/* Minh Dokkai — bảng màu giữ nguyên tông của ForumFlash */
:root {
  --green: #004646;
  --green-deep: #003838;
  --mint: #27c4b5;
  --mint-soft: #e6f0f2;
  --coral: #ed3838;
  --coral-soft: #ffebeb;
  --cream: #f7f4ed;
  --bg: #f8fbfa;
  --ink: #0f172a;
  --muted: #667279;
  --line: #d9e3e4;
  --white: #fff;
  --surface: #fff;
  --on-primary: #fff;
  --brand-ink: var(--green);
  --band-text: #e9f2f1;
  --band-sub: #bcd3d1;
  --hero-text: #37474f;
  --coral-ink: #b42121;
  --soon-bg: #eef1f2;
  --header-bg: rgba(255,255,255,.96);
  --shadow: rgba(0,56,56,.16);
  --step-4: color-mix(in srgb, var(--mint) 55%, var(--green));
  --step-3: color-mix(in srgb, var(--mint) 28%, var(--green));
  --grid: rgba(39, 196, 181, .16);

  --ui: "Be Vietnam Pro", system-ui, sans-serif;
  --jp: "Shippori Mincho B1", "Hiragino Mincho ProN", "Yu Mincho", "Noto Serif JP", serif;
  --jps: "Zen Kaku Gothic New", "Hiragino Sans", "Yu Gothic", "Noto Sans JP", sans-serif;

  --wrap: 1180px;
  --gut: clamp(16px, 4vw, 40px);
  --r-sm: 8px;
  --r: 14px;
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
body {
  margin: 0; background: var(--bg); color: var(--ink);
  font: 400 16px/1.6 var(--ui);
  -webkit-font-smoothing: antialiased;
}
[lang="ja"], .jp { font-family: var(--jp); }
a { color: inherit; }
button { font: inherit; color: inherit; cursor: pointer; }
img, svg { display: block; }
:focus-visible { outline: 3px solid var(--mint); outline-offset: 2px; border-radius: 4px; }
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.skip { position: absolute; left: -999px; top: 8px; background: var(--green); color: var(--on-primary); padding: 8px 14px; border-radius: 8px; z-index: 100; }
.skip:focus { left: 8px; }
.wrap { max-width: var(--wrap); margin: 0 auto; padding: 0 var(--gut); }
[hidden] { display: none !important; }

ruby { ruby-position: over; ruby-align: center; }
rt { font-family: var(--jps); font-size: .42em; color: var(--muted); letter-spacing: .02em; font-weight: 500; }
.sp { display: inline-block; width: .32em; }

/* ---------- header ---------- */
.top { position: sticky; top: 0; z-index: 40; background: var(--header-bg); border-bottom: 1px solid var(--line); backdrop-filter: saturate(1.2) blur(8px); }
.top__in { max-width: var(--wrap); margin: 0 auto; padding: 0 var(--gut); height: 68px; display: flex; align-items: center; gap: 28px; }
.brand { display: flex; align-items: center; gap: 10px; text-decoration: none; flex: none; }
.brand__mark { width: 40px; height: 40px; }
.brand__word { display: flex; flex-direction: column; line-height: 1; font-weight: 800; letter-spacing: -.01em; }
.brand__minh { font-size: 13px; color: var(--muted); font-weight: 600; letter-spacing: .04em; }
.brand__dok { font-size: 22px; color: var(--brand-ink); margin-top: 3px; }
.nav { display: flex; gap: 4px; margin-left: 8px; }
.nav a { text-decoration: none; font-weight: 600; font-size: 14.5px; color: var(--muted); padding: 8px 12px; border-radius: 8px; position: relative; display: flex; gap: 6px; align-items: center; }
.nav a:hover { color: var(--brand-ink); background: var(--mint-soft); }
.nav a[aria-current="page"] { color: var(--brand-ink); }
.nav a[aria-current="page"]::after { content: ""; position: absolute; left: 12px; right: 12px; bottom: -14px; height: 3px; background: var(--coral); border-radius: 3px; }
.badge { background: var(--coral); color: var(--on-primary); font-size: 11px; font-weight: 700; border-radius: 10px; padding: 0 6px; line-height: 18px; min-width: 18px; text-align: center; }
.toggles { margin-left: auto; display: flex; gap: 8px; }
.tg { display: inline-flex; align-items: center; gap: 8px; border: 1px solid var(--line); background: var(--surface); border-radius: 999px; padding: 6px 8px 6px 12px; font-weight: 600; font-size: 13px; }
.tg__ja { font-family: var(--jp); font-weight: 800; font-size: 15px; }
.tg__la { font-style: italic; }
.tg__sw { width: 30px; height: 18px; border-radius: 9px; background: var(--line); position: relative; transition: background .2s; }
.tg__sw::after { content: ""; position: absolute; top: 2px; left: 2px; width: 14px; height: 14px; border-radius: 50%; background: #fff; box-shadow: 0 1px 2px rgba(0,0,0,.2); transition: transform .2s; }
.tg[aria-pressed="true"] { border-color: var(--brand-ink); color: var(--brand-ink); }
.tg[aria-pressed="true"] .tg__sw { background: var(--green); }
.tg[aria-pressed="true"] .tg__sw::after { transform: translateX(12px); }

/* ---------- buttons ---------- */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; border: 1px solid transparent; border-radius: 10px; padding: 11px 18px; font-weight: 700; font-size: 14.5px; text-decoration: none; line-height: 1.2; transition: background .15s, border-color .15s; }
.btn--primary { background: var(--green); color: var(--on-primary); }
.btn--primary:hover { background: var(--green-deep); }
.btn--ghost { background: var(--surface); border-color: var(--line); color: var(--brand-ink); }
.btn--ghost:hover { border-color: var(--brand-ink); }
.btn--coral { background: var(--coral-soft); color: var(--coral-ink); }
.btn--coral:hover { background: color-mix(in srgb, var(--coral) 22%, var(--surface)); }
.btn--sm { padding: 7px 12px; font-size: 13px; border-radius: 8px; }
.btn[disabled] { opacity: .45; cursor: not-allowed; }

/* ---------- hero ---------- */
.hero { background: var(--cream); border-bottom: 1px solid var(--line); overflow: hidden; }
.hero__in { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.05fr); gap: 56px; align-items: end; padding-top: 64px; }
.hero__copy { padding-bottom: 64px; }
.hero h1 { font-size: clamp(34px, 5.2vw, 58px); line-height: 1.08; letter-spacing: -.025em; color: var(--brand-ink); margin: 0 0 20px; font-weight: 800; }
.hero h1 .jp { display: block; font-size: .5em; color: var(--muted); font-weight: 700; letter-spacing: .08em; margin-bottom: 14px; }
.hero p { font-size: 17px; color: var(--hero-text); max-width: 34em; margin: 0 0 28px; }
.hero__actions { display: flex; gap: 10px; flex-wrap: wrap; }

.stairs { display: grid; grid-template-columns: repeat(5, 1fr); gap: 6px; align-items: end; height: 380px; }
.step { position: relative; display: flex; flex-direction: column; justify-content: flex-start; padding: 14px 14px 18px; border-radius: 10px 10px 0 0; text-decoration: none; color: var(--on-primary); min-width: 0; transition: transform .25s ease; }
.step:hover { transform: translateY(-6px); }
.step__lv { font-weight: 800; font-size: clamp(22px, 2.6vw, 34px); letter-spacing: -.02em; line-height: 1; }
.step__n { font-size: 13px; font-weight: 600; margin-top: 6px; opacity: .9; }
.step__st { margin-top: auto; font-size: 12px; font-weight: 600; opacity: .85; }
.step[data-lv="n5"] { height: 30%; background: var(--mint); color: var(--green-deep); }
.step[data-lv="n4"] { height: 46%; background: var(--step-4); }
.step[data-lv="n3"] { height: 63%; background: var(--step-3); }
.step[data-lv="n2"] { height: 81%; background: var(--green); }
.step[data-lv="n1"] { height: 100%; background: var(--green-deep); }
.step__ja { position: absolute; right: 10px; top: 12px; font-family: var(--jp); font-weight: 800; font-size: clamp(28px, 3.4vw, 46px); opacity: .14; line-height: 1; pointer-events: none; }

/* ---------- sections ---------- */
.sec { padding: 72px 0; }
.sec + .sec { border-top: 1px solid var(--line); }
.sec__head { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.4fr); gap: 40px; align-items: start; margin-bottom: 32px; }
.sec h2 { font-size: clamp(26px, 3.2vw, 36px); line-height: 1.15; letter-spacing: -.02em; color: var(--brand-ink); margin: 0; font-weight: 800; }
.sec__lead { color: var(--muted); margin: 6px 0 0; max-width: 40em; }

.demo { display: grid; grid-template-columns: minmax(0, 1.25fr) minmax(0, 1fr); gap: 40px; align-items: center; }
.demo__notes { list-style: none; padding: 0; margin: 0; display: grid; gap: 18px; }
.demo__notes li { padding-left: 18px; border-left: 3px solid var(--mint); }
.demo__notes b { color: var(--brand-ink); display: block; }
.demo__notes span { color: var(--muted); font-size: 15px; }

.ways { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); border-top: 2px solid var(--green); }
.way { padding: 26px 26px 30px 0; text-decoration: none; display: flex; flex-direction: column; gap: 8px; }
.way + .way { padding-left: 26px; border-left: 1px solid var(--line); }
.way__ja { font-family: var(--jp); font-size: 30px; font-weight: 800; color: var(--brand-ink); line-height: 1.1; }
.way b { font-size: 18px; }
.way span { color: var(--muted); font-size: 15px; }
.way em { font-style: normal; font-weight: 700; color: var(--brand-ink); margin-top: 6px; font-size: 14px; text-decoration: underline; text-decoration-color: var(--mint); text-underline-offset: 4px; text-decoration-thickness: 2px; }
.way:hover em { color: var(--green-deep); text-decoration-color: var(--coral); }

/* ---------- page band (level / pos / industry) ---------- */
.band { background: var(--green); color: var(--band-text); }
.band__in { padding-top: 40px; padding-bottom: 40px; display: grid; grid-template-columns: auto minmax(0, 1fr) auto; gap: 36px; align-items: center; }
.band__big { font-size: clamp(64px, 11vw, 132px); font-weight: 800; line-height: .85; color: var(--mint); letter-spacing: -.04em; }
.band__big.jp { font-family: var(--jp); font-size: clamp(44px, 7vw, 84px); letter-spacing: 0; }
.band h1 { margin: 0 0 6px; font-size: clamp(22px, 2.6vw, 30px); color: var(--on-primary); letter-spacing: -.01em; line-height: 1.2; }
.band rt { color: var(--band-sub); }
.band--compact .band__in { padding-top: 24px; padding-bottom: 24px; }
.band p { margin: 0; max-width: 46em; color: var(--band-sub); }
.band__meta { text-align: right; min-width: 180px; }
.band__meta b { font-size: 28px; color: var(--on-primary); display: block; line-height: 1.1; }
.band__meta span { font-size: 13px; color: var(--band-sub); }
.crumb { display: inline-flex; gap: 6px; align-items: center; color: var(--band-sub); font-size: 13.5px; font-weight: 600; text-decoration: none; margin-bottom: 10px; }
.crumb:hover { color: var(--on-primary); }
.lvtabs { display: flex; gap: 6px; margin-top: 18px; flex-wrap: wrap; }
.lvtabs a { text-decoration: none; padding: 5px 12px; border-radius: 8px; font-weight: 700; font-size: 13px; color: var(--band-sub); border: 1px solid rgba(255,255,255,.18); }
.lvtabs a[aria-current="page"] { background: var(--mint); color: var(--green-deep); border-color: var(--mint); }

.meter { height: 6px; background: var(--line); border-radius: 6px; overflow: hidden; }
.meter i { display: block; height: 100%; background: var(--mint); border-radius: 6px; }
.band .meter { background: rgba(255,255,255,.18); margin-top: 8px; }

/* ---------- topic rows ---------- */
.rows { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); column-gap: 40px; }
.row { border-bottom: 1px solid var(--line); }
.row > a, .row > div { display: grid; grid-template-columns: minmax(0, 1fr) 96px; gap: 16px; align-items: center; padding: 18px 4px; text-decoration: none; }
.row > a:hover { background: linear-gradient(90deg, var(--mint-soft), transparent); }
.row__ja { font-family: var(--jp); font-size: 21px; font-weight: 700; color: var(--brand-ink); line-height: 1.5; }
.row__vi { color: var(--ink); font-weight: 600; font-size: 15px; }
.row__sub { color: var(--muted); font-size: 13px; }
.row__side { text-align: right; font-size: 13px; color: var(--muted); }
.row__side b { color: var(--ink); font-size: 15px; }
.row__side .meter { margin-top: 6px; }
.row--off .row__ja { color: var(--muted); }
.row--off .row__side { color: var(--muted); }
.pill { display: inline-block; font-size: 11.5px; font-weight: 700; padding: 1px 8px; border-radius: 6px; background: var(--mint-soft); color: var(--brand-ink); vertical-align: middle; }
.pill--soon { background: var(--soon-bg); color: var(--muted); }

/* ---------- study ---------- */
.study { padding: 28px 0 64px; }
.study__bar { display: flex; align-items: center; gap: 16px; flex-wrap: wrap; margin-bottom: 18px; }
.modes { display: inline-flex; background: var(--surface); border: 1px solid var(--line); border-radius: 12px; padding: 4px; gap: 2px; }
.modes button { border: 0; background: none; padding: 8px 14px; border-radius: 9px; font-weight: 700; font-size: 14px; color: var(--muted); display: inline-flex; gap: 8px; align-items: center; white-space: nowrap; }
.modes button .jp { font-size: 15px; }
.modes button[aria-pressed="true"] { background: var(--green); color: var(--on-primary); }
.study__stats { margin-left: auto; display: flex; gap: 18px; font-size: 13.5px; color: var(--muted); align-items: center; }
.study__stats b { color: var(--ink); font-size: 15px; }
.study__stats .rv b { color: var(--coral); }
.study__grid { display: grid; grid-template-columns: minmax(0, 1fr) 320px; gap: 24px; align-items: start; }

.card { position: relative; background: var(--surface); border: 1px solid var(--line); border-radius: var(--r); min-height: 380px; display: flex; flex-direction: column; overflow: hidden; }
.card__face { flex: 1; display: flex; flex-direction: column; padding: 22px 26px 24px; }
.card__face--front { background-image: linear-gradient(var(--grid) 1px, transparent 1px), linear-gradient(90deg, var(--grid) 1px, transparent 1px); background-size: 46px 46px; background-position: -1px -1px; }
.card__top { display: flex; align-items: center; gap: 8px; font-size: 12.5px; color: var(--muted); font-weight: 600; }
.card__num { margin-left: auto; font-weight: 800; color: var(--brand-ink); font-size: 15px; white-space: nowrap; }
.card__top { flex-wrap: wrap; row-gap: 4px; }
.card__num small { color: var(--muted); font-weight: 600; font-size: 12px; }
.card__main { flex: 1; display: flex; flex-direction: column; align-items: center; justify-content: center; text-align: center; gap: 10px; padding: 20px 0; }
.say { font-family: var(--jp); font-weight: 700; font-size: clamp(30px, 5.4vw, 52px); line-height: 1.9; color: var(--ink); background: rgba(255,255,255,.75); padding: 0 .2em; border-radius: 6px; word-break: keep-all; overflow-wrap: anywhere; }
.say--sm { font-size: clamp(22px, 3.4vw, 32px); }
.hw { background: none; color: var(--brand-ink); box-shadow: inset 0 -.14em 0 var(--mint); }
.blank { display: inline-block; min-width: 2.6em; border-bottom: 3px solid var(--coral); margin: 0 .1em; color: transparent; }
.romaji { font-family: var(--ui); font-size: 15px; font-weight: 500; color: var(--muted); font-style: italic; letter-spacing: .02em; }
.card__hint { font-size: 13px; color: var(--muted); }
.card__actions { display: flex; justify-content: center; gap: 8px; }
.icon-btn { border: 1px solid var(--line); background: var(--surface); border-radius: 999px; padding: 6px 12px; font-size: 13px; font-weight: 700; color: var(--brand-ink); display: inline-flex; gap: 6px; align-items: center; }
.icon-btn:hover { border-color: var(--brand-ink); }
.icon-btn svg { width: 16px; height: 16px; }

.back { display: grid; gap: 18px; }
.back__mean { font-size: clamp(22px, 3vw, 30px); font-weight: 800; color: var(--brand-ink); line-height: 1.25; letter-spacing: -.01em; }
.back__phrase { font-family: var(--jp); font-size: 22px; font-weight: 700; line-height: 1.9; }
.back__word { display: grid; grid-template-columns: auto minmax(0, 1fr); gap: 4px 16px; padding: 14px 16px; background: var(--bg); border-radius: 10px; border: 1px solid var(--line); }
.back__word dt { font-size: 12.5px; color: var(--muted); font-weight: 600; padding-top: 3px; }
.back__word dd { margin: 0; font-weight: 600; }
.back__word dd.jp { font-size: 20px; line-height: 1.8; }
.hv { font-weight: 800; letter-spacing: .06em; color: var(--brand-ink); font-size: 14px; }
.ex { border-left: 3px solid var(--coral); padding: 2px 0 2px 14px; }
.ex__ja { font-family: var(--jp); font-size: 19px; line-height: 2; }
.ex__vi { color: var(--muted); font-size: 15px; }

.ctl { display: grid; grid-template-columns: 1fr auto auto 1fr; gap: 10px; margin-top: 14px; align-items: center; }
.ctl .btn--coral { justify-self: end; }
.ctl .btn--primary { justify-self: start; }
.ctl .nav-btn { width: 44px; height: 44px; border-radius: 50%; border: 1px solid var(--line); background: var(--surface); font-size: 18px; color: var(--brand-ink); display: grid; place-items: center; }
.ctl .nav-btn:hover { border-color: var(--brand-ink); }
.state { display: inline-block; font-size: 11.5px; font-weight: 700; padding: 1px 8px; border-radius: 6px; }
.state--ok { background: var(--mint-soft); color: var(--brand-ink); }
.state--rv { background: var(--coral-soft); color: var(--coral-ink); }
.kbd-hint { text-align: center; font-size: 12.5px; color: var(--muted); margin-top: 12px; }
kbd { font-family: var(--ui); font-size: 11.5px; border: 1px solid var(--line); border-bottom-width: 2px; border-radius: 5px; padding: 0 5px; background: var(--surface); }

/* lật thẻ 3D */
.flip { perspective: 1600px; }
.flip__inner { display: grid; transform-style: preserve-3d; transition: transform .62s cubic-bezier(.3, .75, .25, 1.12); will-change: transform; }
.flip__inner > .card { grid-area: 1 / 1; backface-visibility: hidden; -webkit-backface-visibility: hidden; transition: box-shadow .62s ease; box-shadow: 0 1px 2px var(--shadow); }
.flip__inner > .card:nth-child(2) { transform: rotateY(180deg); }
.flip.is-flipped .flip__inner { transform: rotateY(180deg); }
.flip__inner > .card:nth-child(1) .card__face--front { cursor: pointer; }
.flip:not(.is-flipped) .flip__inner:hover { transform: rotateY(-4deg) translateY(-2px); }
.flip:not(.is-flipped) .flip__inner:hover > .card:nth-child(1) { box-shadow: 10px 14px 28px -12px var(--shadow); }
.flip.is-flipped .flip__inner > .card { animation: lift .62s ease; }
.flip:not(.is-flipped) .flip__inner > .card { animation: lift2 .62s ease; }
@keyframes lift { 0%, 100% { box-shadow: 0 1px 2px var(--shadow); } 45% { box-shadow: 0 30px 40px -18px var(--shadow); } }
@keyframes lift2 { 0%, 100% { box-shadow: 0 1px 2px var(--shadow); } 45% { box-shadow: 0 30px 40px -18px var(--shadow); } }
.deal-next .flip__inner { animation: deal-r .32s cubic-bezier(.2, .8, .3, 1); }
.deal-prev .flip__inner { animation: deal-l .32s cubic-bezier(.2, .8, .3, 1); }
@keyframes deal-r { from { transform: translateX(40px) rotate(2.5deg); opacity: 0; } to { transform: none; opacity: 1; } }
@keyframes deal-l { from { transform: translateX(-40px) rotate(-2.5deg); opacity: 0; } to { transform: none; opacity: 1; } }

/* list aside */
.aside { background: var(--surface); border: 1px solid var(--line); border-radius: var(--r); display: flex; flex-direction: column; max-height: calc(100vh - 120px); position: sticky; top: 88px; }
.aside__head { padding: 14px 16px; border-bottom: 1px solid var(--line); display: flex; align-items: center; gap: 8px; }
.aside__head b { font-size: 14px; }
.aside__head .btn { margin-left: auto; }
.wl { list-style: none; margin: 0; padding: 4px 0; overflow: auto; }
.wl button { width: 100%; text-align: left; border: 0; background: none; padding: 8px 16px; display: grid; grid-template-columns: 30px minmax(0, 1fr) auto; gap: 8px; align-items: center; }
.wl button:hover { background: var(--mint-soft); }
.wl button[aria-current="true"] { background: var(--mint-soft); box-shadow: inset 3px 0 0 var(--green); }
.wl__i { font-size: 12px; color: var(--muted); font-weight: 600; }
.wl__w { font-family: var(--jp); font-weight: 700; font-size: 16px; line-height: 1.7; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.wl__w rt { font-size: .5em; }
.wl__v { display: block; font-family: var(--ui); font-weight: 400; font-size: 12.5px; color: var(--muted); line-height: 1.3; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.dot { width: 8px; height: 8px; border-radius: 50%; background: transparent; }
.dot--ok { background: var(--mint); }
.dot--rv { background: var(--coral); }

/* quiz */
.quiz { padding: 22px 26px 26px; display: flex; flex-direction: column; gap: 18px; flex: 1; }
.quiz__q { text-align: center; padding: 18px 0 6px; display: grid; gap: 6px; justify-items: center; }
.quiz__dir { align-self: flex-start; }
.opts { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
.opt { text-align: left; border: 1px solid var(--line); background: var(--surface); border-radius: 10px; padding: 14px 16px; font-weight: 600; display: flex; gap: 12px; align-items: flex-start; line-height: 1.4; min-height: 58px; }
.opt .k { flex: none; width: 22px; height: 22px; border-radius: 6px; background: var(--mint-soft); color: var(--brand-ink); font-size: 12px; display: grid; place-items: center; font-weight: 800; margin-top: 1px; }
.opt.jp-opt { font-family: var(--jp); font-size: 19px; }
.opt:hover:not([disabled]) { border-color: var(--brand-ink); }
.opt.is-right { border-color: var(--mint); background: var(--mint-soft); color: var(--brand-ink); }
.opt.is-wrong { border-color: var(--coral); background: var(--coral-soft); color: var(--coral-ink); }
.opt[disabled] { cursor: default; }
.feedback { min-height: 24px; font-weight: 600; font-size: 14.5px; text-align: center; }
.feedback.ok { color: var(--brand-ink); }
.fb-badge { display: inline-grid; place-items: center; width: 22px; height: 22px; border-radius: 50%; font-size: 13px; font-weight: 800; margin-right: 4px; vertical-align: -3px; }
.feedback.ok .fb-badge { background: var(--mint); color: var(--green-deep); }
.feedback.no .fb-badge { background: var(--coral); color: #fff; }
.feedback.pop.ok { animation: fb-ok .5s cubic-bezier(.3,1.6,.5,1); }
.feedback.pop.no { animation: fb-no .45s ease-out; }
@keyframes fb-ok { 0% { transform: scale(.7); opacity: 0; } 100% { transform: scale(1); opacity: 1; } }
@keyframes fb-no { 0% { opacity: 0; transform: translateY(-4px); } 100% { opacity: 1; transform: none; } }
.verdict { display: inline-flex; align-items: center; gap: 10px; font-weight: 700; justify-content: center; flex-wrap: wrap; }
.verdict__icon { width: 30px; height: 30px; border-radius: 50%; display: grid; place-items: center; flex: none; animation: v-badge .5s cubic-bezier(.2, .9, .3, 1.5) both; }
.verdict__icon svg { width: 18px; height: 18px; }
.verdict__icon path { stroke-dasharray: 30; stroke-dashoffset: 30; animation: v-draw .4s .15s ease forwards; }
.verdict--ok .verdict__icon { background: var(--mint); color: var(--green-deep); }
.verdict--no .verdict__icon { background: var(--coral); color: #fff; }
.verdict__word { font-size: 16px; animation: v-rise .4s .08s ease both; }
.verdict--ok .verdict__word { color: var(--brand-ink); }
.verdict__ja { font-family: var(--jp); font-weight: 700; margin-left: 8px; padding-left: 8px; border-left: 1px solid var(--line); opacity: .8; }
.verdict--no .verdict__word { color: var(--coral-ink); }
.verdict__ans { font-weight: 600; margin-top: 6px; color: var(--ink); animation: v-rise .4s .16s ease both; }
.streak { display: inline-flex; align-items: center; font-size: 12.5px; font-weight: 800; color: var(--green-deep); background: var(--mint); border-radius: 999px; padding: 2px 10px; animation: v-badge .45s .2s cubic-bezier(.2, .9, .3, 1.5) both; }
@keyframes v-badge { 0% { transform: scale(0) rotate(-30deg); } 100% { transform: scale(1) rotate(0); } }
@keyframes v-draw { to { stroke-dashoffset: 0; } }
@keyframes v-rise { from { opacity: 0; transform: translateY(6px); } to { opacity: 1; transform: none; } }
.score-ring { width: 120px; height: 120px; }
.score-ring circle { fill: none; stroke-width: 10; }
.score-ring .bg { stroke: var(--line); }
.score-ring .fg { stroke: var(--mint); stroke-linecap: round; transform: rotate(-90deg); transform-origin: 50% 50%; transition: stroke-dashoffset 1.1s cubic-bezier(.3, .8, .3, 1); }
.score-ring text { font: 800 26px var(--ui); fill: var(--brand-ink); }
.done__msg { color: var(--brand-ink) !important; font-weight: 700; }
.confetto { position: fixed; width: 8px; height: 11px; border-radius: 2px; pointer-events: none; z-index: 90; }
.tile.is-hit { border-color: var(--mint); background: var(--mint-soft); box-shadow: inset 0 0 0 1px var(--mint); }
.feedback.no { color: var(--coral-ink); }

/* write */
.write { display: grid; gap: 12px; max-width: 520px; margin: 0 auto; width: 100%; }
.write input { width: 100%; font: 600 20px var(--jps); padding: 14px 16px; border: 2px solid var(--line); border-radius: 12px; background: var(--surface); color: var(--ink); }
.write input:focus { outline: none; border-color: var(--brand-ink); }
.write input.ok { border-color: var(--mint); background: var(--mint-soft); }
.write input.no { border-color: var(--coral); background: var(--coral-soft); }
.write__row { display: flex; gap: 8px; }
.write__row .btn { flex: 1; }
.write small { color: var(--muted); font-size: 13px; text-align: center; }

/* match */
.match { padding: 22px 26px 26px; display: flex; flex-direction: column; gap: 16px; flex: 1; }
.match__grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px 14px; }
.match__col { display: grid; gap: 10px; align-content: start; }
.tile { border: 1px solid var(--line); background: var(--surface); border-radius: 10px; padding: 10px 14px; min-height: 58px; text-align: left; font-weight: 600; line-height: 1.35; transition: opacity .3s, background .15s; }
.tile.jp-tile { font-family: var(--jp); font-size: 19px; line-height: 1.8; text-align: center; }
.tile:hover:not([disabled]) { border-color: var(--brand-ink); }
.tile.is-sel { border-color: var(--brand-ink); background: var(--mint-soft); box-shadow: inset 0 0 0 1px var(--green); }
.tile.is-wrong { border-color: var(--coral); background: var(--coral-soft); }
.tile.is-done { opacity: .28; border-style: dashed; }
.match__foot { display: flex; justify-content: space-between; align-items: center; font-size: 14px; color: var(--muted); }

.done { text-align: center; padding: 48px 20px; display: grid; gap: 12px; justify-items: center; }
.done h3 { margin: 0; color: var(--brand-ink); font-size: 24px; }
.done p { margin: 0; color: var(--muted); }

/* download */
.dl { position: relative; }
.dl__menu { position: absolute; right: 0; top: calc(100% + 6px); background: var(--surface); border: 1px solid var(--line); border-radius: 12px; padding: 12px; width: 270px; z-index: 30; box-shadow: 0 12px 32px var(--shadow); }
.dl__menu p { font-size: 13px; color: var(--muted); margin: 0 0 10px; }
.dl__menu button { width: 100%; display: flex; justify-content: space-between; border: 1px solid var(--line); background: var(--surface); border-radius: 8px; padding: 9px 12px; font-weight: 700; margin-top: 6px; font-size: 14px; }
.dl__menu button span { font-weight: 500; color: var(--muted); font-size: 12.5px; }
.dl__menu button:hover { border-color: var(--brand-ink); }

/* pos page */
.chips { display: flex; gap: 6px; flex-wrap: wrap; }
.chip { border: 1px solid var(--line); background: var(--surface); border-radius: 999px; padding: 6px 14px; font-weight: 700; font-size: 13.5px; color: var(--muted); text-decoration: none; }
.chip[aria-pressed="true"], .chip[aria-current="page"] { background: var(--green); border-color: var(--brand-ink); color: var(--on-primary); }
.toolbar { display: flex; gap: 12px; align-items: center; flex-wrap: wrap; margin-bottom: 18px; }
.toolbar .grow { flex: 1; }
.vt { width: 100%; border-collapse: collapse; background: var(--surface); border: 1px solid var(--line); border-radius: var(--r); overflow: hidden; }
.vt th { text-align: left; font-size: 12.5px; color: var(--muted); font-weight: 600; padding: 10px 14px; background: var(--bg); border-bottom: 1px solid var(--line); }
.vt td { padding: 10px 14px; border-bottom: 1px solid var(--line); vertical-align: top; }
.vt tr:last-child td { border-bottom: 0; }
.vt .jp { font-size: 19px; font-weight: 700; line-height: 1.8; }
.vt .col-c { font-family: var(--jp); font-size: 16px; line-height: 1.9; }
.vt .muted { color: var(--muted); font-size: 13.5px; }
.lvtag { display: inline-block; font-weight: 800; font-size: 12px; border-radius: 6px; padding: 1px 7px; color: var(--on-primary); background: var(--green); }
.lvtag[data-lv="n5"] { background: var(--mint); color: var(--green-deep); }
.lvtag[data-lv="n4"] { background: var(--step-4); }
.lvtag[data-lv="n3"] { background: var(--step-3); }
.lvtag[data-lv="n1"] { background: var(--green-deep); }
.lvtag[data-lv="nganh"] { background: var(--coral); color: #fff; }
.packs { display: flex; gap: 6px; flex-wrap: wrap; }

.posrows { list-style: none; padding: 0; margin: 0; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); column-gap: 40px; }
.posrows a { display: grid; grid-template-columns: minmax(0, 1fr) 150px; gap: 16px; padding: 18px 4px; border-bottom: 1px solid var(--line); text-decoration: none; align-items: center; }
.posrows a:hover { background: linear-gradient(90deg, var(--mint-soft), transparent); }
.lvbar { display: flex; height: 8px; border-radius: 4px; overflow: hidden; background: var(--line); }
.lvbar i { display: block; height: 100%; }

.empty { text-align: center; padding: 56px 20px; border: 1px dashed var(--line); border-radius: var(--r); background: var(--surface); display: grid; gap: 10px; justify-items: center; }
.empty h3 { margin: 0; color: var(--brand-ink); }
.empty p { margin: 0; color: var(--muted); max-width: 32em; }

/* footer */
.foot { background: var(--green); color: rgba(255,255,255,.7); margin-top: 0; }
.foot__in { max-width: var(--wrap); margin: 0 auto; padding: 36px var(--gut); display: flex; justify-content: space-between; gap: 32px; flex-wrap: wrap; }
.foot .brand__minh { color: rgba(255,255,255,.6); }
.foot .brand__dok { color: var(--on-primary); }
.foot p { max-width: 30em; font-size: 14px; margin: 12px 0 0; }
.foot__nav { display: flex; gap: 20px; align-items: flex-start; flex-wrap: wrap; }
.foot__nav a { color: rgba(255,255,255,.8); text-decoration: none; font-weight: 600; font-size: 14px; }
.foot__nav a:hover { color: var(--on-primary); }

.toast { position: fixed; left: 50%; bottom: 24px; transform: translate(-50%, 20px); background: var(--green-deep); color: var(--on-primary); padding: 10px 16px; border-radius: 10px; font-size: 14px; font-weight: 600; opacity: 0; pointer-events: none; transition: opacity .2s, transform .2s; z-index: 80; }
.toast.show { opacity: 1; transform: translate(-50%, 0); }
.tabbar { display: none; }
.only-m { display: none; }


/* ---------- giáo trình ---------- */
.btn--mint { background: var(--mint); color: var(--green-deep); }
.btn--mint:hover { background: color-mix(in srgb, var(--mint) 82%, #fff); }
.books { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 22px; }
.book { display: grid; grid-template-columns: 74px minmax(0, 1fr); min-height: 100%; text-decoration: none; color: inherit; background: var(--surface); border: 1px solid var(--line); border-radius: var(--r); overflow: hidden; transition: transform .18s, box-shadow .18s, border-color .18s; }
.book:hover { transform: translateY(-3px); box-shadow: 0 14px 30px -18px var(--shadow); border-color: var(--mint); }
.book__spine { background: var(--green); display: flex; justify-content: center; padding-top: 18px; position: relative; }
.book__spine::after { content: ""; position: absolute; left: 10px; top: 0; bottom: 0; width: 2px; background: rgba(255,255,255,.14); }
.book__spine span { writing-mode: vertical-rl; font-family: var(--jp); font-weight: 800; font-size: 26px; color: var(--mint); letter-spacing: .08em; }
.book--off .book__spine { background: var(--soon-bg); }
.book--off .book__spine span { color: var(--muted); }
.book__body { display: flex; flex-direction: column; gap: 6px; padding: 20px 22px 18px; }
.book__lv { font-size: 12px; font-weight: 800; letter-spacing: .06em; color: var(--coral-ink); }
.book__name { font-size: 20px; color: var(--brand-ink); line-height: 1.25; }
.book__ja { font-family: var(--jp); font-size: 15px; color: var(--muted); }
.book__blurb { color: var(--hero-text); font-size: 14.5px; }
.book__foot { margin-top: auto; padding-top: 12px; display: grid; grid-template-columns: 1fr auto; gap: 6px 12px; font-size: 13px; color: var(--muted); }
.book__foot b { color: var(--ink); }
.book__foot .meter { grid-column: 1 / -1; }
.gt-note { margin: 28px 0 0; padding: 14px 16px; border-left: 3px solid var(--mint); background: var(--mint-soft); border-radius: 0 var(--r-sm) var(--r-sm) 0; color: var(--hero-text); font-size: 14px; max-width: 60em; }
.lessons { list-style: none; margin: 0 0 36px; padding: 0; display: grid; grid-template-columns: repeat(auto-fill, minmax(168px, 1fr)); gap: 12px; }
.lesson { position: relative; display: grid; grid-template-columns: auto minmax(0, 1fr); grid-template-rows: auto auto auto; gap: 2px 12px; align-items: center; padding: 14px 14px 12px; text-decoration: none; color: inherit; background: var(--surface); border: 1px solid var(--line); border-radius: 12px; height: 100%; transition: border-color .15s, transform .15s; }
.lesson:hover { border-color: var(--brand-ink); transform: translateY(-2px); }
.lesson__no { grid-row: 1 / 3; font-size: 30px; font-weight: 800; color: var(--brand-ink); line-height: 1; min-width: 1.4em; letter-spacing: -.03em; }
.lesson__t { font-weight: 700; font-size: 14.5px; line-height: 1.3; }
.lesson__t small { display: block; font-weight: 500; font-size: 12.5px; color: var(--muted); margin-top: 2px; }
.lesson__n { font-size: 12px; color: var(--muted); }
.lesson .meter { grid-column: 1 / -1; margin-top: 8px; height: 4px; }
.lesson--next { border-color: var(--mint); box-shadow: inset 0 0 0 1px var(--mint); }
.lesson--next::before { content: "Tiếp theo"; position: absolute; top: -9px; right: 10px; font-size: 10.5px; font-weight: 800; background: var(--mint); color: var(--green-deep); padding: 1px 7px; border-radius: 5px; }
.lesson--done .lesson__no { color: var(--mint); }
.lesson--done::after { content: "✓"; position: absolute; top: 10px; right: 12px; font-weight: 800; color: var(--mint); }
.unitnav { display: flex; justify-content: space-between; gap: 12px; margin-top: 12px; }
.unitnav__a { color: var(--band-sub); font-size: 13.5px; font-weight: 700; text-decoration: none; border-bottom: 1px solid transparent; }
.unitnav__a:hover { color: var(--on-primary); border-color: var(--mint); }
@media (max-width: 760px) {
  .books { grid-template-columns: minmax(0, 1fr); gap: 14px; }
  .book { grid-template-columns: 54px minmax(0, 1fr); }
  .book__spine span { font-size: 21px; }
  .book__body { padding: 16px 16px 14px; }
  .lessons { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
  .lesson { padding: 12px 10px 10px; gap: 2px 8px; }
  .lesson__no { font-size: 24px; }
  .lesson--done::after { top: 6px; right: 8px; }
}

/* ---------- chủ đề màu ---------- */
:root[data-theme="ai"] {
  --green: #233a63; --green-deep: #172846; --mint: #5fa8d8; --mint-soft: #e8eef6;
  --coral: #e0533d; --coral-soft: #fdebe7; --cream: #f1f3f7; --bg: #f8f9fb; --line: #d8dee8;
  --muted: #5f6b7d; --grid: rgba(95,168,216,.17); --band-sub: #b9c7de; --band-text: #e8edf6; --hero-text: #39465a; --shadow: rgba(23,40,70,.16);
}
:root[data-theme="sakura"] {
  --green: #7a2e4a; --green-deep: #5b1f36; --mint: #ee8fae; --mint-soft: #fbedf2;
  --coral: #d23b3b; --coral-soft: #fdeaea; --cream: #fbf1f2; --bg: #fdf9f9; --line: #ecdbe0;
  --muted: #7a6870; --grid: rgba(238,143,174,.2); --band-sub: #e6c3cf; --band-text: #fbeef2; --hero-text: #4f3b43; --shadow: rgba(91,31,54,.16);
}
:root[data-theme="matcha"] {
  --green: #3f5a22; --green-deep: #2d4316; --mint: #a3c45a; --mint-soft: #eef3e1;
  --coral: #d9622b; --coral-soft: #fcece2; --cream: #f4f2e4; --bg: #f9faf4; --line: #dfe3cf;
  --muted: #66705a; --grid: rgba(163,196,90,.2); --band-sub: #cbd8b2; --band-text: #eef3e4; --hero-text: #3d4632; --shadow: rgba(45,67,22,.16);
}
:root[data-theme="momiji"] {
  --green: #7a2f14; --green-deep: #58200b; --mint: #f2a04a; --mint-soft: #fbeedd;
  --coral: #c8102e; --coral-soft: #fbe5e8; --cream: #faf0e3; --bg: #fdf9f4; --line: #eedfcd;
  --muted: #7b6757; --grid: rgba(242,160,74,.2); --band-sub: #e8c6ad; --band-text: #fbeee4; --hero-text: #4d3a2c; --shadow: rgba(88,32,11,.16);
}
:root[data-theme="yoru"] {
  --green: #134e4c; --green-deep: #0c3634; --mint: #3fd1c0; --mint-soft: #17302f;
  --coral: #ff6b6b; --coral-soft: #3a1f22; --cream: #101c1f; --bg: #0b1416; --line: #243538;
  --ink: #e4eeee; --muted: #93a7a9; --white: #16242a; --surface: #14222a; --on-primary: #f2fbfa;
  --brand-ink: #7fe3d6; --band-text: #e2f1ef; --band-sub: #a7c8c4; --hero-text: #c3d3d4; --coral-ink: #ff9a9a;
  --soon-bg: #1d2c30; --header-bg: rgba(14,24,27,.94); --shadow: rgba(0,0,0,.45); --grid: rgba(63,209,192,.09);
  --step-4: color-mix(in srgb, #3fd1c0 45%, #134e4c); --step-3: color-mix(in srgb, #3fd1c0 22%, #134e4c);
  color-scheme: dark;
}
:root[data-theme="yoru"] .say { background: rgba(20,34,42,.8); }
:root[data-theme="yoru"] .step[data-lv="n5"] { color: #06201f; }
:root[data-theme="yoru"] .lvtag[data-lv="n5"] { color: #06201f; }

.themes { position: relative; }
.theme-btn { display: inline-flex; align-items: center; gap: 6px; border: 1px solid var(--line); background: var(--surface); border-radius: 999px; padding: 5px 10px 5px 6px; font-weight: 600; font-size: 13px; color: var(--ink); }
.theme-btn:hover { border-color: var(--brand-ink); }
.theme-dot { width: 22px; height: 22px; border-radius: 50%; background: conic-gradient(var(--green) 0 50%, var(--mint) 0 75%, var(--coral) 0); box-shadow: inset 0 0 0 2px var(--surface); border: 1px solid var(--line); }
.theme-menu { position: absolute; right: 0; top: calc(100% + 8px); width: 260px; background: var(--surface); border: 1px solid var(--line); border-radius: 14px; padding: 10px; box-shadow: 0 14px 36px var(--shadow); z-index: 70; }
.theme-menu p { margin: 2px 6px 8px; font-size: 12.5px; color: var(--muted); font-weight: 600; }
.theme-opt { width: 100%; display: grid; grid-template-columns: 44px minmax(0, 1fr) auto; gap: 10px; align-items: center; border: 0; background: none; border-radius: 10px; padding: 7px 8px; text-align: left; color: var(--ink); }
.theme-opt:hover { background: var(--mint-soft); }
.theme-opt[aria-checked="true"] { background: var(--mint-soft); box-shadow: inset 0 0 0 1px var(--brand-ink); }
.theme-opt .sw { display: flex; height: 26px; border-radius: 7px; overflow: hidden; border: 1px solid rgba(0,0,0,.08); }
.theme-opt .sw i { flex: 1; }
.theme-opt b { font-size: 14px; display: block; line-height: 1.2; }
.theme-opt small { color: var(--muted); font-size: 12px; }
.theme-opt .ja { font-family: var(--jp); font-weight: 800; font-size: 18px; color: var(--brand-ink); }
.brand__mark .m-back { fill: var(--mint); }
.brand__mark .m-front { fill: var(--green); }
.brand__mark .m-dot { fill: var(--coral); }
@media (max-width: 560px) {
  .theme-btn span.lbl { display: none; }
  .theme-btn { padding: 4px; }
  .toggles { gap: 5px; }
}

/* ---------- tablet & phone ---------- */
@media (max-width: 1000px) {
  .study__grid { grid-template-columns: minmax(0, 1fr); }
  .aside { position: fixed; inset: auto 0 0 0; top: auto; max-height: 72vh; border-radius: 18px 18px 0 0; z-index: 60; transform: translateY(calc(100% + 90px)); visibility: hidden; transition: transform .25s ease, visibility 0s .25s; box-shadow: 0 -12px 40px var(--shadow); }
  .aside.open { transform: none; visibility: visible; transition: transform .25s ease; }
  .only-m { display: inline-flex; }
  .scrim { position: fixed; inset: 0; background: rgba(0,0,0,.4); z-index: 55; }
}
@media (max-width: 860px) {
  .nav { display: none; }
  .tabbar { display: grid; grid-template-columns: repeat(5, 1fr); position: fixed; left: 0; right: 0; bottom: 0; z-index: 50; background: var(--surface); border-top: 1px solid var(--line); padding-bottom: env(safe-area-inset-bottom); }
  .tabbar a { display: flex; flex-direction: column; align-items: center; gap: 1px; padding: 7px 0 8px; text-decoration: none; font-size: 11px; white-space: nowrap; font-weight: 700; color: var(--muted); }
  .tabbar a span { font-family: var(--jp); font-size: 18px; font-weight: 800; line-height: 1.2; }
  .tabbar a[aria-current="page"] { color: var(--brand-ink); }
  .tabbar a[aria-current="page"] span { color: var(--coral); }
  body { padding-bottom: calc(62px + env(safe-area-inset-bottom)); }
  .toast { bottom: 84px; }
  .aside { bottom: calc(62px + env(safe-area-inset-bottom)); }
  .hero__in { grid-template-columns: minmax(0, 1fr); gap: 8px; padding-top: 40px; }
  .hero__copy { padding-bottom: 20px; }
  .stairs { height: 230px; gap: 4px; }
  .step { padding: 10px 8px 12px; }
  .step__n { font-size: 11.5px; }
  .step__st { font-size: 10.5px; }
  .sec { padding: 48px 0; }
  .sec__head, .demo { grid-template-columns: minmax(0, 1fr); gap: 16px; }
  .ways { grid-template-columns: minmax(0, 1fr); }
  .way, .way + .way { padding: 20px 0; border-left: 0; border-bottom: 1px solid var(--line); }
  .rows, .posrows { grid-template-columns: minmax(0, 1fr); }
  .band__in { grid-template-columns: minmax(0, 1fr); gap: 14px; padding-top: 28px; padding-bottom: 28px; }
  .band__meta { text-align: left; }
  .band--compact .band__in { padding-top: 18px; padding-bottom: 18px; gap: 10px; }
  .band--compact p { display: none; }
  .band--compact .crumb { margin-bottom: 4px; }
  .vt thead { display: none; }
  .vt, .vt tbody, .vt tr, .vt td { display: block; width: 100%; }
  .vt tr { padding: 10px 14px; border-bottom: 1px solid var(--line); }
  .vt td { border: 0; padding: 2px 0; }
}
@media (max-width: 560px) {
  .top__in { height: 58px; gap: 10px; }
  .brand__mark { width: 34px; height: 34px; }
  .brand__dok { font-size: 18px; }
  .brand__minh { font-size: 11px; }
  .tg { padding: 5px 6px 5px 9px; gap: 6px; font-size: 12px; }
  .tg__ja { font-size: 14px; }
  .tg__sw { width: 26px; height: 16px; }
  .tg__sw::after { width: 12px; height: 12px; }
  .tg[aria-pressed="true"] .tg__sw::after { transform: translateX(10px); }
  .step__ja { display: none; }
  .step__st { display: none; }
  .step__n { font-size: 10.5px; line-height: 1.25; }
  .step[data-lv="n5"] { height: 34%; }
  .modes { width: 100%; overflow-x: auto; }
  .modes button { flex: 1; padding: 8px 8px; font-size: 13px; justify-content: center; }
  .modes button .jp { display: none; }
  .study__stats { margin-left: 0; width: 100%; justify-content: space-between; }
  .card__face, .quiz, .match { padding: 16px 16px 18px; }
  .opts { grid-template-columns: minmax(0, 1fr); }
  .ctl { grid-template-columns: 44px 1fr 1fr 44px; gap: 8px; }
  .ctl .btn--coral, .ctl .btn--primary { justify-self: stretch; padding: 11px 8px; white-space: nowrap; }
  .ctl .nav-btn.prev { order: -1; }
  .ctl .btn--primary { order: 1; }
  .ctl .nav-btn:not(.prev) { order: 2; }
  .card { min-height: 320px; }
  .kbd-hint { display: none; }
  .tile.jp-tile { font-size: 16px; }
  .tile { font-size: 13.5px; padding: 8px 10px; }
}
@media (prefers-reduced-motion: reduce) {
  .verdict__icon path { stroke-dashoffset: 0; }
  *, *::before, *::after { transition: none !important; animation: none !important; scroll-behavior: auto !important; }
}

/* lộ trình học – ôn theo bài/Unit */
.btn--ghost-l { background: transparent; border-color: color-mix(in srgb, var(--on-primary) 45%, transparent); color: var(--on-primary); }
.btn--ghost-l:hover { border-color: var(--mint); }
.band__meta .band__sub { display: block; margin-top: 6px; }
.plan-sec { padding-bottom: 8px; }
.plan { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 12px; }
.plan__c { display: flex; flex-direction: column; gap: 4px; align-items: flex-start; padding: 16px; background: var(--surface); border: 1px solid var(--line); border-radius: 12px; }
.plan__c > span:not(.plan__k) { color: var(--muted); font-size: 13.5px; }
.plan__c b { font-size: 18px; line-height: 1.25; }
.plan__c .btn { margin-top: auto; }
.plan__c > .btn { margin-top: 10px; }
.plan__k { font-size: 11.5px; font-weight: 800; letter-spacing: .06em; text-transform: uppercase; color: var(--brand-ink); }
.plan__c--new { border-color: var(--mint); box-shadow: inset 0 0 0 1px var(--mint); }
.plan__c--due { border-color: color-mix(in srgb, var(--coral) 55%, var(--line)); }
.plan__c--due .plan__k { color: var(--coral-ink); }
.plan__list { list-style: none; margin: 4px 0 0; padding: 0; display: flex; flex-direction: column; gap: 2px; width: 100%; }
.plan__list a { display: flex; justify-content: space-between; gap: 8px; font-weight: 700; font-size: 14px; color: inherit; text-decoration: none; padding: 4px 0; border-bottom: 1px dashed var(--line); }
.plan__list a:hover { color: var(--coral-ink); }
.plan__list small { font-weight: 500; color: var(--muted); }
.lesson__st { order: 9; grid-column: 1 / -1; font-size: 11.5px; font-weight: 700; margin-top: 6px; color: var(--muted); }
.lesson__st--due { color: var(--coral-ink); }
.lesson__st--solid { color: var(--brand-ink); }
.lesson--due { border-color: color-mix(in srgb, var(--coral) 60%, var(--line)); box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--coral) 40%, transparent); }
.lesson--due::after { content: "↺"; color: var(--coral); }
.unitplan { margin: 14px 0 0; padding: 10px 14px; border-radius: 10px; background: color-mix(in srgb, var(--on-primary) 10%, transparent); color: var(--band-sub); font-size: 14px; max-width: 46em; }
.unitplan b { color: var(--on-primary); }
@media (max-width: 900px) { .plan { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 520px) { .plan { grid-template-columns: 1fr; } .plan__c { padding: 14px; } }
