/* === RESET === */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

html { height: 100%; }

body {
  height: 100%;
  font-family: 'Archivo', sans-serif;
  font-weight: 400;
  background: #000;
  color: #fff;
  -webkit-font-smoothing: antialiased;
}

/* === FONT HELPERS === */
.font-a {
  font-family: 'Times New Roman', Times, serif;
  font-style: italic;
  font-weight: 700;
  font-size: 1.07em;   /* Times NR italic is optically smaller — scale up to match Archivo caps */
  line-height: 1;
}
.font-b {
  font-family: 'Archivo', sans-serif;
  font-weight: 800;
  font-style: normal;
  line-height: 1;
}
em {
  font-family: 'Times New Roman', Times, serif;
  font-style: italic;
  font-weight: 700;
}

/* === SCREEN MANAGEMENT === */
.screen {
  position: fixed;
  inset: 0;
  display: none;
  flex-direction: column;
  overflow-y: auto;
  -webkit-overflow-scrolling: touch;
}
.screen.active { display: flex; }

/* === UNIVERSAL BUTTON === */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  background: #000000;
  color: #FFFFFF;
  border: none;
  border-radius: 8px;
  font-family: 'Archivo', sans-serif;
  font-weight: 800;
  font-size: 14px;
  padding: 10px 18px;
  cursor: pointer;
  white-space: nowrap;
  transition: opacity 0.15s;
}
.btn:hover { opacity: 0.85; }
.btn:active { opacity: 0.7; }

.btn-warning { background: #FFFFFF; color: #000000; }
.btn-danger  { background: #CC0000; color: #FFFFFF; }

.btn-help {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 20px;
  height: 20px;
  border-radius: 50%;
  border: 1.5px solid rgba(255,255,255,0.35);
  background: transparent;
  color: rgba(255,255,255,0.35);
  font-family: 'Archivo', sans-serif;
  font-weight: 800;
  font-size: 11px;
  cursor: pointer;
  padding: 0;
  flex-shrink: 0;
  vertical-align: middle;
}

.btn-full {
  width: 100%;
  padding: 15px;
  font-size: 16px;
  border-radius: 10px;
  background: #000000;
  color: #FFFFFF;
  border: none;
  font-family: 'Archivo', sans-serif;
  font-weight: 800;
  cursor: pointer;
  transition: opacity 0.15s;
}
.btn-full:hover { opacity: 0.85; }

/* === FOOTER LOGOTYPE (Configuration D) === */
.footer-logo {
  display: flex;
  align-items: baseline;
  justify-content: center;
  flex-wrap: wrap;
  gap: 8px;
  padding: 14px 16px;
  background: #000;
  font-size: 13px;
  flex-shrink: 0;
}
.footer-logo .logo-en {
  font-family: 'Arial Black', sans-serif;
  font-weight: 900;
  color: #FFFFFF;
}
.footer-logo .logo-be {
  font-family: 'Times New Roman', Times, serif;
  font-style: italic;
  font-weight: 700;
  font-size: 15px;
  color: #E8365A;
}
.footer-logo .logo-bilingual {
  font-family: 'Archivo', sans-serif;
  font-weight: 800;
  color: #E8365A;
  margin-left: -4px;
}

/* =============================================
   SCREEN 0 — SPLASH
   ============================================= */
#screen-splash {
  background: #E8365A;
  align-items: center;
  justify-content: center;
  transition: opacity 0.8s ease;
}
.splash-logo {
  text-align: center;
  padding: 20px;
}
.splash-wordmark {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 0.3em;
  font-size: clamp(28px, 6.5vw, 64px);
  line-height: 1;
  text-align: center;
}
.splash-line-2 {
  display: flex;
  align-items: baseline;
  flex-wrap: wrap;
  justify-content: center;
  gap: 0.14em;
}
.splash-logo-main {
  font-family: 'Arial Black', sans-serif;
  font-weight: 900;
  color: #000000;
  letter-spacing: -1px;
}
.splash-divider {
  display: none;
  font-family: Arial, sans-serif;
  font-weight: 300;
  color: #000000;
  margin: 0 0.2em;
  line-height: 1;
  align-self: baseline;
}
.splash-be {
  font-family: 'Times New Roman', Times, serif;
  font-style: italic;
  font-weight: 700;
  color: #F5E027;
  font-size: 1.2em;
  line-height: 1;
}
.splash-bilingual {
  font-family: 'Archivo', sans-serif;
  font-weight: 800;
  color: #F5E027;
}

@media (min-width: 1100px) {
  .splash-wordmark {
    flex-direction: row;
    align-items: baseline;
  }
  .splash-line-2 {
    flex-wrap: nowrap;
  }
  .splash-divider {
    display: inline;
  }
}

/* =============================================
   SCREEN 1 — LOGIN
   ============================================= */
#screen-login, #screen-teacher-access {
  background: #000000;
  justify-content: space-between;
  min-height: 100%;
}

/* Language toggle */
.lang-toggle {
  display: flex;
  justify-content: flex-end;
  padding: 12px 16px 0;
  gap: 6px;
}
.lang-btn {
  background: transparent;
  border: 1px solid rgba(255,255,255,0.25);
  color: rgba(255,255,255,0.5);
  border-radius: 6px;
  padding: 5px 10px;
  font-family: 'Archivo', sans-serif;
  font-weight: 700;
  font-size: 12px;
  cursor: pointer;
  transition: all 0.2s;
}
.lang-btn.active {
  background: #FFFFFF;
  color: #000000;
  border-color: #FFFFFF;
}
.btn-info-login {
  background: #000;
  color: rgba(255,255,255,0.5);
  border: 1px solid rgba(255,255,255,0.15);
  border-radius: 6px;
  padding: 5px 10px;
  font-family: 'Archivo', sans-serif;
  font-weight: 700;
  font-size: 12px;
  cursor: pointer;
}

/* Login header / title */
.login-header {
  text-align: center;
  padding: 16px 20px 12px;
}
.app-title-1 {
  font-family: 'Archivo', sans-serif;
  font-weight: 800;
  color: #FFFFFF;
  font-size: clamp(20px, 5vw, 34px);
  display: inline;
}
.app-title-2 {
  font-family: 'Times New Roman', Times, serif;
  font-style: italic;
  font-weight: 700;
  color: #FFFFFF;
  font-size: clamp(23.5px, 5.85vw, 40.5px);
  display: inline;
  margin-left: 6px;
}

/* Login body — contains tab switcher + card */
.login-body {
  flex: 1;
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: 0 16px;
  max-width: 480px;
  margin: 0 auto;
  width: 100%;
}

/* Tab switcher */
.tab-switcher {
  display: flex;
  background: #1a1a1a;
  border: 1px solid rgba(255,255,255,0.1);
  border-radius: 50px;
  padding: 4px;
  margin-bottom: 6px;
}
.tab-btn {
  flex: 1;
  background: transparent;
  border: none;
  color: rgba(255,255,255,0.45);
  font-family: 'Archivo', sans-serif;
  font-weight: 700;
  font-size: 13px;
  padding: 10px 8px;
  border-radius: 50px;
  cursor: pointer;
  transition: all 0.2s;
}
.tab-btn.active {
  background: #FFFFFF;
  color: #000000;
}

/* White login card */
.login-card {
  background: #FFFFFF;
  border-radius: 16px;
  padding: 22px 20px 20px;
}

/* Sub-tab switcher inside card */
.sub-tab-switcher {
  display: flex;
  gap: 6px;
  margin-bottom: 18px;
}
.sub-tab-btn {
  flex: 1;
  padding: 10px 8px;
  border-radius: 8px;
  font-family: 'Archivo', sans-serif;
  font-weight: 700;
  font-size: 13px;
  cursor: pointer;
  border: 1px solid #e0e0e0;
  background: #fff;
  color: #555;
  transition: all 0.2s;
}
.sub-tab-btn.active {
  background: #000000;
  color: #FFFFFF;
  border-color: #000;
}

/* Form fields inside card */
.form-group { margin-bottom: 14px; }
.form-group label {
  display: block;
  font-size: 10px;
  font-weight: 700;
  color: #444;
  text-transform: uppercase;
  letter-spacing: 0.6px;
  margin-bottom: 5px;
  font-family: 'Archivo', sans-serif;
}
.form-group input,
.form-group select,
.form-group textarea {
  width: 100%;
  padding: 11px 13px;
  border-radius: 8px;
  border: 1px solid #ddd;
  font-size: 15px;
  color: #222;
  background: #f8f8f8;
  font-family: 'Archivo', sans-serif;
  font-weight: 500;
  transition: border-color 0.2s;
  box-sizing: border-box;
}
.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
  outline: none;
  border-color: #000;
  background: #fff;
}

.input-reveal-wrap { position: relative; }
.input-reveal-wrap .input-class-code { padding-right: 58px; }
.btn-reveal {
  position: absolute;
  right: 10px;
  top: 50%;
  transform: translateY(-50%);
  background: none;
  border: none;
  color: rgba(0,0,0,0.35);
  font-size: 11px;
  font-weight: 700;
  font-family: 'Archivo', sans-serif;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  cursor: pointer;
  padding: 4px;
}
.btn-reveal:hover { color: rgba(0,0,0,0.65); }

.remember-row {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 14px;
  cursor: pointer;
}
.label-remember {
  font-size: 13px;
  color: #555;
  cursor: pointer;
  font-family: 'Archivo', sans-serif;
}

.error-msg {
  color: #cc0000;
  font-size: 13px;
  margin-top: 8px;
  text-align: center;
  font-family: 'Archivo', sans-serif;
  font-weight: 600;
}

/* Recovery panel */
.recovery-intro {
  font-size: 14px;
  color: #444;
  margin-bottom: 14px;
  font-family: 'Archivo', sans-serif;
}
.recovery-success {
  background: #e8f5e9;
  border-radius: 8px;
  padding: 12px;
  margin-top: 10px;
  font-size: 13px;
  color: #2e7d32;
  font-family: 'Archivo', sans-serif;
  font-weight: 600;
}
/* Register success */
.register-success { display: none; }
.account-created-title {
  font-size: 20px;
  font-weight: 700;
  color: #000;
  margin-bottom: 10px;
  font-family: 'Archivo', sans-serif;
}
.generated-code {
  display: block;
  font-size: 28px;
  font-weight: 800;
  color: #000;
  letter-spacing: 3px;
  text-align: center;
  padding: 14px;
  background: #f0f0f0;
  border-radius: 8px;
  margin: 12px 0;
  font-family: 'Archivo', sans-serif;
}
.success-msg {
  font-size: 13px;
  color: #444;
  margin-bottom: 14px;
  font-family: 'Archivo', sans-serif;
}

/* Login footer */
.login-footer {
  padding: 8px 16px 16px;
  text-align: center;
}
.teacher-access-link {
  display: block;
  color: rgba(255,255,255,0.3);
  font-size: 12px;
  text-decoration: none;
  margin-top: 8px;
  font-family: 'Archivo', sans-serif;
  font-weight: 600;
  transition: color 0.2s;
}
.teacher-access-link:hover { color: rgba(255,255,255,0.6); }

#screen-teacher-access .login-card {
  background: #F5E027;
}

/* Tab / sub-panel visibility */
.tab-panel { display: none; }
.tab-panel.active { display: block; }
.sub-panel { display: none; }
.sub-panel.active { display: block; }
.hidden { display: none !important; }

/* =============================================
   STUDY SESSION SCREEN
   ============================================= */
#screen-session {
  background: #000000;
  min-height: 100%;
}

/* Top session navigation bar */
.session-nav {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
  padding: 12px 14px 8px;
  flex-shrink: 0;
}
.session-nav-left { flex: 1; min-width: 0; }
.cards-remaining-text {
  font-size: 12px;
  color: rgba(255,255,255,0.45);
  font-weight: 600;
  margin-bottom: 5px;
  font-family: 'Archivo', sans-serif;
}
.progress-track {
  height: 4px;
  background: rgba(255,255,255,0.12);
  border-radius: 2px;
  overflow: hidden;
}
.progress-fill {
  height: 100%;
  background: #3AABDC;
  border-radius: 2px;
  transition: width 0.4s ease;
}
.session-nav-right {
  display: flex;
  gap: 6px;
  flex-shrink: 0;
}
.session-nav-right .btn {
  padding: 8px 12px;
  font-size: 12px;
  border-radius: 6px;
}
.session-nav-right .btn-config {
  padding: 12px 18px;
  font-size: 18px;
}

/* Card wrapper */
.card-area {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: flex-start;
  padding: 12px 14px;
}

/* THE VERB CARD */
.verb-card {
  width: 100%;
  max-width: 420px;
  border-radius: 22px;
  overflow: hidden;
  background: var(--card-bg, #3AABDC);
}

/* Card type CSS variables applied by JS */
.verb-card { --card-bg: #3AABDC; --card-font: #E8365A; --card-panel: #2186b0; }

/* Media slot — always reserves space */
.media-slot {
  width: 100%;
  aspect-ratio: 1 / 1;
  border-radius: 12px;
  overflow: hidden;
  display: block;
}
.media-slot:empty { visibility: hidden; }
.media-img, .media-vid {
  width: 100%;
  height: 100%;
  object-fit: cover;
  border-radius: 12px;
}

/* Audio buttons — type colour system (not universal black) */
.audio-btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: var(--card-panel);
  color: var(--card-font);
  border: none;
  border-radius: 8px;
  padding: 8px 14px;
  font-family: 'Archivo', sans-serif;
  font-weight: 700;
  font-size: 14px;
  cursor: pointer;
}
.audio-btn-sm {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  background: var(--card-panel);
  color: var(--card-font);
  border: none;
  border-radius: 8px;
  font-size: 14px;
  cursor: pointer;
  flex-shrink: 0;
  filter: brightness(0.75);
  transition: filter 0.15s;
}
.audio-btn-sm:hover { filter: brightness(0.6); }

/* ---- FRONT FACE ---- */
.card-front-body {
  padding: 28px 22px 22px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 14px;
}

.native-word {
  font-family: 'Times New Roman', Times, serif;
  font-style: italic;
  font-weight: 700;
  font-size: clamp(38px, 10vw, 60px);
  color: var(--card-font);
  text-align: center;
  line-height: 1.05;
  width: 100%;
}

.card-divider {
  width: 80%;
  border: none;
  border-top: 2px dashed var(--card-font);
  opacity: 0.25;
  flex-shrink: 0;
}

.btn-comprobar {
  width: 100%;
  padding: 15px;
  background: #000000;
  color: #FFFFFF;
  border: none;
  border-radius: 10px;
  font-family: 'Archivo', sans-serif;
  font-weight: 800;
  font-size: 17px;
  cursor: pointer;
  text-align: center;
  transition: opacity 0.15s;
}
.btn-comprobar:hover { opacity: 0.85; }

/* ---- BACK FACE ---- */
.card-back-body {
  padding: 22px 20px 20px;
  display: flex;
  flex-direction: column;
  gap: 14px;
}

/* Zone 1 — Infinitive header */
.zone1 {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
}
/* ── Card toggles row ── */
.card-toggles {
  display: flex;
  gap: 16px;
  align-items: center;
  justify-content: center;
  flex-wrap: wrap;
  margin-top: 6px;
}
/* ── Answer mode toggle ── */
.answer-mode-toggle {
  display: flex;
  align-items: center;
  gap: 8px;
}
.mode-label {
  font-family: 'Archivo', sans-serif;
  font-weight: 800;
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  color: var(--card-font);
  opacity: 0.4;
  transition: opacity 0.15s;
}
.mode-label.active { opacity: 1; }
.toggle-switch {
  position: relative;
  width: 44px;
  height: 24px;
  cursor: pointer;
  flex-shrink: 0;
}
.toggle-switch input { opacity: 0; width: 0; height: 0; position: absolute; }
.toggle-slider {
  position: absolute;
  inset: 0;
  background: var(--card-panel);
  border-radius: 12px;
  filter: brightness(0.8);
  transition: filter 0.2s;
}
.toggle-slider::before {
  content: '';
  position: absolute;
  width: 18px;
  height: 18px;
  left: 3px;
  top: 3px;
  background: var(--card-font);
  border-radius: 50%;
  transition: transform 0.2s;
}
.toggle-switch input:checked + .toggle-slider::before { transform: translateX(20px); }
.toggle-switch input:checked + .toggle-slider { filter: brightness(1); }

/* ── Mixed letters mode ── */
.mixed-input-area { display: flex; flex-direction: column; gap: 8px; }
.mixed-answer-display {
  min-height: 44px;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 3px;
  background: rgba(0,0,0,0.15);
  border-radius: 8px;
  padding: 8px 10px;
}
.mixed-answer-char {
  font-family: 'Archivo', sans-serif;
  font-weight: 800;
  font-size: 22px;
  color: var(--card-font);
}
.mixed-placeholder { color: var(--card-font); opacity: 0.25; font-size: 20px; }
.mixed-tiles-row {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  justify-content: center;
}
.mixed-tile {
  font-family: 'Archivo', sans-serif;
  font-weight: 800;
  font-size: 18px;
  color: var(--card-font);
  background: var(--card-panel);
  border: none;
  border-radius: 6px;
  padding: 6px 10px;
  min-width: 34px;
  text-align: center;
  cursor: pointer;
  filter: brightness(0.8);
  transition: filter 0.1s, transform 0.1s;
}
.mixed-tile:hover { filter: brightness(0.65); transform: scale(0.94); }
.mixed-controls-row { display: flex; gap: 8px; justify-content: flex-end; }
@keyframes mixedShake {
  0%,100% { transform: translateX(0); }
  20% { transform: translateX(-6px); }
  50% { transform: translateX(6px); }
  80% { transform: translateX(-3px); }
}
.mixed-wrong { animation: mixedShake 0.4s ease; }

/* ── Pronunciation mic row ── */
.mic-row {
  display: flex;
  gap: 8px;
  align-items: center;
  justify-content: center;
  margin-top: 8px;
}
.btn-mic {
  background: #000000;
  color: #ffffff;
  border: none;
  border-radius: 8px;
  padding: 6px 12px;
  font-family: 'Archivo', sans-serif;
  font-weight: 800;
  font-size: 12px;
  cursor: pointer;
}
@keyframes micPulse {
  0%,100% { background: #E8365A; }
  50% { background: #8B0000; }
}
.btn-mic-active { animation: micPulse 1s ease-in-out infinite; }

.zone1-label-row {
  display: flex;
  align-items: center;
  gap: 8px;
}
.irr-note {
  font-family: 'Times New Roman', Times, serif;
  font-style: italic;
  font-weight: 700;
  font-size: 11px;
  color: var(--card-font);
  opacity: 0.65;
}
.zone1-label {
  font-family: 'Archivo', sans-serif;
  font-weight: 800;
  font-style: normal;
  color: var(--card-font);
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 1.2px;
  opacity: 0.75;
}
.zone1-word {
  font-family: 'Times New Roman', Times, serif;
  font-style: italic;
  font-weight: 700;
  font-size: clamp(38px, 10vw, 60px);
  color: var(--card-font);
  text-align: center;
}
.zone1-rule {
  width: 44px;
  height: 3px;
  background: var(--card-font);
  border-radius: 2px;
  opacity: 0.8;
}

.zone2-divider {
  margin: 0;
  opacity: 0.2;
}

/* Zone 2 — Form panels */
.zone2 {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.verb-form-panel {
  background: var(--card-panel);
  border-radius: 12px;
  padding: 14px;
  transition: opacity 0.3s;
}
.verb-form-panel.locked {
  opacity: 0.45;
  pointer-events: none;
}
.verb-form-panel.completed {
  opacity: 0.85;
}

.form-panel-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 10px;
}
.form-label {
  font-family: 'Archivo', sans-serif;
  font-weight: 800;
  font-style: normal;
  text-transform: uppercase;
  color: var(--card-font);
  font-size: 13px;
}

.form-input-row {
  display: flex;
  gap: 8px;
  align-items: center;
}
.form-input {
  flex: 1;
  padding: 10px 12px;
  border-radius: 8px;
  border: none;
  font-size: 15px;
  color: #222;
  background: rgba(255,255,255,0.92);
  font-family: 'Archivo', sans-serif;
  font-weight: 600;
  outline: none;
  transition: box-shadow 0.2s;
}
.form-input:focus {
  box-shadow: 0 0 0 2px var(--card-font);
}
.form-input.input-correct { background: rgba(255,255,255,0.95); }
.form-input.input-wrong {
  animation: shake 0.4s ease;
  background: rgba(255,220,220,0.95);
}
.input-wrong {
  animation: shake 0.4s ease;
}
@keyframes shake {
  0%,100% { transform: translateX(0); }
  25% { transform: translateX(-6px); }
  75% { transform: translateX(6px); }
}
.form-input:disabled {
  opacity: 0.8;
  cursor: default;
}

.btn-verify {
  width: 40px;
  height: 40px;
  border-radius: 8px;
  border: none;
  background: var(--card-panel);
  color: var(--card-font);
  font-size: 18px;
  font-weight: 800;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  filter: brightness(0.75);
  transition: filter 0.15s;
}
.btn-verify:hover:not(:disabled) { filter: brightness(0.6); }
.btn-verify:disabled { opacity: 0.4; cursor: default; }

.attempt-dots {
  display: flex;
  gap: 6px;
  margin-top: 8px;
  height: 12px;
}
.dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--card-font);
  opacity: 0.2;
  transition: opacity 0.25s;
  flex-shrink: 0;
}
.dot.used { opacity: 0.9; }

.feedback-area {
  margin-top: 6px;
  min-height: 20px;
  font-size: 13px;
  font-family: 'Archivo', sans-serif;
  font-weight: 700;
}
.feedback-ok { color: var(--card-font); }
.feedback-fail { color: var(--card-font); }

.form-answer-reveal {
  font-family: 'Archivo', sans-serif;
  font-weight: 800;
  font-size: 18px;
  color: var(--card-font);
  padding: 6px 0;
}

/* Example sentence area */
.example-sentence-area {
  display: flex;
  flex-direction: column;
  gap: 4px;
  padding: 12px 14px;
  background: var(--card-panel);
  border-radius: 10px;
  opacity: 0.85;
}
.example-label-row {
  display: flex;
  align-items: center;
  gap: 8px;
}
.example-label {
  font-family: 'Archivo', sans-serif;
  font-weight: 800;
  font-style: normal;
  color: var(--card-font);
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.8px;
  opacity: 0.7;
}
.example-text {
  font-size: 15px;
  color: var(--card-font);
  font-style: normal;
  line-height: 1.5;
  font-family: 'Archivo', sans-serif;
  font-weight: 600;
}

/* ---- RATING SCREEN ---- */
.rating-body {
  padding: 32px 22px 28px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 16px;
}

.score-display {
  display: flex;
  align-items: baseline;
  gap: 4px;
  line-height: 1;
}
.score-n {
  font-family: 'Archivo', sans-serif;
  font-weight: 800;
  font-size: 80px;
  color: var(--card-font);
  line-height: 1;
}
.score-denom {
  font-family: 'Archivo', sans-serif;
  font-weight: 700;
  font-size: 38px;
  color: var(--card-font);
  opacity: 0.6;
}

.intentos-label {
  font-family: 'Times New Roman', Times, serif;
  font-style: italic;
  color: var(--card-font);
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 1.5px;
  opacity: 0.7;
}
.que-tal-label {
  font-family: 'Archivo', sans-serif;
  font-weight: 700;
  color: var(--card-font);
  font-size: 12px;
  letter-spacing: 0.5px;
  opacity: 0.8;
  text-align: center;
}

/* Four rating buttons — Universal Button Rule */
.rating-buttons {
  display: flex;
  gap: 8px;
  width: 100%;
}
.rating-btn-wrap {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
}
.rating-btn {
  width: 100%;
  background: #000000;
  color: #FFFFFF;
  border: none;
  border-radius: 8px;
  padding: 13px 4px;
  font-family: 'Archivo', sans-serif;
  font-weight: 800;
  font-size: 12px;
  cursor: pointer;
  text-align: center;
  transition: opacity 0.15s;
  line-height: 1.2;
}
.rating-btn:hover { opacity: 0.85; }
.rating-interval {
  font-size: 11px;
  color: var(--card-font);
  opacity: 0.8;
  text-align: center;
  font-weight: 700;
  font-family: 'Archivo', sans-serif;
}

/* =============================================
   SESSION COMPLETE SCREEN
   ============================================= */
#screen-session-picker {
  background: #000000;
}
.picker-greeting {
  font-family: 'Archivo', sans-serif;
  font-weight: 800;
  font-size: clamp(22px, 5vw, 28px);
  color: #fff;
  margin: 0;
  text-align: center;
  line-height: 1.2;
}

#screen-session-complete {
  background: #000000;
  align-items: center;
  justify-content: center;
  padding: 32px 20px;
}
.session-complete-box {
  text-align: center;
  max-width: 380px;
}
.session-complete-title {
  font-size: 32px;
  color: #FFFFFF;
  margin-bottom: 12px;
  display: flex;
  align-items: baseline;
  justify-content: center;
  gap: 8px;
  flex-wrap: wrap;
}
.session-complete-msg {
  font-size: 16px;
  color: rgba(255,255,255,0.6);
  margin-bottom: 32px;
  font-family: 'Archivo', sans-serif;
}
.session-complete-actions {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

/* =============================================
   STUDENT PREFERENCES SCREEN
   ============================================= */
#screen-prefs {
  background: #000000;
}
.prefs-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 16px 16px 12px;
  flex-shrink: 0;
}
.prefs-title {
  font-size: 22px;
  color: #FFFFFF;
  display: flex;
  align-items: baseline;
  gap: 6px;
}
.prefs-content {
  flex: 1;
  padding: 0 16px 20px;
  max-width: 600px;
  margin: 0 auto;
  width: 100%;
  display: flex;
  flex-direction: column;
  gap: 14px;
}

/* Dark panels */
.panel {
  background: #1a1a1a;
  border: 1px solid rgba(255,255,255,0.1);
  border-radius: 16px;
  padding: 18px;
}
.panel-title {
  font-family: 'Times New Roman', Times, serif;
  font-style: italic;
  font-weight: 700;
  font-size: 17px;
  color: #FFFFFF;
  margin-bottom: 14px;
}

/* Session limit controls */
.session-limits {
  display: flex;
  gap: 14px;
}
.limit-ctrl { flex: 1; }
.limit-label {
  font-family: 'Archivo', sans-serif;
  font-weight: 700;
  font-size: 13px;
  color: #FFFFFF;
  margin-bottom: 8px;
}
.limit-input-row {
  display: flex;
  align-items: center;
  gap: 8px;
}
.limit-input {
  width: 64px;
  padding: 8px;
  border-radius: 8px;
  border: none;
  background: #FFFFFF;
  color: #222;
  font-size: 16px;
  font-weight: 700;
  text-align: center;
  font-family: 'Archivo', sans-serif;
}
.limit-suffix {
  font-size: 12px;
  color: rgba(255,255,255,0.4);
  font-family: 'Archivo', sans-serif;
}
.limit-hint {
  font-size: 11px;
  color: rgba(255,255,255,0.35);
  margin-top: 5px;
  font-family: 'Archivo', sans-serif;
}

/* Verb selection panel */
.sort-toggle {
  display: flex;
  gap: 8px;
  margin-bottom: 10px;
}
.sort-btn {
  background: transparent;
  border: 1px solid rgba(255,255,255,0.25);
  color: rgba(255,255,255,0.6);
  border-radius: 6px;
  padding: 7px 14px;
  font-family: 'Archivo', sans-serif;
  font-weight: 700;
  font-size: 12px;
  cursor: pointer;
  transition: all 0.2s;
}
.sort-btn.active {
  background: #000000;
  border-color: #000;
  color: #FFFFFF;
}

.verb-search {
  width: 100%;
  padding: 10px 13px;
  border-radius: 8px;
  border: 1px solid rgba(255,255,255,0.15);
  background: rgba(255,255,255,0.06);
  color: #FFFFFF;
  font-size: 14px;
  font-family: 'Archivo', sans-serif;
  margin-bottom: 10px;
}
.verb-search::placeholder { color: rgba(255,255,255,0.3); }
.verb-search:focus { outline: none; border-color: rgba(255,255,255,0.4); }

.bulk-btns {
  display: flex;
  gap: 8px;
  margin-bottom: 10px;
}

.verb-list-scroll {
  max-height: 300px;
  overflow-y: auto;
}

.type-group-header {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 8px 0 4px;
  border-bottom: 1px solid rgba(255,255,255,0.08);
  margin-bottom: 4px;
}
.type-badge-small {
  width: 22px;
  height: 22px;
  border-radius: 5px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 11px;
  font-weight: 800;
  font-family: 'Archivo', sans-serif;
  flex-shrink: 0;
}
.type-group-name {
  font-size: 12px;
  color: rgba(255,255,255,0.5);
  font-family: 'Archivo', sans-serif;
  font-weight: 600;
}

.verb-item {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 9px 4px;
  border-bottom: 1px solid rgba(255,255,255,0.06);
  cursor: pointer;
}
.verb-item input[type="checkbox"] {
  width: 17px;
  height: 17px;
  flex-shrink: 0;
  cursor: pointer;
}
.verb-item-locked {
  cursor: default;
  opacity: 0.7;
}
.verb-item-locked input[type="checkbox"] {
  cursor: not-allowed;
}
.verb-item-en {
  color: #FFFFFF;
  font-size: 14px;
  font-family: 'Archivo', sans-serif;
  font-weight: 600;
  flex: 1;
}
.verb-item-es {
  font-family: 'Times New Roman', Times, serif;
  font-style: italic;
  font-weight: 700;
  font-size: 13px;
  color: rgba(255,255,255,0.45);
}

/* =============================================
   MY SESSION BUILDER
   ============================================= */
#screen-focus-builder { background: #000; overflow-y: auto; }
#focus-verb-input {
  width: 100%;
  box-sizing: border-box;
  background: rgba(255,255,255,0.06);
  color: #fff;
  border: 1px solid rgba(255,255,255,0.15);
  border-radius: 8px;
  padding: 10px;
  font-size: 14px;
  font-family: 'Montserrat', sans-serif;
  resize: vertical;
  margin-top: 10px;
}
#focus-verb-feedback {
  margin-top: 8px;
  font-size: 12px;
  font-family: 'Montserrat', sans-serif;
  line-height: 1.5;
}
.focus-feedback-ok { color: #4caf50; }
.focus-feedback-err { color: rgba(255,255,255,0.4); }
#focus-save-error {
  color: #CC0000;
  font-size: 12px;
  margin-top: 6px;
  min-height: 16px;
  font-family: 'Montserrat', sans-serif;
}
.focus-name-row { display: flex; gap: 8px; align-items: center; }
.focus-empty {
  font-size: 13px;
  color: rgba(255,255,255,0.3);
  font-family: 'Montserrat', sans-serif;
  padding: 8px 0;
}
.focus-session-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 10px 8px;
  border-bottom: 1px solid rgba(255,255,255,0.06);
  border-radius: 6px;
  cursor: pointer;
  gap: 8px;
}
.focus-session-row:last-child { border-bottom: none; }
.focus-session-row:hover { background: rgba(255,255,255,0.05); }
.focus-session-row.active {
  background: rgba(58,171,220,0.12);
  border: 1px solid rgba(58,171,220,0.35);
}
.focus-session-info { flex: 1; min-width: 0; }
.focus-session-name-text {
  display: block;
  font-family: 'Archivo', sans-serif;
  font-weight: 600;
  font-size: 14px;
  color: #fff;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.focus-session-meta {
  display: block;
  font-family: 'Montserrat', sans-serif;
  font-size: 11px;
  color: rgba(255,255,255,0.4);
  margin-top: 2px;
}
.focus-session-btns { display: flex; gap: 4px; flex-shrink: 0; }
.btn-sm { padding: 4px 8px; font-size: 12px; }

/* =============================================
   TEACHER DASHBOARD
   ============================================= */
#screen-dashboard { background: #000000; overflow-y: auto; }

.dash-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 16px 16px 14px;
  position: sticky;
  top: 0;
  background: #000;
  z-index: 20;
  border-bottom: 1px solid rgba(255,255,255,0.06);
  flex-shrink: 0;
}
.dash-title { display: flex; align-items: baseline; gap: 4px; }
.dash-title-1 {
  font-family: 'Archivo', sans-serif;
  font-weight: 800;
  font-size: clamp(18px, 4vw, 26px);
  color: #FFFFFF;
  line-height: 1;
}
.dash-title-2 {
  font-family: 'Times New Roman', Times, serif;
  font-style: italic;
  font-weight: 700;
  font-size: clamp(20px, 4.3vw, 28px); /* slightly larger: Times NR italic is optically smaller */
  color: #FFFFFF;
  line-height: 1;
}
.dash-actions { display: flex; gap: 6px; flex-wrap: wrap; }

/* Scrollable body */
.dash-scroll {
  padding: 16px;
  display: flex;
  flex-direction: column;
  gap: 24px;
  max-width: 1100px;
  margin: 0 auto;
  width: 100%;
}

/* Section */
.dash-section { display: flex; flex-direction: column; gap: 12px; }
.dash-section-header {
  display: flex;
  align-items: center;
  gap: 10px;
}
.dash-section-title {
  font-family: 'Archivo', sans-serif;
  font-weight: 800;
  font-size: 16px;
  color: #FFFFFF;
}
.dash-count-badge {
  background: rgba(255,255,255,0.1);
  color: rgba(255,255,255,0.5);
  border-radius: 50px;
  padding: 2px 10px;
  font-size: 12px;
  font-weight: 700;
  font-family: 'Archivo', sans-serif;
}

/* Students table */
.table-scroll-wrapper {
  overflow-x: auto;
  border-radius: 14px;
  border: 1px solid rgba(255,255,255,0.08);
}
.students-table {
  width: 100%;
  border-collapse: collapse;
  min-width: 700px;
}
.students-table thead {
  background: #111;
}
.students-table th {
  text-align: left;
  font-size: 10px;
  color: rgba(255,255,255,0.35);
  text-transform: uppercase;
  letter-spacing: 0.8px;
  font-weight: 700;
  font-family: 'Archivo', sans-serif;
  padding: 11px 14px;
  white-space: nowrap;
}
.students-table td {
  padding: 13px 14px;
  border-top: 1px solid rgba(255,255,255,0.07);
  font-size: 14px;
  color: #FFFFFF;
  vertical-align: middle;
}
.students-table tbody tr.student-row:hover td {
  background: rgba(255,255,255,0.02);
}
.student-blocked td {
  opacity: 0.55;
}
.col-muted {
  color: rgba(255,255,255,0.45) !important;
  font-size: 13px;
}
.hard-verb-col { font-style: italic; }

/* Name cell */
.student-name-cell {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}
.student-name {
  font-weight: 700;
  color: #FFFFFF;
}
.class-code-pill {
  background: #3AABDC;
  color: #FFFFFF;
  border-radius: 50px;
  padding: 2px 9px;
  font-size: 11px;
  font-weight: 700;
  font-family: 'Archivo', sans-serif;
  white-space: nowrap;
}

/* Progress pill */
.progress-pill {
  border-radius: 50px;
  padding: 3px 10px;
  font-size: 12px;
  font-weight: 700;
  font-family: 'Archivo', sans-serif;
  white-space: nowrap;
}

/* Action buttons */
.action-btns {
  display: flex;
  gap: 5px;
  flex-wrap: nowrap;
  align-items: center;
}
.btn-xs {
  padding: 6px 10px;
  font-size: 12px;
  border-radius: 6px;
}
.btn-settings-open {
  background: rgba(255,255,255,0.15) !important;
}

/* Settings expand row */
.settings-expand-row { display: none; }
.settings-expand-row.settings-open { display: table-row; }
.settings-expand-row td {
  padding: 0 !important;
  border-top: none !important;
}

.settings-panel {
  background: #111;
  border-top: 1px solid rgba(255,255,255,0.07);
  padding: 14px 16px;
  display: flex;
  gap: 20px;
  flex-wrap: wrap;
}
.sett-field {
  display: flex;
  flex-direction: column;
  gap: 6px;
  min-width: 160px;
}
.sett-label {
  font-size: 10px;
  color: rgba(255,255,255,0.35);
  text-transform: uppercase;
  letter-spacing: 0.8px;
  font-weight: 700;
  font-family: 'Archivo', sans-serif;
}
.sett-select {
  background: #1a1a1a;
  border: 1px solid rgba(255,255,255,0.15);
  color: #FFFFFF;
  border-radius: 6px;
  padding: 7px 10px;
  font-family: 'Archivo', sans-serif;
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
}
.sett-toggle-group {
  display: flex;
  gap: 0;
  border-radius: 6px;
  overflow: hidden;
  border: 1px solid rgba(255,255,255,0.15);
}
.sett-toggle-btn {
  flex: 1;
  background: transparent;
  border: none;
  color: rgba(255,255,255,0.4);
  font-family: 'Archivo', sans-serif;
  font-weight: 700;
  font-size: 12px;
  padding: 7px 10px;
  cursor: pointer;
  transition: all 0.15s;
  white-space: nowrap;
}
.sett-toggle-btn.active {
  background: #FFFFFF;
  color: #000000;
}

/* ─── ACTIVE CLASSES ─── */
.classes-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 12px;
}
.class-card {
  display: flex;
  flex-direction: column;
  gap: 12px;
}
.class-card-top {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 10px;
}
.class-card-name {
  font-weight: 700;
  font-size: 15px;
  color: #FFFFFF;
  font-family: 'Archivo', sans-serif;
  line-height: 1.3;
}
.class-card-meta {
  display: flex;
  align-items: center;
  gap: 6px;
  margin-top: 4px;
}
.class-status-dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  flex-shrink: 0;
}
.class-meta-text {
  font-size: 12px;
  color: rgba(255,255,255,0.4);
  font-family: 'Archivo', sans-serif;
}
.class-code-pill.class-code-lg {
  font-size: 13px;
  padding: 4px 12px;
  white-space: nowrap;
  flex-shrink: 0;
}
.class-card-stats {
  display: flex;
  gap: 16px;
}
.class-stat {
  font-size: 13px;
  color: rgba(255,255,255,0.5);
  font-family: 'Archivo', sans-serif;
}
.class-stat strong { color: #FFFFFF; }
.class-card-actions { display: flex; gap: 8px; flex-wrap: wrap; }

/* ─── HARD VERBS ─── */
.hard-verbs-row {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}
.hard-verb-chip {
  display: flex;
  align-items: center;
  gap: 8px;
  border-radius: 8px;
  padding: 8px 12px;
  font-family: 'Archivo', sans-serif;
}
.hvc-bare {
  font-weight: 800;
  font-size: 14px;
}
.hvc-count {
  font-size: 11px;
  font-weight: 700;
  background: rgba(0,0,0,0.2);
  border-radius: 50px;
  padding: 1px 7px;
}

/* ─── MODALS ─── */
.modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.75);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 100;
  padding: 16px;
}
.modal-overlay.hidden { display: none; }
#modal-edit-name { z-index: 200; }

.modal-box {
  background: #111;
  border: 1px solid rgba(255,255,255,0.12);
  border-radius: 18px;
  width: 100%;
  max-width: 600px;
  max-height: 85vh;
  display: flex;
  flex-direction: column;
  overflow: hidden;
}
.modal-box.modal-sm { max-width: 380px; }

.modal-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 16px 20px;
  border-bottom: 1px solid rgba(255,255,255,0.08);
  flex-shrink: 0;
}
.modal-title {
  font-family: 'Archivo', sans-serif;
  font-weight: 800;
  font-size: 17px;
  color: #FFFFFF;
}
.modal-close-btn {
  padding: 6px 10px;
  font-size: 13px;
  border-radius: 6px;
}

.modal-body {
  flex: 1;
  overflow-y: auto;
  padding: 16px 20px;
}
.modal-footer {
  display: flex;
  gap: 8px;
  padding: 14px 20px;
  border-top: 1px solid rgba(255,255,255,0.08);
  flex-shrink: 0;
}

/* Verb assignment rows inside modal */
.verb-group { margin-bottom: 16px; }
.verb-group-header {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 6px 0;
  border-bottom: 1px solid rgba(255,255,255,0.08);
  margin-bottom: 4px;
}
.verb-group-badge {
  width: 22px;
  height: 22px;
  border-radius: 5px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 11px;
  font-weight: 800;
  font-family: 'Archivo', sans-serif;
  flex-shrink: 0;
}
.verb-group-name {
  font-size: 12px;
  color: rgba(255,255,255,0.4);
  font-family: 'Archivo', sans-serif;
}
.verb-assign-row {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 8px 4px;
  border-bottom: 1px solid rgba(255,255,255,0.05);
}
.verb-assign-row:last-child { border-bottom: none; }
.verb-row-class { background: rgba(255,255,255,0.02); }
.verb-lock {
  font-size: 13px;
  width: 17px;
  text-align: center;
  flex-shrink: 0;
  opacity: 0.6;
}
.verb-cb { width: 17px; height: 17px; cursor: pointer; flex-shrink: 0; }
.verb-type-dot {
  width: 22px;
  height: 22px;
  border-radius: 5px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 11px;
  font-weight: 800;
  font-family: 'Archivo', sans-serif;
  flex-shrink: 0;
}
.verb-assign-en {
  flex: 1;
  font-size: 14px;
  color: #FFFFFF;
  font-family: 'Archivo', sans-serif;
  font-weight: 600;
}
.verb-assign-es {
  font-family: 'Times New Roman', Times, serif;
  font-style: italic;
  font-size: 13px;
  color: rgba(255,255,255,0.4);
  min-width: 80px;
  text-align: right;
}
.completeness-dot {
  width: 9px;
  height: 9px;
  border-radius: 50%;
  flex-shrink: 0;
}
.completeness-green  { background: #4CB84A; }
.completeness-amber  { background: #F5A623; }
.completeness-red    { background: #CC0000; }

/* Form group inside dark modal */
.form-group-dark { display: flex; flex-direction: column; gap: 8px; }
.form-group-dark label {
  font-size: 11px;
  color: rgba(255,255,255,0.4);
  text-transform: uppercase;
  letter-spacing: 0.6px;
  font-weight: 700;
  font-family: 'Archivo', sans-serif;
}
.form-group-dark input {
  background: #1a1a1a;
  border: 1px solid rgba(255,255,255,0.15);
  color: #FFFFFF;
  border-radius: 8px;
  padding: 12px 14px;
  font-family: 'Archivo', sans-serif;
  font-size: 15px;
  font-weight: 600;
}
.form-group-dark input:focus { outline: none; border-color: rgba(255,255,255,0.4); }

/* New class code display */
.new-class-code-display {
  font-family: 'Archivo', sans-serif;
  font-weight: 800;
  font-size: 32px;
  letter-spacing: 4px;
  color: #FFFFFF;
  background: #000;
  border: 2px solid rgba(255,255,255,0.15);
  border-radius: 10px;
  padding: 16px;
  text-align: center;
  margin-top: 8px;
}

/* Delete confirm message */
#delete-confirm-msg {
  font-family: 'Archivo', sans-serif;
  font-size: 14px;
  color: rgba(255,255,255,0.75);
  line-height: 1.6;
}

/* =============================================
   INFORMATION PAGE
   ============================================= */
#screen-info { background: #000000; }

.info-hero {
  background: #E8365A;
  padding: 32px 20px 28px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 12px;
  position: relative;
}
.info-hero-logo {
  display: flex;
  align-items: baseline;
  justify-content: center;
  flex-wrap: wrap;
  gap: 0;
  font-size: clamp(20px, 4.5vw, 36px);
  line-height: 1;
}
.ihl-main {
  font-family: 'Arial Black', sans-serif;
  font-weight: 900;
  color: #000000;
  letter-spacing: -0.5px;
}
.ihl-be {
  font-family: 'Times New Roman', Times, serif;
  font-style: italic;
  font-weight: 700;
  color: #F5E027;
  font-size: 1.08em;
  margin-left: 0.5em;  /* 2S — twice the word-space */
}
.ihl-bilingual {
  font-family: 'Archivo', sans-serif;
  font-weight: 800;
  color: #F5E027;
  margin-left: 0.25em;  /* S — matches the word-space inside "ENGLISH unplugged" */
}
.info-back-btn {
  position: absolute;
  top: 16px;
  right: 16px;
}

.info-content {
  flex: 1;
  padding: 32px 20px;
  max-width: 700px;
  margin: 0 auto;
  width: 100%;
}
.info-section { margin-bottom: 36px; }
.info-section-heading {
  font-family: 'Archivo', sans-serif;
  font-weight: 800;
  font-size: 20px;
  color: #E8365A;
  margin-bottom: 12px;
  display: flex;
  align-items: baseline;
  gap: 6px;
}
.info-section-heading .ish-en { font-family: 'Archivo', sans-serif; font-weight: 800; color: #F5E027; line-height: 1; }
.info-section-heading .ish-es { font-family: 'Times New Roman', Times, serif; font-style: italic; color: #E8365A; font-size: 1.07em; line-height: 1; }
.info-sub-heading {
  font-family: 'Archivo', sans-serif;
  font-weight: 700;
  font-size: 16px;
  color: #FFFFFF;
  margin: 18px 0 8px;
}
.info-body {
  font-size: 15px;
  color: rgba(255,255,255,0.75);
  line-height: 1.7;
  font-family: 'Archivo', sans-serif;
}
.info-body p { margin-bottom: 12px; }
.info-contact-link {
  display: inline-block;
  color: #F5E027;
  text-decoration: underline;
  font-weight: 700;
  font-family: 'Archivo', sans-serif;
  font-size: 15px;
}
.info-footer {
  padding: 16px 20px;
  text-align: center;
}
.privacy-link {
  color: rgba(255,255,255,0.3);
  font-size: 12px;
  text-decoration: none;
  font-family: 'Archivo', sans-serif;
}
.privacy-link:hover { color: rgba(255,255,255,0.6); }

/* =============================================
   CONTENT EDITOR (Master Teacher only)
   ============================================= */
#screen-content-editor {
  background: #000000;
  overflow-y: auto;
}

.editor-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 16px 16px 14px;
  position: sticky;
  top: 0;
  background: #000;
  z-index: 20;
  border-bottom: 1px solid rgba(255,255,255,0.06);
  flex-shrink: 0;
}

.editor-scroll {
  padding: 16px;
  display: flex;
  flex-direction: column;
  gap: 24px;
  max-width: 1100px;
  margin: 0 auto;
  width: 100%;
}

.editor-section {
  display: flex;
  flex-direction: column;
  gap: 12px;
}
#editor-form-area {
  border: 2px solid rgba(255,255,255,0.25);
  border-radius: 12px;
  padding: 20px;
}

/* ─── TYPES KEY GRID ─── */
.types-key-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 10px;
}

@media (max-width: 500px) {
  .types-key-grid { grid-template-columns: repeat(2, 1fr); }
}

/* type-key-card reuses .panel for dark bg */
.type-key-top {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 4px;
}

.type-key-badge {
  width: 24px;
  height: 24px;
  border-radius: 5px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 12px;
  font-weight: 800;
  font-family: 'Archivo', sans-serif;
  flex-shrink: 0;
}

.type-key-name {
  font-family: 'Archivo', sans-serif;
  font-weight: 700;
  font-size: 12px;
  color: rgba(255,255,255,0.65);
}

.type-key-desc {
  font-family: 'Times New Roman', Times, serif;
  font-style: italic;
  font-size: 12px;
  color: rgba(255,255,255,0.5);
  margin-bottom: 4px;
}

.type-key-example {
  font-family: 'Archivo', sans-serif;
  font-weight: 600;
  font-size: 11px;
  color: rgba(255,255,255,0.35);
}

/* ─── EDITOR FORM (rendered by renderForm()) ─── */
.editor-form-header { margin-bottom: 14px; }

.editor-form-title {
  font-size: 22px;
  color: #FFFFFF;
  line-height: 1.2;
}

.editor-form-cols {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 20px;
}

@media (max-width: 680px) {
  .editor-form-cols { grid-template-columns: 1fr; }
}

.editor-form-col {
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.ef-field {
  display: flex;
  flex-direction: column;
  gap: 5px;
}

.ef-label {
  font-size: 10px;
  color: rgba(255,255,255,0.35);
  text-transform: uppercase;
  letter-spacing: 0.8px;
  font-weight: 700;
  font-family: 'Archivo', sans-serif;
}

.req-star { color: #E8365A; }

.ef-input {
  background: #1a1a1a;
  border: 1px solid rgba(255,255,255,0.15);
  color: #FFFFFF;
  border-radius: 8px;
  padding: 11px 13px;
  font-family: 'Archivo', sans-serif;
  font-size: 14px;
  font-weight: 600;
}

.ef-input:focus { outline: none; border-color: rgba(255,255,255,0.4); }
.ef-input-sm { padding: 7px 10px; font-size: 13px; }

.ef-select {
  background: #1a1a1a;
  border: 1px solid rgba(255,255,255,0.15);
  color: #FFFFFF;
  border-radius: 8px;
  padding: 11px 13px;
  font-family: 'Archivo', sans-serif;
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
  width: 100%;
}
.ef-select:focus { outline: none; border-color: rgba(255,255,255,0.4); }

.ef-error {
  font-family: 'Archivo', sans-serif;
  font-size: 11px;
  color: #E8365A;
}

.irr-check-label {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  cursor: pointer;
  margin-top: 2px;
}
.irr-check-text {
  font-family: 'Times New Roman', Times, serif;
  font-style: italic;
  font-weight: 700;
  font-size: 12px;
  color: rgba(255,255,255,0.55);
}

.ef-actions {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  margin-top: 16px;
  padding-top: 14px;
  border-top: 1px solid rgba(255,255,255,0.07);
}
.ef-actions .btn {
  background: #FFFFFF;
  color: #000000;
  border: 2px solid #000000;
}

/* Type preview box */
.type-preview-box {
  border-radius: 10px;
  padding: 10px 14px;
  min-height: 52px;
  display: flex;
  flex-direction: column;
  gap: 4px;
  transition: background 0.2s;
}

.tp-top {
  display: flex;
  align-items: center;
  gap: 8px;
}

.tp-name {
  font-family: 'Archivo', sans-serif;
  font-weight: 700;
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.tp-desc {
  font-family: 'Times New Roman', Times, serif;
  font-style: italic;
  font-size: 12px;
  opacity: 0.75;
}

.tp-example {
  font-family: 'Archivo', sans-serif;
  font-weight: 600;
  font-size: 11px;
  opacity: 0.55;
  margin-top: 2px;
}

/* Media type toggle */
.media-type-toggle {
  display: flex;
  border-radius: 6px;
  overflow: hidden;
  border: 1px solid rgba(255,255,255,0.15);
}

.media-type-toggle .sett-toggle-btn { flex: 1; }

.media-browse-row {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-top: 6px;
}

.media-preview-area { margin-top: 8px; }

.media-preview-thumb {
  max-width: 100%;
  max-height: 150px;
  border-radius: 8px;
  object-fit: cover;
}

/* Audio rows */
.audio-row {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 6px 0;
  border-bottom: 1px solid rgba(255,255,255,0.06);
}

.audio-row:last-child { border-bottom: none; }

.audio-filename {
  flex: 1;
  font-size: 12px;
  color: rgba(255,255,255,0.4);
  font-family: 'Archivo', sans-serif;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

/* ─── VERBS TABLE ─── */
.editor-table-controls {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}

.editor-sort-btn.active {
  background: #FFFFFF !important;
  color: #000000 !important;
}

.bulk-cb {
  width: 16px;
  height: 16px;
  cursor: pointer;
}

.verb-table-thumb {
  width: 36px;
  height: 28px;
  border-radius: 4px;
  object-fit: cover;
}

/* ─── BULK UPLOAD MODAL ─── */
.bulk-upload-info {
  font-family: 'Archivo', sans-serif;
  font-size: 12px;
  color: rgba(255,255,255,0.5);
  line-height: 1.6;
}

.bulk-upload-info code {
  background: rgba(255,255,255,0.08);
  border-radius: 4px;
  padding: 1px 5px;
  font-size: 11px;
}

/* ─── PREVIEW MODAL ─── */
.modal-preview { max-width: 480px; }

.preview-tab-switcher {
  display: flex;
  border-radius: 8px;
  overflow: hidden;
  border: 1px solid rgba(255,255,255,0.15);
  margin-bottom: 16px;
  width: fit-content;
}

.preview-tab-btn {
  background: transparent;
  border: none;
  color: rgba(255,255,255,0.45);
  font-family: 'Archivo', sans-serif;
  font-weight: 700;
  font-size: 13px;
  padding: 9px 20px;
  cursor: pointer;
  transition: all 0.15s;
}

.preview-tab-btn.active {
  background: #FFFFFF;
  color: #000000;
}

.preview-modal-body {
  display: flex;
  flex-direction: column;
  align-items: stretch;
}

.preview-card-wrap {
  display: flex;
  justify-content: center;
}

.preview-card-wrap .verb-card {
  width: 100%;
  max-width: 380px;
  border-radius: 18px;
}

/* =============================================
   CODE GENERATOR
   ============================================= */

.code-gen-panel { display: flex; flex-direction: column; gap: 16px; }

.code-gen-row {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
}

.code-type-selector { width: fit-content; }
.code-type-selector .sett-toggle-btn { flex: 0 0 auto; padding: 8px 20px; }

.code-gen-label-input { flex: 1; min-width: 180px; margin: 0; }

.code-gen-expires-wrap {
  display: flex;
  align-items: center;
  gap: 8px;
}

.code-gen-date { width: 150px; margin: 0; }

.code-gen-result {
  display: flex;
  align-items: center;
  gap: 16px;
  background: rgba(255, 255, 255, 0.05);
  border-radius: 10px;
  padding: 12px 18px;
  border: 1px solid rgba(255, 255, 255, 0.1);
}

.code-result-display {
  flex: 1;
  font-family: 'Archivo', sans-serif;
  font-weight: 800;
  font-size: 26px;
  letter-spacing: 5px;
  color: #F5E027;
}

.code-type-badge {
  display: inline-block;
  font-family: 'Archivo', sans-serif;
  font-weight: 800;
  font-size: 10px;
  padding: 2px 8px;
  border-radius: 4px;
  letter-spacing: 0.5px;
  text-transform: uppercase;
  white-space: nowrap;
}

.code-filter-tabs { display: flex; gap: 6px; flex-wrap: wrap; }

.code-cell-mono {
  font-family: 'Courier New', Courier, monospace;
  font-weight: 700;
  font-size: 13px;
  letter-spacing: 1.5px;
  color: #F5E027;
}

/* =============================================
   RESPONSIVE
   ============================================= */
@media (max-width: 400px) {
  .session-limits { flex-direction: column; }
  .rating-btn { font-size: 11px; padding: 11px 3px; }
  .score-n { font-size: 60px; }
  .score-denom { font-size: 28px; }
  .tab-btn { font-size: 12px; padding: 9px 6px; }
}

@media (min-width: 700px) {
  .verb-card { max-width: 460px; }
  .login-body { max-width: 440px; }
}
