:root {
  --ink: #17324a;
  --muted: #5e7385;
  --soft: #f2f8fc;
  --card: #ffffff;
  --line: #e7e9f2;
  --purple: #159edb;
  --purple-dark: #087eb8;
  --purple-soft: #e5f6fd;
  --green: #21bb83;
  --green-soft: #e5f8f0;
  --amber: #e79a38;
  --shadow: 0 18px 60px rgba(26, 99, 139, .10);
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body { margin: 0; color: var(--ink); background: var(--soft); font-family: Inter, "PingFang SC", "Microsoft YaHei", system-ui, sans-serif; }
button, input { font: inherit; }
button { cursor: pointer; }
.svg-defs { position: absolute; width: 0; height: 0; overflow: hidden; }
svg { width: 24px; height: 24px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.app-shell { min-height: 100vh; }

.sidebar { position: fixed; inset: 0 auto 0 0; z-index: 5; width: 248px; padding: 34px 24px 24px; background: #fff; border-right: 1px solid var(--line); display: flex; flex-direction: column; }
.brand { display: flex; gap: 12px; align-items: center; color: var(--ink); text-decoration: none; }
.brand-mark { width: 42px; height: 42px; display: grid; place-items: center; border-radius: 14px 14px 18px 14px; color: #fff; background: linear-gradient(145deg,#38b9ef,#118fcf); font-weight: 800; letter-spacing: -.5px; box-shadow: 0 7px 0 #bce9fb; transform: rotate(-2deg); }
.brand strong, .brand small { display: block; }
.brand strong { font-size: 20px; }
.brand small { color: #979caf; font-size: 10px; letter-spacing: 1.1px; text-transform: uppercase; margin-top: 2px; }
.side-nav { display: grid; gap: 8px; margin-top: 62px; }
.nav-item { border: 0; background: transparent; color: #72778a; border-radius: 14px; display: flex; align-items: center; gap: 14px; padding: 14px 16px; text-align: left; transition: .2s ease; }
.nav-item svg { width: 21px; }
.nav-item:hover { background: #f7f6ff; color: var(--purple); }
.nav-item.active { color: var(--purple); background: var(--purple-soft); font-weight: 700; }
.daily-tip { margin-top: auto; padding: 18px; border-radius: 20px; background: #f4f2ff; color: #6558d8; }
.daily-tip svg { width: 20px; height: 20px; margin-bottom: 8px; }
.daily-tip strong { display: block; font-size: 13px; }
.daily-tip p { color: #696789; font-size: 12px; line-height: 1.6; margin: 7px 0 0; }
.profile-mini { display: flex; gap: 11px; align-items: center; margin-top: 24px; padding: 10px 4px 0; border-top: 1px solid var(--line); }
.avatar { width: 36px; height: 36px; display: grid; place-items: center; border-radius: 50%; color: #fff; background: #252c48; font-weight: 700; }
.profile-mini strong, .profile-mini small { display: block; }
.profile-mini strong { font-size: 13px; }.profile-mini small { color: #999eae; font-size: 10px; margin-top: 3px; }

.main { min-height: 100vh; margin-left: 248px; padding: 52px clamp(28px, 5vw, 74px) 70px; }
.view { display: none; max-width: 1120px; margin: 0 auto; animation: fadeUp .35s ease both; }
.view.active { display: block; }
@keyframes fadeUp { from { opacity: 0; transform: translateY(8px); } }
.topline { display: flex; justify-content: space-between; align-items: flex-start; gap: 24px; margin-bottom: 34px; }
.eyebrow { color: #8a8fa2; font-size: 11px; font-weight: 800; letter-spacing: 1.5px; margin: 0 0 9px; }
h1, h2, p { margin-top: 0; }
h1 { font-size: clamp(27px, 3vw, 38px); line-height: 1.25; letter-spacing: -1.2px; margin-bottom: 10px; }
.subtitle { color: var(--muted); margin-bottom: 0; }
.streak-pill { min-width: 132px; display: flex; align-items: center; gap: 11px; padding: 12px 16px; border: 1px solid #ece7dc; background: #fffaf0; border-radius: 16px; }
.streak-pill svg { color: #ec963e; fill: #fff1dd; }
.streak-pill strong, .streak-pill small { display: block; }.streak-pill strong { font-size: 14px; }.streak-pill small { color: #938a7c; font-size: 10px; margin-top: 2px; }

.hero-card { min-height: 280px; display: flex; align-items: center; justify-content: space-between; padding: 44px 56px; overflow: hidden; position: relative; color: #fff; border-radius: 30px 30px 42px 30px; background: linear-gradient(128deg, #28b6e8 0%, #159edb 55%, #087fbd 100%); box-shadow: 0 20px 42px rgba(17, 147, 207, .25); }
.hero-card::before, .hero-card::after { content: ""; position: absolute; border: 1px solid rgba(255,255,255,.1); border-radius: 50%; }
.hero-card::before { width: 360px; height: 360px; right: -105px; top: -140px; border-width: 38px; border-color: rgba(255,255,255,.065); }
.hero-card::after { width: 210px; height: 210px; right: 35px; bottom: -150px; border-width: 22px; border-color: rgba(255,255,255,.075); }
.hero-copy { position: relative; z-index: 1; max-width: 540px; }
.status-chip { display: inline-block; padding: 7px 12px; background: rgba(255,255,255,.14); border: 1px solid rgba(255,255,255,.15); border-radius: 100px; font-size: 11px; font-weight: 700; }
.hero-copy h2 { font-size: clamp(28px, 3.4vw, 42px); letter-spacing: -1.2px; margin: 18px 0 10px; }
.hero-copy p { color: #dcf5ff; line-height: 1.6; }
.hero-actions { display: flex; gap: 18px; align-items: center; margin-top: 27px; }
.hero-actions > span { color: #d8f4ff; font-size: 12px; }
.primary-btn { height: 50px; padding: 0 22px; border: 0; border-radius: 14px; display: inline-flex; justify-content: center; align-items: center; gap: 10px; color: var(--purple); background: #fff; font-weight: 800; box-shadow: 0 6px 0 rgba(43, 33, 132, .3); transition: .2s ease; }
.primary-btn:hover { background: #f8f7ff; box-shadow: 0 4px 0 rgba(43, 33, 132, .3); transform: translateY(2px); }.primary-btn svg { width: 18px; }
.progress-orbit { width: 176px; height: 176px; flex: 0 0 176px; position: relative; z-index: 1; }
.progress-orbit > svg { width: 100%; height: 100%; transform: rotate(-90deg); }
.orbit-bg, .orbit-value { fill: none; stroke-width: 10; }.orbit-bg { stroke: rgba(255,255,255,.14); }.orbit-value { stroke: #8ff0c7; stroke-dasharray: 414.69; stroke-dashoffset: 414.69; transition: stroke-dashoffset .6s ease; }
.progress-orbit > div { position: absolute; inset: 0; display: grid; place-content: center; text-align: center; }.progress-orbit strong { font-size: 30px; }.progress-orbit span { color: #d8f4ff; font-size: 10px; margin-top: 4px; }

.section-heading { display: flex; justify-content: space-between; align-items: end; margin: 42px 0 18px; }
.section-heading h2 { font-size: 22px; margin: 0; }
.text-btn { border: 0; background: transparent; color: var(--purple); display: flex; align-items: center; gap: 5px; padding: 8px; font-weight: 700; font-size: 12px; }.text-btn svg { width: 16px; }
.word-preview { display: grid; grid-template-columns: repeat(4, 1fr); gap: 14px; }
.word-tile { padding: 20px; min-width: 0; border: 1px solid var(--line); border-radius: 19px; background: #fff; box-shadow: 0 8px 24px rgba(50, 57, 91, .045); transition: .2s ease; }
.word-tile:hover { border-color: #d9d5fb; box-shadow: 0 12px 30px rgba(50,57,91,.08); }
.word-tile-top { display: flex; align-items: center; justify-content: space-between; gap: 6px; }.word-tile h3 { margin: 14px 0 4px; font-size: 18px; overflow-wrap: anywhere; }.word-tile p { color: var(--muted); font-size: 13px; margin: 0; }.word-tile .part-tag { font-size: 9px; }
.tile-state { width: 9px; height: 9px; border-radius: 50%; background: #e3e5ec; }.tile-state.done { background: var(--green); box-shadow: 0 0 0 4px var(--green-soft); }.tile-state.review { background: var(--amber); box-shadow: 0 0 0 4px #fff3e5; }
.bottom-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; margin-top: 18px; }
.info-card { display: flex; gap: 16px; align-items: center; padding: 22px; border: 1px solid var(--line); border-radius: 20px; background: #fff; }
.info-icon { width: 47px; height: 47px; display: grid; place-items: center; border-radius: 14px; }.info-icon svg { width: 21px; }.info-icon.purple { color: var(--purple); background: var(--purple-soft); }.info-icon.green { color: var(--green); background: var(--green-soft); }
.info-card small, .info-card strong, .info-card span { display: block; }.info-card small { color: #9499aa; font-size: 10px; }.info-card strong { font-size: 18px; margin: 3px 0; }.info-card span { color: var(--muted); font-size: 11px; }

.learn-head { display: flex; align-items: center; gap: 16px; }
.learn-head h1 { font-size: 27px; margin: 0; }.learn-head .eyebrow { margin-bottom: 4px; }
.back-btn { width: 44px; height: 44px; display: grid; place-items: center; border: 1px solid var(--line); border-radius: 13px; background: #fff; color: var(--ink); }.back-btn svg { transform: rotate(180deg); width: 19px; }
.count-badge { margin-left: auto; color: #8a8fa0; padding: 9px 13px; border-radius: 12px; background: #fff; border: 1px solid var(--line); font-size: 12px; }.count-badge b { color: var(--purple); font-size: 16px; }
.step-track { height: 6px; border-radius: 10px; margin: 22px 0 34px; background: #e5e6ed; overflow: hidden; }.step-track span { height: 100%; width: 5%; display: block; border-radius: inherit; background: linear-gradient(90deg, var(--purple), #8a80ec); transition: width .3s ease; }
.learn-layout { position: relative; display: grid; grid-template-columns: minmax(0, 1fr) 270px; gap: 22px; align-items: stretch; isolation: isolate; }
.flashcard { min-height: 480px; padding: 34px 44px; border-radius: 30px 30px 42px 30px; background: #fff; border: 1px solid #dcebf2; box-shadow: 0 20px 60px rgba(22,92,130,.12); display: flex; flex-direction: column; overflow: hidden; position: relative; }
.flashcard::after { content:""; position:absolute; width:180px; height:180px; right:-92px; top:-92px; border:25px solid #edf9fe; border-radius:50%; pointer-events:none; }
.card-top { display: flex; justify-content: space-between; align-items: center; }
.part-tag { display: inline-block; padding: 6px 9px; color: var(--purple); background: var(--purple-soft); border-radius: 8px; font-size: 11px; font-weight: 800; }
.speech-control { display:flex; align-items:center; justify-content:flex-end; gap:10px; min-width:42px; }
.speech-status { max-width:190px; overflow:hidden; text-overflow:ellipsis; white-space:nowrap; color:#698297; font-size:11px; font-weight:700; transition:color .2s ease; }
.speech-status:empty { display:none; }
.speech-status[data-state="playing"] { color:#138f70; }
.speech-status[data-state="error"] { color:#cf5e54; }
.icon-btn { width: 42px; height: 42px; display: grid; place-items: center; border: 0; border-radius: 50%; color: var(--purple); background: var(--purple-soft); transition: .2s ease; }.icon-btn:hover { background: #dfdcff; }.icon-btn.speaking { animation: pulse .8s ease; }
@keyframes pulse { 50% { box-shadow: 0 0 0 8px rgba(101,88,216,.12); } }
.word-main { text-align: center; margin: 58px 0 48px; }.phonetic { color: #7d98aa; font-size: 14px; margin-bottom: 8px; }.word-main h2 { font-family: Inter, "Arial Rounded MT Bold", system-ui, sans-serif; font-size: clamp(48px, 6vw, 70px); font-weight: 900; letter-spacing: -3px; margin: 0 0 12px; color:#133b55; }.meaning { color: var(--purple); font-size: 20px; font-weight: 800; }
.example-box { margin-top: auto; padding: 22px; border-radius: 18px; background: #f8f8fc; }.example-box span { color: #9a9eae; font-size: 10px; font-weight: 700; }.example-box p { font-family: Georgia, serif; font-size: 16px; margin: 9px 0 6px; line-height: 1.55; }.example-box small { color: var(--muted); line-height: 1.5; }
.session-panel { padding: 28px; border-radius: 24px; background: #252c48; color: #fff; }.session-panel small { color: #9ea4bb; }.session-panel > div strong { display: block; font-size: 27px; margin-top: 6px; }.mini-bar { height: 5px; margin: 21px 0 25px; border-radius: 8px; background: #3c435f; overflow: hidden; }.mini-bar span { display: block; height: 100%; width: 0; background: #72d4ad; transition: width .3s ease; }.session-panel ul { list-style: none; padding: 0; margin: 0; }.session-panel li { display: flex; align-items: center; gap: 8px; color: #d9dce7; font-size: 13px; padding: 10px 0; border-bottom: 1px solid #363d59; }.session-panel li b { margin-left: auto; color: #fff; }.dot { width: 8px; height: 8px; border-radius: 50%; }.dot.green { background: #72d4ad; }.dot.amber { background: #f0af5d; }.session-panel p { color: #979db4; font-size: 11px; line-height: 1.6; margin: 29px 0 0; }
.rating-actions { width: min(600px, calc(100% - 292px)); display: grid; grid-template-columns: 1fr 1fr; gap: 14px; margin-top: 22px; }
.secondary-btn, .success-btn { min-height: 65px; display: flex; justify-content: center; align-items: center; gap: 12px; border-radius: 17px; transition: .2s ease; }.secondary-btn { color: #78603f; background: #fffaf2; border: 1px solid #f0ddc4; }.success-btn { color: #fff; background: var(--green); border: 1px solid var(--green); box-shadow: 0 6px 0 #14815a; }.secondary-btn:hover { background: #fff4e5; }.success-btn:hover { transform: translateY(2px); box-shadow: 0 4px 0 #14815a; }.rating-actions svg { width: 21px; }.rating-actions strong, .rating-actions small { display: block; text-align: left; }.rating-actions small { opacity: .7; font-size: 9px; margin-top: 2px; }

.stats-grid { display: grid; grid-template-columns: 1.4fr 1fr 1fr; gap: 16px; }.stat-card { position: relative; padding: 26px; min-height: 150px; border-radius: 23px; border: 1px solid var(--line); background: #fff; overflow: hidden; }.stat-card span, .stat-card small { color: var(--muted); font-size: 12px; }.stat-card strong { display: block; font-size: 42px; letter-spacing: -2px; margin: 17px 0 2px; }.stat-card.featured { color: #fff; background: var(--purple); border-color: var(--purple); }.stat-card.featured span, .stat-card.featured small { color: #dcd9ff; }.stat-card.featured svg { position: absolute; right: 24px; bottom: 24px; width: 54px; height: 54px; opacity: .18; }
.calendar-card, .review-list-card { padding: 28px; border-radius: 24px; border: 1px solid var(--line); background: #fff; margin-top: 20px; }.calendar-head { display: flex; justify-content: space-between; align-items: center; }.calendar-head h2 { margin: 0; }.calendar-head > span { padding: 8px 12px; border-radius: 10px; color: var(--purple); background: var(--purple-soft); font-size: 11px; font-weight: 700; }.week-grid { display: grid; grid-template-columns: repeat(7, 1fr); gap: 10px; margin-top: 28px; }.day-cell { min-height: 92px; display: grid; place-items: center; align-content: center; gap: 8px; border-radius: 14px; background: #f7f8fb; color: #9297a8; font-size: 11px; }.day-cell b { width: 30px; height: 30px; display: grid; place-items: center; border-radius: 50%; color: var(--ink); }.day-cell.done b { color: #fff; background: var(--green); }.day-cell.today { outline: 2px solid #dcd8ff; }.review-list-card .section-heading { margin-top: 0; }.review-row { display: grid; grid-template-columns: 1fr 1fr auto; gap: 15px; align-items: center; padding: 15px 0; border-top: 1px solid var(--line); }.review-row strong { font-family: Georgia, serif; }.review-row span { color: var(--muted); font-size: 12px; }.review-row button { border: 0; padding: 7px 11px; color: var(--purple); background: var(--purple-soft); border-radius: 9px; font-size: 11px; }.empty-state { color: var(--muted); padding: 24px 0; text-align: center; }

.deck-switch { display: inline-flex; gap: 4px; padding: 4px; margin-top: 18px; border: 1px solid var(--line); border-radius: 13px; background: #fff; }
.deck-switch button { border: 0; padding: 8px 15px; border-radius: 9px; color: #767b8d; background: transparent; font-size: 12px; font-weight: 700; transition: .2s ease; }
.deck-switch button:hover { color: var(--purple); }.deck-switch button.active { color: #fff; background: var(--purple); }
.deck-switch.large { margin: 0; align-self: flex-start; }.deck-switch.large button { padding: 10px 18px; }
.vocab-toolbar { display: flex; justify-content: space-between; align-items: center; gap: 18px; margin-bottom: 16px; }
.vocab-toolbar > span { color: var(--muted); font-size: 12px; white-space: nowrap; }
.search-box { width: min(560px, 100%); height: 48px; display: flex; align-items: center; gap: 11px; padding: 0 15px; border: 1px solid var(--line); border-radius: 14px; background: #fff; }
.search-box:focus-within { border-color: #b8b1f4; box-shadow: 0 0 0 4px rgba(101,88,216,.08); }.search-box svg { width: 19px; color: #979cad; }.search-box input { width: 100%; border: 0; outline: 0; color: var(--ink); background: transparent; }
.vocab-table-card { overflow: hidden; border: 1px solid var(--line); border-radius: 22px; background: #fff; }
.vocab-table-head, .vocab-row { display: grid; grid-template-columns: 1.1fr 2.4fr 90px; gap: 20px; align-items: center; }
.vocab-table-head { padding: 14px 22px; color: #969bad; background: #f8f8fb; font-size: 10px; font-weight: 800; letter-spacing: .7px; }
.vocab-row { min-height: 68px; padding: 12px 22px; border-top: 1px solid var(--line); }.vocab-row strong { font-family: Georgia, serif; font-size: 17px; }.vocab-row p { margin: 0; color: var(--muted); font-size: 13px; line-height: 1.55; }.speak-link { width: 38px; height: 38px; display: grid; place-items: center; margin-left: auto; border: 0; border-radius: 11px; color: var(--purple); background: var(--purple-soft); }.speak-link svg { width: 18px; }
.pagination { display: flex; justify-content: center; align-items: center; gap: 6px; margin-top: 20px; }.pagination button { min-width: 36px; height: 36px; border: 1px solid var(--line); border-radius: 10px; color: #6e7487; background: #fff; }.pagination button.active { color: #fff; border-color: var(--purple); background: var(--purple); }.pagination button:disabled { opacity: .35; cursor: default; }.pagination span { color: #989dae; padding: 0 3px; }

.mode-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; margin-bottom: 20px; }
.mode-card { display: grid; grid-template-columns: 48px 1fr; column-gap: 15px; align-items: center; padding: 18px; text-align: left; border: 1px solid var(--line); border-radius: 19px; color: var(--ink); background: #fff; transition: .2s ease; }.mode-card:hover { border-color: #ccc7f8; box-shadow: 0 10px 28px rgba(48,53,83,.07); }.mode-card.active { border-color: #aea6ef; box-shadow: 0 0 0 3px rgba(101,88,216,.08); }.mode-card .mode-icon { grid-row: 1 / 3; width: 48px; height: 48px; display: grid; place-items: center; border-radius: 14px; }.mode-icon.purple { color: var(--purple); background: var(--purple-soft); }.mode-icon.green { color: var(--green); background: var(--green-soft); }.mode-card strong { align-self: end; }.mode-card small { align-self: start; margin-top: 3px; color: var(--muted); }
.training-card, .exam-runner { max-width: 800px; min-height: 510px; margin: 0 auto; padding: 34px 48px 38px; border: 1px solid var(--line); border-radius: 28px; background: #fff; box-shadow: var(--shadow); }.quiz-meta, .exam-runner-head { display: flex; justify-content: space-between; align-items: center; }.quiz-meta span { padding: 6px 10px; color: var(--purple); background: var(--purple-soft); border-radius: 8px; font-size: 11px; font-weight: 800; }.quiz-meta strong, .exam-runner-head { color: #7d8294; font-size: 12px; }.quiz-progress { height: 6px; margin: 18px 0 45px; overflow: hidden; border-radius: 10px; background: #e9eaf0; }.quiz-progress span { display: block; width: 10%; height: 100%; border-radius: inherit; background: linear-gradient(90deg, var(--purple), #8d83ee); transition: width .25s ease; }.quiz-kicker { color: #979cac; font-size: 11px; font-weight: 800; letter-spacing: .8px; text-align: center; }.quiz-word { min-height: 58px; margin: 11px 0 30px; font-family: Georgia, serif; font-size: clamp(34px, 5vw, 53px); text-align: center; letter-spacing: -1px; }.option-list { display: grid; grid-template-columns: 1fr 1fr; gap: 11px; }.option-btn { min-height: 62px; padding: 13px 16px; border: 1px solid var(--line); border-radius: 14px; color: #4f5568; background: #fafbfc; text-align: left; line-height: 1.45; transition: .18s ease; }.option-btn:hover { border-color: #bcb6f4; background: #f5f3ff; }.option-btn.correct { color: #147d59; border-color: #83d7b9; background: #eaf8f3; }.option-btn.wrong { color: #b34949; border-color: #eab2b2; background: #fff0f0; }.option-btn:disabled { cursor: default; }
.spelling-form { display: none; max-width: 540px; margin: 0 auto; }.spelling-form.visible { display: block; }.spelling-form label { display: block; margin-bottom: 8px; color: var(--muted); font-size: 11px; }.spelling-form div { display: flex; gap: 10px; }.spelling-form input { flex: 1; height: 52px; padding: 0 16px; border: 1px solid var(--line); border-radius: 13px; outline: 0; font-size: 18px; }.spelling-form input:focus { border-color: var(--purple); }.spelling-form button { border: 0; padding: 0 22px; border-radius: 13px; color: #fff; background: var(--purple); font-weight: 700; }.quiz-feedback { min-height: 30px; margin-top: 18px; text-align: center; color: var(--green); font-size: 13px; font-weight: 700; }

.exam-setup { display: grid; grid-template-columns: 1.05fr 1fr; overflow: hidden; border: 1px solid var(--line); border-radius: 28px; background: #fff; box-shadow: var(--shadow); }.setup-copy { padding: 48px; color: #fff; background: linear-gradient(145deg,#28b6e8,#087fbd); }.setup-icon { width: 58px; height: 58px; display: grid; place-items: center; margin-bottom: 44px; border-radius: 17px; color: #fff; background: rgba(255,255,255,.14); }.setup-icon svg { width: 28px; height: 28px; }.setup-copy h2 { font-size: 28px; }.setup-copy p { color: #daf4ff; line-height: 1.75; }.setup-options { padding: 42px; }.setup-options fieldset { margin: 0 0 30px; padding: 0; border: 0; }.setup-options legend { margin-bottom: 10px; color: var(--muted); font-size: 11px; font-weight: 700; }.choice-row { display: grid; grid-template-columns: 1fr 1fr; gap: 9px; }.choice-row label { position: relative; }.choice-row input { position: absolute; opacity: 0; }.choice-row span { display: grid; place-items: center; height: 48px; border: 1px solid var(--line); border-radius: 12px; color: #6d7284; font-size: 13px; cursor: pointer; }.choice-row input:checked + span { color: var(--purple); border-color: #9bd8f2; background: var(--purple-soft); font-weight: 700; }.exam-start-btn { width: 100%; height: 52px; display: flex; justify-content: center; align-items: center; gap: 8px; border: 0; border-radius: 14px; color: #fff; background: var(--purple); box-shadow: 0 6px 0 #0878ae; font-weight: 800; }.exam-start-btn svg { width: 18px; }
.exam-runner { display: none; }.exam-runner.active { display: block; }.exam-timer { padding: 7px 11px; border-radius: 9px; color: #b56b1c; background: #fff3e4; font-variant-numeric: tabular-nums; font-weight: 800; }.exam-submit-link { display: block; margin: 25px auto 0; border: 0; color: #9b6b6b; background: transparent; font-size: 11px; }.exam-result { display: none; max-width: 760px; margin: 0 auto; padding: 38px; border: 1px solid var(--line); border-radius: 28px; background: #fff; box-shadow: var(--shadow); text-align: center; }.exam-result.active { display: block; }.score-orb { width: 132px; height: 132px; display: grid; place-items: center; align-content: center; margin: 0 auto 25px; border-radius: 50%; color: #fff; background: var(--purple); box-shadow: 0 12px 0 #ddd9ff; }.score-orb strong { font-size: 44px; line-height: 1; }.score-orb small { color: #ddd9ff; }.wrong-list { margin-top: 28px; text-align: left; }.wrong-item { display: grid; grid-template-columns: 1fr 2fr; gap: 15px; padding: 12px 0; border-top: 1px solid var(--line); }.wrong-item span { color: var(--muted); font-size: 12px; }

.record-summary { display: grid; grid-template-columns: repeat(3,1fr); gap: 14px; margin-bottom: 20px; }.record-summary article { padding: 24px; border: 1px solid var(--line); border-radius: 20px; background: #fff; }.record-summary small { display: block; color: var(--muted); }.record-summary strong { display: inline-block; margin-top: 9px; font-size: 35px; }.record-summary span { color: var(--muted); font-size: 12px; margin-left: 4px; }.records-card { overflow: hidden; border: 1px solid var(--line); border-radius: 22px; background: #fff; }.records-head, .record-row { display: grid; grid-template-columns: 1.4fr 1.4fr .8fr .8fr .8fr; gap: 14px; align-items: center; padding: 15px 22px; }.records-head { color: #969bad; background: #f8f8fb; font-size: 10px; font-weight: 800; }.record-row { min-height: 63px; border-top: 1px solid var(--line); color: #606678; font-size: 12px; }.record-row strong { color: var(--purple); font-size: 17px; }.records-empty { padding: 55px 20px; color: var(--muted); text-align: center; }

.mobile-head, .bottom-nav { display: none; }
.modal { position: fixed; inset: 0; z-index: 20; display: grid; place-items: center; padding: 20px; background: rgba(25,30,52,.54); backdrop-filter: blur(6px); opacity: 0; pointer-events: none; transition: .25s ease; }.modal.open { opacity: 1; pointer-events: auto; }.modal-card { width: min(440px, 100%); padding: 42px; border-radius: 28px; background: #fff; text-align: center; transform: translateY(12px) scale(.98); transition: .25s ease; }.modal.open .modal-card { transform: none; }.celebrate { width: 64px; height: 64px; display: grid; place-items: center; margin: 0 auto 20px; color: var(--purple); background: var(--purple-soft); border-radius: 20px; box-shadow: 0 7px 0 #d9d5ff; }.celebrate svg { width: 31px; height: 31px; }.modal-card h2 { font-size: 27px; margin-bottom: 10px; }.modal-card > p:not(.eyebrow) { color: var(--muted); line-height: 1.65; }.modal-stats { display: grid; grid-template-columns: 1fr 1fr; margin: 24px 0; }.modal-stats span { color: var(--muted); font-size: 11px; }.modal-stats span + span { border-left: 1px solid var(--line); }.modal-stats strong { color: var(--ink); display: block; font-size: 25px; }.primary-btn.wide { width: 100%; color: #fff; background: var(--purple); box-shadow: 0 6px 0 #4338a9; }

@media (max-width: 900px) {
  .sidebar { width: 88px; padding: 28px 16px; align-items: center; }.sidebar .brand > span:last-child, .nav-item span, .daily-tip, .profile-mini > span:last-child { display: none; }.side-nav { width: 100%; margin-top: 45px; }.nav-item { justify-content: center; padding: 12px; }.profile-mini { margin-top: auto; border: 0; }.main { margin-left: 88px; padding-inline: 28px; }.word-preview { grid-template-columns: repeat(2,1fr); }.learn-layout { grid-template-columns: 1fr; }.session-panel { display: none; }.rating-actions { width: 100%; }.stats-grid { grid-template-columns: 1.3fr 1fr 1fr; }.exam-setup { grid-template-columns: 1fr; }.setup-copy { padding: 32px; }.setup-icon { margin-bottom: 20px; }
}

@media (max-width: 640px) {
  body { background: #f3f9fc; }.sidebar { display: none; }.main { margin: 0; padding: 0 18px 100px; }.mobile-head { height: 70px; display: flex; justify-content: space-between; align-items: center; }.mobile-head .brand { gap: 9px; }.mobile-head .brand-mark { width: 34px; height: 34px; border-radius: 11px 11px 14px 11px; font-size: 13px; box-shadow: 0 4px 0 #bce9fb; }.mobile-head .brand strong { font-size: 17px; }.mobile-streak { display: flex; gap: 5px; align-items: center; color: #dc8736; font-weight: 700; }.mobile-streak svg { width: 18px; fill: #fff1dd; }
  .topline { margin: 15px 2px 25px; }.topline .streak-pill { display: none; }h1 { font-size: 26px; }.subtitle { font-size: 13px; line-height: 1.6; }
  .hero-card { min-height: 320px; display: block; padding: 28px; border-radius: 25px; }.hero-copy h2 { font-size: 29px; margin-top: 16px; }.hero-copy p { font-size: 13px; }.hero-actions { margin-top: 23px; }.hero-actions > span { display: none; }.progress-orbit { position: absolute; width: 92px; height: 92px; right: 18px; bottom: 16px; }.orbit-bg, .orbit-value { stroke-width: 12; }.progress-orbit strong { font-size: 19px; }.progress-orbit span { font-size: 8px; }
  .section-heading { margin-top: 30px; }.word-preview { grid-template-columns: 1fr 1fr; gap: 10px; }.word-tile { padding: 15px; }.word-tile:nth-child(n+7) { display: none; }.word-tile h3 { font-size: 16px; }.bottom-grid { grid-template-columns: 1fr; }.info-card { padding: 18px; }
  .bottom-nav { position: fixed; z-index: 10; left: 12px; right: 12px; bottom: 12px; height: 68px; display: grid; grid-template-columns: repeat(5, 1fr); padding: 7px; border: 1px solid rgba(226,228,237,.9); border-radius: 22px; background: rgba(255,255,255,.94); box-shadow: 0 12px 35px rgba(45,52,82,.16); backdrop-filter: blur(14px); }.bottom-nav button { display: grid; place-items: center; align-content: center; gap: 3px; border: 0; border-radius: 15px; background: transparent; color: #969bad; font-size: 9px; }.bottom-nav button.active { color: var(--purple); background: var(--purple-soft); font-weight: 700; }.bottom-nav svg { width: 18px; height: 18px; }
  .learn-head { margin-top: 10px; }.learn-head h1 { font-size: 21px; }.learn-head .eyebrow { display: none; }.step-track { margin: 18px 0 20px; }.flashcard { min-height: 455px; padding: 25px 22px; border-radius: 24px; }.word-main { margin: 53px 0 38px; }.word-main h2 { font-size: 45px; }.example-box { padding: 18px; }.rating-actions { position: sticky; bottom: 90px; gap: 10px; }.secondary-btn, .success-btn { min-height: 60px; }.stats-grid { grid-template-columns: 1fr 1fr; }.stat-card.featured { grid-column: 1 / -1; }.week-grid { gap: 5px; }.day-cell { min-height: 75px; }.calendar-card, .review-list-card { padding: 20px 15px; }.review-row { grid-template-columns: 1fr auto; }.review-row span { display: none; }.modal-card { padding: 34px 24px; }.vocab-topline { display: block; }.deck-switch.large { margin-top: 18px; }.vocab-toolbar { align-items: stretch; flex-direction: column; }.vocab-table-head, .vocab-row { grid-template-columns: 1fr 2fr 42px; gap: 10px; padding-inline: 14px; }.vocab-row p { font-size: 11px; }.vocab-row strong { font-size: 15px; }.pagination button { min-width: 33px; }.mode-grid { grid-template-columns: 1fr; }.training-card, .exam-runner { min-height: 480px; padding: 25px 18px; border-radius: 23px; }.option-list { grid-template-columns: 1fr; }.quiz-progress { margin-bottom: 32px; }.exam-setup { border-radius: 23px; }.setup-copy, .setup-options { padding: 27px 22px; }.setup-copy h2 { font-size: 23px; }.choice-row { grid-template-columns: 1fr 1fr; }.record-summary { grid-template-columns: repeat(3,1fr); gap: 7px; }.record-summary article { padding: 16px 12px; }.record-summary strong { font-size: 25px; }.records-head, .record-row { grid-template-columns: 1.4fr 1fr .7fr .7fr; padding-inline: 12px; gap: 7px; }.records-head span:nth-child(4), .record-row span:nth-child(4) { display: none; }
}

@media (prefers-reduced-motion: reduce) { *, *::before, *::after { scroll-behavior: auto !important; animation-duration: .01ms !important; transition-duration: .01ms !important; } }
button:focus-visible, a:focus-visible { outline: 3px solid rgba(101,88,216,.35); outline-offset: 3px; }

/* Gamified blue visual language inspired by modern vocabulary apps. */
.session-panel { border-radius: 24px 24px 34px 24px; background: #123a55; }
.session-panel small, .session-panel p { color: #9fc3d8; }
.session-panel li { color: #d6e5ed; border-bottom-color: #2a5069; }
.mini-bar { background: #2c536c; }.mini-bar span { background: #6ce1b1; }
.secondary-btn, .success-btn { border-radius: 17px 17px 22px 17px; }
.secondary-btn { color: #627384; background: #fff; border-color: #dbe8ee; }
.secondary-btn:hover { background: #f3f9fc; }
.success-btn { background: linear-gradient(135deg,#26c98f,#17ac77); border-color: #20b981; box-shadow: 0 6px 0 #0d895c, 0 14px 30px rgba(24,174,120,.2); }
.success-btn:hover { box-shadow: 0 4px 0 #0d895c, 0 9px 22px rgba(24,174,120,.17); }
.word-tile:hover { border-color:#bde6f7; box-shadow:0 14px 32px rgba(18,137,190,.1); transform:translateY(-2px); }
.nav-item.active { box-shadow: inset 3px 0 0 var(--purple); }
.deck-switch button.active { box-shadow:0 4px 12px rgba(20,149,210,.22); }

/* “学会了”斩词动效：卡片按同一斜线分层，上下两半沿切口分离。 */
.slash-source { visibility: hidden; }
.slash-clone { position: absolute !important; z-index: 12; margin: 0 !important; pointer-events: none; transform-origin: center; will-change: transform, opacity, filter; }
.slash-clone.slash-upper { clip-path: polygon(0 0,100% 0,100% 35%,0 68%); animation: slashUpper .72s cubic-bezier(.22,.85,.32,1) forwards; }
.slash-clone.slash-lower { clip-path: polygon(0 68%,100% 35%,100% 100%,0 100%); animation: slashLower .72s cubic-bezier(.22,.85,.32,1) forwards; }
.slash-blade { position:absolute; z-index:15; pointer-events:none; height:4px; border-radius:50%; background:linear-gradient(90deg,transparent,#e9ffff 15%,#fff 55%,#7cefff 82%,transparent); box-shadow:0 0 8px #fff,0 0 22px #54ddff,0 0 42px rgba(44,196,255,.8); transform-origin:center; animation: bladeCut .48s cubic-bezier(.16,.8,.3,1) forwards; }
.slash-burst { position:absolute; z-index:16; pointer-events:none; width:7px; height:7px; border-radius:50%; background:#fff; box-shadow:0 0 10px #77e9ff; animation:sparkBurst .62s ease-out forwards; }
.mastered-pop { position:absolute; z-index:17; pointer-events:none; padding:10px 17px; border-radius:100px; color:#fff; background:#17b97c; font-size:12px; font-weight:900; letter-spacing:.8px; box-shadow:0 9px 24px rgba(20,169,113,.28); animation:masteredPop .72s ease both; }
.card-review-pulse { animation:reviewPulse .28s ease; }
@keyframes bladeCut { 0% { opacity:0; transform:translate(-38%,-50%) rotate(-18deg) scaleX(.15); } 35% { opacity:1; } 100% { opacity:0; transform:translate(28%,-50%) rotate(-18deg) scaleX(1.08); } }
@keyframes slashUpper { 0%,25% { opacity:1; transform:none; filter:none; } 100% { opacity:0; transform:translate(-32px,-24px) rotate(-2.2deg); filter:blur(1px); } }
@keyframes slashLower { 0%,25% { opacity:1; transform:none; filter:none; } 100% { opacity:0; transform:translate(32px,28px) rotate(2.2deg); filter:blur(1px); } }
@keyframes sparkBurst { 0% { opacity:1; transform:scale(1); } 100% { opacity:0; transform:translate(var(--sx),var(--sy)) scale(.15); } }
@keyframes masteredPop { 0% { opacity:0; transform:translateY(10px) scale(.8); } 35%,75% { opacity:1; transform:translateY(0) scale(1); } 100% { opacity:0; transform:translateY(-10px) scale(.96); } }
@keyframes reviewPulse { 40% { transform:translateX(-5px); } 70% { transform:translateX(3px); } }

/* Word-image memory panel */
.flashcard { display:grid; grid-template-columns: minmax(210px,.92fr) minmax(240px,1.08fr); grid-template-areas:"top top" "visual word" "example example"; gap:18px 26px; min-height:520px; }
.flashcard .card-top { grid-area:top; position:relative; z-index:3; }
.flashcard .word-main { grid-area:word; align-self:center; margin:0; text-align:left; position:relative; z-index:2; }
.flashcard .word-main h2 { font-size:clamp(40px,4.7vw,62px); overflow-wrap:anywhere; }
.flashcard .example-box { grid-area:example; margin-top:0; position:relative; z-index:2; }
.memory-visual { grid-area:visual; position:relative; min-height:250px; margin:0; overflow:hidden; border-radius:24px 24px 32px 24px; background:linear-gradient(145deg,#dff5fd,#b9e8fa); box-shadow:inset 0 0 0 1px rgba(13,145,205,.08); isolation:isolate; }
.memory-visual img { position:absolute; inset:0; z-index:1; width:100%; height:100%; object-fit:cover; opacity:0; transform:scale(1.025); transition:opacity .35s ease,transform .8s ease; }
.memory-visual.is-ready img { opacity:1; transform:scale(1); }
.image-shade { position:absolute; inset:0; z-index:2; pointer-events:none; background:linear-gradient(180deg,rgba(5,35,53,.04) 35%,rgba(5,35,53,.66) 100%); opacity:0; transition:opacity .3s ease; }
.memory-visual.is-ready .image-shade { opacity:1; }
.visual-badge { position:absolute; z-index:4; left:14px; top:14px; display:flex; align-items:center; gap:5px; padding:7px 10px; border-radius:100px; color:#fff; background:rgba(10,58,82,.48); border:1px solid rgba(255,255,255,.24); backdrop-filter:blur(8px); font-size:10px; font-weight:800; }
.visual-badge svg { width:14px; height:14px; }
.image-source-btn { position:absolute; z-index:5; right:13px; top:13px; padding:7px 10px; border:1px solid rgba(255,255,255,.35); border-radius:100px; color:#fff; background:rgba(10,58,82,.52); backdrop-filter:blur(8px); font-size:10px; font-weight:800; text-decoration:none; }
.image-source-btn:hover { background:rgba(10,58,82,.72); }
.image-next-btn { position:absolute; z-index:5; left:13px; bottom:11px; display:none; padding:7px 10px; border:1px solid rgba(255,255,255,.35); border-radius:100px; color:#fff; background:rgba(10,58,82,.52); backdrop-filter:blur(8px); font-size:10px; font-weight:800; }
.image-next-btn.available { display:block; }
.image-next-btn:hover { background:rgba(10,58,82,.72); }
.image-credit { position:absolute; z-index:4; right:13px; bottom:11px; max-width:75%; overflow:hidden; color:rgba(255,255,255,.9); text-decoration:none; text-overflow:ellipsis; white-space:nowrap; font-size:9px; opacity:0; }
.memory-visual.is-ready .image-credit { opacity:1; }.image-credit:hover { color:#fff; text-decoration:underline; }
.image-skeleton { position:absolute; inset:0; z-index:3; display:grid; place-items:center; overflow:hidden; background:linear-gradient(135deg,#e6f7fd,#c8edf9); }
.image-skeleton::after { content:""; position:absolute; inset:-50%; background:linear-gradient(105deg,transparent 42%,rgba(255,255,255,.72) 50%,transparent 58%); animation:imageShimmer 1.15s linear infinite; }
.image-skeleton span { width:48px; height:38px; border:3px solid rgba(19,141,193,.25); border-radius:10px; }
.memory-visual:not(.is-loading) .image-skeleton { display:none; }
.image-fallback { position:absolute; inset:0; z-index:3; display:none; place-items:center; align-content:center; color:#0b82b8; background:radial-gradient(circle at 75% 20%,rgba(255,255,255,.85) 0 16%,transparent 17%),linear-gradient(145deg,#e3f7fe,#bceafb); }
.image-fallback::before,.image-fallback::after { content:""; position:absolute; border-radius:50%; background:rgba(255,255,255,.46); }.image-fallback::before { width:130px;height:130px;left:-50px;bottom:-55px; }.image-fallback::after { width:72px;height:72px;right:-20px;top:42px; }
.image-fallback strong { position:relative; z-index:1; font-size:76px; line-height:1; font-weight:950; text-transform:uppercase; text-shadow:0 5px 0 rgba(255,255,255,.65); }.image-fallback span { position:relative; z-index:1; margin-top:10px; font-size:11px; font-weight:800; }
.memory-visual.is-fallback .image-fallback { display:grid; }
@keyframes imageShimmer { to { transform:translateX(50%); } }

@media (max-width:640px) {
  .flashcard { display:grid; grid-template-columns:1fr; grid-template-areas:"top" "visual" "word" "example"; gap:15px; min-height:590px; padding:22px; }
  .memory-visual { min-height:190px; border-radius:20px 20px 27px 20px; }
  .flashcard .word-main { text-align:center; margin:10px 0 2px; }
  .flashcard .word-main h2 { font-size:42px; }
  .image-credit { max-width:68%; }
}

/* Active-recall reveal state */
.reveal-meaning-btn { display:none; align-items:center; gap:6px; margin:17px 0 0; padding:10px 14px; border:1px solid #a9dff4; border-radius:12px; color:var(--purple-dark); background:var(--purple-soft); font-size:12px; font-weight:800; }
.reveal-meaning-btn svg { width:16px; height:16px; }
.flashcard.is-concealed .reveal-meaning-btn { display:inline-flex; }
.flashcard.is-concealed .meaning { opacity:.18; filter:blur(9px); user-select:none; }
.flashcard.is-concealed .example-box > :not(span) { visibility:hidden; }
.flashcard.is-concealed .example-box::after { content:"先看单词和图片，在脑中回忆它的意思"; position:absolute; inset:0; display:grid; place-items:center; padding:20px; color:#6b8798; font-size:12px; font-weight:800; text-align:center; }
.rating-actions.is-locked { opacity:.46; filter:saturate(.45); }
.rating-actions.is-locked button { pointer-events:none; }
.flashcard.meaning-revealed .meaning,.flashcard.meaning-revealed .example-box { animation:meaningReveal .34s ease both; }
@keyframes meaningReveal { from { opacity:.25; transform:translateY(5px); } to { opacity:1; transform:none; } }

/* Legacy API dialog styles retained for compatibility with older cached markup. */
.api-key-card { position:relative; text-align:left; }
.api-key-card > h2, .api-key-card > p { text-align:left; }
.modal-close { position:absolute; right:18px; top:16px; width:36px; height:36px; border:0; border-radius:12px; color:#6f8291; background:#edf5f9; font-size:24px; line-height:1; }
.api-key-field { display:grid; gap:8px; margin-top:22px; }
.api-key-field span { color:var(--ink); font-size:12px; font-weight:800; }
.api-key-field input { width:100%; height:50px; padding:0 15px; border:1px solid #cfe0e9; border-radius:14px; outline:none; color:var(--ink); background:#f8fbfd; font:inherit; }
.api-key-field input:focus { border-color:#27addd; box-shadow:0 0 0 4px rgba(39,173,221,.12); }
.api-key-note { margin-top:10px; font-size:11px; }
.api-key-note a { color:#168dbc; font-weight:800; }
.api-key-status { min-height:34px; margin-top:12px; padding:9px 11px; border-radius:10px; color:#607887; background:#f2f7fa; font-size:11px; line-height:1.45; }
.api-key-status.success { color:#15795f; background:#e9f8f2; }
.api-key-status.error { color:#a84a4a; background:#fff0f0; }
.api-key-actions { display:grid; grid-template-columns:1fr 1fr; gap:12px; margin-top:17px; }
.api-key-actions button { min-height:48px; border-radius:14px; }
.api-key-actions .primary-btn { color:#fff; background:var(--purple); box-shadow:none; }

@media (max-width:640px) {
  .api-key-actions { grid-template-columns:1fr; }
  .api-key-actions .secondary-btn { min-height:48px; }
}

/* Four-step learning chain */
.learning-mode-heading { display:flex; align-items:center; justify-content:space-between; max-width:720px; margin:-2px auto 10px; color:#49697c; }
.learning-mode-heading strong { font-size:12px; }
.learning-mode-heading span { color:#8a9da9; font-size:10px; }
.learning-chain { display:grid; grid-template-columns:repeat(4,1fr); gap:9px; max-width:720px; margin:0 auto 22px; }
.learning-chain > button { min-width:0; min-height:66px; display:grid; grid-template-columns:34px 1fr; grid-template-rows:auto auto; align-items:center; column-gap:9px; padding:10px 12px; border:1px solid #d8e4ea; border-radius:16px; color:#6f8795; background:#fff; box-shadow:0 4px 0 #e4eef2; text-align:left; cursor:pointer; transition:border-color .2s ease,color .2s ease,background .2s ease,box-shadow .2s ease; }
.learning-chain > button:hover { color:#168fba; border-color:#a5deef; background:#f4fcff; box-shadow:0 4px 0 #ccecf6; }
.learning-chain > button b { grid-row:1 / 3; width:34px; height:34px; display:grid; place-items:center; border:1px solid #d8e4ea; border-radius:11px; background:#f8fbfc; transition:.2s ease; }
.learning-chain > button svg { width:16px; height:16px; fill:none; stroke:currentColor; stroke-width:1.8; }
.learning-chain > button em { align-self:end; color:inherit; font-size:12px; font-style:normal; font-weight:850; white-space:nowrap; }
.learning-chain > button small { align-self:start; overflow:hidden; color:#9aabb4; font-size:9px; font-weight:700; text-overflow:ellipsis; white-space:nowrap; }
.learning-chain > button.active { color:#fff; border-color:#1facdc; background:linear-gradient(145deg,#25b6e5,#159cca); box-shadow:0 5px 0 #1288b2,0 9px 18px rgba(31,172,220,.18); }
.learning-chain > button.active b { color:#fff; border-color:rgba(255,255,255,.35); background:rgba(255,255,255,.16); }
.learning-chain > button.active small { color:rgba(255,255,255,.78); }

.chain-controls { display:grid; justify-items:start; gap:12px; margin-top:18px; }
.chain-controls > p { max-width:330px; color:#66808f; font-size:12px; line-height:1.6; }
.chain-primary { display:inline-flex; align-items:center; gap:7px; min-height:44px; padding:0 17px; border:0; border-radius:13px; color:#fff; background:#1aa9d9; box-shadow:0 5px 0 #1288b2; font-size:12px; font-weight:850; }
.chain-primary svg { width:16px; height:16px; fill:none; stroke:currentColor; stroke-width:2; }
.learn-spelling-form { display:none; width:min(360px,100%); }
.learn-spelling-form.visible { display:grid; gap:8px; }
.learn-spelling-form label { color:#33556a; font-size:11px; font-weight:800; }
.learn-spelling-form > div { display:flex; gap:8px; }
.learn-spelling-form input { min-width:0; flex:1; height:48px; padding:0 14px; border:1px solid #bfdde9; border-radius:13px; outline:none; color:#123a55; background:#f8fcfe; font:700 17px/1 Arial,sans-serif; letter-spacing:1px; }
.learn-spelling-form input:focus { border-color:#21a9d8; box-shadow:0 0 0 4px rgba(33,169,216,.12); }
.learn-spelling-form button { min-width:72px; border:0; border-radius:13px; color:#fff; background:#1aa9d9; font-weight:850; }
.learn-spelling-feedback { min-height:18px; color:#5d7483; font-size:11px; font-weight:750; }
.learn-spelling-feedback.correct { color:#158467; }
.learn-spelling-feedback.wrong { color:#b34c4c; }

.flashcard.chain-visual .word-main h2,.flashcard.chain-visual .meaning,.flashcard.chain-audio .word-main h2,.flashcard.chain-audio .meaning,.flashcard.chain-spelling .word-main h2,.flashcard.chain-spelling .meaning { display:none; }
.flashcard:not(.chain-example) .example-box { visibility:hidden; opacity:0; }
.flashcard.chain-example .example-box { visibility:visible; opacity:1; animation:meaningReveal .34s ease both; }
.flashcard.chain-example .word-main h2,.flashcard.chain-example .meaning { display:block; }
.definition-line { display:flex; align-items:flex-start; gap:10px; margin-top:12px; padding-top:12px; border-top:1px solid rgba(100,125,142,.14); }
.definition-line b { flex:0 0 auto; color:#5c7686; font-size:10px; }
.definition-line span { color:#29495d; font-size:12px; line-height:1.6; }
.example-heading { display:flex; align-items:center; justify-content:space-between; gap:12px; }
.example-heading > a { flex:0 0 auto; padding:5px 8px; border:1px solid #d6e8ef; border-radius:999px; color:#168fba; background:#f2fbfe; text-decoration:none; font-size:9px; font-weight:850; transition:border-color .2s ease,background .2s ease; }
.example-heading > a[href]:hover { border-color:#8ed3e9; background:#e3f7fc; }
.dictionary-line[hidden],.dictionary-synonyms[hidden] { display:none; }
.dictionary-line b { min-width:48px; color:#168fba; }
.dictionary-synonyms { display:flex; align-items:flex-start; gap:10px; margin-top:11px; }
.dictionary-synonyms b { flex:0 0 auto; min-width:48px; color:#5c7686; font-size:10px; }
.dictionary-synonyms span { color:#168fba; font-size:11px; font-weight:750; line-height:1.6; }
.rating-actions.chain-hidden { opacity:0; pointer-events:none; transform:translateY(8px); }
.rating-actions { transition:opacity .22s ease,transform .22s ease; }

/* Wrong-word notebook */
.wrongbook-topline { align-items:flex-end; }
.wrongbook-train-btn { width:auto; min-width:190px; padding-inline:24px; }
.wrongbook-summary { display:grid; grid-template-columns:repeat(3,1fr); gap:16px; margin-bottom:22px; }
.wrongbook-summary article { padding:22px; border:1px solid #e0e9ee; border-radius:20px; background:#fff; box-shadow:0 10px 28px rgba(40,75,95,.06); }
.wrongbook-summary small,.wrongbook-summary span { color:#7b909d; font-size:11px; }
.wrongbook-summary strong { display:block; margin:7px 0 3px; color:#123a55; font-size:31px; }
.wrongbook-card { overflow:hidden; border:1px solid #dfe9ee; border-radius:23px; background:#fff; box-shadow:0 12px 34px rgba(40,75,95,.06); }
.wrongbook-head,.wrongbook-row { display:grid; grid-template-columns:minmax(220px,1.7fr) 1fr .55fr .75fr; align-items:center; gap:16px; padding:16px 22px; }
.wrongbook-head { color:#83939d; background:#f6fafc; font-size:10px; font-weight:850; }
.wrongbook-row + .wrongbook-row { border-top:1px solid #edf2f5; }
.wrongbook-word strong { display:block; color:#173c53; font-size:17px; }
.wrongbook-word small { display:block; margin-top:4px; color:#718895; line-height:1.45; }
.wrongbook-source { color:#6f8592; font-size:11px; }
.wrongbook-count { color:#b56d2a; font-size:12px; font-weight:850; }
.wrongbook-actions { display:flex; gap:7px; }
.wrongbook-actions button { padding:8px 10px; border:1px solid #cce4ed; border-radius:10px; color:#168fba; background:#f2fbfe; font-size:10px; font-weight:850; }
.wrongbook-actions button:hover { border-color:#8ed3e9; background:#e3f7fc; }
.wrongbook-row.resolved { opacity:.62; }

@media (max-width:640px) {
  .bottom-nav { grid-template-columns:repeat(6,1fr); }
  .learning-mode-heading { margin-bottom:8px; }
  .learning-chain { grid-template-columns:repeat(2,1fr); gap:8px; margin-bottom:16px; }
  .learning-chain > button { min-height:58px; padding:8px 10px; border-radius:14px; }
  .learning-chain > button b { width:32px; height:32px; }
  .chain-controls { justify-items:center; text-align:center; }
  .chain-controls > p { max-width:100%; }
  .learn-spelling-form > div { width:100%; }
  .wrongbook-topline { display:grid; gap:15px; }
  .wrongbook-train-btn { width:100%; }
  .wrongbook-summary { grid-template-columns:repeat(3,1fr); gap:7px; }
  .wrongbook-summary article { padding:15px 10px; border-radius:16px; }
  .wrongbook-summary strong { font-size:25px; }
  .wrongbook-head { display:none; }
  .wrongbook-row { grid-template-columns:1fr auto; gap:10px; padding:17px 15px; }
  .wrongbook-source,.wrongbook-count { grid-column:1; }
  .wrongbook-actions { grid-column:2; grid-row:1 / span 3; flex-direction:column; }
}
