/* Every public page: a header with the name in bubble letters in the middle, a pale pink page, and
   mint on the sale bar and tags, the current menu item, the category circles and the footer. One light look. First the shared parts and the shop, then the text pages and the
   account. The dashboard has dashboard/dashboard.css. Raspberry marks what to press. Design rules:
   docs/design-guardrails.md. */
@font-face { font-family: 'Nunito Sans'; src: url('/fonts/NunitoSans-Variable.ttf') format('truetype');
  font-weight: 200 1000; font-display: swap; }
@font-face { font-family: 'Fredoka'; src: url('/fonts/Fredoka-Variable.ttf') format('truetype');
  font-weight: 300 700; font-display: swap; }
@font-face { font-family: 'Modak'; src: url('/fonts/Modak-Regular.ttf') format('truetype'); font-display: swap; }

:root {
  color-scheme: light;
  --ground: #fff9fb;
  --surface: #fff;
  --text: #4a1d38;
  --muted: #7d5670;
  --line: #f8d9e6;
  --outline: #c42a70;
  --field: #a8718c;
  --tile: #fff0f6;
  --card-line: #c42a70;
  --action: #c42a70;
  --action-text: #fff;
  --accent: #c42a70;
  --soft: #ffe6f0;
  --soft-text: #7d5670;
  --band: #ffd3e4;
  --bar: #d4f4ea;
  --bar-text: #14604c;
  --mint-soft: #e8f9f3;
  --logo: #f0569b;
  --logo-shadow: #a81d5f;
  --stage: #f6e8ee;
  --bad: #8a0f1d;
  --bad-line: #e0a3aa;
  --bad-ground: #fdeef0;
  --display: 'Fredoka', "Segoe UI", system-ui, sans-serif;
}

* { box-sizing: border-box; }
[hidden] { display: none !important; }
body { display: flex; flex-direction: column; min-height: 100vh; margin: 0; color: var(--text);
  font: 400 1rem/1.55 'Nunito Sans', "Segoe UI", system-ui, sans-serif; background: var(--ground); }
a { color: inherit; font-weight: 700; }
h1, h2, h3 { font-family: var(--display); font-weight: 600; }
/* Read aloud, not drawn. */
.unseen { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }
:focus-visible { outline: 3px solid var(--accent); outline-offset: 2px; }
.wide { width: 100%; max-width: 78rem; margin: 0 auto; padding-inline: 1.5rem; }

button, input, select, textarea { font: inherit; }
button, a.action, a.view, a.see { min-height: 2.75rem; padding: .5rem 1.5rem; border: 1px solid var(--action);
  border-radius: 999px; font-size: .9375rem; font-weight: 800; }
button { white-space: nowrap; cursor: pointer; color: var(--action-text); background: var(--action); }
button:disabled { cursor: default; opacity: .55; }
button.outline { color: var(--text); background: transparent; border-color: var(--outline); }
button.quiet { padding-inline: .5rem; border-color: transparent; font-size: .875rem; font-weight: 400;
  color: var(--text); background: transparent; text-decoration: underline; }
a.action, a.view, a.see { display: inline-flex; align-items: center; justify-content: center; text-align: center;
  text-decoration: none; }
a.action, a.view { color: var(--action-text); background: var(--action); }
a.action:hover, a.view:hover { text-decoration: underline; }
input, select, textarea { min-width: 0; min-height: 2.75rem; padding: .35rem 1rem; border: 1px solid var(--field);
  border-radius: 999px; font-size: 1rem; color: var(--text); background: var(--surface); }
textarea { padding-block: .6rem; border-radius: 1rem; }
input[type='checkbox'], input[type='radio'] { min-height: 0; padding: 0; }

.salebar { display: flex; align-items: center; justify-content: center; gap: .75rem; padding: 0 .75rem;
  font-size: .875rem; font-weight: 700; text-align: center; color: var(--bar-text); background: var(--bar); }
.salebar p { flex: 1; margin: 0; padding: .625rem 0 .625rem 2.75rem; overflow-wrap: anywhere; }
.salebar a { font-weight: 800; white-space: nowrap; }
.salebar button { width: 2.75rem; padding: 0; border: 0; font-size: 1.25rem; color: inherit; background: transparent; }
.salebar :focus-visible { outline-color: var(--bar-text); }
/* A question with two answers, in the same bar. */
.askbar { flex-wrap: wrap; padding-block: .4rem; }
.askbar p { flex: 1 1 16rem; padding: .25rem 0; }
.askbar button { width: auto; min-height: 2.75rem; padding: 0 1rem; border: 2px solid var(--bar-text);
  border-radius: 999px; font-size: .875rem; font-weight: 800; }
.askbar button.plain { border-color: transparent; text-decoration: underline; }

.site { border-bottom: 1px solid var(--line); background: var(--surface); }
.site .wide { display: grid; grid-template-columns: minmax(0, 1fr) auto minmax(0, 1fr); align-items: center;
  gap: .75rem 1rem; padding-block: .875rem; }
/* The name as balloon letters: the color, a white rim, and a darker copy a little below. */
.logo { position: relative; z-index: 0; display: inline-block; padding: 0 .5rem;
  font: 400 3.5rem/1.35 'Modak', var(--display); white-space: nowrap; text-decoration: none; color: var(--logo);
  -webkit-text-stroke: .5rem #fff; paint-order: stroke fill; }
.logo::before { content: 'JuicyCode'; position: absolute; top: .3rem; left: .5rem; z-index: -1;
  color: var(--logo-shadow); -webkit-text-stroke: .6rem var(--logo-shadow); }
.site .logo { justify-self: center; }
.site .logo:only-child { grid-column: 1 / -1; }
.site nav { display: flex; flex-wrap: wrap; align-items: center; gap: .25rem; font-size: .9375rem; }
.site nav a { display: inline-flex; align-items: center; min-height: 2.75rem; padding: 0 1rem; border-radius: 999px;
  font-weight: 800; text-decoration: none; }
.site nav a:hover { text-decoration: underline; text-underline-offset: .35em; }
.site nav a[aria-current] { background: var(--bar); }
.tools { display: flex; align-items: center; justify-content: flex-end; gap: .5rem; }
.tools .round { position: relative; display: inline-flex; flex: none; align-items: center; justify-content: center;
  width: 2.875rem; height: 2.875rem; min-height: 0; padding: 0; border: 2px solid var(--accent); border-radius: 50%;
  color: var(--accent); background: transparent; }
.tools .round[aria-current], .tools .round[aria-expanded='true'] { background: var(--bar); }
.tools .round:hover { background: var(--mint-soft); }
.round svg { width: 1.375rem; height: 1.375rem; fill: none; stroke: currentColor; stroke-width: 1.8;
  stroke-linecap: round; stroke-linejoin: round; }
#cart-count { position: absolute; top: -.375rem; right: -.375rem; min-width: 1.25rem; padding: 0 .3rem;
  border-radius: 999px; font-size: .75rem; font-weight: 800; line-height: 1.25rem; text-align: center;
  color: var(--action-text); background: var(--action); }
#cart-count:empty { display: none; }
/* The round search button grows into a search bar. It is named with .site so the account page's form
   spacing does not reach it. */
.site .seek { display: flex; flex: none; align-items: center; min-width: 0; margin: 0; }
.site .seek.open { flex: 0 1 20rem; border: 2px solid var(--accent); border-radius: 999px; background: var(--surface); }
.site .seek input { flex: 1; width: 0; min-width: 0; min-height: 0; height: 2.625rem; padding: 0 .5rem 0 1rem;
  border: 0; background: transparent; }
.site .seek input:focus-visible { outline: 0; }
.site .seek.open:focus-within { outline: 3px solid var(--accent); outline-offset: 2px; }
.site .seek.open .round { width: 2.625rem; height: 2.625rem; border: 0; color: var(--action-text);
  background: var(--action); }
@media (prefers-reduced-motion: no-preference) {
  .site .seek.open { animation: seek-grow .25s ease-out; }
  @keyframes seek-grow { from { flex-basis: 2.875rem; } }
}
/* Too narrow for the name between the two sides: it moves above them, and the open search bar takes
   the links' place. */
@media (max-width: 62rem) {
  .site .wide { grid-template-columns: auto auto; justify-content: space-between; row-gap: .25rem; }
  .site .logo { grid-column: 1 / -1; order: -1; }
  .site.seeking .wide { grid-template-columns: minmax(0, 1fr); }
  .site.seeking nav { display: none; }
  .site.seeking .seek { flex: 1; }
}

main { flex: 1; padding-block: 1.75rem 3.5rem; }
.head { display: flex; flex-wrap: wrap; align-items: flex-end; justify-content: space-between; gap: 1rem;
  padding-bottom: 1rem; margin-bottom: 1.5rem; border-bottom: 1px solid var(--line); }
h1 { margin: 0; font-size: 2.25rem; line-height: 1.2; }
.head p { margin: .15rem 0 0; min-height: 1.3125rem; color: var(--muted); }
.filters { display: flex; gap: .75rem; }
.filters label { display: grid; gap: .2rem; font-size: .75rem; font-weight: 700; color: var(--muted); }
.filters label, .doc label { padding-inline: .25rem; }
.filters select { min-width: 9.5rem; }

.message { margin: 0 0 1.25rem; padding: .75rem 1rem; border: 1px solid var(--line); border-radius: 1rem;
  background: var(--surface); }
.products { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 18.75rem), 1fr));
  gap: 3rem 1.75rem; }
.products > .message { grid-column: 1 / -1; margin: 0; }

.product { display: flex; flex-direction: column; gap: .625rem; overflow-wrap: anywhere; }
.picture { position: relative; display: block; aspect-ratio: 3 / 4; overflow: hidden; border-radius: 1.125rem;
  background: var(--soft); }
.picture :is(img, video) { position: absolute; inset: 0; width: 100%; height: 100%; }
/* A card is filled by its picture. The product's page and the cart show pictures whole. */
.picture .photo { object-fit: cover; }
.product .picture .cutout { padding: 1.25rem; object-fit: contain; filter: drop-shadow(0 14px 12px rgb(60 8 32 / .25)); }
.line .picture { aspect-ratio: 1; }
.line .picture .photo { object-fit: contain; }
.empty { position: absolute; inset: 0; display: flex; align-items: center; justify-content: center; padding: 1rem;
  font-weight: 800; text-align: center; color: var(--soft-text); background: var(--soft); }
.line .empty { padding: .25rem; font-size: .75rem; }
.more { position: absolute; right: .6rem; bottom: .6rem; padding: .05rem .6rem; border-radius: 999px;
  font-size: .75rem; font-weight: 800; color: #fff; background: rgb(36 16 25 / .85); }
.sale { position: absolute; top: .75rem; right: .75rem; z-index: 1; padding: .1rem .75rem; border-radius: 999px;
  font-size: .8125rem; font-weight: 800; pointer-events: none; color: var(--action-text); background: var(--action); }

.viewer { width: min(56rem, 94vw); max-height: 94vh; padding: 0; border: 1px solid var(--line); border-radius: 1.25rem;
  color: var(--text); background: var(--ground); }
.viewer::backdrop { background: rgb(20 4 12 / .8); }
.viewer .stage { height: min(70vh, 42rem); overflow: auto; background: var(--stage); }
.viewer .large { display: block; width: 100%; height: 100%; object-fit: contain; }
.viewer img.large { cursor: zoom-in; }
.viewer .stage.zoomed .large { width: auto; height: auto; min-width: 200%; max-width: none; cursor: zoom-out; }
.controls { display: flex; flex-wrap: wrap; align-items: center; gap: .5rem; padding: .75rem; }
.controls strong { margin-right: auto; }
.count { color: var(--muted); }
.offers { display: grid; grid-template-columns: minmax(0, 1fr); gap: .75rem; }
.offer { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: .75rem;
  padding: 1rem 1.25rem; border: 1px solid var(--line); border-radius: 1.25rem; background: var(--surface); }
.offer.first { border-color: var(--card-line); }
.offer > div:first-child { flex: 1 1 10rem; }
.price, .amount-large { font-family: var(--display); font-size: 2.125rem; font-weight: 600; line-height: 1.2; }
.was { margin-right: .5rem; color: var(--muted); }
.was:empty { display: none; }
.note { display: block; font-size: .875rem; color: var(--muted); }
.free { display: flex; flex-wrap: wrap; align-items: center; gap: .5rem; }
.free .price, .free p { flex: 1 0 100%; margin: 0; }
.free input { flex: 1 1 14rem; }

footer { font-size: .875rem; color: var(--text); background: var(--bar); }
footer .wide { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 1rem 2rem;
  padding-block: 2rem; }
footer p { margin: 0; font-weight: 600; }
footer nav { display: flex; flex-wrap: wrap; gap: .25rem 1.25rem; }
footer a { display: inline-flex; align-items: center; min-height: 2.75rem; font-weight: 600; text-decoration: none; }
footer a:hover, footer a[aria-current] { text-decoration: underline; text-underline-offset: .35em; }

/* Front page */
main.home, main.item { padding: 0; }
.home > .message { width: calc(100% - 2rem); max-width: 75rem; margin: 1.25rem auto; }

/* A row that scrolls sideways; its arrows are the visible way along it. */
.rail { display: flex; gap: 1.5rem; overflow-x: auto; scroll-snap-type: x mandatory; scrollbar-width: none; }
.rail > * { scroll-snap-align: start; }
.step { display: inline-flex; flex: none; align-items: center; justify-content: center; width: 3rem; height: 3rem;
  padding: 0; border: 2px solid var(--accent); color: var(--accent); background: var(--surface); }
.step svg { width: 1.5rem; height: 1.5rem; fill: none; stroke: currentColor; stroke-width: 2;
  stroke-linecap: round; stroke-linejoin: round; }

/* The featured band: pink, with each product's picture standing straight on it. No box behind a
   picture and no words under it: the picture is the link. */
.featured { padding: 3rem 1.5rem 3.5rem; background: var(--band); }
.reel { display: flex; align-items: center; gap: .75rem; max-width: 75rem; margin: 0 auto; }
.reel .rail { flex: 1; min-width: 0; justify-content: safe center; column-gap: 3.5rem; }
.featured .step { width: 3.25rem; height: 3.25rem; border: 0; }
.feature { flex: 0 0 min(18.75rem, 100%); }
.stand { position: relative; display: block; height: 22.5rem; border-radius: 1.125rem; text-decoration: none; }
/* A picture cut out of its background (a transparent PNG or WebP) stands on the band. One with a
   background of its own still shows, filling the space with round corners. */
.stand :is(img, video) { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover;
  border-radius: 1.125rem; }
.stand img.cutout { object-fit: contain; object-position: center bottom; border-radius: 0;
  filter: drop-shadow(0 18px 14px rgb(60 8 32 / .35)); }
.none { position: absolute; inset: 0; display: flex; align-items: center;
  justify-content: center; padding: 1rem; font-weight: 800; text-align: center; text-decoration: none; }
.stand .none { flex-direction: column; gap: .25rem; }
.stand .none strong { font: 600 1.5rem/1.25 var(--display); overflow-wrap: anywhere; }
.stand .none small { font-size: .8125rem; font-weight: 700; color: var(--muted); }
.frame .none, .display-case .none { color: var(--soft-text); }
.badge { position: absolute; top: .75rem; left: 50%; z-index: 1; transform: translateX(-50%); padding: .2rem 1rem;
  border-radius: 999px; font-size: .75rem; font-weight: 800; text-transform: uppercase; white-space: nowrap;
  color: var(--bar-text); background: var(--bar); }
/* The two sliders */
.shelf { padding: 2.75rem 0 .75rem; }
.shelf h2 { margin: 0 0 1.5rem; padding-inline: 1.5rem; font-size: 2.25rem; line-height: 1.25; text-align: center; }
.slider { position: relative; }
.slider .rail { padding: .25rem 2.75rem; scroll-padding-inline: 2.75rem; justify-content: safe center; }
.slider .step { position: absolute; top: 11rem; z-index: 1; }
.slider .back { left: .875rem; }
.slider .next { right: .875rem; }
.tile { display: flex; flex: 0 0 min(17.5rem, 85%); flex-direction: column; gap: .625rem; text-decoration: none;
  overflow-wrap: anywhere; }
.frame { position: relative; display: block; height: 24.375rem; overflow: hidden; border-radius: 1.125rem;
  background: var(--soft); }
.frame :is(img, video) { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.frame img.cutout { padding: 1.25rem; object-fit: contain; filter: drop-shadow(0 14px 12px rgb(60 8 32 / .25)); }
.tile .titled { font: 600 1.125rem/1.35 var(--display); }
.tile:hover .titled > span:first-child { text-decoration: underline; }
.shop-all { display: flex; justify-content: flex-end; margin: 1rem 0 0; padding-inline: 2.75rem; }
.shop-all a, .product .add { min-height: 2.875rem; border: 2px solid var(--accent); font-weight: 800;
  text-align: center; text-decoration: none; color: var(--accent); background: transparent; }
.shop-all a { display: inline-flex; align-items: center; padding: 0 1.75rem; border-radius: 999px; }
.shop-all a:hover, a.add:hover { text-decoration: underline; }
.home > .note { margin: 1.5rem 0; padding-inline: 1.5rem; font-size: .875rem; text-align: center; }

/* One product, large, above the footer */
.spotlight { display: flex; flex-wrap: wrap; align-items: center; gap: 3rem; margin-top: 2rem; padding: 4rem;
  border-top: 1px solid var(--line); background: var(--surface); }
.words { display: flex; flex: 1 1 20rem; flex-direction: column; gap: 1.25rem; min-width: 0; overflow-wrap: anywhere; }
.words h2 { margin: 0; font-size: clamp(3rem, 7vw, 5.25rem); line-height: 1; }
.words h2 a { font-weight: 600; text-decoration: none; }
.words h2 .first { display: block; text-transform: uppercase; }
.words h2 .rest { display: block; padding-left: clamp(1rem, 4vw, 3.5rem); font-size: .62em; }
.words p { max-width: 26rem; margin: 0; font-size: 1.125rem; color: var(--muted); white-space: pre-line; }
.words .buy { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: .75rem 1.5rem;
  max-width: 26rem; }
.words .amount-large:empty { display: none; }
.words .buy button, .words .buy a.action { min-height: 3rem; margin-left: auto; padding-inline: 2.125rem; }
.display-case { position: relative; flex: 1 1 26rem; height: 26.25rem; overflow: hidden; border-radius: 1.375rem;
  background: var(--soft); }
.display-case :is(img, video) { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.display-case img.cutout { padding: 1.5rem; object-fit: contain; filter: drop-shadow(0 18px 14px rgb(60 8 32 / .3)); }
/* The large video and the button that stops it. */
.showing { position: relative; display: flex; flex: 1 1 26rem; min-width: 0; }
.showing .display-case { flex: 1; }
.showing .pause { position: absolute; right: .875rem; bottom: .875rem; }

/* A mark on a picture that is a video. It makes way while a card's video plays. */
:is(.picture, .stand, .frame, .thumb):has(video)::after { content: '\25B6\FE0E'; position: absolute; bottom: .6rem;
  left: .6rem; z-index: 2; display: flex; align-items: center; justify-content: center; width: 2rem; height: 2rem;
  border-radius: 50%; font-size: .75rem; pointer-events: none; color: #fff; background: rgb(74 29 56 / .85); }
@media (prefers-reduced-motion: no-preference) {
  :is(.product, .feature):is(:hover, :focus-within) :is(.picture, .stand):has(video)::after { opacity: 0; }
  .tile:is(:hover, :focus-visible) .frame:has(video)::after { opacity: 0; }
}

/* All products */
.catalog { padding-top: 2.25rem; }
.catalog h1 { text-align: center; }
.types { display: flex; flex-wrap: wrap; justify-content: center; gap: 1.5rem 2rem; margin-top: 2.25rem; }
.types button { display: flex; flex-direction: column; align-items: center; justify-content: flex-start; gap: .625rem;
  width: 8rem; padding: 0; border: 0; border-radius: 1rem; font-size: .875rem; line-height: 1.3;
  text-transform: uppercase; white-space: normal; overflow-wrap: anywhere; color: var(--text); background: transparent; }
.types .icon { display: flex; align-items: center; justify-content: center; width: 6.5rem; height: 6.5rem;
  border-radius: 50%; color: var(--bar-text); background: var(--bar); }
.types button[aria-pressed='true'] .icon { color: var(--action-text); background: var(--action); }
.types svg { width: 2.5rem; height: 2.5rem; fill: none; stroke: currentColor; stroke-width: 1.6;
  stroke-linecap: round; stroke-linejoin: round; }
.shelves { max-width: 68.75rem; margin: 0 auto; }
.bar { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: .75rem 1.5rem;
  padding-block: 1.25rem; }
.bar p { margin: 0; font-weight: 600; color: var(--muted); }
.bar .filters { margin-left: auto; }
.shelves > .note { margin: 2rem 0 0; font-size: .875rem; text-align: center; }

@media (max-width: 75rem) { .reel .rail { column-gap: 1.5rem; } }
@media (max-width: 37.5rem) {
  .wide { padding-inline: 1rem; }
  .logo { font-size: 2.75rem; }
  .featured { padding: 2rem 1rem 2.5rem; }
  .reel .step { display: none; }
  .reel .rail { column-gap: .5rem; }
  .feature { flex-basis: min(18.75rem, 84%); }
  .shelf h2 { font-size: 1.875rem; }
  .slider .rail { padding-inline: 1rem; scroll-padding-inline: 1rem; }
  .slider .step { display: none; }
  .shop-all { justify-content: center; padding-inline: 1rem; }
  .spotlight { gap: 2rem; padding: 2.5rem 1rem; }
  .showing { flex-basis: 100%; }
  .display-case { flex-basis: 100%; height: 20rem; }
  .types { gap: 1rem .5rem; }
  .types button { width: 6.25rem; font-size: .75rem; }
  .types .icon { width: 5rem; height: 5rem; }
  .types svg { width: 2rem; height: 2rem; }
  .filters { width: 100%; gap: .5rem; }
  .filters label { flex: 1; min-width: 0; }
  .filters select { min-width: 0; width: 100%; }
  .free button { flex: 1 0 100%; }
  .offer .buttons { flex: 1 0 100%; align-items: stretch; }
  .free input { flex: 0 0 100%; width: 100%; }
}

/* Text pages: policies, contact, account and download */
.doc > * { max-width: 44rem; }
.doc > .head { max-width: none; }
.doc > .wider { max-width: none; }
.doc h2 { margin: 1.75rem 0 .5rem; font-size: 1.375rem; line-height: 1.35; }
.doc h3 { margin: 0; font-size: 1.0625rem; }
.doc p, .doc ul { margin: .6rem 0; }
.doc ul { padding-left: 1.25rem; }
.doc li { margin: .3rem 0; }
.doc, .doc li { line-height: 1.6; }
.note { color: var(--muted); }
.doc .note { font-size: .8125rem; }

.scroll { overflow-x: auto; border: 1px solid var(--line); border-radius: 1rem; }
table { width: 100%; border-collapse: collapse; font-size: .875rem; }
th, td { padding: .55rem .75rem; text-align: left; vertical-align: top; }
th { font-size: .75rem; font-weight: 800; color: var(--bar-text); background: var(--mint-soft); }
tbody td { border-top: 1px solid var(--line); }

/* Forms and boxes of the account and download pages (signin.js builds most of them) */
.app form { display: flex; flex-wrap: wrap; align-items: flex-end; gap: .75rem; margin: .75rem 0; }
.app form p { flex-basis: 100%; margin: 0; }
.app form.stack { flex-direction: column; align-items: stretch; }
.app label { display: grid; gap: .2rem; font-size: .75rem; font-weight: 700; color: var(--muted); }
.app label.wide { flex: 1 1 14rem; width: auto; margin: 0; padding: 0; }
button.light { color: var(--text); background: transparent; border-color: var(--field); }
button.danger { color: var(--bad); background: transparent; border-color: var(--bad-line); }
/* The sign-in card: one thing to do, the other ways under a line, and a way to the other views. */
.signin { padding: 1.5rem; }
.signin h2 { margin: 0 0 .5rem; }
.signin form { margin-bottom: 0; }
.signin > button { width: 100%; }
.signin > .or { margin: .75rem 0; }
.signin .aside { margin: -.75rem 0; text-align: right; }
.signin .aside button { padding-inline: 0; }
.signin .or { display: flex; align-items: center; gap: .75rem; margin: .25rem 0; font-size: .75rem; font-weight: 700;
  color: var(--muted); }
.signin .or::before, .signin .or::after { content: ''; flex: 1; border-top: 1px solid var(--line); }
.signin .switch { margin: .75rem 0 0; text-align: center; font-size: .875rem; color: var(--muted); }
.signin .switch button { padding-inline: .25rem; font-weight: 700; }
.card { margin: .75rem 0; padding: 1rem 1.25rem; border: 1px solid var(--line); border-radius: 1.25rem;
  background: var(--surface); }
.card > :first-child { margin-top: 0; }
.card > :last-child { margin-bottom: 0; }
.card > header { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: .5rem; }
.chip { display: inline-block; padding: 0 .625rem; border: 1px solid var(--line); border-radius: 999px; font-size: .75rem;
  font-weight: 800; background: var(--tile); }
.chip::first-letter { text-transform: uppercase; }
.actions, .row { display: flex; flex-wrap: wrap; align-items: center; gap: .5rem 1rem; margin: .75rem 0; }
.key { font: 700 .9375rem ui-monospace, Consolas, monospace; user-select: all; overflow-wrap: anywhere; }
.codes { display: grid; grid-template-columns: repeat(auto-fit, minmax(9rem, 1fr)); gap: .35rem 1rem; padding: 0;
  list-style: none; }
#message { margin: 0 0 1rem; padding: .6rem 1rem; border: 1px solid var(--line); border-radius: 1rem;
  background: var(--tile); }
#message.error { color: var(--bad); border-color: var(--bad-line); background: var(--bad-ground); }
.narrow { max-width: 24rem; }
.card h4 { margin: 1rem 0 .35rem; font-size: .8125rem; font-weight: 800; }
.versions, .doc .versions { margin: 0; padding: 0; list-style: none; }
.doc .versions li { margin: 0; padding: .1rem 0; border-top: 1px solid var(--line); }
.versions li:first-child { border-top: 0; }
.versions .row strong { margin-right: auto; }
.notes { white-space: pre-line; font-size: .8125rem; }

.tabs { display: flex; flex-wrap: wrap; align-items: center; gap: .25rem; }
.tabs a { padding: .35rem .875rem; border-radius: 999px; text-decoration: none; }
.tabs a:hover { text-decoration: underline; }
.tabs a[aria-current] { color: var(--action-text); background: var(--action); }
.tabs button { margin-left: .5rem; }

dialog.card { width: min(24rem, 92vw); color: var(--text); background: var(--surface); }
dialog.card::backdrop { background: rgb(40 5 20 / .6); }

/* Search, filters, order, and a card that leads to its product page */
.filters { display: flex; flex-wrap: wrap; align-items: flex-end; gap: .75rem; }
.filters label.search { margin: 0; padding: 0; }
.filters input { min-width: 12rem; }
.filters select { min-width: 8rem; }
.product p { margin: 0; }
.titled { display: flex; flex-wrap: wrap; align-items: baseline; justify-content: space-between; gap: 0 .75rem; }
.product h3 { margin: 0; font-size: 1.1875rem; line-height: 1.35; text-transform: uppercase; }
.product h3 a { font-weight: 600; text-decoration: none; }
.product h3 a:hover { text-decoration: underline; }
.cost { font: 600 1.1875rem/1.35 var(--display); }
.product .note { font-size: .875rem; }
.product .note:empty { display: none; }
/* One dot for each of up to three photos. The dot is small; what can be pressed is not. */
.dots { display: flex; gap: .125rem; margin-left: -.375rem; }
.dots button { display: inline-flex; align-items: center; justify-content: center; width: 1.75rem; height: 1.75rem;
  min-height: 0; padding: 0; border: 0; background: transparent; }
.dots button::before { content: ''; width: 1rem; height: 1rem; border-radius: 50%; background: var(--accent); }
.dots button:nth-child(2)::before { background: #e86a9f; }
.dots button:nth-child(3)::before { background: #f4b5cd; }
.dots button[aria-pressed='true']::before { box-shadow: 0 0 0 2px var(--ground), 0 0 0 4px var(--text); }
.product .add { display: flex; align-items: center; justify-content: center; margin-top: auto; padding: .5rem 1rem;
  border-radius: .625rem; font-size: 1rem; }
.description { white-space: pre-line; }
.owned { margin: .5rem 0; padding: .35rem .875rem; border: 1px solid var(--line); border-radius: 1rem;
  font-size: .875rem; background: var(--tile); }
.product .owned { margin: 0; }

/* Product page */
.top { padding-top: 1.5rem; }
.crumbs { margin: 0 0 1.25rem; font-size: .875rem; color: var(--muted); }
.crumbs a { font-weight: 400; }
.showcase { display: grid; grid-template-columns: minmax(0, 8fr) minmax(0, 5fr); gap: 3rem; align-items: start;
  padding-bottom: 3.5rem; }
.gallery .main { position: relative; display: block; width: 100%; aspect-ratio: 78 / 64; overflow: hidden; padding: 0;
  border: 0; border-radius: 1.375rem; background: var(--stage); }
button.main { cursor: zoom-in; }
.gallery .main :is(img, video) { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: contain; }
.thumbs { display: grid; grid-template-columns: repeat(auto-fill, minmax(5.5rem, 1fr)); gap: .9375rem; margin-top: 1rem; }
.thumb { position: relative; aspect-ratio: 10 / 7; padding: 0; overflow: hidden; border: 2px solid transparent; border-radius: .875rem;
  background: var(--stage); }
.thumb[aria-current='true'] { border-color: var(--accent); }
.thumb :is(img, video) { display: block; width: 100%; height: 100%; object-fit: contain; }
.summary { overflow-wrap: anywhere; }
.summary h1 { font-size: clamp(2.25rem, 4vw, 3.375rem); }
.summary .lead { margin: .75rem 0; font-size: 1.0625rem; color: var(--muted); white-space: pre-line; }
.summary .offers { margin: 1.25rem 0 .875rem; }
.offer .note { max-width: 15rem; }
.buttons { display: flex; flex-direction: column; align-items: center; gap: .25rem; }
.buttons button:not(.quiet) { min-width: 9.5rem; }
.buttons a.view { border-color: transparent; font-size: .875rem; font-weight: 400; color: var(--text);
  background: transparent; text-decoration: underline; }
.before { margin: 1rem 0; padding: .875rem 1.25rem; border-radius: 1.25rem; font-size: .875rem; background: var(--bar); }
.before strong { font-size: .9375rem; }
.before p { margin: .2rem 0 0; }
.facts { display: grid; grid-template-columns: 7rem minmax(0, 1fr); margin: 0; font-size: .875rem; }
.facts dt, .facts dd { margin: 0; padding: .625rem 0; border-top: 1px solid var(--line); }
.facts dt { padding-right: .75rem; font-weight: 700; color: var(--muted); }
.info { background: var(--surface); }
.columns { display: flex; flex-wrap: wrap; gap: 2rem 4rem; padding-block: 3rem; }
.columns > :is(section, details) { flex: 1 1 26rem; min-width: 0; }
.info summary { min-height: 2.75rem; cursor: pointer; }
.info summary h2 { display: inline; }
.info h2, .after h2, .related h2 { margin: 0 0 1rem; font-size: 2rem; line-height: 1.3; }
.info ul { margin: 0; padding-left: 1.25rem; }
.info li { margin: .6rem 0; }
.info .text { margin: 0 0 .875rem; white-space: pre-line; }
.after { padding-block: 3rem; }
.steps { display: grid; grid-template-columns: repeat(auto-fit, minmax(13rem, 1fr)); gap: 1.5rem 2.375rem;
  margin: 0 0 2rem; padding: 0; list-style: none; counter-reset: step; }
.steps li { counter-increment: step; }
.steps li::before { display: block; content: counter(step); font: 600 1.75rem/1.4 var(--display);
  color: var(--accent); }
.steps strong { font-size: 1.0625rem; }
.steps p { margin: .25rem 0 0; font-size: .875rem; color: var(--muted); }
.related { padding-bottom: 3.5rem; }

.info .contents { padding: 0; list-style: none; }
.info .contents li { margin: 0 0 .75rem; padding: .875rem 1rem; border: 1px solid var(--line); border-radius: 1rem; }
.contents h3 { margin: 0; font-size: 1.125rem; }
.contents p { margin: .25rem 0 0; }
.saving { margin: .75rem 0; font-weight: 800; }
.saving:empty { display: none; }

/* Cart */
.lines { margin: 0; padding: 0; list-style: none; }
.line { display: grid; grid-template-columns: 6rem minmax(0, 1fr) auto; gap: 1rem; align-items: start;
  padding: .9rem 0; border-bottom: 1px solid var(--line); }
.line .picture { border-radius: .875rem; }
.line h2 { margin: 0; font-size: 1.25rem; }
.line .price { font-size: 1.25rem; }
.line p { margin: .25rem 0; }
.amount { display: flex; flex-direction: column; align-items: flex-end; gap: .4rem; }
.pay { display: grid; gap: .75rem; max-width: 24rem; margin: 1.25rem 0 0 auto; }
.pay label { display: grid; gap: .2rem; font-size: .75rem; font-weight: 700; color: var(--muted); }
.pay button { min-height: 2.5rem; }
.total { margin: 0; font-size: 1.0625rem; font-weight: 800; }
.total:empty { display: none; }

dialog.ask { width: min(28rem, 92vw); padding: 1.25rem; border: 1px solid var(--line); border-radius: 1.25rem;
  color: var(--text); background: var(--surface); }
dialog.ask::backdrop { background: rgb(20 4 12 / .7); }
dialog.ask h2 { margin: 0 0 .5rem; font-size: 1.125rem; }
dialog.ask .controls { padding: .5rem 0 0; }
dialog.checkout { width: min(40rem, 96vw); max-height: 92vh; padding: .75rem; overflow: auto; background: #fff;
  border: 1px solid var(--line); border-radius: 1.25rem; }
dialog.checkout::backdrop { background: rgb(20 4 12 / .7); }
dialog.checkout > button { display: block; margin: 0 0 .75rem auto; color: #1a1a1a; border-color: #1a1a1a; }

.doc details, .info .asked { margin: .5rem 0; border: 1px solid var(--line); border-radius: 1rem; background: var(--surface); }
.doc summary, .info .asked summary { padding: .6rem .85rem; font-weight: 800; cursor: pointer; }
.doc details p, .info .asked p { margin: 0; padding: 0 .85rem .75rem; }
label.check { display: flex; align-items: center; gap: .5rem; min-height: 2.75rem; font-size: .875rem; }
label.check input { width: auto; min-height: 0; margin: 0; }
.soon { margin-top: 2.5rem; }
.soon h2 { margin: 0 0 1rem; font-size: 1.5rem; }
.soon .contents { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 20rem), 1fr)); gap: 1rem;
  margin: 0; padding: 0; list-style: none; }
.soon .contents li { display: flex; gap: 1rem; align-items: center; padding: .875rem 1rem; border: 1px solid var(--line);
  border-radius: 1rem; background: var(--surface); }
.soon .contents img { width: 5rem; height: 5rem; flex: none; object-fit: contain; border-radius: .75rem;
  background: var(--stage); }
.soon .contents h3, .soon .contents p { margin: 0 0 .2rem; }
.reviews .contents { padding: 0; list-style: none; }
.reviews .contents li { margin: 0 0 .75rem; padding: .875rem 1rem; border: 1px solid var(--line); border-radius: 1rem;
  background: var(--surface); }
.reviews .contents p { margin: 0 0 .4rem; }
.reviews .text { white-space: pre-line; }
.tags { display: flex; flex-wrap: wrap; gap: .4rem; margin: 1rem 0 0; }
a.chip { color: inherit; text-decoration: none; }
a.chip:hover { border-color: var(--outline); }
.filters .tagged { align-self: center; margin: 0; font-size: .875rem; }

@media (max-width: 56.25rem) { .showcase { grid-template-columns: minmax(0, 1fr); gap: 1.25rem; } }
@media (max-width: 37.5rem) {
  .filters label.search { flex: 1 0 100%; }
  .filters input { width: 100%; min-width: 0; }
  .filters label { flex: 1 1 40%; }
  .line { grid-template-columns: 4.5rem minmax(0, 1fr); }
  .amount { grid-column: 2; align-items: flex-start; }
  .pay { max-width: none; }
}

/* Phones: smaller type and cards two across, so a page is shorter. This block comes last. Text boxes
   keep 16px, below which some phones zoom in on them. */
@media (max-width: 37.5rem) {
  :root { font-size: 93.75%; }
  input, select, textarea, .site .seek input { font-size: 16px; }
  .logo { font-size: 2.5rem; }
  .site .wide { padding-block: .375rem .625rem; column-gap: .5rem; }
  .site nav { gap: 0; }
  .site nav a { padding: 0 .625rem; font-size: .875rem; }
  .tools { gap: .375rem; }
  .tools .round { width: 2.75rem; height: 2.75rem; }
  main { padding-block: 1.25rem 2rem; }
  h1 { font-size: 1.75rem; }
  .head { margin-bottom: 1rem; }
  .doc h2 { font-size: 1.1875rem; }
  footer .wide { gap: .25rem; padding-block: 1rem; }
  footer nav { column-gap: 1rem; }

  .featured { padding: 1rem 1rem 1.25rem; }
  .reel .rail { column-gap: .75rem; }
  .feature { flex-basis: calc(50% - .375rem); }
  .stand { height: 13rem; }
  .stand, .stand :is(img, video) { border-radius: .875rem; }
  .stand img.cutout { border-radius: 0; }
  .stand .none strong { font-size: 1.0625rem; }
  .badge { top: .5rem; padding: .1rem .5rem; font-size: .6875rem; }

  .shelf { padding: 1.25rem 0 0; }
  .shelf h2 { margin-bottom: .75rem; font-size: 1.375rem; }
  .tile { flex-basis: 44%; gap: .375rem; }
  .frame { height: auto; aspect-ratio: 3 / 4; }
  .frame .none { font-size: .8125rem; }
  .tile .titled { font-size: .9375rem; }
  .shop-all { margin-top: .5rem; }
  .home > .note { margin: .875rem 0; font-size: .8125rem; }
  .spotlight { gap: 1rem; margin-top: 0; padding: 1.25rem 1rem; }
  .words { gap: .625rem; }
  .words h2 { font-size: 2.25rem; }
  .words p { font-size: .9375rem; }
  .words .amount-large { font-size: 1.625rem; }
  .display-case { height: 12rem; }

  .catalog { padding-top: 1rem; }
  .types { gap: .75rem .25rem; margin-top: .875rem; }
  .types button { width: 5.25rem; gap: .375rem; font-size: .6875rem; }
  .types .icon { width: 3.5rem; height: 3.5rem; }
  .types svg { width: 1.5rem; height: 1.5rem; }
  .bar { padding-block: .75rem; }
  .filters label { padding-inline: 0; }
  .products { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 1.5rem .75rem; }
  .product { gap: .375rem; }
  .product h3, .cost { font-size: .9375rem; }
  .product .note { font-size: .8125rem; }
  .product .add { padding-inline: .5rem; font-size: .875rem; }
  .picture .empty { font-size: .8125rem; }

  .top { padding-top: .75rem; }
  .crumbs { margin-bottom: .625rem; }
  .showcase { gap: .75rem; padding-bottom: 1.5rem; }
  .thumbs { grid-template-columns: repeat(4, minmax(0, 1fr)); gap: .5rem; margin-top: .5rem; }
  .summary h1 { font-size: 1.875rem; }
  .summary .lead { margin: .375rem 0; font-size: .9375rem; }
  .summary .offers { margin: .75rem 0 .5rem; }
  .offers { gap: .5rem; }
  .offer { gap: .5rem; padding: .625rem .875rem; }
  .price { font-size: 1.5rem; }
  .offer .buttons { flex-direction: row; gap: .5rem; }
  .offer .buttons > * { flex: 1; }
  .offer .buttons button:not(.quiet) { min-width: 0; }
  .before { margin: .625rem 0; padding: .625rem .875rem; }
  .facts dt, .facts dd { padding-block: .375rem; }
  .columns { flex-direction: column; gap: .5rem; padding-block: 1rem; }
  .columns > :is(section, details) { flex: none; }
  .info h2, .after h2, .related h2 { margin-bottom: .625rem; font-size: 1.25rem; }
  .after { padding-block: 1.5rem; }
  .steps { gap: .75rem; margin-bottom: 1rem; }
  .steps li::before { font-size: 1.25rem; }
  .related { padding-bottom: 2rem; }
}
/* The narrowest phones. */
@media (max-width: 23rem) {
  .site nav a { padding: 0 .3rem; font-size: .8125rem; }
  .tools { gap: .25rem; }
  .tools .round { width: 2.5rem; height: 2.5rem; }
}
