﻿:root {
  --bg: #f6f7fb;
  --panel: #ffffff;
  --ink: #172033;
  --muted: #6c7484;
  --line: #dfe4ee;
  --primary: #2878ff;
  --accent: #2878ff;
  --primary-dark: #145bd1;
  --green: #1b8f5a;
  --orange: #d46b08;
  --red: #c83532;
  --yellow: #fff6da;
  --shadow: 0 18px 48px rgba(20, 38, 70, 0.11);
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  min-height: 100vh;
  background: var(--bg);
  color: var(--ink);
  font-family: "Segoe UI Variable Display", "SF Pro Display", "PingFang SC", "Microsoft YaHei UI", "Noto Sans SC", "Helvetica Neue", Arial, sans-serif;
  letter-spacing: 0;
}

body.is-practice-page {
  height: 100dvh;
  overflow: hidden;
}

body.is-practice-page #app {
  height: 100dvh;
  overflow: hidden;
}

button {
  border: 0;
  font: inherit;
  cursor: pointer;
  transition: background 160ms ease, border-color 160ms ease, color 160ms ease, box-shadow 160ms ease, opacity 160ms ease, transform 160ms ease, filter 160ms ease;
}

.app-shell {
  display: grid;
  grid-template-columns: 248px 1fr;
  min-height: 100vh;
}

.sidebar {
  background: #101827;
  color: #f8fafc;
  padding: 24px 18px;
}

.brand {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 28px;
}

.brand-mark {
  display: grid;
  width: 38px;
  height: 38px;
  place-items: center;
  border-radius: 8px;
  background: #2878ff;
  font-weight: 800;
}

.brand-title {
  margin: 0;
  font-size: 18px;
  line-height: 1.2;
}

.brand-subtitle {
  margin: 4px 0 0;
  color: #aab3c4;
  font-size: 12px;
}

.brand .brand-mark {
  object-fit: contain;
}

.nav {
  display: grid;
  gap: 8px;
}

.account-panel {
  display: grid;
  gap: 10px;
  margin: 0 0 22px;
  padding: 14px;
  border: 1px solid rgba(205, 177, 132, 0.2);
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.035);
}

.account-panel span {
  color: #9a968c;
  font-size: 12px;
  font-weight: 700;
}

.account-panel strong {
  overflow: hidden;
  color: #fffaf0;
  font-size: 13px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.account-panel button {
  min-height: 38px;
  border: 1px solid rgba(205, 177, 132, 0.25);
  border-radius: 10px;
  background: rgba(205, 177, 132, 0.1);
  color: #f0dfbd;
  font-weight: 800;
}

.account-panel button:hover {
  border-color: rgba(205, 177, 132, 0.5);
  background: rgba(205, 177, 132, 0.18);
  color: #fff7e6;
}

.account-panel.is-session-expired {
  border-color: rgba(255, 155, 120, 0.35);
  background: rgba(255, 155, 120, 0.08);
}

.account-panel.is-session-expired span {
  color: #ffd6c5;
}

.nav-button {
  display: flex;
  align-items: center;
  gap: 10px;
  width: 100%;
  min-height: 44px;
  padding: 10px 12px;
  border-radius: 8px;
  background: transparent;
  color: #cdd5e1;
  text-align: left;
}

.nav-button.active,
.nav-button:hover {
  background: #1e2a3d;
  color: #ffffff;
}

.nav-icon {
  width: 24px;
  text-align: center;
}

.nav-icon svg {
  display: block;
  width: 22px;
  height: 22px;
  fill: none;
  stroke: currentColor;
  stroke-linecap: round;
  stroke-linejoin: round;
  stroke-width: 1.9;
}

.icp-placeholder {
  margin: 18px 4px 0;
  color: #8b93a3;
  font-size: 12px;
  line-height: 1.6;
}

.icp-placeholder a {
  color: #9ca3af;
  text-decoration: none;
}

.icp-placeholder a:hover {
  color: #f0dfbd;
  text-decoration: underline;
}

.site-icp-footer {
  position: fixed;
  left: 50%;
  bottom: 8px;
  z-index: 20;
  transform: translateX(-50%);
  padding: 4px 10px;
  border: 1px solid rgba(205, 177, 132, 0.12);
  border-radius: 999px;
  background: rgba(10, 10, 12, 0.66);
  backdrop-filter: blur(10px);
  font-size: 12px;
  line-height: 1.4;
}

.site-icp-footer a {
  color: rgba(240, 223, 189, 0.76);
  text-decoration: none;
}

.site-icp-footer a:hover {
  color: #fff7e6;
  text-decoration: underline;
}

.main {
  position: relative;
  padding: 28px;
  overflow: auto;
}

.topbar {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 18px;
  margin-bottom: 22px;
}

.topbar-actions {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 12px;
  flex-shrink: 0;
}

.profile-chip {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  min-height: 42px;
  padding: 7px 12px 7px 8px;
  border: 1px solid rgba(205, 177, 132, 0.22);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.045);
  color: #f7eddc;
  font-weight: 850;
}

.profile-chip img {
  width: 34px;
  height: 28px;
  object-fit: contain;
}

.profile-avatar-button {
  position: fixed;
  top: max(8px, env(safe-area-inset-top));
  right: max(8px, env(safe-area-inset-right));
  z-index: 120;
  display: inline-grid;
  place-items: center;
  width: 42px;
  height: 42px;
  padding: 0;
  border: 1px solid rgba(205, 177, 132, 0.32);
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.045);
  box-shadow: 0 10px 26px rgba(0, 0, 0, 0.24);
  overflow: hidden;
}

.profile-avatar-button img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.auth-entry-actions {
  display: inline-flex;
  align-items: center;
  gap: 16px;
}

.auth-entry-actions button {
  min-height: 42px;
  padding: 0 22px;
  border-radius: 10px;
  font-size: 18px;
  font-weight: 760;
}

.auth-entry-login {
  background: transparent;
  color: #f7eddc;
}

.auth-entry-register {
  background: linear-gradient(135deg, #b667f6, #a742ed);
  color: #ffffff;
  box-shadow: 0 10px 20px rgba(166, 72, 237, 0.26);
}

.profile-overlay {
  position: fixed;
  inset: 0;
  z-index: 9000;
  display: grid;
  justify-items: end;
  padding: 12px;
  background: rgba(0, 0, 0, 0.48);
  backdrop-filter: blur(8px);
}

.profile-panel {
  width: min(350px, calc(100vw - 20px));
  max-height: calc(100vh - 20px);
  overflow: auto;
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 16px;
  background:
    linear-gradient(180deg, rgba(66, 60, 77, 0.92), rgba(31, 31, 35, 0.98) 120px),
    rgba(31, 31, 35, 0.98);
  box-shadow: 0 30px 90px rgba(0, 0, 0, 0.52);
}

.profile-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 50px;
  padding: 12px 16px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.09);
}

.profile-head h2 {
  margin: 0;
  color: #ffffff;
  font-size: 19px;
  font-weight: 650;
}

.profile-close {
  display: grid;
  width: 30px;
  height: 30px;
  place-items: center;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.58);
  color: #33343a;
  font-size: 22px;
  line-height: 1;
}

.profile-hero {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 16px;
}

.profile-avatar {
  width: 56px;
  height: 56px;
  border-radius: 14px;
  object-fit: contain;
  background: #050505;
}

.profile-hero-text {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px;
}

.profile-hero-text strong {
  color: #ffffff;
  font-size: 15px;
}

.profile-hero-text button {
  min-height: 28px;
  padding: 0 11px;
  border: 1px solid rgba(205, 177, 132, 0.45);
  border-radius: 999px;
  background: rgba(205, 177, 132, 0.12);
  color: #ead4a4;
  font-size: 13px;
  font-weight: 800;
}

.profile-list {
  display: grid;
  gap: 2px;
  padding: 0 16px 14px;
}

.profile-list div,
.profile-row-button {
  display: grid;
  grid-template-columns: minmax(86px, 0.86fr) minmax(0, 1fr);
  align-items: center;
  min-height: 40px;
  color: #ffffff;
}

.profile-list span,
.profile-row-button {
  font-size: 13px;
  font-weight: 760;
}

.profile-list span {
  display: inline-flex;
  align-items: center;
  gap: 8px;
}

.profile-list svg {
  width: 17px;
  height: 17px;
  fill: none;
  stroke: currentColor;
  stroke-linecap: round;
  stroke-linejoin: round;
  stroke-width: 1.8;
}

.profile-list strong {
  overflow: hidden;
  color: rgba(255, 255, 255, 0.62);
  font-size: 13px;
  font-weight: 760;
  text-align: right;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.profile-badge {
  justify-self: end;
  padding: 6px 11px;
  border-radius: 999px;
  background: #5fc83f;
  color: #ffffff !important;
}

.profile-row-button {
  grid-template-columns: minmax(0, 1fr) auto;
  width: 100%;
  padding: 0;
  background: transparent;
  text-align: left;
}

.profile-row-button span {
  color: rgba(255, 255, 255, 0.66);
  font-size: 24px;
  line-height: 1;
}

.profile-logout {
  width: calc(100% - 32px);
  min-height: 40px;
  margin: 0 16px 16px;
  border-radius: 999px;
  background: #ff3d8d;
  color: #ffffff;
  font-size: 14px;
  font-weight: 850;
}

.profile-edit-panel,
.delete-account-panel {
  align-self: start;
  width: min(560px, 100%);
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 22px;
  background: #f7f7f8;
  color: #141414;
  box-shadow: 0 30px 90px rgba(0, 0, 0, 0.48);
}

.profile-edit-panel {
  width: min(480px, calc(100vw - 28px));
  background:
    linear-gradient(180deg, rgba(48, 43, 57, 0.98), rgba(22, 22, 25, 0.99) 150px),
    #18181c;
  color: #f7eddc;
}

.profile-edit-panel .profile-head {
  border-bottom-color: rgba(255, 255, 255, 0.09);
}

.profile-edit-panel .profile-head h2 {
  color: #ffffff;
}

.profile-edit-panel .profile-close {
  background: rgba(255, 255, 255, 0.14);
  color: #ffffff;
}

.profile-edit-body {
  display: grid;
  grid-template-columns: 104px 1fr;
  gap: 18px;
  align-items: center;
  padding: 22px 20px 18px;
}

.profile-edit-avatar {
  width: 92px;
  height: 92px;
  border-radius: 24px;
  object-fit: contain;
  background: #050505;
}

.profile-file-input {
  display: none;
}

.profile-image-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  width: 100%;
  min-height: 48px;
  border: 1px solid rgba(205, 177, 132, 0.24);
  border-radius: 10px;
  background: rgba(255, 255, 255, 0.07);
  color: #f7eddc;
  font-size: 15px;
  font-weight: 780;
}

.profile-image-button svg {
  width: 18px;
  height: 18px;
}

.profile-edit-body p {
  margin: 10px 0 0;
  color: rgba(247, 237, 220, 0.58);
  font-size: 14px;
}

.profile-edit-field {
  display: grid;
  gap: 10px;
  padding: 0 20px 20px;
}

.profile-edit-field span {
  display: flex;
  justify-content: space-between;
  color: rgba(247, 237, 220, 0.74);
  font-size: 15px;
  font-weight: 750;
}

.profile-edit-field em {
  color: rgba(247, 237, 220, 0.55);
  font-style: normal;
  font-weight: 600;
}

.profile-edit-field input,
.delete-code-row input {
  min-height: 48px;
  border: 1px solid rgba(205, 177, 132, 0.22);
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.07);
  color: #ffffff;
  font-size: 15px;
  font-weight: 700;
}

.profile-edit-actions,
.delete-account-actions {
  display: flex;
  justify-content: flex-end;
  gap: 12px;
  padding: 0 20px 20px;
}

.profile-edit-actions button,
.delete-account-actions button {
  min-width: 112px;
  min-height: 42px;
  border-radius: 999px;
  font-size: 15px;
  font-weight: 820;
}

.profile-edit-actions button:first-child,
.delete-account-actions button:first-child {
  background: rgba(0, 0, 0, 0.06);
  color: #333;
}

.profile-edit-actions button:last-child,
.delete-account-actions button:last-child {
  background: #4164ff;
  color: #ffffff;
}

.profile-edit-actions button:first-child {
  background: rgba(255, 255, 255, 0.08);
  color: #f7eddc;
}

.profile-edit-actions button:last-child {
  background: linear-gradient(135deg, #d9bf82, #a77835);
  color: #17120b;
}

.delete-account-panel {
  width: min(620px, 100%);
  background: #1e1f25;
  color: #ffffff;
}

.delete-account-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 24px;
}

.delete-account-head h2 {
  margin: 0;
  color: #ff2d37;
  font-size: 24px;
}

.delete-account-warning {
  margin: 0;
  padding: 0 24px 20px;
  color: rgba(255, 255, 255, 0.65);
  font-size: 17px;
  font-weight: 700;
  line-height: 1.7;
}

.delete-account-warning strong {
  color: #ffffff;
}

.delete-code-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 12px;
  padding: 0 24px 18px;
}

.delete-code-row input {
  background: #2b2c34;
  color: #ffffff;
}

.delete-code-row button {
  min-width: 130px;
  border-radius: 12px;
  background: #2b2c34;
  color: #4c6fff;
  font-size: 16px;
  font-weight: 820;
}

.delete-confirm-row {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 0 24px 18px;
  color: #ffffff;
  font-size: 18px;
  font-weight: 820;
}

.delete-confirm-row input {
  width: 20px;
  height: 20px;
}

.delete-account-notice {
  margin: 0 24px 18px;
  color: #bfe8c8;
  font-size: 15px;
  font-weight: 750;
}

.page-title {
  margin: 0;
  font-size: 28px;
  line-height: 1.2;
}

.page-kicker {
  margin: 8px 0 0;
  color: var(--muted);
}

.status-strip {
  display: grid;
  grid-template-columns: repeat(3, minmax(120px, 1fr));
  gap: 12px;
  margin-bottom: 22px;
}

.metric {
  min-height: 78px;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--panel);
}

.metric strong {
  display: block;
  margin-top: 6px;
  font-size: 24px;
}

.grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
  gap: 14px;
}

.two-column {
  display: grid;
  grid-template-columns: minmax(0, 1.1fr) minmax(320px, 0.9fr);
  gap: 18px;
}

.card,
.panel {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--panel);
  box-shadow: 0 1px 0 rgba(20, 38, 70, 0.03);
}

.card {
  display: grid;
  gap: 10px;
  padding: 14px;
}

.course-card {
  overflow: hidden;
  padding: 0;
}

.course-card > :not(.course-cover) {
  margin-left: 14px;
  margin-right: 14px;
}

.course-card > :last-child {
  margin-bottom: 14px;
}

.course-cover {
  position: relative;
  display: grid;
  min-height: 132px;
  align-content: center;
  gap: 8px;
  overflow: hidden;
  padding: 16px;
  color: #ffffff;
  background: linear-gradient(135deg, #25c6ff, #4ade80);
  transition: filter 180ms ease, transform 180ms ease;
}

.course-card:hover .course-cover,
.vocab-deck-card:hover .deck-cover,
.word-picture:hover {
  filter: brightness(1.04) saturate(1.02);
}

.course-cover strong {
  position: relative;
  z-index: 1;
  max-width: 78%;
  font-size: 22px;
  line-height: 1.08;
  text-shadow: 0 3px 12px rgba(0, 0, 0, 0.24);
}

.course-cover small {
  position: relative;
  z-index: 1;
  width: fit-content;
  padding: 5px 10px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.18);
  font-weight: 800;
  font-size: 12px;
}

.cover-daily { background: linear-gradient(135deg, #7dd3fc 0%, #38bdf8 45%, #22c55e 100%); }
.cover-family { background: linear-gradient(135deg, #fb7185 0%, #f59e0b 48%, #84cc16 100%); }
.cover-travel { background: linear-gradient(135deg, #60a5fa 0%, #06b6d4 50%, #14b8a6 100%); }
.cover-work { background: linear-gradient(135deg, #64748b 0%, #2563eb 52%, #0f766e 100%); }
.cover-shopping { background: linear-gradient(135deg, #f97316 0%, #ec4899 52%, #8b5cf6 100%); }
.cover-phone { background: linear-gradient(135deg, #22c55e 0%, #06b6d4 52%, #2563eb 100%); }
.cover-emergency { background: linear-gradient(135deg, #ef4444 0%, #f97316 52%, #facc15 100%); }

.cover-bubbles span,
.cover-people i {
  position: absolute;
  border-radius: 999px;
}

.cover-bubbles span:nth-child(1) {
  right: 22px;
  top: 24px;
  width: 70px;
  height: 70px;
  background: rgba(255, 255, 255, 0.2);
}

.cover-bubbles span:nth-child(2) {
  right: 105px;
  bottom: 18px;
  width: 28px;
  height: 28px;
  background: rgba(255, 255, 255, 0.24);
}

.cover-bubbles span:nth-child(3) {
  left: -26px;
  top: -18px;
  width: 90px;
  height: 90px;
  background: rgba(255, 255, 255, 0.14);
}

.cover-people i {
  right: 26px;
  bottom: 14px;
  width: 34px;
  height: 52px;
  border-radius: 24px 24px 12px 12px;
  background: rgba(255, 255, 255, 0.82);
  box-shadow: 0 12px 24px rgba(0, 0, 0, 0.14);
}

.cover-people i:nth-child(2) {
  right: 56px;
  bottom: 10px;
  width: 30px;
  height: 44px;
  background: rgba(255, 255, 255, 0.62);
}

.panel {
  padding: 20px;
}

.section-kicker {
  display: inline-flex;
  width: fit-content;
  margin-bottom: 8px;
  color: var(--accent);
  font-size: 12px;
  font-weight: 900;
  letter-spacing: 0.08em;
}

.placement-prompt,
.weekly-report,
.placement-hero,
.placement-result,
.placement-actions {
  margin-bottom: 18px;
}

.placement-prompt {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
}

.placement-prompt h3,
.weekly-report h3,
.placement-hero h2,
.placement-result h2 {
  margin: 0;
}

.placement-prompt p,
.weekly-report p,
.placement-hero p,
.placement-result p {
  margin: 8px 0 0;
  color: var(--muted);
  line-height: 1.55;
}

.placement-prompt.compact {
  border-color: rgba(37, 99, 235, 0.28);
}

.placement-hero {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 132px;
  gap: 18px;
  align-items: center;
}

.placement-meter {
  display: grid;
  min-height: 112px;
  place-items: center;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--panel-raised, rgba(255, 255, 255, 0.72));
}

.placement-meter strong {
  font-size: 30px;
  line-height: 1;
}

.placement-meter span {
  color: var(--muted);
  font-size: 13px;
}

.placement-question-list {
  display: grid;
  gap: 12px;
}

.placement-question {
  display: grid;
  gap: 14px;
}

.placement-question-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  color: var(--muted);
  font-size: 13px;
}

.placement-question h3 {
  margin: 0;
  font-size: 18px;
  line-height: 1.45;
}

.placement-options {
  display: grid;
  gap: 10px;
}

.placement-option {
  display: flex;
  align-items: center;
  gap: 10px;
  min-height: 46px;
  padding: 10px 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--panel-solid, rgba(255, 255, 255, 0.76));
  cursor: pointer;
}

.placement-option.selected {
  border-color: var(--accent);
  box-shadow: 0 0 0 2px rgba(37, 99, 235, 0.12);
}

.placement-option input {
  width: 18px;
  height: 18px;
  margin: 0;
  accent-color: var(--accent);
}

.placement-option span {
  line-height: 1.45;
}

.placement-actions {
  display: flex;
  align-items: center;
  gap: 12px;
}

.placement-actions span {
  color: var(--muted);
}

.placement-result {
  display: grid;
  gap: 18px;
  border-color: rgba(34, 197, 94, 0.32);
}

.placement-breakdown,
.weekly-report-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 12px;
}

.placement-breakdown {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.placement-breakdown article,
.weekly-report-grid article,
.recommendation-grid article {
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--panel-raised, rgba(255, 255, 255, 0.68));
}

.placement-breakdown span,
.weekly-report-grid span,
.recommendation-grid span {
  display: block;
  color: var(--muted);
  font-size: 13px;
}

.placement-breakdown strong,
.weekly-report-grid strong {
  display: block;
  margin: 6px 0;
  font-size: 22px;
}

.recommendation-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
  margin-top: 12px;
}

.recommendation-grid article {
  display: grid;
  gap: 8px;
}

.recommendation-grid strong {
  font-size: 16px;
}

.recommendation-grid p {
  margin: 0;
  font-size: 13px;
}

.placement-apply {
  margin-top: 14px;
}

.weekly-report-head {
  display: flex;
  justify-content: space-between;
  gap: 16px;
}

.weekly-report-head > strong {
  display: grid;
  width: 76px;
  height: 76px;
  flex: 0 0 76px;
  place-items: center;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--panel-raised, rgba(255, 255, 255, 0.68));
  font-size: 24px;
}

.weekly-next {
  padding: 12px;
  border-radius: 8px;
  background: rgba(37, 99, 235, 0.08);
}

.card h3,
.panel h2,
.panel h3 {
  margin: 0;
}

.course-card h3 {
  font-size: 18px;
  line-height: 1.25;
}

.course-card .muted {
  margin: 0;
  font-size: 13px;
  line-height: 1.45;
}

.course-card .tag {
  min-height: 22px;
  padding: 3px 7px;
  font-size: 11px;
}

.course-card .button-row {
  gap: 8px;
}

.course-card .primary,
.course-card .secondary,
.course-card .ghost {
  min-height: 32px;
  padding: 6px 9px;
  font-size: 12px;
}

.muted {
  color: var(--muted);
}

.tag-row {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.tag {
  display: inline-flex;
  align-items: center;
  min-height: 28px;
  padding: 4px 9px;
  border-radius: 999px;
  background: #eef3ff;
  color: #225fc7;
  font-size: 13px;
}

.progress {
  display: block;
  width: 100%;
  overflow: hidden;
  height: 8px;
  border: 0;
  border-radius: 99px;
  background: #e9edf5;
  appearance: none;
}

.progress span {
  display: block;
  height: 100%;
  border-radius: inherit;
  background: var(--green);
}

.progress::-webkit-progress-bar {
  border-radius: inherit;
  background: #e9edf5;
}

.progress::-webkit-progress-value {
  border-radius: inherit;
  background: var(--green);
}

.progress::-moz-progress-bar {
  border-radius: inherit;
  background: var(--green);
}

.button-row {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  align-items: center;
}

.primary,
.secondary,
.ghost,
.danger {
  min-height: 38px;
  padding: 8px 13px;
  border-radius: 8px;
  font-weight: 700;
}

.primary {
  background: var(--primary);
  color: #fff;
}

.primary:hover {
  background: var(--primary-dark);
}

button:disabled {
  cursor: default;
  opacity: 0.72;
}

.secondary {
  background: #edf4ff;
  color: #195ec4;
}

.ghost {
  border: 1px solid var(--line);
  background: #fff;
  color: var(--ink);
}

.danger {
  background: #fff0f0;
  color: var(--red);
}

.course-layout {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
  gap: 14px;
}

.lesson-list {
  display: grid;
  gap: 10px;
}

.lesson-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  min-height: 56px;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fbfcff;
}

.puzzle-board {
  display: grid;
  gap: 18px;
  padding: 22px;
  border: 1px solid #cad6ea;
  border-radius: 8px;
  background: linear-gradient(180deg, #ffffff 0%, #f7faff 100%);
  box-shadow: var(--shadow);
}

.prompt-box {
  display: grid;
  gap: 8px;
  padding: 16px;
  border-radius: 8px;
  background: #101827;
  color: #ffffff;
}

.prompt-box .muted {
  color: #b8c1d1;
}

.answer-area,
.word-bank {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  min-height: 66px;
  padding: 12px;
  border: 1px dashed #b7c5dd;
  border-radius: 8px;
  background: #ffffff;
}

.answer-area.empty::before {
  content: "鐐瑰嚮涓嬫柟璇嶅潡锛屾妸鑻辨枃鍙ュ瓙鎷煎埌杩欓噷";
  color: var(--muted);
  align-self: center;
}

.word-tile {
  min-height: 40px;
  padding: 9px 13px;
  border-radius: 8px;
  background: #f1f5fb;
  color: #172033;
  box-shadow: inset 0 -2px 0 rgba(20, 38, 70, 0.08);
}

.word-tile:hover {
  background: #e7efff;
}

.word-tile.selected {
  background: #dceaff;
}

.feedback {
  min-height: 28px;
  font-weight: 700;
}

.feedback.ok {
  color: var(--green);
}

.feedback.bad {
  color: var(--red);
}

.tabs {
  display: inline-flex;
  gap: 6px;
  padding: 5px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #ffffff;
}

.tab {
  min-height: 34px;
  padding: 7px 12px;
  border-radius: 6px;
  background: transparent;
  color: var(--muted);
}

.tab.active {
  background: #101827;
  color: #ffffff;
}

.review-list {
  display: grid;
  gap: 12px;
}

.review-item {
  display: grid;
  gap: 8px;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #ffffff;
}

.sentence-card {
  position: relative;
  display: grid;
  gap: 18px;
  padding: 22px 26px;
  overflow: hidden;
  border: 1px solid #e5ecf6;
  border-radius: 8px;
  background: #ffffff;
  box-shadow: 0 10px 24px rgba(31, 45, 68, 0.08);
  cursor: pointer;
}

.sentence-card::before {
  position: absolute;
  inset: 0 auto 0 0;
  width: 6px;
  background: #ff9f0a;
  content: "";
}

.vocab-card {
  position: relative;
  padding: 22px 26px;
  overflow: hidden;
  border: 1px solid #e5ecf6;
  border-radius: 8px;
  background: #ffffff;
  box-shadow: 0 10px 24px rgba(31, 45, 68, 0.08);
}

.vocab-card::before {
  position: absolute;
  inset: 0 auto 0 0;
  width: 6px;
  background: #ff9f0a;
  content: "";
}

.sentence-main {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 18px;
  align-items: start;
}

.vocab-main {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 18px;
  align-items: start;
}

.sentence-title-row {
  display: flex;
  flex-wrap: wrap;
  gap: 18px;
  align-items: center;
}

.sentence-title-row h3 {
  margin: 0;
  color: #0f1d33;
  font-size: 28px;
  line-height: 1.2;
}

.sentence-badge {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  padding: 8px 18px;
  border: 1px solid #b8d4ff;
  border-radius: 8px;
  background: #eef6ff;
  color: #2878ff;
  font-size: 20px;
  font-weight: 800;
}

.sentence-meta {
  margin: 14px 0 0;
  color: #a6b4c8;
  font-size: 17px;
  font-weight: 700;
}

.sentence-star {
  display: grid;
  width: 60px;
  height: 60px;
  place-items: center;
  border: 2px solid #ffc42e;
  border-radius: 50%;
  background: #fff9df;
  color: #ff9f0a;
  font-size: 28px;
}

.sentence-star:hover {
  background: #fff7d6;
  box-shadow: 0 0 0 4px rgba(255, 196, 46, 0.08);
  transform: translateY(-1px);
}

.review-actions {
  display: flex;
  gap: 12px;
  align-items: center;
}

.sentence-audio {
  display: grid;
  width: 52px;
  height: 52px;
  place-items: center;
  border: 1px solid #b8d4ff;
  border-radius: 50%;
  background: #eef6ff;
  color: #2878ff;
  font-size: 18px;
  font-weight: 900;
}

.sentence-audio svg,
.icon-action svg {
  width: 24px;
  height: 24px;
  fill: currentColor;
  stroke: currentColor;
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.sentence-audio:hover,
.icon-action:hover {
  border-color: rgba(16, 217, 238, 0.42);
  background: rgba(16, 217, 238, 0.07);
  color: #18cce0;
  box-shadow: 0 0 0 4px rgba(16, 217, 238, 0.06);
  filter: brightness(1.04);
  transform: translateY(-1px);
}

.vocab-example {
  margin: 18px 0 0;
  color: #304157;
  font-size: 20px;
  font-weight: 600;
}

.sentence-translation {
  display: flex;
  align-items: center;
  gap: 18px;
  margin: 12px -26px -22px;
  padding: 48px 76px;
  border-top: 1px solid #edf2f8;
  background: #f8fbff;
}

.sentence-translation span {
  display: grid;
  width: 46px;
  height: 46px;
  place-items: center;
  border-radius: 8px;
  background: #e6edf6;
  color: #65758b;
  font-weight: 800;
}

.sentence-translation strong {
  color: #18263a;
  font-size: 26px;
  font-weight: 500;
}

.vocab-deck-list {
  display: grid;
  gap: 14px;
  margin-bottom: 18px;
}

.vocab-deck-card {
  display: grid;
  grid-template-columns: 128px minmax(0, 1fr) 58px;
  gap: 30px;
  align-items: center;
  min-height: 150px;
  padding: 28px 40px;
  border-radius: 8px;
  background: #ffffff;
  color: #172033;
  text-align: left;
  box-shadow: 0 12px 32px rgba(31, 45, 68, 0.08);
}

.vocab-deck-card:hover,
.vocab-deck-card.active {
  box-shadow: 0 14px 34px rgba(31, 45, 68, 0.11);
  transform: translateY(-1px);
}

.deck-cover {
  display: grid;
  width: 128px;
  height: 96px;
  place-items: center;
  border-radius: 8px;
  color: #ffffff;
  text-align: center;
}

.tone-red .deck-cover { background: linear-gradient(135deg, #fb7185, #dc2626); }
.tone-orange .deck-cover { background: linear-gradient(135deg, #fb923c, #ea580c); }
.tone-green .deck-cover { background: linear-gradient(135deg, #4ade80, #14b8a6); }

.deck-cover strong {
  font-size: 24px;
  line-height: 1.05;
}

.deck-cover small {
  font-size: 13px;
  font-weight: 800;
}

.deck-info {
  display: grid;
  gap: 10px;
}

.deck-info strong {
  font-size: 28px;
}

.deck-info em {
  color: #9aa7bb;
  font-size: 22px;
  font-style: normal;
}

.deck-plus {
  display: grid;
  width: 58px;
  height: 58px;
  place-items: center;
  border-radius: 50%;
  background: #f3f7fd;
  color: #b9c5d6;
  font-size: 34px;
  box-shadow: 0 10px 24px rgba(31, 45, 68, 0.1);
}

.vocab-deck-card:hover .deck-plus,
.vocab-deck-card.active .deck-plus {
  background: #f0fbff;
  color: #49bfd2;
}

.word-card {
  display: grid;
  gap: 18px;
  min-height: 420px;
  align-content: center;
  text-align: center;
}

.word-visual {
  display: flex;
  justify-content: center;
}

.word-picture {
  display: grid;
  width: min(360px, 100%);
  min-height: 160px;
  place-items: center;
  padding: 22px;
  border-radius: 8px;
  background:
    radial-gradient(circle at 25% 20%, rgba(255, 255, 255, 0.28), transparent 28%),
    linear-gradient(135deg, #f43f5e, #fb923c);
  color: #ffffff;
  box-shadow: 0 18px 44px rgba(244, 63, 94, 0.22);
}

.word-picture span {
  font-size: 72px;
}

.word-controls {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 12px;
}

.icon-action {
  display: inline-grid;
  min-width: 58px;
  min-height: 58px;
  place-items: center;
  padding: 0 16px;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: #ffffff;
  color: #172033;
  font-weight: 800;
}

.icon-action.text-action {
  min-width: 96px;
}

.favorite-action.is-saved {
  border-color: rgba(205, 177, 124, 0.55);
  background: linear-gradient(135deg, rgba(205, 177, 124, 0.28), rgba(205, 177, 124, 0.12));
  color: #f2d89f;
  box-shadow: 0 0 0 4px rgba(205, 177, 124, 0.08), inset 0 1px 0 rgba(255, 255, 255, 0.08);
}

.favorite-action.is-saved:hover {
  border-color: rgba(205, 177, 124, 0.78);
  background: linear-gradient(135deg, rgba(205, 177, 124, 0.36), rgba(205, 177, 124, 0.18));
  color: #fff0c8;
}

.control-button.favorite-action.is-saved {
  border-color: rgba(205, 177, 124, 0.75);
  background: rgba(205, 177, 124, 0.2);
  color: #f2d89f;
}

.word-main {
  font-size: 54px;
  line-height: 1.1;
  font-weight: 800;
}

.phonetic {
  color: var(--muted);
  font-size: 18px;
}

.meaning {
  font-size: 24px;
  font-weight: 700;
}

.example {
  max-width: 620px;
  margin: 0 auto;
  padding: 14px;
  border-radius: 8px;
  background: var(--yellow);
  color: #3d3211;
}

.word-answer-input {
  width: 150px;
  height: 40px;
  border: 0;
  border-bottom: 3px solid #6d5f2b;
  background: transparent;
  color: #172033;
  font-size: 22px;
  font-weight: 800;
  outline: 0;
  text-align: center;
}

.word-answer-input:focus {
  border-bottom-color: var(--primary);
}

.empty-state {
  display: grid;
  place-items: center;
  min-height: 180px;
  border: 1px dashed var(--line);
  border-radius: 8px;
  color: var(--muted);
  text-align: center;
}

.course-start-modal {
  position: fixed;
  inset: 0;
  z-index: 8;
  display: grid;
  place-items: center;
  padding: 24px;
  background: rgba(3, 6, 12, 0.74);
  backdrop-filter: blur(10px);
}

.course-start-panel {
  position: relative;
  width: min(540px, 100%);
  padding: 44px;
  border: 2px solid #16d8ec;
  border-radius: 8px;
  background: #10151f;
  color: #f8fbff;
  text-align: center;
  box-shadow: 0 28px 90px rgba(0, 0, 0, 0.46);
}

.course-start-icon {
  display: grid;
  width: 92px;
  height: 92px;
  place-items: center;
  margin: 0 auto 22px;
  border: 1px dashed rgba(22, 216, 236, 0.55);
  border-radius: 50%;
  background: rgba(22, 216, 236, 0.08);
  font-size: 42px;
}

.course-start-panel h2 {
  margin: 0;
  font-size: 40px;
  font-weight: 700;
}

.course-start-panel p {
  color: #aab7c7;
  font-size: 24px;
}

.course-start-panel p strong {
  color: #16d8ec;
  font-size: 34px;
}

.course-start-actions {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 20px;
  margin-top: 28px;
}

.course-start-actions button {
  min-height: 58px;
  font-size: 20px;
}

.course-start-close {
  position: absolute;
  top: 14px;
  right: 14px;
  width: 34px;
  height: 34px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.08);
  color: #cbd5e1;
  font-size: 22px;
}

.practice-shell {
  height: 100dvh;
  min-height: 100dvh;
  background: #030508;
  color: #f7fbff;
  font-family: "SF Pro Display", "PingFang SC", "Microsoft YaHei UI", "Noto Sans SC", "Helvetica Neue", Arial, sans-serif;
  overflow: hidden;
}

.practice-topbar {
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: center;
  gap: 18px;
  height: 62px;
  padding: 0 28px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.09);
  background: rgba(5, 8, 14, 0.96);
}

.practice-back,
.mode-button {
  min-height: 34px;
  padding: 6px 10px;
  border-radius: 8px;
  border: 1px solid rgba(0, 207, 232, 0.55);
  background: rgba(0, 207, 232, 0.08);
  color: #25d9eb;
  font-size: 13px;
  font-weight: 700;
}

.practice-back:hover,
.mode-button:hover {
  border-color: rgba(32, 242, 255, 0.62);
  background: rgba(0, 207, 232, 0.1);
  color: #bff9ff;
  box-shadow: 0 0 0 4px rgba(0, 207, 232, 0.06);
}

.practice-path {
  min-width: 0;
  overflow: hidden;
  color: #8d98a8;
  font-weight: 400;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.practice-path span {
  margin: 0 10px;
  color: #2aa7b8;
}

.practice-path strong {
  color: #16d8ec;
  font-weight: 500;
}

.practice-status {
  display: flex;
  align-items: center;
  gap: 10px;
  color: #8d98a8;
  font-size: 15px;
}

.voice-select-label {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  min-height: 34px;
  padding: 0 8px;
  border: 1px solid rgba(0, 207, 232, 0.45);
  border-radius: 8px;
  background: rgba(0, 207, 232, 0.08);
  color: #25d9eb;
  font-weight: 700;
  white-space: nowrap;
}

.voice-select-label span {
  font-size: 13px;
}

.voice-select {
  width: auto;
  min-width: 54px;
  border: 0;
  background: transparent;
  color: #e9fbff;
  font: inherit;
  font-size: 13px;
  outline: 0;
}

.practice-mode-select {
  min-width: 74px;
}

.voice-select option {
  background: #101827;
  color: #ffffff;
}

.practice-timer {
  color: #f7fbff;
  font-size: 21px;
  font-weight: 700;
  font-variant-numeric: tabular-nums;
}

.dictation-stage {
  position: relative;
  display: grid;
  grid-template-rows: auto 108px minmax(0, 1fr);
  height: calc(100dvh - 62px);
  min-height: 0;
  box-sizing: border-box;
  align-content: start;
  justify-items: center;
  gap: 0;
  overflow: hidden;
  padding: 8px 18px 74px;
}

.dictation-stage.has-answer-stage {
  padding-bottom: 74px;
}

.grid-bg {
  position: absolute;
  inset: 0;
  background:
    linear-gradient(rgba(255, 255, 255, 0.035) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.035) 1px, transparent 1px);
  background-size: 72px 72px;
  mask-image: radial-gradient(circle at center, black 0%, transparent 74%);
}

.dictation-card {
  position: relative;
  z-index: 1;
  display: grid;
  gap: clamp(34px, 5.8vh, 58px);
  width: min(980px, 100%);
  justify-items: center;
  align-self: start;
  margin-top: clamp(54px, 8vh, 96px);
  text-align: center;
  min-height: 0;
}

.dictation-card.has-answer {
  gap: clamp(34px, 5.8vh, 58px);
}

.dictation-stage.has-answer-stage .dictation-card {
  gap: clamp(34px, 5.8vh, 58px);
  margin-top: clamp(54px, 8vh, 96px);
  transform: none;
}

.practice-progress-panel,
.practice-answer-slot {
  position: relative;
  z-index: 1;
  width: 100%;
}

.practice-progress-panel {
  display: grid;
  width: min(100%, calc(100vw - 36px));
  gap: 0;
}

.practice-progress-meta {
  display: none;
  align-items: center;
  justify-content: space-between;
  color: rgba(255, 244, 223, 0.76);
  font-size: 14px;
  font-weight: 800;
}

.practice-progress-meta strong {
  color: #fff4df;
  font-variant-numeric: tabular-nums;
}

.practice-progress-track {
  display: block;
  width: 100%;
  height: 5px;
  overflow: hidden;
  border: 1px solid rgba(205, 177, 132, 0.22);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.055);
  appearance: none;
}

.practice-progress-track::-webkit-progress-bar {
  background: rgba(255, 255, 255, 0.055);
}

.practice-progress-track::-webkit-progress-value {
  border-radius: inherit;
  background: linear-gradient(90deg, #8f6b37, #e4c991);
  box-shadow: 0 0 16px rgba(205, 177, 132, 0.2);
}

.practice-progress-track::-moz-progress-bar {
  border-radius: inherit;
  background: linear-gradient(90deg, #8f6b37, #e4c991);
  box-shadow: 0 0 16px rgba(205, 177, 132, 0.2);
}

.practice-answer-slot {
  height: 108px;
  min-height: 108px;
  display: grid;
  align-items: start;
  justify-items: center;
  padding-top: 10px;
  pointer-events: none;
}

.practice-answer-slot .answer-analysis,
.listening-answer-stage .answer-analysis {
  box-sizing: border-box;
  width: fit-content;
  max-width: min(1800px, calc(100vw - 240px));
  min-height: 84px;
  padding: 10px 18px 12px;
  border: 1px solid rgba(205, 177, 132, 0.22);
  border-radius: 10px;
  background:
    linear-gradient(145deg, rgba(255, 255, 255, 0.07), rgba(255, 255, 255, 0.022)),
    rgba(16, 16, 20, 0.92);
  box-shadow:
    inset 0 1px 0 rgba(255, 244, 223, 0.08),
    0 16px 38px rgba(0, 0, 0, 0.24);
  overflow: hidden;
  pointer-events: auto;
}

.practice-answer-slot .answer-token-line,
.listening-answer-stage .answer-token-line {
  max-width: 100%;
  justify-content: center;
  gap: clamp(4px, 0.34vw, 7px);
}

.practice-answer-placeholder {
  min-height: 1px;
}

.zh-prompt {
  margin: 0;
  color: rgba(255, 255, 255, 0.86);
  font-size: 42px;
  font-weight: 300;
  line-height: 1.34;
  letter-spacing: 0;
  width: min(980px, calc(100vw - 96px));
  overflow-wrap: anywhere;
  word-break: break-all;
  white-space: normal;
  justify-self: center;
}

.dictation-stage.has-answer-stage .zh-prompt {
  width: min(980px, calc(100vw - 96px));
  font-size: 42px;
  line-height: 1.34;
}

.blank-row {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 22px 18px;
  max-width: 1040px;
}

.sentence-dictation-panel {
  display: grid;
  gap: 18px;
  width: min(860px, calc(100vw - 64px));
}

.sentence-dictation-panel p {
  margin: 0;
  color: rgba(255, 244, 223, 0.78);
  font-size: 20px;
  font-weight: 760;
}

.sentence-dictation-input {
  width: 100%;
  min-height: 118px;
  resize: vertical;
  border: 1px solid rgba(205, 177, 132, 0.28);
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.045);
  color: #fff4df;
  caret-color: #cdb184;
  font-family: inherit;
  font-size: 28px;
  font-weight: 760;
  line-height: 1.45;
  outline: 0;
  padding: 18px 20px;
}

.sentence-dictation-input:focus {
  border-color: rgba(205, 177, 132, 0.62);
  box-shadow: 0 0 0 4px rgba(205, 177, 132, 0.08);
}

.listening-panel {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 8px;
}

.listening-answer-stage {
  display: grid;
  justify-items: center;
  width: 100%;
}

.listening-answer-stage .answer-analysis {
  min-height: 0;
  padding: 18px 22px 20px;
}

.listening-answer-stage .answer-grammar-row {
  gap: 16px;
}

.listening-answer-stage .answer-word {
  grid-template-rows: 48px 22px;
}

.listening-answer-stage .answer-word strong {
  height: 48px;
  padding-inline: 6px;
  border-bottom-width: 3px;
  font-size: clamp(22px, 2.1vw, 34px);
}

.listening-answer-stage .answer-word em {
  font-size: 14px;
  line-height: 22px;
}

.listening-answer-stage .review-translation {
  margin-top: 10px;
  font-size: clamp(24px, 2vw, 34px);
}

.listening-action {
  min-width: 54px;
  min-height: 34px;
  padding: 0 10px;
  border: 1px solid rgba(205, 177, 132, 0.34);
  border-radius: 7px;
  background: rgba(205, 177, 132, 0.1);
  color: #fff4df;
  font-size: 13px;
  font-weight: 850;
}

.listening-action:hover,
.listening-action:focus-visible {
  border-color: rgba(205, 177, 132, 0.62);
  background: rgba(205, 177, 132, 0.16);
  box-shadow: 0 0 0 4px rgba(205, 177, 132, 0.08);
  outline: 0;
}

.listening-answer-text {
  margin: 0;
  color: #fff4df;
  font-size: clamp(24px, 3vw, 38px);
  font-weight: 800;
  line-height: 1.36;
  text-align: center;
  overflow-wrap: anywhere;
}

.dictation-token {
  display: inline-flex;
  align-items: flex-end;
  gap: 6px;
}

.dictation-comma {
  display: inline-flex;
  align-items: flex-end;
  height: 50px;
  color: rgba(255, 255, 255, 0.9);
  font-size: 34px;
  font-weight: 800;
  line-height: 1;
  padding-bottom: 4px;
}

.dictation-stage.has-answer-stage .blank-row {
  gap: 22px 18px;
  max-width: 1040px;
}

.dictation-blank {
  min-width: 58px;
  max-width: min(320px, 82vw);
  height: 50px;
  border: 0;
  border-top: 0 !important;
  border-right: 0 !important;
  border-left: 0 !important;
  border-bottom: 4px solid rgba(255, 255, 255, 0.26);
  border-radius: 0;
  background: transparent;
  color: rgba(255, 255, 255, 0.94);
  caret-color: transparent;
  font-family: inherit;
  font-size: 30px;
  font-weight: 800;
  outline: 0;
  text-align: center;
  appearance: none;
  -webkit-appearance: none;
  box-shadow: none !important;
  padding: 0 3px 4px;
}

.dictation-stage.has-answer-stage .dictation-blank {
  height: 50px;
  border-bottom-width: 4px;
  font-size: 30px;
}

.dictation-stage.has-answer-stage .dictation-comma {
  height: 50px;
  font-size: 34px;
  padding-bottom: 4px;
}

.dictation-blank:focus {
  border-top: 0 !important;
  border-right: 0 !important;
  border-left: 0 !important;
  border-bottom-color: #18d6e8;
  background: transparent;
  box-shadow: none !important;
  outline: 0;
}

.dictation-blank.wrong {
  border-bottom-color: #ff1f6d;
  color: #ff1f6d;
}

.practice-feedback {
  min-height: 0;
  margin: 0;
  color: #9aa6b6;
  font-size: 24px;
  font-weight: 800;
}

.practice-feedback.ok {
  color: #33d28b;
}

.practice-feedback.bad {
  color: #ff7373;
}

.audio-status {
  min-height: 24px;
  margin: -42px 0 0;
  color: #8792a2;
}

.answer-analysis {
  display: grid;
  gap: 8px;
  width: min(1480px, 98vw);
  margin: 0;
  padding: 0;
  border: 0;
  background: transparent;
  box-shadow: none;
  overflow: visible;
}

.answer-font-21 {
  --answer-font-size: 21px;
}

.answer-font-23 {
  --answer-font-size: 23px;
}

.answer-font-24 {
  --answer-font-size: 24px;
}

.answer-font-32 {
  --answer-font-size: 32px;
}

.dictation-card.has-answer > .answer-analysis:not(.review-answer-analysis) {
  position: static;
  z-index: auto;
  transform: none;
  justify-self: center;
  width: min(980px, calc(100vw - 96px));
  margin: -6px auto 0;
  pointer-events: auto;
}

.dictation-stage.has-answer-stage .answer-analysis {
  gap: 6px;
}

.dictation-stage.has-answer-stage .answer-token-line {
  gap: clamp(4px, 0.34vw, 7px);
}

.dictation-stage.has-answer-stage .answer-word {
  grid-template-rows: 30px 17px;
}

.dictation-stage.has-answer-stage .answer-word strong {
  height: 30px;
  font-size: min(var(--answer-font-size, 21px), 18px);
  border-bottom-width: 2px;
}

.dictation-stage.has-answer-stage .answer-word em {
  font-size: 11px;
  line-height: 17px;
}

.dictation-stage.has-answer-stage .listening-answer-stage .answer-analysis {
  gap: 12px;
}

.dictation-stage.has-answer-stage .listening-answer-stage .answer-token-line {
  gap: clamp(7px, 0.68vw, 13px);
}

.dictation-stage.has-answer-stage .listening-answer-stage .answer-word {
  grid-template-rows: 48px 22px;
}

.dictation-stage.has-answer-stage .listening-answer-stage .answer-word strong {
  height: 48px;
  padding-inline: 6px;
  border-bottom-width: 3px;
  font-size: clamp(22px, 2.1vw, 34px);
}

.dictation-stage.has-answer-stage .listening-answer-stage .answer-word em {
  font-size: 14px;
  line-height: 22px;
}

.answer-grammar-row {
  display: grid;
  gap: 18px;
  width: 100%;
}

.answer-token-line {
  display: flex;
  flex-wrap: nowrap;
  align-items: start;
  justify-content: center;
  gap: clamp(5px, 0.5vw, 10px);
  width: 100%;
  overflow-x: auto;
  overflow-y: hidden;
  padding-bottom: 2px;
  scrollbar-width: none;
}

.answer-token-line::-webkit-scrollbar {
  display: none;
}

.answer-word {
  --answer-blue: #586cff;
  display: grid;
  grid-template-rows: 40px 20px;
  gap: 2px;
  min-width: max-content;
  justify-items: center;
  border-radius: 7px;
  cursor: pointer;
}

.answer-word-popover {
  position: fixed;
  z-index: 40;
  width: min(640px, calc(100vw - 28px));
  overflow: hidden;
  border: 1px solid rgba(205, 177, 132, 0.2);
  border-radius: 16px;
  background:
    linear-gradient(145deg, rgba(255, 255, 255, 0.065), rgba(255, 255, 255, 0.018)),
    rgba(18, 18, 22, 0.98);
  color: #fff4df;
  box-shadow:
    inset 0 1px 0 rgba(255, 244, 223, 0.08),
    0 24px 70px rgba(0, 0, 0, 0.42);
}

.answer-word-popover-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 14px;
  padding: 24px 28px 12px;
}

.answer-word-title {
  display: flex;
  align-items: baseline;
  gap: 12px;
  min-width: 0;
}

.answer-word-popover-head strong {
  color: #fff4df;
  font-size: 34px;
  font-weight: 820;
  line-height: 1;
}

.answer-word-syllable {
  color: rgba(255, 244, 223, 0.62);
  font-size: 22px;
  font-weight: 480;
  line-height: 1;
}

.answer-word-syllable b {
  color: #a855f7;
  font-weight: 760;
}

.answer-word-popover-head button {
  display: grid;
  width: 28px;
  height: 28px;
  place-items: center;
  border: 0;
  border-radius: 999px;
  background: transparent;
  color: rgba(255, 244, 223, 0.58);
  font-size: 20px;
  cursor: pointer;
}

.answer-word-pron-list {
  display: grid;
  gap: 10px;
  padding: 0 28px 22px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.answer-word-pron-row {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 0;
  color: rgba(255, 244, 223, 0.68);
  font-size: 18px;
}

.answer-word-pron-row button {
  display: grid;
  width: 26px;
  height: 26px;
  place-items: center;
  border: 1px solid rgba(205, 177, 132, 0.2);
  border-radius: 999px;
  background: rgba(205, 177, 132, 0.08);
  color: #e4c991;
  font-size: 13px;
  cursor: pointer;
}

.answer-word-accent {
  color: rgba(255, 244, 223, 0.48);
  font-size: 18px;
}

.answer-word-phonetic {
  letter-spacing: 0.08em;
}

.answer-word-detail {
  display: grid;
  gap: 18px;
  max-height: min(300px, 34vh);
  overflow-y: auto;
  padding: 24px 28px 20px;
}

.answer-word-meaning {
  display: grid;
  gap: 10px;
  padding: 0;
}

.answer-word-meaning span,
.answer-word-forms span {
  color: rgba(255, 244, 223, 0.48);
  font-size: 18px;
  font-weight: 560;
}

.answer-word-meaning p,
.answer-word-forms p {
  margin: 0;
  color: rgba(255, 244, 223, 0.88);
  font-size: 22px;
  line-height: 1.45;
}

.answer-word-forms {
  display: grid;
  gap: 8px;
}

.answer-word-save {
  display: grid;
  width: calc(100% - 56px);
  min-height: 56px;
  margin: 0 28px 24px;
  place-items: center;
  border: 0;
  border-radius: 12px;
  background: linear-gradient(135deg, #9f4bf2, #a855f7);
  color: #fff;
  font-size: 22px;
  font-weight: 760;
  cursor: pointer;
  box-shadow: 0 14px 28px rgba(168, 85, 247, 0.22);
}

.answer-word-save.is-saved {
  background: rgba(168, 85, 247, 0.18);
  color: #d8b4fe;
  box-shadow: none;
}

.answer-word:hover,
.answer-word:focus-visible {
  background: rgba(205, 177, 132, 0.08);
  outline: 0;
}

.answer-word strong {
  grid-row: 1;
  display: flex;
  align-items: end;
  justify-content: center;
  width: auto;
  height: 40px;
  min-width: 0;
  padding-inline: 5px;
  padding-bottom: 5px;
  border-bottom: 3px solid var(--answer-blue);
  color: #ffffff;
  font-size: var(--answer-font-size, 24px);
  font-weight: 900;
  white-space: nowrap;
  text-shadow: 0 0 16px rgba(88, 108, 255, 0.22);
}

.answer-comma {
  display: inline-block;
  margin-left: 2px;
}

.answer-word em {
  grid-row: 2;
  color: rgba(255, 255, 255, 0.58);
  font-size: 14px;
  font-style: normal;
  font-weight: 700;
  line-height: 20px;
  white-space: nowrap;
}

.dictation-card.is-reviewing {
  visibility: hidden;
}

.correct-review {
  position: fixed;
  inset: 62px 0 128px;
  z-index: 5;
  display: grid;
  place-items: center;
  padding: 28px 28px 36px;
  pointer-events: auto;
  background: radial-gradient(circle at center, rgba(0, 0, 0, 0.54), rgba(0, 0, 0, 0.14) 46%, transparent 72%);
  animation: review-hold 260ms ease-out both;
}

.correct-review .answer-analysis {
  position: static;
  transform: none;
  width: min(1480px, 98vw);
}

.correct-review .answer-grammar-row {
  gap: 14px;
}

.correct-review .answer-word {
  grid-template-rows: 48px 26px;
  padding: 0 2px;
}

.correct-review .answer-word em {
  grid-row: 2;
  font-size: 16px;
  color: rgba(255, 255, 255, 0.58);
}

.correct-review .answer-word strong {
  grid-row: 1;
  height: 48px;
  font-size: calc(var(--answer-font-size, 24px) + 2px);
  border-bottom-width: 4px;
}

.review-translation {
  margin: 4px 0 0;
  width: auto;
  max-width: min(980px, calc(100vw - 120px));
  justify-self: center;
  color: rgba(255, 255, 255, 0.86);
  font-size: 24px;
  font-weight: 700;
  line-height: 1.35;
  text-align: center;
  overflow-wrap: anywhere;
  word-break: break-all;
  white-space: normal;
}

@media (max-width: 640px) {
  .practice-shell {
    overflow-x: hidden;
  }

  .practice-topbar {
    grid-template-columns: 1fr;
    height: auto;
    padding: 14px;
    gap: 12px;
  }

  .practice-back {
    width: 100%;
  }

  .practice-path {
    width: 100%;
    white-space: normal;
  }

  .practice-status {
    flex-wrap: wrap;
    width: 100%;
    gap: 8px;
  }

  .practice-status > .voice-select-label,
  .practice-status > .mode-button {
    flex: 1 1 auto;
    justify-content: center;
  }

  .voice-select-label span {
    font-size: 12px;
  }

  .voice-select {
    font-size: 12px;
  }

  .dictation-stage {
    padding-right: 14px;
    padding-left: 14px;
    overflow-x: hidden;
  }

  .sentence-dictation-panel {
    width: min(100%, calc(100vw - 28px));
  }

  .sentence-dictation-input {
    font-size: 20px;
  }

  .practice-controls {
    max-width: calc(100vw - 24px);
    gap: 7px;
    padding: 7px 8px;
  }

  .control-button,
  .check-button {
    min-width: 42px;
    height: 36px;
    padding: 0 8px;
  }

  .submit-control {
    min-width: 54px;
    height: 36px;
  }

  .dictation-card.has-answer > .answer-analysis:not(.review-answer-analysis),
  .answer-analysis,
  .correct-review .answer-analysis {
    width: min(100%, calc(100vw - 28px));
    max-width: calc(100vw - 28px);
  }

  .answer-token-line,
  .dictation-stage.has-answer-stage .answer-token-line,
  .correct-review .answer-token-line {
    flex-wrap: nowrap;
    gap: 8px 12px;
    max-width: 100%;
  }

  .answer-word strong,
  .answer-word em {
    max-width: calc(100vw - 44px);
  }

  .correct-review {
    padding: 18px 14px 28px;
    overflow: hidden auto;
  }

  .correct-review .answer-word {
    padding: 0 2px;
  }

  .correct-review .answer-word strong {
    font-size: min(28px, calc(var(--answer-font-size, 24px) + 2px));
  }

  .review-translation {
    width: min(100%, calc(100vw - 32px));
    max-width: calc(100vw - 32px);
    font-size: 20px;
  }
}

.chapter-complete {
  position: fixed;
  inset: 0;
  z-index: 10000;
  display: grid;
  place-items: center;
  padding: 24px;
  background:
    radial-gradient(circle at 50% 35%, rgba(143, 132, 255, 0.18), transparent 34%),
    rgba(2, 6, 12, 0.82);
  backdrop-filter: blur(14px);
  overflow: hidden;
  isolation: isolate;
}

.chapter-complete::before,
.chapter-complete::after {
  content: none !important;
  display: none !important;
  animation: none !important;
}

.chapter-complete > :not(.chapter-complete-panel):not(.chapter-complete-fx) {
  display: none !important;
  animation: none !important;
}

body.is-chapter-complete .course-start-icon,
body.is-chapter-complete .correct-review,
body.is-chapter-complete .answer-analysis,
body.is-chapter-complete [class*="firework"],
body.is-chapter-complete [class*="confetti"],
body.is-chapter-complete [class*="spark"],
body.is-chapter-complete [class*="pyro"],
body.is-chapter-complete [class*="particle"],
body.is-chapter-complete [class*="celebrat"],
body.is-chapter-complete [class*="comet"],
body.is-chapter-complete [class*="burst"],
body.is-chapter-complete [class*="streak"],
body.is-chapter-complete [class*="strip"],
body.is-chapter-complete [class*="ribbon"],
body.is-chapter-complete [class*="launcher"],
body.is-chapter-complete [class*="trail"],
body.is-chapter-complete [class*="meteor"],
body.is-chapter-complete [class*="flare"],
body.is-chapter-complete [class*="ray"],
body.is-chapter-complete [class*="shard"],
body.is-chapter-complete [class*="sprinkle"],
body.is-chapter-complete [class*="shoot"],
body.is-chapter-complete [class*="beam"],
.chapter-complete .course-start-icon {
  display: none !important;
  visibility: hidden !important;
  opacity: 0 !important;
  width: 0 !important;
  height: 0 !important;
  background: none !important;
  box-shadow: none !important;
  filter: none !important;
  animation: none !important;
  transform: none !important;
}

.chapter-complete-panel {
  position: relative;
  z-index: 8;
  width: min(520px, 100%);
  padding: 36px;
  border: 1px solid rgba(255, 255, 255, 0.14);
  border-radius: 18px;
  background: rgba(16, 18, 28, 0.78);
  text-align: center;
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.2),
    0 24px 80px rgba(0, 0, 0, 0.46);
  backdrop-filter: blur(18px);
}

.chapter-complete-kicker {
  margin: 0 0 12px;
  color: #19d6ea;
  font-size: 15px;
  font-weight: 900;
}

.chapter-complete-panel h2 {
  margin: 0;
  color: #ffffff;
  font-size: 34px;
  font-weight: 800;
}

.chapter-complete-panel p {
  color: #aab7c7;
  font-weight: 700;
}

.chapter-actions {
  display: flex;
  justify-content: center;
  gap: 12px;
  margin-top: 22px;
}

@keyframes review-hold {
  0% {
    opacity: 0;
    transform: scale(0.96);
  }
  100% {
    opacity: 1;
    transform: scale(1);
  }
}

.practice-controls {
  position: fixed;
  left: 50%;
  bottom: 18px;
  z-index: 2;
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 7px 9px;
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 10px;
  background: rgba(10, 14, 24, 0.92);
  box-shadow: 0 18px 48px rgba(0, 0, 0, 0.45);
  transform: translateX(-50%);
}

.control-button,
.check-button {
  min-width: 48px;
  height: 36px;
  padding: 0 9px;
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 7px;
  background: #0d1220;
  color: #d7e1ee;
  font-size: 13px;
  font-weight: 700;
}

.arrow-control {
  min-width: 38px;
  font-size: 24px;
  line-height: 1;
}

.answer-toggle {
  min-width: 50px;
  font-size: 13px;
}

.submit-control {
  min-width: 56px;
  height: 36px;
  border-radius: 7px;
  font-size: 13px;
  letter-spacing: 0;
}

.word-answer-line {
  min-height: 28px;
  margin: -8px 0 0;
  color: var(--primary);
  font-size: 24px;
  font-weight: 800;
}

.control-button:hover,
.check-button:hover {
  border-color: rgba(0, 207, 232, 0.34);
  color: #ffffff;
  background: rgba(0, 207, 232, 0.08);
}

.primary-control {
  background: rgba(0, 207, 232, 0.14);
  color: #25d9eb;
}

.check-button {
  min-width: 82px;
  background: #f7fbff;
  color: #111827;
}

@media (max-width: 980px) {
  .app-shell {
    grid-template-columns: 1fr;
  }

  .sidebar {
    position: sticky;
    top: 0;
    z-index: 2;
    padding: 14px;
  }

  .brand {
    margin-bottom: 12px;
  }

  .nav {
    grid-template-columns: repeat(auto-fit, minmax(48px, 1fr));
  }

  .nav-button {
    justify-content: center;
    padding: 10px 6px;
  }

  .nav-label {
    display: none;
  }

  .main {
    padding: 18px;
  }

  .topbar,
  .two-column {
    grid-template-columns: 1fr;
    display: grid;
  }

  .grid,
  .status-strip,
  .legal-grid,
  .admin-grid,
  .admin-metrics,
  .admin-service-list,
  .admin-task-list,
  .admin-report-list,
  .admin-payment-summary,
  .admin-referral-list,
  .admin-audit-stats,
  .admin-audit-samples {
    grid-template-columns: 1fr;
  }

  .admin-status-heading {
    display: grid;
  }

  .practice-topbar {
    grid-template-columns: 1fr;
    height: auto;
    padding: 14px;
  }

  .practice-status {
    justify-content: space-between;
  }

  .zh-prompt {
    font-size: 34px;
  }

  .practice-controls {
    width: calc(100% - 24px);
    gap: 7px;
    padding: 7px 8px;
  }

  .control-button,
  .check-button {
    min-width: 0;
    flex: 1;
    height: 36px;
    padding: 0 7px;
  }
}

@media (max-width: 560px) {
  .page-title {
    font-size: 23px;
  }

  .word-main {
    font-size: 40px;
  }

  .button-row,
  .tabs {
    width: 100%;
  }

  .primary,
  .secondary,
  .ghost,
  .danger,
  .tab {
    flex: 1;
  }
}

/* Taste-skill redesign layer */
:root {
  --bg: #07090d;
  --panel: rgba(18, 22, 30, 0.82);
  --panel-solid: #111821;
  --panel-raised: rgba(22, 28, 38, 0.9);
  --ink: #eef4f8;
  --muted: #91a0ae;
  --line: rgba(184, 205, 224, 0.15);
  --primary: #45e3f2;
  --primary-dark: #18b9cb;
  --green: #3ce0a0;
  --orange: #f2b95b;
  --red: #ff5c7c;
  --yellow: rgba(242, 185, 91, 0.13);
  --shadow: 0 24px 80px rgba(0, 0, 0, 0.34);
  --radius-card: 18px;
  --radius-control: 12px;
}

html {
  background: #07090d;
}

body {
  min-height: 100dvh;
  background:
    radial-gradient(circle at 18% 0%, rgba(69, 227, 242, 0.13), transparent 32%),
    radial-gradient(circle at 82% 18%, rgba(242, 185, 91, 0.08), transparent 30%),
    linear-gradient(135deg, #07090d 0%, #0a0f14 46%, #090b10 100%);
  color: var(--ink);
  font-family: "Segoe UI Variable Display", "SF Pro Display", "PingFang SC", "Microsoft YaHei UI", "Noto Sans SC", Arial, sans-serif;
}

body::before {
  position: fixed;
  inset: 0;
  z-index: -1;
  pointer-events: none;
  background:
    linear-gradient(rgba(255, 255, 255, 0.025) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.025) 1px, transparent 1px);
  background-size: 72px 72px;
  mask-image: radial-gradient(circle at center, black 0%, transparent 78%);
  content: "";
}

button:active {
  transform: translateY(1px) scale(0.99);
}

.app-shell {
  grid-template-columns: 260px minmax(0, 1fr);
  min-height: 100dvh;
}

.sidebar {
  position: sticky;
  top: 0;
  min-height: 100dvh;
  padding: 24px 18px;
  border-right: 1px solid rgba(255, 255, 255, 0.08);
  background:
    linear-gradient(180deg, rgba(17, 24, 34, 0.88), rgba(8, 11, 16, 0.96)),
    rgba(10, 14, 19, 0.94);
  box-shadow: inset -1px 0 0 rgba(255, 255, 255, 0.04);
}

.brand {
  position: relative;
  margin-bottom: 34px;
  padding: 0;
  border: 0;
  border-radius: 0;
  background: transparent;
}

.brand-mark {
  width: 44px;
  height: 44px;
  border: 0;
  border-radius: 14px;
  background: transparent;
  box-shadow: none;
}

.brand-title {
  font-size: 17px;
  font-weight: 850;
  letter-spacing: 0;
  transform: translateY(3px);
}

.brand-subtitle {
  display: none;
}

.nav {
  gap: 10px;
}

.nav-button {
  min-height: 48px;
  padding: 11px 12px;
  border: 1px solid transparent;
  border-radius: var(--radius-control);
  color: #98a6b5;
}

.nav-button:hover {
  border-color: rgba(69, 227, 242, 0.18);
  background: rgba(255, 255, 255, 0.05);
  color: #eef8fb;
}

.nav-button.active {
  border-color: rgba(69, 227, 242, 0.32);
  background:
    linear-gradient(135deg, rgba(69, 227, 242, 0.14), rgba(69, 227, 242, 0.04)),
    rgba(255, 255, 255, 0.04);
  color: #ffffff;
  box-shadow: 0 12px 32px rgba(69, 227, 242, 0.1);
}

.nav-icon {
  display: grid;
  width: 28px;
  height: 28px;
  place-items: center;
  border-radius: 10px;
  background: rgba(255, 255, 255, 0.06);
  color: #d6bc87;
}

.main {
  padding: 32px;
}

.main-inner {
  width: min(1240px, 100%);
  margin: 0 auto;
}

.topbar {
  align-items: end;
  margin-bottom: 24px;
  padding: 6px 2px 0;
}

.page-title {
  color: #f6fbff;
  font-size: clamp(30px, 4vw, 48px);
  font-weight: 860;
  line-height: 0.98;
  letter-spacing: 0;
}

.page-kicker {
  max-width: 620px;
  margin-top: 12px;
  color: var(--muted);
  font-size: 15px;
  line-height: 1.8;
}

.status-strip {
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 14px;
  margin-bottom: 24px;
}

.metric {
  min-height: 92px;
  padding: 18px;
  border-color: rgba(255, 255, 255, 0.1);
  border-radius: var(--radius-card);
  background:
    linear-gradient(145deg, rgba(255, 255, 255, 0.075), rgba(255, 255, 255, 0.025)),
    rgba(13, 18, 25, 0.78);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.08);
}

.metric strong {
  color: #ffffff;
  font-size: 34px;
  font-weight: 860;
}

.grid,
.course-layout {
  grid-template-columns: repeat(auto-fill, minmax(176px, 1fr));
  gap: 12px;
}

.market-groups {
  display: grid;
  gap: 22px;
}

.market-toolbar {
  display: grid;
  grid-template-columns: minmax(220px, 1fr) auto auto;
  align-items: end;
  gap: 12px;
  margin-bottom: 18px;
  padding: 12px;
  border: 1px solid rgba(205, 177, 124, 0.18);
  border-radius: var(--radius-card);
  background:
    linear-gradient(145deg, rgba(205, 177, 124, 0.1), rgba(255, 255, 255, 0.018)),
    rgba(14, 15, 18, 0.82);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.045);
}

.market-search {
  display: grid;
  gap: 7px;
}

.market-search span {
  color: #9d9688;
  font-size: 12px;
  font-weight: 760;
}

.market-search input {
  width: 100%;
  min-height: 40px;
  padding: 0 12px;
  border: 1px solid rgba(205, 177, 124, 0.22);
  border-radius: 11px;
  outline: none;
  background: rgba(0, 0, 0, 0.2);
  color: #fff7e8;
  font: inherit;
}

.market-search input:focus {
  border-color: rgba(205, 177, 124, 0.58);
  box-shadow: 0 0 0 3px rgba(205, 177, 124, 0.1);
}

.market-filter {
  display: inline-flex;
  gap: 4px;
  padding: 4px;
  border: 1px solid rgba(205, 177, 124, 0.16);
  border-radius: 999px;
  background: rgba(0, 0, 0, 0.18);
}

.market-filter button {
  min-height: 32px;
  padding: 0 12px;
  border-radius: 999px;
  background: transparent;
  color: #a7a095;
  font-size: 13px;
  font-weight: 780;
}

.market-filter button:hover {
  color: #fff7e8;
  background: rgba(205, 177, 124, 0.08);
}

.market-filter button.active {
  color: #15120d;
  background: linear-gradient(135deg, #dbc28e, #b69155);
}

.market-toolbar > strong {
  min-width: 54px;
  color: var(--accent);
  font-size: 18px;
  font-weight: 880;
  text-align: right;
}

.course-level-section {
  display: grid;
  gap: 10px;
}

.course-level-header {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 14px;
  padding: 12px 14px;
  border: 1px solid rgba(205, 177, 124, 0.18);
  border-radius: var(--radius-card);
  background:
    linear-gradient(135deg, rgba(205, 177, 124, 0.11), rgba(255, 255, 255, 0.025)),
    rgba(12, 13, 16, 0.72);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.05);
}

.course-level-header h3 {
  margin: 6px 0 3px;
  color: #fff7e6;
  font-size: 20px;
  line-height: 1.15;
}

.course-level-header p {
  max-width: 680px;
  margin: 0;
  color: #9d9688;
  font-size: 13px;
  line-height: 1.5;
}

.course-level-header strong {
  flex: 0 0 auto;
  color: var(--accent);
  font-size: 22px;
  font-weight: 880;
}

.level-pill {
  display: inline-flex;
  align-items: center;
  min-height: 26px;
  padding: 4px 10px;
  border: 1px solid rgba(205, 177, 124, 0.28);
  border-radius: 999px;
  color: var(--accent);
  background: rgba(205, 177, 124, 0.1);
  font-size: 12px;
  font-weight: 820;
}

.course-level-empty {
  padding: 24px;
  border: 1px dashed rgba(205, 177, 124, 0.22);
  border-radius: var(--radius-card);
  color: #9d9688;
  background: rgba(255, 255, 255, 0.03);
  text-align: center;
}

.card,
.panel,
.empty-state {
  border-color: rgba(255, 255, 255, 0.11);
  border-radius: var(--radius-card);
  background:
    linear-gradient(145deg, rgba(255, 255, 255, 0.07), rgba(255, 255, 255, 0.025)),
    rgba(13, 18, 25, 0.8);
  box-shadow: 0 20px 70px rgba(0, 0, 0, 0.24), inset 0 1px 0 rgba(255, 255, 255, 0.06);
}

.card {
  padding: 12px;
}


.course-card {
  position: relative;
  gap: 9px;
  overflow: hidden;
}

.course-card::after {
  position: absolute;
  inset: 0;
  pointer-events: none;
  border-radius: inherit;
  background: linear-gradient(135deg, rgba(255, 255, 255, 0.12), transparent 36%, rgba(69, 227, 242, 0.08));
  opacity: 0;
  transition: opacity 180ms ease;
  content: "";
}

.course-card:hover {
  border-color: rgba(69, 227, 242, 0.25);
  transform: translateY(-2px);
}

.course-card:hover::after {
  opacity: 1;
}

.course-card > :not(.course-cover) {
  margin-left: 0;
  margin-right: 0;
}

.course-card > :last-child {
  margin-bottom: 0;
}

.course-card h3 {
  color: #f7fbff;
  font-size: 15px;
  line-height: 1.25;
  font-weight: 850;
}

.course-card .muted {
  color: #8d9aa8;
  display: -webkit-box;
  overflow: hidden;
  font-size: 12px;
  line-height: 1.45;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
}

.course-cover {
  min-height: 96px;
  margin: -12px -12px 0;
  padding: 14px;
  border-radius: 0 0 var(--radius-card) var(--radius-card);
  background:
    linear-gradient(135deg, rgba(69, 227, 242, 0.92), rgba(18, 185, 203, 0.58)),
    #13232c;
}

.course-cover::before {
  position: absolute;
  inset: 0;
  background:
    linear-gradient(rgba(255, 255, 255, 0.12) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.1) 1px, transparent 1px);
  background-size: 24px 24px;
  mask-image: linear-gradient(135deg, black, transparent 80%);
  content: "";
}

.course-cover::after {
  position: absolute;
  right: -28px;
  bottom: -48px;
  width: 132px;
  height: 132px;
  border: 1px solid rgba(255, 255, 255, 0.28);
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.08);
  content: "";
}

.course-cover strong {
  max-width: 90%;
  color: #071017;
  font-size: 18px;
  font-weight: 900;
  text-shadow: none;
}

.course-cover small {
  color: #061016;
  background: rgba(255, 255, 255, 0.36);
  font-size: 10px;
}

.cover-daily,
.cover-family,
.cover-travel,
.cover-work,
.cover-shopping,
.cover-phone,
.cover-emergency {
  background:
    radial-gradient(circle at 78% 18%, rgba(255, 255, 255, 0.38), transparent 24%),
    linear-gradient(135deg, #55e5ee 0%, #2daab8 52%, #14343f 100%);
}

.cover-family {
  background:
    radial-gradient(circle at 78% 18%, rgba(255, 255, 255, 0.32), transparent 24%),
    linear-gradient(135deg, #7ee6d2 0%, #e4b45c 54%, #303225 100%);
}

.cover-work {
  background:
    radial-gradient(circle at 78% 18%, rgba(255, 255, 255, 0.28), transparent 24%),
    linear-gradient(135deg, #9ec8ff 0%, #43d6e6 52%, #15233a 100%);
}

.cover-shopping,
.cover-emergency {
  background:
    radial-gradient(circle at 78% 18%, rgba(255, 255, 255, 0.32), transparent 24%),
    linear-gradient(135deg, #ffd26d 0%, #45e3f2 54%, #18313a 100%);
}

.cover-bubbles span {
  opacity: 0.42;
}

.cover-people i {
  background: rgba(5, 15, 22, 0.62);
  box-shadow: 0 16px 36px rgba(0, 0, 0, 0.22);
}

.tag {
  min-height: 26px;
  border: 1px solid rgba(69, 227, 242, 0.16);
  background: rgba(69, 227, 242, 0.08);
  color: #aef7ff;
  font-weight: 750;
}

.progress {
  height: 7px;
  background: rgba(255, 255, 255, 0.08);
}

.progress span {
  background: linear-gradient(90deg, #45e3f2, #c8f7ff);
}

.primary,
.secondary,
.ghost,
.danger,
.tab,
.course-start-close {
  border-radius: var(--radius-control);
}

.primary {
  background: #eafcff;
  color: #071017;
  box-shadow: 0 12px 26px rgba(69, 227, 242, 0.15);
}

.primary:hover {
  background: #ffffff;
  color: #071017;
}

.secondary {
  border: 1px solid rgba(69, 227, 242, 0.16);
  background: rgba(69, 227, 242, 0.09);
  color: #bdf8ff;
}

.ghost {
  border-color: rgba(255, 255, 255, 0.12);
  background: rgba(255, 255, 255, 0.045);
  color: #d9e7ef;
}

.danger {
  border: 1px solid rgba(255, 92, 124, 0.2);
  background: rgba(255, 92, 124, 0.1);
  color: #ffc3ce;
}

.tabs {
  border-color: rgba(255, 255, 255, 0.12);
  border-radius: var(--radius-control);
  background: rgba(255, 255, 255, 0.045);
}

.tab.active {
  background: #eafcff;
  color: #071017;
}

.sentence-card,
.vocab-card {
  border-color: rgba(255, 255, 255, 0.11);
  border-radius: var(--radius-card);
  background:
    linear-gradient(145deg, rgba(255, 255, 255, 0.075), rgba(255, 255, 255, 0.025)),
    rgba(13, 18, 25, 0.84);
  box-shadow: 0 22px 70px rgba(0, 0, 0, 0.24);
}

.sentence-card::before,
.vocab-card::before {
  width: 3px;
  background: linear-gradient(180deg, #45e3f2, rgba(69, 227, 242, 0));
}

.sentence-title-row h3,
.sentence-translation strong {
  color: #f8fbff;
}

.sentence-badge {
  min-height: 34px;
  padding: 6px 12px;
  border-color: rgba(69, 227, 242, 0.22);
  border-radius: var(--radius-control);
  background: rgba(69, 227, 242, 0.1);
  color: #aef7ff;
  font-size: 14px;
}

.sentence-meta {
  color: #778797;
}

.sentence-star,
.sentence-audio,
.icon-action {
  border-color: rgba(255, 255, 255, 0.13);
  background: rgba(255, 255, 255, 0.055);
  color: #dce8f0;
}

.sentence-star {
  color: #f2c76d;
}

.sentence-audio:hover,
.icon-action:hover,
.sentence-star:hover {
  border-color: rgba(69, 227, 242, 0.32);
  background: rgba(69, 227, 242, 0.09);
  color: #c7fbff;
  box-shadow: 0 0 0 5px rgba(69, 227, 242, 0.055);
}

.vocab-example {
  color: #d4dee7;
}

.sentence-translation {
  border-top-color: rgba(255, 255, 255, 0.09);
  background: rgba(255, 255, 255, 0.035);
}

.sentence-translation span {
  background: rgba(255, 255, 255, 0.07);
  color: #b6c5d3;
}

.vocab-deck-list {
  gap: 16px;
}

.vocab-deck-card {
  grid-template-columns: 104px minmax(0, 1fr) 48px;
  min-height: 128px;
  gap: 22px;
  padding: 20px 24px;
  border: 1px solid rgba(255, 255, 255, 0.11);
  border-radius: var(--radius-card);
  background:
    linear-gradient(145deg, rgba(255, 255, 255, 0.07), rgba(255, 255, 255, 0.025)),
    rgba(13, 18, 25, 0.82);
  color: #f6fbff;
  box-shadow: 0 20px 70px rgba(0, 0, 0, 0.24);
}

.vocab-deck-card:hover,
.vocab-deck-card.active {
  border-color: rgba(69, 227, 242, 0.26);
  box-shadow: 0 24px 80px rgba(0, 0, 0, 0.3), 0 0 0 5px rgba(69, 227, 242, 0.045);
}

.deck-cover {
  width: 104px;
  height: 82px;
  border-radius: 16px;
  background:
    linear-gradient(135deg, rgba(69, 227, 242, 0.95), rgba(18, 185, 203, 0.58)),
    #12303a;
}

.tone-red .deck-cover,
.tone-orange .deck-cover,
.tone-green .deck-cover {
  background:
    radial-gradient(circle at 78% 18%, rgba(255, 255, 255, 0.32), transparent 26%),
    linear-gradient(135deg, #45e3f2, #2daab8 48%, #12303a);
}

.deck-cover strong {
  font-size: 19px;
}

.deck-info strong {
  color: #f8fbff;
  font-size: 24px;
}

.deck-info em {
  color: #7f8f9e;
  font-size: 16px;
}

.deck-plus {
  width: 48px;
  height: 48px;
  background: rgba(255, 255, 255, 0.055);
  color: #a6b6c5;
  box-shadow: none;
}

.vocab-deck-card:hover .deck-plus,
.vocab-deck-card.active .deck-plus {
  background: #eafcff;
  color: #071017;
}

.word-card {
  min-height: 520px;
}

.word-picture {
  min-height: 190px;
  border: 1px solid rgba(69, 227, 242, 0.16);
  border-radius: var(--radius-card);
  background:
    radial-gradient(circle at 30% 18%, rgba(255, 255, 255, 0.2), transparent 24%),
    linear-gradient(135deg, rgba(69, 227, 242, 0.88), rgba(242, 185, 91, 0.62)),
    #12242b;
  box-shadow: 0 24px 80px rgba(69, 227, 242, 0.12);
}

.meaning {
  color: #f6fbff;
}

.phonetic {
  color: #9aa9b7;
}

.example {
  border: 1px solid rgba(242, 185, 91, 0.18);
  border-radius: var(--radius-card);
  background: rgba(242, 185, 91, 0.09);
  color: #f5e9cf;
}

.word-answer-input {
  color: #ffffff;
  border-bottom-color: rgba(255, 255, 255, 0.34);
}

.word-answer-input:focus {
  border-bottom-color: #cdb184;
}

.course-start-modal,
.chapter-complete {
  background: rgba(4, 7, 11, 0.78);
  backdrop-filter: blur(18px);
}

.course-start-panel,
.chapter-complete-panel {
  border-color: rgba(69, 227, 242, 0.24);
  border-radius: 22px;
  background:
    linear-gradient(145deg, rgba(255, 255, 255, 0.08), rgba(255, 255, 255, 0.025)),
    #101820;
}

.course-start-icon {
  position: relative;
  border-color: rgba(69, 227, 242, 0.36);
  background: rgba(69, 227, 242, 0.08);
}

.practice-shell {
  min-height: 100dvh;
  background:
    radial-gradient(circle at 50% 42%, rgba(69, 227, 242, 0.08), transparent 34%),
    #030508;
}

.practice-topbar {
  border-bottom-color: rgba(255, 255, 255, 0.08);
  background: rgba(5, 8, 14, 0.84);
  backdrop-filter: blur(18px);
}

.practice-back,
.mode-button,
.voice-select-label,
.practice-controls,
.control-button,
.check-button {
  border-radius: var(--radius-control);
}

.practice-back,
.mode-button,
.voice-select-label {
  border-color: rgba(69, 227, 242, 0.28);
  background: rgba(69, 227, 242, 0.08);
  color: #aef7ff;
}

.practice-controls {
  border-color: rgba(255, 255, 255, 0.11);
  background:
    linear-gradient(145deg, rgba(255, 255, 255, 0.08), rgba(255, 255, 255, 0.025)),
    rgba(9, 13, 20, 0.88);
  backdrop-filter: blur(18px);
}

.control-button,
.check-button {
  background: rgba(255, 255, 255, 0.055);
}

.primary-control {
  background: rgba(69, 227, 242, 0.12);
  color: #aef7ff;
}

.check-button {
  background: #eafcff;
  color: #071017;
}

.zh-prompt {
  font-weight: 420;
}

@media (max-width: 980px) {
  .app-shell {
    grid-template-columns: 1fr;
  }

  .sidebar {
    min-height: auto;
    border-right: 0;
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
  }

  .main {
    padding: 20px;
  }

  .main-inner {
    width: 100%;
  }

  .grid,
  .course-layout,
  .status-strip {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .vocab-deck-card {
    grid-template-columns: 86px minmax(0, 1fr) 44px;
  }

  .deck-cover {
    width: 86px;
  }
}

@media (max-width: 640px) {
  .market-toolbar {
    grid-template-columns: 1fr;
    align-items: stretch;
  }

  .market-filter {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    border-radius: 14px;
  }

  .market-toolbar > strong {
    text-align: left;
  }

  .grid,
  .course-layout,
  .status-strip {
    grid-template-columns: 1fr;
  }

  .course-level-header {
    align-items: flex-start;
    flex-direction: column;
  }

  .course-level-header strong {
    font-size: 22px;
  }

  .page-title {
    font-size: 30px;
  }

  .sentence-main,
  .vocab-main,
  .vocab-deck-card {
    grid-template-columns: 1fr;
  }

  .review-actions {
    justify-content: flex-start;
  }

  .deck-plus {
    justify-self: start;
  }
}

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

}

/* Premium black-gold theme override */
:root {
  --bg: #101012;
  --panel: rgba(28, 28, 33, 0.88);
  --panel-solid: #1b1b20;
  --panel-raised: rgba(31, 31, 37, 0.94);
  --ink: #f2f0eb;
  --muted: #8c8b86;
  --line: rgba(210, 180, 122, 0.18);
  --primary: #cdb184;
  --primary-dark: #b7955d;
  --green: #d6bc87;
  --orange: #d6bc87;
  --red: #ff6b8a;
  --yellow: rgba(205, 177, 132, 0.12);
  --shadow: 0 26px 86px rgba(0, 0, 0, 0.38);
}

html {
  background: #101012;
}

body {
  background:
    radial-gradient(circle at 18% 0%, rgba(205, 177, 132, 0.12), transparent 31%),
    radial-gradient(circle at 84% 16%, rgba(146, 120, 76, 0.09), transparent 30%),
    linear-gradient(135deg, #101012 0%, #121216 48%, #0c0c0e 100%);
  color: var(--ink);
}

body::before {
  background:
    linear-gradient(rgba(205, 177, 132, 0.028) 1px, transparent 1px),
    linear-gradient(90deg, rgba(205, 177, 132, 0.024) 1px, transparent 1px);
}

.sidebar {
  border-right-color: rgba(205, 177, 132, 0.12);
  background:
    linear-gradient(180deg, rgba(25, 25, 29, 0.92), rgba(11, 11, 13, 0.98)),
    rgba(15, 15, 17, 0.96);
}

.brand {
  border-color: transparent;
  background: transparent;
}

.brand-mark {
  border: 0;
  background: transparent;
  box-shadow: none;
}

.brand-title,
.page-title,
.course-card h3,
.sentence-title-row h3,
.sentence-translation strong,
.deck-info strong,
.meaning {
  color: #fffaf0;
}

.brand-subtitle,
.page-kicker,
.muted,
.course-card .muted,
.sentence-meta,
.deck-info em,
.phonetic {
  color: #8d8a82;
}

.nav-button {
  color: #a09d95;
}

.nav-icon {
  background: rgba(205, 177, 132, 0.08);
  color: #d4b982;
}

.nav-button:hover {
  border-color: rgba(205, 177, 132, 0.24);
  background: rgba(205, 177, 132, 0.06);
  color: #f8efe0;
}

.nav-button.active {
  border-color: rgba(205, 177, 132, 0.42);
  background:
    linear-gradient(135deg, rgba(205, 177, 132, 0.18), rgba(205, 177, 132, 0.045)),
    rgba(255, 255, 255, 0.025);
  color: #fff7e8;
  box-shadow: 0 14px 34px rgba(205, 177, 132, 0.08);
}

.metric,
.card,
.panel,
.empty-state,
.sentence-card,
.vocab-card,
.vocab-deck-card {
  border-color: rgba(205, 177, 132, 0.18);
  background:
    linear-gradient(145deg, rgba(255, 255, 255, 0.055), rgba(255, 255, 255, 0.015)),
    rgba(27, 27, 32, 0.9);
  box-shadow: 0 24px 80px rgba(0, 0, 0, 0.34), inset 0 1px 0 rgba(255, 255, 255, 0.045);
}

.metric strong {
  color: #fff6e8;
}

.course-card:hover,
.vocab-deck-card:hover,
.vocab-deck-card.active {
  border-color: rgba(205, 177, 132, 0.45);
  box-shadow: 0 26px 84px rgba(0, 0, 0, 0.4), 0 0 0 5px rgba(205, 177, 132, 0.045);
}

.course-card::after {
  background: linear-gradient(135deg, rgba(255, 244, 218, 0.12), transparent 36%, rgba(205, 177, 132, 0.1));
}

.course-cover,
.cover-daily,
.cover-family,
.cover-travel,
.cover-work,
.cover-shopping,
.cover-phone,
.cover-emergency,
.tone-red .deck-cover,
.tone-orange .deck-cover,
.tone-green .deck-cover,
.deck-cover {
  background:
    radial-gradient(circle at 78% 18%, rgba(255, 255, 255, 0.32), transparent 25%),
    linear-gradient(135deg, #d8c08c 0%, #b69155 48%, #24221e 100%);
}

.course-cover::before {
  background:
    linear-gradient(rgba(255, 247, 232, 0.12) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 247, 232, 0.09) 1px, transparent 1px);
}

.course-cover strong,
.course-cover small {
  color: #101012;
}

.course-cover small {
  background: rgba(255, 247, 232, 0.4);
}

.cover-people i {
  background: rgba(20, 18, 14, 0.68);
}

.tag,
.sentence-badge {
  border-color: rgba(205, 177, 132, 0.26);
  background: rgba(205, 177, 132, 0.09);
  color: #dcc28d;
}

.progress {
  background: rgba(255, 255, 255, 0.08);
}

.progress span {
  background: linear-gradient(90deg, #cdb184, #f3ddaa);
}

.primary,
.tab.active,
.deck-plus:hover,
.vocab-deck-card:hover .deck-plus,
.vocab-deck-card.active .deck-plus,
.check-button {
  background: #cdb184;
  color: #111113;
  box-shadow: 0 14px 28px rgba(205, 177, 132, 0.14);
}

.primary:hover,
.check-button:hover {
  background: #e2c995;
  color: #111113;
}

.start-learning-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 36px;
  padding: 7px 14px;
  border: 1px solid rgba(255, 236, 190, 0.42);
  border-radius: 999px;
  background:
    radial-gradient(circle at 24% 20%, rgba(255, 255, 255, 0.36), transparent 32%),
    linear-gradient(135deg, #ead09a 0%, #cdb184 46%, #9d7b49 100%);
  color: #15130f;
  line-height: 1;
  box-shadow: 0 15px 30px rgba(205, 177, 132, 0.23), inset 0 1px 0 rgba(255, 248, 230, 0.32);
}

.start-learning-button:hover {
  border-color: rgba(255, 238, 196, 0.64);
  background:
    radial-gradient(circle at 24% 20%, rgba(255, 255, 255, 0.42), transparent 32%),
    linear-gradient(135deg, #f3dca8 0%, #d8bd8a 48%, #aa8752 100%);
  color: #11100d;
  box-shadow: 0 17px 34px rgba(205, 177, 132, 0.3), inset 0 1px 0 rgba(255, 248, 230, 0.42);
}

.start-learning-button .play-start-icon {
  display: block;
  width: 17px;
  height: 17px;
  flex: 0 0 auto;
  transform: translateY(0);
}

.start-learning-button .play-start-icon circle {
  fill: rgba(17, 16, 13, 0.08);
  stroke: currentColor;
  stroke-width: 2.2;
}

.start-learning-button .play-start-icon path {
  fill: currentColor;
}

.start-learning-button span {
  display: block;
  line-height: 1;
}

.course-card .start-learning-button {
  min-height: 36px;
  padding: 7px 14px;
  font-size: 14px;
  border-radius: 999px;
}

.secondary,
.ghost,
.tab,
.icon-action,
.sentence-audio,
.sentence-star,
.control-button {
  border-color: rgba(205, 177, 132, 0.18);
  background: rgba(255, 255, 255, 0.035);
  color: #e7dcc8;
}

.secondary:hover,
.ghost:hover,
.tab:hover,
.sentence-audio:hover,
.icon-action:hover,
.sentence-star:hover,
.control-button:hover {
  border-color: rgba(205, 177, 132, 0.42);
  background: rgba(205, 177, 132, 0.08);
  color: #fff4df;
  box-shadow: 0 0 0 5px rgba(205, 177, 132, 0.055);
}

.sentence-card::before,
.vocab-card::before {
  background: linear-gradient(180deg, #cdb184, rgba(205, 177, 132, 0));
}

.sentence-star {
  color: #d6bc87;
}

.sentence-translation {
  border-top-color: rgba(205, 177, 132, 0.12);
  background: rgba(205, 177, 132, 0.035);
}

.sentence-translation span {
  background: rgba(205, 177, 132, 0.1);
  color: #d6bc87;
}

.deck-plus {
  background: rgba(255, 255, 255, 0.045);
  color: #b9aa8d;
}

.word-picture {
  border-color: rgba(205, 177, 132, 0.28);
  background:
    radial-gradient(circle at 30% 18%, rgba(255, 255, 255, 0.18), transparent 25%),
    linear-gradient(135deg, rgba(205, 177, 132, 0.9), rgba(95, 73, 42, 0.72)),
    #1c1a17;
  box-shadow: 0 26px 86px rgba(205, 177, 132, 0.1);
}

.example {
  border-color: rgba(205, 177, 132, 0.2);
  background: rgba(205, 177, 132, 0.08);
  color: #ecdfc6;
}

.word-answer-line {
  color: #d6bc87;
}

.course-start-modal,
.chapter-complete {
  background: rgba(8, 8, 10, 0.82);
}

.course-start-panel,
.chapter-complete-panel {
  border-color: rgba(205, 177, 132, 0.35);
  background:
    linear-gradient(145deg, rgba(255, 255, 255, 0.06), rgba(255, 255, 255, 0.018)),
    #1a1a1f;
}

.course-start-icon {
  border-color: rgba(205, 177, 132, 0.46);
  background: rgba(205, 177, 132, 0.08);
}

.chapter-complete-kicker,
.course-start-panel p strong {
  color: #d6bc87;
}

.practice-shell {
  background:
    radial-gradient(circle at 50% 42%, rgba(205, 177, 132, 0.08), transparent 34%),
    #060607;
  overflow-x: hidden;
}

.practice-topbar {
  border-bottom-color: rgba(205, 177, 132, 0.12);
  background: rgba(11, 11, 13, 0.86);
}

.practice-back,
.mode-button,
.voice-select-label {
  border-color: rgba(205, 177, 132, 0.34);
  background: rgba(205, 177, 132, 0.08);
  color: #dcc28d;
}

.practice-back:hover,
.mode-button:hover {
  border-color: rgba(205, 177, 132, 0.56);
  background: rgba(205, 177, 132, 0.11);
  color: #fff4df;
  box-shadow: 0 0 0 4px rgba(205, 177, 132, 0.07);
}

.fullscreen-button {
  position: relative;
  display: inline-grid;
  min-width: 36px;
  width: 36px;
  min-height: 34px;
  padding: 0;
  place-items: center;
  font-size: 18px;
  line-height: 1;
}

.fullscreen-button::after {
  content: attr(data-tooltip);
  position: absolute;
  top: calc(100% + 10px);
  left: 50%;
  z-index: 5;
  transform: translateX(-50%) translateY(-4px);
  min-width: 84px;
  padding: 10px 14px;
  border: 1px solid rgba(205, 177, 132, 0.2);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.96);
  color: #1b1b20;
  box-shadow: 0 12px 28px rgba(0, 0, 0, 0.18);
  font-size: 13px;
  font-weight: 760;
  opacity: 0;
  pointer-events: none;
  white-space: nowrap;
  transition: opacity 140ms ease, transform 140ms ease;
}

.fullscreen-button:hover::after,
.fullscreen-button:focus-visible::after {
  opacity: 1;
  transform: translateX(-50%) translateY(0);
}

.mode-button.is-active {
  border-color: rgba(205, 177, 132, 0.7);
  background: rgba(205, 177, 132, 0.18);
  color: #fff4df;
}

.practice-path strong,
.practice-path span {
  color: #d6bc87;
}

.voice-select {
  color: #fff4df;
}

.voice-select option {
  background: #1b1b20;
  color: #fff4df;
}

.grid-bg {
  background:
    linear-gradient(rgba(205, 177, 132, 0.035) 1px, transparent 1px),
    linear-gradient(90deg, rgba(205, 177, 132, 0.03) 1px, transparent 1px);
}

.dictation-blank:focus {
  border-bottom-color: #cdb184;
}

.dictation-blank.wrong {
  border-bottom-color: #ff5c7c;
  color: #ff5c7c;
}

.answer-word {
  --answer-blue: #cdb184;
}

.dictation-blank:not(.wrong) {
  caret-color: #cdb184;
}

.dictation-blank.wrong:focus {
  caret-color: #ff5c7c;
}

.answer-word strong {
  color: #fff4df;
  text-shadow: 0 0 18px rgba(205, 177, 132, 0.18);
}

.review-translation {
  color: #fff4df;
}

.practice-controls {
  border-color: rgba(205, 177, 132, 0.16);
  background:
    linear-gradient(145deg, rgba(255, 255, 255, 0.06), rgba(255, 255, 255, 0.018)),
    rgba(23, 23, 28, 0.9);
}

.primary-control {
  background: rgba(205, 177, 132, 0.12);
  color: #e4c991;
}

.practice-status-divider {
  width: 1px;
  height: 24px;
  background: rgba(205, 177, 132, 0.22);
}

.practice-settings-button {
  font-size: 18px;
}

.practice-status .fullscreen-button,
.practice-status .practice-settings-button {
  border-color: transparent;
  background: transparent;
  box-shadow: none;
}

.practice-status .fullscreen-button:hover,
.practice-status .practice-settings-button:hover {
  border-color: transparent;
  background: transparent;
}

.immersive-exit-button {
  display: none;
}

.practice-settings-panel {
  position: fixed;
  top: 55px;
  right: 18px;
  z-index: 20;
  width: min(500px, calc(100vw - 36px));
  min-height: 0;
  padding: 12px;
  border: 1px solid rgba(205, 177, 132, 0.18);
  border-radius: 12px;
  background:
    linear-gradient(145deg, rgba(255, 255, 255, 0.055), rgba(255, 255, 255, 0.015)),
    rgba(9, 10, 13, 0.96);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.06),
    0 28px 80px rgba(0, 0, 0, 0.48);
}

.practice-settings-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
}

.practice-setting-tile {
  position: relative;
  min-height: 64px;
  padding: 9px 12px;
  border: 1px solid rgba(255, 255, 255, 0.09);
  border-radius: 5px;
  background: rgba(255, 255, 255, 0.018);
  color: #fff4df;
  text-align: left;
}

button.practice-setting-tile,
.practice-setting-select > button {
  cursor: pointer;
}

.practice-setting-tile span {
  display: block;
  color: rgba(255, 244, 223, 0.52);
  font-size: 14px;
  font-weight: 400;
  line-height: 1.2;
}

.practice-setting-tile strong {
  display: block;
  margin-top: 3px;
  color: #f8efe0;
  font-size: 18px;
  font-weight: 700;
  line-height: 1.12;
}

.practice-setting-tile i {
  position: absolute;
  right: 12px;
  top: 50%;
  color: rgba(255, 255, 255, 0.2);
  font-size: 18px;
  font-style: normal;
  transform: translateY(-50%);
}

.practice-setting-select {
  padding: 0;
}

.practice-setting-select > button,
.practice-font-setting label {
  display: block;
  width: 100%;
  min-height: 64px;
  padding: 9px 12px;
  border: 0;
  background: transparent;
  color: inherit;
  font: inherit;
  text-align: left;
}

.practice-setting-dropdown {
  position: absolute;
  left: 0;
  top: calc(100% + 8px);
  z-index: 22;
  display: grid;
  width: 100%;
  padding: 6px;
  border: 1px solid rgba(0, 207, 232, 0.42);
  border-radius: 8px;
  background: rgba(7, 10, 14, 0.98);
  box-shadow: 0 22px 52px rgba(0, 0, 0, 0.42);
}

.practice-setting-dropdown button {
  min-height: 32px;
  padding: 0 10px;
  border: 0;
  border-radius: 7px;
  background: transparent;
  color: rgba(255, 244, 223, 0.82);
  font-size: 14px;
  font-weight: 720;
  text-align: left;
}

.practice-setting-dropdown button.is-selected {
  background: rgba(0, 207, 232, 0.16);
  color: #20f2ff;
}

.practice-font-setting {
  grid-column: span 1;
}

.practice-font-setting input {
  display: block;
  width: 100%;
  margin: 10px 0 6px;
  accent-color: #20d8ee;
}

.font-scale-labels {
  display: flex;
  justify-content: space-between;
  color: rgba(190, 203, 220, 0.7);
  font-size: 13px;
  font-weight: 650;
}

.zh-prompt,
.dictation-stage.has-answer-stage .zh-prompt {
  font-size: 2.2rem;
}

.dictation-token {
  display: inline-flex;
  align-items: flex-end;
}

.dictation-blank,
.dictation-stage.has-answer-stage .dictation-blank {
  flex: 0 0 var(--blank-ch, 4ch);
  inline-size: var(--blank-ch, 4ch);
  min-inline-size: 1.28ch;
  width: var(--blank-ch, 4ch);
  min-width: 1.28ch;
  height: calc(var(--practice-font-size, 3.2rem) * 1.05);
  font-size: calc(var(--practice-font-size, 3.2rem) * 0.82);
  padding-inline: 0;
}

.listening-answer-stage .answer-analysis {
  max-width: min(1760px, calc(100vw - 160px));
  overflow: visible;
}

.listening-answer-stage .answer-token-line,
.dictation-stage.has-answer-stage .listening-answer-stage .answer-token-line {
  flex-wrap: wrap;
  justify-content: center;
  width: 100%;
  min-width: 0;
  overflow: visible;
}

body[data-practice-theme="light"].is-practice-page {
  background: #f8fafc;
  color: #111827;
}

body[data-practice-theme="light"] .practice-shell {
  background: #f8fafc;
  color: #101827;
}

body[data-practice-theme="light"] .practice-topbar {
  border-bottom-color: rgba(15, 23, 42, 0.12);
  background: rgba(255, 255, 255, 0.94);
}

body[data-practice-theme="light"] .practice-path,
body[data-practice-theme="light"] .practice-status {
  color: #667085;
}

body[data-practice-theme="light"] .practice-path strong,
body[data-practice-theme="light"] .practice-path span,
body[data-practice-theme="light"] .practice-timer {
  color: #111827;
}

body[data-practice-theme="light"] .practice-back,
body[data-practice-theme="light"] .mode-button,
body[data-practice-theme="light"] .voice-select-label {
  border-color: rgba(15, 23, 42, 0.16);
  background: #ffffff;
  color: #111827;
}

body[data-practice-theme="light"] .practice-status .fullscreen-button,
body[data-practice-theme="light"] .practice-status .practice-settings-button {
  border-color: transparent;
  background: transparent;
  color: #64748b;
}

body[data-practice-theme="light"] .practice-status .fullscreen-button:hover,
body[data-practice-theme="light"] .practice-status .practice-settings-button:hover {
  color: #111827;
}

body[data-practice-theme="light"] .voice-select {
  color: #111827;
}

body[data-practice-theme="light"] .practice-progress-track {
  border-color: rgba(15, 23, 42, 0.12);
  background: #e5e7eb;
}

body[data-practice-theme="light"] .practice-progress-track::-webkit-progress-bar {
  background: #e5e7eb;
}

body[data-practice-theme="light"] .practice-progress-track::-webkit-progress-value,
body[data-practice-theme="light"] .practice-progress-track::-moz-progress-bar {
  background: linear-gradient(90deg, #10b981, #14b8a6);
}

body[data-practice-theme="light"] .grid-bg {
  display: none;
}

body[data-practice-theme="light"] .zh-prompt,
body[data-practice-theme="light"] .review-translation {
  color: #111827;
}

body[data-practice-theme="light"] .dictation-blank {
  border-bottom-color: #d1d5db;
  color: #6b7280;
}

body[data-practice-theme="light"] .dictation-blank:focus {
  border-bottom-color: #2563eb;
  caret-color: #2563eb;
}

body[data-practice-theme="light"] .dictation-blank.wrong {
  border-bottom-color: #ff4f85;
  color: #ff4f85;
}

body[data-practice-theme="light"] .answer-word strong {
  color: #111827;
  text-shadow: none;
}

body[data-practice-theme="light"] .correct-review {
  background: #ffffff;
}

body[data-practice-theme="light"] .correct-review .answer-word strong {
  color: #111827;
  text-shadow: none;
}

body[data-practice-theme="light"] .correct-review .answer-word em {
  color: #6b7280;
}

body[data-practice-theme="light"] .practice-answer-slot .answer-analysis,
body[data-practice-theme="light"] .listening-answer-stage .answer-analysis {
  border-color: rgba(15, 23, 42, 0.1);
  background: #ffffff;
  box-shadow: 0 18px 42px rgba(15, 23, 42, 0.1);
}

body[data-practice-theme="light"] .practice-controls,
body[data-practice-theme="light"] .control-button {
  border-color: rgba(15, 23, 42, 0.12);
  background: #ffffff;
  color: #111827;
}

body[data-practice-theme="light"] .practice-settings-panel {
  border-color: rgba(148, 163, 184, 0.28);
  background: rgba(255, 255, 255, 0.98);
  box-shadow: 0 18px 46px rgba(15, 23, 42, 0.14);
}

body[data-practice-theme="light"] .answer-word-popover {
  border-color: rgba(15, 23, 42, 0.1);
  background: rgba(255, 255, 255, 0.98);
  color: #111827;
  box-shadow: 0 24px 68px rgba(15, 23, 42, 0.16);
}

body[data-practice-theme="light"] .answer-word-popover-head strong,
body[data-practice-theme="light"] .answer-word-meaning p,
body[data-practice-theme="light"] .answer-word-forms p {
  color: #111827;
}

body[data-practice-theme="light"] .answer-word-popover-head button,
body[data-practice-theme="light"] .answer-word-pron-row,
body[data-practice-theme="light"] .answer-word-syllable {
  color: #64748b;
}

body[data-practice-theme="light"] .answer-word-pron-list {
  border-bottom-color: rgba(15, 23, 42, 0.08);
}

body[data-practice-theme="light"] .answer-word-pron-row button {
  border-color: rgba(15, 23, 42, 0.1);
  background: #f8fafc;
  color: #0f766e;
}

body[data-practice-theme="light"] .answer-word-accent,
body[data-practice-theme="light"] .answer-word-meaning span,
body[data-practice-theme="light"] .answer-word-forms span {
  color: #94a3b8;
}

body[data-practice-theme="light"] .answer-word-detail {
  border-bottom-color: rgba(15, 23, 42, 0.08);
}

body[data-practice-theme="light"] .answer-word-save.is-saved {
  background: #f3e8ff;
  color: #7e22ce;
}

body[data-practice-theme="light"] .answer-word-meaning span {
  color: #94a3b8;
}

body[data-practice-theme="light"] .practice-setting-tile {
  border-color: rgba(148, 163, 184, 0.24);
  background: rgba(255, 255, 255, 0.96);
  color: #111827;
}

body[data-practice-theme="light"] .practice-setting-tile span {
  color: #8a8f98;
}

body[data-practice-theme="light"] .practice-setting-tile strong {
  color: #1f2937;
}

body[data-practice-theme="light"] .practice-setting-dropdown {
  background: #ffffff;
}

body[data-practice-theme="light"] .practice-setting-dropdown button {
  color: #111827;
}

body[data-practice-layout="immersive"] .practice-back,
body[data-practice-layout="immersive"] .practice-path,
body[data-practice-layout="immersive"] .practice-mode-label,
body[data-practice-layout="immersive"] .practice-status-divider,
body[data-practice-layout="immersive"] .practice-timer,
body[data-practice-layout="immersive"] .practice-status > strong,
body[data-practice-layout="immersive"] .practice-status > span:not(.practice-status-divider) {
  display: none;
}

body[data-practice-layout="immersive"] .practice-topbar {
  position: fixed;
  top: 12px;
  right: 14px;
  z-index: 12;
  display: flex;
  width: auto;
  height: 42px;
  padding: 0;
  border-bottom: 0;
  background: transparent;
}

body[data-practice-layout="immersive"] .practice-status {
  gap: 12px;
}

body[data-practice-layout="immersive"] .fullscreen-button,
body[data-practice-layout="immersive"] .immersive-exit-button,
body[data-practice-layout="immersive"] .practice-settings-button {
  display: inline-grid;
  width: 30px;
  min-width: 30px;
  height: 30px;
  min-height: 30px;
  padding: 0;
  border: 0;
  background: transparent;
  color: rgba(255, 255, 255, 0.58);
  box-shadow: none;
  font-size: 22px;
}

body[data-practice-theme="light"][data-practice-layout="immersive"] .fullscreen-button,
body[data-practice-theme="light"][data-practice-layout="immersive"] .immersive-exit-button,
body[data-practice-theme="light"][data-practice-layout="immersive"] .practice-settings-button {
  color: #64748b;
}

body[data-practice-theme="light"][data-practice-layout="immersive"] .fullscreen-button:hover,
body[data-practice-theme="light"][data-practice-layout="immersive"] .immersive-exit-button:hover,
body[data-practice-theme="light"][data-practice-layout="immersive"] .practice-settings-button:hover {
  color: #111827;
}

body[data-practice-layout="immersive"] .fullscreen-button:hover,
body[data-practice-layout="immersive"] .immersive-exit-button:hover,
body[data-practice-layout="immersive"] .practice-settings-button:hover {
  color: #ffffff;
  background: transparent;
  box-shadow: none;
}

body[data-practice-layout="immersive"] .dictation-stage {
  height: calc(100dvh - 62px);
  margin-top: 62px;
  padding-top: 13px;
}

body[data-practice-layout="immersive"] .practice-progress-panel {
  position: fixed;
  top: 0;
  left: 0;
  z-index: 10;
  width: 100vw;
}

body[data-practice-layout="immersive"] .practice-progress-track {
  height: 5px;
  border: 0;
  border-radius: 0;
  background: rgba(255, 255, 255, 0.06);
}

body[data-practice-layout="immersive"] .practice-settings-panel {
  top: 80px;
  right: 22px;
}

/* Compact premium review book */
.review-list {
  grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
  gap: 14px;
  align-items: start;
}

.review-list .sentence-card,
.review-list .vocab-card {
  min-height: 0;
  padding: 16px 18px 16px 20px;
  border-radius: 16px;
}

.review-list .sentence-card::before,
.review-list .vocab-card::before {
  width: 2px;
}

.review-list .sentence-main,
.review-list .vocab-main {
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 12px;
  align-items: center;
}

.review-list .sentence-title-row {
  gap: 10px;
}

.review-list .sentence-title-row h3 {
  max-width: 100%;
  color: #fff7e8;
  font-size: 18px;
  font-weight: 820;
  line-height: 1.35;
  overflow-wrap: anywhere;
}

.review-list .vocab-card .sentence-title-row h3 {
  font-size: 24px;
  line-height: 1.05;
}

.review-list .sentence-badge {
  min-height: 24px;
  padding: 4px 8px;
  border-radius: 9px;
  font-size: 12px;
  font-weight: 800;
}

.review-list .sentence-meta {
  margin-top: 8px;
  font-size: 12px;
  line-height: 1.55;
  font-weight: 650;
}

.review-list .vocab-example {
  margin-top: 10px;
  color: #c9c1b4;
  font-size: 14px;
  line-height: 1.6;
  font-weight: 560;
}

.review-list .review-actions {
  gap: 8px;
}

.review-list .sentence-audio,
.review-list .sentence-star {
  width: 38px;
  height: 38px;
  border-width: 1px;
  font-size: 18px;
}

.review-list .sentence-audio svg,
.review-list .icon-action svg {
  width: 18px;
  height: 18px;
}

.review-list .sentence-translation {
  gap: 12px;
  margin: 12px -18px -16px -20px;
  padding: 16px 18px 16px 20px;
  background: rgba(205, 177, 132, 0.045);
}

.review-list .sentence-translation span {
  width: 28px;
  height: 28px;
  border-radius: 9px;
  font-size: 13px;
}

.review-list .sentence-translation strong {
  font-size: 16px;
  line-height: 1.65;
  font-weight: 620;
}

@media (min-width: 1280px) {
  .review-list {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}

/* Square vocabulary cards and fixed review-card rhythm */
.vocab-deck-list {
  grid-template-columns: repeat(auto-fill, minmax(206px, 1fr));
  gap: 16px;
}

.vocab-deck-card {
  grid-template-columns: 1fr;
  grid-template-rows: 1fr auto auto;
  gap: 12px;
  min-height: 0;
  aspect-ratio: 1 / 1;
  padding: 0;
  overflow: hidden;
}

.vocab-deck-card .deck-cover {
  width: 100%;
  height: auto;
  min-height: 0;
  aspect-ratio: 1.36 / 1;
  border-radius: 0 0 16px 16px;
}

.vocab-deck-card .deck-info {
  padding: 0 16px;
}

.vocab-deck-card .deck-info strong {
  font-size: 18px;
  line-height: 1.25;
}

.vocab-deck-card .deck-info em {
  font-size: 13px;
}

.vocab-deck-card .deck-plus {
  position: absolute;
  right: 14px;
  bottom: 14px;
  width: 38px;
  height: 38px;
  font-size: 25px;
}

.word-picture {
  width: min(320px, 72vw);
  min-height: 0;
  aspect-ratio: 1 / 1;
  border-radius: 18px;
}

.word-picture span {
  font-size: clamp(78px, 12vw, 118px);
}

.vocab-deck-list-plain {
  grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
}

.vocab-deck-list-plain .vocab-deck-card {
  grid-template-columns: minmax(0, 1fr) auto;
  grid-template-rows: none;
  align-items: center;
  min-height: 132px;
  aspect-ratio: auto;
  padding: 20px;
}

.vocab-deck-list-plain .deck-info {
  display: grid;
  gap: 8px;
  padding: 0;
  text-align: left;
}

.vocab-deck-list-plain .deck-info small {
  color: #cdb184;
  font-size: 12px;
  font-style: normal;
  font-weight: 850;
}

.vocab-deck-list-plain .deck-plus {
  position: static;
  width: 38px;
  height: 38px;
  font-size: 28px;
}

.word-card-plain {
  min-height: 480px;
}

.word-study-head {
  display: grid;
  justify-items: center;
  gap: 10px;
}

.word-study-head > span {
  display: inline-flex;
  min-height: 28px;
  align-items: center;
  padding: 4px 12px;
  border: 1px solid rgba(205, 177, 132, 0.26);
  border-radius: 999px;
  color: #cdb184;
  background: rgba(205, 177, 132, 0.08);
  font-size: 12px;
  font-weight: 850;
}

.word-card-plain .meaning {
  max-width: min(780px, 92vw);
  font-size: clamp(42px, 6vw, 76px);
  line-height: 1.1;
}

.word-card-plain .phonetic {
  font-size: clamp(22px, 3vw, 34px);
}

.review-list .sentence-card:not(.expanded),
.review-list .vocab-card {
  height: 142px;
}

.review-list .sentence-card:not(.expanded) .sentence-main,
.review-list .vocab-card .vocab-main {
  height: 100%;
}

.review-list .sentence-card:not(.expanded) .sentence-title-row h3,
.review-list .vocab-card .vocab-example {
  display: -webkit-box;
  overflow: hidden;
  -webkit-box-orient: vertical;
}

.review-list .sentence-card:not(.expanded) .sentence-title-row h3 {
  -webkit-line-clamp: 2;
}

.review-list .vocab-card .vocab-example {
  -webkit-line-clamp: 2;
}

.review-list-sentences {
  grid-template-columns: repeat(auto-fill, minmax(430px, 1fr));
}

.review-list-sentences .sentence-card:not(.expanded) {
  height: auto;
  min-height: 184px;
}

.review-list-sentences .sentence-card:not(.expanded) .sentence-main {
  height: auto;
  align-items: start;
}

.review-list-sentences .sentence-card:not(.expanded) .sentence-title-row h3 {
  display: block;
  overflow: visible;
  -webkit-line-clamp: unset;
  -webkit-box-orient: unset;
}

.review-list-sentences .sentence-meta {
  margin-top: 14px;
  padding-bottom: 8px;
}

.review-list-sentences .review-actions {
  padding-top: 4px;
}

.review-list-words .vocab-card {
  height: 142px;
}

.membership-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 22px;
  align-items: stretch;
}

.membership-grid-four {
  grid-template-columns: repeat(4, minmax(0, 1fr));
}

.membership-grid-vip {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.membership-grid-partner {
  grid-template-columns: minmax(320px, 560px);
  justify-content: center;
}

.membership-tabs {
  display: flex;
  width: max-content;
  margin: 0 auto 28px;
  padding: 6px;
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.045);
}

.membership-tabs button {
  min-width: 160px;
  min-height: 46px;
  border-radius: 12px;
  background: transparent;
  color: #9f9b95;
  font-weight: 850;
}

.membership-tabs button.active {
  background: rgba(255, 255, 255, 0.08);
  color: #fff7e6;
}

.membership-status {
  display: grid;
  gap: 8px;
  margin-bottom: 20px;
  padding: 20px 22px;
  border: 1px solid rgba(205, 177, 132, 0.2);
  border-radius: 18px;
  background:
    linear-gradient(145deg, rgba(205, 177, 132, 0.08), rgba(255, 255, 255, 0.016)),
    rgba(27, 27, 32, 0.78);
}

.membership-status.active {
  border-color: rgba(205, 177, 132, 0.42);
  box-shadow: 0 18px 54px rgba(205, 177, 132, 0.08);
}

.membership-status span {
  color: #cdb184;
  font-size: 13px;
  font-weight: 850;
}

.membership-status strong {
  color: #fffaf0;
  font-size: 22px;
}

.membership-status p {
  margin: 0;
  color: #b7ada0;
  font-weight: 700;
  line-height: 1.65;
}

.membership-card {
  position: relative;
  display: grid;
  min-height: 640px;
  padding: 30px;
  overflow: hidden;
  border: 1px solid rgba(205, 177, 132, 0.18);
  border-radius: 22px;
  background:
    linear-gradient(145deg, rgba(255, 255, 255, 0.055), rgba(255, 255, 255, 0.014)),
    rgba(27, 27, 32, 0.9);
  box-shadow: 0 28px 86px rgba(0, 0, 0, 0.36), inset 0 1px 0 rgba(255, 255, 255, 0.045);
}

.membership-card-head {
  display: flex;
  align-items: center;
  gap: 14px;
  min-height: 78px;
  padding-right: 92px;
}

.membership-gem {
  display: grid;
  width: 34px;
  height: 34px;
  place-items: center;
  color: #8c91ff;
}

.membership-gem svg {
  width: 31px;
  height: 31px;
  fill: none;
  stroke: currentColor;
  stroke-linecap: round;
  stroke-linejoin: round;
  stroke-width: 1.9;
}

.membership-card.featured,
.membership-card.partner {
  border-color: rgba(205, 177, 132, 0.48);
}

.membership-card.partner {
  background:
    radial-gradient(circle at 85% 10%, rgba(205, 177, 132, 0.13), transparent 28%),
    linear-gradient(145deg, rgba(205, 177, 132, 0.075), rgba(255, 255, 255, 0.014)),
    rgba(27, 27, 32, 0.92);
}

.membership-ribbon {
  position: absolute;
  top: 28px;
  right: 26px;
  padding: 7px 12px;
  border: 1px solid rgba(205, 177, 132, 0.3);
  border-radius: 999px;
  background: rgba(205, 177, 132, 0.14);
  color: #f1dba9;
  font-size: 13px;
  font-weight: 800;
}

.membership-kicker {
  margin: 0 0 12px;
  color: #cdb184;
  font-size: 14px;
  font-weight: 800;
}

.membership-card h3 {
  margin: 0;
  color: #fffaf0;
  font-size: clamp(24px, 2vw, 32px);
  line-height: 1.1;
}

.membership-summary {
  margin: 14px 0 0;
  color: #9a968c;
  font-size: 16px;
  line-height: 1.7;
}

.membership-price {
  align-self: start;
  margin: 34px 0 10px;
  color: #e7c987;
  font-size: clamp(44px, 4vw, 58px);
  font-weight: 860;
  line-height: 1;
  text-shadow: 0 0 18px rgba(205, 177, 132, 0.12);
}

.membership-price span {
  margin-right: 5px;
  font-size: 0.55em;
}

.membership-price em {
  margin-left: 8px;
  color: #b7ada0;
  font-size: 0.28em;
  font-style: normal;
  font-weight: 650;
}

.vip-switch {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 6px;
  margin: 28px 0 4px;
  padding: 6px;
  border: 1px solid rgba(205, 177, 132, 0.13);
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.035);
}

.vip-switch button {
  min-height: 48px;
  border-radius: 10px;
  background: transparent;
  color: #a9a196;
  font-weight: 800;
}

.vip-switch button.active,
.vip-switch button:hover {
  background: #cdb184;
  color: #111113;
  box-shadow: 0 12px 28px rgba(205, 177, 132, 0.14);
}

.membership-note {
  min-height: 24px;
  margin: 0 0 14px;
  color: #d7c39b;
  font-weight: 700;
}

.membership-benefits {
  display: grid;
  gap: 18px;
  align-content: start;
  min-height: 190px;
  margin: 26px 0;
  padding: 28px 0 0;
  border-top: 1px solid rgba(205, 177, 132, 0.13);
  color: #f4eddf;
  list-style: none;
}

.membership-benefits.rich {
  min-height: 300px;
}

.membership-benefits.rich li {
  display: grid;
  gap: 8px;
}

.membership-benefits.rich strong {
  color: #fffaf0;
  font-size: 17px;
}

.membership-benefits.rich span {
  color: #9a968c;
  font-size: 15px;
  font-weight: 680;
}

.membership-benefits li {
  position: relative;
  padding-left: 28px;
  font-size: 16px;
  line-height: 1.55;
}

.membership-benefits li::before {
  position: absolute;
  left: 0;
  color: #cdb184;
  content: "鉁?;
  font-weight: 900;
}

.membership-button {
  width: 100%;
  min-height: 58px;
  border-radius: 12px;
  font-size: 17px;
  font-weight: 850;
}

.membership-button:disabled {
  cursor: not-allowed;
  opacity: 0.58;
}

.payment-box {
  align-self: end;
  display: grid;
  gap: 12px;
  margin-top: auto;
}

.payment-box p {
  margin: 0;
  color: #9a968c;
  font-size: 14px;
  font-weight: 800;
}

.payment-methods {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
}

.payment-methods button {
  min-height: 46px;
  border: 1px solid rgba(205, 177, 132, 0.2);
  border-radius: 11px;
  background: rgba(255, 255, 255, 0.035);
  color: #e7dcc8;
  font-weight: 800;
}

.payment-methods button:disabled,
.payment-methods button.disabled {
  cursor: not-allowed;
  border-color: rgba(255, 255, 255, 0.08);
  background: rgba(255, 255, 255, 0.025);
  color: rgba(231, 220, 200, 0.45);
}

.payment-methods button.active,
.payment-methods button:not(:disabled):hover {
  border-color: rgba(205, 177, 132, 0.52);
  background: rgba(205, 177, 132, 0.12);
  color: #fff4df;
}

.sentence-breakdown {
  display: grid;
  grid-template-columns: minmax(0, 0.9fr) minmax(0, 1.1fr);
  gap: 18px;
  align-items: start;
}

.sentence-breakdown-card {
  display: grid;
  gap: 18px;
  min-width: 0;
  padding: 22px;
  border: 1px solid rgba(205, 177, 132, 0.18);
  border-radius: 16px;
  background: rgba(24, 24, 28, 0.9);
  box-shadow: 0 18px 42px rgba(0, 0, 0, 0.22);
}

.sentence-breakdown-field {
  display: grid;
  gap: 10px;
  color: #d5c29e;
  font-size: 15px;
  font-weight: 850;
}

.sentence-breakdown-field textarea {
  min-height: 220px;
  resize: vertical;
  border: 1px solid rgba(205, 177, 132, 0.22);
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.035);
  color: #fff8ea;
  font: inherit;
  font-size: 18px;
  line-height: 1.7;
  padding: 16px;
  outline: none;
}

.sentence-breakdown-field textarea:focus {
  border-color: rgba(205, 177, 132, 0.58);
  box-shadow: 0 0 0 3px rgba(205, 177, 132, 0.12);
}

.sentence-breakdown-actions {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 120px;
  gap: 12px;
  align-items: center;
}

.sentence-breakdown-result > h3 {
  margin: 0;
  color: #fff8ea;
  font-size: 22px;
}

.sentence-breakdown-output {
  color: #efe4d1;
  font-size: 16px;
  line-height: 1.85;
}

.sentence-breakdown-output h3 {
  margin: 36px 0 16px;
  color: #d8ba7a;
  font-size: 18px;
}

.sentence-breakdown-output h3:first-child {
  margin-top: 0;
}

.sentence-breakdown-item-gap {
  display: block;
  height: 14px;
}

.sentence-breakdown-empty {
  margin: 0;
  color: #9d978b;
  font-size: 16px;
  line-height: 1.7;
}

.payment-notice {
  margin-top: 20px;
  padding: 18px 20px;
  border: 1px solid rgba(205, 177, 132, 0.24);
  border-radius: 16px;
  background: rgba(205, 177, 132, 0.07);
  color: #f0dfbd;
  font-weight: 700;
  line-height: 1.7;
}

.payment-qr-panel {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 22px;
  margin-top: 20px;
  padding: 20px;
  border: 1px solid rgba(205, 177, 132, 0.24);
  border-radius: 18px;
  background: linear-gradient(135deg, rgba(205, 177, 132, 0.13), rgba(255, 255, 255, 0.035));
}

.payment-qr-panel span {
  display: block;
  color: #d9bd83;
  font-weight: 900;
  margin-bottom: 8px;
}

.payment-qr-panel strong {
  display: block;
  color: #fff7e8;
  font-size: 24px;
}

.payment-qr-panel p {
  margin: 8px 0 0;
  color: rgba(255, 247, 232, 0.62);
}

.payment-qr-panel img {
  width: 180px;
  height: 180px;
  border-radius: 14px;
  padding: 10px;
  background: #fff7df;
}

.payment-dialog-overlay {
  position: fixed;
  inset: 0;
  z-index: 8500;
  display: grid;
  place-items: center;
  padding: 28px;
  background: rgba(0, 0, 0, 0.58);
  backdrop-filter: blur(10px);
}

.payment-dialog {
  width: min(1180px, 100%);
  max-height: calc(100vh - 56px);
  overflow: hidden auto;
  border: 1px solid rgba(205, 177, 132, 0.22);
  border-radius: 28px;
  background:
    linear-gradient(180deg, rgba(82, 78, 92, 0.88), rgba(36, 37, 42, 0.96) 112px),
    rgba(35, 36, 40, 0.96);
  box-shadow: 0 34px 110px rgba(0, 0, 0, 0.62), inset 0 1px 0 rgba(255, 255, 255, 0.08);
}

.payment-dialog-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 92px;
  padding: 24px 34px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.payment-dialog-head h2 {
  margin: 0;
  color: #ffffff;
  font-size: 32px;
  font-weight: 650;
}

.payment-dialog-close {
  display: grid;
  width: 46px;
  height: 46px;
  place-items: center;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.58);
  color: #33343a;
  font-size: 34px;
  line-height: 1;
}

.payment-dialog-body {
  display: grid;
  grid-template-columns: minmax(300px, 0.9fr) minmax(360px, 1.1fr);
  min-height: 560px;
}

.payment-dialog-left,
.payment-dialog-right {
  display: grid;
  align-content: center;
  gap: 22px;
  padding: 38px;
}

.payment-dialog-left {
  justify-items: center;
  border-right: 1px solid rgba(255, 255, 255, 0.08);
  background: rgba(255, 255, 255, 0.055);
  text-align: center;
}

.payment-dialog-price {
  color: #fffaf0;
  font-size: 46px;
  font-weight: 900;
}

.payment-dialog-price span {
  margin-right: 4px;
  font-size: 0.55em;
}

.payment-dialog-left p {
  width: min(360px, 100%);
  min-height: 22px;
  margin: 0;
  color: rgba(255, 255, 255, 0.78);
  font-size: 16px;
  font-weight: 760;
  text-align: center;
}

.payment-dialog-qr {
  display: grid;
  width: 230px;
  height: 230px;
  place-items: center;
  border: 1px solid rgba(205, 177, 132, 0.28);
  background: rgba(255, 255, 255, 0.08);
}

.payment-dialog-qr img {
  width: 210px;
  height: 210px;
  padding: 10px;
  background: #ffffff;
}

.payment-dialog-methods {
  display: grid;
  grid-template-columns: 1fr;
  width: min(360px, 100%);
  gap: 8px;
  padding: 6px;
  border-radius: 16px;
  background: rgba(0, 0, 0, 0.18);
}

.payment-dialog-methods button {
  min-height: 48px;
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.08);
  color: #fffaf0;
  font-weight: 850;
}

.payment-dialog-methods button.active {
  background: #fffaf0;
  color: #1b1b20;
}

.payment-dialog-methods button.disabled {
  color: rgba(255, 255, 255, 0.42);
}

.payment-dialog-right h3 {
  margin: 0;
  color: #ffffff;
  font-size: 28px;
}

.payment-steps {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  align-items: start;
}

.payment-steps span {
  display: grid;
  justify-items: center;
  gap: 10px;
  color: rgba(255, 255, 255, 0.68);
  font-weight: 850;
}

.payment-steps span::before {
  display: grid;
  width: 54px;
  height: 54px;
  place-items: center;
  border-radius: 50%;
  background: #ffffff;
  color: #111113;
  font-size: 24px;
}

.payment-steps span.active::before {
  background: #d6bc87;
  color: #111113;
}

.payment-steps span:nth-child(1)::before {
  content: "01";
}

.payment-steps span:nth-child(2)::before {
  content: "02";
}

.payment-steps span:nth-child(3)::before {
  content: "03";
}

.payment-steps em {
  color: rgba(255, 255, 255, 0.72);
  font-size: 16px;
  font-style: normal;
}

.payment-guidance {
  padding: 28px;
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 22px;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.16), rgba(255, 255, 255, 0.06)),
    rgba(255, 255, 255, 0.05);
}

.payment-guidance h4 {
  margin: 0 0 18px;
  color: #fffaf0;
  font-size: 22px;
}

.payment-guidance ul {
  display: grid;
  gap: 14px;
  margin: 0;
  padding-left: 22px;
  color: rgba(255, 255, 255, 0.82);
  font-weight: 760;
  line-height: 1.55;
}

.payment-refresh,
.payment-help {
  min-height: 58px;
  border-radius: 16px;
  color: #ffffff;
  font-size: 18px;
  font-weight: 850;
}

.payment-refresh {
  background: linear-gradient(135deg, #d6bc87, #9d7d47);
  color: #111113;
}

.payment-help {
  background: rgba(255, 255, 255, 0.1);
}

.payment-history {
  display: grid;
  gap: 14px;
  margin-top: 20px;
  padding: 20px;
  border: 1px solid rgba(205, 177, 132, 0.16);
  border-radius: 18px;
  background: rgba(27, 27, 32, 0.7);
}

.payment-history h3 {
  margin: 0;
  color: #fffaf0;
  font-size: 18px;
}

.payment-history > div {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
}

.payment-history article {
  display: grid;
  gap: 6px;
  padding: 14px;
  border: 1px solid rgba(205, 177, 132, 0.14);
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.03);
}

.payment-history strong {
  color: #fffaf0;
  font-size: 15px;
}

.mock-pay-button {
  justify-self: start;
  min-height: 36px;
  margin-top: 4px;
  padding: 0 13px;
  border: 1px solid rgba(205, 177, 132, 0.3);
  border-radius: 999px;
  background: rgba(205, 177, 132, 0.13);
  color: #f1dba9;
  font-size: 13px;
  font-weight: 850;
}

.mock-pay-button:hover {
  border-color: rgba(205, 177, 132, 0.62);
  background: rgba(205, 177, 132, 0.24);
  color: #fff7e6;
}

.legal-grid,
.admin-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 18px;
}

.legal-card,
.admin-card,
.admin-metric {
  border: 1px solid rgba(205, 177, 132, 0.18);
  border-radius: 18px;
  background:
    linear-gradient(145deg, rgba(205, 177, 132, 0.07), rgba(255, 255, 255, 0.015)),
    rgba(27, 27, 32, 0.82);
  box-shadow: 0 24px 72px rgba(0, 0, 0, 0.24);
}

.legal-card {
  padding: 24px;
}

.legal-card h3,
.admin-card h3 {
  margin: 0 0 14px;
  color: #fffaf0;
  font-size: 22px;
}

.legal-card ul {
  display: grid;
  gap: 12px;
  margin: 0;
  padding-left: 20px;
  color: #c9c0b4;
  line-height: 1.75;
}

.admin-metrics {
  display: grid;
  grid-template-columns: repeat(6, minmax(0, 1fr));
  gap: 12px;
  margin-bottom: 20px;
}

.admin-access-panel,
.admin-session-bar {
  border: 1px solid rgba(205, 177, 132, 0.18);
  border-radius: 18px;
  background:
    linear-gradient(145deg, rgba(205, 177, 132, 0.07), rgba(255, 255, 255, 0.015)),
    rgba(27, 27, 32, 0.82);
  box-shadow: 0 24px 72px rgba(0, 0, 0, 0.24);
}

.admin-access-panel {
  display: grid;
  gap: 18px;
  max-width: 560px;
  padding: 24px;
}

.admin-access-panel h3,
.admin-access-panel p {
  margin: 0;
}

.admin-access-panel h3 {
  color: #fffaf0;
  font-size: 24px;
}

.admin-access-panel p,
.admin-access-panel span {
  color: #b9b2a8;
}

.admin-access-panel label {
  display: grid;
  gap: 8px;
}

.admin-access-panel input {
  width: 100%;
  min-height: 48px;
  border: 1px solid rgba(205, 177, 132, 0.28);
  border-radius: 12px;
  padding: 0 14px;
  color: #fffaf0;
  background: rgba(12, 12, 14, 0.72);
}

.admin-access-panel button,
.admin-session-bar button {
  min-height: 44px;
  border: 1px solid rgba(205, 177, 132, 0.42);
  border-radius: 12px;
  padding: 0 16px;
  color: #181511;
  background: #d7ba83;
  font-weight: 850;
  cursor: pointer;
}

.admin-access-notice {
  color: #f1dba9 !important;
}

.admin-session-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  margin-bottom: 20px;
  padding: 14px 16px;
  color: #c9c0b4;
}

.admin-metric {
  display: grid;
  gap: 8px;
  min-height: 106px;
  padding: 18px;
}

.admin-metric span {
  color: #9a968c;
  font-weight: 800;
}

.admin-metric strong {
  color: #f1dba9;
  font-size: 34px;
  line-height: 1;
}

.admin-status-panel {
  display: grid;
  gap: 18px;
  margin-bottom: 20px;
  padding: 22px;
  border: 1px solid rgba(205, 177, 132, 0.18);
  border-radius: 18px;
  background:
    linear-gradient(145deg, rgba(205, 177, 132, 0.06), rgba(255, 255, 255, 0.012)),
    rgba(27, 27, 32, 0.82);
}

.admin-task-panel {
  display: grid;
  gap: 18px;
  margin-bottom: 20px;
  padding: 22px;
  border: 1px solid rgba(205, 177, 132, 0.18);
  border-radius: 18px;
  background:
    linear-gradient(145deg, rgba(205, 177, 132, 0.055), rgba(255, 255, 255, 0.012)),
    rgba(27, 27, 32, 0.82);
}

.admin-report-panel {
  display: grid;
  gap: 18px;
  margin-bottom: 20px;
  padding: 22px;
  border: 1px solid rgba(205, 177, 132, 0.18);
  border-radius: 18px;
  background:
    linear-gradient(145deg, rgba(205, 177, 132, 0.05), rgba(255, 255, 255, 0.012)),
    rgba(27, 27, 32, 0.82);
}

.admin-payment-panel {
  display: grid;
  gap: 18px;
  margin-bottom: 20px;
  padding: 22px;
  border: 1px solid rgba(205, 177, 132, 0.18);
  border-radius: 18px;
  background:
    linear-gradient(145deg, rgba(205, 177, 132, 0.055), rgba(255, 255, 255, 0.012)),
    rgba(27, 27, 32, 0.82);
}

.admin-referral-panel {
  display: grid;
  gap: 18px;
  margin-bottom: 20px;
  padding: 22px;
  border: 1px solid rgba(205, 177, 132, 0.18);
  border-radius: 18px;
  background:
    linear-gradient(145deg, rgba(205, 177, 132, 0.055), rgba(255, 255, 255, 0.012)),
    rgba(27, 27, 32, 0.82);
}

.admin-report-panel > h3 {
  margin: 0;
  color: #fffaf0;
  font-size: 22px;
}

.admin-report-panel > p {
  margin: 0;
  color: #9a968c;
  font-size: 14px;
  font-weight: 750;
}

.admin-audit-panel {
  display: grid;
  gap: 18px;
  margin-bottom: 20px;
  padding: 22px;
  border: 1px solid rgba(205, 177, 132, 0.18);
  border-radius: 18px;
  background:
    linear-gradient(145deg, rgba(205, 177, 132, 0.052), rgba(255, 255, 255, 0.012)),
    rgba(27, 27, 32, 0.82);
}

.admin-audit-panel > h3 {
  margin: 0;
  color: #fffaf0;
  font-size: 22px;
}

.admin-audit-panel > p {
  margin: 0;
  color: #b7ada0;
  font-size: 14px;
  font-weight: 750;
}

.admin-status-heading {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
}

.admin-status-heading h3 {
  margin: 0;
  color: #fffaf0;
  font-size: 22px;
}

.admin-status-heading p,
.admin-status-time {
  margin: 6px 0 0;
  color: #9a968c;
  font-size: 13px;
  font-weight: 700;
}

.admin-status-heading button {
  min-height: 40px;
  padding: 0 14px;
  border: 1px solid rgba(205, 177, 132, 0.25);
  border-radius: 12px;
  background: rgba(205, 177, 132, 0.1);
  color: #f0dfbd;
  font-weight: 850;
}

.admin-status-heading button:hover {
  border-color: rgba(205, 177, 132, 0.55);
  background: rgba(205, 177, 132, 0.2);
  color: #fff7e6;
}

.admin-service-list {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
}

.admin-service-row {
  display: grid;
  gap: 10px;
  min-height: 118px;
  padding: 16px;
  border: 1px solid rgba(205, 177, 132, 0.14);
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.03);
}

.admin-service-row > div {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.admin-service-row strong {
  color: #fffaf0;
  font-size: 15px;
}

.admin-service-row span {
  padding: 5px 9px;
  border-radius: 999px;
  color: #111113;
  background: #cdb184;
  font-size: 12px;
  font-weight: 900;
  white-space: nowrap;
}

.admin-service-row.warning span {
  background: #ffd166;
}

.admin-service-row.disabled span {
  background: #9a968c;
}

.admin-service-row.ready span {
  background: #75d69b;
}

.admin-service-row p {
  margin: 0;
  color: #b7ada0;
  font-size: 13px;
  line-height: 1.6;
  word-break: break-word;
}

.admin-task-list {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}

.admin-task {
  display: grid;
  gap: 10px;
  min-height: 132px;
  padding: 16px;
  border: 1px solid rgba(205, 177, 132, 0.14);
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.03);
}

.admin-task > div {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.admin-task strong {
  color: #fffaf0;
  font-size: 16px;
}

.admin-task span {
  padding: 5px 9px;
  border-radius: 999px;
  color: #111113;
  background: #cdb184;
  font-size: 12px;
  font-weight: 900;
  white-space: nowrap;
}

.admin-task.done span {
  background: #75d69b;
}

.admin-task.ready span {
  background: #7dd3fc;
}

.admin-task.waiting span {
  background: #ffd166;
}

.admin-task.blocked span {
  background: #f29a9a;
}

.admin-task p {
  margin: 0;
  color: #b7ada0;
  font-size: 14px;
  line-height: 1.7;
}

.admin-report-list {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
}

.admin-payment-summary {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
}

.admin-referral-list {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 12px;
}

.admin-payment-stat,
.admin-payment-event,
.admin-referral-item {
  border: 1px solid rgba(205, 177, 132, 0.14);
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.03);
}

.admin-payment-stat {
  display: grid;
  gap: 8px;
  padding: 14px;
}

.admin-payment-stat span {
  color: #9a968c;
  font-size: 12px;
  font-weight: 850;
}

.admin-payment-stat strong {
  color: #f1dba9;
  font-size: 18px;
  line-height: 1.2;
  word-break: break-word;
}

.admin-payment-events {
  display: grid;
  gap: 10px;
}

.admin-payment-event {
  display: grid;
  gap: 8px;
  padding: 14px;
}

.admin-payment-event > div {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.admin-payment-event strong {
  color: #fffaf0;
  font-size: 15px;
}

.admin-payment-event span {
  padding: 5px 9px;
  border-radius: 999px;
  color: #111113;
  background: #cdb184;
  font-size: 12px;
  font-weight: 900;
  white-space: nowrap;
}

.admin-payment-event.warning span {
  background: #f29a9a;
}

.admin-payment-event p {
  margin: 0;
  color: #b7ada0;
  font-size: 13px;
  line-height: 1.6;
  word-break: break-word;
}

.admin-payment-event em,
.admin-empty-text {
  color: #8f887c;
  font-size: 12px;
  font-style: normal;
  font-weight: 750;
}

.admin-referral-item {
  display: grid;
  gap: 10px;
  min-height: 132px;
  padding: 16px;
}

.admin-referral-item > div {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.admin-referral-item strong {
  color: #fffaf0;
  font-size: 15px;
}

.admin-referral-item span {
  padding: 5px 9px;
  border-radius: 999px;
  color: #111113;
  background: #cdb184;
  font-size: 12px;
  font-weight: 900;
  white-space: nowrap;
}

.admin-referral-item.ready span {
  background: #75d69b;
}

.admin-referral-item.waiting span {
  background: #ffd166;
}

.admin-referral-item p {
  margin: 0;
  color: #b7ada0;
  font-size: 13px;
  line-height: 1.6;
}

.admin-report-card {
  display: grid;
  gap: 10px;
  min-height: 156px;
  padding: 16px;
  border: 1px solid rgba(205, 177, 132, 0.14);
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.03);
}

.admin-report-card > div {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.admin-report-card strong {
  color: #fffaf0;
  font-size: 16px;
}

.admin-report-card span {
  padding: 5px 9px;
  border-radius: 999px;
  color: #111113;
  background: #cdb184;
  font-size: 12px;
  font-weight: 900;
  white-space: nowrap;
}

.admin-report-card.passed span {
  background: #75d69b;
}

.admin-report-card.warning span {
  background: #ffd166;
}

.admin-report-card.missing span {
  background: #f29a9a;
}

.admin-report-card p {
  margin: 0;
  color: #d9c9ab;
  font-size: 14px;
  line-height: 1.65;
}

.admin-report-card em,
.admin-report-card small {
  color: #8f897f;
  font-size: 12px;
  font-style: normal;
}

.admin-audit-stats {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 12px;
}

.admin-audit-stat {
  display: grid;
  gap: 8px;
  padding: 14px;
  border: 1px solid rgba(205, 177, 132, 0.14);
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.03);
}

.admin-audit-stat span {
  color: #9a968c;
  font-size: 12px;
  font-weight: 850;
}

.admin-audit-stat strong {
  color: #75d69b;
  font-size: 30px;
  line-height: 1;
}

.admin-audit-stat.warning strong {
  color: #ffd166;
}

.admin-audit-samples {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}

.admin-audit-sample-group {
  display: grid;
  gap: 10px;
  padding: 16px;
  border: 1px solid rgba(205, 177, 132, 0.14);
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.03);
}

.admin-audit-sample-group h4 {
  margin: 0;
  color: #fffaf0;
  font-size: 16px;
}

.admin-audit-sample-group p {
  display: grid;
  gap: 4px;
  margin: 0;
  padding-top: 8px;
  border-top: 1px solid rgba(205, 177, 132, 0.1);
}

.admin-audit-sample-group strong {
  color: #cdb184;
  font-size: 12px;
}

.admin-audit-sample-group span {
  color: #d9c9ab;
  font-size: 13px;
  line-height: 1.55;
}

.admin-card {
  display: grid;
  gap: 14px;
  align-content: start;
  padding: 24px;
}

.admin-card p {
  margin: 0;
  color: #b7ada0;
  line-height: 1.7;
}

.admin-card code {
  display: block;
  padding: 12px 14px;
  border: 1px solid rgba(205, 177, 132, 0.14);
  border-radius: 12px;
  background: rgba(0, 0, 0, 0.24);
  color: #f1dba9;
  font-family: "Cascadia Code", Consolas, monospace;
}

.admin-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.admin-actions button {
  min-height: 42px;
  padding: 0 16px;
  border: 1px solid rgba(205, 177, 132, 0.24);
  border-radius: 12px;
  background: rgba(205, 177, 132, 0.12);
  color: #f0dfbd;
  font-weight: 850;
}

.admin-actions button:hover {
  border-color: rgba(205, 177, 132, 0.56);
  background: rgba(205, 177, 132, 0.22);
  color: #fff7e6;
}

.payment-history span,
.payment-history em {
  color: #a99f93;
  font-size: 13px;
  font-style: normal;
}

.partner-hero {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 220px;
  gap: 20px;
  align-items: center;
  margin-bottom: 20px;
  padding: 28px;
  border: 1px solid rgba(205, 177, 132, 0.22);
  border-radius: 22px;
  background:
    radial-gradient(circle at 82% 16%, rgba(205, 177, 132, 0.16), transparent 28%),
    linear-gradient(145deg, rgba(205, 177, 132, 0.08), rgba(255, 255, 255, 0.014)),
    rgba(27, 27, 32, 0.88);
  box-shadow: 0 28px 86px rgba(0, 0, 0, 0.32);
}

.partner-hero.active {
  border-color: rgba(205, 177, 132, 0.5);
}

.partner-hero h3 {
  margin: 0;
  color: #fffaf0;
  font-size: clamp(30px, 4vw, 52px);
  line-height: 1.1;
}

.partner-hero p {
  margin: 14px 0 0;
  color: #b7ada0;
  font-weight: 700;
  line-height: 1.7;
}

.partner-code-card {
  display: grid;
  gap: 10px;
  min-height: 132px;
  align-content: center;
  padding: 20px;
  border: 1px solid rgba(205, 177, 132, 0.2);
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.035);
  text-align: center;
}

.partner-code-card span {
  color: #9a968c;
  font-size: 13px;
  font-weight: 850;
}

.partner-code-card strong {
  color: #f1dba9;
  font-size: 32px;
  letter-spacing: 0.04em;
}

.partner-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 18px;
}

.partner-panel {
  display: grid;
  gap: 16px;
  align-content: start;
  min-height: 230px;
  padding: 24px;
  border: 1px solid rgba(205, 177, 132, 0.18);
  border-radius: 18px;
  background:
    linear-gradient(145deg, rgba(205, 177, 132, 0.06), rgba(255, 255, 255, 0.014)),
    rgba(27, 27, 32, 0.82);
  box-shadow: 0 24px 72px rgba(0, 0, 0, 0.24);
}

.partner-panel h3 {
  margin: 0;
  color: #fffaf0;
  font-size: 22px;
}

.partner-panel p,
.partner-muted {
  margin: 0;
  color: #b7ada0;
  line-height: 1.7;
}

.partner-link-box {
  padding: 14px 16px;
  overflow-wrap: anywhere;
  border: 1px solid rgba(205, 177, 132, 0.18);
  border-radius: 14px;
  background: rgba(0, 0, 0, 0.24);
  color: #f1dba9;
  font-family: "Cascadia Code", Consolas, monospace;
  line-height: 1.6;
}

.partner-stats {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 10px;
}

.partner-stats article {
  display: grid;
  gap: 8px;
  padding: 14px;
  border: 1px solid rgba(205, 177, 132, 0.14);
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.03);
}

.partner-stats span {
  color: #9a968c;
  font-size: 12px;
  font-weight: 850;
}

.partner-stats strong {
  color: #f1dba9;
  font-size: 24px;
  line-height: 1;
}

.partner-rule-list {
  display: grid;
  gap: 12px;
  margin: 0;
  padding-left: 20px;
  color: #d9c9ab;
  line-height: 1.75;
}

.auth-card {
  display: grid;
  gap: 22px;
  max-width: 620px;
  padding: 32px;
  border: 1px solid rgba(205, 177, 132, 0.28);
  border-radius: 22px;
  background:
    linear-gradient(145deg, rgba(255, 255, 255, 0.055), rgba(255, 255, 255, 0.014)),
    rgba(27, 27, 32, 0.92);
  box-shadow: 0 28px 86px rgba(0, 0, 0, 0.32), inset 0 1px 0 rgba(255, 255, 255, 0.045);
}

.auth-shell {
  grid-template-columns: 1fr;
  min-height: 100vh;
  background: #ffffff;
}

.auth-shell .sidebar,
.auth-shell .site-icp-footer {
  display: none;
}

.auth-shell .main {
  padding: 0;
  overflow: auto;
  background: #ffffff;
}

.auth-shell .main-inner {
  width: 100%;
  max-width: none;
  min-height: 100vh;
}

.auth-layout {
  display: grid;
  grid-template-columns: minmax(360px, 0.85fr) minmax(480px, 1.15fr);
  min-height: 100vh;
  background: #ffffff;
  color: #111827;
}

.auth-visual {
  position: relative;
  display: grid;
  align-content: center;
  justify-items: center;
  overflow: hidden;
  padding: 56px;
  background: linear-gradient(145deg, #7537d6, #3a2097);
  color: #ffffff;
}

.auth-visual::before {
  content: "";
  position: absolute;
  width: min(72vw, 680px);
  aspect-ratio: 1;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.12);
  transform: translate(-10%, 10%);
}

.auth-visual-mark {
  position: relative;
  z-index: 1;
  display: grid;
  place-items: center;
  width: 86px;
  height: 86px;
  margin-bottom: 26px;
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.18);
}

.auth-visual-mark img {
  width: 56px;
  height: 48px;
  object-fit: contain;
}

.auth-visual-figure {
  position: relative;
  z-index: 1;
  width: min(52vw, 360px);
  height: 280px;
  margin-bottom: 28px;
}

.auth-figure-head,
.auth-figure-body,
.auth-figure-book {
  position: absolute;
  left: 50%;
  transform: translateX(-50%);
}

.auth-figure-head {
  top: 18px;
  width: 104px;
  height: 104px;
  border-radius: 50%;
  background: #f7d7dd;
}

.auth-figure-body {
  top: 108px;
  width: 210px;
  height: 118px;
  border-radius: 52% 52% 22px 22px;
  background: #fff5f0;
  box-shadow: inset 0 -22px #ef6f8f;
}

.auth-figure-book {
  bottom: 24px;
  width: 250px;
  height: 56px;
  border-radius: 16px;
  background: linear-gradient(90deg, #fb5f89 0 52%, #ffc766 52%);
}

.auth-visual h2 {
  position: relative;
  z-index: 1;
  margin: 0;
  color: #ffffff;
  font-size: clamp(34px, 5vw, 54px);
  line-height: 1.25;
  text-align: center;
}

.auth-panel {
  display: grid;
  align-content: center;
  width: min(680px, calc(100vw - 48px));
  margin: 0 auto;
  padding: 48px 24px;
}

.auth-scan,
.auth-form {
  display: grid;
  gap: 22px;
  width: 100%;
  max-width: 560px;
  margin: 0 auto;
}

.auth-scan {
  justify-items: center;
  text-align: center;
}

.auth-scan h2,
.auth-form h2,
.auth-bind-card h2 {
  margin: 0;
  color: #111827;
  font-size: 30px;
  line-height: 1.2;
}

.auth-qr-box {
  display: grid;
  place-items: center;
  width: 220px;
  height: 220px;
  border-radius: 18px;
  background: #f3f4f8;
}

.auth-qr-box img {
  width: 176px;
  height: 176px;
  border-radius: 12px;
  background: #ffffff;
}

.auth-qr-box button {
  min-height: 48px;
  padding: 0 18px;
  border-radius: 12px;
  background: #aa4cec;
  color: #ffffff;
  font-weight: 820;
}

.auth-scan h3 {
  margin: 0;
  color: #111827;
  font-size: 22px;
}

.auth-scan p,
.auth-bind-card p {
  margin: 0;
  color: #6b7280;
  line-height: 1.65;
}

.auth-scan-legal {
  font-size: 14px;
}

.auth-scan-legal button {
  padding: 0;
  background: transparent;
  color: #9d38ee;
  font-weight: 760;
  text-decoration: underline;
}

.auth-return-link,
.auth-back-scan,
.auth-forgot {
  justify-self: end;
  background: transparent;
  color: #6b7280;
  font-size: 15px;
  font-weight: 700;
}

.auth-field.light span {
  color: #374151;
  font-size: 16px;
  font-weight: 720;
}

.auth-field.light b {
  color: #ff4a5f;
}

.auth-field.light input {
  min-height: 54px;
  border: 1px solid #d1d5db;
  border-radius: 9px;
  background: #ffffff;
  color: #111827;
  font-size: 18px;
  font-weight: 650;
}

.auth-field.light input[readonly] {
  background: #f3f4f6;
  color: #6b7280;
}

.auth-target-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 136px;
  gap: 10px;
}

.auth-send-button {
  min-height: 54px;
  border-radius: 9px;
  background: #c084ef;
  color: #ffffff;
  font-weight: 820;
}

.auth-agree-row {
  display: flex;
  align-items: center;
  gap: 10px;
  color: #4b5563;
  font-size: 15px;
}

.auth-agree-row input {
  width: 18px;
  height: 18px;
  accent-color: #b353f3;
}

.auth-agree-row button {
  padding: 0;
  background: transparent;
  color: #9d38ee;
  text-decoration: underline;
}

.auth-submit {
  width: 100%;
  min-height: 58px;
  border-radius: 10px;
  background: linear-gradient(135deg, #bc74f4, #a63ff0);
  color: #ffffff;
  font-size: 19px;
  font-weight: 850;
}

.auth-submit:disabled {
  background: #e5e7eb;
  color: #ffffff;
}

.auth-mode-tabs {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
  padding-top: 18px;
  border-top: 1px solid #e5e7eb;
}

.auth-mode-tabs button {
  display: grid;
  justify-items: center;
  gap: 6px;
  min-height: 82px;
  border-radius: 12px;
  background: transparent;
  color: #4b5563;
}

.auth-mode-tabs button.active,
.auth-mode-tabs button:hover {
  background: #fbf5ff;
  color: #a53fed;
  box-shadow: inset 0 0 0 1px rgba(164, 63, 237, 0.12);
}

.auth-mode-tabs svg {
  width: 26px;
  height: 26px;
  fill: none;
  stroke: currentColor;
  stroke-linecap: round;
  stroke-linejoin: round;
  stroke-width: 1.8;
}

.auth-mode-tabs em {
  font-style: normal;
  font-weight: 760;
}

.auth-bind-card {
  display: grid;
  gap: 24px;
  width: min(520px, 100%);
  margin: 0 auto;
  padding: 34px;
  border: 1px solid #e5e7eb;
  border-radius: 18px;
  background: #ffffff;
  box-shadow: 0 24px 80px rgba(17, 24, 39, 0.12);
}

.auth-phone-row {
  display: grid;
  grid-template-columns: 76px minmax(0, 1fr);
}

.auth-phone-row strong {
  display: grid;
  place-items: center;
  border: 1px solid #d1d5db;
  border-right: 0;
  border-radius: 9px 0 0 9px;
  background: #f8fafc;
  color: #4b5563;
}

.auth-phone-row input {
  border-radius: 0 9px 9px 0 !important;
}

.auth-bind-actions {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 14px;
}

.auth-bind-actions button {
  min-height: 54px;
  border-radius: 10px;
  font-size: 18px;
  font-weight: 820;
}

.auth-bind-actions button:first-child {
  border: 1px solid #e5e7eb;
  background: #ffffff;
  color: #111827;
}

.auth-bind-actions button:last-child {
  background: #c084ef;
  color: #ffffff;
}

.auth-kicker {
  margin: 0;
  color: #cdb184;
  font-size: 14px;
  font-weight: 850;
}

.auth-card h3 {
  margin: 0;
  color: #fffaf0;
  font-size: clamp(26px, 3vw, 38px);
  line-height: 1.18;
}

.auth-copy,
.auth-help {
  margin: 0;
  color: #9a968c;
  line-height: 1.7;
}

.sms-config-card {
  display: grid;
  gap: 6px;
  padding: 14px 16px;
  border-radius: 14px;
  color: #efe2c5;
  font-size: 14px;
  line-height: 1.55;
}

.sms-config-card strong {
  color: #fff7e6;
  font-size: 15px;
}

.sms-config-card span {
  color: #c8b99e;
}

.sms-config-card.muted {
  border: 1px solid rgba(205, 177, 132, 0.18);
  background: rgba(255, 255, 255, 0.035);
}

.sms-config-card.warning {
  border: 1px solid rgba(255, 190, 96, 0.3);
  background: rgba(255, 190, 96, 0.08);
}

.sms-config-card.ready {
  border: 1px solid rgba(86, 211, 142, 0.3);
  background: rgba(86, 211, 142, 0.09);
  color: #b9f3ca;
}

.auth-switch {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
  padding: 6px;
  border: 1px solid rgba(205, 177, 132, 0.13);
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.035);
}

.auth-switch button {
  min-height: 48px;
  border-radius: 10px;
  background: transparent;
  color: #a9a196;
  font-weight: 850;
}

.auth-switch button.active,
.auth-switch button:hover {
  background: #cdb184;
  color: #111113;
}

.auth-field {
  display: grid;
  gap: 10px;
}

.auth-field span {
  color: #cdb184;
  font-size: 14px;
  font-weight: 850;
}

.auth-field input {
  width: 100%;
  min-height: 58px;
  padding: 0 16px;
  border: 1px solid rgba(205, 177, 132, 0.2);
  border-radius: 12px;
  outline: none;
  background: rgba(255, 255, 255, 0.035);
  color: #fffaf0;
  font: inherit;
  font-weight: 700;
}

.auth-target-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: stretch;
  gap: 10px;
}

.auth-send-button {
  min-width: 122px;
  min-height: 58px;
  padding: 0 16px;
  border: 1px solid rgba(205, 177, 132, 0.34);
  border-radius: 12px;
  background: rgba(205, 177, 132, 0.13);
  color: #f6dfaa;
  font-weight: 900;
  white-space: nowrap;
}

.auth-send-button:hover {
  border-color: rgba(205, 177, 132, 0.58);
  background: rgba(205, 177, 132, 0.2);
}

.auth-send-button:disabled {
  border-color: transparent;
  background: #d1d5db;
  color: #ffffff;
  cursor: not-allowed;
}

.auth-field input:focus {
  border-color: rgba(205, 177, 132, 0.58);
  box-shadow: 0 0 0 3px rgba(205, 177, 132, 0.12);
}

.auth-actions {
  display: grid;
  grid-template-columns: 1fr;
  gap: 12px;
}

.auth-actions .membership-button:only-child {
  grid-column: 1 / -1;
}

.auth-actions:empty {
  display: none;
}

.auth-notice {
  padding: 14px 16px;
  border: 1px solid rgba(205, 177, 132, 0.24);
  border-radius: 14px;
  background: rgba(205, 177, 132, 0.07);
  color: #f0dfbd;
  font-weight: 750;
  line-height: 1.65;
}

.auth-notice.success {
  border-color: rgba(86, 211, 142, 0.3);
  background: rgba(86, 211, 142, 0.09);
  color: #bdf4ce;
}

.auth-notice.warning {
  border-color: rgba(255, 155, 120, 0.3);
  background: rgba(255, 155, 120, 0.09);
  color: #ffd6c5;
}

.auth-panel {
  padding: 36px 24px;
}

.auth-scan,
.auth-form {
  gap: 16px;
  max-width: 520px;
}

.auth-scan h2,
.auth-form h2,
.auth-bind-card h2 {
  font-size: 26px;
}

.auth-qr-box {
  position: relative;
}

.auth-qr-box.expired img {
  opacity: 0.24;
  filter: grayscale(1);
}

.auth-qr-expired {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #111827;
  font-size: 15px;
  font-weight: 760;
  background: rgba(255, 255, 255, 0.12);
}

.auth-qr-expired button {
  min-height: auto;
  padding: 0;
  border-radius: 0;
  background: transparent;
  color: #2563eb;
  font: inherit;
  text-decoration: underline;
}

.auth-scan h3 {
  font-size: 20px;
}

.auth-scan p,
.auth-bind-card p {
  font-size: 15px;
  line-height: 1.55;
}

.auth-field {
  gap: 7px;
}

.auth-field.light span {
  font-size: 14px;
}

.auth-field.light input,
.auth-send-button {
  min-height: 46px;
  font-size: 15px;
}

.auth-target-row {
  grid-template-columns: minmax(0, 1fr) 120px;
  gap: 9px;
}

.auth-send-button {
  min-width: 112px;
  padding: 0 12px;
}

.auth-agree-row {
  align-items: flex-start;
  font-size: 14px;
  line-height: 1.55;
}

.auth-submit {
  min-height: 48px;
  font-size: 16px;
}

.auth-mode-tabs {
  gap: 10px;
  padding-top: 14px;
}

.auth-mode-tabs button {
  min-height: 68px;
}

.auth-mode-tabs svg {
  width: 22px;
  height: 22px;
}

.auth-bind-card {
  gap: 18px;
  padding: 28px;
}

.auth-bind-actions button {
  min-height: 48px;
  font-size: 16px;
}

.legal-modal-backdrop {
  position: fixed;
  inset: 0;
  z-index: 100;
  display: grid;
  place-items: center;
  padding: 28px;
  background: rgba(0, 0, 0, 0.72);
  backdrop-filter: blur(4px);
}

.legal-modal {
  width: min(980px, calc(100vw - 56px));
  max-height: min(78vh, 820px);
  overflow: hidden;
  border-radius: 8px;
  background: #ffffff;
  color: #4b5563;
  box-shadow: 0 24px 80px rgba(0, 0, 0, 0.32);
}

.legal-modal-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 18px 24px;
  border-bottom: 1px solid #e5e7eb;
}

.legal-modal-head h2 {
  margin: 0;
  color: #111827;
  font-size: 20px;
  line-height: 1.3;
}

.legal-modal-head button {
  display: grid;
  place-items: center;
  width: 28px;
  height: 28px;
  border: 1px solid #d1d5db;
  border-radius: 50%;
  background: #ffffff;
  color: #6b7280;
  font-size: 22px;
  line-height: 1;
}

.legal-modal-body {
  max-height: calc(min(78vh, 820px) - 66px);
  overflow: auto;
  padding: 28px 34px 34px;
  font-size: 16px;
  line-height: 1.85;
}

.legal-modal-body p {
  margin: 0 0 18px;
}

.legal-modal-body .legal-modal-heading {
  margin-top: 30px;
  color: #111827;
  font-size: 20px;
  font-weight: 850;
  line-height: 1.45;
}

@media (max-width: 1180px) {
  .auth-layout {
    grid-template-columns: 1fr;
  }

  .auth-visual {
    min-height: 360px;
  }

  .sentence-breakdown {
    grid-template-columns: 1fr;
  }

  .membership-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .membership-grid-vip,
  .membership-grid-partner {
    grid-template-columns: 1fr;
  }

  .payment-dialog-body {
    grid-template-columns: 1fr;
  }

  .payment-dialog-left {
    border-right: 0;
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
  }

  .partner-hero,
  .partner-grid {
    grid-template-columns: 1fr;
  }

  .membership-card {
    min-height: 0;
  }

  .payment-history > div {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 640px) {
  .auth-shell .main-inner {
    min-height: 100vh;
  }

  .auth-visual {
    min-height: 260px;
    padding: 34px 20px;
  }

  .auth-visual-figure {
    display: none;
  }

  .auth-panel {
    width: 100%;
    padding: 32px 18px;
  }

  .auth-target-row,
  .auth-bind-actions {
    grid-template-columns: 1fr;
  }

  .auth-mode-tabs {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .topbar-actions {
    justify-content: flex-start;
  }

  .profile-chip span {
    display: none;
  }

  .profile-overlay {
    padding: 0;
  }

  .profile-panel {
    width: 100%;
    max-height: 100vh;
    min-height: 100vh;
    border-radius: 0;
  }

  .profile-edit-panel,
  .delete-account-panel {
    width: 100%;
    max-height: 100vh;
    min-height: 100vh;
    border-radius: 0;
  }

  .profile-edit-body {
    grid-template-columns: 88px 1fr;
    gap: 16px;
    padding: 22px 18px 18px;
  }

  .profile-edit-avatar {
    width: 78px;
    height: 78px;
    border-radius: 20px;
  }

  .delete-code-row {
    grid-template-columns: 1fr;
  }

  .profile-list div,
  .profile-row-button {
    grid-template-columns: 94px minmax(0, 1fr);
  }

  .profile-list span,
  .profile-row-button {
    font-size: 14px;
  }

  .profile-list strong {
    font-size: 13px;
  }

  .membership-tabs {
    width: 100%;
  }

  .membership-tabs button {
    min-width: 0;
    flex: 1;
  }

  .membership-grid {
    grid-template-columns: 1fr;
  }

  .membership-card-head {
    padding-right: 76px;
  }

  .membership-ribbon {
    top: 22px;
    right: 20px;
  }

  .payment-dialog-overlay {
    padding: 0;
  }

  .payment-dialog {
    width: 100%;
    max-height: 100vh;
    min-height: 100vh;
    border-radius: 0;
  }

  .payment-dialog-head {
    min-height: 78px;
    padding: 18px 20px;
  }

  .payment-dialog-head h2 {
    font-size: 26px;
  }

  .payment-dialog-left,
  .payment-dialog-right {
    padding: 24px 20px;
  }

  .payment-steps em {
    font-size: 13px;
  }

  .partner-hero,
  .partner-panel {
    padding: 18px;
  }

  .partner-stats {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .vocab-deck-list {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .vocab-deck-card .deck-cover strong {
    font-size: 16px;
  }
}

/* UI preview: sidebar and ICP placement */
.sidebar {
  display: flex;
  flex-direction: column;
}

.sidebar-bottom {
  display: grid;
  gap: 12px;
  margin-top: auto;
  padding-top: 18px;
}

.sidebar-bottom .account-panel {
  margin: 0;
}

.sidebar-legal-links {
  display: flex;
  justify-content: center;
  gap: 14px;
  font-size: 12px;
}

.sidebar-legal-links button {
  padding: 0;
  border: 0;
  background: transparent;
  color: rgba(240, 223, 189, 0.72);
  cursor: pointer;
}

.sidebar-legal-links button:hover {
  color: #fff7e6;
  text-decoration: underline;
}

.icp-placeholder {
  display: none;
}

.site-icp-footer {
  position: static;
  left: auto;
  bottom: auto;
  z-index: auto;
  grid-column: 1 / -1;
  justify-self: center;
  transform: none;
  margin: 12px auto 22px;
  padding: 0 14px;
  border: 0;
  border-radius: 0;
  background: transparent;
  backdrop-filter: none;
  color: rgba(240, 223, 189, 0.62);
}

/* UI preview variants: course market only */
body[data-ui-variant] .market-groups .grid {
  grid-template-columns: repeat(auto-fill, minmax(236px, 1fr));
  gap: 12px;
}

body[data-ui-variant] .market-groups .course-card {
  min-height: 0;
}

body[data-ui-variant] .market-groups .course-cover {
  min-height: 68px;
  height: 68px;
  margin: -12px -12px 0;
  padding: 10px 12px;
  border-radius: 0 0 10px 10px;
}

body[data-ui-variant] .market-groups .course-cover strong {
  max-width: 100%;
  font-size: 14px;
  line-height: 1.15;
}

body[data-ui-variant] .market-groups .course-cover small {
  max-width: 100%;
  padding: 2px 7px;
  overflow: hidden;
  font-size: 10px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

body[data-ui-variant] .market-groups .cover-bubbles,
body[data-ui-variant] .market-groups .cover-people {
  opacity: 0.55;
  transform: scale(0.72);
  transform-origin: right bottom;
}

body[data-ui-variant] .market-groups .course-card h3 {
  display: -webkit-box;
  overflow: hidden;
  min-height: 36px;
  font-size: 14px;
  line-height: 1.28;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
}

body[data-ui-variant] .market-groups .course-card .muted {
  min-height: 34px;
  font-size: 12px;
  line-height: 1.42;
}

body[data-ui-variant] .market-groups .course-card .tag-row {
  gap: 5px;
}

body[data-ui-variant] .market-groups .course-card .tag {
  min-height: 24px;
  padding: 4px 7px;
  font-size: 11px;
}

body[data-ui-variant] .market-groups .course-card .button-row {
  gap: 6px;
}

body[data-ui-variant] .market-groups .course-card .primary,
body[data-ui-variant] .market-groups .course-card .secondary,
body[data-ui-variant] .market-groups .course-card .ghost {
  min-height: 34px;
  padding: 0 9px;
  border-radius: 9px;
  font-size: 12px;
}

body[data-ui-variant="1"] .market-groups .course-card {
  border-color: rgba(219, 194, 142, 0.24);
  background:
    linear-gradient(145deg, rgba(255, 248, 232, 0.07), rgba(255, 255, 255, 0.015)),
    rgba(20, 20, 23, 0.94);
  box-shadow: 0 18px 54px rgba(0, 0, 0, 0.3), inset 0 1px 0 rgba(255, 248, 232, 0.055);
}

body[data-ui-variant="1"] .market-groups .course-cover {
  background:
    radial-gradient(circle at 80% 18%, rgba(255, 255, 255, 0.28), transparent 24%),
    linear-gradient(135deg, #dcc48f 0%, #a67c42 58%, #1f1d1a 100%);
}

body[data-ui-variant="1"] .market-groups .course-cover small {
  display: none;
}

body[data-ui-variant="1"] .market-groups .course-card:hover {
  border-color: rgba(219, 194, 142, 0.58);
  box-shadow: 0 24px 76px rgba(0, 0, 0, 0.38), 0 0 0 4px rgba(219, 194, 142, 0.055);
}

body[data-ui-variant="2"] .market-groups .grid {
  grid-template-columns: repeat(auto-fill, minmax(290px, 1fr));
}

body[data-ui-variant="2"] .market-groups .course-card {
  display: grid;
  grid-template-columns: 78px minmax(0, 1fr);
  align-items: start;
  gap: 8px 11px;
  border-color: rgba(86, 210, 210, 0.22);
  background:
    linear-gradient(145deg, rgba(86, 210, 210, 0.08), rgba(255, 255, 255, 0.018)),
    rgba(15, 22, 27, 0.94);
  box-shadow: 0 18px 56px rgba(0, 0, 0, 0.28), inset 0 1px 0 rgba(178, 255, 255, 0.06);
}

body[data-ui-variant="2"] .market-groups .course-card > :not(.course-cover) {
  grid-column: 2;
}

body[data-ui-variant="2"] .market-groups .course-cover {
  grid-row: 1 / span 3;
  width: 78px;
  height: 92px;
  min-height: 92px;
  margin: 0;
  padding: 10px;
  border-radius: 10px;
  background:
    radial-gradient(circle at 76% 20%, rgba(255, 255, 255, 0.24), transparent 28%),
    linear-gradient(150deg, #6ee1de 0%, #27849b 52%, #13212a 100%);
}

body[data-ui-variant="2"] .market-groups .course-cover small {
  display: none;
}

body[data-ui-variant="2"] .market-groups .course-cover strong {
  font-size: 13px;
  line-height: 1.18;
}

body[data-ui-variant="2"] .market-groups .course-card h3 {
  min-height: auto;
}

body[data-ui-variant="2"] .market-groups .course-card .muted {
  min-height: 32px;
  -webkit-line-clamp: 2;
}

body[data-ui-variant="2"] .market-groups .course-card:hover {
  border-color: rgba(86, 210, 210, 0.52);
  box-shadow: 0 24px 76px rgba(0, 0, 0, 0.36), 0 0 0 4px rgba(86, 210, 210, 0.055);
}

body[data-ui-variant="3"] .market-groups .grid {
  grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
}

body[data-ui-variant="3"] .market-groups .course-card {
  border-color: rgba(234, 226, 205, 0.2);
  background:
    linear-gradient(145deg, rgba(234, 226, 205, 0.075), rgba(255, 255, 255, 0.018)),
    rgba(22, 23, 25, 0.95);
  box-shadow: 0 18px 52px rgba(0, 0, 0, 0.26), inset 0 1px 0 rgba(255, 255, 255, 0.055);
}

body[data-ui-variant="3"] .market-groups .course-cover {
  min-height: 52px;
  height: 52px;
  margin: -12px -12px 0;
  padding: 9px 12px;
  border-radius: 0;
  background:
    linear-gradient(90deg, rgba(230, 215, 179, 0.95), rgba(150, 117, 74, 0.72)),
    #292723;
}

body[data-ui-variant="3"] .market-groups .course-cover::before,
body[data-ui-variant="3"] .market-groups .course-cover::after,
body[data-ui-variant="3"] .market-groups .cover-bubbles,
body[data-ui-variant="3"] .market-groups .cover-people {
  display: none;
}

body[data-ui-variant="3"] .market-groups .course-cover strong {
  font-size: 13px;
  line-height: 1.1;
}

body[data-ui-variant="3"] .market-groups .course-cover small {
  display: none;
}

body[data-ui-variant="3"] .market-groups .course-card:hover {
  border-color: rgba(234, 226, 205, 0.48);
  box-shadow: 0 24px 72px rgba(0, 0, 0, 0.34), 0 0 0 4px rgba(234, 226, 205, 0.045);
}

@media (max-width: 980px) {
  .sidebar {
    position: static;
    top: auto;
  }

  .sidebar-bottom {
    margin-top: 16px;
    padding-top: 0;
  }

  .site-icp-footer {
    margin-bottom: 18px;
  }
}

@media (max-width: 640px) {
  body[data-ui-variant] .market-groups .grid,
  body[data-ui-variant="2"] .market-groups .grid,
  body[data-ui-variant="3"] .market-groups .grid {
    grid-template-columns: 1fr;
  }

  body[data-ui-variant="2"] .market-groups .course-card {
    grid-template-columns: 72px minmax(0, 1fr);
  }

  body[data-ui-variant="2"] .market-groups .course-cover {
    width: 72px;
    height: 86px;
    min-height: 86px;
  }
}

/* UI preview refresh: keep desktop sidebar usable while main content scrolls */
@media (min-width: 981px) {
  .sidebar {
    position: sticky;
    top: 0;
    height: 100dvh;
    min-height: 0;
    overflow: hidden;
  }

  .brand,
  .sidebar-bottom {
    flex-shrink: 0;
  }

  .nav {
    min-height: 0;
    overflow-y: auto;
    padding-right: 2px;
    scrollbar-width: thin;
  }
}

/* UI preview variants 4-8: new course-market options */
body[data-ui-variant="4"] .market-groups .grid {
  grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
  gap: 14px;
}

body[data-ui-variant="4"] .market-groups .course-card {
  border-color: rgba(221, 226, 232, 0.22);
  background:
    linear-gradient(145deg, rgba(255, 255, 255, 0.08), rgba(255, 255, 255, 0.02)),
    rgba(24, 25, 29, 0.96);
  box-shadow: 0 20px 58px rgba(0, 0, 0, 0.32), inset 0 1px 0 rgba(255, 255, 255, 0.06);
}

body[data-ui-variant="4"] .market-groups .course-cover {
  height: 58px;
  min-height: 58px;
  border-radius: 0;
  background:
    linear-gradient(90deg, rgba(233, 237, 242, 0.96), rgba(111, 124, 138, 0.84)),
    #222832;
}

body[data-ui-variant="4"] .market-groups .course-cover::before,
body[data-ui-variant="4"] .market-groups .course-cover::after,
body[data-ui-variant="4"] .market-groups .cover-bubbles,
body[data-ui-variant="4"] .market-groups .cover-people {
  display: none;
}

body[data-ui-variant="4"] .market-groups .course-cover strong {
  color: #16191e;
  font-size: 13px;
}

body[data-ui-variant="4"] .market-groups .course-cover small {
  display: none;
}

body[data-ui-variant="4"] .market-groups .course-card h3 {
  min-height: 34px;
}

body[data-ui-variant="5"] .market-groups .grid {
  grid-template-columns: repeat(auto-fill, minmax(340px, 1fr));
  gap: 12px;
}

body[data-ui-variant="5"] .market-groups .course-card {
  display: grid;
  grid-template-columns: 64px minmax(0, 1fr) auto;
  align-items: center;
  gap: 8px 12px;
  border-color: rgba(110, 231, 183, 0.22);
  background:
    linear-gradient(145deg, rgba(110, 231, 183, 0.07), rgba(255, 255, 255, 0.014)),
    rgba(14, 21, 22, 0.96);
  box-shadow: 0 18px 52px rgba(0, 0, 0, 0.26), inset 0 1px 0 rgba(196, 255, 230, 0.045);
}

body[data-ui-variant="5"] .market-groups .course-card > :not(.course-cover) {
  grid-column: 2 / 4;
}

body[data-ui-variant="5"] .market-groups .course-cover {
  grid-row: 1 / span 4;
  width: 64px;
  height: 64px;
  min-height: 64px;
  margin: 0;
  padding: 8px;
  border-radius: 12px;
  background:
    radial-gradient(circle at 24% 24%, rgba(255, 255, 255, 0.28), transparent 28%),
    linear-gradient(145deg, #69f0b4, #1d8b76 56%, #12312d);
}

body[data-ui-variant="5"] .market-groups .course-cover small,
body[data-ui-variant="5"] .market-groups .cover-bubbles,
body[data-ui-variant="5"] .market-groups .cover-people {
  display: none;
}

body[data-ui-variant="5"] .market-groups .course-cover strong {
  color: #061613;
  font-size: 11px;
  line-height: 1.18;
}

body[data-ui-variant="5"] .market-groups .course-card h3,
body[data-ui-variant="5"] .market-groups .course-card .muted {
  min-height: auto;
}

body[data-ui-variant="5"] .market-groups .course-card .button-row {
  justify-content: flex-start;
}

body[data-ui-variant="6"] .market-groups .grid {
  grid-template-columns: repeat(auto-fill, minmax(246px, 1fr));
  gap: 14px;
}

body[data-ui-variant="6"] .market-groups .course-card {
  border-color: rgba(245, 188, 112, 0.28);
  background:
    linear-gradient(180deg, rgba(245, 188, 112, 0.075), rgba(255, 255, 255, 0.012)),
    rgba(27, 22, 19, 0.96);
  box-shadow: 0 20px 62px rgba(0, 0, 0, 0.32), inset 0 1px 0 rgba(255, 220, 170, 0.055);
}

body[data-ui-variant="6"] .market-groups .course-cover {
  height: 74px;
  min-height: 74px;
  border-radius: 0 0 18px 18px;
  background:
    radial-gradient(circle at 84% 18%, rgba(255, 255, 255, 0.24), transparent 22%),
    linear-gradient(135deg, #f7c77b 0%, #d48742 48%, #3b2518 100%);
}

body[data-ui-variant="6"] .market-groups .course-cover strong {
  color: #1a1008;
  font-size: 14px;
}

body[data-ui-variant="6"] .market-groups .course-cover small {
  display: none;
}

body[data-ui-variant="6"] .market-groups .course-card .primary,
body[data-ui-variant="6"] .market-groups .course-card .ghost {
  background: linear-gradient(135deg, #f0bc72, #c87938);
  color: #19110a;
}

body[data-ui-variant="7"] .market-groups .grid {
  grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
  gap: 12px;
}

body[data-ui-variant="7"] .market-groups .course-card {
  border-color: rgba(116, 185, 255, 0.26);
  background:
    linear-gradient(145deg, rgba(116, 185, 255, 0.09), rgba(255, 255, 255, 0.025)),
    rgba(17, 23, 34, 0.88);
  backdrop-filter: blur(16px);
  box-shadow: 0 22px 70px rgba(0, 0, 0, 0.34), inset 0 1px 0 rgba(215, 236, 255, 0.07);
}

body[data-ui-variant="7"] .market-groups .course-cover {
  height: 62px;
  min-height: 62px;
  background:
    linear-gradient(120deg, rgba(139, 217, 255, 0.94), rgba(79, 140, 214, 0.8) 54%, rgba(22, 36, 56, 0.92)),
    #152438;
}

body[data-ui-variant="7"] .market-groups .course-cover strong {
  color: #071522;
  font-size: 13px;
}

body[data-ui-variant="7"] .market-groups .course-cover small {
  display: none;
}

body[data-ui-variant="7"] .market-groups .course-card:hover {
  border-color: rgba(116, 185, 255, 0.58);
  box-shadow: 0 26px 84px rgba(0, 0, 0, 0.38), 0 0 0 4px rgba(116, 185, 255, 0.055);
}

body[data-ui-variant="8"] .market-groups .grid {
  grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
  gap: 10px;
}

body[data-ui-variant="8"] .market-groups .course-card {
  display: grid;
  grid-template-columns: 5px minmax(0, 1fr);
  gap: 8px 12px;
  padding-left: 0;
  border-color: rgba(255, 255, 255, 0.16);
  background:
    linear-gradient(145deg, rgba(248, 250, 252, 0.1), rgba(255, 255, 255, 0.024)),
    rgba(18, 18, 20, 0.96);
  box-shadow: 0 18px 54px rgba(0, 0, 0, 0.28), inset 0 1px 0 rgba(255, 255, 255, 0.055);
}

body[data-ui-variant="8"] .market-groups .course-card::before {
  grid-row: 1 / span 4;
  width: 5px;
  min-height: 100%;
  border-radius: 8px 0 0 8px;
  background: linear-gradient(180deg, #f8d27a, #6ee7b7 52%, #7dd3fc);
  content: "";
}

body[data-ui-variant="8"] .market-groups .course-card > :not(.course-cover) {
  grid-column: 2;
}

body[data-ui-variant="8"] .market-groups .course-cover {
  display: none;
}

body[data-ui-variant="8"] .market-groups .course-card h3 {
  min-height: auto;
  font-size: 15px;
}

body[data-ui-variant="8"] .market-groups .course-card .muted {
  min-height: 32px;
}

@media (max-width: 640px) {
  .placement-prompt,
  .weekly-report-head,
  .placement-actions {
    align-items: stretch;
    flex-direction: column;
  }

  .placement-hero,
  .placement-breakdown,
  .weekly-report-grid,
  .recommendation-grid {
    grid-template-columns: 1fr;
  }

  .placement-meter {
    min-height: 86px;
  }

  .placement-question-head {
    align-items: flex-start;
    flex-direction: column;
    gap: 4px;
  }

  .placement-question h3 {
    font-size: 16px;
  }

  .weekly-report-head > strong {
    width: 100%;
    height: 58px;
    flex-basis: auto;
  }

  body[data-ui-variant="4"] .market-groups .grid,
  body[data-ui-variant="5"] .market-groups .grid,
  body[data-ui-variant="6"] .market-groups .grid,
  body[data-ui-variant="7"] .market-groups .grid,
  body[data-ui-variant="8"] .market-groups .grid {
    grid-template-columns: 1fr;
  }

  body[data-ui-variant="5"] .market-groups .course-card {
    grid-template-columns: 58px minmax(0, 1fr);
  }

  body[data-ui-variant="5"] .market-groups .course-card > :not(.course-cover) {
    grid-column: 2;
  }

  body[data-ui-variant="5"] .market-groups .course-cover {
    width: 58px;
    height: 72px;
    min-height: 72px;
  }
}

/* Chapter completion must not show any legacy visual celebration strips. */
body.is-chapter-complete > :not(#app):not(script):not(style):not(link):not(meta) {
  display: none !important;
  visibility: hidden !important;
  opacity: 0 !important;
  animation: none !important;
}

body.is-chapter-complete .practice-shell {
  position: fixed !important;
  inset: 0 !important;
  z-index: 9999 !important;
  overflow: hidden !important;
}

body.is-chapter-complete .practice-shell > :not(.chapter-complete),
body.is-chapter-complete .practice-topbar,
body.is-chapter-complete .dictation-stage,
body.is-chapter-complete .practice-controls,
body.is-chapter-complete .status-strip,
body.is-chapter-complete .grid-bg,
body.is-chapter-complete .dictation-card,
body.is-chapter-complete .blank-row,
body.is-chapter-complete .answer-analysis,
body.is-chapter-complete .correct-review {
  content: none !important;
  display: none !important;
  visibility: hidden !important;
  opacity: 0 !important;
  width: 0 !important;
  height: 0 !important;
  overflow: hidden !important;
  animation: none !important;
  transform: none !important;
  box-shadow: none !important;
  filter: none !important;
}

body.is-chapter-complete .practice-shell *,
body.is-chapter-complete .practice-shell *::before,
body.is-chapter-complete .practice-shell *::after {
  animation: none !important;
  transition: none !important;
}

body.is-chapter-complete .chapter-complete {
  position: fixed !important;
  inset: 0 !important;
  z-index: 10000 !important;
  display: grid !important;
  visibility: visible !important;
  opacity: 1 !important;
  width: auto !important;
  height: auto !important;
  overflow: hidden !important;
  background: rgba(2, 6, 12, 0.9) !important;
  box-shadow: none !important;
  filter: none !important;
  transform: none !important;
  isolation: isolate !important;
}

body.is-chapter-complete .chapter-complete::before,
body.is-chapter-complete .chapter-complete::after,
body.is-chapter-complete .chapter-complete > :not(.chapter-complete-panel),
body.is-chapter-complete .correct-review,
body.is-chapter-complete .correct-review *,
body.is-chapter-complete .answer-analysis,
body.is-chapter-complete .answer-analysis *,
body.is-chapter-complete .course-start-icon,
body.is-chapter-complete .course-start-icon span,
body.is-chapter-complete .course-start-icon *,
body.is-chapter-complete [class*="firework"],
body.is-chapter-complete [class*="firework"] *,
body.is-chapter-complete [class*="confetti"],
body.is-chapter-complete [class*="confetti"] *,
body.is-chapter-complete [class*="spark"],
body.is-chapter-complete [class*="spark"] *,
body.is-chapter-complete [class*="pyro"],
body.is-chapter-complete [class*="pyro"] *,
body.is-chapter-complete [class*="particle"],
body.is-chapter-complete [class*="particle"] *,
body.is-chapter-complete [class*="celebrat"],
body.is-chapter-complete [class*="celebrat"] *,
body.is-chapter-complete [class*="comet"],
body.is-chapter-complete [class*="comet"] *,
body.is-chapter-complete [class*="burst"],
body.is-chapter-complete [class*="burst"] *,
body.is-chapter-complete [class*="streak"],
body.is-chapter-complete [class*="streak"] *,
body.is-chapter-complete [class*="strip"],
body.is-chapter-complete [class*="strip"] *,
body.is-chapter-complete [class*="ribbon"],
body.is-chapter-complete [class*="ribbon"] *,
body.is-chapter-complete [class*="launcher"],
body.is-chapter-complete [class*="launcher"] *,
body.is-chapter-complete [class*="trail"],
body.is-chapter-complete [class*="trail"] *,
body.is-chapter-complete [class*="meteor"],
body.is-chapter-complete [class*="meteor"] *,
body.is-chapter-complete [class*="flare"],
body.is-chapter-complete [class*="flare"] *,
body.is-chapter-complete [class*="ray"],
body.is-chapter-complete [class*="ray"] *,
body.is-chapter-complete [class*="shard"],
body.is-chapter-complete [class*="shard"] *,
body.is-chapter-complete [class*="sprinkle"],
body.is-chapter-complete [class*="sprinkle"] *,
body.is-chapter-complete [class*="shoot"],
body.is-chapter-complete [class*="shoot"] *,
body.is-chapter-complete [class*="beam"],
body.is-chapter-complete [class*="beam"] *,
body.is-chapter-complete [class*="bar"],
body.is-chapter-complete [class*="bar"] *,
body.is-chapter-complete [class*="line"],
body.is-chapter-complete [class*="line"] *,
body.is-chapter-complete [class*="dot"],
body.is-chapter-complete [class*="dot"] *,
body.is-chapter-complete [class*="star"],
body.is-chapter-complete [class*="star"] * {
  content: none !important;
  display: none !important;
  visibility: hidden !important;
  opacity: 0 !important;
  width: 0 !important;
  height: 0 !important;
  overflow: hidden !important;
  animation: none !important;
  transform: none !important;
  box-shadow: none !important;
  filter: none !important;
}

body.is-chapter-complete .chapter-complete-panel,
body.is-chapter-complete .chapter-complete-panel * {
  visibility: visible !important;
  opacity: 1 !important;
  animation: none !important;
  transition: none !important;
}

body.is-chapter-complete .chapter-complete-panel {
  display: block !important;
  position: relative !important;
  z-index: 10001 !important;
}

body.is-chapter-complete .chapter-actions {
  display: flex !important;
}

body.is-chapter-complete .chapter-actions button {
  display: inline-flex !important;
}

body.is-chapter-complete .chapter-complete-panel [class*="firework"],
body.is-chapter-complete .chapter-complete-panel [class*="firework"] *,
body.is-chapter-complete .chapter-complete-panel [class*="confetti"],
body.is-chapter-complete .chapter-complete-panel [class*="confetti"] *,
body.is-chapter-complete .chapter-complete-panel [class*="spark"],
body.is-chapter-complete .chapter-complete-panel [class*="spark"] *,
body.is-chapter-complete .chapter-complete-panel [class*="pyro"],
body.is-chapter-complete .chapter-complete-panel [class*="pyro"] *,
body.is-chapter-complete .chapter-complete-panel [class*="particle"],
body.is-chapter-complete .chapter-complete-panel [class*="particle"] *,
body.is-chapter-complete .chapter-complete-panel [class*="celebrat"],
body.is-chapter-complete .chapter-complete-panel [class*="celebrat"] *,
body.is-chapter-complete .chapter-complete-panel [class*="comet"],
body.is-chapter-complete .chapter-complete-panel [class*="comet"] *,
body.is-chapter-complete .chapter-complete-panel [class*="burst"],
body.is-chapter-complete .chapter-complete-panel [class*="burst"] *,
body.is-chapter-complete .chapter-complete-panel [class*="streak"],
body.is-chapter-complete .chapter-complete-panel [class*="streak"] *,
body.is-chapter-complete .chapter-complete-panel [class*="strip"],
body.is-chapter-complete .chapter-complete-panel [class*="strip"] *,
body.is-chapter-complete .chapter-complete-panel [class*="ribbon"],
body.is-chapter-complete .chapter-complete-panel [class*="ribbon"] *,
body.is-chapter-complete .chapter-complete-panel [class*="launcher"],
body.is-chapter-complete .chapter-complete-panel [class*="launcher"] *,
body.is-chapter-complete .chapter-complete-panel [class*="trail"],
body.is-chapter-complete .chapter-complete-panel [class*="trail"] *,
body.is-chapter-complete .chapter-complete-panel [class*="meteor"],
body.is-chapter-complete .chapter-complete-panel [class*="meteor"] *,
body.is-chapter-complete .chapter-complete-panel [class*="flare"],
body.is-chapter-complete .chapter-complete-panel [class*="flare"] *,
body.is-chapter-complete .chapter-complete-panel [class*="ray"],
body.is-chapter-complete .chapter-complete-panel [class*="ray"] *,
body.is-chapter-complete .chapter-complete-panel [class*="shard"],
body.is-chapter-complete .chapter-complete-panel [class*="shard"] *,
body.is-chapter-complete .chapter-complete-panel [class*="sprinkle"],
body.is-chapter-complete .chapter-complete-panel [class*="sprinkle"] *,
body.is-chapter-complete .chapter-complete-panel [class*="shoot"],
body.is-chapter-complete .chapter-complete-panel [class*="shoot"] *,
body.is-chapter-complete .chapter-complete-panel [class*="beam"],
body.is-chapter-complete .chapter-complete-panel [class*="beam"] *,
body.is-chapter-complete .chapter-complete-panel [class*="bar"],
body.is-chapter-complete .chapter-complete-panel [class*="bar"] *,
body.is-chapter-complete .chapter-complete-panel [class*="line"],
body.is-chapter-complete .chapter-complete-panel [class*="line"] *,
body.is-chapter-complete .chapter-complete-panel [class*="dot"],
body.is-chapter-complete .chapter-complete-panel [class*="dot"] *,
body.is-chapter-complete .chapter-complete-panel [class*="star"],
body.is-chapter-complete .chapter-complete-panel [class*="star"] * {
  content: none !important;
  display: none !important;
  visibility: hidden !important;
  opacity: 0 !important;
  width: 0 !important;
  height: 0 !important;
  overflow: hidden !important;
  animation: none !important;
  transform: none !important;
  box-shadow: none !important;
  filter: none !important;
}

body.is-chapter-complete .chapter-complete > .chapter-complete-fx,
body.is-chapter-complete .chapter-complete > .chapter-complete-fx *,
.chapter-complete > .chapter-complete-fx,
.chapter-complete > .chapter-complete-fx * {
  content: normal !important;
  display: block !important;
  visibility: visible !important;
  opacity: 1 !important;
  overflow: visible !important;
  transform: none;
}

.chapter-complete-fx {
  position: absolute !important;
  inset: 0 !important;
  z-index: 1 !important;
  width: auto !important;
  height: auto !important;
  overflow: hidden !important;
  pointer-events: none !important;
  contain: layout paint style;
}

body.is-chapter-complete .chapter-complete > .chapter-complete-fx,
body.is-chapter-complete .chapter-complete > .chapter-complete-fx .fx-pop {
  width: auto !important;
  height: auto !important;
}

.chapter-complete-fx .fx-pop {
  position: absolute !important;
  inset: 0 !important;
  z-index: 1 !important;
  width: auto !important;
  height: auto !important;
  overflow: hidden !important;
  pointer-events: none !important;
  transform: translate(var(--pyro-layer-x, 0), var(--pyro-layer-y, 0)) !important;
  contain: layout paint style;
}

.chapter-complete-fx .fx-layer-1 {
  --pyro-layer-x: -42vw;
  --pyro-layer-y: -28vh;
  --pyro-layer-delay: 0ms;
}

.chapter-complete-fx .fx-layer-2 {
  --pyro-layer-x: -8vw;
  --pyro-layer-y: -22vh;
  --pyro-layer-delay: 120ms;
}

.chapter-complete-fx .fx-layer-3 {
  --pyro-layer-x: 33vw;
  --pyro-layer-y: -16vh;
  --pyro-layer-delay: 240ms;
}

.chapter-complete-fx .fx-layer-4 {
  --pyro-layer-x: 18vw;
  --pyro-layer-y: 23vh;
  --pyro-layer-delay: 980ms;
}

.chapter-complete-fx .fx-layer-5 {
  --pyro-layer-x: -35vw;
  --pyro-layer-y: 18vh;
  --pyro-layer-delay: 1120ms;
}

.chapter-complete-fx .fx-layer-6 {
  --pyro-layer-x: 43vw;
  --pyro-layer-y: 7vh;
  --pyro-layer-delay: 1260ms;
}

.chapter-complete-fx .fx-layer-7 {
  --pyro-layer-x: -20vw;
  --pyro-layer-y: -6vh;
  --pyro-layer-delay: 1980ms;
}

.chapter-complete-fx .fx-layer-8 {
  --pyro-layer-x: 5vw;
  --pyro-layer-y: 35vh;
  --pyro-layer-delay: 2140ms;
}

.chapter-complete-fx .fx-layer-9 {
  --pyro-layer-x: -47vw;
  --pyro-layer-y: 2vh;
  --pyro-layer-delay: 2310ms;
}

.chapter-complete-fx .fx-layer-10 {
  --pyro-layer-x: 24vw;
  --pyro-layer-y: -32vh;
  --pyro-layer-delay: 3040ms;
}

.chapter-complete-fx .fx-layer-11 {
  --pyro-layer-x: -30vw;
  --pyro-layer-y: 34vh;
  --pyro-layer-delay: 3220ms;
}

.chapter-complete-fx .fx-layer-12 {
  --pyro-layer-x: 48vw;
  --pyro-layer-y: 31vh;
  --pyro-layer-delay: 3410ms;
}

.chapter-complete-fx .fx-layer-13 {
  --pyro-layer-x: -5vw;
  --pyro-layer-y: 8vh;
  --pyro-layer-delay: 4140ms;
}

.chapter-complete-fx .fx-layer-14 {
  --pyro-layer-x: -48vw;
  --pyro-layer-y: -12vh;
  --pyro-layer-delay: 4350ms;
}

.chapter-complete-fx .fx-layer-15 {
  --pyro-layer-x: 38vw;
  --pyro-layer-y: -35vh;
  --pyro-layer-delay: 4580ms;
}

.chapter-complete-fx .fx-pop {
  --pyro-box-shadow-start: 0 0 #fff, 0 0 #fff, 0 0 #fff, 0 0 #fff, 0 0 #fff, 0 0 #fff, 0 0 #fff, 0 0 #fff, 0 0 #fff, 0 0 #fff, 0 0 #fff, 0 0 #fff, 0 0 #fff, 0 0 #fff, 0 0 #fff, 0 0 #fff, 0 0 #fff, 0 0 #fff, 0 0 #fff, 0 0 #fff, 0 0 #fff, 0 0 #fff, 0 0 #fff, 0 0 #fff, 0 0 #fff, 0 0 #fff, 0 0 #fff, 0 0 #fff, 0 0 #fff, 0 0 #fff, 0 0 #fff;
}

.chapter-complete-fx .fx-pattern-1 {
  --pyro-box-shadow-end: 84px -518px hsl(77, 100%, 50%), 150px -216px hsl(29, 100%, 50%), 212px -85px hsl(264, 100%, 50%), -281px 96px hsl(85, 100%, 50%), -33px -122px hsl(203, 100%, 50%), -289px -557px hsl(190, 100%, 50%), -159px -355px hsl(110, 100%, 50%), 294px -361px hsl(11, 100%, 50%), 18px -215px hsl(328, 100%, 50%), -31px -489px hsl(23, 100%, 50%), 23px -364px hsl(233, 100%, 50%), -85px -49px hsl(107, 100%, 50%), -313px 110px hsl(116, 100%, 50%), -185px -255px hsl(218, 100%, 50%), 162px 72px hsl(223, 100%, 50%), -155px -240px hsl(44, 100%, 50%), -29px 85px hsl(235, 100%, 50%), 234px -302px hsl(313, 100%, 50%), 50px -451px hsl(200, 100%, 50%), 55px 12px hsl(102, 100%, 50%), 211px -498px hsl(256, 100%, 50%), 307px -298px hsl(66, 100%, 50%), 141px -327px hsl(171, 100%, 50%), 71px -453px hsl(166, 100%, 50%), -337px -371px hsl(313, 100%, 50%), 50px -119px hsl(129, 100%, 50%), 227px -71px hsl(261, 100%, 50%), 49px -331px hsl(4, 100%, 50%), -216px -38px hsl(156, 100%, 50%), -337px -246px hsl(78, 100%, 50%), -38px 102px hsl(202, 100%, 50%);
}

.chapter-complete-fx .fx-pattern-2 {
  --pyro-box-shadow-end: 84px -456px hsl(324, 100%, 50%), 175px -443px hsl(299, 100%, 50%), -175px -142px hsl(87, 100%, 50%), -242px -275px hsl(331, 100%, 50%), -49px -155px hsl(285, 100%, 50%), 28px -453px hsl(196, 100%, 50%), 44px -432px hsl(358, 100%, 50%), -3px 94px hsl(37, 100%, 50%), 98px 85px hsl(184, 100%, 50%), -190px 62px hsl(245, 100%, 50%), -257px -258px hsl(220, 100%, 50%), 327px -459px hsl(80, 100%, 50%), 269px -11px hsl(80, 100%, 50%), -85px -437px hsl(178, 100%, 50%), -137px -229px hsl(80, 100%, 50%), -156px 30px hsl(311, 100%, 50%), 174px -354px hsl(304, 100%, 50%), 139px -268px hsl(234, 100%, 50%), -91px -171px hsl(188, 100%, 50%), -241px -460px hsl(334, 100%, 50%), -29px -118px hsl(256, 100%, 50%), -267px -77px hsl(303, 100%, 50%), -45px -171px hsl(90, 100%, 50%), -153px 6px hsl(352, 100%, 50%), -97px 82px hsl(48, 100%, 50%), -245px -482px hsl(77, 100%, 50%), 232px -188px hsl(175, 100%, 50%), 103px -245px hsl(230, 100%, 50%), 49px -78px hsl(70, 100%, 50%), 164px -514px hsl(322, 100%, 50%), -328px -548px hsl(228, 100%, 50%);
}

.chapter-complete-fx .fx-pattern-3 {
  --pyro-box-shadow-end: 84px -394px hsl(210, 100%, 50%), 200px 10px hsl(208, 100%, 50%), 118px -199px hsl(270, 100%, 50%), -203px 33px hsl(218, 100%, 50%), -65px -188px hsl(7, 100%, 50%), -335px -349px hsl(201, 100%, 50%), 247px -509px hsl(247, 100%, 50%), -300px -130px hsl(62, 100%, 50%), 178px -294px hsl(40, 100%, 50%), 332px -67px hsl(108, 100%, 50%), 142px -153px hsl(207, 100%, 50%), 60px -189px hsl(52, 100%, 50%), 172px -132px hsl(43, 100%, 50%), 14px 61px hsl(138, 100%, 50%), 243px -531px hsl(298, 100%, 50%), -157px -380px hsl(218, 100%, 50%), -303px -114px hsl(13, 100%, 50%), 44px -233px hsl(156, 100%, 50%), -232px 108px hsl(175, 100%, 50%), 143px -252px hsl(207, 100%, 50%), -269px -418px hsl(256, 100%, 50%), -162px -536px hsl(180, 100%, 50%), -231px -15px hsl(8, 100%, 50%), 303px -215px hsl(177, 100%, 50%), 142px -146px hsl(143, 100%, 50%), 140px -166px hsl(25, 100%, 50%), 237px -305px hsl(89, 100%, 50%), 157px -160px hsl(97, 100%, 50%), 314px -118px hsl(344, 100%, 50%), -15px -101px hsl(205, 100%, 50%), 62px -518px hsl(254, 100%, 50%);
}

.chapter-complete-fx .fx-pattern-4 {
  --pyro-box-shadow-end: 85px -333px hsl(96, 100%, 50%), 225px -216px hsl(117, 100%, 50%), -269px -256px hsl(93, 100%, 50%), -164px -338px hsl(105, 100%, 50%), -80px -221px hsl(89, 100%, 50%), -18px -245px hsl(207, 100%, 50%), -230px 94px hsl(136, 100%, 50%), 82px -354px hsl(88, 100%, 50%), 258px 6px hsl(255, 100%, 50%), 173px -197px hsl(330, 100%, 50%), -138px -47px hsl(194, 100%, 50%), -208px 82px hsl(24, 100%, 50%), 74px -254px hsl(7, 100%, 50%), 114px -121px hsl(98, 100%, 50%), -56px -152px hsl(155, 100%, 50%), -157px -110px hsl(125, 100%, 50%), -101px -553px hsl(83, 100%, 50%), -52px -199px hsl(77, 100%, 50%), 307px -292px hsl(163, 100%, 50%), -153px -45px hsl(79, 100%, 50%), 171px -39px hsl(255, 100%, 50%), -56px -316px hsl(57, 100%, 50%), 263px -539px hsl(287, 100%, 50%), 79px -436px hsl(3, 100%, 50%), -298px -374px hsl(239, 100%, 50%), -155px -530px hsl(333, 100%, 50%), 243px -422px hsl(4, 100%, 50%), 210px -74px hsl(323, 100%, 50%), -101px -158px hsl(257, 100%, 50%), -194px -368px hsl(88, 100%, 50%), -228px -488px hsl(281, 100%, 50%);
}

.chapter-complete-fx .fx-pattern-5 {
  --pyro-box-shadow-end: 85px -271px hsl(343, 100%, 50%), 251px -443px hsl(26, 100%, 50%), 24px -313px hsl(276, 100%, 50%), -125px -30px hsl(351, 100%, 50%), -96px -253px hsl(172, 100%, 50%), 299px -141px hsl(212, 100%, 50%), -27px 17px hsl(25, 100%, 50%), -215px 102px hsl(114, 100%, 50%), 338px -373px hsl(111, 100%, 50%), 15px -326px hsl(192, 100%, 50%), 261px 58px hsl(180, 100%, 50%), 204px -328px hsl(356, 100%, 50%), -23px -375px hsl(330, 100%, 50%), 214px -303px hsl(59, 100%, 50%), 324px -454px hsl(13, 100%, 50%), -158px -520px hsl(32, 100%, 50%), 102px -312px hsl(152, 100%, 50%), -147px -165px hsl(359, 100%, 50%), 166px -13px hsl(150, 100%, 50%), 231px -517px hsl(311, 100%, 50%), -69px -339px hsl(255, 100%, 50%), 50px -95px hsl(294, 100%, 50%), 78px -383px hsl(205, 100%, 50%), -144px 23px hsl(188, 100%, 50%), -59px 79px hsl(334, 100%, 50%), 229px -213px hsl(281, 100%, 50%), 248px -539px hsl(278, 100%, 50%), 264px 11px hsl(189, 100%, 50%), 164px -198px hsl(171, 100%, 50%), 307px 44px hsl(332, 100%, 50%), 162px -458px hsl(307, 100%, 50%);
}

.chapter-complete-fx .fx-pop > .before,
.chapter-complete-fx .fx-pop > .after {
  position: absolute !important;
  top: 58% !important;
  left: 50% !important;
  width: 7px !important;
  height: 7px !important;
  border-radius: 50% !important;
  filter: drop-shadow(0 0 8px rgba(255, 255, 255, 0.82)) !important;
  box-shadow: var(--pyro-box-shadow-start);
  animation:
    1.95s chapter-firework-bang ease-out 2 backwards,
    3.2s chapter-firework-gravity ease-in 2 backwards !important;
  animation-delay:
    var(--pyro-layer-delay, 0ms),
    var(--pyro-layer-delay, 0ms) !important;
}

.chapter-complete-fx .fx-pop > .after {
  animation-delay:
    calc(var(--pyro-layer-delay, 0ms) + 720ms),
    calc(var(--pyro-layer-delay, 0ms) + 720ms) !important;
  animation-duration: 2.05s, 3.2s !important;
  animation-iteration-count: 1, 1 !important;
}

@keyframes chapter-firework-bang {
  to {
    box-shadow: var(--pyro-box-shadow-end);
  }
}

@keyframes chapter-firework-gravity {
  to {
    transform: translateY(200px);
    opacity: 0;
  }
}

@media (prefers-reduced-motion: reduce) {
  .chapter-complete-fx .fx-pop > .before,
  .chapter-complete-fx .fx-pop > .after {
    animation: none !important;
  }
}

/* 2026-08-10 selected visual system: obsidian gold workspace */
:root {
  color-scheme: dark;
  --bg: #08080a;
  --panel: #151517;
  --panel-strong: #1d1b1d;
  --ink: #f7eddc;
  --muted: #a69e92;
  --line: rgba(218, 191, 129, 0.18);
  --primary: #d9bf7d;
  --accent: #d9bf7d;
  --primary-dark: #a87934;
  --shadow: 0 30px 90px rgba(0, 0, 0, 0.38);
}

body:not(.is-chapter-complete) {
  background:
    radial-gradient(circle at 76% 18%, rgba(204, 177, 119, 0.14), transparent 32%),
    linear-gradient(135deg, #08080a, #121114 58%, #070708);
  color: var(--ink);
}

body:not(.is-chapter-complete)::before {
  background:
    radial-gradient(circle at 70% 0%, rgba(218, 191, 129, 0.13), transparent 30%),
    radial-gradient(circle at 18% 96%, rgba(81, 67, 42, 0.22), transparent 34%);
  opacity: 1;
}

.app-shell,
.main,
.main-inner,
.auth-shell,
.auth-layout {
  background: transparent;
  color: var(--ink);
}

.sidebar {
  background: linear-gradient(180deg, #121214, #080809) !important;
  border-right: 1px solid rgba(218, 191, 129, 0.14);
  box-shadow: 18px 0 60px rgba(0, 0, 0, 0.22);
}

.brand,
.sidebar-bottom,
.sidebar-legal-links button {
  color: var(--ink);
}

.nav-button {
  color: var(--muted);
}

.nav-button .nav-icon {
  background: rgba(218, 191, 129, 0.08);
  color: var(--primary);
}

.nav-button.active,
.nav-button:hover {
  color: var(--ink);
  background: linear-gradient(135deg, rgba(218, 191, 129, 0.18), rgba(255, 255, 255, 0.04));
  border-color: rgba(218, 191, 129, 0.36);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.08),
    0 18px 45px rgba(0, 0, 0, 0.22);
}

.card,
.course-card,
.stat-card,
.section-panel,
.review-panel,
.word-card,
.practice-panel,
.membership-card,
.membership-status,
.sentence-breakdown-card,
.payment-dialog,
.payment-dialog-left,
.payment-dialog-right,
.profile-panel,
.profile-edit-panel,
.delete-account-panel,
.partner-panel,
.auth-card,
.auth-bind-card,
.legal-modal {
  background: linear-gradient(145deg, rgba(255, 255, 255, 0.075), rgba(255, 255, 255, 0.028));
  border: 1px solid rgba(218, 191, 129, 0.18);
  box-shadow: 0 30px 90px rgba(0, 0, 0, 0.34);
  color: var(--ink);
}

h1,
h2,
h3,
.page-title,
.section-title,
.membership-card h3,
.payment-dialog-head h2,
.auth-scan h2,
.auth-form h2,
.auth-bind-card h2,
.sentence-breakdown-result > h3,
.profile-panel h2,
.profile-edit-panel h2,
.legal-modal h2 {
  color: var(--ink);
}

.kicker,
.muted,
.subtitle,
.membership-note,
.membership-benefits.rich span,
.auth-copy,
.auth-help,
.auth-scan p,
.auth-bind-card p,
.sentence-breakdown-empty {
  color: var(--muted);
}

.primary,
.membership-button.primary,
.auth-entry-register,
.auth-submit:not(:disabled),
.auth-bind-actions button:last-child,
.payment-dialog-methods button.active,
.auth-send-button:not(:disabled) {
  background: linear-gradient(135deg, #ead394, #b9853e);
  border-color: rgba(255, 225, 156, 0.5);
  color: #11100d;
  box-shadow: 0 16px 38px rgba(185, 133, 62, 0.25);
}

.ghost,
.secondary,
.auth-entry-login,
.auth-back-scan,
.auth-forgot,
.auth-bind-actions button:first-child,
.membership-tabs button,
.payment-dialog-methods button {
  background: rgba(255, 255, 255, 0.035);
  border: 1px solid rgba(218, 191, 129, 0.22);
  color: var(--ink);
}

.membership-tabs button.active,
.auth-mode-tabs button.active,
.auth-mode-tabs button:hover {
  background: linear-gradient(135deg, rgba(218, 191, 129, 0.18), rgba(255, 255, 255, 0.04));
  border-color: rgba(218, 191, 129, 0.38);
  color: var(--ink);
}

input,
textarea,
select,
.auth-field.light input,
.auth-field input,
.sentence-breakdown-field textarea,
.auth-phone-row strong {
  background: rgba(9, 9, 11, 0.72);
  border-color: rgba(218, 191, 129, 0.2);
  color: var(--ink);
}

input::placeholder,
textarea::placeholder {
  color: rgba(166, 158, 146, 0.72);
}

input:focus,
textarea:focus,
select:focus,
.auth-field.light input:focus,
.sentence-breakdown-field textarea:focus {
  border-color: rgba(234, 211, 148, 0.7);
  box-shadow: 0 0 0 4px rgba(218, 191, 129, 0.14);
  outline: none;
}

.auth-visual {
  background:
    radial-gradient(circle at 60% 35%, rgba(218, 191, 129, 0.13), transparent 34%),
    linear-gradient(160deg, #17121d, #2b1b5f 55%, #08080a);
}

.auth-panel {
  color: var(--ink);
}

.auth-qr-box {
  background: #f2f3f7;
  border-color: rgba(218, 191, 129, 0.16);
}

.auth-qr-expired {
  color: #111827;
}

.auth-scan-legal button,
.auth-agree-row button,
.auth-return-link,
.auth-switch button.active {
  color: var(--primary);
}

.auth-mode-tabs {
  border-color: rgba(218, 191, 129, 0.14);
}

.auth-mode-tabs button {
  color: var(--muted);
}

.auth-submit:disabled,
.auth-send-button:disabled {
  background: rgba(255, 255, 255, 0.12);
  border-color: transparent;
  box-shadow: none;
  color: rgba(247, 237, 220, 0.45);
}

.profile-avatar-button {
  top: max(6px, env(safe-area-inset-top));
  right: max(6px, env(safe-area-inset-right));
  background: #050505;
  border-color: rgba(218, 191, 129, 0.32);
  box-shadow: 0 10px 28px rgba(0, 0, 0, 0.28);
}

.profile-panel {
  top: 12px;
  right: 12px;
  font-size: 14px;
}

.profile-panel h2 {
  font-size: 28px;
}

.profile-row,
.profile-row strong,
.profile-value {
  font-size: 14px;
}

.profile-edit-panel,
.delete-account-panel {
  background: linear-gradient(145deg, #171719, #0d0d0f);
  color: var(--ink);
}

.profile-edit-panel input {
  background: rgba(255, 255, 255, 0.06);
  color: var(--ink);
}

.membership-price,
.sentence-breakdown-output h3 {
  color: #ead394;
}

.membership-price span,
.membership-price em {
  color: var(--muted);
}

.sentence-breakdown-output {
  color: var(--ink);
}

.sentence-breakdown-output h3 {
  margin-top: 34px;
}

.sentence-breakdown-output h3:first-child {
  margin-top: 0;
}

.payment-dialog-price {
  color: var(--ink);
}

.payment-dialog-qr {
  background: rgba(255, 255, 255, 0.05);
  border-color: rgba(218, 191, 129, 0.22);
}

.legal-modal {
  background: linear-gradient(145deg, #171719, #0d0d0f);
}

.legal-modal p,
.legal-modal li {
  color: #d7cec0;
}

@media (max-width: 900px) {
  .auth-layout {
    background: linear-gradient(160deg, #17121d, #08080a);
  }

  .auth-panel {
    background: rgba(8, 8, 10, 0.9);
  }

  .profile-panel {
    top: 8px;
    right: 8px;
  }
}

/* 2026-08-11 auth surfaces: complete the selected obsidian-gold treatment */
.auth-shell,
.auth-shell .main,
.auth-shell .main-inner,
.auth-layout,
.auth-panel {
  background:
    radial-gradient(circle at 18% 20%, rgba(218, 191, 129, 0.13), transparent 25%),
    radial-gradient(circle at 88% 12%, rgba(141, 108, 242, 0.12), transparent 28%),
    linear-gradient(135deg, #050506 0%, #121113 58%, #08080a 100%);
  color: var(--ink);
}

.auth-layout {
  grid-template-columns: minmax(360px, 0.86fr) minmax(520px, 1.14fr);
}

.auth-visual {
  background:
    radial-gradient(circle at 52% 48%, rgba(255, 255, 255, 0.12), transparent 34%),
    linear-gradient(155deg, #130f17 0%, #37216f 54%, #070708 100%);
  border-right: 1px solid rgba(218, 191, 129, 0.18);
}

.auth-visual-mark {
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(218, 191, 129, 0.22);
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.28);
}

.auth-figure-head {
  background: #ead5cf;
}

.auth-figure-body {
  background: #fff6ed;
  box-shadow: inset 0 -22px #c95b75;
}

.auth-figure-book {
  background: linear-gradient(90deg, #cf5d77 0 50%, #d9aa52 50%);
}

.auth-panel {
  width: min(650px, calc(100vw - 48px));
}

.auth-scan,
.auth-form,
.auth-bind-card {
  position: relative;
  padding: 34px;
  border: 1px solid rgba(218, 191, 129, 0.16);
  border-radius: 22px;
  background:
    linear-gradient(145deg, rgba(255, 255, 255, 0.07), rgba(255, 255, 255, 0.026)),
    rgba(18, 17, 19, 0.78);
  box-shadow: 0 26px 90px rgba(0, 0, 0, 0.34);
}

.auth-scan h2,
.auth-form h2,
.auth-bind-card h2 {
  color: var(--ink);
  font-size: 27px;
}

.auth-scan h3 {
  color: var(--ink);
  font-size: 20px;
}

.auth-field.light span,
.auth-field span,
.auth-agree-row {
  color: #d9d0c1;
}

.auth-field.light input,
.auth-field input,
.auth-phone-row {
  border-color: rgba(218, 191, 129, 0.24);
  background: rgba(7, 7, 8, 0.76);
  color: var(--ink);
}

.auth-phone-row strong {
  background: rgba(255, 255, 255, 0.05);
  border-color: rgba(218, 191, 129, 0.18);
  color: #ead394;
}

.auth-target-row {
  align-items: stretch;
}

.auth-mode-tabs {
  border-top-color: rgba(218, 191, 129, 0.16);
}

.auth-mode-tabs button {
  border: 1px solid transparent;
  border-radius: 14px;
}

.auth-mode-tabs button.active,
.auth-mode-tabs button:hover {
  background: rgba(218, 191, 129, 0.11);
}

.auth-return-link,
.auth-back-scan,
.auth-forgot,
.auth-scan-legal button,
.auth-agree-row button {
  color: #e2bf74;
}

.auth-notice {
  border-color: rgba(218, 191, 129, 0.2);
  background: rgba(255, 255, 255, 0.05);
}

.auth-notice.success {
  border-color: rgba(79, 219, 137, 0.28);
  background: rgba(79, 219, 137, 0.1);
}

.auth-qr-box {
  position: relative;
  background: #f3f4f8;
  box-shadow: 0 18px 44px rgba(0, 0, 0, 0.26);
}

.auth-qr-box.expired img {
  opacity: 0.18;
}

.auth-qr-expired {
  color: #111827;
  font-size: 15px;
  font-weight: 760;
}

@media (max-width: 900px) {
  .auth-layout {
    grid-template-columns: 1fr;
  }

  .auth-scan,
  .auth-form,
  .auth-bind-card {
    padding: 26px;
  }
}


