/* WickBrand studio. One type family, one accent, the email is the hero. */
:root {
  --wall: #EEF0F4; --wall-2: #E4E7EE; --sheet: #fff; --ink: #11131A; --muted: #5F6578; --faint: #9AA0B2;
  --line: #D9DCE6; --line-2: #C7CBD8; --pen: #1F3FE0; --on-pen: #fff; --pen-wash: #E6EAFD; --pen-deep: #1733B8;
  --signal: #FFD84D; --on-signal: #241C00; --ok: #117A4F;
  --r: 14px; --r-sm: 10px; --lift: 0 22px 44px -30px rgba(17,19,26,.35);
}
* { box-sizing: border-box; }
[hidden] { display: none !important; }
html { color-scheme: light; scroll-behavior: smooth; }
body { margin: 0; background: var(--wall); color: var(--ink); font-family: 'Schibsted Grotesk', 'Helvetica Neue', Arial, sans-serif; font-size: 15px; line-height: 1.5; -webkit-font-smoothing: antialiased; }
h1, h2, p { margin: 0; }
button, input, textarea, output { font: inherit; color: inherit; }
button { cursor: pointer; }
:focus-visible { outline: 2px solid var(--pen); outline-offset: 2px; }
@media (prefers-reduced-motion: reduce) { *, *::before, *::after { transition: none !important; animation: none !important; } }

/* top bar */
.top { background: var(--wall); border-bottom: 1px solid var(--line); position: sticky; top: 0; z-index: 20; }
.top .wrap { display: flex; align-items: center; justify-content: space-between; height: 52px; max-width: 1480px; margin-inline: auto; padding-inline: 20px; }
.wm { font-weight: 800; font-size: 19px; letter-spacing: -.03em; color: var(--ink); text-decoration: none; }
.wm::before { content: ""; display: inline-block; width: 10px; height: 10px; border-radius: 3px; background: var(--pen); margin-right: 8px; transform: rotate(45deg) translateY(-1px); }
.top-note { font-size: 13px; color: var(--muted); }
.foot { border-top: 1px solid var(--line); margin-top: 40px; padding-block: 20px 36px; font-size: 13px; color: var(--muted); }
.foot .wrap { max-width: 1480px; margin-inline: auto; padding-inline: 20px; }

/* shared controls */
.field { display: flex; flex-direction: column; gap: 5px; min-width: 0; }
.field > span:first-child { font-size: 12.5px; font-weight: 600; color: var(--muted); }
.field .opt { font-weight: 500; color: var(--faint); margin-left: 4px; }
.field input[type="text"], .field input[type="url"] { height: 44px; border: 1px solid transparent; background: var(--wall); border-radius: 12px; padding: 0 14px; width: 100%; min-width: 0; font-size: 15px; transition: background .15s, border-color .15s, box-shadow .15s; }
.field input:hover { background: var(--wall-2); }
.field input:focus { background: var(--sheet); border-color: var(--pen); box-shadow: 0 0 0 3px var(--pen-wash); outline: none; }
.brain .field input { background: var(--wall); }
.swatch { display: flex; align-items: center; gap: 10px; height: 40px; border: 1px solid var(--line); background: var(--sheet); border-radius: var(--r-sm); padding: 0 12px 0 6px; }
.swatch input[type="color"] { width: 28px; height: 28px; border: 0; padding: 0; background: none; border-radius: 8px; overflow: hidden; cursor: pointer; }
.swatch input[type="color"]::-webkit-color-swatch-wrapper { padding: 0; }
.swatch input[type="color"]::-webkit-color-swatch { border: 0; border-radius: 8px; }
.swatch output { font-size: 13px; color: var(--muted); font-variant-numeric: tabular-nums; }
.row { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.hint { font-size: 13px; color: var(--muted); }
.hint.bad { color: #B3261E; }
.btn { height: 40px; display: inline-flex; align-items: center; justify-content: center; gap: 8px; border: 1px solid var(--line-2); background: var(--sheet); border-radius: 999px; padding: 0 18px; font-weight: 700; font-size: 14px; text-decoration: none; color: var(--ink); white-space: nowrap; transition: background .15s, border-color .15s, transform .08s; }
.btn:hover { background: var(--wall); }
.btn:active { transform: translateY(1px); }
.btn.primary { background: var(--pen); border-color: var(--pen); color: var(--on-pen); }
.btn.primary:hover { background: var(--pen-deep); border-color: var(--pen-deep); }
.btn.big { height: 48px; padding: 0 24px; font-size: 15px; }
.btn.small { height: 32px; padding: 0 12px; font-size: 13px; }
.btn[disabled] { opacity: .6; cursor: progress; }
.up { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; padding: 2px 0 2px; }
.up .hint { flex-basis: 100%; }
.thumb { height: 40px; max-width: 120px; object-fit: contain; border: 1px solid var(--line); border-radius: 8px; background: #fff; padding: 2px; }
.thumb.round { width: 40px; border-radius: 50%; object-fit: cover; padding: 0; }

/* option tiles (QR choices, motion style) */
.qr, .styles { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.style { display: flex; gap: 10px; align-items: flex-start; border: 1px solid var(--line); background: var(--sheet); border-radius: var(--r-sm); padding: 10px 12px; cursor: pointer; transition: border-color .15s, background .15s; }
.style:hover { border-color: var(--line-2); }
.style:has(input:checked) { border-color: var(--pen); box-shadow: 0 0 0 1px var(--pen); background: var(--pen-wash); }
.style input { margin: 3px 0 0; accent-color: var(--pen); }
.style span { display: flex; flex-direction: column; gap: 1px; min-width: 0; }
.style b { font-size: 14px; }
.style small { font-size: 12px; color: var(--muted); }

/* ===== studio ===== */
.studio { display: grid; grid-template-columns: 400px minmax(0, 1fr); gap: 32px; max-width: 1240px; margin-inline: auto; padding: 28px 24px 10px; align-items: start; }

.panel { display: flex; flex-direction: column; gap: 16px; }
.brain { display: flex; flex-wrap: wrap; align-items: end; gap: 8px 10px; background: var(--sheet); border-radius: 18px; padding: 16px 18px 14px; box-shadow: 0 0 0 1px var(--line); }
.brain .grow { flex: 1 1 180px; }
.brain .hint { flex-basis: 100%; font-size: 12.5px; }

.kit { background: var(--sheet); border-radius: 18px; box-shadow: 0 0 0 1px var(--line), var(--lift); padding: 18px 22px 20px; display: flex; flex-direction: column; gap: 16px; min-height: 520px; }
.stepper { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(4, 1fr); gap: 6px; }
.stepper button { width: 100%; border: 0; background: none; display: flex; flex-direction: column; align-items: flex-start; gap: 8px; padding: 0 0 10px; font-size: 13px; font-weight: 700; color: var(--faint); border-bottom: 3px solid var(--line); border-radius: 0; transition: color .15s, border-color .15s; }
.stepper button:hover { color: var(--muted); }
.stepper button[aria-current="step"] { color: var(--ink); border-bottom-color: var(--pen); }
.dot { width: 24px; height: 24px; border-radius: 50%; display: inline-flex; align-items: center; justify-content: center; font-size: 12px; font-weight: 800; color: var(--muted); background: var(--wall); transition: all .2s; }
.stepper button[aria-current="step"] .dot { background: var(--pen); color: #fff; }
.stepper button.done .dot, .ready.done .dot { background: var(--ok); color: #fff; font-size: 0; }
.stepper button.done .dot::after, .ready.done .dot::after { content: "✓"; font-size: 13px; }
.step { display: flex; flex-direction: column; gap: 14px; flex: 1; }
.step h2 { font-size: 22px; font-weight: 800; letter-spacing: -.025em; line-height: 1.1; margin: 4px 0 0; }
.step .lead { color: var(--muted); font-size: 14px; margin: -8px 0 2px; max-width: 42ch; }
.nav { display: flex; align-items: center; gap: 10px; padding-top: 6px; border-top: 1px solid var(--line); }
.nav-gap { flex: 1; }
.link { border: 0; background: none; color: var(--pen); font-size: 13px; font-weight: 600; padding: 0; text-decoration: underline; text-underline-offset: 2px; cursor: pointer; }

/* colours as two big dots, not hex boxes */
.colors { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.colour { position: relative; display: flex; align-items: center; gap: 12px; background: var(--wall); border-radius: 12px; padding: 8px 12px 8px 8px; cursor: pointer; }
.colour:hover { background: var(--wall-2); }
.colour input[type="color"] { position: absolute; inset: 0; width: 100%; height: 100%; opacity: 0; cursor: pointer; }
.colour-dot { width: 40px; height: 40px; border-radius: 50%; box-shadow: inset 0 0 0 2px rgba(0,0,0,.08); flex: none; }
.colour:has(#bPrimary) .colour-dot { background: var(--c1, #0b1e4b); }
.colour:has(#bAccent) .colour-dot { background: var(--c2, #b02a4f); }
.colour-text { display: flex; flex-direction: column; line-height: 1.2; pointer-events: none; }
.colour-text b { font-size: 13.5px; }
.colour-text output { font-size: 12.5px; color: var(--muted); font-variant-numeric: tabular-nums; }

/* social networks as toggles */
.socs { display: flex; flex-wrap: wrap; gap: 8px; }
.soc { display: inline-flex; align-items: center; gap: 8px; height: 40px; padding: 0 14px 0 10px; border: 1px solid var(--line); background: var(--sheet); border-radius: 999px; font-size: 13.5px; font-weight: 600; color: var(--muted); transition: all .15s; }
.soc img { width: 18px; height: 18px; opacity: .8; }
.soc:hover { border-color: var(--line-2); color: var(--ink); }
.soc[aria-pressed="true"] { background: var(--ink); border-color: var(--ink); color: #fff; }
.soc[aria-pressed="true"] img { filter: invert(1) brightness(2); opacity: 1; }

/* switch */
.switch { display: flex; align-items: center; gap: 14px; background: var(--wall); border-radius: 12px; padding: 12px 14px; cursor: pointer; }
.switch input { position: absolute; opacity: 0; width: 0; height: 0; }
.track { width: 44px; height: 26px; border-radius: 999px; background: var(--line-2); position: relative; flex: none; transition: background .2s; }
.track::after { content: ""; position: absolute; top: 3px; left: 3px; width: 20px; height: 20px; border-radius: 50%; background: #fff; box-shadow: 0 1px 3px rgba(0,0,0,.25); transition: transform .2s; }
.switch input:checked + .track { background: var(--pen); }
.switch input:checked + .track::after { transform: translateX(18px); }
.switch input:focus-visible + .track { outline: 2px solid var(--pen); outline-offset: 2px; }
.switch-text { display: flex; flex-direction: column; line-height: 1.2; }
.switch-text b { font-size: 14px; }
.switch-text small { font-size: 12.5px; color: var(--muted); }
#banFields { display: flex; flex-direction: column; gap: 12px; }
.up { padding: 0; }

/* stage */
.stage { position: sticky; top: 68px; display: flex; flex-direction: column; gap: 14px; min-width: 0; }
.pickers { display: flex; flex-direction: column; gap: 14px; }
.picker { display: flex; flex-direction: column; gap: 8px; }
.picker-head { display: flex; align-items: baseline; gap: 10px; }
.picker-head b { font-size: 14px; }
.picker-head small { font-size: 12.5px; color: var(--muted); }
.tiles { display: grid; gap: 10px; }
.tiles.looks { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.tiles.lays { grid-template-columns: repeat(5, minmax(0, 1fr)); }
.tile { display: flex; flex-direction: column; gap: 6px; padding: 0; border: 0; background: none; text-align: left; min-width: 0; border-radius: 14px; }
.tile-paper { display: block; position: relative; height: 92px; background: var(--sheet); border-radius: 12px; box-shadow: 0 0 0 1px var(--line); overflow: hidden; transition: box-shadow .15s, transform .15s; }
.tile-zoom { position: absolute; left: 8px; top: 8px; display: block; width: 500px; pointer-events: none; }
.tile-zoom > table { pointer-events: none; }
.tile-paper::after { content: ""; position: absolute; inset: 0; background: linear-gradient(to bottom, transparent 70%, #fff 100%); pointer-events: none; }
.tile:hover .tile-paper { box-shadow: 0 0 0 1px var(--line-2), 0 10px 20px -16px rgba(17,19,26,.4); transform: translateY(-1px); }
.tile[aria-pressed="true"] .tile-paper { box-shadow: 0 0 0 2px var(--pen), 0 12px 24px -16px rgba(31,63,224,.5); }
.tile[aria-pressed="true"] .tile-paper::before { content: "✓"; position: absolute; right: 8px; top: 8px; z-index: 2; width: 20px; height: 20px; border-radius: 50%; background: var(--pen); color: #fff; font-size: 12px; font-weight: 800; display: flex; align-items: center; justify-content: center; }
.tile-text { display: flex; flex-direction: column; line-height: 1.2; padding: 0 2px; }
.tile-text b { font-size: 13.5px; }
.tile-text small { font-size: 11.5px; color: var(--muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.tile[aria-pressed="true"] .tile-text b { color: var(--pen); }
.tile:focus-visible { outline: none; }
.tile:focus-visible .tile-paper { box-shadow: 0 0 0 2px var(--pen), 0 0 0 5px var(--pen-wash); }

.inbox { background: var(--sheet); border-radius: 18px; box-shadow: 0 0 0 1px var(--line), var(--lift); overflow: hidden; }
.inbox-bar { display: flex; align-items: center; gap: 6px; height: 40px; padding: 0 14px; background: var(--wall-2); border-bottom: 1px solid var(--line); }
.winbtn { width: 10px; height: 10px; border-radius: 50%; background: var(--line-2); }
.inbox-title { margin-left: 10px; font-size: 13px; color: var(--muted); flex: 1; }
.device { display: inline-flex; background: var(--sheet); border-radius: 999px; border: 1px solid var(--line); padding: 2px; }
.dev-btn { border: 0; background: none; border-radius: 999px; height: 24px; padding: 0 10px; font-size: 12px; font-weight: 700; color: var(--muted); }
.dev-btn[aria-pressed="true"] { background: var(--ink); color: #fff; }
.paper { padding: 22px 26px 30px; min-height: 360px; overflow: auto; transition: max-width .25s; }
.inbox.phone .paper { max-width: 375px; margin-inline: auto; border-inline: 1px solid var(--line); padding: 18px 16px 26px; }
.mail-head { border-bottom: 1px solid var(--line); padding-bottom: 10px; margin-bottom: 16px; font-size: 13px; display: flex; flex-direction: column; gap: 3px; }
.mh-k { color: var(--faint); display: inline-block; width: 58px; }
.mh-v { color: var(--ink); }
.paper-msg { font-family: Arial, Helvetica, sans-serif; font-size: 14px; line-height: 1.5; color: #15171d; margin-bottom: 18px; }
#sigOut { min-width: 0; overflow: auto; }

.stage-foot { display: flex; align-items: center; justify-content: space-between; gap: 16px; flex-wrap: wrap; background: var(--sheet); border-radius: var(--r); box-shadow: 0 0 0 1px var(--line); padding: 12px 14px 12px 16px; }
.ready { display: flex; align-items: center; gap: 12px; min-width: 0; }
.ready > span:last-child { display: flex; flex-direction: column; }
.ready b { font-size: 15px; }
.ready small { font-size: 12.5px; color: var(--muted); }

/* ===== install page ===== */
.wrap { max-width: 1180px; margin-inline: auto; padding-inline: 20px; }
.install { padding-block: 32px 10px; display: flex; flex-direction: column; gap: 18px; }
.install h1 { font-size: clamp(28px, 4.6vw, 40px); font-weight: 800; letter-spacing: -.035em; line-height: 1.05; }
.install .paper { background: #fff; border-radius: 18px; box-shadow: 0 0 0 1px var(--line), var(--lift); }
.actions { display: flex; flex-wrap: wrap; align-items: center; gap: 10px; }
.dev summary { cursor: pointer; font-size: 13px; color: var(--muted); font-weight: 600; }
.dev[open] summary { margin-bottom: 10px; }
.dev .btn { margin-bottom: 8px; }
.code { width: 100%; height: 140px; border: 1px solid var(--line); border-radius: 12px; background: var(--sheet); padding: 10px; font-family: ui-monospace, Menlo, Consolas, monospace; font-size: 12px; resize: vertical; }
.move { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 12px 24px; background: var(--sheet); border-radius: var(--r); padding: 16px 18px; box-shadow: 0 0 0 1px var(--line); }
.move-text { flex: 1 1 320px; min-width: 0; }
.move h2 { font-size: 16px; font-weight: 800; margin: 0 0 4px; }
.move p { font-size: 14px; color: var(--muted); max-width: 60ch; }
.styles { margin-top: 12px; grid-template-columns: repeat(auto-fit, minmax(min(100%, 220px), 1fr)); }
.tier { display: inline-block; border-radius: 6px; padding: 2px 7px; font-size: 12px; font-weight: 700; margin-left: 8px; vertical-align: 1px; background: var(--signal); color: var(--on-signal); }
.steps { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 280px), 1fr)); gap: 16px; }
.steps h2 { grid-column: 1 / -1; margin: 6px 0 0; font-size: 16px; font-weight: 800; }
.install .step { background: var(--sheet); border-radius: var(--r); padding: 14px 16px; box-shadow: 0 0 0 1px var(--line); }
.install .step ol { margin: 6px 0 0; padding-left: 18px; display: flex; flex-direction: column; gap: 4px; font-size: 14px; }

@media (max-width: 700px) { .top-note { display: none; } }

/* ===== small screens ===== */
@media (max-width: 960px) {
  .studio { grid-template-columns: minmax(0, 1fr); gap: 18px; padding-top: 16px; }
  .stage { position: static; order: -1; }
  .kit { min-height: 0; padding: 16px; }
  .stepper button span.dot { width: 22px; height: 22px; }
  .tiles { display: flex; overflow-x: auto; scrollbar-width: none; padding: 2px; margin: -2px; }
  .tiles::-webkit-scrollbar { display: none; }
  .tile { flex: 0 0 150px; }
  .row, .qr { grid-template-columns: 1fr; }
  .stage-foot { position: sticky; bottom: 10px; z-index: 10; box-shadow: 0 0 0 1px var(--line), var(--lift); }
}
