/* Rhythmic Rhyme — design system
   Extracted verbatim from the Claude Design pages so every screen stays
   visually identical to the approved comps. Tokens first, then components. */

@import url("fonts.css");

:root {
  /* surface */
  --cream: #FBF3E3;
  --paper: #FFFDF6;
  --ink: #1A2440;
  --ink-72: rgba(26, 36, 64, .72);
  --ink-68: rgba(26, 36, 64, .68);
  --ink-62: rgba(26, 36, 64, .62);
  --ink-55: rgba(26, 36, 64, .55);
  --ink-45: rgba(26, 36, 64, .45);
  --ink-35: rgba(26, 36, 64, .35);
  --ink-12: rgba(26, 36, 64, .12);
  --ink-05: rgba(26, 36, 64, .05);

  /* accents */
  --amber: #F7A928;
  --coral: #FF5A36;
  --green: #4CAF7D;
  --blue: #6FA8DC;
  --pink: #F4C7D4;
  --link: #E1780F;
  --link-hover: #B85A05;

  /* status fills */
  --ok-bg: #C9EED9;
  --warn-bg: #FFE3B0;
  --bad-bg: #F6D8D2;
  --idle-bg: #F0E7D4;

  /* type */
  --display: 'Baloo 2', system-ui, sans-serif;
  --body: 'DM Sans', system-ui, sans-serif;

  /* geometry */
  --r-card: 22px;
  --r-field: 12px;
  --r-pill: 999px;
  --pad-x: clamp(20px, 4vw, 52px);
  --shadow-card: 8px 8px 0 var(--ink);
  --shadow-btn: 4px 4px 0 var(--amber);
  --maxw: 1240px;
}

* { box-sizing: border-box; }
html, body { margin: 0; padding: 0; background: var(--cream); }
body {
  font-family: var(--body);
  color: var(--ink);
  -webkit-font-smoothing: antialiased;
}
a { color: var(--link); text-decoration: none; }
a:hover { color: var(--link-hover); }
img { display: block; max-width: 100%; }
button { font-family: var(--body); }
input, select, textarea { font-family: var(--body); }

/* ---------------------------------------------------------------- motion */
@keyframes floatA { 0%,100% { transform: translateY(0) rotate(-5deg); } 50% { transform: translateY(-16px) rotate(-2deg); } }
@keyframes floatB { 0%,100% { transform: translateY(0) rotate(4deg); } 50% { transform: translateY(-12px) rotate(1deg); } }
@keyframes floatC { 0%,100% { transform: translateY(0) rotate(2deg); } 50% { transform: translateY(-19px) rotate(6deg); } }
@keyframes fadeUp { from { opacity: 0; transform: translateY(22px); } to { opacity: 1; transform: none; } }
@keyframes wordPop { from { opacity: 0; transform: translateY(30px) rotate(2deg) scale(.96); } to { opacity: 1; transform: none; } }
@keyframes stickerIn { from { opacity: 0; transform: rotate(-14deg) scale(.5); } to { opacity: 1; transform: rotate(-3deg) scale(1); } }
@keyframes popIn { from { opacity: 0; transform: scale(.8); } to { opacity: 1; transform: none; } }
@keyframes jumpY { 0%,38% { transform: translateY(0); } 58%,82% { transform: translateY(-7.5%); } 100% { transform: translateY(0); } }
@keyframes shadowPump { 0%,38% { transform: translateX(-50%) scaleX(1); opacity: .30; } 60%,82% { transform: translateX(-50%) scaleX(.72); opacity: .16; } 100% { transform: translateX(-50%) scaleX(1); opacity: .30; } }
@keyframes tick { from { transform: translateX(0); } to { transform: translateX(-50%); } }
@keyframes pillWob { 0%,100% { transform: rotate(-6deg) translateY(0); } 50% { transform: rotate(-2deg) translateY(-8px); } }
@keyframes pillWob2 { 0%,100% { transform: rotate(5deg) translateY(0); } 50% { transform: rotate(9deg) translateY(-10px); } }
@keyframes spinSlow { to { transform: rotate(360deg); } }
@keyframes nudge { 0%,100% { transform: translateY(0); } 50% { transform: translateY(8px); } }
@keyframes dashSlide { from { background-position-x: 0; } to { background-position-x: -64px; } }
@keyframes shimmer { 0% { background-position: -300px 0; } 100% { background-position: 300px 0; } }
@keyframes spin { to { transform: rotate(360deg); } }

.fade-up { animation: fadeUp .6s ease-out both; }
.pop-in { animation: popIn .4s ease-out both; }
@media (prefers-reduced-motion: reduce) {
  /* Delay has to go too, not just duration: entrance animations use
     `fill-mode: both`, so a surviving delay would hold the element at its
     opacity-0 start frame — leaving headlines and buttons blank for the first
     second for exactly the people who asked for less motion. */
  *, *::before, *::after {
    animation-duration: .001ms !important;
    animation-delay: 0s !important;
    animation-iteration-count: 1 !important;
    transition-duration: .001ms !important;
  }
}

/* ------------------------------------------------------------------ shell */
.wrap { max-width: var(--maxw); margin: 0 auto; padding: 0 var(--pad-x); }

.nav {
  position: relative; z-index: 50;
  display: flex; align-items: center; justify-content: space-between;
  gap: 20px; padding: 22px var(--pad-x); flex-wrap: wrap;
}
.brand { display: flex; align-items: center; gap: 10px; color: var(--ink); }
.brand:hover { color: var(--ink); }
/* The mark sits on its own cream tile so it keeps working on the dark footer
   and the navy hero without needing a second drawing. */
.brand-mark {
  width: 40px; height: 40px; border-radius: 26%;
  background: var(--cream); border: 2px solid var(--ink);
  display: grid; place-items: center;
  box-shadow: 3px 3px 0 rgba(26, 36, 64, .16);
  flex: none; overflow: hidden;
}
/* object-fit matters: the artwork is 411×448, so setting both dimensions to a
   square percentage would squash it. Contain keeps the aspect and letterboxes. */
.brand-mark img { width: 84%; height: 84%; object-fit: contain; display: block; }
/* buk in ink, kid in amber — the wordmark from the brand sheet. */
.brand-name {
  font-family: var(--display); font-weight: 800; font-size: 25px;
  letter-spacing: -.02em; line-height: 1;
}
.brand-name i { font-style: normal; color: var(--amber); }
.footer .brand-name { color: var(--cream); }
.nav-links {
  display: flex; align-items: center; gap: 26px;
  font-size: 15px; font-weight: 500; color: var(--ink-72); flex-wrap: wrap;
}
.nav-links a { color: inherit; }
.nav-links a:hover { color: var(--ink); }
.nav-links a.active { color: var(--ink); font-weight: 700; }
.nav-toggle {
  display: none; background: none; border: 2px solid var(--ink);
  border-radius: 10px; padding: 7px 10px; cursor: pointer; line-height: 0;
}

/* ------------------------------------------------------------ account menu
   Names whoever the session is about — the CHILD for a parent — and opens the
   things they actually came back for. */
.acct { position: relative; }
.acct-btn {
  display: flex; align-items: center; gap: 9px; cursor: pointer;
  background: var(--paper); border: 2px solid var(--ink); border-radius: var(--r-pill);
  padding: 5px 13px 5px 5px; color: var(--ink); font-family: var(--body);
  box-shadow: 3px 3px 0 rgba(26, 36, 64, .14);
  transition: transform .18s ease, box-shadow .18s ease;
}
.acct-btn:hover { transform: translate(-1px, -2px); box-shadow: 5px 5px 0 rgba(26, 36, 64, .16); }
.acct-dot {
  width: 32px; height: 32px; border-radius: 50%; flex: none;
  background: var(--amber); border: 2px solid var(--ink);
  display: grid; place-items: center;
  font-family: var(--display); font-weight: 800; font-size: 14px;
}
.acct-who { display: grid; text-align: left; line-height: 1.15; min-width: 0; }
.acct-who strong { font-family: var(--display); font-weight: 700; font-size: 14.5px; }
.acct-who span { font-size: 11px; color: var(--ink-55); }
.acct-caret { font-size: 11px; color: var(--ink-55); }

.acct-panel {
  position: absolute; right: 0; top: calc(100% + 10px); z-index: 60;
  min-width: 232px; padding: 8px;
  background: var(--paper); border: 2.5px solid var(--ink);
  border-radius: 18px; box-shadow: 6px 6px 0 rgba(26, 36, 64, .18);
  display: grid; gap: 2px;
  animation: popIn .16s ease-out both;
}
.acct-panel[hidden] { display: none; }
.acct-head {
  display: grid; gap: 2px; padding: 8px 12px 10px;
  border-bottom: 2px dashed var(--ink-12); margin-bottom: 6px;
}
.acct-head strong { font-family: var(--display); font-size: 15px; }
.acct-head span { font-size: 11.5px; color: var(--ink-55); word-break: break-all; }
.acct-panel a, .acct-out {
  display: flex; align-items: center; gap: 10px;
  padding: 10px 12px; border-radius: 11px; border: none; background: none;
  font-family: var(--body); font-size: 14.5px; font-weight: 600;
  color: var(--ink); cursor: pointer; text-align: left; width: 100%;
}
.acct-panel a:hover, .acct-out:hover { background: var(--cream); color: var(--ink); }
.acct-panel i { font-style: normal; font-size: 15px; width: 20px; text-align: center; }
.acct-out { color: var(--coral); margin-top: 4px; border-top: 2px dashed var(--ink-12);
  border-radius: 0 0 11px 11px; padding-top: 12px; }

@media (max-width: 640px) {
  .acct-who { display: none; }
  .acct-btn { padding: 5px; }
}

/* ------------------------------------------------------------------ type */
h1, h2, h3, h4 { font-family: var(--display); font-weight: 800; margin: 0; line-height: 1.05; }
.h-xl { font-size: clamp(34px, 4.6vw, 54px); }
.h-lg { font-size: clamp(27px, 3.4vw, 40px); }
.h-md { font-size: clamp(21px, 2.3vw, 27px); }
.lede { font-size: 15px; line-height: 1.55; color: var(--ink-68); }
.eyebrow {
  font-size: 12.5px; font-weight: 700; letter-spacing: .03em;
  text-transform: uppercase; color: var(--ink-62);
}
.muted { color: var(--ink-62); }

/* ----------------------------------------------------------- components */
.card {
  background: var(--paper);
  border: 2.5px solid var(--ink);
  border-radius: var(--r-card);
  box-shadow: var(--shadow-card);
  padding: clamp(22px, 4vw, 38px);
}
.card-flat {
  background: var(--paper); border: 2px solid var(--ink);
  border-radius: 16px; padding: 18px;
}
.panel-dark {
  background: var(--ink); color: var(--cream);
  border-radius: var(--r-card); padding: clamp(22px, 3vw, 30px);
}

.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 10px;
  background: var(--ink); color: var(--cream);
  font-family: var(--display); font-weight: 700; font-size: 17px;
  padding: 15px 26px; border: none; border-radius: var(--r-pill);
  box-shadow: var(--shadow-btn); cursor: pointer;
  transition: transform .25s ease, box-shadow .25s ease;
}
.btn:hover:not(:disabled) { transform: translate(-2px, -3px); box-shadow: 7px 7px 0 var(--amber); color: var(--cream); }
.btn:active:not(:disabled) { transform: translate(1px, 1px); box-shadow: 2px 2px 0 var(--amber); }
.btn:disabled { opacity: .5; cursor: not-allowed; box-shadow: none; }
.btn-full { width: 100%; }
.btn-amber {
  background: var(--amber); color: var(--ink);
  border: 2.5px solid var(--ink); box-shadow: 3px 3px 0 var(--ink);
}
.btn-amber:hover:not(:disabled) { color: var(--ink); box-shadow: 6px 6px 0 var(--ink); }
.btn-green { background: var(--green); color: var(--ink); border: 2.5px solid var(--ink); box-shadow: 3px 3px 0 var(--ink); }
.btn-green:hover:not(:disabled) { color: var(--ink); }
.btn-ghost {
  background: transparent; color: var(--ink);
  border: 2px solid var(--ink); box-shadow: none; font-size: 15px; padding: 11px 20px;
}
.btn-ghost:hover:not(:disabled) { color: var(--ink); box-shadow: 3px 3px 0 var(--amber); }
.btn-sm { font-size: 13.5px; padding: 10px 16px; }

.tab {
  font-family: var(--display); font-weight: 700; font-size: 15px;
  padding: 10px 22px; border-radius: var(--r-pill); cursor: pointer;
  transition: all .2s ease; background: transparent; color: var(--ink);
  border: 2px solid var(--ink); box-shadow: none;
}
.tab.on { background: var(--ink); color: var(--cream); box-shadow: 3px 3px 0 var(--amber); }

.chip {
  cursor: pointer; font-family: var(--display); font-weight: 700; font-size: 13.5px;
  padding: 8px 16px; border-radius: var(--r-pill); border: 2px solid var(--ink);
  transition: all .15s ease; background: transparent; color: var(--ink);
}
.chip.on { background: var(--ink); color: var(--cream); box-shadow: 2px 2px 0 var(--amber); }

.pill {
  display: inline-block; font-size: 11.5px; font-weight: 700; letter-spacing: .03em;
  padding: 4px 12px; border-radius: var(--r-pill);
  border: 1.5px solid var(--ink); color: var(--ink); background: var(--idle-bg);
}
.pill-ok { background: var(--ok-bg); }
.pill-warn { background: var(--warn-bg); }
.pill-bad { background: var(--bad-bg); }

/* choice cards (parent / school) */
.choice {
  display: grid; gap: 4px; justify-items: center; text-align: center;
  padding: 14px 10px; border-radius: 16px; cursor: pointer;
  transition: all .2s ease; font-family: var(--body);
  background: var(--cream); border: 2px dashed var(--ink-45); color: var(--ink);
}
.choice.on {
  background: var(--amber); border: 2.5px solid var(--ink);
  box-shadow: 4px 4px 0 var(--ink);
}
.choice-emoji { font-size: 22px; line-height: 1; }
.choice-title { font-family: var(--display); font-weight: 700; font-size: 16px; }
.choice-sub { font-size: 12px; color: var(--ink-62); font-weight: 500; }

/* forms */
.field { display: grid; gap: 6px; }
.field > span,
label.field > span {
  font-size: 12.5px; font-weight: 700; letter-spacing: .03em;
  text-transform: uppercase; color: var(--ink-62);
}
.input, input[type=text], input[type=email], input[type=password],
input[type=date], input[type=number], input[type=tel], select, textarea {
  border: 2px solid var(--ink); border-radius: var(--r-field);
  padding: 12px 14px; font-size: 15px;
  /* background-COLOR, not the shorthand: `.input` outranks the bare `select`
     selector below, and the shorthand would reset its chevron to none. A
     <select class="input"> would then silently lose its arrow. */
  background-color: var(--cream);
  color: var(--ink); outline-color: var(--amber); width: 100%;
}
.input:focus, input:focus, select:focus, textarea:focus {
  outline: 3px solid var(--amber); outline-offset: 1px;
}
.input.err, input.err, select.err { border-color: var(--coral); }

/* ---------------------------------------------------------------- selects
   Left alone, a <select> is drawn by the operating system: a grey gradient
   well with a system-blue chevron, at a height that does not match the text
   input sitting next to it. `appearance: none` hands the whole control back to
   us, and everything below redraws it in the house style.

   The chevron is three stacked background layers rather than a wrapper element,
   so any plain <select> in any page gets the treatment without its markup
   changing: the arrow itself, a 2px ink rule, and an amber block behind them —
   the same hard-edged tab the buttons use. */
/* `:not([multiple])` is doing two jobs. It excludes list-boxes, which should
   keep their native rendering — a chevron on a scrolling list is nonsense. And
   it lifts this rule to the same specificity as `.input`, which several pages
   put on their selects; a bare `select` selector would lose to it and the
   control would keep input padding with the amber block on top of the text. */
select:not([multiple]) {
  appearance: none; -webkit-appearance: none;
  padding-right: 52px;                 /* clears the amber block */
  cursor: pointer;
  line-height: 1.3;
  /* "Dadra and Nagar Haveli and Daman and Diu" in a 320px field on a phone.
     Without this it is chopped mid-letter at the amber block. */
  text-overflow: ellipsis; white-space: nowrap; overflow: hidden;
  /* Stops a dark-mode browser inverting the drop-down list to grey-on-black,
     which no amount of styling here can reach. */
  color-scheme: light;
  background-color: var(--cream);
  background-image:
    url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='14' height='9' fill='none'%3E%3Cpath d='M1.6 1.6 7 7l5.4-5.4' stroke='%231A2440' stroke-width='2.6' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E"),
    linear-gradient(var(--ink), var(--ink)),
    linear-gradient(var(--amber), var(--amber));
  background-position: right 15px center, right 38px center, right center;
  background-size: 14px 9px, 2px 100%, 38px 100%;
  background-repeat: no-repeat;
}
select:not([multiple]):hover { background-color: var(--paper); }
select:not([multiple]):hover, select:not([multiple]):focus {
  /* nudge the chevron down a hair — it reads as the control depressing */
  background-position: right 15px calc(50% + 1px), right 38px center, right center;
}
select:not([multiple]):disabled {
  cursor: not-allowed; color: var(--ink-45);
  background-image:
    url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='14' height='9' fill='none'%3E%3Cpath d='M1.6 1.6 7 7l5.4-5.4' stroke='%231A2440' stroke-width='2.6' stroke-linecap='round' stroke-linejoin='round' opacity='.4'/%3E%3C/svg%3E"),
    linear-gradient(var(--ink-35), var(--ink-35)),
    linear-gradient(var(--ink-12), var(--ink-12));
  /* Restated rather than inherited from the rule above: a page that styles
     `.input:disabled` with the `background` shorthand outranks that rule and
     would reset the geometry, tiling the divider into stripes. */
  background-position: right 15px center, right 38px center, right center;
  background-size: 14px 9px, 2px 100%, 38px 100%;
  background-repeat: no-repeat;
  border-color: var(--ink-35);
}
/* The drop-down list itself. Browsers expose very little here, but background
   and colour land on most, and without them a cream control opens a stark
   white list. */
select option { background: var(--paper); color: var(--ink); font-weight: 500; }
select option:disabled { color: var(--ink-45); }

/* A select rendered small — filter bars, the dial-code box. */
select.sel-sm {
  padding: 9px 44px 9px 12px; font-size: 14px;
  background-position: right 13px center, right 32px center, right center;
  background-size: 12px 8px, 2px 100%, 32px 100%;
}
.grid-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.stack { display: grid; gap: 14px; }
.field-err { font-size: 12px; font-weight: 600; color: var(--coral); text-transform: none; letter-spacing: 0; }
/* Explanatory line under an input. Lives here rather than per-page so every
   form that grows one looks the same. */
.field > .hint, .hint {
  font-size: 12px; line-height: 1.5; color: var(--ink-55);
  font-weight: 500; text-transform: none; letter-spacing: 0;
}

/* feedback */
.alert {
  border: 2px solid var(--ink); border-radius: var(--r-field);
  padding: 12px 15px; font-size: 14px; font-weight: 500; line-height: 1.5;
}
.alert-bad { background: var(--bad-bg); }
.alert-ok { background: var(--ok-bg); }
.alert-warn { background: var(--warn-bg); }

.spinner {
  width: 17px; height: 17px; border-radius: 50%; flex: none;
  border: 2.5px solid var(--ink-35); border-top-color: var(--ink);
  animation: spin .7s linear infinite;
}
.spinner-cream { border-color: rgba(251,243,227,.35); border-top-color: var(--cream); }

.skeleton {
  background: linear-gradient(90deg, var(--ink-05) 25%, rgba(26,36,64,.11) 50%, var(--ink-05) 75%);
  background-size: 600px 100%; animation: shimmer 1.4s infinite linear;
  border-radius: 10px;
}

/* toast */
.toast-host {
  position: fixed; left: 50%; bottom: 26px; transform: translateX(-50%);
  z-index: 999; display: grid; gap: 10px; width: min(92vw, 420px);
}
.toast {
  background: var(--ink); color: var(--cream);
  border-radius: 14px; padding: 13px 18px; font-size: 14px; font-weight: 600;
  box-shadow: 4px 4px 0 var(--amber); animation: popIn .25s ease-out both;
}
.toast.bad { background: var(--coral); color: #fff; box-shadow: 4px 4px 0 var(--ink); }
.toast.ok { background: var(--green); color: var(--ink); box-shadow: 4px 4px 0 var(--ink); }

/* modal */
.modal-back {
  position: fixed; inset: 0; background: rgba(26,36,64,.55);
  display: grid; place-items: center; padding: 18px; z-index: 200;
  animation: popIn .2s ease-out both; overflow-y: auto;
}
.modal {
  background: var(--paper); border: 2.5px solid var(--ink);
  border-radius: var(--r-card); box-shadow: var(--shadow-card);
  padding: clamp(20px, 3vw, 30px); width: min(560px, 100%); margin: auto;
  position: relative;
}
/* The dialog's visible way out. Escape and a backdrop click work too, but
   neither announces itself. */
.modal-x {
  position: absolute; top: 12px; right: 12px; width: 34px; height: 34px;
  border: 0; border-radius: 50%; background: rgba(26, 36, 64, .06);
  color: var(--ink); font-size: 21px; line-height: 1; cursor: pointer;
}
.modal-x:hover { background: rgba(26, 36, 64, .12); }

/* Full-screen artwork. The console's whole job is judging a keyed edge, so
   art opens on a neutral field and can be zoomed. */
.lightbox {
  position: fixed; inset: 0; z-index: 90; background: #0C101C;
  display: flex; flex-direction: column;
}
.lightbox-bar {
  display: flex; align-items: center; gap: 12px;
  padding: 12px 16px; color: #fff;
}
.lightbox-cap { flex: 1; font-size: 13px; opacity: .85; }
.lightbox-stage { flex: 1; overflow: auto; display: grid; place-items: center; }
.lightbox-stage img {
  max-width: 100%; max-height: 100%; transform-origin: center center;
  transition: transform .12s ease-out; cursor: zoom-in;
}
.lightbox-stage.zoomed { place-items: start; }
.lightbox-stage.zoomed img { max-width: none; max-height: none; cursor: zoom-out; }
.lightbox-hint { text-align: center; color: rgba(255,255,255,.55); font-size: 11.5px; padding: 10px; }

/* A page collapses to a strip and opens on click. */
.pb-panel { border: 2px solid var(--ink); border-radius: 16px; overflow: hidden; margin-top: 12px; background: var(--paper); }
.pb-head { display: flex; align-items: center; gap: 12px; padding: 10px 12px; width: 100%;
  background: none; border: 0; cursor: pointer; text-align: left; }
.pb-thumb { width: 46px; height: 60px; border-radius: 8px; object-fit: cover; background: var(--cream); flex: none; }
.pb-body { padding: 0 14px 16px; border-top: 1px solid rgba(26,36,64,.12); }

/* footer */
.footer {
  position: relative; z-index: 20; background: var(--ink); color: var(--cream);
  margin-top: 60px; padding: 40px var(--pad-x) 22px;
}
.footer-top {
  display: flex; flex-wrap: wrap; gap: 34px; justify-content: space-between;
  max-width: var(--maxw); margin: 0 auto;
}
.footer-cols { display: flex; gap: clamp(30px, 5vw, 70px); flex-wrap: wrap; }
.footer-col { display: grid; gap: 9px; font-size: 13.5px; align-content: start; }
.footer-col strong {
  font-size: 11px; letter-spacing: .09em; text-transform: uppercase;
  color: rgba(251,243,227,.5); font-weight: 700;
}
.footer-col a { color: rgba(251,243,227,.8); }
.footer-col a:hover { color: var(--cream); }
.footer-blurb { margin: 12px 0 0; font-size: 13px; line-height: 1.6; color: rgba(251,243,227,.6); }
.footer-bottom {
  max-width: var(--maxw); margin: 28px auto 0; padding-top: 15px;
  border-top: 1px solid rgba(251,243,227,.18);
  display: flex; justify-content: space-between; gap: 12px; flex-wrap: wrap;
  font-size: 12px; color: rgba(251,243,227,.45); font-weight: 500;
}

/* page header block used on app screens */
.page-head { padding: 6px var(--pad-x) 0; max-width: var(--maxw); margin: 0 auto; }
.page-head h1 { font-size: clamp(28px, 3.6vw, 42px); }
.page-head p { margin: 10px 0 0; max-width: 60ch; }

.section { padding: clamp(30px, 5vw, 60px) var(--pad-x); }

/* responsive */
@media (max-width: 860px) {
  .grid-2 { grid-template-columns: 1fr; }
}
@media (max-width: 720px) {
  .nav-toggle { display: block; }
  .nav-links {
    display: none; width: 100%; flex-direction: column; align-items: flex-start;
    gap: 14px; padding: 14px 2px 4px; font-size: 16px;
  }
  .nav-links.open { display: flex; animation: fadeUp .25s ease-out both; }
  .footer-top { flex-direction: column; gap: 26px; }
  .footer-cols { gap: 26px; }
  .card { box-shadow: 5px 5px 0 var(--ink); }
}

/* ------------------------------------------------- book preview (books.js) */
.preview-bar { margin-top: 14px; }
.preview-stage {
  margin-top: 8px; background: var(--cream);
  border: 2px solid var(--ink); border-radius: 14px;
  min-height: 260px; padding: 12px;
  display: grid; place-items: center; overflow: hidden;
}
.preview-img {
  max-width: 100%; max-height: min(58vh, 560px); width: auto;
  border: 2px solid var(--ink); border-radius: 8px;
  box-shadow: 4px 4px 0 var(--ink); animation: popIn .2s ease-out both;
}
.preview-loading {
  display: flex; align-items: center; gap: 10px;
  font-size: 14px; font-weight: 600; color: var(--ink-62);
}
.preview-actions {
  display: flex; align-items: center; gap: 10px;
  margin-top: 16px; flex-wrap: wrap;
}

/* -------------------------------------------------------------- checkout */
.pay-choice {
  grid-template-columns: auto 1fr;
  grid-template-areas: "emoji title" "emoji sub";
  gap: 2px 14px; align-items: center; padding: 16px 18px;
}
.pay-choice .choice-emoji { grid-area: emoji; font-size: 26px; }
.pay-choice .choice-title { grid-area: title; align-self: end; }
.pay-choice .choice-sub { grid-area: sub; align-self: start; text-align: left; }
.pay-choice:hover {
  background: var(--paper); border-style: solid; border-color: var(--ink);
  box-shadow: 4px 4px 0 var(--amber);
}
.pay-line {
  display: flex; justify-content: space-between; gap: 12px;
  font-size: 13.5px; padding: 3px 0;
}
.pay-line strong { font-weight: 700; }
.pay-total {
  display: flex; justify-content: space-between; align-items: baseline; gap: 12px;
  margin-top: 10px; padding-top: 10px; border-top: 2px solid currentColor;
  font-family: var(--display); font-weight: 800; font-size: 19px;
}
