  :root {
    --bg: #f6f7f9;
    --surface: #ffffff;
    --surface-2: #f0f2f5;
    --border: #dfe3e8;
    --text: #1c2024;
    --text-dim: #5b6570;
    --accent: #3b6cf0;
    --accent-soft: #e8eefe;
    --ok: #17864b;
    --ok-soft: #e3f5ea;
    --bad: #c4342b;
    --bad-soft: #fdeae8;
    --code-bg: #1e2229;
    --code-text: #e6e9ef;
    --c-kw: #c792ea;
    --c-str: #a5d6a7;
    --c-num: #f5b97a;
    --c-com: #7f8a99;
    --c-fn: #82b8ff;
    --radius: 12px;
    --shadow: 0 1px 2px rgba(20,25,35,.06), 0 6px 20px rgba(20,25,35,.05);
  }
  @media (prefers-color-scheme: dark) {
    :root {
      --bg: #12151a;
      --surface: #1a1e25;
      --surface-2: #22272f;
      --border: #2e343d;
      --text: #e7eaef;
      --text-dim: #9aa4b2;
      --accent: #6f97ff;
      --accent-soft: #1e2740;
      --ok: #5fd08a;
      --ok-soft: #16301f;
      --bad: #ff8a80;
      --bad-soft: #331c1a;
      --code-bg: #10131a;
      --shadow: 0 1px 2px rgba(0,0,0,.3), 0 8px 24px rgba(0,0,0,.25);
    }
  }
  :root[data-theme="dark"] {
    --bg: #12151a; --surface: #1a1e25; --surface-2: #22272f; --border: #2e343d;
    --text: #e7eaef; --text-dim: #9aa4b2; --accent: #6f97ff; --accent-soft: #1e2740;
    --ok: #5fd08a; --ok-soft: #16301f; --bad: #ff8a80; --bad-soft: #331c1a;
    --code-bg: #10131a; --shadow: 0 1px 2px rgba(0,0,0,.3), 0 8px 24px rgba(0,0,0,.25);
  }
  :root[data-theme="light"] {
    --bg: #f6f7f9; --surface: #ffffff; --surface-2: #f0f2f5; --border: #dfe3e8;
    --text: #1c2024; --text-dim: #5b6570; --accent: #3b6cf0; --accent-soft: #e8eefe;
    --ok: #17864b; --ok-soft: #e3f5ea; --bad: #c4342b; --bad-soft: #fdeae8;
    --code-bg: #1e2229; --shadow: 0 1px 2px rgba(20,25,35,.06), 0 6px 20px rgba(20,25,35,.05);
  }

  * { box-sizing: border-box; }
  body {
    margin: 0;
    background: var(--bg);
    color: var(--text);
    font: 16px/1.7 "Jua", -apple-system, "Segoe UI", "Malgun Gothic", Roboto, sans-serif;
    -webkit-text-size-adjust: 100%;
  }
  code, pre, kbd { font-family: ui-monospace, SFMono-Regular, Consolas, "D2Coding", monospace; }
  a { color: var(--accent); }

  /* ---------- 헤더 ---------- */
  header {
    position: sticky; top: 0; z-index: 20;
    background: var(--surface);
    background: color-mix(in srgb, var(--surface) 88%, transparent);
    backdrop-filter: blur(10px);
    border-bottom: 1px solid var(--border);
  }
  .head-inner {
    max-width: 1120px; margin: 0 auto; padding: 14px 20px;
    display: flex; align-items: center; gap: 16px; flex-wrap: wrap;
  }
  .brand { font-size: 18px; font-weight: 700; letter-spacing: -.01em; margin-right: auto; cursor: pointer; }
  .brand span { color: var(--accent); }
  .langbar { display: flex; gap: 6px; flex-wrap: wrap; }
  .auth-area { display: flex; align-items: center; gap: 8px; }
  .user-greet { font-size: 14px; color: var(--text-dim); }
  .btn.small { padding: 6px 13px; font-size: 13.5px; border-radius: 999px; }
  .text-btn { border: 0; background: none; color: var(--text-dim); font: inherit; font-size: 13.5px; text-decoration: underline; cursor: pointer; padding: 0; }
  .chip {
    border: 1px solid var(--border); background: var(--surface-2); color: var(--text-dim);
    padding: 6px 13px; border-radius: 999px; font-size: 14px; font-weight: 600;
    cursor: pointer; transition: .15s;
  }
  .chip:hover { color: var(--text); border-color: var(--accent); }
  .chip[aria-pressed="true"] {
    background: var(--accent); border-color: var(--accent); color: #fff;
  }
  .icon-btn {
    border: 1px solid var(--border); background: var(--surface-2); color: var(--text);
    width: 36px; height: 36px; border-radius: 9px; cursor: pointer; font-size: 16px; line-height: 1;
  }
  .icon-btn:hover { border-color: var(--accent); }

  /* ---------- 레이아웃 ---------- */
  .wrap { max-width: 1120px; margin: 0 auto; padding: 28px 20px 80px; display: grid; gap: 28px; grid-template-columns: 250px 1fr; align-items: start; }
  .wrap.home-view { grid-template-columns: 1fr; max-width: 1000px; }
  @media (max-width: 860px) { .wrap { grid-template-columns: 1fr; } }

  /* ---------- 사이드바 ---------- */
  aside { position: sticky; top: 78px; display: grid; gap: 16px; }
  aside[hidden] { display: none; }
  @media (max-width: 860px) { aside { position: static; } }
  .card { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); box-shadow: var(--shadow); }
  .card-pad { padding: 18px 20px; }
  .side-title { font-size: 12px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; color: var(--text-dim); padding: 16px 18px 8px; }
  .unit-list { list-style: none; margin: 0; padding: 0 10px 12px; display: grid; gap: 2px; }
  .unit-btn {
    width: 100%; text-align: left; display: flex; align-items: center; gap: 9px;
    border: 0; background: transparent; color: var(--text); font: inherit; font-size: 14.5px;
    padding: 9px 10px; border-radius: 8px; cursor: pointer;
  }
  .unit-btn:hover:not(:disabled) { background: var(--surface-2); }
  .unit-btn[aria-current="true"] { background: var(--accent-soft); color: var(--accent); font-weight: 600; }
  .unit-btn:disabled { color: var(--text-dim); cursor: not-allowed; opacity: .7; }
  .dot { width: 8px; height: 8px; border-radius: 50%; background: var(--border); flex: none; }
  .unit-btn.done .dot { background: var(--ok); }
  .soon { margin-left: auto; font-size: 11px; border: 1px solid var(--border); border-radius: 5px; padding: 1px 5px; color: var(--text-dim); }
  .tier-head { font-size: 11px; font-weight: 700; letter-spacing: .07em; text-transform: uppercase; color: var(--text-dim); padding: 12px 10px 3px; }
  .tier-head:first-child { padding-top: 2px; }
  .tier-challenge { display: grid; gap: 6px; padding: 0 10px 12px; }
  .tier-challenge .btn { width: 100%; }

  .progress-num { font-size: 30px; font-weight: 700; letter-spacing: -.02em; }
  .bar { height: 8px; border-radius: 999px; background: var(--surface-2); overflow: hidden; margin-top: 10px; }
  .bar > i { display: block; height: 100%; background: var(--accent); border-radius: 999px; transition: width .4s ease; }
  .muted { color: var(--text-dim); font-size: 13.5px; }
  .reset { margin-top: 14px; background: none; border: 0; padding: 0; color: var(--text-dim); font: inherit; font-size: 13px; text-decoration: underline; cursor: pointer; }
  .tip-line { margin-top: 14px; font-size: 13px; line-height: 1.6; color: var(--text-dim); background: var(--surface-2); border-radius: 8px; padding: 10px 12px; }
  .tip-line b { color: var(--accent); }

  /* ---------- 본문 ---------- */
  .hero { margin-bottom: 22px; }
  .hero h1 { margin: 6px 0 6px; font-size: 30px; letter-spacing: -.02em; line-height: 1.3; }
  .eyebrow { font-size: 13px; font-weight: 700; color: var(--accent); letter-spacing: .04em; }
  .hero p { margin: 0; color: var(--text-dim); }
  .goals { list-style: none; margin: 16px 0 0; padding: 0; display: flex; flex-wrap: wrap; gap: 8px; }
  .goals li { font-size: 13.5px; background: var(--surface-2); border: 1px solid var(--border); border-radius: 999px; padding: 4px 12px; }

  /* ---------- 홈 화면 ---------- */
  .home-hero { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); box-shadow: var(--shadow); padding: 32px 28px; margin-bottom: 26px; }
  .home-hero h1 { margin: 6px 0 10px; font-size: 28px; letter-spacing: -.02em; line-height: 1.35; }
  .home-hero p { margin: 0 0 16px; color: var(--text-dim); font-size: 15px; }
  .home-stat { display: inline-block; background: var(--accent-soft); color: var(--accent); font-weight: 600; font-size: 14px; padding: 8px 14px; border-radius: 8px; }
  .lang-grid { display: grid; gap: 16px; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); }
  .lang-card { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); box-shadow: var(--shadow); padding: 20px; cursor: pointer; transition: .15s; display: flex; flex-direction: column; }
  .lang-card:hover { border-color: var(--accent); transform: translateY(-2px); }
  .lang-card h3 { margin: 0 0 6px; font-size: 17px; }
  .lang-card p { margin: 0 0 12px; color: var(--text-dim); font-size: 13.5px; flex-grow: 1; }
  .lang-card-meta { font-size: 12.5px; color: var(--text-dim); margin-bottom: 12px; }
  .lang-card .btn { align-self: flex-start; }
  .review-langs { display: flex; flex-wrap: wrap; gap: 10px; }
  .review-lang-opt {
    display: flex; align-items: center; gap: 8px; border: 1px solid var(--border); background: var(--surface-2);
    padding: 8px 14px; border-radius: 999px; cursor: pointer; font-size: 14.5px;
  }
  .review-lang-opt input { accent-color: var(--accent); }
  .boss-cta .body { display: flex; align-items: center; gap: 14px; flex-wrap: wrap; }
  .boss-cta h3 { margin: 0 0 4px; font-size: 16px; }
  .boss-cta p { margin: 0; }
  .boss-cta .btn { margin-left: auto; }

  section.block { margin-bottom: 18px; }
  section.block > h2 { margin: 0; padding: 18px 20px 0; font-size: 18px; letter-spacing: -.01em; }
  section.block > .body { padding: 10px 20px 20px; }
  .body > p { margin: 0 0 12px; }
  .body > p:last-child { margin-bottom: 0; }
  .body ul { margin: 0 0 12px; padding-left: 20px; }
  .body li { margin-bottom: 5px; }
  .body table { width: 100%; border-collapse: collapse; font-size: 14.5px; margin-bottom: 12px; }
  .body th, .body td { text-align: left; padding: 8px 10px; border-bottom: 1px solid var(--border); }
  .body th { color: var(--text-dim); font-weight: 600; font-size: 13px; }
  .body td code { background: var(--surface-2); padding: 1px 5px; border-radius: 4px; font-size: 13.5px; }
  p code, li code { background: var(--surface-2); padding: 1px 5px; border-radius: 4px; font-size: 14px; }
  .note {
    border-left: 3px solid var(--accent); background: var(--accent-soft);
    padding: 12px 14px; border-radius: 0 8px 8px 0; font-size: 14.5px;
  }
  .note b { color: var(--accent); }

  /* ---------- 코드 블록 ---------- */
  figure.code { margin: 0 0 14px; border: 1px solid var(--border); border-radius: 10px; overflow: hidden; background: var(--code-bg); }
  figure.code figcaption {
    display: flex; align-items: center; gap: 10px;
    padding: 8px 12px; background: rgba(255,255,255,.05); color: #b9c2cf;
    font-size: 13px; border-bottom: 1px solid rgba(255,255,255,.07);
  }
  .copy {
    margin-left: auto; border: 1px solid rgba(255,255,255,.18); background: transparent;
    color: #cdd5e0; border-radius: 6px; padding: 3px 9px; font: inherit; font-size: 12.5px; cursor: pointer;
  }
  .copy:hover { background: rgba(255,255,255,.1); }
  figure.code pre { margin: 0; padding: 14px 16px; overflow-x: auto; color: var(--code-text); font-size: 14px; line-height: 1.65; }
  .out { border-top: 1px dashed rgba(255,255,255,.15); padding: 10px 16px 12px; color: #9aa4b2; font-size: 13.5px; white-space: pre-wrap; }
  .out b { color: #cdd5e0; font-weight: 600; display: block; margin-bottom: 3px; font-size: 12px; letter-spacing: .06em; }
  .preview { padding: 12px 16px 16px; border-top: 1px dashed rgba(255,255,255,.15); }
  .preview-label { color: #9aa4b2; font-size: 12px; letter-spacing: .06em; margin-bottom: 6px; display: block; }
  .preview iframe { display: block; width: 100%; height: 150px; border: 1px solid rgba(255,255,255,.14); border-radius: 8px; background: #fff; }
  .tok-kw { color: var(--c-kw); }
  .tok-str { color: var(--c-str); }
  .tok-num { color: var(--c-num); }
  .tok-com { color: var(--c-com); font-style: italic; }
  .tok-fn { color: var(--c-fn); }

  /* ---------- 연습 문제 ---------- */
  .q { padding: 4px 20px 18px; }
  .q-source { display: inline-block; font-size: 12px; color: var(--text-dim); background: var(--surface-2); border: 1px solid var(--border); padding: 3px 10px; border-radius: 999px; margin-bottom: 12px; }
  .q-head { display: flex; gap: 10px; font-weight: 600; margin-bottom: 12px; }
  .q-num { color: var(--accent); flex: none; }
  .q-text { font-weight: 600; }
  .q-text code { background: var(--surface-2); padding: 1px 5px; border-radius: 4px; font-size: 14px; font-weight: 400; }
  .opts { display: grid; gap: 7px; }
  .opt {
    display: flex; align-items: flex-start; gap: 10px; cursor: pointer;
    border: 1px solid var(--border); background: var(--surface); border-radius: 9px; padding: 10px 12px; font-size: 15px;
  }
  .opt:hover { border-color: var(--accent); }
  .opt input { margin: 4px 0 0; accent-color: var(--accent); flex: none; }
  .opt code { font-size: 14px; }
  .opt.correct { border-color: var(--ok); background: var(--ok-soft); }
  .opt.wrong { border-color: var(--bad); background: var(--bad-soft); }
  .blank-row { display: flex; gap: 8px; flex-wrap: wrap; align-items: center; }
  .blank-row input[type=text] {
    flex: 1 1 160px; min-width: 0; font: inherit; font-family: ui-monospace, Consolas, monospace; font-size: 14.5px;
    padding: 9px 12px; border: 1px solid var(--border); border-radius: 9px; background: var(--surface); color: var(--text);
  }
  .blank-row input:focus-visible, .opt:focus-within { outline: 2px solid var(--accent); outline-offset: 1px; }
  .verdict { margin-top: 12px; font-size: 14.5px; padding: 10px 12px; border-radius: 8px; }
  .verdict.ok { background: var(--ok-soft); color: var(--ok); }
  .verdict.no { background: var(--bad-soft); color: var(--bad); }
  .verdict.ok::before { content: "정답이에요  "; font-weight: 700; }
  .verdict.no::before { content: "아쉬워요  "; font-weight: 700; }
  .quiz-stats { display: flex; gap: 10px; flex-wrap: wrap; margin-bottom: 4px; }
  .stat { background: var(--surface-2); border: 1px solid var(--border); border-radius: 8px; padding: 6px 12px; font-size: 13.5px; color: var(--text-dim); }
  .stat b { color: var(--text); font-size: 15px; margin-right: 4px; }
  .stat.done { background: var(--ok-soft); color: var(--ok); border-color: transparent; font-weight: 600; }
  .hint-box { margin: 0 20px 16px; border-left: 3px solid var(--accent); background: var(--accent-soft); padding: 10px 12px; border-radius: 0 8px 8px 0; font-size: 14px; }
  .hint-box b { color: var(--accent); margin-right: 4px; }
  .code-editor { padding: 0 20px 14px; }
  .code-editor textarea {
    width: 100%; min-height: 110px; font-family: ui-monospace, Consolas, "D2Coding", monospace; font-size: 14px;
    padding: 12px 14px; border: 1px solid var(--border); border-radius: 9px;
    background: var(--code-bg); color: var(--code-text); resize: vertical; line-height: 1.6; tab-size: 4;
  }
  .code-editor textarea:disabled { opacity: .75; }
  .code-editor textarea:focus-visible { outline: 2px solid var(--accent); outline-offset: 1px; }
  .code-output { font-family: ui-monospace, Consolas, monospace; font-size: 13.5px; white-space: pre-wrap; margin-bottom: 8px; background: rgba(127,127,127,.08); padding: 8px 10px; border-radius: 6px; }
  .code-output b { display: block; font-size: 11px; letter-spacing: .06em; margin-bottom: 4px; opacity: .7; }
  .code-error { color: var(--bad); }
  .code-preview { padding: 0 20px 16px; }
  .code-preview-label { color: var(--text-dim); font-size: 12px; letter-spacing: .06em; margin-bottom: 6px; display: block; }
  .code-preview iframe { display: block; width: 100%; height: 130px; border: 1px solid var(--border); border-radius: 8px; background: #fff; }
  .quiz-foot { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; border-top: 1px solid var(--border); padding: 16px 20px; }
  .btn {
    border: 0; background: var(--accent); color: #fff; font: inherit; font-weight: 600;
    padding: 10px 18px; border-radius: 9px; cursor: pointer;
  }
  .btn:hover { filter: brightness(1.08); }
  .btn:disabled { opacity: .5; cursor: not-allowed; }
  .btn.ghost { background: var(--surface-2); color: var(--text); border: 1px solid var(--border); }
  footer { max-width: 1120px; margin: 0 auto; padding: 0 20px 40px; color: var(--text-dim); font-size: 13.5px; }

  /* ---------- 로그인/회원가입 모달 ---------- */
  .modal-overlay {
    position: fixed; inset: 0; z-index: 50; background: rgba(10,12,16,.5);
    display: flex; align-items: center; justify-content: center; padding: 20px;
  }
  .modal-overlay[hidden] { display: none; }
  .modal {
    width: 100%; max-width: 380px; background: var(--surface); border: 1px solid var(--border);
    border-radius: var(--radius); box-shadow: var(--shadow); padding: 26px 24px 24px; position: relative;
  }
  .modal-close {
    position: absolute; top: 14px; right: 14px; border: 0; background: none; color: var(--text-dim);
    font-size: 20px; line-height: 1; cursor: pointer; width: 28px; height: 28px; border-radius: 6px;
  }
  .modal-close:hover { background: var(--surface-2); color: var(--text); }
  .auth-tabs { display: flex; gap: 6px; margin-bottom: 14px; }
  .auth-tab {
    flex: 1; border: 1px solid var(--border); background: var(--surface-2); color: var(--text-dim);
    font: inherit; font-weight: 600; font-size: 14px; padding: 8px; border-radius: 8px; cursor: pointer;
  }
  .auth-tab[aria-pressed="true"] { background: var(--accent); border-color: var(--accent); color: #fff; }
  .auth-title { margin: 0 0 6px; font-size: 20px; letter-spacing: -.01em; }
  .auth-note { margin: 0 0 18px; line-height: 1.6; }
  .auth-form { display: grid; gap: 14px; }
  .auth-form label { display: grid; gap: 6px; font-size: 13.5px; color: var(--text-dim); font-weight: 600; }
  .auth-form label[hidden] { display: none; }
  .auth-form input {
    font: inherit; font-size: 15px; padding: 10px 12px; border: 1px solid var(--border);
    border-radius: 9px; background: var(--surface); color: var(--text);
  }
  .auth-form input:focus-visible { outline: 2px solid var(--accent); outline-offset: 1px; }
  .auth-error { background: var(--bad-soft); color: var(--bad); font-size: 13.5px; padding: 9px 12px; border-radius: 8px; }
  .auth-form .btn { width: 100%; padding: 11px; font-size: 15px; }

  /* ---------- 미니게임 ---------- */
  .minigame-btn { background: linear-gradient(135deg, var(--accent), #9d6bff); border: 0; color: #fff; }
  .game-hud { display: flex; gap: 10px; margin-bottom: 14px; }
  .bug-lines { border: 1px solid var(--border); border-radius: 10px; overflow: hidden; background: var(--code-bg); }
  .bug-line {
    display: flex; align-items: center; gap: 12px; width: 100%; text-align: left;
    border: 0; border-bottom: 1px solid rgba(255,255,255,.08); background: none; color: var(--code-text);
    padding: 10px 14px; cursor: pointer; font-family: ui-monospace, Consolas, "D2Coding", monospace; font-size: 14.5px;
  }
  .bug-line:last-child { border-bottom: 0; }
  .bug-line:hover:not(:disabled) { background: rgba(255,255,255,.06); }
  .bug-line:disabled { cursor: default; }
  .bug-line-no { flex: none; width: 20px; color: #7f8a99; font-size: 12px; text-align: right; }
  .bug-line.correct { background: rgba(23,134,75,.35); }
  .bug-line.wrong { background: rgba(196,52,43,.35); }
  .type-target { font-family: ui-monospace, Consolas, "D2Coding", monospace; font-size: 16px; background: var(--code-bg); color: var(--code-text); padding: 14px 16px; border-radius: 9px; white-space: pre-wrap; margin-bottom: 14px; }
  .typing-input { width: 100%; font-family: ui-monospace, Consolas, monospace; font-size: 15px; padding: 10px 12px; border: 1px solid var(--border); border-radius: 9px; background: var(--surface); color: var(--text); }
  .typing-input:focus-visible { outline: 2px solid var(--accent); outline-offset: 1px; }
  .reorder-pool, .reorder-answer { display: flex; flex-wrap: wrap; gap: 8px; min-height: 44px; padding: 10px; border: 1px dashed var(--border); border-radius: 9px; background: var(--surface-2); }
  .reorder-line { font-family: ui-monospace, Consolas, monospace; font-size: 13.5px; border: 1px solid var(--border); background: var(--surface); color: var(--text); padding: 8px 12px; border-radius: 7px; cursor: pointer; white-space: pre; }
  .reorder-line:hover { border-color: var(--accent); }

  /* 미니게임 허브 */
  .minigame-hub { display: grid; gap: 16px; }
  .minigame-lang-row { padding: 18px 20px; }
  .minigame-lang-row h3 { margin: 0 0 12px; font-size: 16px; }
  .minigame-slots { display: grid; grid-template-columns: repeat(auto-fit, minmax(160px, 1fr)); gap: 10px; }
  .minigame-slot {
    display: flex; flex-direction: column; gap: 4px; align-items: flex-start; text-align: left;
    border: 1px solid var(--border); background: var(--surface-2); border-radius: 10px; padding: 12px 14px; cursor: pointer;
  }
  .minigame-slot:hover:not(:disabled) { border-color: var(--accent); }
  .minigame-slot:disabled { opacity: .55; cursor: not-allowed; }
  .minigame-slot-tier { font-size: 11px; font-weight: 700; letter-spacing: .06em; text-transform: uppercase; color: var(--accent); }
  .minigame-slot-name { font-size: 14.5px; font-weight: 600; color: var(--text); }
  .minigame-slot.locked .minigame-slot-tier { color: var(--text-dim); }
  .minigame-slot.locked .minigame-slot-name { color: var(--text-dim); font-weight: 500; }

  /* 짝 맞추기 */
  .match-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(110px, 1fr)); gap: 10px; }
  .match-card {
    min-height: 72px; display: flex; align-items: center; justify-content: center; text-align: center;
    border: 1px solid var(--border); border-radius: 10px; background: var(--surface-2); color: var(--text);
    font-size: 13.5px; padding: 8px; cursor: pointer; word-break: keep-all;
  }
  .match-card.flipped { background: var(--accent-soft); border-color: var(--accent); color: var(--accent); font-weight: 600; }
  .match-card.matched { background: var(--ok-soft); border-color: var(--ok); color: var(--ok); font-weight: 600; cursor: default; }

  /* 출력 맞히기 스피드런 */
  .speed-opts { display: grid; gap: 8px; }
  .speed-opt { border: 1px solid var(--border); background: var(--surface); color: var(--text); border-radius: 9px; padding: 10px 14px; font: inherit; font-size: 15px; text-align: left; cursor: pointer; }
  .speed-opt:hover:not(:disabled) { border-color: var(--accent); }
  .speed-opt.correct { border-color: var(--ok); background: var(--ok-soft); }
  .speed-opt.wrong { border-color: var(--bad); background: var(--bad-soft); }

  /* 키워드 골라내기 */
  .keyword-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(90px, 1fr)); gap: 10px; }
  .keyword-tile {
    font-family: ui-monospace, Consolas, monospace; font-size: 14px; border: 1px solid var(--border);
    background: var(--surface-2); color: var(--text); border-radius: 9px; padding: 12px 8px; cursor: pointer;
  }
  .keyword-tile:hover:not(:disabled) { border-color: var(--accent); }
  .keyword-tile.correct { border-color: var(--ok); background: var(--ok-soft); color: var(--ok); }
  .keyword-tile.wrong { border-color: var(--bad); background: var(--bad-soft); color: var(--bad); }
