/* Rensa Puzzle website. Colours are the app's own (lib/ui/game_colors.dart):
   royal-blue band, pale page, white raised tiles with a soft lower edge, and
   the board's dark frame. Nunito is bundled from the app (fonts/). */
@font-face {
  font-family: "Nunito";
  src: url("/fonts/Nunito-Variable.ttf") format("truetype");
  font-weight: 600 900;
  font-style: normal;
  font-display: swap;
}

:root {
  --page: #edf2ff; --paper: #ffffff; --edge: #cdd7ee; --tray: #e2e9fa; --frame: #1b2a4a;
  --ink: #1b2a4a; --muted: #5a6a86; --line: #d5ddef; --link: #2a5ce4;
  --accent: #2a5ce4; --accent-edge: #1b3fb0;
  --band-a: #3f6ff2; --band-b: #2b55da; --band-edge: #1d3cab;
  --gold: #ffd23f; --gold-edge: #c99700; --focus: #ffb800;
  --empty: #d3dcf0;
  --round: "Nunito", "Arial Rounded MT Bold", "Helvetica Neue", Arial, sans-serif;
  color-scheme: light;
}
@media (prefers-color-scheme: dark) {
  :root {
    --page: #0f131c; --paper: #263047; --edge: #141a27; --tray: #181e2c; --frame: #5a6a90;
    --ink: #e9eefb; --muted: #95a2bc; --line: #232c40; --link: #84a6ff;
    --accent: #4a7bf5; --accent-edge: #2b55c4;
    --band-a: #3461e0; --band-b: #2448c2; --band-edge: #142f86;
    --empty: #2d3950;
    color-scheme: dark;
  }
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; background: var(--page); color: var(--ink); font-family: var(--round); font-weight: 600; font-size: 17px; line-height: 1.55; -webkit-font-smoothing: antialiased; font-variant-numeric: tabular-nums; }
a { color: var(--link); text-underline-offset: 3px; }
a:focus-visible, summary:focus-visible, .skip:focus-visible { outline: 3px solid var(--focus); outline-offset: 3px; border-radius: 6px; }
img, svg { max-width: 100%; }
.wrap { max-width: 1080px; margin: 0 auto; padding-left: max(20px, env(safe-area-inset-left)); padding-right: max(20px, env(safe-area-inset-right)); }
.skip { position: absolute; left: -999px; top: 8px; background: var(--paper); color: var(--ink); padding: 8px 14px; border-radius: 10px; z-index: 10; }
.skip:focus { left: 12px; }

/* ---- the board art (inline SVG from the generator) ---- */
.bd-paper { fill: var(--paper); }
.bd-edge { fill: var(--edge); }
.bd-ink { fill: var(--ink); }
.bd-tray { fill: var(--tray); stroke: var(--frame); }
.bd-tray.bd-soft { stroke: var(--line); }
.bd-wall { fill: var(--frame); fill-opacity: .82; }
.bd-empty { fill: var(--empty); }
.bd-q { fill: var(--accent); }
@media (prefers-color-scheme: dark) { .bd-q { fill: #84a6ff; } }
svg.board, svg.mos, svg.glyph { display: block; width: 100%; height: auto; }

/* ---- band: the app's blue header ---- */
.band { background: linear-gradient(180deg, var(--band-a) 0%, var(--band-b) 100%); color: #fff; border-radius: 0 0 36px 36px; box-shadow: 0 6px 0 var(--band-edge); padding-bottom: 56px; position: relative; overflow: hidden; }
.band a { color: #fff; }
.nav { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding-top: 20px; }
.brand { display: inline-flex; align-items: center; gap: 12px; text-decoration: none; font-weight: 900; font-size: 1.25rem; letter-spacing: .01em; color: inherit; }
.brand img { border-radius: 11px; box-shadow: 0 3px 0 rgba(0,0,0,.18); }
.nav__links { display: flex; gap: 4px; }
.nav__links a { text-decoration: none; font-weight: 800; font-size: .95rem; padding: 10px 14px; border-radius: 12px; min-height: 44px; display: inline-flex; align-items: center; }
.nav__links a:hover { background: rgba(255,255,255,.14); }

.hero { display: grid; grid-template-columns: minmax(0, 1.1fr) minmax(0, .9fr); gap: clamp(28px, 5vw, 72px); align-items: center; padding-top: clamp(28px, 6vw, 64px); }
.eyebrow { font-size: .78rem; font-weight: 900; letter-spacing: .14em; text-transform: uppercase; color: #ffe27a; margin: 0 0 10px; }
h1 { font-weight: 900; font-size: clamp(2.4rem, 6.4vw, 4.1rem); line-height: 1.02; letter-spacing: -.015em; margin: 0; text-wrap: balance; }
.hero__pitch { font-size: clamp(1.05rem, 1.6vw, 1.22rem); margin: 20px 0 0; max-width: 34ch; opacity: .93; }
.hero__art { position: relative; max-width: 420px; justify-self: center; width: 100%; }
.hero__art .board { transform: rotate(-3deg); filter: drop-shadow(0 14px 0 rgba(10, 30, 110, .28)); }

/* store slots: "Coming soon" until the apps are live (see the comment in index.html) */
.stores { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 28px; }
.store { display: inline-flex; flex-direction: column; justify-content: center; min-height: 54px; min-width: 168px; padding: 7px 18px; border-radius: 14px; background: rgba(255,255,255,.12); border: 2px dashed rgba(255,255,255,.55); color: #fff; line-height: 1.15; }
.store small { font-size: .72rem; font-weight: 800; letter-spacing: .1em; text-transform: uppercase; opacity: .8; }
.store b { font-size: 1.1rem; font-weight: 900; }
.badge { display: inline-block; line-height: 0; border-radius: 9px; }
.badge img { display: block; height: 52px; width: auto; }
.facts { display: flex; flex-wrap: wrap; gap: 8px 18px; margin: 18px 0 0; padding: 0; list-style: none; font-weight: 800; font-size: .95rem; opacity: .92; }
.facts li { display: inline-flex; align-items: center; gap: 7px; }
.facts li::before { content: ""; width: 9px; height: 9px; border-radius: 3px; background: var(--gold); box-shadow: 0 2px 0 var(--gold-edge); }

/* ---- sections ---- */
main section { padding: clamp(48px, 8vw, 88px) 0 0; }
.kicker { font-size: .78rem; font-weight: 900; letter-spacing: .14em; text-transform: uppercase; color: var(--accent); margin: 0 0 8px; }
@media (prefers-color-scheme: dark) { .kicker { color: #84a6ff; } }
h2 { font-weight: 900; font-size: clamp(1.75rem, 4vw, 2.5rem); line-height: 1.1; margin: 0; letter-spacing: -.01em; text-wrap: balance; }
h3 { font-weight: 900; font-size: 1.2rem; line-height: 1.2; margin: 0 0 6px; }
.lead { color: var(--muted); font-size: 1.1rem; max-width: 58ch; margin: 14px 0 0; }
.raised { background: var(--paper); border-radius: 22px; box-shadow: 0 5px 0 var(--edge); }
.cards { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 18px; margin-top: 30px; }
.card { padding: 18px 18px 22px; }
.card p { margin: 0; color: var(--muted); }
.card__art { width: 100%; max-width: 150px; margin: 2px 0 14px; }
.step { display: inline-block; font-size: .75rem; font-weight: 900; letter-spacing: .12em; color: var(--accent); margin-bottom: 4px; }
@media (prefers-color-scheme: dark) { .step { color: #84a6ff; } }

.sizes { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 12px; margin-top: 28px; }
.size { padding: 14px 10px 12px; display: flex; flex-direction: column; align-items: center; gap: 8px; font-weight: 900; font-size: 1.05rem; }
.size .glyph { width: 56px; }
.size small { font-size: .78rem; font-weight: 800; color: var(--muted); text-align: center; line-height: 1.25; }
.twists { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 18px; margin-top: 18px; }
.twist { display: grid; grid-template-columns: 130px minmax(0, 1fr); gap: 18px; align-items: center; padding: 18px; }
.twist p { margin: 0; color: var(--muted); }
.tag { display: inline-block; font-size: .7rem; font-weight: 900; letter-spacing: .12em; color: #fff; background: #7e5ce0; border-radius: 6px; padding: 2px 7px; margin-bottom: 8px; }

.duo { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 18px; margin-top: 30px; }
.duo .raised { padding: 22px; display: flex; flex-direction: column; gap: 16px; }
.duo p { margin: 0; color: var(--muted); }
.cal { display: grid; grid-template-columns: repeat(7, minmax(0, 1fr)); gap: 6px; }
.cal .today { aspect-ratio: 1; border-radius: 9px; background: var(--accent); box-shadow: 0 3px 0 var(--accent-edge); color: #fff; font-weight: 900; display: flex; align-items: center; justify-content: center; font-size: .9rem; }
.cal .fz { aspect-ratio: 1; border-radius: 9px; background: #d6efff; display: flex; align-items: center; justify-content: center; }
.cal .fz svg { width: 60%; }
.cal .later { aspect-ratio: 1; border-radius: 9px; border: 2px dashed var(--line); }
.pills { margin-top: auto !important; display: flex; flex-wrap: wrap; gap: 8px; margin: 0; padding: 0; list-style: none; }
.pills li { font-size: .85rem; font-weight: 800; padding: 5px 11px; border-radius: 999px; background: var(--tray); color: var(--ink); }
.rush { display: flex; align-items: center; gap: 18px; }
.rush svg { width: 132px; flex: none; }
.rush .clock-num { font-weight: 900; }

.album { margin-top: clamp(48px, 8vw, 88px); }
.album .band { border-radius: 30px; padding: clamp(28px, 5vw, 48px); box-shadow: 0 6px 0 var(--band-edge); }
.album__row { display: grid; grid-template-columns: repeat(10, minmax(0, 1fr)); gap: 8px; margin: 24px 0 6px; }
.album .lead { color: #fff; opacity: .9; }
.album h2 { color: #fff; }

.foot { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 14px 24px; padding: 40px 0 48px; margin-top: clamp(40px, 6vw, 64px); border-top: 1px solid var(--line); color: var(--muted); font-size: .92rem; }
.foot nav { display: flex; flex-wrap: wrap; gap: 6px 4px; }
.foot nav a { padding: 10px 10px; min-height: 44px; display: inline-flex; align-items: center; font-weight: 800; }
.foot p { margin: 0; display: flex; align-items: center; }

/* ---- document pages (privacy, support) ---- */
.band.slim { padding-bottom: 40px; }
.band.slim h1 { font-size: clamp(2rem, 5.4vw, 3.2rem); margin-top: clamp(26px, 5vw, 48px); }
.band.slim .lead { color: #fff; opacity: .9; }
.doc { max-width: 760px; }
.doc h2 { font-size: 1.45rem; margin-top: 36px; }
.doc p, .doc li { color: var(--muted); max-width: 68ch; overflow-wrap: anywhere; }
.doc p strong, .doc li strong { color: var(--ink); }
.doc ul { padding-left: 1.2em; }
.doc .date { font-size: .9rem; font-weight: 800; color: #fff; opacity: .85; margin: 12px 0 0; }
.contact { margin-top: 34px; padding: 22px; display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 14px; }
.contact p { margin: 0; color: var(--muted); }
.email { font-weight: 900; font-size: 1.25rem; color: var(--ink); user-select: all; -webkit-user-select: all; overflow-wrap: anywhere; }
.btn { display: inline-flex; align-items: center; justify-content: center; min-height: 48px; padding: 0 20px; border-radius: 14px; background: var(--accent); box-shadow: 0 4px 0 var(--accent-edge); color: #fff; font-weight: 900; text-decoration: none; }
.faq { margin-top: 18px; display: flex; flex-direction: column; gap: 12px; }
.faq details { padding: 0 20px; }
.faq summary { cursor: pointer; list-style: none; display: flex; justify-content: space-between; align-items: center; gap: 14px; min-height: 60px; font-weight: 900; font-size: 1.08rem; }
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: "+"; font-size: 1.5rem; line-height: 1; color: var(--accent); flex: none; }
.faq details[open] summary::after { content: "−"; }
.faq details p { margin: 0 0 18px; color: var(--muted); }

@media (max-width: 860px) {
  .hero { grid-template-columns: 1fr; }
  .hero__art { max-width: 340px; }
  .cards { grid-template-columns: 1fr; }
  .card { display: grid; grid-template-columns: 110px minmax(0, 1fr); gap: 16px; align-items: center; }
  .card__art { margin: 0; }
  .twists, .duo { grid-template-columns: 1fr; }
  .sizes { grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 8px; }
  .size { padding: 10px 4px; font-size: .9rem; }
  .size .glyph { width: 40px; }
  .size small { display: none; }
  .album__row { grid-template-columns: repeat(5, minmax(0, 1fr)); }
}
@media (max-width: 420px) {
  .twist { grid-template-columns: 96px minmax(0, 1fr); gap: 14px; }
  .rush { flex-direction: column; align-items: flex-start; }
  .store { min-width: 0; flex: 1 1 140px; }
}
@media (prefers-reduced-motion: no-preference) {
  .raised { transition: transform .15s ease; }
}
