/* Labas Hello — labashello.lt
   Palette accents from the Lithuanian flag: yellow, green, red. */

:root {
  --yellow: #fdb913;
  --green: #00833e;
  --red: #c1272d;
  --green-700: #006a44;

  --bg: #f7f8fa;
  --surface: #ffffff;
  --surface-2: #f0f2f5;
  --border: #e3e7ee;
  --text: #1c2330;
  --muted: #5b6677;
  --primary: var(--green);
  --primary-ink: #ffffff;
  --ring: rgba(0, 131, 62, 0.25);

  --ok-bg: #e7f6ec;
  --ok-ink: #11703a;
  --no-bg: #fdecec;
  --no-ink: #b22025;

  --radius: 14px;
  --radius-sm: 9px;
  --shadow: 0 1px 2px rgba(20, 30, 50, 0.05), 0 8px 24px rgba(20, 30, 50, 0.06);
  --shadow-sm: 0 1px 2px rgba(20, 30, 50, 0.06);
  --maxw: 1080px;
  --font: "Inter", system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
}

@media (prefers-color-scheme: dark) {
  :root {
    --bg: #0e1117;
    --surface: #161b24;
    --surface-2: #1d2430;
    --border: #2a323f;
    --text: #e8edf5;
    --muted: #9aa6b6;
    --primary: #18a657;
    --ring: rgba(24, 166, 87, 0.3);
    --ok-bg: #14321f;
    --ok-ink: #6ee7a0;
    --no-bg: #3a1b1d;
    --no-ink: #ff9aa0;
    --shadow: 0 1px 2px rgba(0, 0, 0, 0.3), 0 8px 24px rgba(0, 0, 0, 0.35);
  }
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  font-family: var(--font);
  color: var(--text);
  background: var(--bg);
  line-height: 1.55;
  font-size: 16px;
  -webkit-font-smoothing: antialiased;
}
a { color: var(--primary); text-decoration: none; }
a:hover { text-decoration: underline; }
h1, h2, h3, h4 { line-height: 1.2; margin: 0 0 0.5em; font-weight: 700; letter-spacing: -0.01em; }
h1 { font-size: 1.95rem; }
h2 { font-size: 1.4rem; }
h3 { font-size: 1.1rem; }
p { margin: 0 0 0.8em; }
.muted { color: var(--muted); }
.lead { font-size: 1.12rem; color: var(--muted); }
.narrow { max-width: 680px; }
.lt { font-weight: 600; }

/* ---------- layout ---------- */
.site-header {
  position: sticky; top: 0; z-index: 50;
  background: color-mix(in srgb, var(--surface) 88%, transparent);
  backdrop-filter: saturate(1.4) blur(10px);
  border-bottom: 1px solid var(--border);
}
.header-inner {
  max-width: var(--maxw); margin: 0 auto; padding: 0.6rem 1.1rem;
  display: flex; align-items: center; gap: 1.2rem;
}
.brand { display: inline-flex; align-items: baseline; font-weight: 800; font-size: 1.25rem; letter-spacing: -0.02em; }
.brand:hover { text-decoration: none; }
.brand-labas { color: var(--green); }
.brand-hello { color: var(--red); }
.brand-dot { color: var(--muted); font-weight: 600; font-size: 0.9rem; margin-left: 1px; }
.main-nav { display: flex; gap: 0.3rem; margin-right: auto; }
.nav-link { padding: 0.4rem 0.7rem; border-radius: 999px; color: var(--text); font-weight: 500; font-size: 0.95rem; }
.nav-link:hover { background: var(--surface-2); text-decoration: none; }
.nav-link.is-active { background: var(--surface-2); color: var(--primary); }
.header-right { display: flex; align-items: center; gap: 0.7rem; }
.lang-toggle { display: inline-flex; background: var(--surface-2); border-radius: 999px; padding: 2px; }
.lang-btn { border: 0; background: transparent; color: var(--muted); font-weight: 700; font-size: 0.78rem; padding: 0.25rem 0.55rem; border-radius: 999px; cursor: pointer; }
.lang-btn.is-active { background: var(--surface); color: var(--text); box-shadow: var(--shadow-sm); }
.auth-area { display: flex; align-items: center; gap: 0.5rem; }
.user-chip { display: inline-flex; align-items: center; gap: 0.45rem; padding: 0.2rem 0.55rem 0.2rem 0.2rem; border-radius: 999px; background: var(--surface-2); color: var(--text); font-weight: 600; font-size: 0.9rem; }
.user-chip:hover { text-decoration: none; }
.user-avatar { width: 26px; height: 26px; border-radius: 50%; background: var(--green); color: #fff; display: grid; place-items: center; font-size: 0.8rem; font-weight: 800; }

main { max-width: var(--maxw); margin: 0 auto; padding: 1.6rem 1.1rem 4rem; }
.view { animation: fade 0.25s ease; }
@keyframes fade { from { opacity: 0; transform: translateY(4px); } to { opacity: 1; transform: none; } }
.section { margin-top: 2.4rem; }
.section-h { margin: 2rem 0 0.9rem; }
.page-head { margin-bottom: 1.4rem; }
.crumbs { display: flex; gap: 0.4rem; align-items: center; color: var(--muted); font-size: 0.88rem; margin-bottom: 1rem; flex-wrap: wrap; }
.crumbs span { color: var(--muted); }

/* ---------- buttons ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 0.4rem;
  border: 1px solid var(--border); background: var(--surface); color: var(--text);
  padding: 0.58rem 1.05rem; border-radius: 999px; font-weight: 600; font-size: 0.95rem;
  cursor: pointer; transition: transform 0.04s ease, box-shadow 0.15s ease, background 0.15s ease;
}
.btn:hover { box-shadow: var(--shadow-sm); text-decoration: none; }
.btn:active { transform: translateY(1px); }
.btn:disabled { opacity: 0.6; cursor: default; }
.btn-primary { background: var(--primary); color: var(--primary-ink); border-color: transparent; }
.btn-primary:hover { background: var(--green-700); }
.btn-ghost { background: transparent; }
.btn-lg { padding: 0.8rem 1.5rem; font-size: 1.05rem; }
.btn-sm { padding: 0.4rem 0.8rem; font-size: 0.88rem; }
.btn-block { width: 100%; }
.btn-ok { background: var(--ok-bg); color: var(--ok-ink); border-color: transparent; }
.btn.is-done { background: var(--ok-bg); color: var(--ok-ink); border-color: transparent; }
.pill { font-size: 0.72rem; font-weight: 700; padding: 0.12rem 0.5rem; border-radius: 999px; background: var(--surface-2); color: var(--muted); }
.pill-ok { background: var(--ok-bg); color: var(--ok-ink); }
.pill-progress { background: color-mix(in srgb, var(--yellow) 30%, transparent); color: #8a6400; }

/* ---------- hero ---------- */
.hero { text-align: center; padding: 2.4rem 1rem 1.2rem; position: relative; }
.hero-flag { width: 84px; height: 56px; margin: 0 auto 1.2rem; border-radius: 8px; overflow: hidden; box-shadow: var(--shadow);
  background: linear-gradient(var(--yellow) 0 33.3%, var(--green) 33.3% 66.6%, var(--red) 66.6% 100%); }
.hero-title { font-size: clamp(1.9rem, 4vw, 2.8rem); margin-bottom: 0.5rem; }
.hero-sub { max-width: 640px; margin: 0 auto 1.4rem; color: var(--muted); font-size: 1.1rem; }
.hero-cta { display: flex; gap: 0.7rem; justify-content: center; flex-wrap: wrap; }
.hero-stats { display: flex; gap: 2rem; justify-content: center; margin-top: 2rem; flex-wrap: wrap; }
.stat { display: flex; flex-direction: column; }
.stat strong { font-size: 1.6rem; color: var(--text); }
.stat span { font-size: 0.82rem; color: var(--muted); }

/* ---------- level cards ---------- */
.level-cards { display: grid; grid-template-columns: repeat(auto-fit, minmax(230px, 1fr)); gap: 1rem; }
.level-card { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); padding: 1.1rem; box-shadow: var(--shadow-sm); display: flex; flex-direction: column; gap: 0.5rem; transition: transform 0.1s ease, box-shadow 0.15s ease; color: var(--text); }
.level-card:hover { transform: translateY(-3px); box-shadow: var(--shadow); text-decoration: none; }
.level-card-top { display: flex; align-items: center; gap: 0.6rem; }
.level-card-name { font-weight: 700; }
.level-card-tag { color: var(--muted); font-size: 0.92rem; flex: 1; }
.level-card-foot { display: flex; align-items: center; gap: 0.5rem; flex-wrap: wrap; font-size: 0.82rem; color: var(--muted); }
.level-badge { font-weight: 800; font-size: 0.78rem; color: #fff; background: var(--muted); padding: 0.2rem 0.5rem; border-radius: 6px; letter-spacing: 0.02em; }
.lv-a1 { background: var(--green); }
.lv-a2 { background: #2e7d32; }
.lv-b1 { background: var(--yellow); color: #4a3500; }
.lv-b2 { background: var(--red); }
.bar-fill.lv-b1 { background: var(--yellow); }

/* ---------- features ---------- */
.features { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 1rem; }
.feature { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); padding: 1.2rem; }
.feature-icon { font-size: 1.6rem; }
.feature h3 { margin: 0.5rem 0 0.3rem; }
.feature p { color: var(--muted); font-size: 0.94rem; margin: 0; }

/* ---------- course / units ---------- */
.strands { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 0.8rem; }
.strand { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius-sm); padding: 0.9rem; position: relative; }
.strand h4 { margin: 0 0 0.2rem; }
.strand-range { font-size: 0.72rem; font-weight: 700; color: var(--green); }
.strand p { font-size: 0.86rem; color: var(--muted); margin: 0.3rem 0 0; }
.course-level { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); padding: 1.2rem; margin-bottom: 1.2rem; box-shadow: var(--shadow-sm); }
.course-level-head { display: flex; align-items: center; gap: 0.9rem; margin-bottom: 1rem; flex-wrap: wrap; }
.course-level-head h2 { margin: 0; }
.course-level-hours { margin-left: auto; text-align: right; }
.course-level-hours strong { display: block; font-size: 1.2rem; }
.course-level-hours span { font-size: 0.76rem; color: var(--muted); }
.unit-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 0.7rem; margin-bottom: 1rem; }
.unit-chip { display: grid; grid-template-columns: auto 1fr; grid-template-rows: auto auto; gap: 0.1rem 0.6rem; background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius-sm); padding: 0.7rem 0.8rem; color: var(--text); transition: transform 0.08s, box-shadow 0.15s; }
.unit-chip:hover { transform: translateY(-2px); box-shadow: var(--shadow); text-decoration: none; }
.unit-chip.is-locked { opacity: 0.62; }
.unit-chip-n { grid-row: 1 / 3; width: 30px; height: 30px; border-radius: 8px; background: var(--surface-2); display: grid; place-items: center; font-weight: 800; color: var(--muted); align-self: center; }
.unit-chip-title { font-weight: 600; font-size: 0.95rem; }
.unit-chip-meta { font-size: 0.78rem; color: var(--muted); }
.unit-chip-done { grid-column: 2; font-size: 0.75rem; color: var(--ok-ink); font-weight: 700; }
.unit-chip-soon { grid-column: 2; font-size: 0.72rem; color: var(--muted); }

/* ---------- level/unit info ---------- */
.level-hero { background: var(--surface); border: 1px solid var(--border); border-left: 5px solid var(--green); border-radius: var(--radius); padding: 1.4rem; margin-bottom: 1.2rem; box-shadow: var(--shadow-sm); }
.level-hero.lv-a2 { border-left-color: #2e7d32; }
.level-hero.lv-b1 { border-left-color: var(--yellow); }
.level-hero.lv-b2 { border-left-color: var(--red); }
.level-hero .level-badge { margin-bottom: 0.6rem; }
.level-cols { display: grid; grid-template-columns: 1fr 1fr; gap: 1rem; margin-bottom: 1rem; }
.info-block { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); padding: 1.1rem 1.2rem; }
.info-block h3 { margin-top: 0; }
.ticks, .dots { margin: 0; padding-left: 1.2rem; }
.ticks { list-style: none; padding-left: 0; }
.ticks li { padding-left: 1.6rem; position: relative; margin-bottom: 0.5rem; }
.ticks li::before { content: "✓"; position: absolute; left: 0; color: var(--green); font-weight: 800; }
.dots li { margin-bottom: 0.35rem; }
.notice { background: color-mix(in srgb, var(--yellow) 14%, var(--surface)); border: 1px solid color-mix(in srgb, var(--yellow) 40%, var(--border)); border-radius: var(--radius); padding: 1rem 1.2rem; display: flex; align-items: center; justify-content: space-between; gap: 1rem; flex-wrap: wrap; }
.unit-head { margin-bottom: 1.2rem; }
.unit-head h1 { margin: 0.4rem 0 0.3rem; }

/* ---------- lesson list ---------- */
.lesson-list { display: flex; flex-direction: column; gap: 0.5rem; }
.lesson-row { display: flex; align-items: center; gap: 0.9rem; background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius-sm); padding: 0.8rem 1rem; color: var(--text); }
.lesson-row:hover { box-shadow: var(--shadow); text-decoration: none; transform: translateX(2px); }
.lesson-row.is-done { border-color: color-mix(in srgb, var(--green) 40%, var(--border)); }
.lesson-row-n { width: 30px; height: 30px; border-radius: 50%; background: var(--surface-2); display: grid; place-items: center; font-weight: 800; color: var(--muted); flex: none; }
.lesson-row.is-done .lesson-row-n { background: var(--ok-bg); color: var(--ok-ink); }
.lesson-row-title { font-weight: 600; flex: 1; }
.lesson-row-min { font-size: 0.8rem; color: var(--muted); }

/* ---------- lesson content ---------- */
.lesson-title { margin-bottom: 1.2rem; }
.sec { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); padding: 1.2rem 1.3rem; margin-bottom: 1.1rem; box-shadow: var(--shadow-sm); }
.sec h3 { margin-top: 0; }
.prose p { margin: 0 0 0.7em; }
.prose code { background: var(--surface-2); padding: 0.05rem 0.35rem; border-radius: 5px; font-size: 0.9em; }
.vocab-list { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 0.5rem; }
.vocab-item { background: var(--surface-2); border-radius: var(--radius-sm); padding: 0.6rem 0.8rem; }
.vocab-main { display: flex; justify-content: space-between; gap: 0.6rem; align-items: baseline; }
.vocab-lt { font-weight: 700; color: var(--text); }
.vocab-gloss { color: var(--muted); font-size: 0.92rem; text-align: right; }
.vocab-ex { margin: 0.35rem 0 0; font-size: 0.84rem; color: var(--muted); }
.examples { margin-top: 0.8rem; padding-top: 0.6rem; border-top: 1px dashed var(--border); }
.examples h4 { margin: 0 0 0.4rem; font-size: 0.85rem; text-transform: uppercase; letter-spacing: 0.04em; color: var(--muted); }
.example { margin: 0 0 0.35rem; }
.ex-gloss { color: var(--muted); }
.dlg-line { display: grid; grid-template-columns: minmax(0, auto) 1fr; gap: 0.2rem 0.6rem; padding: 0.45rem 0; border-bottom: 1px solid var(--border); }
.dlg-line:last-child { border-bottom: 0; }
.dlg-sp { font-weight: 700; color: var(--green); }
.dlg-lt { font-weight: 600; }
.dlg-gloss { grid-column: 2; color: var(--muted); font-size: 0.9rem; }

/* ---------- tables ---------- */
.table-wrap { overflow-x: auto; }
.g-table { width: 100%; border-collapse: collapse; margin: 0.4rem 0 0.6rem; font-size: 0.94rem; }
.g-table caption { text-align: left; color: var(--muted); font-size: 0.85rem; margin-bottom: 0.4rem; }
.g-table th, .g-table td { border: 1px solid var(--border); padding: 0.45rem 0.7rem; text-align: left; }
.g-table thead th { background: var(--surface-2); font-size: 0.85rem; }
.g-table td:first-child { font-weight: 600; }

/* ---------- exercises ---------- */
.sec-exercise { border-left: 4px solid var(--yellow); }
.ex-head { margin-bottom: 0.8rem; }
.ex-kind { display: inline-block; font-size: 0.72rem; font-weight: 800; text-transform: uppercase; letter-spacing: 0.05em; color: #8a6400; background: color-mix(in srgb, var(--yellow) 22%, transparent); padding: 0.15rem 0.55rem; border-radius: 999px; }
.ex-instr { margin: 0.5rem 0 0; color: var(--muted); font-size: 0.92rem; }
.ex-instr-mini { color: var(--muted); font-size: 0.85rem; margin: 0 0 0.6rem; }
.ex-progress { font-size: 0.8rem; color: var(--muted); margin-bottom: 0.6rem; font-weight: 600; }
.ex-actions { display: flex; gap: 0.5rem; margin-top: 0.8rem; flex-wrap: wrap; }
.ex-feedback { margin-top: 0.7rem; }
.fb { font-weight: 700; padding: 0.5rem 0.8rem; border-radius: var(--radius-sm); display: inline-block; }
.fb-ok { background: var(--ok-bg); color: var(--ok-ink); }
.fb-no { background: var(--no-bg); color: var(--no-ink); }
.fb-explain { margin: 0.5rem 0 0; color: var(--muted); font-size: 0.9rem; }
.fb-translation { margin: 0.3rem 0 0; color: var(--muted); font-style: italic; font-size: 0.9rem; }
.ex-result { display: flex; align-items: center; gap: 1rem; margin-top: 0.6rem; flex-wrap: wrap; }
.ex-score { font-weight: 800; font-size: 1.05rem; }

/* flashcards */
.flashcard { perspective: 1000px; height: 150px; margin: 0.4rem 0; cursor: pointer; position: relative; }
.flash-face { position: absolute; inset: 0; border-radius: var(--radius); display: grid; place-items: center; padding: 1rem; text-align: center; backface-visibility: hidden; border: 1px solid var(--border); transition: transform 0.4s; }
.flash-front { background: var(--surface-2); transform: rotateY(0deg); }
.flash-back { background: var(--green); color: #fff; transform: rotateY(180deg); font-size: 1.2rem; }
.flashcard.is-flipped .flash-front { transform: rotateY(180deg); }
.flashcard.is-flipped .flash-back { transform: rotateY(360deg); }
.flash-front .lt { font-size: 1.6rem; font-weight: 800; }
.flash-hint { display: block; margin-top: 0.4rem; color: var(--muted); font-size: 0.85rem; font-weight: 400; }

/* mcq */
.mcq-q { margin-bottom: 0.8rem; }
.mcq-lt { font-size: 1.15rem; font-weight: 600; margin: 0; }
.mcq-gloss { color: var(--muted); font-size: 0.9rem; margin: 0.2rem 0 0; }
.mcq-opts { display: grid; gap: 0.5rem; }
.mcq-opt { text-align: left; padding: 0.65rem 0.9rem; border: 1px solid var(--border); background: var(--surface); border-radius: var(--radius-sm); font-size: 1rem; cursor: pointer; color: var(--text); font-weight: 500; }
.mcq-opt:hover:not(:disabled) { border-color: var(--primary); background: var(--surface-2); }
.mcq-opt.is-correct { background: var(--ok-bg); color: var(--ok-ink); border-color: transparent; font-weight: 700; }
.mcq-opt.is-wrong { background: var(--no-bg); color: var(--no-ink); border-color: transparent; }

/* fill + translate */
.fill-sentence { font-size: 1.15rem; display: flex; align-items: center; gap: 0.35rem; flex-wrap: wrap; line-height: 2.2; }
.fill-input { font: inherit; font-size: 1.05rem; padding: 0.35rem 0.6rem; border: 2px solid var(--border); border-radius: 8px; background: var(--surface); color: var(--text); min-width: 130px; }
.fill-input:focus { outline: none; border-color: var(--primary); box-shadow: 0 0 0 3px var(--ring); }
.fill-input.is-correct { border-color: var(--ok-ink); background: var(--ok-bg); }
.fill-input.is-wrong { border-color: var(--no-ink); background: var(--no-bg); }
.fill-hint { color: var(--muted); font-size: 0.88rem; margin: 0.4rem 0 0; }
.tr-prompt { font-size: 1.15rem; font-weight: 600; margin-bottom: 0.6rem; }
.ex-translate .fill-input { width: 100%; margin-top: 0.3rem; }

/* match */
.match-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 0.6rem; }
.match-col { display: flex; flex-direction: column; gap: 0.5rem; }
.match-item { padding: 0.6rem 0.7rem; border: 1px solid var(--border); border-radius: var(--radius-sm); background: var(--surface); cursor: pointer; font-size: 0.98rem; color: var(--text); font-weight: 500; text-align: center; }
.match-item:hover:not(:disabled) { border-color: var(--primary); }
.match-item.is-sel { border-color: var(--primary); background: var(--surface-2); box-shadow: 0 0 0 3px var(--ring); }
.match-item.is-matched { background: var(--ok-bg); color: var(--ok-ink); border-color: transparent; cursor: default; }
.match-item.is-wrong { background: var(--no-bg); color: var(--no-ink); border-color: transparent; }

/* ---------- lesson footer ---------- */
.lesson-footer { margin-top: 1.6rem; padding-top: 1.2rem; border-top: 1px solid var(--border); display: flex; flex-direction: column; gap: 1rem; }
.lesson-nav { display: flex; justify-content: space-between; gap: 0.6rem; }
.save-hint { background: var(--surface-2); border-radius: var(--radius-sm); padding: 0.6rem 0.9rem; font-size: 0.9rem; color: var(--muted); margin: 0; }

/* ---------- dashboard ---------- */
.stat-cards { display: grid; grid-template-columns: repeat(3, 1fr); gap: 0.8rem; margin-bottom: 1.5rem; }
.stat-card { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); padding: 1.1rem; text-align: center; box-shadow: var(--shadow-sm); }
.stat-card-icon { font-size: 1.5rem; }
.stat-card-value { font-size: 1.9rem; font-weight: 800; }
.stat-card-label { color: var(--muted); font-size: 0.82rem; }
.dash-levels { display: flex; flex-direction: column; gap: 0.7rem; }
.dash-level { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius-sm); padding: 0.9rem 1rem; color: var(--text); }
.dash-level:hover { text-decoration: none; box-shadow: var(--shadow); }
.dash-level-top { display: flex; align-items: center; gap: 0.6rem; margin-bottom: 0.5rem; }
.dash-level-count { margin-left: auto; font-size: 0.85rem; }
.bar { height: 8px; background: var(--surface-2); border-radius: 999px; overflow: hidden; }
.bar-fill { height: 100%; background: var(--green); border-radius: 999px; transition: width 0.4s ease; }

/* ---------- auth ---------- */
.auth-wrap { max-width: 420px; margin: 1.5rem auto; }
.auth-form { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); padding: 1.6rem; box-shadow: var(--shadow); }
.auth-form h1 { font-size: 1.5rem; }
.field { display: block; margin-bottom: 0.9rem; }
.field-label { display: block; font-size: 0.85rem; font-weight: 600; margin-bottom: 0.3rem; color: var(--muted); }
.field-hint { display: block; font-size: 0.78rem; color: var(--muted); margin-top: 0.25rem; }
.input { width: 100%; font: inherit; padding: 0.6rem 0.75rem; border: 1px solid var(--border); border-radius: var(--radius-sm); background: var(--surface); color: var(--text); }
.input:focus { outline: none; border-color: var(--primary); box-shadow: 0 0 0 3px var(--ring); }
.auth-switch { text-align: center; font-size: 0.9rem; color: var(--muted); margin: 1rem 0 0; }
.auth-msg:not(:empty) { margin-bottom: 0.8rem; }

/* ---------- misc ---------- */
.loading { text-align: center; color: var(--muted); padding: 3rem 1rem; }
.error-box { text-align: center; padding: 2rem; color: var(--muted); }
.site-footer { border-top: 1px solid var(--border); color: var(--muted); font-size: 0.85rem; }
.footer-inner { max-width: var(--maxw); margin: 0 auto; padding: 1.4rem 1.1rem; display: flex; justify-content: space-between; gap: 1rem; flex-wrap: wrap; }

/* ---------- responsive ---------- */
@media (max-width: 760px) {
  .main-nav { display: none; }
  .level-cols { grid-template-columns: 1fr; }
  .header-inner { gap: 0.6rem; }
  h1 { font-size: 1.6rem; }
  .stat-cards { grid-template-columns: 1fr; }
  .course-level-hours { margin-left: 0; text-align: left; }
}

/* ---------- anonymous accounts + consent ---------- */
.code-input { width: 100%; font-family: ui-monospace, SFMono-Regular, Menlo, monospace; letter-spacing: 0.08em; text-transform: uppercase; resize: vertical; }
.code-box { font-family: ui-monospace, SFMono-Regular, Menlo, monospace; font-size: 1.15rem; font-weight: 700; letter-spacing: 0.1em; background: var(--surface-2); border: 1px dashed var(--border); border-radius: var(--radius-sm); padding: 0.9rem; text-align: center; word-break: break-all; margin: 0.6rem 0; }
.code-warn { background: var(--no-bg); color: var(--no-ink); border-radius: var(--radius-sm); padding: 0.6rem 0.8rem; font-size: 0.88rem; margin: 0.8rem 0; }
.code-check { display: flex; align-items: center; gap: 0.5rem; margin: 0.6rem 0 1rem; font-size: 0.92rem; }
.account-card { display: flex; align-items: center; justify-content: space-between; gap: 1rem; flex-wrap: wrap; margin-top: 1.6rem; background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); padding: 1rem 1.2rem; }
.account-handle code { background: var(--surface-2); padding: 0.15rem 0.5rem; border-radius: 6px; font-weight: 700; }
.btn-danger { background: var(--no-bg); color: var(--no-ink); border-color: transparent; }
.btn-danger:hover { background: var(--red); color: #fff; }
.legal h3 { margin-top: 1.4rem; }
.legal ul { padding-left: 1.2rem; }
.legal li { margin-bottom: 0.4rem; }
.linklike { background: none; border: 0; color: var(--primary); cursor: pointer; font: inherit; padding: 0; }
.linklike:hover { text-decoration: underline; }
.cookie-banner { position: fixed; left: 0; right: 0; bottom: 0; z-index: 200; background: var(--surface); border-top: 1px solid var(--border); box-shadow: 0 -4px 16px rgba(20, 30, 50, 0.08); padding: 0.8rem 1.1rem; display: flex; align-items: center; justify-content: center; gap: 1rem; flex-wrap: wrap; font-size: 0.9rem; }
.cb-text { color: var(--text); max-width: 720px; }
.cb-actions { display: flex; gap: 0.5rem; }
.cb-btn { padding: 0.45rem 1rem; border-radius: 999px; border: 1px solid var(--border); background: var(--surface); color: var(--text); font-weight: 600; cursor: pointer; font-size: 0.88rem; }
.cb-accept { background: var(--primary); color: #fff; border-color: transparent; }
.cb-decline { background: transparent; }

/* ---------- reading ---------- */
.sec-reading .reading-lt { font-size: 1.05rem; line-height: 1.75; }
.reading-tr { margin-top: 0.5rem; border-top: 1px dashed var(--border); padding-top: 0.5rem; }
.reading-tr summary { cursor: pointer; color: var(--primary); font-weight: 600; font-size: 0.9rem; }
.reading-tr p { color: var(--muted); margin: 0.5rem 0 0; }
