

:root {
  --study-bg: #0a0c0f;
  --study-panel: #0d1117;
  --study-border: #1a2332;
  --study-border-dim: #111820;
  --study-green: #00ff88;
  --study-green-dim: #00cc6a;
  --study-green-glow: rgba(0, 255, 136, 0.08);
  --study-red: #ff3355;
  --study-purple: #9b59b6;
  --study-text: #c8d8e8;
  --study-text-dim: #6a8298;
  --study-text-muted: #3a4f62;
  --study-code-bg: #060a0e;
  --study-font-mono: "Courier New", "Lucida Console", monospace;
  --study-font-main: "Segoe UI", system-ui, sans-serif;
  --study-radius: 4px;
  --study-transition: 0.2s ease;
}

/* ── Icons ── */
.svg-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}
.svg-icon svg {
  display: block;
}

.study-layout {
  display: flex;
  height: calc(100vh - 120px);
  min-height: 480px;
  position: relative;
  background: var(--study-bg);
}

/* ── Sidebar ── */
.study-sidebar {
  width: 240px;
  min-width: 240px;
  background: var(--study-panel);
  border-right: 1px solid var(--study-border);
  display: flex;
  flex-direction: column;
  overflow: hidden;
}
.study-sidebar-header {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 14px 12px;
  border-bottom: 1px solid var(--study-border);
  background: rgba(0, 255, 136, 0.03);
  flex-shrink: 0;
}
.study-sidebar-icon {
  color: var(--study-green);
}
.study-sidebar-title {
  font-family: var(--study-font-mono);
  font-size: 10px;
  font-weight: bold;
  letter-spacing: 0.15em;
  color: var(--study-green);
  text-transform: uppercase;
}

.study-module-list {
  flex: 1;
  overflow-y: auto;
  padding: 6px 0;
  scrollbar-width: thin;
  scrollbar-color: var(--study-border) transparent;
}
.study-module-list::-webkit-scrollbar {
  width: 4px;
}
.study-module-list::-webkit-scrollbar-track {
  background: transparent;
}
.study-module-list::-webkit-scrollbar-thumb {
  background: var(--study-border);
  border-radius: 2px;
}

.study-module-item {
  padding: 10px 12px;
  border-bottom: 1px solid var(--study-border-dim);
  cursor: pointer;
  transition: background var(--study-transition);
  position: relative;
}
.study-module-item:hover {
  background: rgba(0, 255, 136, 0.04);
}
.study-module-item.active {
  background: rgba(0, 255, 136, 0.07);
  border-left: 2px solid var(--study-green);
}
.study-module-item.locked {
  cursor: not-allowed;
  opacity: 0.5;
}
.study-module-item.locked:hover {
  background: transparent;
}
.study-module-item.completed .smi-icon {
  color: var(--study-green);
}

.smi-header {
  display: flex;
  align-items: center;
  gap: 8px;
}
.smi-icon {
  color: var(--study-text-dim);
  flex-shrink: 0;
  width: 18px;
  display: flex;
  align-items: center;
  justify-content: center;
}
.smi-info {
  flex: 1;
  min-width: 0;
}
.smi-title {
  display: block;
  font-family: var(--study-font-mono);
  font-size: 10px;
  font-weight: bold;
  color: var(--study-text);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.smi-sub {
  display: block;
  font-size: 9px;
  color: var(--study-text-muted);
  margin-top: 2px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.smi-status {
  font-family: var(--study-font-mono);
  font-size: 10px;
  color: var(--study-green);
  flex-shrink: 0;
  display: flex;
  align-items: center;
}
.smi-progress-bar {
  height: 2px;
  background: var(--study-border);
  border-radius: 1px;
  margin-top: 6px;
  overflow: hidden;
}
.smi-progress-fill {
  height: 100%;
  background: var(--study-green);
  transition: width 0.4s ease;
}
.smi-lock-msg {
  font-size: 9px;
  color: var(--study-text-muted);
  margin-top: 5px;
  font-family: var(--study-font-mono);
}

.study-content-panel {
  flex: 1;
  overflow-y: auto;
  overflow-x: hidden;
  padding: 20px 24px 56px;
  scrollbar-width: thin;
  scrollbar-color: var(--study-border) transparent;
}
.study-content-panel::-webkit-scrollbar {
  width: 5px;
}
.study-content-panel::-webkit-scrollbar-track {
  background: transparent;
}
.study-content-panel::-webkit-scrollbar-thumb {
  background: var(--study-border);
  border-radius: 3px;
}

/* ── Boas-vindas ── */
.study-welcome {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  min-height: 360px;
  text-align: center;
  gap: 14px;
}
.study-welcome-icon {
  color: var(--study-green);
  opacity: 0.3;
  animation: swPulse 3s infinite;
}
@keyframes swPulse {
  0%,
  100% {
    opacity: 0.3;
  }
  50% {
    opacity: 0.6;
  }
}
.study-welcome-title {
  font-family: var(--study-font-mono);
  font-size: 17px;
  color: var(--study-text);
  font-weight: normal;
  margin: 0;
}
.study-welcome-desc {
  font-size: 13px;
  color: var(--study-text-dim);
  line-height: 1.7;
  max-width: 360px;
  margin: 0;
}

/* ══════════════════════════════════════════
   CONTEÚDO DO MÓDULO
══════════════════════════════════════════ */
.study-module-view {
  max-width: 760px;
}

.smv-header {
  display: flex;
  align-items: center;
  gap: 14px;
  margin-bottom: 16px;
  padding-bottom: 16px;
  border-bottom: 1px solid var(--study-border);
}
.smv-icon {
  color: var(--study-green);
  opacity: 0.7;
  flex-shrink: 0;
}
.smv-titles {
  flex: 1;
}
.smv-title {
  font-family: var(--study-font-mono);
  font-size: 20px;
  color: var(--study-text);
  margin: 0 0 4px;
  font-weight: normal;
}
.smv-subtitle {
  font-size: 13px;
  color: var(--study-text-dim);
  margin: 0;
}
.smv-time {
  font-family: var(--study-font-mono);
  font-size: 10px;
  color: var(--study-text-muted);
  flex-shrink: 0;
}

.smv-progress-wrap {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 16px;
}
.smv-progress-bar {
  flex: 1;
  height: 3px;
  background: var(--study-border);
  border-radius: 2px;
  overflow: hidden;
}
.smv-progress-fill {
  height: 100%;
  background: linear-gradient(
    90deg,
    var(--study-green-dim),
    var(--study-green)
  );
  transition: width 0.5s ease;
  box-shadow: 0 0 6px var(--study-green);
}
.smv-progress-label {
  font-family: var(--study-font-mono);
  font-size: 10px;
  color: var(--study-green);
  white-space: nowrap;
  flex-shrink: 0;
  width: 58px;
  text-align: right;
}

.smv-sections {
  display: flex;
  flex-direction: column;
  gap: 28px;
  margin-top: 6px;
}
.smv-section {
  opacity: 0.6;
  transition: opacity 0.4s ease;
  position: relative;
}
.smv-section.read {
  opacity: 1;
}
.smv-section.read::before {
  content: "";
  position: absolute;
  right: -18px;
  top: 4px;
  width: 13px;
  height: 13px;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 14 14'%3E%3Cpath d='M2 7l3.5 3.5L12 4' stroke='%2300ff88' stroke-width='1.5' fill='none' stroke-linecap='round' stroke-linejoin='round' opacity='0.5'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-size: contain;
}

.sec-title {
  font-family: var(--study-font-mono);
  font-size: 13px;
  font-weight: bold;
  color: var(--study-green);
  margin: 0 0 10px;
  letter-spacing: 0.05em;
  text-transform: uppercase;
}
.sec-body {
  font-family: var(--study-font-main);
  font-size: 13px;
  line-height: 1.8;
  color: var(--study-text);
  margin: 0 0 10px;
}
.sec-body:last-child {
  margin-bottom: 0;
}

.sec-cards {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(185px, 1fr));
  gap: 10px;
  margin-top: 12px;
}
.sec-card {
  background: var(--study-panel);
  border: 1px solid var(--study-border);
  border-radius: var(--study-radius);
  padding: 12px;
  transition:
    border-color var(--study-transition),
    background var(--study-transition);
}
.sec-card:hover {
  border-color: var(--study-green);
  background: var(--study-green-glow);
}
.sec-card-icon {
  display: block;
  margin-bottom: 7px;
  color: var(--study-green);
  opacity: 0.8;
}
.sec-card-term {
  display: block;
  font-family: var(--study-font-mono);
  font-size: 11px;
  color: var(--study-green);
  margin-bottom: 5px;
}
.sec-card-def {
  font-size: 12px;
  line-height: 1.6;
  color: var(--study-text-dim);
  margin: 0;
}

.sec-code-desc {
  font-size: 13px;
  color: var(--study-text-dim);
  margin: 7px 0 10px;
  font-style: italic;
}
.sec-code-block {
  background: var(--study-code-bg);
  border: 1px solid var(--study-border);
  border-radius: var(--study-radius);
  overflow: hidden;
}
.sec-code-lang {
  background: var(--study-border);
  padding: 3px 10px;
  font-family: var(--study-font-mono);
  font-size: 10px;
  color: var(--study-text-muted);
  text-transform: uppercase;
  letter-spacing: 0.1em;
}
.sec-code {
  margin: 0;
  padding: 14px;
  overflow-x: auto;
  font-family: var(--study-font-mono);
  font-size: 12px;
  line-height: 1.7;
  color: var(--study-green-dim);
  scrollbar-width: thin;
  scrollbar-color: var(--study-border) transparent;
}
.sec-code code {
  font-family: inherit;
}

/* ══════════════════════════════════════════
   NAVEGAÇÃO — top + bottom
   Grid 3 colunas garante Anterior | dots | Próximo
   sempre alinhados e visíveis.
══════════════════════════════════════════ */
.smv-module-nav {
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  gap: 12px;
}
.smv-module-nav--top {
  margin-bottom: 24px;
  padding-bottom: 18px;
  border-bottom: 1px solid var(--study-border-dim);
}
.smv-module-nav--bottom {
  margin-top: 40px;
  padding-top: 24px;
  border-top: 1px solid var(--study-border);
}

.smv-nav-side {
  display: flex;
}
.smv-nav-prev {
  justify-content: flex-start;
}
.smv-nav-next {
  justify-content: flex-end;
}

.smv-nav-btn {
  display: flex;
  align-items: center;
  gap: 10px;
  background: rgba(255, 255, 255, 0.02);
  border: 1px solid var(--study-border);
  padding: 12px 16px;
  cursor: pointer;
  border-radius: var(--study-radius);
  transition: all 0.25s ease;
  max-width: 240px;
  text-align: left;
}
.smv-nav-btn:hover:not(:disabled) {
  background: rgba(0, 255, 136, 0.06);
  border-color: var(--study-green);
  box-shadow: 0 0 12px rgba(0, 255, 136, 0.12);
  transform: translateY(-1px);
}
.smv-nav-btn--prev:hover:not(:disabled) {
  transform: translateX(-2px) translateY(-1px);
}
.smv-nav-btn--next:hover:not(:disabled) {
  transform: translateX(2px) translateY(-1px);
}
.smv-nav-btn--locked {
  opacity: 0.4;
  cursor: not-allowed;
  border-style: dashed;
}

.smv-nav-arrow {
  color: var(--study-green);
  flex-shrink: 0;
  transition:
    color 0.2s,
    transform 0.2s;
  display: flex;
  align-items: center;
}
.smv-nav-arrow--dim {
  color: var(--study-text-muted);
}
.smv-nav-btn--prev:hover:not(:disabled) .smv-nav-arrow {
  transform: translateX(-3px);
}
.smv-nav-btn--next:hover:not(:disabled) .smv-nav-arrow {
  transform: translateX(3px);
}

.smv-nav-info {
  display: flex;
  flex-direction: column;
  gap: 3px;
  min-width: 0;
}
.smv-nav-label {
  display: block;
  font-family: var(--study-font-mono);
  font-size: 9px;
  letter-spacing: 0.12em;
  color: var(--study-text-muted);
  text-transform: uppercase;
}
.smv-nav-name {
  display: block;
  font-family: var(--study-font-mono);
  font-size: 11px;
  font-weight: bold;
  color: var(--study-text);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  max-width: 155px;
  transition: color 0.2s;
}
.smv-nav-btn:hover:not(:disabled) .smv-nav-name {
  color: var(--study-green);
}
.smv-nav-lock-hint {
  display: block;
  font-size: 9px;
  color: var(--study-text-muted);
  font-family: var(--study-font-mono);
  margin-top: 2px;
  font-style: italic;
}

.smv-nav-center {
  display: flex;
  align-items: center;
  gap: 5px;
  justify-content: center;
}
.smv-nav-dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--study-border);
  cursor: pointer;
  transition: all 0.25s ease;
  border: 1px solid transparent;
}
.smv-nav-dot:hover {
  background: var(--study-text-muted);
  transform: scale(1.2);
}
.smv-nav-dot.active {
  background: var(--study-green);
  box-shadow: 0 0 8px var(--study-green);
  border-color: var(--study-green);
  transform: scale(1.3);
}
.smv-nav-dot.done {
  background: var(--study-green-dim);
  opacity: 0.6;
}

.smv-nav-end {
  display: flex;
  justify-content: flex-end;
  align-items: center;
}
.smv-nav-end-label {
  font-family: var(--study-font-mono);
  font-size: 10px;
  color: var(--study-text-muted);
  letter-spacing: 0.08em;
  border: 1px dashed var(--study-border);
  padding: 8px 12px;
  border-radius: var(--study-radius);
}

/* ══════════════════════════════════════════
   CHECKPOINT
══════════════════════════════════════════ */
.smv-checkpoint-wrap {
  margin-top: 36px;
  padding: 24px 20px;
  border: 1px solid var(--study-border);
  border-radius: var(--study-radius);
  background: rgba(0, 255, 136, 0.02);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 14px;
  text-align: center;
  position: relative;
  overflow: hidden;
}
.smv-checkpoint-wrap::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 2px;
  background: linear-gradient(
    90deg,
    transparent,
    var(--study-border),
    transparent
  );
  transition: background 0.5s ease;
}
.smv-checkpoint-wrap:has(#smv-checkpoint-btn.ready)::before,
.smv-checkpoint-wrap.completed::before {
  background: linear-gradient(
    90deg,
    transparent,
    var(--study-green),
    transparent
  );
}
.smv-checkpoint-wrap.completed {
  border-color: rgba(0, 255, 136, 0.3);
  background: rgba(0, 255, 136, 0.05);
}

.smv-checkpoint-title {
  font-family: var(--study-font-mono);
  font-size: 10px;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: var(--study-text-muted);
}
.smv-checkpoint-msg {
  font-size: 13px;
  color: var(--study-text-dim);
  line-height: 1.6;
  max-width: 400px;
  margin: 0;
}

.smv-checkpoint-progress {
  width: 100%;
  max-width: 320px;
  height: 2px;
  background: var(--study-border);
  border-radius: 1px;
  overflow: hidden;
}
.smv-checkpoint-progress-fill {
  height: 100%;
  background: linear-gradient(
    90deg,
    var(--study-green-dim),
    var(--study-green)
  );
  transition: width 0.6s ease;
  box-shadow: 0 0 6px var(--study-green);
}

.smv-checkpoint-btn {
  display: flex;
  align-items: center;
  gap: 10px;
  font-family: var(--study-font-mono);
  font-size: 12px;
  font-weight: bold;
  color: var(--study-text-muted);
  background: transparent;
  border: 1px solid var(--study-border);
  padding: 13px 28px;
  cursor: not-allowed;
  letter-spacing: 0.12em;
  transition: all 0.35s ease;
  text-transform: uppercase;
  border-radius: var(--study-radius);
}
.smv-checkpoint-btn.needs-scroll {
  border-style: dashed;
  opacity: 0.45;
}
.smv-checkpoint-btn.ready {
  color: var(--study-green);
  border-color: var(--study-green);
  cursor: pointer;
  opacity: 1;
  animation: cpPulse 2.5s ease-in-out infinite;
}
@keyframes cpPulse {
  0%,
  100% {
    box-shadow: 0 0 0 0 rgba(0, 255, 136, 0);
  }
  50% {
    box-shadow: 0 0 0 6px rgba(0, 255, 136, 0.12);
  }
}
.smv-checkpoint-btn.ready:hover {
  background: var(--study-green);
  color: #000;
  box-shadow: 0 0 24px rgba(0, 255, 136, 0.4);
  animation: none;
  transform: translateY(-1px);
}
.smv-checkpoint-btn.ready:active {
  transform: scale(0.98) translateY(0);
}
.smv-checkpoint-btn:disabled:not(.needs-scroll):not(.ready) {
  opacity: 0.4;
  cursor: not-allowed;
}

.smv-checkpoint-hint {
  font-family: var(--study-font-mono);
  font-size: 10px;
  color: var(--study-text-muted);
  display: flex;
  align-items: center;
  gap: 6px;
  animation: hintBounce 2s ease-in-out infinite;
}
@keyframes hintBounce {
  0%,
  100% {
    transform: translateY(0);
  }
  50% {
    transform: translateY(3px);
  }
}

.smv-checkpoint-done {
  display: flex;
  align-items: center;
  gap: 10px;
  font-family: var(--study-font-mono);
  font-size: 13px;
  color: var(--study-green);
  letter-spacing: 0.08em;
}

/* ══════════════════════════════════════════
   LOKI OVERLAY
══════════════════════════════════════════ */
.loki-study-overlay {
  position: absolute;
  inset: 0;
  background: rgba(5, 2, 8, 0.97);
  z-index: 100;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 24px;
}
.loki-glitch-bar {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 3px;
  background: linear-gradient(
    90deg,
    transparent,
    var(--study-red),
    var(--study-purple),
    var(--study-red),
    transparent
  );
  animation: lgBar 0.8s infinite;
}
@keyframes lgBar {
  0%,
  100% {
    opacity: 1;
    transform: scaleX(1);
  }
  50% {
    opacity: 0.4;
    transform: scaleX(0.98) translateX(4px);
  }
}

.loki-overlay-inner {
  width: 100%;
  max-width: 560px;
  display: flex;
  flex-direction: column;
  gap: 18px;
}
.loki-header {
  display: flex;
  align-items: center;
  gap: 12px;
  padding-bottom: 14px;
  border-bottom: 1px solid rgba(255, 51, 85, 0.2);
}
.loki-moon {
  color: var(--study-purple);
  animation: moonPulse 2s infinite;
}
@keyframes moonPulse {
  0%,
  100% {
    filter: drop-shadow(0 0 4px var(--study-purple));
  }
  50% {
    filter: drop-shadow(0 0 12px var(--study-purple))
      drop-shadow(0 0 20px var(--study-red));
  }
}
.loki-titles {
  flex: 1;
}
.loki-name {
  font-family: var(--study-font-mono);
  font-size: 15px;
  font-weight: bold;
  color: var(--study-red);
  letter-spacing: 0.15em;
}
.loki-sub {
  font-family: var(--study-font-mono);
  font-size: 10px;
  color: rgba(255, 51, 85, 0.5);
  margin-top: 3px;
}
.loki-q-counter {
  font-family: var(--study-font-mono);
  font-size: 12px;
  color: var(--study-text-muted);
  flex-shrink: 0;
}

.loki-taunt-wrap {
  background: rgba(155, 89, 182, 0.06);
  border: 1px solid rgba(155, 89, 182, 0.2);
  border-left: 3px solid var(--study-purple);
  padding: 10px 14px;
  border-radius: var(--study-radius);
}
.loki-taunt {
  font-family: var(--study-font-mono);
  font-size: 12px;
  color: rgba(200, 180, 220, 0.85);
  margin: 0;
  font-style: italic;
  line-height: 1.6;
}

.loki-timer-wrap {
  display: flex;
  align-items: center;
  gap: 10px;
}
.loki-timer-bar {
  flex: 1;
  height: 4px;
  background: rgba(255, 255, 255, 0.08);
  border-radius: 2px;
  overflow: hidden;
}
.loki-timer-fill {
  height: 100%;
  background: var(--study-green);
  transition:
    width 0.1s linear,
    background 0.3s ease;
}
.loki-timer-fill.critical {
  background: var(--study-red);
  box-shadow: 0 0 8px var(--study-red);
  animation: timerFlicker 0.4s infinite;
}
@keyframes timerFlicker {
  0%,
  100% {
    opacity: 1;
  }
  50% {
    opacity: 0.6;
  }
}
.loki-timer-label {
  font-family: var(--study-font-mono);
  font-size: 14px;
  font-weight: bold;
  color: var(--study-text);
  width: 24px;
  text-align: right;
  flex-shrink: 0;
}

.loki-question {
  font-family: var(--study-font-main);
  font-size: 14px;
  color: var(--study-text);
  line-height: 1.5;
  font-weight: 500;
}
.loki-options {
  display: flex;
  flex-direction: column;
  gap: 7px;
}
.loki-option {
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid var(--study-border);
  color: var(--study-text-dim);
  padding: 10px 14px;
  text-align: left;
  font-family: var(--study-font-main);
  font-size: 13px;
  cursor: pointer;
  border-radius: var(--study-radius);
  transition: all var(--study-transition);
  line-height: 1.4;
}
.loki-option:hover:not(:disabled) {
  background: rgba(0, 255, 136, 0.06);
  border-color: var(--study-green);
  color: var(--study-text);
}
.loki-option:disabled {
  cursor: default;
}
.loki-option.correct {
  background: rgba(0, 255, 136, 0.1);
  border-color: var(--study-green);
  color: var(--study-green);
}
.loki-option.wrong {
  background: rgba(255, 51, 85, 0.1);
  border-color: var(--study-red);
  color: var(--study-red);
}

.loki-result {
  padding: 10px 14px;
  border-radius: var(--study-radius);
  font-family: var(--study-font-main);
  font-size: 13px;
  line-height: 1.6;
  animation: lrFade 0.3s ease;
}
@keyframes lrFade {
  from {
    opacity: 0;
    transform: translateY(4px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}
.loki-result.win {
  background: rgba(0, 255, 136, 0.07);
  border: 1px solid rgba(0, 255, 136, 0.25);
  color: rgba(0, 255, 136, 0.85);
}
.loki-result.fail {
  background: rgba(255, 51, 85, 0.07);
  border: 1px solid rgba(255, 51, 85, 0.25);
  color: rgba(255, 150, 150, 0.9);
}
.lr-icon {
  margin-right: 6px;
}

.loki-study-overlay.glitch-in {
  animation: oIn 0.5s ease forwards;
}
.loki-study-overlay.glitch-out {
  animation: oOut 0.4s ease forwards;
}
@keyframes oIn {
  0% {
    opacity: 0;
    clip-path: inset(100% 0 0 0);
  }
  40% {
    clip-path: inset(0 0 60% 0);
  }
  60% {
    clip-path: inset(20% 0 10% 0);
  }
  80% {
    clip-path: inset(5% 0 5% 0);
  }
  100% {
    opacity: 1;
    clip-path: inset(0 0 0 0);
  }
}
@keyframes oOut {
  0% {
    opacity: 1;
    clip-path: inset(0 0 0 0);
  }
  40% {
    clip-path: inset(50% 0 0 0);
  }
  100% {
    opacity: 0;
    clip-path: inset(100% 0 0 0);
  }
}

/* ══════════════════════════════════════════
   RESPONSIVO
══════════════════════════════════════════ */
@media (max-width: 768px) {
  .study-layout {
    height: auto;
    min-height: 0;
    flex-direction: column;
  }
  .study-sidebar {
    width: 100%;
    min-width: unset;
    max-height: 180px;
    border-right: none;
    border-bottom: 1px solid var(--study-border);
  }
  .study-content-panel {
    padding: 14px 14px 32px;
  }
  .sec-cards {
    grid-template-columns: 1fr;
  }
  .smv-title {
    font-size: 17px;
  }
  .smv-module-nav {
    grid-template-columns: 1fr 1fr;
    grid-template-rows: auto auto;
  }
  .smv-nav-center {
    grid-column: 1 / -1;
    order: -1;
    margin-bottom: 6px;
  }
  .smv-nav-btn {
    max-width: 100%;
  }
  .smv-nav-name {
    max-width: 100px;
  }
}
@media (max-width: 480px) {
  .smv-module-nav {
    grid-template-columns: 1fr;
    gap: 8px;
  }
  .smv-nav-prev,
  .smv-nav-next {
    justify-content: center;
  }
  .smv-nav-btn {
    width: 100%;
    max-width: 100%;
  }
}
