:root {
    --ink: #173128;
    --muted: #69766f;
    --cream: #f7f6ee;
    --paper: rgba(255, 255, 252, .88);
    --lime: #c7f45d;
    --lime-strong: #a9e535;
    --mint: #dff4c8;
    --green: #214b3b;
    --green-deep: #153a2d;
    --orange: #ff9466;
    --lavender: #d8d2fb;
    --line: rgba(23, 49, 40, .12);
    --shadow: 0 24px 70px rgba(35, 67, 49, .13);
    --radius-lg: 30px;
    --radius-md: 20px;
    --ease: cubic-bezier(.22, 1, .36, 1);
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
    margin: 0;
    min-height: 100vh;
    color: var(--ink);
    background: var(--cream);
    font-family: Inter, ui-rounded, "SF Pro Rounded", "PingFang SC", "Microsoft YaHei", system-ui, sans-serif;
    overflow-x: hidden;
}
button, input, textarea, select { font: inherit; }
button, a { -webkit-tap-highlight-color: transparent; }
button { color: inherit; }
a { color: inherit; text-decoration: none; }
[hidden] { display: none !important; }

.ambient {
    position: fixed;
    z-index: -3;
    border-radius: 50%;
    filter: blur(12px);
    pointer-events: none;
    animation: ambientFloat 16s ease-in-out infinite alternate;
}
.ambient-one { width: 520px; height: 520px; right: -210px; top: -190px; background: rgba(199, 244, 93, .33); }
.ambient-two { width: 450px; height: 450px; left: -230px; bottom: -220px; background: rgba(216, 210, 251, .38); animation-delay: -7s; }
.noise {
    position: fixed;
    z-index: -2;
    inset: 0;
    opacity: .035;
    pointer-events: none;
    background-image: repeating-radial-gradient(circle at 20% 30%, #173128 0, #173128 .45px, transparent .55px, transparent 4px);
    background-size: 11px 13px;
}

.site-header {
    max-width: 1240px;
    margin: 0 auto;
    padding: 27px 34px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
}
.brand { display: inline-flex; align-items: center; gap: 12px; font-size: 19px; font-weight: 750; letter-spacing: -.5px; }
.brand strong { color: #4e8063; }
.brand-mark {
    width: 38px;
    height: 38px;
    border-radius: 13px 13px 16px 16px;
    position: relative;
    display: inline-block;
    background: var(--green);
    box-shadow: inset 0 0 0 1px rgba(255,255,255,.12), 0 8px 18px rgba(33,75,59,.16);
}
.brand-mark::after { content: ""; position: absolute; left: 18px; bottom: 8px; width: 2px; height: 16px; border-radius: 2px; background: var(--lime); transform: rotate(1deg); }
.brand-mark i, .brand-mark b { position: absolute; top: 8px; width: 12px; height: 8px; background: var(--lime); }
.brand-mark i { left: 7px; border-radius: 10px 2px 10px 2px; transform: rotate(25deg); }
.brand-mark b { right: 6px; border-radius: 2px 10px 2px 10px; transform: rotate(-18deg); }
.header-actions { display: flex; align-items: center; gap: 10px; }
.stat-pill, .admin-link {
    min-height: 41px;
    border: 1px solid var(--line);
    border-radius: 999px;
    background: rgba(255,255,255,.66);
    backdrop-filter: blur(12px);
}
.stat-pill { padding: 0 13px; display: inline-flex; align-items: center; gap: 5px; cursor: default; }
.stat-pill strong { font-size: 14px; }
.stat-pill small { font-size: 10px; color: var(--muted); font-weight: 800; }
.spark-icon { color: #e89f31; }
.streak-pill { background: rgba(255, 244, 229, .82); }
.admin-link { display: grid; place-items: center; padding: 0 18px; font-size: 13px; font-weight: 750; transition: .25s ease; }
.admin-link:hover { border-color: var(--green); background: var(--green); color: #fff; transform: translateY(-2px); }

main { width: 100%; }
.view { display: none; }
.view.is-active { display: grid; animation: viewIn .6s var(--ease) both; }
.home-view {
    max-width: 1180px;
    margin: 28px auto 70px;
    padding: 0 34px;
    grid-template-columns: minmax(0, .95fr) minmax(440px, 1.05fr);
    grid-template-rows: auto auto;
    align-items: center;
    column-gap: 70px;
    row-gap: 28px;
}
.hero-copy { padding: 36px 0; }
.eyebrow, .section-kicker, .result-kicker { font-size: 10px; font-weight: 900; letter-spacing: 1.9px; text-transform: uppercase; }
.eyebrow { display: inline-flex; align-items: center; gap: 9px; color: #5d7668; }
.eyebrow span { width: 25px; height: 1px; background: var(--green); position: relative; }
.eyebrow span::after { content: ""; position: absolute; right: 0; top: -2px; width: 5px; height: 5px; background: var(--lime-strong); border-radius: 50%; }
.hero-copy h1 { margin: 19px 0 22px; font-family: Georgia, "Songti SC", serif; font-size: clamp(43px, 5.2vw, 69px); font-weight: 500; line-height: 1.07; letter-spacing: -3px; }
.hero-copy h1 em { color: var(--green); font-style: italic; position: relative; }
.hero-copy h1 em::after { content: ""; position: absolute; height: 13px; left: 1%; right: -1%; bottom: 1px; z-index: -1; border-radius: 50%; background: rgba(199,244,93,.57); transform: rotate(-1deg); }
.hero-copy > p { max-width: 520px; margin: 0; color: var(--muted); font-size: 16px; line-height: 1.9; }
.mini-proof { margin-top: 30px; display: flex; align-items: center; gap: 13px; font-size: 12px; color: var(--muted); }
.mini-proof strong { color: var(--ink); }
.avatar-stack { display: flex; padding-left: 8px; }
.avatar-stack span { width: 31px; height: 31px; margin-left: -8px; border: 2px solid var(--cream); border-radius: 50%; display: grid; place-items: center; font-size: 9px; font-weight: 900; color: var(--green); background: var(--mint); }
.avatar-stack span:nth-child(2) { background: var(--lavender); }
.avatar-stack span:nth-child(3) { background: #ffd8c7; }
.avatar-stack span:last-child { background: var(--ink); color: white; }

.planner-card {
    position: relative;
    padding: 31px;
    border-radius: var(--radius-lg);
    background: var(--paper);
    border: 1px solid rgba(255,255,255,.9);
    box-shadow: var(--shadow);
    backdrop-filter: blur(22px);
    overflow: hidden;
}
.planner-card::before { content: ""; position: absolute; right: -42px; top: -58px; width: 150px; height: 150px; border: 28px solid rgba(199,244,93,.18); border-radius: 50%; }
.planner-heading { position: relative; display: flex; align-items: flex-start; justify-content: space-between; gap: 20px; margin-bottom: 26px; }
.section-kicker { color: #809085; }
.planner-heading h2 { margin: 6px 0 0; font-size: 24px; letter-spacing: -.8px; }
.live-count { min-width: 62px; text-align: right; }
.live-count span { display: block; font-family: Georgia, serif; font-size: 31px; line-height: 1; }
.live-count small { color: var(--muted); font-size: 9px; white-space: nowrap; }
fieldset { padding: 0; margin: 0; border: 0; }
.form-group { margin-top: 20px; }
.form-group legend, .legend-like { display: block; margin-bottom: 10px; font-size: 11px; color: #53675d; font-weight: 850; }
.preset-row { display: flex; gap: 7px; margin-bottom: 10px; }
.preset-chip { border: 1px solid var(--line); border-radius: 10px; padding: 7px 11px; background: transparent; font-size: 11px; font-weight: 700; color: var(--muted); cursor: pointer; transition: .2s ease; }
.preset-chip:hover { border-color: #90bd48; color: var(--ink); }
.preset-chip.is-selected { border-color: var(--green); background: var(--green); color: white; }
.date-range { display: grid; grid-template-columns: 1fr auto 1fr; align-items: end; gap: 10px; }
.date-range label { border: 1px solid var(--line); border-radius: 13px; padding: 8px 11px; background: rgba(248,249,243,.8); }
.date-range label span { display: block; margin-bottom: 3px; color: #839088; font-size: 9px; font-weight: 800; }
.date-range input { width: 100%; padding: 0; border: 0; outline: 0; color: var(--ink); background: transparent; font-size: 12px; font-weight: 750; }
.date-arrow { padding-bottom: 13px; color: #93a097; }
.type-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 8px; }
.type-option input { position: absolute; opacity: 0; pointer-events: none; }
.type-option-card { height: 69px; position: relative; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 3px; border: 1px solid var(--line); border-radius: 14px; background: rgba(248,249,243,.74); cursor: pointer; transition: .25s var(--ease); }
.type-option-card b { font-family: Georgia, serif; font-size: 17px; }
.type-option-card em { color: var(--muted); font-size: 10px; font-style: normal; font-weight: 750; }
.type-option-card i { position: absolute; top: 6px; right: 7px; width: 15px; height: 15px; border-radius: 50%; display: grid; place-items: center; background: var(--green); color: white; font-size: 8px; font-style: normal; opacity: 0; transform: scale(.5); transition: .25s var(--ease); }
.type-option input:checked + .type-option-card { border-color: rgba(51,103,77,.38); background: var(--mint); box-shadow: inset 0 0 0 1px rgba(255,255,255,.5); transform: translateY(-2px); }
.type-option input:checked + .type-option-card i { opacity: 1; transform: scale(1); }
.type-option input:focus-visible + .type-option-card { outline: 3px solid rgba(169,229,53,.45); outline-offset: 2px; }
.setup-row { display: grid; grid-template-columns: 1fr 1.2fr; gap: 15px; align-items: end; }
.compact-group { margin-top: 18px; }
.stepper, .language-switch { height: 42px; border: 1px solid var(--line); border-radius: 12px; background: rgba(248,249,243,.7); }
.stepper { display: grid; grid-template-columns: 38px 1fr 38px; align-items: center; text-align: center; }
.stepper button { height: 100%; border: 0; background: transparent; cursor: pointer; font-size: 18px; }
.stepper output { font-size: 13px; font-weight: 850; }
.language-switch { display: grid; grid-template-columns: 1fr 1fr; padding: 3px; }
.language-switch input { position: absolute; opacity: 0; }
.language-switch label { display: contents; }
.language-switch span { display: grid; place-items: center; border-radius: 9px; font-size: 10px; font-weight: 800; cursor: pointer; }
.language-switch input:checked + span { background: white; box-shadow: 0 3px 10px rgba(23,49,40,.1); }
.primary-cta { width: 100%; min-height: 57px; margin-top: 22px; padding: 0 10px 0 22px; display: flex; align-items: center; justify-content: space-between; border: 0; border-radius: 17px; color: white; background: var(--green); font-weight: 850; cursor: pointer; box-shadow: 0 14px 28px rgba(33,75,59,.2); transition: .3s var(--ease); }
.primary-cta i { width: 39px; height: 39px; border-radius: 12px; display: grid; place-items: center; color: var(--green); background: var(--lime); font-size: 19px; font-style: normal; transition: .3s var(--ease); }
.primary-cta:hover { transform: translateY(-3px); background: var(--green-deep); box-shadow: 0 18px 34px rgba(33,75,59,.28); }
.primary-cta:hover i { transform: translateX(2px) rotate(-4deg); }
.primary-cta:disabled { opacity: .65; cursor: wait; transform: none; }
.form-message { min-height: 18px; margin: 9px 0 -8px; text-align: center; color: #ae4b33; font-size: 11px; }

.growth-card { max-width: 470px; display: flex; align-items: center; gap: 18px; padding: 18px 22px; border: 1px solid rgba(33,75,59,.1); border-radius: 21px; background: rgba(224,244,200,.46); }
.growth-card > div:last-child { display: grid; gap: 3px; }
.growth-card span { color: var(--muted); font-size: 10px; font-weight: 750; }
.growth-card strong { font-size: 15px; }
.growth-card small { max-width: 340px; color: var(--muted); font-size: 10px; line-height: 1.5; }
.plant-pot { position: relative; flex: 0 0 48px; height: 51px; }
.plant-pot .stem { position: absolute; left: 23px; top: 8px; width: 2px; height: 27px; background: var(--green); transform-origin: bottom; animation: plantSway 4s ease-in-out infinite alternate; }
.leaf { position: absolute; z-index: 2; width: 19px; height: 11px; background: #6fa25d; }
.leaf-a { left: 6px; top: 11px; border-radius: 13px 2px 13px 2px; transform: rotate(23deg); }
.leaf-b { right: 3px; top: 5px; border-radius: 2px 13px 2px 13px; transform: rotate(-17deg); }
.leaf-c { left: 8px; top: 26px; width: 16px; height: 9px; border-radius: 12px 2px 12px 2px; transform: rotate(18deg); }
.pot { position: absolute; left: 10px; bottom: 0; width: 30px; height: 17px; border-radius: 4px 4px 10px 10px; background: #e89063; box-shadow: inset 0 4px rgba(151,82,54,.18); }

/* Study */
.study-view { min-height: calc(100vh - 96px); padding: 15px 34px 50px; }
.study-topbar { width: min(1050px, 100%); margin: 0 auto 24px; display: grid; grid-template-columns: 180px 1fr 180px; align-items: center; gap: 30px; }
.ghost-button, .sound-button { border: 0; background: transparent; font-size: 12px; font-weight: 750; cursor: pointer; color: var(--muted); }
.ghost-button { text-align: left; }
.ghost-button span { display: inline-grid; width: 28px; height: 28px; margin-right: 6px; place-items: center; border: 1px solid var(--line); border-radius: 50%; }
.sound-button { justify-self: end; padding: 9px 13px; border: 1px solid var(--line); border-radius: 12px; background: rgba(255,255,255,.62); }
.progress-meta { display: flex; justify-content: space-between; margin-bottom: 7px; font-size: 10px; color: var(--muted); font-weight: 750; }
.progress-meta strong { color: #739e25; }
.progress-meta i { font-style: normal; }
.progress-track { height: 8px; border-radius: 999px; background: rgba(33,75,59,.1); overflow: hidden; }
.progress-track span { display: block; width: 10%; height: 100%; border-radius: inherit; background: linear-gradient(90deg, #83b93e, var(--lime)); box-shadow: 0 0 14px rgba(169,229,53,.45); transition: width .6s var(--ease); }
.card-stage { width: min(760px, 100%); margin: 0 auto; display: grid; justify-items: center; }
.flash-card {
    width: 100%;
    min-height: 390px;
    position: relative;
    padding: 30px 34px 22px;
    display: flex;
    flex-direction: column;
    overflow: hidden;
    border-radius: 34px;
    color: #f7ffe9;
    background: radial-gradient(circle at 82% 10%, rgba(199,244,93,.17), transparent 29%), linear-gradient(145deg, #234f3e 0%, #17392d 62%, #102b22 100%);
    box-shadow: 0 31px 80px rgba(20,55,41,.25);
    transform-style: preserve-3d;
}
.flash-card.card-enter { animation: cardEnter .55s var(--ease) both; }
.flash-card.card-exit { animation: cardExit .35s ease both; }
.card-orbit { position: absolute; border: 1px solid rgba(199,244,93,.12); border-radius: 50%; pointer-events: none; }
.orbit-one { width: 290px; height: 290px; right: -150px; bottom: -90px; }
.orbit-two { width: 170px; height: 170px; left: -115px; top: 80px; }
.card-head { position: relative; z-index: 1; display: flex; justify-content: space-between; align-items: center; }
.card-type { padding: 7px 12px; border-radius: 999px; color: var(--lime); background: rgba(199,244,93,.1); font-size: 9px; font-weight: 900; letter-spacing: 1px; }
.card-date { color: rgba(255,255,255,.48); font-size: 10px; }
.card-content { flex: 1; position: relative; z-index: 1; display: flex; flex-direction: column; align-items: center; justify-content: center; padding: 30px 25px 17px; text-align: center; }
.card-label { margin: 0 0 17px; color: rgba(255,255,255,.48); font-size: 11px; }
.card-content h2 { max-width: 650px; margin: 0; white-space: pre-line; font-family: Georgia, "Times New Roman", serif; font-size: clamp(37px, 5vw, 62px); line-height: 1.2; font-weight: 500; letter-spacing: -.7px; }
.card-content h2.is-long { font-family: inherit; font-size: clamp(25px, 3.2vw, 39px); line-height: 1.45; font-weight: 600; }
.hint-button { margin-top: 26px; padding: 7px 11px; border: 1px solid rgba(255,255,255,.13); border-radius: 999px; color: rgba(255,255,255,.62); background: rgba(255,255,255,.045); font-size: 9px; cursor: pointer; }
.hint-button span { color: var(--lime); }
.context-hint { max-width: 540px; margin: 13px 0 0; padding: 10px 14px; border-radius: 12px; color: rgba(255,255,255,.75); background: rgba(255,255,255,.07); font-size: 11px; line-height: 1.65; animation: smallIn .3s ease both; }
.card-footer { position: relative; z-index: 1; display: flex; justify-content: space-between; color: rgba(255,255,255,.34); font-size: 9px; }
kbd { padding: 3px 7px; border: 1px solid rgba(255,255,255,.2); border-radius: 6px; font-family: inherit; }
.answer-zone { width: 100%; min-height: 230px; display: flex; flex-direction: column; align-items: center; padding: 25px 0 0; }
.mic-button { width: 74px; height: 74px; position: relative; display: grid; place-items: center; border: 0; border-radius: 50%; background: transparent; cursor: pointer; }
.mic-ripple { position: absolute; inset: 3px; border-radius: inherit; background: rgba(199,244,93,.23); animation: micBreathe 2.2s ease-in-out infinite; }
.mic-core { width: 57px; height: 57px; position: relative; display: grid; place-items: center; border-radius: 50%; background: var(--lime); box-shadow: 0 11px 25px rgba(126,170,52,.25); transition: .25s var(--ease); }
.mic-core i { width: 14px; height: 22px; position: relative; border: 2px solid var(--green); border-radius: 8px; }
.mic-core i::before { content: ""; position: absolute; left: 50%; top: 100%; width: 21px; height: 11px; border: 2px solid var(--green); border-top: 0; border-radius: 0 0 13px 13px; transform: translateX(-50%); }
.mic-core i::after { content: ""; position: absolute; left: 50%; top: 31px; width: 2px; height: 6px; background: var(--green); transform: translateX(-50%); }
.mic-button:hover .mic-core { transform: scale(1.06); }
.mic-button.is-listening .mic-ripple { animation: listening 1.2s ease-out infinite; }
.mic-button.is-listening .mic-core { background: var(--orange); transform: scale(1.08); box-shadow: 0 0 0 8px rgba(255,148,102,.13), 0 12px 28px rgba(196,92,48,.25); }
.answer-zone > strong { margin-top: 11px; font-size: 13px; }
.answer-zone > p { margin: 5px 0 0; color: var(--muted); font-size: 10px; }
.transcript-bubble { max-width: 560px; margin-top: 14px; padding: 12px 15px; border: 1px solid var(--line); border-radius: 16px; background: rgba(255,255,255,.72); text-align: center; animation: smallIn .3s ease both; }
.transcript-bubble span { color: var(--muted); font-size: 9px; font-weight: 750; }
.transcript-bubble p { margin: 4px 0; font-size: 13px; font-weight: 650; }
.transcript-bubble button { border: 0; background: transparent; color: #63853e; font-size: 9px; text-decoration: underline; cursor: pointer; }
.evaluate-button { margin-top: 10px; padding: 11px 17px; border: 0; border-radius: 12px; background: var(--green); color: white; font-size: 11px; font-weight: 800; cursor: pointer; }
.evaluate-button span { color: var(--lime); }
.evaluate-button.is-loading { pointer-events: none; opacity: .72; }
.reveal-button { margin-top: 11px; border: 0; background: transparent; color: #78867e; font-size: 9px; text-decoration: underline; text-underline-offset: 3px; cursor: pointer; }
.feedback-panel { width: 100%; min-height: 245px; position: relative; margin-top: 21px; padding: 23px 85px 23px 25px; display: grid; grid-template-columns: 92px 1fr; gap: 18px; align-items: start; border: 1px solid rgba(46,104,74,.17); border-radius: 24px; background: rgba(255,255,255,.78); box-shadow: 0 18px 48px rgba(39,69,51,.09); animation: feedbackIn .55s var(--ease) both; }
.feedback-panel.is-almost { border-color: rgba(211,145,59,.3); }
.feedback-panel.is-incorrect { border-color: rgba(200,91,67,.25); }
.score-ring { width: 86px; height: 86px; display: grid; place-items: center; align-content: center; border: 8px solid var(--mint); border-right-color: var(--lime-strong); border-radius: 50%; background: white; transform: rotate(-4deg); }
.score-ring strong { font-family: Georgia, serif; font-size: 31px; line-height: 1; }
.score-ring span { color: var(--muted); font-size: 9px; }
.feedback-copy { min-width: 0; }
.verdict-badge { display: inline-block; padding: 4px 8px; border-radius: 999px; color: #42743a; background: var(--mint); font-size: 8px; font-weight: 900; }
.is-almost .verdict-badge { color: #916331; background: #fff0c9; }
.is-incorrect .verdict-badge { color: #9b4835; background: #ffe0d6; }
.feedback-copy h3 { margin: 7px 0 5px; font-size: 18px; }
.feedback-copy > p { margin: 0; color: var(--muted); font-size: 11px; line-height: 1.65; }
.answer-reference { margin-top: 11px; padding: 10px 12px; border-radius: 12px; background: #f1f5eb; }
.answer-reference span { color: #7d8c82; font-size: 8px; font-weight: 850; }
.answer-reference p { margin: 3px 0 0; white-space: pre-line; font-size: 11px; line-height: 1.55; font-weight: 650; }
.next-button { position: absolute; right: 20px; bottom: 20px; padding: 10px 13px; border: 0; border-radius: 12px; color: white; background: var(--green); font-size: 10px; font-weight: 800; cursor: pointer; }

/* Result */
.result-view { min-height: calc(100vh - 96px); padding: 30px 24px 70px; place-items: center; }
.result-card { width: min(660px, 100%); position: relative; overflow: hidden; padding: 53px 48px 44px; border: 1px solid white; border-radius: 35px; background: rgba(255,255,252,.87); box-shadow: var(--shadow); text-align: center; }
.result-card::after { content: ""; position: absolute; width: 210px; height: 210px; right: -100px; bottom: -120px; border-radius: 50%; background: var(--mint); opacity: .65; }
.result-burst { width: 78px; height: 78px; position: relative; display: grid; place-items: center; margin: 0 auto 19px; border-radius: 26px; color: var(--green); background: var(--lime); transform: rotate(-5deg); box-shadow: 0 13px 30px rgba(133,183,60,.25); }
.result-burst span { font-size: 34px; animation: starPulse 2s ease-in-out infinite; }
.result-burst i, .result-burst b { position: absolute; width: 7px; height: 7px; border-radius: 50%; background: var(--orange); }
.result-burst i { left: -15px; top: 2px; }
.result-burst b { right: -12px; bottom: 7px; background: #8375d1; }
.result-kicker { color: #759182; }
.result-card h2 { max-width: 480px; margin: 10px auto; font-family: Georgia, "Songti SC", serif; font-size: clamp(30px, 5vw, 44px); font-weight: 500; line-height: 1.25; letter-spacing: -1.5px; }
.result-card > p { color: var(--muted); font-size: 13px; }
.result-stats { margin: 31px 0 23px; display: grid; grid-template-columns: repeat(3, 1fr); border: 1px solid var(--line); border-radius: 19px; background: #f8f9f3; }
.result-stats div { padding: 18px 8px; border-right: 1px solid var(--line); }
.result-stats div:last-child { border-right: 0; }
.result-stats span { display: block; color: var(--muted); font-size: 9px; }
.result-stats strong { display: block; margin-top: 6px; font-size: 18px; }
.result-stats i { font-style: normal; }
.new-badges { margin: 0 0 20px; }
.new-badges > span { font-size: 9px; color: var(--muted); font-weight: 850; }
#badgeList { display: flex; justify-content: center; flex-wrap: wrap; gap: 8px; margin-top: 9px; }
.badge-chip { padding: 9px 12px; border-radius: 12px; background: #fff3cc; color: #775c19; font-size: 10px; font-weight: 800; animation: badgeIn .6s var(--ease) both; }
.result-actions { position: relative; z-index: 1; max-width: 360px; margin: 0 auto; display: grid; grid-template-columns: 1fr 120px; gap: 10px; }
.result-actions .primary-cta { margin: 0; min-height: 51px; }
.secondary-button { border: 1px solid var(--line); border-radius: 15px; background: transparent; font-size: 11px; font-weight: 750; cursor: pointer; }

.toast { position: fixed; z-index: 50; left: 50%; bottom: 30px; max-width: min(420px, calc(100vw - 30px)); padding: 12px 18px; border-radius: 13px; color: white; background: #173128; box-shadow: 0 13px 30px rgba(0,0,0,.18); font-size: 11px; font-weight: 700; opacity: 0; pointer-events: none; transform: translate(-50%, 20px); transition: .35s var(--ease); }
.toast.is-visible { opacity: 1; transform: translate(-50%, 0); }
.toast.is-error { background: #943f30; }
.xp-pop { position: fixed; z-index: 60; left: 50%; top: 45%; padding: 10px 15px; border-radius: 12px; color: var(--green); background: var(--lime); font-size: 18px; font-weight: 900; opacity: 0; pointer-events: none; transform: translate(-50%, 20px) scale(.7); }
.xp-pop.is-visible { animation: xpPop 1.4s var(--ease) both; }
.confetti { position: fixed; z-index: 55; inset: 0; pointer-events: none; overflow: hidden; }
.confetti-piece { position: absolute; top: -30px; width: 8px; height: 16px; border-radius: 3px; animation: confettiFall var(--duration) ease-in forwards; animation-delay: var(--delay); transform: rotate(var(--rotation)); }

@keyframes ambientFloat { to { transform: translate3d(35px, 20px, 0) scale(1.08); } }
@keyframes viewIn { from { opacity: 0; transform: translateY(12px); } to { opacity: 1; transform: none; } }
@keyframes smallIn { from { opacity: 0; transform: translateY(-5px); } to { opacity: 1; transform: none; } }
@keyframes plantSway { to { transform: rotate(5deg); } }
@keyframes micBreathe { 50% { transform: scale(1.13); opacity: .5; } }
@keyframes listening { 0% { transform: scale(.9); opacity: .8; } 100% { transform: scale(1.45); opacity: 0; } }
@keyframes cardEnter { from { opacity: 0; transform: translateX(45px) rotateY(-4deg) scale(.98); } to { opacity: 1; transform: none; } }
@keyframes cardExit { to { opacity: 0; transform: translateX(-45px) rotateY(4deg) scale(.98); } }
@keyframes feedbackIn { from { opacity: 0; transform: translateY(20px) scale(.98); } to { opacity: 1; transform: none; } }
@keyframes starPulse { 50% { transform: rotate(13deg) scale(1.12); } }
@keyframes badgeIn { from { opacity: 0; transform: translateY(9px) scale(.8); } to { opacity: 1; transform: none; } }
@keyframes xpPop { 0% { opacity: 0; transform: translate(-50%,20px) scale(.7); } 20% { opacity: 1; transform: translate(-50%,-10px) scale(1.05); } 70% { opacity: 1; } 100% { opacity: 0; transform: translate(-50%,-100px) scale(.9); } }
@keyframes confettiFall { to { top: 110vh; transform: translateX(var(--drift)) rotate(620deg); } }

@media (max-width: 900px) {
    .home-view { grid-template-columns: 1fr; max-width: 690px; row-gap: 12px; }
    .hero-copy { padding: 10px 0; text-align: center; }
    .hero-copy > p { margin: 0 auto; }
    .eyebrow { justify-content: center; }
    .mini-proof { justify-content: center; }
    .growth-card { justify-self: center; }
    .study-topbar { grid-template-columns: 130px 1fr 130px; gap: 15px; }
}

@media (max-width: 620px) {
    .site-header { padding: 18px 17px; }
    .brand { font-size: 15px; gap: 8px; }
    .brand-mark { width: 33px; height: 33px; }
    .admin-link { display: none; }
    .stat-pill { min-height: 35px; padding: 0 10px; }
    .home-view { margin: 3px auto 40px; padding: 0 16px; }
    .hero-copy h1 { margin-top: 14px; font-size: 39px; letter-spacing: -2px; }
    .hero-copy > p { font-size: 14px; line-height: 1.75; }
    .mini-proof { margin-top: 20px; }
    .planner-card { padding: 23px 18px; border-radius: 25px; }
    .planner-heading h2 { font-size: 21px; }
    .date-range { grid-template-columns: 1fr 1fr; }
    .date-arrow { display: none; }
    .type-grid { grid-template-columns: repeat(2, 1fr); }
    .setup-row { grid-template-columns: 1fr; gap: 0; }
    .growth-card { width: 100%; }
    .study-view { padding: 2px 13px 38px; }
    .study-topbar { grid-template-columns: 45px 1fr 45px; gap: 10px; margin-bottom: 14px; }
    .ghost-button, .sound-button { width: 42px; height: 42px; padding: 0; display: grid; place-items: center; border: 1px solid var(--line); border-radius: 12px; background: rgba(255,255,255,.66); font-size: 0; }
    .ghost-button span { width: auto; height: auto; margin: 0; border: 0; font-size: 18px; }
    .sound-button { font-size: 16px; }
    .sound-button span { display: none; }
    .flash-card { min-height: 350px; padding: 22px 19px 18px; border-radius: 27px; }
    .card-content { padding-left: 0; padding-right: 0; }
    .card-content h2 { font-size: 40px; }
    .card-content h2.is-long { font-size: 24px; }
    .card-footer span:last-child { display: none; }
    .answer-zone { min-height: 220px; }
    .feedback-panel { padding: 20px 19px 68px; grid-template-columns: 1fr; text-align: center; }
    .score-ring { margin: 0 auto; }
    .answer-reference { text-align: left; }
    .result-card { padding: 42px 19px 31px; }
    .result-stats strong { font-size: 15px; }
    .result-actions { grid-template-columns: 1fr; }
    .secondary-button { min-height: 47px; }
}

@media (prefers-reduced-motion: reduce) {
    *, *::before, *::after { scroll-behavior: auto !important; animation-duration: .01ms !important; animation-iteration-count: 1 !important; transition-duration: .01ms !important; }
}
