/* ============ Suara Kembali — Design System ============ */
:root {
  --bg: #FBF5EE;
  --ink: #1D2633;
  --muted: #5E6878;
  --primary: #0FA391;
  --primary-2: #0B7A6D;
  --accent: #FF6F61;
  --accent-2: #FF9A62;
  --success: #22A35A;
  --gold: #FFB938;
  --glass: rgba(255, 255, 255, 0.72);
  --glass-border: rgba(255, 255, 255, 0.9);
  --line: rgba(29, 38, 51, 0.08);
  --shadow-sm: 0 2px 8px rgba(40, 30, 20, 0.06);
  --shadow: 0 10px 30px -10px rgba(60, 40, 20, 0.18), 0 2px 6px rgba(60, 40, 20, 0.05);
  --shadow-lg: 0 24px 60px -18px rgba(60, 40, 20, 0.28);
  --r: 26px;
  --r-sm: 16px;
  --ease: cubic-bezier(.2, .8, .2, 1);
}
html { font-size: 18px; }
html[data-textsize="large"] { font-size: 20px; }
html[data-textsize="xlarge"] { font-size: 23px; }

* { box-sizing: border-box; margin: 0; padding: 0; }
body {
  font-family: 'Nunito', system-ui, -apple-system, sans-serif;
  color: var(--ink);
  background: var(--bg);
  min-height: 100vh;
  line-height: 1.45;
  -webkit-font-smoothing: antialiased;
  padding-bottom: calc(6.2rem + env(safe-area-inset-bottom));
  overflow-x: hidden;
}
body.in-session { padding-bottom: 1.5rem; }
button { font: inherit; color: inherit; cursor: pointer; border: 0; background: none; -webkit-tap-highlight-color: transparent; }
button:disabled { opacity: .45; cursor: not-allowed; }
:focus-visible { outline: 4px solid rgba(15, 163, 145, .45); outline-offset: 3px; border-radius: 12px; }
.muted { color: var(--muted); }
.small { font-size: .85rem; }
.center { text-align: center; }

/* Background */
.bg-blobs { position: fixed; inset: 0; z-index: -1; overflow: hidden; pointer-events: none; }
.bg-blobs span { position: absolute; border-radius: 50%; filter: blur(70px); opacity: .55; animation: drift 22s ease-in-out infinite alternate; }
.bg-blobs span:nth-child(1) { width: 55vw; height: 55vw; background: #FFD3BF; top: -18vw; right: -12vw; }
.bg-blobs span:nth-child(2) { width: 45vw; height: 45vw; background: #BDEFE6; bottom: -15vw; left: -14vw; animation-delay: -6s; }
.bg-blobs span:nth-child(3) { width: 30vw; height: 30vw; background: #E5D9FF; top: 40%; left: 45%; animation-delay: -12s; opacity: .4; }
@keyframes drift { to { transform: translate(4vw, 3vw) scale(1.08); } }

.glass {
  background: var(--glass);
  backdrop-filter: blur(18px) saturate(1.3);
  -webkit-backdrop-filter: blur(18px) saturate(1.3);
  border: 1px solid var(--glass-border);
  box-shadow: var(--shadow);
  border-radius: var(--r);
}

/* Header */
.app-header { max-width: 980px; margin: 0 auto; padding: 1rem 1.2rem .4rem; }
.brand { display: flex; align-items: center; gap: .7rem; text-align: left; }
.brand-logo { width: 2.6rem; height: 2.6rem; filter: drop-shadow(0 6px 10px rgba(15, 163, 145, .3)); }
.brand-name { font-size: 1.35rem; font-weight: 900; letter-spacing: -.02em; line-height: 1.1;
  background: linear-gradient(90deg, var(--primary-2), var(--primary)); -webkit-background-clip: text; background-clip: text; color: transparent; }
.brand-tag { font-size: .78rem; color: var(--muted); font-weight: 700; }
body.in-session .app-header { display: none; }

.app-main { max-width: 980px; margin: 0 auto; padding: .6rem 1.2rem 1rem; }
.view-enter > * { animation: rise .5s var(--ease) both; }
.view-enter > *:nth-child(2) { animation-delay: .05s; }
.view-enter > *:nth-child(3) { animation-delay: .1s; }
.view-enter > *:nth-child(4) { animation-delay: .15s; }
@keyframes rise { from { opacity: 0; transform: translateY(14px); } }

/* Buttons */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: .45rem;
  min-height: 3.1rem; padding: .7rem 1.3rem; border-radius: 999px;
  font-weight: 800; font-size: 1rem; letter-spacing: .01em;
  transition: transform .18s var(--ease), box-shadow .2s, background .2s, filter .2s;
  user-select: none;
}
.btn:active { transform: scale(.96); }
.btn-lg { min-height: 3.6rem; font-size: 1.1rem; padding: .8rem 1.6rem; }
.btn-xl { min-height: 4.4rem; font-size: 1.35rem; padding: 1rem 2.6rem; }
.btn-sm { min-height: 2.5rem; font-size: .9rem; padding: .4rem 1rem; }
.btn-wide { width: 100%; }
.btn-primary { color: #fff; background: linear-gradient(135deg, #19C3AE, var(--primary-2)); box-shadow: 0 10px 22px -8px rgba(11, 122, 109, .6); }
.btn-primary:hover { filter: brightness(1.06); box-shadow: 0 14px 28px -8px rgba(11, 122, 109, .7); }
.btn-success { color: #fff; background: linear-gradient(135deg, #3CCB7A, #1E9650); box-shadow: 0 10px 22px -8px rgba(30, 150, 80, .55); }
.btn-success:hover { filter: brightness(1.06); }
.btn-soft { background: #fff; box-shadow: var(--shadow-sm); border: 1.5px solid var(--line); }
.btn-soft:hover { border-color: rgba(15, 163, 145, .4); transform: translateY(-1px); }
.btn-soft.active { background: #E3F7F3; border-color: var(--primary); color: var(--primary-2); }
.btn-ghost { background: rgba(255, 255, 255, .55); border: 1.5px solid var(--line); }
.btn-ghost:hover { background: #fff; }
.btn-ghost.danger { color: #C0392B; margin: .5rem auto 0; display: flex; }
.glow { animation: glow 1.4s ease-in-out infinite; border-color: var(--gold) !important; }
@keyframes glow { 50% { box-shadow: 0 0 0 8px rgba(255, 185, 56, .3); } }
.pop { animation: pop .5s var(--ease); }
@keyframes pop { 0% { transform: scale(.85); } 60% { transform: scale(1.06); } }

.icon-btn { width: 3rem; height: 3rem; flex: none; border-radius: 50%; background: #fff; box-shadow: var(--shadow-sm); font-size: 1.3rem; font-weight: 900; display: grid; place-items: center; border: 1.5px solid var(--line); transition: transform .15s; }
.icon-btn:hover { transform: scale(1.06); }

/* Hero */
.hero { display: grid; grid-template-columns: 1.4fr 1fr; gap: 1.5rem; padding: 1.8rem; position: relative; overflow: hidden; }
.hero::after { content: ''; position: absolute; width: 280px; height: 280px; right: -80px; top: -90px; border-radius: 50%; background: radial-gradient(circle, rgba(25, 195, 174, .25), transparent 70%); }
.eyebrow { font-weight: 800; color: var(--primary-2); font-size: 1.05rem; }
.hero-title { font-size: 2rem; line-height: 1.15; font-weight: 900; letter-spacing: -.02em; margin: .3rem 0 .5rem; }
.hero-text .btn { margin-top: 1.1rem; }
.hero-stats { display: grid; gap: .7rem; align-content: center; position: relative; z-index: 1; }
.stat { display: flex; flex-direction: column; background: rgba(255, 255, 255, .8); padding: .7rem 1rem; border-radius: var(--r-sm); border: 1px solid var(--line); }
.stat-num { font-size: 1.6rem; font-weight: 900; line-height: 1.1; }
.stat-num small { font-size: .7em; color: var(--muted); font-weight: 800; margin-left: 2px; }
.stat-label { font-size: .85rem; color: var(--muted); font-weight: 700; }
.stat-fire .stat-num { color: #E8590C; }

.section-title { font-size: 1.35rem; font-weight: 900; margin: 1.6rem 0 .8rem; letter-spacing: -.01em; }
.section-title.small { font-size: 1.05rem; margin: 1.2rem 0 .6rem; color: var(--muted); }

/* Module cards */
.module-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); gap: 1rem; }
.module-card {
  position: relative; display: flex; align-items: center; gap: 1rem; text-align: left;
  padding: 1.15rem 1.2rem; min-height: 6rem; border-radius: var(--r);
  background: rgba(255, 255, 255, .82); border: 1px solid #fff; box-shadow: var(--shadow);
  transition: transform .25s var(--ease), box-shadow .25s;
  animation: rise .5s var(--ease) both; animation-delay: calc(var(--i) * 60ms + .1s);
  overflow: hidden;
}
.module-card::before { content: ''; position: absolute; inset: 0 auto 0 0; width: 6px; background: var(--grad); }
.module-card:hover { transform: translateY(-4px); box-shadow: var(--shadow-lg); }
.module-card:active { transform: scale(.98); }
.module-icon { width: 4rem; height: 4rem; flex: none; border-radius: 20px; background: var(--grad); display: grid; place-items: center; font-size: 2rem; box-shadow: 0 8px 18px -8px rgba(0, 0, 0, .35); transition: transform .3s var(--ease); }
.module-card:hover .module-icon { transform: rotate(-6deg) scale(1.06); }
.module-text { display: flex; flex-direction: column; flex: 1; }
.module-title { font-size: 1.15rem; font-weight: 900; }
.module-sub { font-size: .9rem; color: var(--muted); font-weight: 600; }
.badge-done { position: absolute; top: .55rem; right: 2.4rem; font-size: .72rem; font-weight: 800; color: var(--success); background: #E4F7EC; padding: .15rem .55rem; border-radius: 999px; }
.chev { font-size: 2rem; color: #C3C8D0; font-weight: 300; }

.notice { margin-top: 1.2rem; padding: 1rem 1.2rem; border-radius: var(--r-sm); background: #FFF4DB; border: 1px solid #FFE1A1; font-weight: 600; }
.disclaimer { margin: 1.6rem auto 0; text-align: center; font-size: .85rem; color: var(--muted); max-width: 640px; }

/* Level picker */
.level-head { display: flex; align-items: center; gap: 1rem; padding: .4rem 0 .2rem; }
.level-icon { width: 4.2rem; height: 4.2rem; border-radius: 22px; background: var(--grad); display: grid; place-items: center; font-size: 2.2rem; box-shadow: 0 10px 22px -10px rgba(0, 0, 0, .4); flex: none; }
.level-title { font-size: 1.7rem; font-weight: 900; line-height: 1.1; }
.tip { margin-top: 1rem; padding: 1rem 1.2rem; background: rgba(255, 255, 255, .7); border-left: 5px solid var(--gold); border-radius: var(--r-sm); font-weight: 600; }
.level-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(290px, 1fr)); gap: .9rem; }
.level-card { display: flex; align-items: center; gap: 1rem; text-align: left; padding: 1rem 1.1rem; min-height: 5.4rem; border-radius: 22px; background: rgba(255, 255, 255, .85); border: 1px solid #fff; box-shadow: var(--shadow); transition: transform .25s var(--ease), box-shadow .25s; animation: rise .45s var(--ease) both; animation-delay: calc(var(--i) * 50ms); }
.level-card:hover { transform: translateY(-3px); box-shadow: var(--shadow-lg); }
.level-emoji { font-size: 2.2rem; width: 3.4rem; text-align: center; }
.level-text { flex: 1; display: flex; flex-direction: column; }
.level-name { font-weight: 900; font-size: 1.08rem; }
.level-desc { color: var(--muted); font-size: .9rem; font-weight: 600; }
.play-pill { flex: none; padding: .45rem .9rem; border-radius: 999px; background: var(--grad); color: #fff; font-weight: 900; font-size: .85rem; text-shadow: 0 1px 2px rgba(0, 0, 0, .2); }

/* Practice */
.practice { display: flex; flex-direction: column; gap: 1rem; max-width: 760px; margin: 0 auto; padding-top: .6rem; }
.session-bar { display: flex; align-items: center; gap: .9rem; }
.session-info { flex: 1; min-width: 0; }
.session-title { font-weight: 800; font-size: .92rem; color: var(--muted); display: block; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; margin-bottom: .35rem; }
.session-count { font-weight: 900; font-size: 1.4rem; }
.session-count small { color: var(--muted); font-size: .7em; }
.progress { height: 10px; border-radius: 999px; background: rgba(29, 38, 51, .08); overflow: hidden; }
.progress.thick { height: 12px; }
.progress-fill { height: 100%; border-radius: inherit; background: var(--grad, linear-gradient(90deg, #19C3AE, #0B7A6D)); transition: width .6s var(--ease); }

.stage { position: relative; padding: 1.6rem 1.4rem 1.4rem; text-align: center; display: flex; flex-direction: column; align-items: center; gap: .5rem; overflow: hidden; transition: box-shadow .4s, transform .4s; }
.stage::before { content: ''; position: absolute; inset: 0 0 auto 0; height: 7px; background: var(--grad); }
.stage.success { box-shadow: 0 0 0 4px rgba(34, 163, 90, .35), var(--shadow-lg); animation: pop .6s var(--ease); }
.instruction { font-weight: 800; color: var(--muted); font-size: 1.05rem; text-transform: uppercase; letter-spacing: .08em; }
.stage-emoji { font-size: clamp(5rem, 22vw, 8rem); line-height: 1.1; filter: drop-shadow(0 12px 18px rgba(0, 0, 0, .15)); animation: float 3.5s ease-in-out infinite; }
@keyframes float { 50% { transform: translateY(-8px); } }
.target { font-weight: 900; letter-spacing: .01em; line-height: 1.1; word-break: break-word; }
.target.xl { font-size: clamp(5rem, 24vw, 8.5rem); letter-spacing: .06em; }
.target.lg { font-size: clamp(3.4rem, 15vw, 5.5rem); letter-spacing: .04em; }
.target.md { font-size: clamp(2.4rem, 9vw, 3.6rem); }
.target.sm { font-size: clamp(1.8rem, 6vw, 2.6rem); }
.target.reveal { animation: pop .55s var(--ease); }
.mystery { color: #C5CBD3; letter-spacing: .2em; }
.w { transition: color .3s, background .3s; border-radius: 10px; padding: 0 .08em; }
.w.ok { color: var(--success); }
.w.miss { color: #E0573F; text-decoration: underline wavy rgba(224, 87, 63, .5); text-underline-offset: 6px; }
.target-sub { font-size: 1.3rem; font-weight: 800; color: var(--primary-2); letter-spacing: .1em; }
.mouth-hint { background: #FFF3E6; color: #9A4A14; border-radius: 14px; padding: .55rem .9rem; font-weight: 700; font-size: .98rem; max-width: 520px; }
.hints { display: flex; flex-direction: column; gap: .45rem; width: 100%; max-width: 540px; }
.hint { background: #FFF8E1; border: 1.5px solid #FFE08A; border-radius: 14px; padding: .6rem .9rem; font-weight: 700; animation: rise .4s var(--ease); }

.reading { width: 100%; text-align: left; }
.reading-title { font-size: 1.2rem; font-weight: 900; margin-bottom: .6rem; text-align: center; }
.reading-text { font-size: 1.55rem; line-height: 1.8; font-weight: 700; }
.sent { color: #A9B0BA; transition: color .3s; }
.sent.done { color: #6FBF94; }
.sent.current { color: var(--ink); background: linear-gradient(transparent 55%, rgba(255, 199, 95, .55) 55%); font-size: 1.15em; font-weight: 900; }

.tools { display: flex; gap: .6rem; justify-content: center; flex-wrap: wrap; }

.mic-area { display: flex; flex-direction: column; align-items: center; gap: .5rem; padding: .3rem 0; }
.mic-btn { position: relative; width: 7.2rem; height: 7.2rem; border-radius: 50%; background: linear-gradient(145deg, var(--accent-2), var(--accent)); box-shadow: 0 18px 34px -12px rgba(255, 111, 97, .75), inset 0 -6px 12px rgba(0, 0, 0, .1); display: grid; place-items: center; transition: transform .2s var(--ease); }
.mic-btn:hover { transform: scale(1.05); }
.mic-btn:active { transform: scale(.95); }
.mic-svg { width: 3.2rem; height: 3.2rem; fill: #fff; position: relative; z-index: 1; }
.mic-ring { position: absolute; inset: 0; border-radius: 50%; border: 3px solid rgba(255, 111, 97, .5); opacity: 0; }
.mic-btn.listening { background: linear-gradient(145deg, #FF5E7E, #E8364F); }
.mic-btn.listening .mic-ring { animation: ripple 1.6s ease-out infinite; }
.mic-btn.listening .mic-ring.r2 { animation-delay: .8s; }
@keyframes ripple { 0% { transform: scale(1); opacity: .9; } 100% { transform: scale(1.8); opacity: 0; } }
.mic-label { font-weight: 800; color: var(--muted); }
.meter { display: flex; gap: 5px; height: 2rem; align-items: center; opacity: 0; transition: opacity .3s; }
.meter.active { opacity: 1; }
.meter i { width: 6px; height: 100%; border-radius: 4px; background: linear-gradient(var(--accent), var(--accent-2)); transform: scaleY(.2); transition: transform .08s; }
.meter.active i { animation: eq 1s ease-in-out infinite; animation-delay: calc(var(--n, 0) * 1s); }
.meter i:nth-child(odd) { --n: .15; } .meter i:nth-child(3n) { --n: .35; }
@keyframes eq { 50% { opacity: .7; } }

.feedback:empty { display: none; }
.fb { padding: 1rem 1.2rem; border-radius: var(--r-sm); text-align: center; display: flex; flex-direction: column; align-items: center; gap: .35rem; animation: rise .35s var(--ease); }
.fb.good { background: linear-gradient(135deg, #E3F8EC, #D2F4E8); border: 1.5px solid #9EE0BC; }
.fb.try { background: #FFF5EC; border: 1.5px solid #FFD7B5; }
.fb.listening { background: rgba(255, 255, 255, .7); border: 1.5px dashed var(--line); }
.fb-title { font-size: 1.35rem; font-weight: 900; }
.heard { font-size: 1.1rem; font-weight: 700; color: var(--muted); font-style: italic; }
.stars { font-size: 2.2rem; letter-spacing: .15em; }
.stars span, .big-stars span { color: #DDE1E6; display: inline-block; }
.stars span.on, .big-stars span.on { color: var(--gold); text-shadow: 0 4px 12px rgba(255, 185, 56, .5); animation: starIn .6s var(--ease) both; animation-delay: var(--d); }
@keyframes starIn { 0% { transform: scale(0) rotate(-90deg); } 70% { transform: scale(1.3) rotate(10deg); } }

.actions { display: flex; gap: .8rem; justify-content: center; flex-wrap: wrap; }
.actions .btn { flex: 1 1 200px; max-width: 360px; }
.actions .btn-wide { max-width: none; }

/* Mirror */
.mirror { position: relative; width: min(100%, 360px); aspect-ratio: 4/3; border-radius: 20px; overflow: hidden; margin-top: .6rem; box-shadow: var(--shadow); border: 4px solid #fff; }
.mirror video { width: 100%; height: 100%; object-fit: cover; transform: scaleX(-1); background: #222; }
.mirror-tag { position: absolute; left: .6rem; top: .6rem; background: rgba(0, 0, 0, .5); color: #fff; font-size: .8rem; font-weight: 800; padding: .2rem .6rem; border-radius: 999px; }

/* Oral */
.oral-stage { display: grid; grid-template-columns: 1.2fr 1fr; align-items: center; gap: 1rem; text-align: left; }
.oral-stage .mirror, .oral-stage .rep-dots { grid-column: 1 / -1; justify-self: center; }
.oral-main { display: flex; flex-direction: column; gap: .4rem; align-items: flex-start; }
.oral-stage .stage-emoji { font-size: clamp(4.5rem, 16vw, 6.5rem); }
.oral-stage.active .stage-emoji { animation: breathe 1.2s ease-in-out infinite; }
@keyframes breathe { 50% { transform: scale(1.12); } }
.oral-name { font-size: 1.8rem; font-weight: 900; line-height: 1.1; }
.oral-how { font-size: 1.15rem; font-weight: 600; }
.chip { display: inline-block; background: #fff; border: 1.5px solid var(--line); border-radius: 999px; padding: .3rem .8rem; font-weight: 800; font-size: .92rem; }
.timer { position: relative; width: min(100%, 220px); aspect-ratio: 1; justify-self: center; }
.ring { width: 100%; height: 100%; transform: rotate(-90deg); }
.ring-bg { fill: none; stroke: rgba(29, 38, 51, .08); stroke-width: 10; }
.ring-fg { fill: none; stroke: url(#none); stroke: #FF6F91; stroke-width: 10; stroke-linecap: round; transition: stroke-dashoffset 1s linear, stroke .3s; }
.ring-fg.rest { stroke: #19C3AE; }
.timer-center { position: absolute; inset: 0; display: flex; flex-direction: column; align-items: center; justify-content: center; }
.timer-num { font-size: 3.6rem; font-weight: 900; line-height: 1; }
.timer-phase { font-weight: 800; color: var(--muted); font-size: 1.05rem; }
.rep-dots { display: flex; gap: .5rem; }
.rep-dots i { width: 1.1rem; height: 1.1rem; border-radius: 50%; background: rgba(29, 38, 51, .1); transition: background .3s, transform .3s; }
.rep-dots i.on { background: linear-gradient(135deg, #FFB199, #FF6F91); transform: scale(1.15); }
.bob { animation: float 3s ease-in-out infinite; }

/* Summary */
.summary { position: relative; max-width: 620px; margin: 1rem auto 0; padding: 2rem 1.5rem; text-align: center; overflow: hidden; display: flex; flex-direction: column; align-items: center; gap: .5rem; }
.summary::before { content: ''; position: absolute; inset: 0 0 auto 0; height: 8px; background: var(--grad); }
.trophy { font-size: 5.5rem; animation: pop .8s var(--ease); filter: drop-shadow(0 12px 18px rgba(0, 0, 0, .15)); }
.summary-title { font-size: 2rem; font-weight: 900; }
.big-stars { font-size: 3.4rem; letter-spacing: .1em; }
.summary-msg { font-size: 1.2rem; font-weight: 800; }
.summary-stats { display: grid; grid-template-columns: 1fr 1fr; gap: .8rem; width: 100%; margin: .6rem 0; }
.result-list { list-style: none; width: 100%; display: flex; flex-wrap: wrap; gap: .45rem; justify-content: center; margin: .4rem 0 .8rem; }
.result-list li { padding: .35rem .8rem; border-radius: 999px; font-weight: 800; font-size: .92rem; display: flex; gap: .35rem; }
.result-list li.ok { background: #E4F7EC; color: #1E7A45; }
.result-list li.no { background: #F1F2F4; color: var(--muted); }
.summary-actions { display: flex; gap: .7rem; flex-wrap: wrap; justify-content: center; }
.confetti { position: absolute; inset: 0; pointer-events: none; }
.confetti i { position: absolute; top: -20px; left: var(--x); width: 10px; height: 16px; background: var(--c); border-radius: 3px; transform: rotate(var(--r)); animation: fall 2.6s ease-in forwards; animation-delay: var(--d); opacity: 0; }
@keyframes fall { 0% { opacity: 1; transform: translateY(0) rotate(var(--r)); } 100% { opacity: 0; transform: translateY(560px) rotate(calc(var(--r) + 540deg)); } }

/* Board */
.board-display { margin-top: 1rem; min-height: 6rem; padding: 1rem 1.4rem; display: flex; align-items: center; justify-content: center; gap: 1rem; text-align: center; }
.board-big { font-size: 2.2rem; font-weight: 900; line-height: 1.15; animation: pop .4s var(--ease); }
.board-emoji.big { font-size: 3.2rem; }
.board-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(160px, 1fr)); gap: .8rem; }
.board-card { display: flex; flex-direction: column; align-items: center; justify-content: center; gap: .3rem; min-height: 8.5rem; padding: .9rem; border-radius: 22px; background: rgba(255, 255, 255, .88); border: 2px solid #fff; box-shadow: var(--shadow); transition: transform .2s var(--ease), box-shadow .2s, border-color .2s; }
.board-card:hover { transform: translateY(-3px); }
.board-card.speaking { border-color: #9466FF; box-shadow: 0 0 0 5px rgba(148, 102, 255, .25), var(--shadow-lg); transform: scale(1.04); }
.board-emoji { font-size: 2.8rem; }
.board-text { font-weight: 900; font-size: 1.08rem; line-height: 1.2; }

/* Progress */
.stat-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(180px, 1fr)); gap: .9rem; }
.stat-card { padding: 1.1rem 1.2rem; display: flex; flex-direction: column; }
.panel { padding: 1.3rem 1.4rem; margin-top: 1rem; }
.panel-title { font-size: 1.15rem; font-weight: 900; margin-bottom: .9rem; }
.chart { display: grid; grid-template-columns: repeat(7, 1fr); gap: .6rem; height: 12rem; align-items: end; }
.bar-col { display: flex; flex-direction: column; align-items: center; height: 100%; justify-content: flex-end; gap: .3rem; }
.bar { width: 100%; max-width: 48px; height: max(6px, var(--h)); border-radius: 12px 12px 6px 6px; background: linear-gradient(180deg, #19C3AE, #0B7A6D); animation: grow .8s var(--ease) both; animation-delay: calc(var(--i) * 70ms); transform-origin: bottom; }
@keyframes grow { from { transform: scaleY(0); } }
.bar-val { font-weight: 900; font-size: .9rem; }
.bar-lbl { font-size: .8rem; font-weight: 800; color: var(--muted); white-space: nowrap; }
.bar-lbl.today { color: var(--primary-2); }
.mod-row { display: flex; align-items: center; gap: .9rem; padding: .55rem 0; }
.mod-ico { font-size: 1.8rem; width: 2.4rem; text-align: center; flex: none; }
.mod-info { flex: 1; }
.mod-top { display: flex; justify-content: space-between; gap: .5rem; margin-bottom: .3rem; flex-wrap: wrap; }
.history { list-style: none; }
.history li { display: flex; align-items: center; gap: .8rem; padding: .7rem 0; border-bottom: 1px solid var(--line); }
.history li:last-child { border-bottom: 0; }
.history li > div { flex: 1; }
.hist-score { font-weight: 900; font-size: 1.15rem; background: #E3F7F3; color: var(--primary-2); padding: .25rem .7rem; border-radius: 999px; }

/* Settings */
.field { display: flex; flex-direction: column; gap: .5rem; margin-bottom: 1.1rem; }
.field:last-child { margin-bottom: 0; }
.field input[type=text] { font: inherit; font-size: 1.1rem; padding: .85rem 1rem; border-radius: 14px; border: 2px solid var(--line); background: #fff; outline: none; transition: border-color .2s; }
.field input[type=text]:focus { border-color: var(--primary); }
.seg { display: flex; background: rgba(29, 38, 51, .06); border-radius: 999px; padding: 4px; gap: 4px; }
.seg-btn { flex: 1; min-height: 2.9rem; border-radius: 999px; font-weight: 800; transition: background .2s, color .2s, box-shadow .2s; }
.seg-btn.active { background: #fff; color: var(--primary-2); box-shadow: var(--shadow-sm); }
.range-row { display: flex; align-items: center; gap: .7rem; font-size: 1.4rem; }
input[type=range] { flex: 1; accent-color: var(--primary); height: 2rem; }
.toggle-row { display: flex; align-items: center; justify-content: space-between; gap: 1rem; padding: .7rem 0; cursor: pointer; }
.switch { appearance: none; -webkit-appearance: none; width: 3.6rem; height: 2.1rem; border-radius: 999px; background: #D5D9DF; position: relative; cursor: pointer; flex: none; transition: background .25s; }
.switch::after { content: ''; position: absolute; top: 4px; left: 4px; width: calc(2.1rem - 8px); height: calc(2.1rem - 8px); border-radius: 50%; background: #fff; box-shadow: 0 2px 6px rgba(0, 0, 0, .2); transition: transform .25s var(--ease); }
.switch:checked { background: var(--primary); }
.switch:checked::after { transform: translateX(1.5rem); }
#mic-test-out { margin-top: .7rem; }

/* Bottom nav */
.bottom-nav {
  position: fixed; left: 50%; bottom: calc(.8rem + env(safe-area-inset-bottom)); transform: translateX(-50%);
  display: flex; gap: .3rem; padding: .4rem; border-radius: 999px;
  background: rgba(255, 255, 255, .85); backdrop-filter: blur(16px); -webkit-backdrop-filter: blur(16px);
  box-shadow: var(--shadow-lg); border: 1px solid #fff; z-index: 50;
}
body.in-session .bottom-nav { display: none; }
.nav-btn { display: flex; align-items: center; gap: .45rem; padding: .7rem 1.2rem; border-radius: 999px; font-weight: 800; color: var(--muted); transition: background .25s, color .25s; min-height: 3.3rem; }
.nav-ico { font-size: 1.35rem; }
.nav-btn.active { background: linear-gradient(135deg, #19C3AE, var(--primary-2)); color: #fff; box-shadow: 0 8px 18px -8px rgba(11, 122, 109, .6); }

.toast { position: fixed; left: 50%; bottom: 6.5rem; transform: translate(-50%, 20px); background: var(--ink); color: #fff; padding: .8rem 1.2rem; border-radius: 14px; font-weight: 700; opacity: 0; pointer-events: none; transition: opacity .3s, transform .3s var(--ease); z-index: 60; max-width: 90vw; text-align: center; }
.toast.show { opacity: 1; transform: translate(-50%, 0); }

/* Responsive */
@media (max-width: 720px) {
  .hero { grid-template-columns: 1fr; padding: 1.4rem; }
  .hero-stats { grid-template-columns: repeat(3, 1fr); }
  .hero-stats .stat { padding: .6rem .7rem; }
  .stat-num { font-size: 1.3rem; }
  .hero-title { font-size: 1.6rem; }
  .oral-stage { grid-template-columns: 1fr; text-align: center; }
  .oral-main { align-items: center; }
  .timer { width: 170px; }
  .nav-btn span:not(.nav-ico) { font-size: .85rem; }
  .nav-btn { padding: .6rem .9rem; }
  .reading-text { font-size: 1.3rem; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .01ms !important; animation-iteration-count: 1 !important; transition-duration: .01ms !important; }
}
