/* Onboarding (start.html), the setup guide (setup.html) and the download page. Loaded after site.css. */
[hidden] { display: none !important; }
:root { --vp: #e03a52; --va: #ffc94a; --vp-ink: #fff; --va-ink: #0b0c10; }
.nav .grow { flex: 1; }
.ob-main, .guide-main, .dl-main { padding: 36px max(16px, calc(50% - 600px)) 40px; }
.ob-head h1, .done h1 { font-size: clamp(2.2em, 5vw, 3.6em); margin-bottom: 10px; }
.ob-head h1 em, .done h1 em { font-style: normal; color: var(--brand); }
.lbl { display: block; font-weight: 600; font-size: 0.9em; margin-bottom: 8px; }
.linkish { background: none; border: 0; padding: 0; color: var(--cyan); font-weight: 700; font-size: 0.9em; text-decoration: underline; text-underline-offset: 3px; }

/* Progress */
.ob-progress { list-style: none; display: flex; gap: 6px; margin: 26px 0 22px; counter-reset: s; }
.ob-progress li { flex: 1; }
.ob-progress button { width: 100%; display: flex; align-items: center; gap: 10px; background: var(--panel); border: 1px solid var(--line); border-radius: 14px; padding: 10px 12px; font-weight: 700; color: var(--muted); font-size: 0.9em; }
.ob-progress button span { width: 26px; height: 26px; flex: none; border-radius: 50%; display: grid; place-items: center; background: var(--bg2); border: 1px solid var(--line); font-size: 0.85em; }
.ob-progress li.on button { color: var(--text); border-color: var(--brand); }
.ob-progress li.on button span { background: var(--brand); border-color: var(--brand); color: #fff; }
.ob-progress li.past button span { background: var(--green); border-color: var(--green); color: #0b0c10; }

/* Layout */
.ob-grid { display: grid; grid-template-columns: minmax(0, 1.15fr) minmax(0, 1fr); gap: 28px; align-items: start; }
.step { display: grid; gap: 16px; }
.step[hidden] { display: none; }
.step h2 { font-size: 2em; margin-bottom: 0; }
.step > .muted { margin-top: -8px; }
fieldset { border: 0; display: grid; gap: 8px; }
legend { font-weight: 600; font-size: 0.9em; margin-bottom: 8px; padding: 0; }
.ob-nav { display: flex; align-items: center; gap: 12px; padding-top: 6px; border-top: 1px solid var(--line); margin-top: 4px; padding-top: 16px; }
.ob-nav .grow { flex: 1; }
select.bad, textarea.bad { border-color: var(--brand); }
.bad-text { color: #ff8b98; font-weight: 700; }

/* Choice chips made of radios */
.choice { display: flex; flex-wrap: wrap; gap: 8px; border-radius: 14px; }
.choice.bad { outline: 2px solid var(--brand); outline-offset: 4px; }
.choice label { display: block; font-weight: 600; }
.choice input { position: absolute; opacity: 0; width: 1px; height: 1px; }
.choice span { display: inline-block; padding: 0.6em 1.1em; border-radius: 999px; border: 1px solid var(--line); background: var(--bg2); cursor: pointer; font-size: 0.95em; }
.choice input:checked + span { background: var(--text); color: var(--bg); border-color: var(--text); }
.choice input:focus-visible + span { outline: 2px solid var(--cyan); outline-offset: 2px; }

/* Number steppers and the lane map */
.stepper { display: grid; grid-template-columns: 48px 1fr 48px; gap: 6px; }
.stepper button { border-radius: 12px; border: 1px solid var(--line); background: var(--bg2); font-size: 1.3em; font-weight: 700; }
.stepper button:hover { border-color: var(--muted); }
.stepper input { text-align: center; font-weight: 800; font-size: 1.15em; -moz-appearance: textfield; }
.stepper input::-webkit-inner-spin-button, .stepper input::-webkit-outer-spin-button { -webkit-appearance: none; margin: 0; }
.lane-map { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; }
.lane-map .pj { background: var(--bg2); border: 1px solid var(--line); border-radius: 12px; padding: 8px 10px; display: grid; gap: 6px; font-size: 0.85em; }
.lane-map .pj span { display: flex; gap: 4px; }
.lane-map i { font-style: normal; background: #3a2a1c; color: #ffd9a8; border-radius: 6px; padding: 2px 8px; font-weight: 700; font-size: 0.9em; }

/* Logo */
.logo-drop { position: relative; display: grid; grid-template-columns: 132px 1fr; gap: 16px; align-items: center; background: var(--bg2); border: 1px dashed var(--muted); border-radius: 16px; padding: 14px; }
.logo-drop.over { border-color: var(--cyan); background: #0f1d24; }
.logo-drop.bad { border-color: var(--brand); }
.logo-drop input[type=file] { position: absolute; inset: 0; opacity: 0; cursor: pointer; width: 100%; }
.logo-box { width: 132px; height: 132px; border-radius: 12px; display: grid; place-items: center; text-align: center; font-size: 0.82em; font-weight: 600; color: var(--muted);
  background: repeating-conic-gradient(#1c1f28 0% 25%, #14161d 0% 50%) 50% / 16px 16px; overflow: hidden; }
.logo-box img { max-width: 88%; max-height: 88%; object-fit: contain; display: none; }
.logo-box.has img { display: block; }
.logo-box.has span { display: none; }
.logo-info { display: grid; gap: 4px; min-width: 0; }
.logo-info b { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.logo-info span { font-size: 0.85em; }

/* Colours */
.colour { display: grid; grid-template-columns: 52px 1fr; gap: 8px; }
.colour input[type=color], .pal input[type=color] { padding: 3px; height: 46px; cursor: pointer; }
.colour input:not([type=color]) { font-family: Menlo, Consolas, monospace; text-transform: lowercase; }
input[type=color]::-webkit-color-swatch-wrapper { padding: 0; }
input[type=color]::-webkit-color-swatch { border: 0; border-radius: 8px; }
.suggest { display: flex; flex-wrap: wrap; align-items: center; gap: 10px; }
.suggest .lbl { margin: 0; width: 100%; }
.swatches { display: flex; flex-wrap: wrap; gap: 6px; }
.sw { display: inline-flex; align-items: center; gap: 6px; padding: 4px 10px 4px 4px; border-radius: 999px; border: 1px solid var(--line); background: var(--bg2); font: 600 0.78em Menlo, Consolas, monospace; }
.sw span { width: 22px; height: 22px; border-radius: 50%; background: var(--c); box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.18); }
.sw.in { border-color: var(--text); }
.palette { display: flex; flex-wrap: wrap; gap: 8px; }
.pal { display: inline-flex; align-items: center; gap: 6px; background: var(--bg2); border: 1px solid var(--line); border-radius: 12px; padding: 4px 6px 4px 4px; }
.pal input[type=color] { width: 40px; height: 34px; }
.pal code { font-size: 0.78em; color: var(--muted); }
.pal button { border: 0; background: none; color: var(--muted); font-size: 1.2em; line-height: 1; padding: 0 4px; }
.pal.add { padding: 0 14px; height: 44px; font-weight: 700; color: var(--text); border-style: dashed; }

/* Plans */
.plan-pick { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; }
.pcard { position: relative; display: grid; gap: 6px; align-content: start; background: var(--bg2); border: 1px solid var(--line); border-radius: 16px; padding: 14px; cursor: pointer; font-weight: 400; }
.pcard input { position: absolute; opacity: 0; }
.pcard:has(input:checked) { border-color: var(--brand); box-shadow: 0 0 0 1px var(--brand), 0 14px 40px rgba(224, 58, 82, 0.15); }
.pcard:has(input:focus-visible) { outline: 2px solid var(--cyan); }
.pc-top { display: flex; justify-content: space-between; align-items: baseline; gap: 8px; flex-wrap: wrap; }
.pc-top b { font-size: 1.15em; }
.pc-price { font-family: var(--display); font-size: 1.5em; }
.pc-price small { font: 600 0.45em Inter, sans-serif; color: var(--muted); }
.pc-count { color: var(--gold); font-weight: 700; font-size: 0.85em; }
.pc-genres { display: flex; flex-wrap: wrap; gap: 4px; }
.pc-genres i { font-style: normal; font-size: 0.72em; background: var(--panel); border-radius: 999px; padding: 2px 8px; color: #c9cdd6; }
.money { display: grid; grid-template-columns: auto 1fr; align-items: center; background: var(--bg2); border: 1px solid var(--line); border-radius: 12px; overflow: hidden; }
.money span { padding: 0 10px; color: var(--muted); font-weight: 700; font-size: 0.9em; }
.money input { border: 0; border-radius: 0; }

/* Review */
.review { display: grid; gap: 10px; }
.rv { background: var(--bg2); border: 1px solid var(--line); border-radius: 16px; padding: 14px 16px; }
.rv-h { display: flex; justify-content: space-between; margin-bottom: 8px; }
.rv dl { display: grid; grid-template-columns: minmax(110px, 0.6fr) 1fr; gap: 6px 12px; font-size: 0.92em; }
.rv dt { color: var(--muted); }
.rv dd { overflow-wrap: anywhere; }
.rv-logo { height: 44px; width: auto; background: var(--logo-on-panel, transparent); border-radius: 8px; padding: 3px; }
.dot { display: inline-block; width: 22px; height: 22px; border-radius: 50%; margin-right: 4px; vertical-align: middle; box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.2); }

/* Live preview */
.ob-preview { position: sticky; top: 84px; display: grid; gap: 8px; }
.ob-preview .lbl { color: var(--muted); text-transform: uppercase; letter-spacing: 0.12em; font-size: 0.75em; font-weight: 800; margin: 0; }
.ob-preview .cap { color: var(--muted); font-size: 0.8em; text-align: center; margin-bottom: 8px; }
.wallboard { background: #050608; border: 1px solid var(--line); border-radius: 16px; overflow: hidden; font-family: 'Rajdhani', 'Inter', sans-serif; box-shadow: 0 20px 60px rgba(0, 0, 0, 0.4); }
.wb-top { display: flex; align-items: center; gap: 10px; padding: 10px 14px; background: var(--vp); color: var(--vp-ink); }
.wb-top img { height: 30px; max-width: 90px; object-fit: contain; background: var(--logo-on-brand, transparent); border-radius: 6px; padding: 2px; }
.wb-top img:not([src]) { display: none; }
.wb-top b { font-size: 1.25em; letter-spacing: 0.02em; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.wb-lane { font-weight: 700; opacity: 0.85; white-space: nowrap; }
.wb-body { padding: 10px 14px; display: grid; gap: 6px; }
.wb-row { display: grid; grid-template-columns: 14px 1fr auto; gap: 10px; align-items: center; padding: 6px 10px; border-radius: 10px; background: #12141a; font-weight: 700; font-size: 1.1em; }
.wb-row b { font-family: var(--display); font-weight: 400; font-size: 1.3em; }
.wb-row.on { background: color-mix(in srgb, var(--va) 22%, #12141a); box-shadow: inset 4px 0 0 var(--va); }
.wb-row.on b { color: var(--va); }
.wb-dot { width: 12px; height: 12px; border-radius: 50%; }
.wb-foot { display: flex; justify-content: space-between; gap: 10px; padding: 0 14px 10px; color: var(--muted); font-weight: 700; font-size: 0.95em; }
.wb-time { color: var(--va); }
.wb-palette { display: flex; height: 8px; }
.wb-palette i { flex: 1; }
.brand-tablet { border-width: 8px; border-radius: 22px; }
.brand-tablet .tbar { background: var(--vp); color: var(--vp-ink); border-bottom: 0; }
.brand-tablet .tbar img:not([src]) { display: none; }
.brand-tablet .tbar img { background: var(--logo-on-brand, transparent); border-radius: 6px; padding: 2px; }
.brand-tablet .pill { background: var(--va); color: var(--va-ink); }
.brand-tablet canvas { aspect-ratio: 16 / 9; }
.tfoot { display: flex; gap: 6px; padding: 8px 10px; background: #0d0f14; flex-wrap: wrap; }
.tbtn { padding: 6px 12px; border-radius: 999px; font-weight: 700; font-size: 0.78em; white-space: nowrap; }
.tbtn.ghost { border: 1px solid var(--line); color: var(--muted); }
.tbtn.pri { background: var(--vp); color: var(--vp-ink); }
.tbtn.acc { background: var(--va); color: var(--va-ink); }
.tfoot .grow { flex: 1; }

/* Done */
.done { display: grid; place-items: center; padding-top: 20px; }
.done-card { width: min(680px, 100%); background: var(--panel); border: 1px solid var(--line); border-radius: 24px; padding: 32px; display: grid; gap: 14px; }
.done-card > img { background: var(--logo-on-panel, transparent); border-radius: 12px; padding: 6px; height: 72px; width: auto; max-width: 220px; object-fit: contain; }
.code-row { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; }
.code { font: 800 clamp(1.6em, 6vw, 2.4em) Menlo, Consolas, monospace; letter-spacing: 0.06em; background: var(--bg2); border: 1px solid var(--line); border-radius: 14px; padding: 8px 16px; user-select: all; }
.done .cta { margin-top: 4px; }
.done h3 { margin-top: 10px; }
.code.small { font-size: 1.05em; padding: 3px 10px; border-radius: 10px; }
.pay-note { color: var(--text); }
.pay-note b { color: var(--gold, #ffc94a); }
.next { padding-left: 22px; display: grid; gap: 6px; color: #c9cdd6; }
.next a { color: var(--text); }

/* Download page */
.dl-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 16px; margin-top: 24px; }
.dl { background: var(--panel); border: 1px solid var(--line); border-radius: 24px; padding: 28px; display: grid; gap: 12px; align-content: start; }
.dl .os { font-size: 2.6em; line-height: 1; }
.dl h2 { font-size: 2em; margin: 0; }
.dl .btn[aria-disabled=true] { background: var(--bg2); color: var(--muted); border: 1px solid var(--line); pointer-events: none; }
.soon { display: inline-block; background: var(--gold); color: #0b0c10; font-weight: 800; font-size: 0.72em; text-transform: uppercase; letter-spacing: 0.08em; padding: 3px 10px; border-radius: 999px; }
.dl ul { padding-left: 20px; color: var(--muted); font-size: 0.92em; display: grid; gap: 4px; }
.dl-code { margin-top: 20px; background: var(--panel); border: 1px solid var(--line); border-radius: 18px; padding: 18px 22px; display: flex; gap: 16px; align-items: center; flex-wrap: wrap; }

/* Setup guide */
.guide-main { max-width: 980px; margin: 0 auto; padding-left: 16px; padding-right: 16px; }
.g-hero { display: grid; grid-template-columns: auto 1fr; gap: 22px; align-items: center; background: var(--panel); border: 1px solid var(--line); border-top: 6px solid var(--vp); border-radius: 24px; padding: 26px; }
.g-hero img { border-radius: 14px; padding: 8px; height: 84px; width: auto; max-width: 180px; object-fit: contain; }
.g-hero h1 { font-size: clamp(2em, 4.6vw, 3.2em); margin-bottom: 6px; }
.g-hero .facts { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 10px; }
.g-hero .facts span { background: var(--bg2); border: 1px solid var(--line); border-radius: 999px; padding: 3px 12px; font-size: 0.85em; font-weight: 600; }
.g-tools { display: flex; flex-wrap: wrap; gap: 10px; margin: 18px 0 8px; }
.g-toc { columns: 2; gap: 24px; background: var(--panel); border: 1px solid var(--line); border-radius: 18px; padding: 18px 22px 18px 44px; margin: 14px 0 10px; }
.g-toc li { margin-bottom: 4px; break-inside: avoid; }
.g-toc a { color: var(--text); text-decoration: none; font-weight: 600; }
.g-toc a:hover { color: var(--brand-hi); }
.g-sec { padding-top: 46px; }
.g-sec > h2 { display: flex; align-items: center; gap: 14px; font-size: clamp(1.7em, 3.4vw, 2.4em); }
.g-sec > h2 .n { flex: none; width: 1.5em; height: 1.5em; border-radius: 50%; background: var(--vp); color: var(--vp-ink); display: grid; place-items: center; font-size: 0.8em; }
.g-sec > p, .g-sec li { color: #d4d7de; }
.g-sec h3 { margin: 22px 0 8px; font-size: 1.15em; }
.g-sec p { margin: 8px 0; max-width: 46em; }
.g-steps { counter-reset: gs; list-style: none; display: grid; gap: 10px; margin: 12px 0; }
.g-steps > li { counter-increment: gs; position: relative; padding: 12px 14px 12px 54px; background: var(--panel); border: 1px solid var(--line); border-radius: 14px; }
.g-steps > li::before { content: counter(gs); position: absolute; left: 14px; top: 11px; width: 28px; height: 28px; border-radius: 50%; background: var(--bg2); border: 2px solid var(--vp); display: grid; place-items: center; font-weight: 800; font-size: 0.85em; color: var(--text); }
.g-steps b, .g-sec strong { color: var(--text); }
.g-steps ul { margin: 6px 0 0 18px; }
.g-check { list-style: none; display: grid; gap: 6px; margin: 10px 0; }
.g-check li { position: relative; padding-left: 32px; }
.g-check li::before { content: ''; position: absolute; left: 0; top: 2px; width: 20px; height: 20px; border: 2px solid var(--muted); border-radius: 5px; }
.g-note { background: #10202a; border: 1px solid #1f4152; border-radius: 14px; padding: 12px 16px; margin: 12px 0; color: #cfeaf3; }
.g-note.warn { background: #2a1a10; border-color: #5a3820; color: #ffe2c4; }
.g-note b { color: inherit; }
.g-pay { background: #2a1a10; border: 1px solid #a8642a; border-radius: 16px; padding: 14px 18px; margin: 0 0 18px; color: #ffe2c4; display: flex; gap: 10px 16px; align-items: center; flex-wrap: wrap; }
.g-pay p { margin: 0; flex: 1 1 320px; }
.g-pay b { color: #fff; }
.g-fig { background: var(--panel); border: 1px solid var(--line); border-radius: 18px; padding: 14px; margin: 14px 0; }
.g-fig svg { width: 100%; height: auto; display: block; }
.g-fig figcaption { color: var(--muted); font-size: 0.85em; text-align: center; margin-top: 8px; }
.g-fig .t { fill: #f2f3f6; font: 600 13px Inter, sans-serif; }
.g-fig .t.s { font-size: 11px; fill: #9aa1b0; font-weight: 400; }
.g-fig .t.b { font-weight: 800; }
.g-table { width: 100%; border-collapse: collapse; font-size: 0.92em; margin: 10px 0; }
.g-table th { text-align: left; color: var(--muted); font-weight: 600; font-size: 0.85em; padding: 0 8px 8px; border-bottom: 1px solid var(--line); }
.g-table td { padding: 10px 8px; border-bottom: 1px solid var(--line); vertical-align: top; }
.g-table td span { display: block; color: var(--muted); font-size: 0.85em; }
.g-table .n { text-align: right; white-space: nowrap; }
.g-table .have td { color: var(--muted); }
.g-table .box { width: 28px; }
.g-table .box i { display: inline-block; width: 18px; height: 18px; border: 2px solid var(--muted); border-radius: 4px; }
.g-code { display: inline-block; font: 800 1.5em Menlo, Consolas, monospace; letter-spacing: 0.06em; background: var(--bg2); border: 2px solid var(--vp); border-radius: 12px; padding: 6px 14px; }
.g-trouble { display: grid; gap: 10px; }
.g-trouble details { background: var(--panel); border: 1px solid var(--line); border-radius: 14px; padding: 12px 16px; }
.g-trouble summary { font-weight: 700; cursor: pointer; }
.g-trouble ol { margin: 8px 0 2px 20px; display: grid; gap: 4px; color: #d4d7de; }
.os-alt { margin-top: 12px; }
.os-alt > summary { cursor: pointer; font-weight: 700; color: var(--cyan); }
.g-enter { background: var(--panel); border: 1px solid var(--line); border-radius: 24px; padding: 26px; max-width: 560px; display: grid; gap: 12px; }
.g-enter form { padding: 0; border: 0; background: none; grid-template-columns: 1fr auto; }
.g-sample { display: inline-block; margin-left: 8px; background: var(--gold); color: #0b0c10; font-weight: 800; font-size: 0.45em; vertical-align: middle; padding: 3px 10px; border-radius: 999px; letter-spacing: 0.06em; font-family: Inter, sans-serif; }

/* Smaller screens */
@media (max-width: 1000px) {
  .ob-grid { grid-template-columns: 1fr; }
  .ob-preview { position: static; }
  /* On a phone the preview sits under the form and only shows where it matters. */
  body.ob:not([data-step=brand]):not([data-step=review]) .ob-preview { display: none; }
}
@media (max-width: 720px) {
  .ob-main, .dl-main { padding-top: 22px; }
  .ob-progress button { flex-direction: column; gap: 4px; padding: 8px 4px; font-size: 0.72em; }
  .plan-pick, .dl-grid { grid-template-columns: 1fr; }
  .logo-drop { grid-template-columns: 96px 1fr; }
  .logo-box { width: 96px; height: 96px; }
  .rv dl { grid-template-columns: 1fr; gap: 0 0; }
  .rv dt { margin-top: 6px; }
  .done-card, .dl, .g-hero, .g-enter { padding: 20px; }
  .g-hero { grid-template-columns: 1fr; }
  .g-toc { columns: 1; }
  .g-steps > li { padding-left: 48px; }
  .g-enter form { grid-template-columns: 1fr; }
  .nav .btn.small.ghost { font-size: 0.78em; padding: 0.5em 0.8em; }
  .tfoot .tbtn.ghost + .tbtn.ghost { display: none; }
}

/* Printing the setup guide: plain black on white, one section after another, no buttons. */
@media print {
  @page { margin: 14mm; }
  body { background: #fff !important; color: #000; font-size: 11pt; }
  .nav, .g-tools, .no-print, .os-alt > summary { display: none !important; }
  .os-alt { display: block; }
  .os-alt[data-print=hide] { display: none !important; }
  .guide-main { padding: 0; max-width: none; }
  .g-hero, .g-toc, .g-steps > li, .g-fig, .g-note, .g-trouble details, .g-enter { background: #fff !important; border-color: #bbb !important; color: #000 !important; box-shadow: none; }
  .g-sec { padding-top: 18px; break-before: page; }
  .g-sec.keep { break-before: auto; }
  .g-sec > p, .g-sec li, .g-trouble ol, .g-note { color: #000 !important; }
  .g-steps > li, .g-fig, .g-trouble details, .g-note, tr { break-inside: avoid; }
  .g-steps > li::before { background: #fff; color: #000; }
  .g-steps b, .g-sec strong, .g-toc a { color: #000; }
  .g-hero .facts span, .g-code { background: #fff; color: #000; }
  .g-table th, .g-table td span, .muted { color: #444 !important; }
  .g-fig figcaption { color: #ddd !important; }
  .g-table td, .g-table th { border-color: #bbb; }
  .g-check li::before, .g-table .box i { border-color: #000; }
  .g-fig { background: #0b0c10 !important; print-color-adjust: exact; -webkit-print-color-adjust: exact; }
  .g-trouble details > * { display: block; }
  footer { margin-top: 20px; }
  a { color: #000; }
}
