/* StarSeed Academy portal: Option D (Storybook Painted) design tokens */
:root {
  --cream: #FFF8EE;
  --white: #FFFFFF;
  --ink: #23201C;
  --amber: #D9862A;
  --amber-deep: #9A5412;
  --amber-soft: #FBE7CC;
  --forest: #3F7D4E;
  --forest-soft: #DCEBDD;
  --sand: #F3EBDD;
  --line: #E8DCC8;
  --field: #D8C9B2;
  --danger-bg: #FBE1DC;
  --danger: #7A1F12;
  --radius: 20px;
  --shadow: 0 4px 16px rgba(35, 32, 28, 0.06);
}
* { box-sizing: border-box; }
body { margin: 0; background: var(--cream); color: var(--ink); font-family: Nunito, system-ui, sans-serif; font-size: 16px; line-height: 1.5; }
a { color: var(--amber-deep); font-weight: 700; }
a:hover { color: var(--ink); }
h1, h2, h3 { font-family: Lora, Georgia, serif; font-weight: 700; line-height: 1.2; margin: 0; }
h1 { font-size: 32px; } h2 { font-size: 22px; }
p { margin: 0; }

.topbar { background: var(--white); border-bottom: 1px solid var(--line); }
.topbar.dark { background: var(--ink); color: var(--cream); }
.topbar-inner { max-width: 1180px; margin: 0 auto; padding: 14px 24px; display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 12px; }
.brand { display: flex; align-items: center; gap: 12px; text-decoration: none; color: inherit; }
.brand img { width: 48px; height: 48px; border-radius: 50%; object-fit: contain; background: var(--white); }
.brand strong { font-family: Lora, serif; font-size: 20px; }
.nav { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; font-size: 15px; }
.nav a { padding: 10px 14px; border-radius: 999px; color: inherit; text-decoration: none; }
.nav a.active { background: var(--forest-soft); color: var(--ink); }
.topbar.dark .nav a.active { background: var(--cream); }
.linklike { background: none; border: 0; padding: 10px 14px; font: inherit; font-weight: 700; color: var(--amber-deep); cursor: pointer; }
.topbar.dark .linklike { color: #F2C46B; }

main.page { max-width: 1180px; margin: 0 auto; padding: 32px 24px 48px; display: flex; flex-direction: column; gap: 24px; }
main.narrow { max-width: 560px; }
.grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(320px, 1fr)); gap: 20px; }
.card { background: var(--white); border-radius: var(--radius); box-shadow: var(--shadow); padding: 24px; display: flex; flex-direction: column; gap: 14px; }
.row { display: flex; justify-content: space-between; align-items: center; gap: 12px; padding: 14px; border-radius: 14px; background: var(--cream); flex-wrap: wrap; }
.muted { font-size: 14px; }
.pill { display: inline-block; padding: 4px 12px; border-radius: 999px; font-size: 13px; font-weight: 700; background: var(--sand); }
.pill.ok { background: var(--forest-soft); } .pill.wait { background: var(--amber-soft); }

.btn { display: inline-flex; align-items: center; justify-content: center; min-height: 48px; padding: 0 22px; border-radius: 999px; border: 2px solid transparent; background: var(--forest); color: var(--white); font: 700 16px Nunito, sans-serif; text-decoration: none; cursor: pointer; }
.btn:hover { color: var(--white); filter: brightness(0.95); }
.btn.secondary { background: var(--white); color: var(--ink); border-color: var(--ink); }
.btn.amber { background: var(--amber); color: var(--ink); }
.actions { display: flex; flex-wrap: wrap; gap: 10px; align-items: center; }

form.stack { display: flex; flex-direction: column; gap: 16px; }
.field { display: flex; flex-direction: column; gap: 6px; }
.field label { font-size: 15px; font-weight: 700; }
.field input, .field select, .field textarea { min-height: 48px; padding: 0 14px; border: 2px solid var(--field); border-radius: 12px; font: 16px Nunito, sans-serif; background: var(--white); color: var(--ink); }
.field textarea { padding: 12px 14px; }
.field input:focus, .field select:focus, .btn:focus-visible, a:focus-visible { outline: 3px solid var(--amber); outline-offset: 2px; }
.check { display: flex; gap: 10px; align-items: flex-start; font-size: 15px; }
.check input { width: 22px; height: 22px; flex: none; margin-top: 1px; }
.help { font-size: 14px; }
.errorlist { list-style: none; margin: 0; padding: 0; color: var(--danger); font-size: 14px; font-weight: 700; }
.alert { padding: 12px 16px; border-radius: 12px; font-weight: 700; }
.alert.error { background: var(--danger-bg); color: var(--danger); }
.alert.success { background: var(--forest-soft); }
.alert.warning, .alert.info { background: var(--amber-soft); }

.signin { min-height: 100vh; display: flex; flex-wrap: wrap; }
.signin-art { flex: 1 1 480px; min-height: 280px; background: url("../img/signin.0b2421da2b4d.jpg") center / cover no-repeat; }
.signin-panel { flex: 1 1 420px; display: flex; align-items: center; justify-content: center; padding: 48px 24px; }
.signin-panel .inner { width: 100%; max-width: 400px; display: flex; flex-direction: column; gap: 20px; }
.logo-lg { width: 96px; height: 96px; border-radius: 50%; object-fit: contain; background: var(--white); }
.note { padding: 14px 16px; border-radius: 12px; background: var(--forest-soft); font-size: 15px; }

.qr { width: 220px; height: 220px; background: var(--white); padding: 10px; border-radius: 12px; }
.qr svg { width: 100%; height: 100%; }
.codes { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; font-family: ui-monospace, monospace; font-size: 18px; }
.codes span { padding: 8px 12px; background: var(--cream); border-radius: 8px; }

table.list { width: 100%; border-collapse: collapse; font-size: 15px; }
table.list th { text-align: left; padding: 10px 8px; border-bottom: 2px solid var(--line); }
table.list td { padding: 12px 8px; border-bottom: 1px solid #F0E6D6; vertical-align: middle; }
.table-wrap { overflow-x: auto; }
footer.site { max-width: 1180px; margin: 0 auto; padding: 0 24px 32px; display: flex; flex-wrap: wrap; gap: 16px; font-size: 14px; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.card .pill, .inner .pill { align-self: flex-start; }
.inner .linklike { padding-left: 0; align-self: flex-start; }
.nav form { margin: 0; }
.grid-2 { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 16px; }
.grid-3 { display: grid; grid-template-columns: repeat(auto-fit, minmax(160px, 1fr)); gap: 16px; }
fieldset.checks { border: 0; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 10px; }
fieldset.checks legend { font-weight: 700; font-size: 15px; margin-bottom: 6px; }
.check .help { display: block; }
.child-text { font-family: Andika, Nunito, sans-serif; font-size: 18px; }
details { background: var(--cream); border-radius: 12px; padding: 12px 16px; }
details summary { font-weight: 700; cursor: pointer; }
details ul { margin: 6px 0 0; padding-left: 20px; }
.linecounts { display: flex; flex-wrap: wrap; gap: 8px 16px; margin-top: 8px; }
.is-off { opacity: 0.45; }
.fieldwrap { display: flex; flex-direction: column; gap: 6px; }
.btn:disabled { opacity: 0.7; cursor: progress; }
.practice-img { max-width: 100%; max-height: 70vh; border-radius: 12px; border: 1px solid var(--line); display: block; }
.session { align-items: flex-start; }
.check input[type=radio] { width: 22px; height: 22px; flex: none; margin-top: 1px; }
.charts { display: grid; grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); gap: 20px; }
.chart-card { margin: 0; display: flex; flex-direction: column; gap: 8px; }
.chart-card figcaption { font-weight: 700; }
svg.chart { width: 100%; height: auto; background: var(--white); }
svg.chart .tick { font: 13px Nunito, sans-serif; fill: #5F5A54; font-variant-numeric: tabular-nums; }
svg.chart .legend { font: 14px Nunito, sans-serif; fill: var(--ink); }
svg.chart .endlabel { font: 700 14px Nunito, sans-serif; fill: var(--ink); }
svg.chart .pt:focus { outline: none; }
svg.chart .pt:focus circle:last-child, svg.chart .pt:hover circle:last-child { r: 6; }
