/* Invisible Team look — same tokens and type as webshop-template (globals.css). */
:root {
  --bg: #ffffff; --fg: #0a0a0a; --muted: #6b6b6b; --line: #e4e4e4; --surface: #f4f4f4;
  --accent: #0a0a0a; --accent-fg: #ffffff;
  --ease: cubic-bezier(.2, .7, .2, 1);
}

* { box-sizing: border-box; }
html, body { margin: 0; }
body {
  min-height: 100dvh; display: flex; flex-direction: column;
  background: var(--bg); color: var(--fg);
  font: 16px/1.5 Geist, system-ui, sans-serif; -webkit-font-smoothing: antialiased;
}
button { font: inherit; color: inherit; cursor: pointer; border-radius: 0; }
[hidden] { display: none !important; }

/* Shared primitives, as in the shop */
.eyebrow, .say, .meta { font-size: 12px; text-transform: uppercase; letter-spacing: .2em; color: var(--muted); }
.lab { display: block; font-size: 12px; text-transform: uppercase; letter-spacing: .15em; color: var(--muted); margin: 0 0 6px; }
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px; height: 48px; padding: 0 28px;
  border: 1px solid var(--accent); background: var(--accent); color: var(--accent-fg);
  font-size: 14px; font-weight: 500; text-transform: uppercase; letter-spacing: .15em; transition: background .2s, opacity .2s;
}
.btn:hover { background: color-mix(in srgb, var(--fg) 80%, transparent); }
.btn.quiet { background: none; border-color: transparent; color: var(--muted); padding: 0; }
.btn.quiet:hover { color: var(--fg); }

.bar { position: fixed; top: 0; left: 0; height: 2px; width: 0; background: var(--fg); transition: width .6s var(--ease); z-index: 50; }

header { position: sticky; top: 0; z-index: 40; border-bottom: 1px solid var(--line); background: color-mix(in srgb, var(--bg) 95%, transparent); backdrop-filter: blur(8px); }
.headin { max-width: 1280px; margin: 0 auto; height: 64px; padding: 0 24px; display: flex; align-items: center; justify-content: space-between; }
.logo { font-weight: 600; text-transform: uppercase; letter-spacing: .35em; white-space: nowrap; color: inherit; text-decoration: none; }
.restart { background: none; border: 0; padding: 0; font-size: 12px; text-transform: uppercase; letter-spacing: .15em; color: var(--muted); }
.restart:hover { color: var(--fg); }

main { flex: 1; width: 100%; max-width: 720px; margin: 0 auto; padding: 8vh 24px 160px; }

/* ── The invisible team member ── */
.ghost { display: flex; gap: 10px; height: 44px; align-items: center; margin-bottom: 28px; animation: float 4s ease-in-out infinite; }
.eye {
  width: 14px; height: 22px; background: var(--fg); border-radius: 50%;
  transform: translate(var(--x, 0), var(--y, 0));
  transition: transform .25s ease-out, height .15s, width .15s, border-radius .2s;
}
body[data-step="intro"] .eye, body[data-step="done"] .eye { width: 20px; height: 32px; }
.ghost.blink .eye { transform: translate(var(--x, 0), var(--y, 0)) scaleY(.1); }
.ghost.happy .eye { height: 12px; width: 18px; background: transparent; border: 4px solid var(--fg); border-bottom: 0; border-radius: 18px 18px 0 0; }
.ghost.listen .eye { animation: bob .45s ease-in-out infinite alternate; }
.ghost.listen .eye + .eye { animation-delay: .22s; }
.ghost.oops .eye { animation: shake .4s; }
.ghost.think .eye { animation: read .7s ease-in-out infinite alternate; } /* eyes scan left-right, like reading */
@keyframes read { from { transform: translate(-5px, -3px); } to { transform: translate(5px, -3px); } }
@keyframes float { 50% { transform: translateY(-6px); } }
@keyframes bob { to { height: 10px; } }

/* ── Step content ── */
.say { margin: 0 0 16px; }
h1 { font-size: clamp(30px, 5vw, 48px); line-height: 1.15; font-weight: 300; margin: 0 0 16px; text-wrap: balance; }
.sub { color: var(--muted); line-height: 1.7; margin: 0 0 8px; max-width: 36em; text-wrap: pretty; }
.meta { margin-top: 32px; }

.options { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; margin-top: 32px; }
.opt {
  display: flex; align-items: center; gap: 14px; text-align: left; min-height: 56px;
  padding: 14px 16px; border: 1px solid var(--line); background: var(--bg);
  transition: border-color .2s, background .2s, color .2s;
}
.opt:hover { border-color: var(--fg); }
.opt.help { border-style: dashed; }
.opt .k { flex: none; width: 22px; height: 22px; display: grid; place-items: center; font: 11px 'Geist Mono', monospace; border: 1px solid var(--line); color: var(--muted); }
.opt .l { display: block; }
.opt .hint { display: block; font-size: 13px; color: var(--muted); }
.opt.on { background: var(--accent); color: var(--accent-fg); border-color: var(--accent); }
.opt.on .k { border-color: currentColor; color: inherit; }
.opt.on .hint { color: inherit; opacity: .7; }

.fields { margin-top: 32px; max-width: 32rem; }
.field { display: block; margin-bottom: 20px; }
.inwrap { position: relative; display: block; }
input:not([type=checkbox]):not([type=color]), textarea {
  display: block; width: 100%; font: inherit; font-size: 15px; color: var(--fg); background: var(--bg);
  border: 1px solid var(--line); border-radius: 0; padding: 12px 52px 12px 12px; outline: none; transition: border-color .2s;
}
textarea { min-height: 112px; resize: vertical; line-height: 1.6; }
input:focus, textarea:focus { border-color: var(--fg); }
::placeholder { color: var(--muted); opacity: .6; }
.count { display: block; margin-top: 4px; text-align: right; font: 11px 'Geist Mono', monospace; color: var(--muted); }

.mic {
  position: absolute; right: 6px; top: 6px; width: 34px; height: 34px;
  display: grid; place-items: center; border: 1px solid var(--line); background: var(--bg); transition: background .2s, color .2s;
}
.mic:hover { border-color: var(--fg); }
.mic.on { background: var(--fg); color: var(--bg); border-color: var(--fg); animation: pulse 1.2s infinite; }
@keyframes pulse { from { box-shadow: 0 0 0 0 color-mix(in srgb, var(--fg) 35%, transparent); } to { box-shadow: 0 0 0 12px transparent; } }

.linkrow { display: grid; grid-template-columns: 130px 1fr; align-items: center; gap: 12px; margin-bottom: 8px; }
.linkrow .lab { margin: 0; }
.linkrow input { padding-right: 12px !important; }

/* "I don't know" buttons = the shop's outline button, dashed */
.ghostbtn {
  display: inline-flex; align-items: center; height: 44px; margin-top: 16px; padding: 0 20px;
  border: 1px dashed var(--muted); background: none; color: var(--muted);
  font-size: 12px; text-transform: uppercase; letter-spacing: .15em; transition: all .2s;
}
.ghostbtn:hover { border-color: var(--fg); color: var(--fg); }
.ghostbtn.on { background: var(--accent); color: var(--accent-fg); border: 1px solid var(--accent); }

.consent { display: flex; gap: 12px; align-items: flex-start; font-size: 14px; line-height: 1.6; color: var(--muted); cursor: pointer; }
.consent input { width: 18px; height: 18px; margin-top: 2px; accent-color: var(--fg); flex: none; }

/* ── Colours & vibe ── */
.swatches { display: flex; flex-wrap: wrap; gap: 14px; margin-top: 32px; }
.swwrap { display: flex; flex-direction: column; align-items: center; gap: 6px; }
.sw { position: relative; width: 68px; height: 68px; border: 1px solid var(--line); }
.sw input { position: absolute; inset: 0; width: 100%; height: 100%; opacity: 0; cursor: pointer; }
.sw .x { position: absolute; top: -9px; right: -9px; width: 22px; height: 22px; padding: 0; border: 1px solid var(--line); background: var(--bg); font-size: 14px; line-height: 1; }
.hex { font: 11px 'Geist Mono', monospace; color: var(--muted); text-transform: uppercase; }
.add { width: 68px; height: 68px; border: 1px dashed var(--muted); background: none; font-size: 24px; font-weight: 300; color: var(--muted); }
.add:hover { border-color: var(--fg); color: var(--fg); }
.step-colors .lab { margin-top: 32px; }
.chips { display: flex; flex-wrap: wrap; gap: 8px; }
.chip { height: 40px; padding: 0 16px; border: 1px solid var(--line); background: none; font-size: 12px; text-transform: uppercase; letter-spacing: .15em; transition: all .2s; }
.chip:hover { border-color: var(--fg); }
.chip.on { background: var(--accent); color: var(--accent-fg); border-color: var(--accent); }

/* ── Summary ── */
.summary { margin: 32px 0 0; border-top: 1px solid var(--line); }
.summary .row { display: grid; grid-template-columns: 170px 1fr; gap: 16px; padding: 14px 0; border-bottom: 1px solid var(--line); }
.summary dt { font-size: 12px; text-transform: uppercase; letter-spacing: .15em; color: var(--muted); padding-top: 3px; }
.summary dd { margin: 0; white-space: pre-line; overflow-wrap: anywhere; }

/* ── Bottom nav ── */
nav { position: fixed; left: 0; right: 0; bottom: 0; z-index: 30; border-top: 1px solid var(--line); background: color-mix(in srgb, var(--bg) 95%, transparent); backdrop-filter: blur(8px); padding: 12px 24px calc(12px + env(safe-area-inset-bottom)); }
.navin { max-width: 672px; margin: 0 auto; display: flex; align-items: center; justify-content: space-between; gap: 12px; }
#next { margin-left: auto; }
.toast { flex: 1; margin: 0; text-align: center; font-size: 13px; opacity: 0; transform: translateY(6px); transition: all .3s var(--ease); }
.toast.show { opacity: 1; transform: none; }

/* ── Motion: things materialise out of thin air ── */
.reveal { opacity: 0; filter: blur(10px); transform: translateY(10px); animation: materialise .7s var(--ease) forwards; animation-delay: calc(var(--d, 0) * 55ms); }
@keyframes materialise { to { opacity: 1; filter: none; transform: none; } }
.stage.leave { animation: vanish .22s forwards; }
@keyframes vanish { to { opacity: 0; filter: blur(10px); transform: translateY(-8px); } }
.stage.shake { animation: shake .4s; }
@keyframes shake { 25% { translate: -6px 0; } 50% { translate: 6px 0; } 75% { translate: -3px 0; } }

.bit { position: fixed; top: -12px; width: 8px; height: 8px; background: var(--fg); z-index: 60; pointer-events: none; animation: fall var(--t) linear forwards; }
@keyframes fall { to { transform: translate(var(--dx), 105vh) rotate(540deg); opacity: 0; } }

@media (max-width: 560px) {
  .headin { padding: 0 16px; }
  .logo { letter-spacing: .25em; font-size: 14px; }
  main { padding: 5vh 16px 140px; }
  nav { padding-left: 16px; padding-right: 16px; }
  .options { grid-template-columns: 1fr; }
  .opt .k { display: none; }
  .linkrow { grid-template-columns: 1fr; gap: 0; margin-bottom: 14px; }
  .linkrow .lab { margin-bottom: 6px; }
  .summary .row { grid-template-columns: 1fr; gap: 2px; }
  .btn { padding: 0 20px; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; }
  .reveal { opacity: 1; filter: none; transform: none; }
}
