/* BUDDY's shop: the page is the device. Its top bar, its five tabs at the bottom, its screens in between.
   Colours are the firmware's (firmware/src/ui.cpp): AMBER FFB547, SAGE 8DB384, BG 0C0B09; NO and ERROR are its red;
   the light bar's are LED_PAL's (amber FF961E, red E62828, blue 2878FF, green 3CC850).
   The type is the device's too: DejaVu, subset to Latin (fonts/DEJAVU-LICENSE.txt). The stitches are the mark's
   pocket (brand/buddypocket-mark.svg: dashes of 8, gaps of 6). */
@font-face { font-family: "DejaVu Sans"; src: url("/fonts/dejavusans.woff2") format("woff2"); font-weight: 400; font-display: swap; }
@font-face { font-family: "DejaVu Sans"; src: url("/fonts/dejavusans-bold.woff2") format("woff2"); font-weight: 700; font-display: swap; }
@font-face { font-family: "DejaVu Sans Mono"; src: url("/fonts/dejavusansmono.woff2") format("woff2"); font-weight: 400; font-display: swap; }

:root {
  --bg: #0C0B09;
  --panel: #14120E;
  --line: #2B2620;
  --paper: #EFE9DD;
  --soft: #D3CBBC;
  --muted: #9C9384;
  --amber: #FFB547;
  --sage: #8DB384;
  --red: #E0704F;
  --led-amber: #FF961E;
  --led-red: #E62828;
  --led-blue: #2878FF;
  --led-green: #3CC850;
  --max: 1180px;
  --side: max(1rem, calc((100vw - var(--max)) / 2));
  --mono: "DejaVu Sans Mono", ui-monospace, monospace;
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: 4.5rem; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--paper);
  font: 400 17px/1.6 "DejaVu Sans", system-ui, sans-serif;
  overflow-x: clip;
  padding-bottom: 4.6rem; /* room for the tabs */
}
body.form-page { padding-bottom: 0; }
img, video { display: block; max-width: 100%; height: auto; }
a { color: var(--amber); }
h1, h2, h3 { line-height: 1.15; margin: 0 0 .55em; letter-spacing: -.01em; }
h1 { font-size: clamp(2.1rem, 4.2vw, 3.4rem); }
h1 em { font-style: normal; color: var(--amber); display: block; }
h2 { font-size: clamp(1.6rem, 3.1vw, 2.4rem); }
h3 { font-size: 1.05rem; color: var(--amber); letter-spacing: .02em; }
p { margin: 0 0 1em; }
figure { margin: 0; }
.copy p, .sub { color: var(--soft); }
.sub { max-width: 46em; }

/* the device's spaced capitals: PERMISSION, AGENTS, BUDDY XL */
.label {
  font-family: var(--mono); letter-spacing: .32em; font-size: .8rem; color: var(--amber);
  margin-bottom: 1.4rem;
}

/* top bar, as on the device */
.bar {
  position: sticky; top: 0; z-index: 10;
  display: flex; align-items: center; justify-content: space-between; gap: .8rem;
  padding: .55rem var(--side);
  background: rgba(12, 11, 9, .9);
  backdrop-filter: blur(8px);
  border-bottom: 1px solid var(--line);
}
.brand { display: flex; align-items: center; gap: .55rem; color: var(--paper); text-decoration: none; font-weight: 700; letter-spacing: .14em; font-size: .95rem; }
.status { display: flex; align-items: center; gap: .8rem; color: var(--sage); }
.needs {
  font-family: var(--mono); font-size: .8rem; letter-spacing: .08em; white-space: nowrap;
  color: #1A1206; background: var(--amber); text-decoration: none;
  padding: .2rem .75rem; border-radius: 99px;
}
.needs:hover, .needs:focus-visible { background: #FFC56E; }
.ico { width: 22px; height: 22px; }
.batt { position: relative; width: 26px; height: 13px; border: 2px solid var(--sage); border-radius: 3px; }
.batt::after { content: ""; position: absolute; right: -5px; top: 2px; width: 3px; height: 5px; background: var(--sage); border-radius: 0 1px 1px 0; }
.batt i { position: absolute; inset: 1.5px; right: 20%; background: var(--sage); border-radius: 1px; }
.pct { font-size: .85rem; color: var(--soft); }

/* the tabs, as on the device: fixed at the bottom */
.tabs {
  position: fixed; left: 50%; bottom: 0; z-index: 10; transform: translateX(-50%);
  width: min(100%, 680px);
  display: grid; grid-template-columns: repeat(5, 1fr);
  background: rgba(20, 18, 14, .94); backdrop-filter: blur(8px);
  border: 1px solid var(--line); border-bottom: 0; border-radius: 14px 14px 0 0;
}
.tabs a {
  position: relative; display: flex; flex-direction: column; align-items: center; gap: .15rem;
  padding: .55rem 0 .5rem; color: #7E776B; text-decoration: none;
  font-family: var(--mono); font-size: .66rem; letter-spacing: .2em;
}
.tabs svg { width: 24px; height: 24px; }
.tabs a::before { content: ""; position: absolute; top: -1px; left: 22%; right: 22%; height: 3px; border-radius: 0 0 3px 3px; background: transparent; }
.tabs a:hover, .tabs a:focus-visible { color: var(--paper); }
.badge {
  position: absolute; top: .25rem; left: calc(50% + 6px);
  min-width: 1.1rem; height: 1.1rem; border-radius: 99px; background: var(--amber); color: #1A1206;
  font-size: .62rem; letter-spacing: 0; line-height: 1.1rem; text-align: center; font-weight: 700;
}
/* the open tab is the section last jumped to; HOME when none; TOGETHER and INSIDE belong to SHOP */
body:not(:has(section:target)) .tabs a[href="#home"],
body:has(#home:target) .tabs a[href="#home"],
body:has(#agents:target) .tabs a[href="#agents"],
body:has(#xl:target) .tabs a[href="#xl"],
body:has(#pocket:target) .tabs a[href="#pocket"],
body:has(#together:target) .tabs a[href="#shop"],
body:has(#shop:target) .tabs a[href="#shop"],
body:has(#inside:target) .tabs a[href="#shop"] { color: var(--amber); }
body:not(:has(section:target)) .tabs a[href="#home"]::before,
body:has(#home:target) .tabs a[href="#home"]::before,
body:has(#agents:target) .tabs a[href="#agents"]::before,
body:has(#xl:target) .tabs a[href="#xl"]::before,
body:has(#pocket:target) .tabs a[href="#pocket"]::before,
body:has(#together:target) .tabs a[href="#shop"]::before,
body:has(#shop:target) .tabs a[href="#shop"]::before,
body:has(#inside:target) .tabs a[href="#shop"]::before { background: var(--amber); }

main > section { padding: clamp(3rem, 6vw, 5rem) var(--side); }

/* the pocket's stitching between the screens */
.stitch {
  height: 3px; margin: 0 var(--side);
  background: repeating-linear-gradient(90deg, rgba(255, 181, 71, .45) 0 8px, transparent 8px 14px);
  border-radius: 2px;
}

.btn {
  display: inline-block; padding: .85rem 1.6rem; border-radius: 12px; border: 2px solid var(--amber);
  background: var(--amber); color: #1A1406; font: 400 .95rem/1.2 var(--mono); letter-spacing: .1em; text-decoration: none;
  cursor: pointer; text-align: center;
}
.btn:hover, .btn:focus-visible { background: #FFC56E; border-color: #FFC56E; }
.btn.ghost { background: transparent; color: var(--amber); }
.btn.ghost:hover, .btn.ghost:focus-visible { background: rgba(255, 181, 71, .12); }
.center { text-align: center; margin-top: 2.2rem; }

/* HOME */
.home { display: grid; grid-template-columns: 1fr 1.25fr; gap: clamp(1.5rem, 4vw, 3.5rem); align-items: center; }
.clock { width: min(100%, 330px); margin-bottom: .9rem; }
.date { font-family: var(--mono); color: var(--sage); font-size: .85rem; letter-spacing: .1em; margin-bottom: 1.1rem; }
.lead { font-size: 1.1rem; color: var(--soft); max-width: 34em; }
.cta { display: flex; flex-wrap: wrap; gap: .8rem; margin: 1.6rem 0 .9rem; }
.free { font-size: .88rem; color: var(--muted); }
.home-pic img, .pic img { border-radius: 22px; box-shadow: 0 30px 80px rgba(0, 0, 0, .6); }

/* AGENTS: the request, built like the device's, with a YES that really has to be held */
.ask { display: grid; grid-template-columns: 1fr 1fr; gap: clamp(1.5rem, 5vw, 4rem); align-items: center; }
.req {
  background: #050504; border: 2px dashed rgba(255, 181, 71, .5); border-radius: 18px;
  padding: 1.2rem 1.3rem 1rem; max-width: 520px; width: 100%; justify-self: center;
  transform: rotate(.8deg);
}
.req p { margin: 0; }
.req-top { display: flex; justify-content: space-between; font-family: var(--mono); font-size: .78rem; letter-spacing: .25em; color: var(--amber); }
.muted { color: var(--muted); letter-spacing: .02em; }
.req-who { font-family: var(--mono); font-size: 1.7rem; color: var(--amber); line-height: 1.3; margin-top: .2rem !important; }
.req-what { color: var(--muted); font-size: 1.05rem; }
.req-cmd {
  font-family: var(--mono); font-size: 1rem; color: var(--paper); white-space: pre-wrap;
  background: #0D0C0A; border: 1px solid var(--line); border-radius: 10px;
  padding: .8rem .9rem 2.6rem; margin: .8rem 0;
}
.req-keys { display: grid; grid-template-columns: 1fr 1fr; gap: .8rem; }
.req-keys button {
  position: relative; overflow: hidden;
  font: 400 1.5rem/1.1 var(--mono); padding: .8rem 0 .55rem; border-radius: 12px; cursor: pointer;
  -webkit-user-select: none; user-select: none; touch-action: manipulation; -webkit-touch-callout: none;
}
.req-keys small { display: block; font-size: .6rem; letter-spacing: .3em; margin-top: .35rem; opacity: .8; }
.no { color: var(--red); background: #241410; border: 2px solid var(--red); }
.no:active { background: #3A1A12; }
.yes { color: var(--sage); background: #121A10; border: 2px solid var(--sage); }
.yes .fill { position: absolute; inset: 0; width: 0; background: #9CC493; transition: width .15s ease-out; }
.yes .word, .yes .sent { position: relative; }
.yes .sent {
  position: absolute; inset: 0; display: grid; place-items: center;
  background: #9CC493; color: #0F1A0C; font-size: 1.5rem; opacity: 0;
}
.yes:active .fill { width: 100%; transition: width .7s linear; }
.yes:active .word { color: #0F1A0C; transition: color 0s .35s; }
.yes:active .sent { animation: sent 0s .7s forwards; }
@keyframes sent { to { opacity: 1; } }
.req-try { text-align: center; font-size: .82rem; color: var(--muted); margin-top: .7rem !important; }

.talk { display: grid; grid-template-columns: 1.15fr 1fr; gap: clamp(1.5rem, 5vw, 4rem); align-items: center; margin-top: clamp(3rem, 7vw, 5.5rem); }

/* a screen of the device's own pixels, in a dark bezel like the case's */
.glass {
  background: #070706; border: 1px solid #2A2722; border-radius: 18px; padding: clamp(.5rem, 1.6vw, 1rem);
  box-shadow: 0 24px 60px rgba(0, 0, 0, .55), inset 0 0 0 4px #121110;
}
.glass img { border-radius: 4px; width: 100%; }
.talk .glass { transform: rotate(-.7deg); }
.flip .glass { transform: rotate(.9deg) translateY(4px); }

/* the AGENTS grid: each session its state's colour, like the device's cards */
.glance { margin-top: clamp(3rem, 7vw, 5.5rem); }
.sessions { list-style: none; padding: 0; margin: 1.6rem 0 0; display: grid; grid-template-columns: repeat(3, 1fr); gap: .9rem; }
.sessions li {
  --st: var(--paper);
  display: grid; grid-template-columns: 1fr auto; gap: .1rem .6rem;
  background: #0A0908; border: 1px solid var(--line); border-top: 4px solid var(--st); border-radius: 10px;
  padding: .75rem .9rem .9rem; font-family: var(--mono);
}
.sessions b { color: var(--paper); font-weight: 400; font-size: 1.02rem; }
.sessions em { grid-column: 1; font-style: normal; color: var(--st); font-size: .78rem; letter-spacing: .12em; }
.sessions i { grid-row: 1; grid-column: 2; font-style: normal; color: var(--muted); font-size: .78rem; align-self: center; }
.sessions span { grid-column: 1 / -1; color: var(--soft); font-size: .86rem; margin-top: .3rem; }
.sessions .s-wait { --st: var(--amber); }
.sessions .s-ask { --st: #FFC56E; }
.sessions .s-run { --st: var(--sage); }
.sessions .s-done { --st: #E8E2D6; }
.sessions .s-err { --st: var(--red); }

/* BUDDY XL and BUDDYPOCKET: picture and words side by side */
.dev { display: grid; grid-template-columns: 1.2fr 1fr; gap: clamp(1.5rem, 5vw, 4rem); align-items: center; }
.dev + .dev { margin-top: clamp(3rem, 7vw, 5rem); }
.pocket .dev, .dev.flip { grid-template-columns: 1fr 1.2fr; }
.facts { list-style: none; padding: 0; margin: 1.4rem 0 0; display: grid; gap: .9rem; }
.facts li { color: var(--soft); border-left: 2px solid var(--sage); padding-left: 1rem; }
.facts li:nth-child(2) { border-left-color: var(--amber); }
.facts li:nth-child(3) { border-left-color: #6E95D8; }
.facts b { display: block; color: var(--paper); }

/* the games: the device's GAMES cards */
.carts { list-style: none; padding: 0; margin: 2.4rem 0 0; display: grid; grid-template-columns: repeat(4, 1fr); gap: 1rem; }
.carts li {
  display: grid; grid-template-columns: 72px 1fr; gap: .2rem .8rem; align-content: start;
  background: #0A0908; border: 2px solid #5A4421; border-radius: 12px; padding: .7rem;
}
.carts img { grid-row: span 2; width: 72px; image-rendering: pixelated; border-radius: 4px; }
.carts b { font-family: var(--mono); font-weight: 400; font-size: .85rem; letter-spacing: .06em; color: var(--paper); }
.carts span { color: var(--soft); font-size: .85rem; line-height: 1.4; }
.carts li:nth-child(2) { transform: translateY(6px); }
.carts li:nth-child(3) { transform: rotate(-.6deg); }
.carts li:nth-child(4) { transform: translateY(-4px) rotate(.5deg); }

.pocket h2 em { font-style: normal; color: var(--amber); }
.play { display: grid; grid-template-columns: 1fr 1.1fr; gap: clamp(1.5rem, 4vw, 3rem); align-items: center; margin-top: clamp(2.5rem, 6vw, 4rem); }
.play .glass { transform: rotate(-1deg); }
.play .glass img { image-rendering: pixelated; }
.play .carts { grid-template-columns: 1fr 1fr; margin: 0; }

/* LOOKS AFTER YOU: H2O as it is on both, then the break that is coming */
.h2o { display: flex; flex-direction: column; gap: clamp(1rem, 2.5vw, 1.6rem); }
.h2o .big { width: 90%; transform: rotate(.8deg); }
.h2o .small { width: 54%; align-self: flex-end; transform: rotate(-2deg); }
.h2o .small img { image-rendering: pixelated; }
.nudge {
  display: grid; grid-template-columns: minmax(0, 360px) 1fr; gap: clamp(1.5rem, 4vw, 3rem); align-items: center;
  margin-top: clamp(2.5rem, 6vw, 4rem);
}
/* the break, drawn like BOS's own pop-ups (WATER, PERMISSION): dark, spaced capitals, two held keys */
.toast {
  background: #050504; border: 2px dashed rgba(141, 179, 132, .55); border-radius: 18px; padding: 1.1rem 1.2rem 1rem;
  font-family: var(--mono); transform: rotate(-.8deg);
}
.toast p { margin: 0; }
.t-top { letter-spacing: .3em; font-size: .78rem; color: var(--sage); text-align: center; }
.t-say { color: var(--paper); font-size: 1.02rem; line-height: 1.45; margin: .8rem 0 1rem !important; }
.t-keys { display: grid; grid-template-columns: 1fr 1fr; gap: .7rem; }
.t-keys span { text-align: center; padding: .7rem 0; border-radius: 12px; border: 2px solid var(--line); color: var(--soft); letter-spacing: .12em; font-size: .9rem; }
.t-keys .go { background: #8DB384; border-color: #8DB384; color: #0F1A0C; }
.nudge h3 { font-size: 1.3rem; color: var(--paper); }

/* the cards' devices in 3D: the picture until the model is drawn, and for good with no WebGL or no script */
.spin {
  position: relative; aspect-ratio: 3 / 2; margin-bottom: 1rem; border-radius: 12px; overflow: hidden;
  background: radial-gradient(ellipse at 50% 45%, #33291C 0, #17130E 58%, #0E0C0A 100%);
}
.card .spin img { width: 100%; height: 100%; margin: 0; object-fit: cover; border-radius: 0; }
.spin.live img { display: none; }
.spin canvas { position: absolute; inset: 0; width: 100% !important; height: 100% !important; display: block; cursor: grab; }
.spin canvas:active { cursor: grabbing; }
.spin-hint {
  display: none; position: absolute; right: .7rem; bottom: .5rem; margin: 0; pointer-events: none;
  font-family: var(--mono); font-size: .62rem; letter-spacing: .2em; color: var(--muted); transition: opacity .6s;
}
.spin.live .spin-hint { display: block; }
.spin.touched .spin-hint { opacity: 0; }
.spin-open {
  position: absolute; left: .55rem; bottom: .5rem; z-index: 1; display: flex; align-items: center; gap: .45rem;
  min-height: 44px; padding: 0 .9rem; border-radius: 99px; border: 1px solid rgba(255, 181, 71, .55);
  background: rgba(12, 11, 9, .78); color: var(--amber); font: 400 .68rem/1 var(--mono); letter-spacing: .18em; cursor: pointer;
}
.spin-open[hidden] { display: none; }
.spin-open svg { width: 15px; height: 15px; }
.spin-open:hover, .spin-open:focus-visible { background: rgba(255, 181, 71, .16); }

/* the big card: one product in the middle of the screen, its 3D large, its card beside it */
html:has(dialog.view[open]) { overflow: hidden; }
dialog.view {
  width: min(1120px, calc(100vw - 32px)); max-width: none; max-height: calc(100dvh - 32px);
  margin: auto; padding: 0; border: 0; background: transparent; color: var(--paper); overflow: visible;
}
dialog.view::backdrop { background: rgba(6, 5, 4, .8); backdrop-filter: blur(6px); }
.view-card {
  position: relative; display: grid; grid-template-columns: minmax(0, 1.65fr) minmax(0, 1fr);
  max-height: calc(100dvh - 32px); background: var(--panel); border: 2px solid var(--line); border-radius: 20px; overflow: hidden;
}
.view-stage {
  position: relative; min-height: min(72dvh, 660px);
  background: radial-gradient(ellipse at 50% 45%, #3A2E1F 0, #17130E 60%, #0E0C0A 100%);
}
.view-stage canvas { position: absolute; inset: 0; width: 100% !important; height: 100% !important; display: block; cursor: grab; }
.view-stage canvas:active { cursor: grabbing; }
.view-hint {
  position: absolute; left: 1rem; bottom: .8rem; margin: 0; z-index: 1; pointer-events: none; transition: opacity .6s;
  font-family: var(--mono); font-size: .64rem; letter-spacing: .2em; color: var(--muted);
}
.view-stage.touched .view-hint { opacity: 0; }
.view-info { position: relative; display: flex; flex-direction: column; padding: 1.6rem; overflow-y: auto; }
.view-info .flag { position: static; align-self: flex-start; margin: 0 0 .8rem; }
.view-info h3 { font-size: 1.6rem; margin-bottom: .3rem; padding-right: 2.8rem; }
.view-info ul { list-style: none; padding: 0; margin: .4rem 0 1.2rem; color: var(--soft); }
.view-info li { padding: .45rem 0; border-top: 1px dashed #2E2922; }
.view-info .btn { margin-top: auto; }
.view-close {
  position: absolute; top: .7rem; right: .7rem; z-index: 2; width: 44px; height: 44px; display: grid; place-items: center;
  border-radius: 50%; border: 1px solid var(--line); background: rgba(12, 11, 9, .8); color: var(--paper); cursor: pointer;
}
.view-close svg { width: 20px; height: 20px; }
.view-close:hover, .view-close:focus-visible { border-color: var(--amber); color: var(--amber); }
@media (prefers-reduced-motion: no-preference) {
  dialog.view[open] .view-card { animation: view-in .26s ease-out; }
  dialog.view[open]::backdrop { animation: view-dim .26s ease-out; }
}
@keyframes view-in { from { opacity: 0; transform: translateY(10px) scale(.97); } }
@keyframes view-dim { from { opacity: 0; } }
@media (max-width: 760px) {
  dialog.view { width: calc(100vw - 16px); max-height: calc(100dvh - 16px); }
  .view-card { grid-template-columns: 1fr; grid-template-rows: auto minmax(0, 1fr); max-height: calc(100dvh - 16px); }
  .view-stage { min-height: 46dvh; }
  .view-info { padding: 1.1rem; }
  .view-info h3 { padding-right: 0; }
  .view-info h3 { font-size: 1.3rem; }
}
.price .tier { display: block; font-size: .62rem; letter-spacing: .22em; color: var(--amber); margin-bottom: .15rem; }
.later { font-family: var(--mono); font-size: .8rem; color: var(--muted); margin: -.5rem 0 1rem; }

/* TOGETHER: the join, then the light bar to play with */
.together-head { max-width: 52em; }
.soon {
  display: inline-block; font-family: var(--mono); font-size: .8rem; letter-spacing: .04em; color: var(--sage);
  border: 1px dashed rgba(141, 179, 132, .55); border-radius: 10px; padding: .45rem .8rem;
}
.join { margin-top: 1.8rem; border-radius: 22px; overflow: hidden; box-shadow: 0 30px 80px rgba(0, 0, 0, .6); background: #1A1611; }
.join video, .join img { width: 100%; }
.join .still { display: none; }

.lights {
  position: relative; margin-top: clamp(2rem, 5vw, 3rem);
  display: grid; grid-template-columns: 1fr 1.1fr; gap: 1rem 2.5rem; align-items: center;
  background: var(--panel); border: 2px dashed #3A3226; border-radius: 18px; padding: clamp(1rem, 3vw, 1.8rem);
}
.lights > input { position: absolute; opacity: 0; width: 1px; height: 1px; pointer-events: none; }
.lights-copy h3 { margin-bottom: .9rem; }
.chips { display: flex; flex-wrap: wrap; gap: .5rem; }
.chips label {
  font-family: var(--mono); font-size: .76rem; letter-spacing: .14em; color: var(--soft); cursor: pointer;
  border: 1px solid var(--line); border-radius: 99px; padding: .45rem .8rem; background: #0A0908;
  -webkit-user-select: none; user-select: none;
}
.chips label:hover { border-color: var(--muted); color: var(--paper); }
#led-team:checked ~ .lights-copy [for="led-team"], #led-ask:checked ~ .lights-copy [for="led-ask"],
#led-run:checked ~ .lights-copy [for="led-run"], #led-done:checked ~ .lights-copy [for="led-done"],
#led-err:checked ~ .lights-copy [for="led-err"], #led-hello:checked ~ .lights-copy [for="led-hello"] {
  background: var(--amber); border-color: var(--amber); color: #1A1206;
}
#led-team:focus-visible ~ .lights-copy [for="led-team"], #led-ask:focus-visible ~ .lights-copy [for="led-ask"],
#led-run:focus-visible ~ .lights-copy [for="led-run"], #led-done:focus-visible ~ .lights-copy [for="led-done"],
#led-err:focus-visible ~ .lights-copy [for="led-err"], #led-hello:focus-visible ~ .lights-copy [for="led-hello"] {
  outline: 2px solid var(--amber); outline-offset: 3px;
}
/* the cap: frosted, over a dark board, eight LEDs 7 mm apart */
.cap {
  grid-row: span 2; justify-self: stretch;
  background: linear-gradient(#2A2723, #1C1A17); border-radius: 16px; padding: clamp(.9rem, 2.4vw, 1.4rem);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, .06), 0 14px 40px rgba(0, 0, 0, .5);
}
.leds {
  display: grid; grid-template-columns: repeat(8, 1fr); gap: clamp(.35rem, 1.4vw, .8rem);
  background: rgba(225, 222, 214, .08); border: 1px solid rgba(225, 222, 214, .16); border-radius: 10px;
  padding: clamp(.7rem, 2vw, 1.1rem) clamp(.6rem, 1.8vw, 1rem);
}
.leds i { position: relative; aspect-ratio: 1; border-radius: 30%; background: #15130F; --c: transparent; }
.leds i::after {
  content: ""; position: absolute; inset: 0; border-radius: inherit; opacity: 0;
  background: radial-gradient(circle, #fff 0 18%, var(--c) 46%);
  box-shadow: 0 0 10px 3px var(--c), 0 0 26px 8px color-mix(in srgb, var(--c) 45%, transparent);
}
.say { display: none; color: var(--soft); margin: 0; font-size: .95rem; }
#led-team:checked ~ .say-team, #led-ask:checked ~ .say-ask, #led-run:checked ~ .say-run,
#led-done:checked ~ .say-done, #led-err:checked ~ .say-err, #led-hello:checked ~ .say-hello { display: block; }

/* TEAM, as BOS orders it: who asks first, then who failed, who works, who just finished */
#led-team:checked ~ .cap i:nth-child(1), #led-ask:checked ~ .cap i:nth-child(-n+2) { --c: var(--led-amber); }
#led-team:checked ~ .cap i:nth-child(1)::after, #led-ask:checked ~ .cap i:nth-child(-n+2)::after { opacity: .9; animation: heart 1.4s infinite; }
#led-ask:checked ~ .cap i:nth-child(2)::after { animation-delay: .07s; }
#led-team:checked ~ .cap i:nth-child(2), #led-err:checked ~ .cap i:nth-child(1) { --c: var(--led-red); }
#led-team:checked ~ .cap i:nth-child(2)::after, #led-err:checked ~ .cap i:nth-child(1)::after { opacity: .9; animation: blink 1s infinite; }
#led-team:checked ~ .cap i:nth-child(3), #led-team:checked ~ .cap i:nth-child(4), #led-run:checked ~ .cap i:nth-child(-n+4) { --c: var(--led-blue); }
#led-team:checked ~ .cap i:nth-child(3)::after, #led-team:checked ~ .cap i:nth-child(4)::after,
#led-run:checked ~ .cap i:nth-child(-n+4)::after { opacity: .8; animation: breathe 1.5s ease-in-out infinite; }
#led-team:checked ~ .cap i:nth-child(4)::after, #led-run:checked ~ .cap i:nth-child(2)::after { animation-delay: -.3s; }
#led-run:checked ~ .cap i:nth-child(3)::after { animation-delay: -.65s; }
#led-run:checked ~ .cap i:nth-child(4)::after { animation-delay: -1.1s; }
#led-team:checked ~ .cap i:nth-child(5), #led-done:checked ~ .cap i:nth-child(-n+3) { --c: var(--led-green); }
#led-team:checked ~ .cap i:nth-child(5)::after, #led-done:checked ~ .cap i:nth-child(-n+3)::after { opacity: .38; }
/* HELLO: a rainbow lit LED by LED, held, faded */
#led-hello:checked ~ .cap i:nth-child(1) { --c: #FF2A2A; }
#led-hello:checked ~ .cap i:nth-child(2) { --c: #FF9A1F; }
#led-hello:checked ~ .cap i:nth-child(3) { --c: #F2E21C; }
#led-hello:checked ~ .cap i:nth-child(4) { --c: #4CE04C; }
#led-hello:checked ~ .cap i:nth-child(5) { --c: #22D8C8; }
#led-hello:checked ~ .cap i:nth-child(6) { --c: #2F7BFF; }
#led-hello:checked ~ .cap i:nth-child(7) { --c: #8A4BFF; }
#led-hello:checked ~ .cap i:nth-child(8) { --c: #FF3FB8; }
#led-hello:checked ~ .cap i::after { opacity: .9; animation: hello 2.6s infinite both; }
#led-hello:checked ~ .cap i:nth-child(2)::after { animation-delay: .08s; }
#led-hello:checked ~ .cap i:nth-child(3)::after { animation-delay: .16s; }
#led-hello:checked ~ .cap i:nth-child(4)::after { animation-delay: .24s; }
#led-hello:checked ~ .cap i:nth-child(5)::after { animation-delay: .32s; }
#led-hello:checked ~ .cap i:nth-child(6)::after { animation-delay: .4s; }
#led-hello:checked ~ .cap i:nth-child(7)::after { animation-delay: .48s; }
#led-hello:checked ~ .cap i:nth-child(8)::after { animation-delay: .56s; }

/* BOS's moments (blinktfx.h): two beats every 1.4 s and a glow between; on a third of a second; 1.5 s breathing */
@keyframes heart { 0% { opacity: .3; } 5% { opacity: 1; } 18.6% { opacity: .45; } 23.6% { opacity: .8; } 47% { opacity: .3; } 100% { opacity: .3; } }
@keyframes blink { 0% { opacity: 0; } 7% { opacity: 1; } 26% { opacity: 1; } 33% { opacity: 0; } 100% { opacity: 0; } }
@keyframes breathe { 0%, 100% { opacity: .28; } 50% { opacity: 1; } }
@keyframes hello { 0% { opacity: 0; } 6% { opacity: 1; } 62% { opacity: 1; } 84% { opacity: 0; } 100% { opacity: 0; } }

/* HANDMADE IN ITALY: the words, a hand-drawn stamp, three promises that do not overpromise */
.made { margin-top: .6rem; font-family: var(--mono); font-size: .78rem; letter-spacing: .08em; color: var(--sage); }
.italy-head { display: grid; grid-template-columns: minmax(0, 1fr) 210px; gap: clamp(1.5rem, 5vw, 4rem); align-items: center; }
.italy h2 em { font-style: normal; color: var(--amber); }
.stamp { width: 100%; max-width: 210px; color: var(--amber); transform: rotate(-9deg); opacity: .9; }
.promises { list-style: none; padding: 0; margin: clamp(2rem, 5vw, 3rem) 0 0; display: grid; grid-template-columns: repeat(3, 1fr); gap: 1.2rem; }
.promises li { display: flex; flex-direction: column; gap: .5rem; padding: 1.2rem 1.3rem; background: var(--panel); border: 2px solid var(--line); border-radius: 16px; }
.promises b { font-family: var(--mono); font-weight: 400; letter-spacing: .08em; color: var(--paper); }
.promises span { color: var(--soft); line-height: 1.5; }
.promises .btn { margin-top: auto; align-self: flex-start; padding: .6rem 1.1rem; font-size: .85rem; }
.promises li:nth-child(1) { transform: rotate(-.4deg); }
.promises li:nth-child(2) { transform: translateY(8px) rotate(.3deg); }
.promises li:nth-child(3) { transform: rotate(.6deg) translateY(-3px); border-style: dashed; border-color: rgba(255, 181, 71, .55); }

/* SHOP: three cards, the two together in the middle */
.cards { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1.4rem; margin-top: 2.2rem; align-items: start; }
.card {
  position: relative; display: flex; flex-direction: column;
  background: var(--panel); border: 2px solid var(--line); border-radius: 18px; padding: 1rem 1.2rem 1.3rem;
}
.card img { border-radius: 12px; margin-bottom: 1rem; aspect-ratio: 3 / 2; object-fit: cover; width: 100%; }
.card h3 { font-size: 1.15rem; margin-bottom: .2rem; }
.card-line { color: var(--soft); margin-bottom: .7rem; }
.card ul { list-style: none; padding: 0; margin: 0 0 1rem; color: var(--soft); font-size: .92rem; }
.card li { padding: .3rem 0; border-top: 1px dashed #2E2922; }
.price { font-family: var(--mono); font-size: 1.5rem; color: var(--paper); margin: .2rem 0 .9rem; }
.price small { font-size: .7rem; color: var(--muted); letter-spacing: .05em; }
.price.none { font-size: .92rem; color: var(--sage); letter-spacing: .03em; }
.card .btn { margin-top: auto; }
.card:nth-child(1) { transform: rotate(-.5deg) translateY(10px); }
.card:nth-child(3) { transform: rotate(.7deg) translateY(16px); }
.card.best { border: 2px dashed rgba(255, 181, 71, .7); background: #18140D; }
.flag {
  position: absolute; top: -.8rem; left: 1.2rem; margin: 0;
  font-family: var(--mono); font-size: .7rem; letter-spacing: .22em; color: #1A1206; background: var(--amber);
  padding: .2rem .7rem; border-radius: 99px;
}
.works { margin-top: 2.6rem; color: var(--muted); font-size: .9rem; }
.faq { margin-top: 1.4rem; display: grid; gap: .6rem; max-width: 52em; }
.faq details { border: 1px solid var(--line); border-radius: 12px; background: #0A0908; padding: .2rem 1rem; }
.faq summary { cursor: pointer; padding: .7rem 0; font-weight: 700; color: var(--paper); }
.faq details p { color: var(--soft); }

/* INSIDE: a terminal, since it is made for people who live in one */
.apps-in { display: grid; grid-template-columns: 1.15fr 1fr; gap: clamp(1.5rem, 5vw, 4rem); align-items: start; margin-top: 1.4rem; }
.term {
  margin: 0; font-family: var(--mono); font-size: .88rem; line-height: 1.75; color: var(--soft);
  background: #050504; border: 1px solid var(--line); border-radius: 14px; padding: 1.2rem 1.3rem;
  white-space: pre; overflow-x: auto;
}
.term b { color: var(--amber); font-weight: 400; }
.prompt { color: var(--sage); }
.yours p { color: var(--soft); border-left: 2px solid var(--sage); padding-left: 1rem; }
.yours p:nth-child(2) { border-left-color: var(--amber); }
.yours strong { display: block; color: var(--paper); margin-bottom: .2rem; }

/* 404 */
.contact { text-align: center; padding-bottom: clamp(4rem, 8vw, 6rem) !important; }
.contact img { margin: 0 auto 1.2rem; }
.contact p { color: var(--soft); }

/* the reservation and privacy pages */
.reserve { max-width: 680px; margin: 0 auto; padding: clamp(2.2rem, 6vw, 4rem) 1rem 4rem; }
.reserve h1 { font-size: clamp(1.8rem, 4vw, 2.6rem); }
.reserve.done { text-align: center; }
.reserve.done img { margin: 0 auto 1rem; }
.reserve.done .sub { margin-left: auto; margin-right: auto; }
.num { color: var(--amber); font-family: var(--mono); }
.legal h2 { font-size: 1.15rem; color: var(--amber); margin-top: 1.6rem; }
.legal p { color: var(--soft); }
.err { background: #241410; border: 1px solid var(--red); color: #F2C2B0; border-radius: 10px; padding: .7rem 1rem; }
.rform { display: grid; gap: 1.2rem; margin-top: 1.4rem; }
.pick { border: 0; padding: 0; margin: 0; display: grid; gap: .6rem; }
.pick legend { font-weight: 700; margin-bottom: .6rem; }
.opt {
  display: flex; gap: .8rem; align-items: center; cursor: pointer;
  background: #0A0908; border: 2px solid var(--line); border-radius: 12px; padding: .75rem .9rem;
}
.opt:has(input:checked) { border-color: var(--amber); background: #18140D; }
.opt input { accent-color: var(--amber); width: 1.15rem; height: 1.15rem; flex: none; }
.opt b { display: block; font-family: var(--mono); font-weight: 400; letter-spacing: .06em; }
.opt small { color: var(--muted); }
.field { display: grid; gap: .35rem; }
.field span { font-weight: 700; }
.field input, .field select {
  font: inherit; color: var(--paper); background: #0A0908; border: 2px solid var(--line); border-radius: 10px;
  padding: .7rem .8rem; width: 100%;
}
.field input:focus, .field select:focus { outline: 2px solid var(--amber); outline-offset: 1px; border-color: transparent; }
.consent { display: flex; gap: .7rem; align-items: flex-start; color: var(--soft); font-size: .93rem; cursor: pointer; }
.consent input { accent-color: var(--amber); width: 1.15rem; height: 1.15rem; margin-top: .2rem; flex: none; }
.hp { position: absolute; left: -10000px; width: 1px; height: 1px; overflow: hidden; }
.small { color: var(--muted); font-size: .88rem; margin-top: 1.2rem; }

footer {
  border-top: 1px solid var(--line); padding: 1.6rem var(--side) 1.4rem;
  color: var(--muted); font-size: .85rem; display: flex; justify-content: space-between; gap: 1rem; flex-wrap: wrap;
}
footer p { margin: 0; }

a:focus-visible, button:focus-visible, summary:focus-visible { outline: 2px solid var(--amber); outline-offset: 3px; }

/* narrow screens */
/* LIVE TRY: the band on the page, the lab's walk on the device's own screens, its two held keys, the door, and the
   deletion's two steps */
.try-in { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.1fr); gap: clamp(1.5rem, 5vw, 4rem); align-items: center; }
.try h2 em { font-style: normal; color: var(--amber); }
.try-in img { width: 100%; height: auto; border-radius: 14px; border: 8px solid #1C1A16; transform: rotate(1.2deg); }
.lab { max-width: 1240px; margin: 0 auto; padding: clamp(2.2rem, 6vw, 4rem) 1rem 4rem; }
.lab h1 em { font-style: normal; color: var(--amber); }
.lab-what { margin: 1.4rem 0; padding-left: 1.2rem; color: var(--soft); line-height: 1.8; }
.lab-head { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: clamp(1.5rem, 4vw, 3.5rem); align-items: end; margin-bottom: 2.8rem; }
.new { margin: 0; padding: 1.2rem 1.4rem; max-width: 52em; border: 2px dashed rgba(141, 179, 132, .55); border-radius: 16px; background: var(--panel); transform: rotate(-.35deg); }
.new h2 { font-size: 1.1rem; color: var(--sage); margin-bottom: .5rem; }
.new p + p { margin-top: .6rem; }
.tour { list-style: none; padding: 0; margin: 0; display: grid; gap: 3rem; }
.step { display: grid; grid-template-columns: minmax(0, 1.75fr) minmax(0, 1fr); gap: clamp(1.2rem, 4vw, 2.6rem); align-items: center; }
.step:nth-child(even) .screen { transform: rotate(.35deg); }
.step:nth-child(3n) .screen { transform: rotate(-.25deg); }
.step[hidden], .lab-end[hidden], .lab-nav [hidden] { display: none; }
.screen { position: relative; border-radius: 16px; overflow: hidden; border: 10px solid #1C1A16; background: #000; box-shadow: 0 18px 50px rgba(0, 0, 0, .45); }
.screen img { display: block; width: 100%; height: auto; -webkit-user-select: none; user-select: none; -webkit-touch-callout: none; pointer-events: none; }
.tell .n { font-family: var(--mono); letter-spacing: .25em; font-size: .75rem; color: var(--amber); }
.tell h2 { margin: .3rem 0 .6rem; }
.tell p + p { margin-top: .6rem; }
.hint { color: var(--amber); font-size: .92rem; }
.hint:empty { display: none; }
.after { display: none; color: var(--sage); }
.step.tried .after { display: block; }
.js-only { display: none; }
.lab-js .js-only { display: inline; }
.hot { position: absolute; transform: translate(-50%, -50%); min-width: 48px; min-height: 48px; padding: 0; border: 2px solid var(--amber); border-radius: 12px;
  background: rgba(255, 181, 71, .08); color: transparent; font: 400 .6rem/1 var(--mono); cursor: pointer;
  touch-action: none; -webkit-user-select: none; user-select: none; -webkit-touch-callout: none; animation: hot 1.6s ease-in-out infinite; }
.hot-yes { left: 74.4%; top: 85.5%; width: 46.4%; height: 22.3%; }
.hot-mic { left: 82.6%; top: auto; bottom: 1.7%; width: 8.5%; height: 12.5%; transform: translateX(-50%); }
.hot.down { animation: none; border-color: transparent; background: transparent; }
.hot:focus-visible { outline: 2px solid var(--paper); outline-offset: 3px; }
@keyframes hot { 0%, 100% { box-shadow: 0 0 0 0 rgba(255, 181, 71, .55); } 50% { box-shadow: 0 0 0 9px rgba(255, 181, 71, 0); } }
.lab-nav { display: flex; align-items: center; justify-content: space-between; gap: 1rem; margin-top: 2rem; }
.lab-nav .btn[disabled] { opacity: .35; cursor: default; }
.lab-nav .btn:not(.ghost):not(.ready) { background: transparent; color: var(--amber); }
.lab-count { font-family: var(--mono); letter-spacing: .2em; color: var(--soft); font-size: .8rem; }
.lab-end { margin-top: 3rem; padding: 1.6rem 1.7rem; max-width: 52em; border: 2px solid var(--line); border-radius: 18px; background: var(--panel); transform: rotate(.25deg); }
.lab-end h2 { margin-bottom: .6rem; }
.lab-end .cta { margin-top: 1.2rem; }
.lab-out { margin-top: 2.5rem; display: flex; flex-wrap: wrap; gap: .6rem 1.4rem; align-items: center; font-size: .88rem; color: var(--soft); }
button.link { background: none; border: 0; padding: 0; color: var(--amber); text-decoration: underline; font: inherit; cursor: pointer; }
.confirm { display: flex; flex-wrap: wrap; gap: 1rem; margin-top: 1.8rem; align-items: center; }
.btn.danger { background: transparent; color: #E58A6E; border-color: #E58A6E; }
.btn.danger:hover, .btn.danger:focus-visible { background: rgba(229, 138, 110, .12); border-color: #E58A6E; }
@media (prefers-reduced-motion: reduce) { .hot { animation: none; } }
@media (max-width: 760px) {
  .try-in, .step, .lab-head { grid-template-columns: 1fr; }
  .screen { border-width: 6px; border-radius: 12px; }
  .lab-nav .btn { padding: .8rem 1.1rem; }
}

@media (max-width: 1000px) {
  .carts { grid-template-columns: 1fr 1fr; }
  .cards { grid-template-columns: 1fr 1fr; }
  .card.best { grid-column: 1 / -1; order: -1; }
}
@media (max-width: 900px) {
  .home, .ask, .talk, .dev, .pocket .dev, .dev.flip, .apps-in, .lights, .play, .nudge, .promises { grid-template-columns: 1fr; }
  .italy-head { grid-template-columns: 1fr 120px; }
  .care .dev .h2o { order: -1; }
  .pocket .dev .pic { order: -1; }
  .dev.flip .glass { order: -1; }
  .sessions { grid-template-columns: 1fr 1fr; }
  .cap { grid-row: auto; }
}
@media (max-width: 640px) {
  .cards { grid-template-columns: 1fr; }
  .card:nth-child(n) { transform: none; }
  .card:nth-child(3) { transform: rotate(.4deg); }
}
@media (max-width: 560px) {
  body { font-size: 16px; }
  .brand span { font-size: .8rem; letter-spacing: .1em; }
  .brand img { width: 26px; }
  .status { gap: .5rem; }
  .pc, .pct { display: none; }
  .needs { font-size: .72rem; padding: .18rem .6rem; }
  .sessions, .carts, .play .carts { grid-template-columns: 1fr; }
  .req { transform: none; padding: 1rem; }
  .req-who { font-size: 1.45rem; }
  .term { font-size: .64rem; padding: .9rem .8rem; }
  .tabs a { font-size: .58rem; letter-spacing: .14em; }
  .cta .btn { flex: 1 1 100%; }
}
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .join video { display: none; }
  .join .still { display: block; }
  .leds i::after { animation: none !important; }
}

/* print: A4, light paper, no bars */
@page { size: A4; margin: 14mm; }
@media print {
  body { background: #fff; color: #111; font-size: 10.5pt; padding: 0; }
  .bar, .tabs, .stitch, .btn, .req-try, .lights, .join video, .faq summary::marker { display: none; }
  .join .still { display: block; }
  main > section { padding: 7mm 0; }
  * { transform: none !important; box-shadow: none !important; }
  .copy p, .sub, .yours p, .lead, .carts span, .sessions span, .term, .card-line, .card ul, .facts li, .faq details p, .free, .works { color: #222; }
  h1, h2, .nudge h3, .yours strong, .carts b, .sessions b, .facts b, .faq summary, .price { color: #111; }
  h1 em, h3, .label, .term b, .flag { color: #9A5B00; }
  .flag { background: none; position: static; }
  .home, .ask, .talk, .dev, .pocket .dev, .dev.flip { grid-template-columns: 1fr 1fr; gap: 8mm; }
  .sessions { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .cards { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 5mm; }
  .carts { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .apps-in { grid-template-columns: 1fr; }
  .term { white-space: pre-wrap; font-size: 8pt; }
  .home-pic img, .pic img, .join img { max-height: 75mm; width: auto; margin: 0 auto; }
  .faq details { border: 0; padding: 0; }
  .faq details:not([open]) > p { display: block; }
  .card, .sessions li, .carts li, figure, .req, .faq details { break-inside: avoid; }
  .spin canvas, .spin-hint { display: none !important; }
  .spin.live img { display: block; }  /* on paper the picture, never a canvas caught mid-turn */
  .card, .card.best, .sessions li, .carts li, .term, .req, .glass, .faq details { background: none; }
  .card.best { border-color: #9A5B00; }
  .join { background: none; }
  .clock { display: none; } /* its unlit segments are dark: on paper they all read lit */
  .label, h2 { break-after: avoid; }
  .promises li { background: none; border-color: #999; break-inside: avoid; }
  .promises b, .italy h2 { color: #111; }
  .promises span, .made { color: #222; }
  .italy h2 em, .try h2 em, .stamp { color: #9A5B00; }
  .try-in img { max-height: 60mm; width: auto; }
}
