/* ============================================
   BAD APPLE DESIGNS — shared styles
   Dark & gritty, modern rat rod aesthetic
   ============================================ */

:root {
  --bg: #0a0c09;
  /* Raised from #121510. The alt sections are now 80% opaque so the blueprint
     shows through, which composited them down to ~#10130f and flattened the step
     between sections to roughly three quarters of what it was. This is the value
     that composites back to the original #121510 over --bg, so the banding reads
     exactly as designed while the watermark still comes through. */
  --bg-alt: #141712;
  /* Same color, translucent, so the blueprint watermark shows through an alt
     section instead of being painted over. Kept beside --bg-alt so the two
     cannot drift apart. rgba() rather than color-mix(): an unsupported
     color-mix drops the whole declaration, leaving the section with NO
     background at all. */
  --bg-alt-veil: rgba(20, 23, 18, 0.8);
  /* Lifted from #191d16, which sat only 7 points above --bg-alt and so read as
     the same color — cards had no visible edge against the section behind them.
     Darkening was the instinct but there is no room below: --bg is already
     near-black, so a darker panel converges with it (1.01 contrast) and the
     edges vanish entirely. Lighter is the only direction with headroom. */
  --panel: #282e20;
  /* Bad Apple green — pulled from the logo */
  --rust: #6faf2e;
  --rust-bright: #8cc63e;
  --rust-dark: #3d6318;
  --bone: #e8e6dc;
  --steel: #8a8f80;
  --line: #262b22;
  --font-display: 'Bebas Neue', 'Oswald', sans-serif;
  --font-body: 'Barlow', 'Inter', sans-serif;
}

* { margin: 0; padding: 0; box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  background: var(--bg);
  color: var(--bone);
  font-family: var(--font-body);
  line-height: 1.6;
  /* subtle grain texture */
  background-image:
    radial-gradient(ellipse at 20% 0%, rgba(140, 198, 62, 0.05), transparent 50%),
    url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='120' height='120'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='2'/%3E%3C/filter%3E%3Crect width='120' height='120' filter='url(%23n)' opacity='0.04'/%3E%3C/svg%3E");
}

img { max-width: 100%; display: block; }

a { color: var(--rust-bright); text-decoration: none; }
a:hover { color: var(--bone); }

.container { max-width: 1200px; margin: 0 auto; padding: 0 24px; }

/* ---------- Nav ---------- */
.nav {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(13, 13, 13, 0.92);
  backdrop-filter: blur(8px);
  border-bottom: 1px solid var(--line);
}

.nav-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 14px 24px;
  max-width: 1200px;
  margin: 0 auto;
}

.nav-logo {
  font-family: var(--font-display);
  font-size: 1.7rem;
  letter-spacing: 0.08em;
  color: var(--bone);
  display: flex;
  align-items: center;
  gap: 12px;
}

.nav-logo span { color: var(--rust-bright); }

/* The wordmark gives way, never the menu button. In Bebas Neue it fits beside
   the button and the cart at every phone width; in the fallback font (shown
   while Bebas loads, and for good if Google Fonts is blocked) it is far wider
   and used to push the button off-screen and the page sideways. Shrinkable and
   clipped instead, so the header always holds the viewport; no change when
   Bebas has loaded (2026-10-10). */
.nav-logo { flex: 0 1 auto; min-width: 0; overflow: hidden; white-space: nowrap; }
.nav-logo img { flex: none; }
.nav-toggle, .cart-indicator { flex: none; }

.nav-logo img { height: 56px; width: auto; }

.nav-links { display: flex; gap: 28px; list-style: none; }

.nav-links a {
  color: var(--steel);
  font-size: 0.85rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  transition: color 0.2s;
}

.nav-links a:hover, .nav-links a.active { color: var(--rust-bright); }

.nav-toggle {
  display: none;
  background: none;
  border: none;
  color: var(--bone);
  font-size: 1.6rem;
  cursor: pointer;
}

/* ---------- Hero ---------- */
.hero {
  min-height: 88vh;
  display: flex;
  align-items: center;
  position: relative;
  overflow: hidden;
  background:
    linear-gradient(160deg, rgba(10,12,9,0.5) 0%, rgba(10,12,9,0.92) 70%),
    linear-gradient(20deg, #1c2b10 0%, #10150a 45%, #0a0c09 100%);
}

.hero::after {
  /* diagonal green streak */
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(115deg, transparent 55%, rgba(140, 198, 62, 0.08) 55.2%, rgba(140, 198, 62, 0.08) 62%, transparent 62.2%);
  pointer-events: none;
}

/* rat rod silhouette blended into the hero background —
   anchored bottom-left, wide enough that the floating logo
   on the right drifts over its tail end */
.hero-ratrod {
  position: absolute;
  bottom: -2%;
  left: -4%;
  width: min(1100px, 96vw);
  height: auto;
  opacity: 0.5;
  z-index: 0;
  pointer-events: none;
  filter: drop-shadow(0 0 40px rgba(140, 198, 62, 0.15));
}

.hero-content {
  position: relative;
  z-index: 2;
  /* Vertical only. This element is also a .container, and a `padding` shorthand
     here beats .container's `0 24px` (equal specificity, later in the file),
     zeroing the horizontal gutter — hero text then ran flush to the screen edge
     on every page with a hero, at any viewport under ~1250px. */
  padding-top: 80px;
  padding-bottom: 80px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 48px;
}

.hero-text { flex: 1 1 420px; min-width: 0; max-width: 620px; }

/* big free-floating logo — drifts and tilts, but owns its own column
   so it can never sit on top of the text at any screen width */
.hero-logo {
  flex: 0 1 auto;
  width: clamp(240px, 34vw, 460px);
  min-width: 200px;
  height: auto;
  margin-right: -28px; /* bleeds toward the page edge, away from the words */
  z-index: 1;
  pointer-events: none;
  filter: drop-shadow(0 0 50px rgba(140, 198, 62, 0.45));
  animation: logoFloat 7s ease-in-out infinite alternate;
}

@keyframes logoFloat {
  from { transform: translateY(-10px) rotate(-4deg); }
  to   { transform: translateY(10px) rotate(-1deg); }
}

.hero-kicker {
  color: var(--rust-bright);
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.3em;
  font-size: 0.8rem;
  margin-bottom: 16px;
}

.hero h1 {
  font-family: var(--font-display);
  font-size: clamp(3.2rem, 9vw, 7rem);
  line-height: 0.95;
  letter-spacing: 0.02em;
  text-transform: uppercase;
  color: var(--bone);
}

.hero h1 .accent { color: var(--rust-bright); display: block; }

/* "Rust." — mottled oxidized iron: rust-tone gradient with baked-in noise texture */
.word-rust {
  background-image:
    url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='180' height='180'%3E%3Cfilter id='r'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.32' numOctaves='4' seed='7'/%3E%3CfeColorMatrix type='matrix' values='0 0 0 0 0.38  0 0 0 0 0.16  0 0 0 0 0.04  0 0 0 0.75 0'/%3E%3C/filter%3E%3Crect width='180' height='180' filter='url(%23r)'/%3E%3C/svg%3E"),
    linear-gradient(172deg, #e07a33 0%, #b34d18 26%, #7c3410 48%, #c25c1f 66%, #8a3a0f 82%, #5c2408 100%);
  background-blend-mode: multiply;
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  filter: drop-shadow(0 2px 3px rgba(0, 0, 0, 0.55));
}

/* "Steel." — polished chrome: mirror gradient with a hard horizon line */
.word-steel {
  background-image: linear-gradient(180deg,
    #fdfeff 0%,
    #d9e0e7 22%,
    #aab4bf 38%,
    #78828d 47%,
    #2f353c 50%,
    #9aa4af 53%,
    #d2dae1 66%,
    #f4f8fb 78%,
    #79838e 92%,
    #a9b3bd 100%);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  filter: drop-shadow(0 2px 3px rgba(0, 0, 0, 0.55)) drop-shadow(0 0 14px rgba(220, 235, 250, 0.18));
}

.hero p.lede {
  max-width: 560px;
  margin-top: 24px;
  font-size: 1.15rem;
  color: var(--steel);
}

.hero-cta { margin-top: 36px; display: flex; gap: 16px; flex-wrap: wrap; }

.btn {
  display: inline-block;
  padding: 14px 32px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.14em;
  font-size: 0.85rem;
  border: 2px solid var(--rust-bright);
  transition: all 0.2s;
}

.btn-solid { background: var(--rust-bright); color: #0a0c09; }
.btn-solid:hover { background: transparent; color: var(--rust-bright); }
.btn-ghost { color: var(--bone); border-color: var(--steel); }
.btn-ghost:hover { border-color: var(--rust-bright); color: var(--rust-bright); }

/* ---------- Compact hero (commission page) ----------
   The default .hero is min-height: 88vh, which is viewport-relative — so it
   consumes 88% of ANY screen and the form below it can never peek above the
   fold to signal that it's there. On a page whose entire purpose is the form,
   the hero is a header band, not a stage. */
.hero.hero-compact {
  min-height: 0;
  padding: 24px 0 0;
}

/* padding-top/bottom only — NOT the `padding` shorthand. .hero-content is also
   a .container, which supplies the 24px horizontal padding; a shorthand here
   silently resets that to 0 and the hero text runs to the screen edge while
   everything below it stays correctly inset. */
.hero.hero-compact .hero-content {
  padding-top: 8px;
  padding-bottom: 20px;
  gap: 28px;
  align-items: center;
}

/* Nav already shows the logo; here it's an accent, not the main event.
   Animation dropped too — a drifting logo next to a form is a distraction. */
.hero.hero-compact .hero-logo {
  width: clamp(110px, 13vw, 175px);
  margin-right: 0;
  animation: none;
  filter: drop-shadow(0 0 28px rgba(140, 198, 62, 0.35));
}

.hero.hero-compact h1 { font-size: clamp(2rem, 4.4vw, 3.2rem); }
.hero.hero-compact .hero-kicker { margin-bottom: 10px; }
.hero.hero-compact p.lede { font-size: 1.02rem; margin-top: 12px; max-width: 640px; }

/* Keep the rat rod, but as texture rather than a feature. */
.hero.hero-compact .hero-ratrod {
  width: min(760px, 82vw);
  opacity: 0.3;
  bottom: -8%;
}

/* Pull the form up under the compact hero instead of the default 90px gap. */
#commission-form-section { padding-top: 18px; }

/* Replaces the removed section-head: one line of context, matched to the
   card's width so it reads as part of the form rather than a new section. */
.form-intro {
  color: var(--steel);
  font-size: 1rem;
  max-width: 640px;
  margin: 0 auto 18px;
}

@media (max-width: 820px) {
  /* Drop the hero logo on narrow screens: the nav bar two inches above already
     shows it, and in a flex row it competes with the text for width. */
  .hero.hero-compact .hero-logo { display: none; }
  .hero.hero-compact h1 { font-size: clamp(1.9rem, 8vw, 2.5rem); }
  .hero.hero-compact { padding-top: 16px; }
  .hero.hero-compact p.lede { font-size: 0.98rem; }
}

/* ---------- Sections ---------- */
section { padding: 90px 0; }

/* Every in-page anchor target must clear the sticky nav.
   This existed only on .inv-cat-head, so jumping to #about, #gallery, #contact
   and friends put the section's top edge UNDERNEATH the 85px bar. It is most
   obvious on a phone, where the nav is proportionally taller and the menu
   drawer closing hands you straight to a heading tucked behind it. */
section[id] { scroll-margin-top: 96px; }
/* Translucent rather than solid, so the blueprint watermark carries through the
   alt sections instead of vanishing behind them. At 0.80 the tonal step between
   a normal and an alt section still reads; the drawing just survives it. */
section.alt { background: var(--bg-alt-veil); }

.section-head { margin-bottom: 48px; }

.section-head .kicker {
  color: var(--rust-bright);
  text-transform: uppercase;
  letter-spacing: 0.28em;
  font-size: 0.75rem;
  font-weight: 700;
}

.section-head h2 {
  font-family: var(--font-display);
  font-size: clamp(2.2rem, 5vw, 3.4rem);
  text-transform: uppercase;
  letter-spacing: 0.03em;
  margin-top: 6px;
}

.section-head p { color: var(--steel); max-width: 640px; margin-top: 10px; }

/* ---------- Gallery ---------- */
.gallery-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 20px;
}

.art-card {
  display: block;
  color: inherit;
  background: var(--panel);
  border: 1px solid var(--line);
  overflow: hidden;
  transition: transform 0.25s, border-color 0.25s;
}

.art-card:hover { transform: translateY(-4px); border-color: var(--rust); color: inherit; }

.art-card:hover .tag { background: var(--rust-bright); color: #0a0c09; border-color: var(--rust-bright); }

.art-img {
  /* 4:5 PORTRAIT, matched to the photos rather than to a habit.
     This was 4/3 landscape while 25 of the 28 product photos are portrait
     (median aspect 0.79, against 1.33 for the box). background-size: cover then
     centres on the whole garment — shoulders and hem included — so the printed
     design landed near an edge or was clipped outright, and because the source
     aspects run 0.54 to 1.80 some cards cropped top/bottom while others cropped
     left/right. That inconsistency was the visible symptom.
     4/5 = 0.80 is almost exactly the median: average visibility goes from 65%
     to 80%, and the number of photos losing more than 40% drops from 15 to 3.
     The three that still crop are the genuinely landscape ones (patch, hat,
     locker room), which now lose a little width instead of most of their height. */
  aspect-ratio: 4 / 5;
  background:
    linear-gradient(135deg, #222a1c 0%, #131710 60%, #1a2112 100%);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--steel);
  font-size: 0.8rem;
  text-transform: uppercase;
  letter-spacing: 0.2em;
  border-bottom: 2px solid var(--rust-dark);
}

/* Carousel: stacked slides, moved by a shared JS timer (startGalleryCarousels).
   The next photo slides in from the right OVER the current one, which stays
   solid underneath (.leaving) until it is covered (Ken, 2026-11-14). A
   cross-fade showed two shirts blended at once, which read as blurry.
   GALLERY_STEP_MS in index.js counts the 0.5 s slide. */
.art-carousel { position: relative; overflow: hidden; }

.art-carousel-slide {
  position: absolute;
  inset: 0;
  background-size: cover;
  background-position: center;
  visibility: hidden;
  transform: translateX(100%);
}

.art-carousel-slide.leaving { visibility: visible; transform: none; z-index: 1; }
.art-carousel-slide.active {
  visibility: visible;
  transform: none;
  z-index: 2;
  transition: transform 0.5s ease-out;
}

/* No sliding for visitors who ask their device for less motion: an instant swap. */
@media (prefers-reduced-motion: reduce) {
  .art-carousel-slide.active { transition: none; }
}

/* Gallery-card-sized Coming Soon, same look as the Inventory page's full banner */
.art-coming-soon {
  border: 2px dashed var(--rust-dark);
  background:
    repeating-linear-gradient(-45deg,
      rgba(140, 198, 62, 0.05) 0 18px,
      transparent 18px 36px),
    var(--panel);
}

.art-coming-soon .acs-title {
  font-family: var(--font-display);
  font-size: 1.4rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--rust-bright);
  text-shadow: 0 0 24px rgba(140, 198, 62, 0.35);
}

.art-card .art-info { padding: 18px 20px; }

.art-card h3 {
  font-family: var(--font-display);
  font-size: 1.3rem;
  letter-spacing: 0.05em;
  text-transform: uppercase;
}

.art-card p { color: var(--steel); font-size: 0.9rem; margin-top: 4px; }

.tag {
  display: inline-block;
  margin-top: 10px;
  padding: 3px 10px;
  font-size: 0.7rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  color: var(--rust-bright);
  border: 1px solid var(--rust-dark);
}

/* ---------- About ---------- */
.about-grid {
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;
  gap: 56px;
  align-items: center;
}

.about-text p { color: var(--steel); margin-bottom: 18px; font-size: 1.05rem; }
.about-text p strong { color: var(--bone); }

.about-photo {
  aspect-ratio: 1 / 1;
  background: linear-gradient(160deg, #222a1c, #10140c);
  border: 1px solid var(--line);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--steel);
  text-transform: uppercase;
  letter-spacing: 0.2em;
  font-size: 0.8rem;
  position: relative;
  overflow: hidden;
}

.about-photo img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  /* solid white backdrop — the stencil hangs like a print on the dark wall */
  background: #fff;
}

.about-photo::before {
  content: '';
  position: absolute;
  inset: 12px;
  border: 1px solid var(--rust-dark);
  pointer-events: none;
}

/* ---------- Moments ---------- */
.moments-grid {
  display: grid;
  grid-template-columns: 0.95fr 1.05fr;
  gap: 56px;
  align-items: center;
}

.moments-text p { color: var(--steel); margin-bottom: 18px; font-size: 1.05rem; }
.moments-text p strong { color: var(--bone); }

.moments-slideshow { display: flex; justify-content: center; }
/* The polaroid is tilted a random 3-9 degrees on every photo, and on a phone
   the rotated corner reached 2-4px past the screen's right edge — enough to
   make the whole page slide sideways under a thumb. Trim horizontal overflow
   at the section. `clip` (not `hidden`) so no scroll container is created;
   `hidden` first for browsers that predate `clip`. */
#moments { overflow-x: hidden; overflow-x: clip; }

/* Single <img> whose src is swapped by JS (not 58 stacked slides) so the
   page only ever pays for one photo in flight, however large the reel gets. */
.moment-frame {
  position: relative;
  box-sizing: border-box;
  width: 100%;
  max-width: 420px;
  aspect-ratio: 4 / 5;
  background: var(--panel);
  overflow: hidden;
}

.moment-frame img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0;
  transition: opacity 0.6s ease;
}

.moment-frame img.loaded { opacity: 1; }

/* Shared worn-photo grain, one CSS gradient reused by every frame instead
   of a texture image per photo. */
.moment-frame::after {
  content: '';
  position: absolute;
  inset: 0;
  pointer-events: none;
  background: repeating-linear-gradient(-45deg,
    rgba(232, 230, 220, 0.045) 0 3px,
    transparent 3px 6px);
  mix-blend-mode: overlay;
}

/* Polaroid treatment. Rotation is set inline per-slide by JS (a random
   angle each time) so the reel doesn't look identically tilted every photo. */
.moment-frame.frame-polaroid {
  padding: 16px 16px 44px;
  background: var(--bone);
  box-shadow: 0 14px 30px rgba(0, 0, 0, 0.45);
  /* rotation is set inline per-slide with no transition -- it should
     appear already at its angle, not visibly turn into place */
}

.stat-row { display: flex; gap: 40px; margin-top: 30px; flex-wrap: wrap; }

.stat .num {
  font-family: var(--font-display);
  font-size: 2.6rem;
  color: var(--rust-bright);
  line-height: 1;
}

.stat .label {
  color: var(--steel);
  font-size: 0.75rem;
  text-transform: uppercase;
  letter-spacing: 0.15em;
  margin-top: 4px;
}

/* ---------- Events ---------- */
.event-card {
  display: grid;
  grid-template-columns: auto 1fr auto;
  gap: 28px;
  align-items: center;
  background: var(--panel);
  border: 1px solid var(--line);
  border-left: 4px solid var(--rust-bright);
  padding: 28px 32px;
  margin-bottom: 16px;
}

.event-date {
  font-family: var(--font-display);
  text-align: center;
  min-width: 80px;
}

.event-date .month { color: var(--rust-bright); font-size: 1rem; letter-spacing: 0.2em; text-transform: uppercase; }
.event-date .day { font-size: 2.4rem; line-height: 1; }
/* Only present on exact dates, where the big number is a day. Sized and
   colored like .month so the box reads month / day / year top to bottom
   without competing with the day. */
.event-date .year {
  font-size: 0.85rem;
  letter-spacing: 0.16em;
  color: var(--steel);
  margin-top: 2px;
}

.event-card h3 { font-family: var(--font-display); font-size: 1.5rem; letter-spacing: 0.04em; text-transform: uppercase; }
.event-card p { color: var(--steel); font-size: 0.95rem; margin-top: 4px; }

/* Off-season state: shown when nothing is upcoming but there are past shows.
   Steel accent rather than green — this is history, not something to plan around. */
.event-offseason {
  background: var(--panel);
  border: 1px solid var(--line);
  border-left: 4px solid var(--steel);
  padding: 32px;
  margin-bottom: 36px;
}

.event-offseason h3 {
  font-family: var(--font-display);
  font-size: clamp(1.8rem, 4vw, 2.4rem);
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--bone);
}

.event-offseason p { color: var(--steel); margin-top: 8px; max-width: 620px; }

.past-events-head {
  color: var(--steel);
  font-size: 0.75rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.28em;
  margin-bottom: 14px;
}

.event-card.is-past { border-left-color: var(--steel); opacity: 0.72; }
.event-card.is-past .event-date .month { color: var(--steel); }

.event-flag {
  font-size: 0.7rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.14em;
  color: #0a0c09;
  background: var(--rust-bright);
  padding: 5px 12px;
  white-space: nowrap;
}

/* ---------- Contact ---------- */
.contact-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 56px; }

.contact-list { list-style: none; margin-top: 20px; }

.contact-list li {
  padding: 16px 0;
  border-bottom: 1px solid var(--line);
  display: flex;
  gap: 14px;
  align-items: baseline;
}

.contact-list .label {
  color: var(--rust-bright);
  font-weight: 700;
  text-transform: uppercase;
  font-size: 0.75rem;
  letter-spacing: 0.15em;
  min-width: 90px;
}

.commission-box {
  background: var(--panel);
  border: 1px solid var(--line);
  padding: 32px;
}

.commission-box h3 { font-family: var(--font-display); font-size: 1.6rem; text-transform: uppercase; letter-spacing: 0.04em; }
.commission-box p { color: var(--steel); margin: 14px 0 24px; }

/* ---------- Commission form ---------- */
.commission-card { position: relative; max-width: 640px; margin: 0 auto; transition: opacity 0.6s ease, transform 0.6s ease; }
.commission-card.poof-out { opacity: 0; transform: scale(0.96); }

.commission-success { max-width: 640px; margin: 0 auto; text-align: center; }
.commission-success h3 { font-family: var(--font-display); font-size: 2rem; text-transform: uppercase; letter-spacing: 0.06em; color: var(--rust-bright); }

.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; }
@media (max-width: 640px) { .form-row { grid-template-columns: 1fr; } }

.form-field { margin-bottom: 22px; }

.form-field label {
  display: block;
  font-size: 1rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--bone);
  margin-bottom: 8px;
}

.form-field input, .form-field textarea {
  width: 100%;
  background: var(--bg);
  border: 1px solid var(--line);
  color: var(--bone);
  padding: 14px 16px;
  font-family: var(--font-body);
  font-size: 1.1rem;
  resize: vertical;
}

.form-field input:focus, .form-field textarea:focus { outline: 1px solid var(--rust); }

.form-field label .optional { font-weight: 400; text-transform: none; letter-spacing: 0; color: var(--steel); }

/* The needed-by date, drawn by us: iPhone Safari ignores width and padding on
   a native date field, which would leave it shorter than the boxes above. */
.form-field input[type="date"] {
  -webkit-appearance: none;
  appearance: none;
  border-radius: 0;
  min-height: 56px;
  text-align: left;
}
.form-field input[type="date"]::-webkit-date-and-time-value { text-align: left; }

.form-field input::placeholder, .form-field textarea::placeholder { color: var(--steel); opacity: 1; }

.commission-card .char-count { color: var(--bone); font-size: 0.95rem; text-align: right; margin-top: 4px; }

.commission-card .field-error-msg { color: var(--rust-bright); font-size: 1rem; font-weight: 600; margin-top: 6px; min-height: 1.2em; }

.field-error { border-color: var(--rust-bright) !important; animation: fieldShake 0.4s; }

@keyframes fieldShake {
  0%, 100% { transform: translateX(0); }
  25% { transform: translateX(-4px); }
  75% { transform: translateX(4px); }
}

/* exhaust-smoke poof played on successful submission */
.smoke-puff {
  position: absolute;
  top: 50%;
  left: 50%;
  width: 70px;
  height: 70px;
  margin: -35px 0 0 -35px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(138, 143, 128, 0.55) 0%, rgba(138, 143, 128, 0) 70%);
  opacity: 0;
  pointer-events: none;
}

.commission-card.poof-out .smoke-puff { animation: smokePuff 0.9s ease-out forwards; }
.commission-card.poof-out .smoke-puff:nth-child(2) { animation-delay: 0.1s; margin-left: -60px; }
.commission-card.poof-out .smoke-puff:nth-child(3) { animation-delay: 0.2s; margin-left: -10px; }

@keyframes smokePuff {
  0% { opacity: 0.7; transform: scale(0.4) translateY(0); }
  100% { opacity: 0; transform: scale(2.2) translateY(-40px); }
}

/* ---------- Inventory page ---------- */
.inv-toolbar {
  display: flex;
  gap: 16px;
  flex-wrap: wrap;
  align-items: center;
  margin-bottom: 28px;
}

.inv-toolbar input[type="search"], .inv-toolbar select {
  background: var(--panel);
  border: 1px solid var(--line);
  color: var(--bone);
  padding: 12px 16px;
  font-family: var(--font-body);
  font-size: 0.95rem;
  min-width: 220px;
}

.inv-toolbar input:focus, .inv-toolbar select:focus { outline: 1px solid var(--rust); }

.inv-count { color: var(--steel); font-size: 0.85rem; margin-left: auto; }

.inv-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
  gap: 20px;
}

.inv-card {
  background: var(--panel);
  border: 1px solid var(--line);
  padding: 22px 24px;
  display: flex;
  flex-direction: column;
  gap: 8px;
  transition: border-color 0.2s;
}

.inv-card:hover { border-color: var(--rust); }

.inv-card h3 { font-family: var(--font-display); font-size: 1.35rem; letter-spacing: 0.04em; text-transform: uppercase; }
.inv-card .desc { color: var(--steel); font-size: 0.9rem; flex: 1; }
/* The item's options note ("Always black. Choose the logo color."), on its own
   line under the description, in its colour and one step smaller, so it fits
   one line on the narrowest card (218px, iPad landscape) (Chad, 2026-10-10). */
.inv-card .desc-note { display: block; margin-top: 4px; font-size: 0.85rem; }

.inv-meta { display: flex; justify-content: space-between; align-items: center; margin-top: 10px; }

.inv-price { font-family: var(--font-display); font-size: 1.5rem; color: var(--rust-bright); }

/* Shown where the price would be, for pieces quoted per job. Sized to sit on
   the same baseline as .inv-price so the card's rhythm does not change, but
   styled as the link it is rather than imitating a figure. */
.inv-enquire {
  font-family: var(--font-display);
  font-size: 1.15rem;
  letter-spacing: 0.04em;
  color: var(--rust-bright);
  text-decoration: none;
  border-bottom: 1px solid var(--rust-dark);
}
.inv-enquire:hover,
.inv-enquire:focus-visible { color: var(--bone); border-bottom-color: var(--bone); }

.badge {
  font-size: 0.68rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  padding: 4px 10px;
  border: 1px solid;
}

.badge-available { color: #7fbf6a; border-color: #3d5c34; }
.badge-custom { color: var(--bone); border-color: var(--rust); }

/* ---------- Full-image preview (inventory) ----------
   The card is a 4/3 landscape crop of a portrait photo, so the whole garment is
   never visible on the grid. Clicking a card photo opens it uncropped. */

body.preview-open { overflow: hidden; }        /* don't scroll the page behind it */

.art-img-zoom { cursor: zoom-in; }
.art-img-zoom:focus-visible { outline: 2px solid var(--rust-bright); outline-offset: 3px; }

.preview-overlay {
  position: fixed;
  inset: 0;
  z-index: 2000;
  background: rgba(8, 10, 7, 0.93);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 26px 18px;
}

/* The box only positions the close button — it must NOT constrain width.
   Giving it `max-width` while the image inside was `width: 100%` created a
   circular sizing dependency as a flex child, and the image collapsed to 2x2. */
.preview-box { position: relative; }

/* The image sizes ITSELF from its intrinsic dimensions and is merely capped:
   never wider than the file's natural 640px (so it is never upscaled into
   softness) and never taller than the viewport. */
.preview-img {
  display: block;
  width: auto;
  height: auto;
  max-width: min(640px, 92vw);
  max-height: 82vh;
  object-fit: contain;                          /* the WHOLE image, never cropped */
  border: 1px solid var(--line);
  background: #0d100b;
}

.preview-caption {
  margin: 10px 0 0;
  text-align: center;
  color: var(--bone);
  font-size: 0.9rem;
  letter-spacing: 0.04em;
}

.preview-close {
  position: absolute;
  top: -15px;
  right: -15px;
  width: 40px;
  height: 40px;
  border: none;
  border-radius: 50%;
  background: var(--rust);
  color: #0d100b;
  font-size: 1.5rem;
  line-height: 1;
  cursor: pointer;
}
.preview-close:focus-visible { outline: 2px solid var(--bone); outline-offset: 2px; }

/* On a narrow screen the corner button would sit off-canvas, so it moves inside
   the image. It does NOT shrink: 44x44 is the minimum comfortable touch target,
   and this is the only way out of the overlay on a phone. */
@media (max-width: 560px) {
  .preview-close { top: 6px; right: 6px; width: 44px; height: 44px; font-size: 1.4rem; }
}  /* made-to-order — an invitation, never struck through like "sold" */
/* Coming Soon: rust rather than green, so it never reads as "you can buy this
   now". Distinct from sold, which is struck through. */
.badge-coming { color: var(--rust-bright); border-color: var(--rust-dark); }
/* Fallback for a status the site does not recognise — deliberately makes no
   availability claim either way. */
.badge-neutral { color: var(--steel); border-color: var(--line); }

.inv-status-msg { color: var(--steel); padding: 40px 0; text-align: center; }

/* category section headers on the inventory page */
.inv-cat-head {
  margin: 56px 0 20px;
  padding-bottom: 10px;
  border-bottom: 2px solid var(--rust-dark);
  scroll-margin-top: 90px; /* clears the sticky nav when jumping */
}

.inv-cat-head:first-child { margin-top: 8px; }

.inv-cat-head h3 {
  font-family: var(--font-display);
  font-size: 1.9rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--bone);
}

.inv-cat-head p { color: var(--steel); font-size: 0.9rem; margin-top: 2px; }

/* coming-soon banner for categories with nothing in stock */
.coming-soon {
  border: 2px dashed var(--rust-dark);
  background:
    repeating-linear-gradient(-45deg,
      rgba(140, 198, 62, 0.05) 0 18px,
      transparent 18px 36px),
    var(--panel);
  padding: 40px 32px;
  text-align: center;
}

.coming-soon .cs-title {
  font-family: var(--font-display);
  font-size: clamp(2rem, 5vw, 2.8rem);
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--rust-bright);
  text-shadow: 0 0 24px rgba(140, 198, 62, 0.35);
}

.coming-soon p { color: var(--steel); margin-top: 8px; max-width: 480px; margin-inline: auto; }

/* ---------- Footer ---------- */
footer {
  border-top: 1px solid var(--line);
  padding: 40px 0;
  text-align: center;
  color: var(--steel);
  font-size: 0.85rem;
}

footer .foot-logo {
  font-family: var(--font-display);
  font-size: 1.4rem;
  letter-spacing: 0.08em;
  color: var(--bone);
  margin-bottom: 8px;
}

footer .foot-logo span { color: var(--rust-bright); }

footer .foot-logo img { height: 56px; width: auto; margin: 0 auto 12px; }

/* Agency attribution — subtle, below the copyright. */
footer .powered-by { margin-top: 14px; font-size: 0.78rem; opacity: 0.7; }
footer .powered-by a { color: var(--rust-bright); text-decoration: none; }
footer .powered-by a:hover { text-decoration: underline; }

/* ---------- Responsive ---------- */
@media (max-width: 900px) {
  /* stack: logo centered above the text */
  /* padding-top/bottom only — see the note on .hero-content above. */
  .hero-content { flex-direction: column; gap: 36px; padding-top: 56px; padding-bottom: 56px; }
  .hero-logo { width: min(60vw, 300px); min-width: 0; margin: 0 auto; }
  .hero-text { max-width: none; flex: initial; }
}

@media (max-width: 820px) {
  .nav-links {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: var(--bg);
    flex-direction: column;
    gap: 0;
    padding: 12px 24px 20px;
    border-bottom: 1px solid var(--line);
  }
  .nav-links.open { display: flex; }
  .nav-links li { padding: 10px 0; }
  .nav-toggle { display: block; }
  .about-grid, .contact-grid, .moments-grid { grid-template-columns: 1fr; }
  .event-card { grid-template-columns: auto 1fr; }
  .event-flag { grid-column: 2; justify-self: start; }
  section { padding: 60px 0; }
}


/* ---------- Ken's chassis blueprint, as a page watermark ----------
   His own hand-drawn rat rod: top view, frame profile and side elevation, with
   the real dimensions still pencilled on it.

   The source is dark pencil on light paper — the inverse of this site — so the
   linework is extracted to a transparent PNG (line darkness becomes the alpha
   channel) rather than dimming a photograph of paper. A dimmed photo would drop
   a grey rectangle onto the page; this leaves only the drawing.

   Fixed rather than absolute: the page scrolls past a stationary drawing, so the
   hero sits over the chassis and the form over the side elevation. pointer-events
   is off so it can never intercept a click on the form behind it. */
.blueprint-bg {
  position: fixed;
  inset: 0;
  /* -1, not 0. At 0 this sat in the normal stacking order, which meant every
     other element had to be lifted above it — and that lifting is what broke the
     site: a blanket `position: relative` overrode the nav's `position: sticky`
     (header stopped sticking) and its `z-index: 100` (the mobile drawer opened
     underneath the page). A negative index puts the watermark behind in-flow
     content on its own, so nothing else needs touching. It still paints above
     the body's background, so the drawing remains visible. */
  z-index: -1;
  pointer-events: none;
  background-image: url('../images/rat-rod-blueprint-lines.png');
  background-repeat: no-repeat;
  background-position: center 55%;
  background-size: min(1100px, 88vw);
  opacity: 0.09;
}


/* A drawing this fine turns to mush below phone width, and it is decoration —
   nothing is lost by dropping it. */
@media (max-width: 700px) { .blueprint-bg { display: none; } }

@media (prefers-reduced-motion: reduce) { .blueprint-bg { position: absolute; } }

/* ==========================================================
   Commerce: buy controls and the cart indicator
   Rendered only when the launch gate is open — see js/buy.js.
   ========================================================== */

.buy-controls {
  display: flex;
  flex-direction: column;
  gap: .55rem;
  margin-top: .75rem;
}

.buy-row {
  display: flex;
  gap: .5rem;
  align-items: center;
  flex-wrap: wrap;
}

/* --- print color swatches --- */

/* ONE row, always. At 1.65rem with wrapping, seven print colors needed 223px
   and the narrowest card has 212, so Purple Glitter dropped onto a line of its
   own. Now each circle is 1.5rem (24px, still the WCAG minimum target) — seven
   take 206px — and the columns are minmax(0, 1.5rem), so an item with more
   colors than fit shrinks every circle a little instead of wrapping. */
.buy-swatches {
  display: grid;
  grid-auto-flow: column;
  grid-auto-columns: minmax(0, 1.5rem);
  justify-content: start;
  gap: .4rem;
}
/* A full row spans the size box's width: first circle on its left edge, last
   on its right. Left-packed, seven circles stopped ~28px short of the box and
   the ragged right edge read as misaligned. Only from five colors up — two or
   three spread edge to edge would look scattered rather than aligned. Without
   :has() support the row simply stays left-packed. */
.buy-swatches:has(> .swatch:nth-child(5)) { justify-content: space-between; }

.swatch {
  width: 100%;
  height: auto;
  aspect-ratio: 1;
  padding: 0;
  border: 2px solid var(--rust);
  border-radius: 50%;
  cursor: pointer;
  background: var(--bg-alt);
  /* Sits on a dark card, so a dark swatch needs an edge of its own to read as
     a circle rather than a hole. */
  box-shadow: inset 0 0 0 1px rgba(0, 0, 0, .35);
  transition: transform .12s ease, border-color .12s ease;
}

.swatch:hover { transform: scale(1.12); }

.swatch.is-chosen {
  border-color: var(--bone);
  transform: scale(1.12);
  box-shadow: inset 0 0 0 1px rgba(0, 0, 0, .35), 0 0 0 2px var(--rust-bright);
}

/* A color with no hex still has to be visible and identifiable, or a missing
   value in the catalogue looks like a rendering bug instead of missing data. */
.swatch-unset {
  font-family: var(--font-display);
  font-size: .62rem;
  color: var(--bone);
  background: var(--bg-alt);
  border-style: dashed;
}

/* Keyboard users get the same affordance as the pointer hover. */
.swatch:focus-visible {
  outline: 2px solid var(--rust-bright);
  outline-offset: 2px;
}

.buy-size {
  flex: 1 1 8rem;
  min-width: 0;                 /* lets it shrink inside the card grid */
  padding: .45rem .6rem;
  background: var(--bg-alt);
  color: var(--bone);
  border: 1px solid var(--rust);
  border-radius: 3px;
  font-family: inherit;
  font-size: .9rem;
}

.buy-add {
  flex: 0 0 auto;
  padding: .5rem 1rem;
  background: var(--rust);
  color: var(--bone);
  border: 1px solid var(--rust-bright);
  border-radius: 3px;
  font-family: var(--font-display);
  font-size: .95rem;
  letter-spacing: .04em;
  cursor: pointer;
  transition: background .15s ease, opacity .15s ease;
}

.buy-add:hover:not([disabled]) { background: var(--rust-bright); }

/* Disabled means "choose a size first". Kept legible rather than ghosted —
   a control you cannot read is a control you cannot act on. */
.buy-add[disabled] { opacity: .55; cursor: not-allowed; }

.buy-add.is-added {
  background: var(--bg-alt);
  color: var(--rust-bright);
  border-color: var(--rust-bright);
}

/* --- header indicator --- */

.cart-indicator {
  position: relative;
  display: inline-flex;
  align-items: center;
  gap: .3rem;
  margin-left: auto;
  margin-right: .75rem;
  padding: .3rem .5rem;
  color: var(--bone);
  text-decoration: none;
  font-size: 1.05rem;
  line-height: 1;
}

.cart-indicator:hover { color: var(--rust-bright); }

/* The `hidden` attribute only works if nothing sets a display.
   `.cart-indicator { display: inline-flex }` has the same specificity as a bare
   `[hidden]` rule and comes later, so the element stayed visible showing "0" —
   caught in the local preview, not by reading the code.
   Scoped rather than a global `[hidden] { display: none !important }`, because
   this stylesheet already ships on a live site and a blanket !important is a
   wide change to make for one element. */
.cart-indicator[hidden] { display: none; }

.cart-count {
  min-width: 1.35em;
  padding: .1em .35em;
  background: var(--rust);
  color: var(--bone);
  border-radius: 999px;
  font-family: var(--font-display);
  font-size: .78rem;
  text-align: center;
}

/* The nav toggle only appears on narrow screens, so on mobile the indicator
   sits beside it rather than pushing it off the row. */
@media (max-width: 720px) {
  .cart-indicator { margin-left: auto; margin-right: .5rem; }
}

/* ==========================================================
   The cart page
   ==========================================================
   A single column of lines, deliberately narrower than the inventory grid —
   this is a list to check, not a gallery to browse, and a 1200px row puts the
   item name and its price at opposite ends of a wide screen where they cannot
   be read as one thing.
   ========================================================== */
.container-narrow { max-width: 820px; }

.cart-count-line { color: var(--steel); }

/* Why a line disappeared. Amber rather than red: nothing has gone wrong, an
   item simply is not for sale any more. */
.cart-notice {
  margin-bottom: 20px;
  padding: 12px 16px;
  background: var(--bg-alt);
  border-left: 3px solid var(--rust);
  color: var(--bone);
  font-size: 0.92rem;
}

.cart-lines { border-top: 1px solid var(--line); }

.cart-line {
  display: grid;
  grid-template-columns: 86px 1fr auto auto;
  gap: 18px;
  align-items: center;
  padding: 18px 0;
  border-bottom: 1px solid var(--line);
}

.cart-line-img {
  width: 86px;
  height: 86px;
  border: 1px solid var(--line);
  background: var(--bg-alt);
}
/* An item with no photo still needs to hold its column, or the row's four
   tracks collapse and every line below it sits at a different indent. */
.cart-line-noimg { background: var(--bg-alt); }

.cart-line-main h3 { font-size: 1.05rem; margin: 0 0 4px; }
.cart-line-variant {
  display: flex;
  align-items: center;
  gap: 8px;
  margin: 0 0 4px;
  color: var(--bone);
  font-size: 0.92rem;
}
.cart-swatch {
  width: 14px;
  height: 14px;
  flex: 0 0 auto;
  border: 1px solid var(--line);
  border-radius: 2px;
}
.cart-line-each { margin: 0; color: var(--steel); font-size: 0.85rem; }

.cart-line-qty { display: flex; flex-direction: column; align-items: center; gap: 6px; }

.qty-stepper { display: flex; align-items: center; border: 1px solid var(--line); }
.qty-step {
  width: 34px;
  height: 34px;
  background: transparent;
  border: none;
  color: var(--bone);
  font-size: 1.1rem;
  line-height: 1;
  cursor: pointer;
}
.qty-step:hover:not(:disabled) { color: var(--rust-bright); }
/* Dimmed rather than hidden at the floor: a control that vanishes at one moves
   the two buttons either side of it and makes the next click land on Remove. */
.qty-step:disabled { opacity: 0.3; cursor: not-allowed; }
.qty-count { min-width: 34px; text-align: center; font-weight: 700; }

.cart-line-del {
  background: none;
  border: none;
  padding: 0;
  color: var(--steel);
  font-size: 0.72rem;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  cursor: pointer;
}
.cart-line-del:hover { color: var(--rust-bright); }

.cart-line-total { font-weight: 700; font-size: 1.05rem; white-space: nowrap; }

.cart-foot { margin-top: 28px; text-align: right; }
.cart-total {
  display: flex;
  justify-content: flex-end;
  align-items: baseline;
  gap: 16px;
  font-family: var(--font-display);
  font-size: 1.6rem;
  letter-spacing: 0.06em;
}
.cart-total strong { color: var(--rust-bright); }
.cart-foot-note { margin: 4px 0 20px; color: var(--steel); font-size: 0.85rem; }
/* align-items: flex-start, not the default stretch. The Checkout control is a
   column (button plus caption), so stretching would pull "Keep shopping" to the
   full height of both and leave the two buttons visibly mismatched. */
.cart-actions {
  display: flex;
  gap: 12px;
  justify-content: flex-end;
  align-items: flex-start;
  flex-wrap: wrap;
}

.cart-empty { text-align: center; padding: 40px 0; }
.cart-empty p { color: var(--steel); margin-bottom: 20px; }

/* On a phone the four-column row becomes a photo beside the details, with the
   quantity and the line total on a row of their own — the price must not end up
   under the thumbnail where it reads as a caption. */
@media (max-width: 620px) {
  /* The quantity row gets the photo column AND the middle one, with the total
     in its own auto column at the end. It used to be 'qty total' over
     64px | 1fr, so the stepper and Remove overflowed the 64px photo column and
     the total's cell, drawn after it, covered + and Remove: on every phone the
     quantity could go down but not up, and lines could not be removed
     (found 2026-10-10, WebKit and Chromium, 360-620px). */
  .cart-line {
    grid-template-columns: 64px minmax(0, 1fr) auto;
    grid-template-areas: 'img main main' 'qty qty total';
    gap: 12px 14px;
  }
  .cart-line-img { grid-area: img; width: 64px; height: 64px; }
  .cart-line-main { grid-area: main; }
  .cart-line-qty { grid-area: qty; flex-direction: row; justify-content: flex-start; gap: 14px; }
  .cart-line-total { grid-area: total; text-align: right; align-self: center; }
  .cart-actions { justify-content: stretch; }
  .cart-actions .btn { flex: 1 1 auto; text-align: center; }
}

/* At phone width the wordmark and the cart chip compete for the same row, and
   the chip wins — it overlaps the last letters of "ORCHARD". This only happens
   when the chip is actually showing, since it is hidden at zero, so the
   wordmark steps down only then and a cart-less page is untouched.

   :has() rather than a class toggled from JS: the indicator's visibility is
   already driven by its `hidden` attribute, and a second source of truth for
   the same state is how the two drift apart. A browser without :has() gets
   today's behaviour, which is what it already had. */
@media (max-width: 720px) {
  .nav-inner:has(.cart-indicator:not([hidden])) .nav-logo { font-size: 1.25rem; gap: 8px; }
  .nav-inner:has(.cart-indicator:not([hidden])) .nav-logo img { height: 40px; }
}

/* ==========================================================
   Checkout
   ========================================================== */
.co-summary {
  background: var(--bg-alt);
  border: 1px solid var(--line);
  padding: 18px 20px;
  margin-bottom: 24px;
}
.co-summary-head { display: flex; justify-content: space-between; align-items: baseline; margin-bottom: 12px; }
.co-summary-head h3 { margin: 0; font-size: 1.1rem; }
.co-count { color: var(--steel); font-size: 0.85rem; }

.co-line { display: grid; grid-template-columns: auto 1fr auto; gap: 10px; padding: 6px 0; font-size: 0.95rem; }
.co-line-qty { color: var(--steel); }
.co-line-variant { color: var(--steel); }
.co-line-total { white-space: nowrap; }

.co-summary-total {
  display: flex;
  justify-content: space-between;
  margin-top: 12px;
  padding-top: 12px;
  border-top: 1px solid var(--line);
  font-family: var(--font-display);
  font-size: 1.3rem;
  letter-spacing: 0.06em;
}
.co-summary-total strong { color: var(--rust-bright); }
.co-summary-note { margin: 10px 0 0; color: var(--steel); font-size: 0.82rem; }

/* A quote opened from its email link: whose it is, until when, and Ken's
   note. Above the summary, because it explains why nothing below can be
   changed. */
.co-quote { margin-bottom: 18px; padding: 14px 16px; border: 1px solid var(--rust); background: var(--bg); }
.co-quote p { margin: 0; }
.co-quote p + p { margin-top: 8px; }
.co-quote .co-quote-note { color: var(--bone); font-style: italic; }
.co-quote .co-quote-test { color: var(--rust-bright); font-weight: 600; }

.co-fields { border: none; padding: 0; margin: 0 0 26px; }
.co-fields legend {
  padding: 0;
  margin-bottom: 12px;
  font-family: var(--font-display);
  font-size: 1.2rem;
  letter-spacing: 0.06em;
  color: var(--bone);
}
.co-fields label {
  display: block;
  margin-bottom: 5px;
  font-size: 0.72rem;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--steel);
  font-weight: 600;
}
.co-fields input,
.co-fields select {
  width: 100%;
  margin-bottom: 14px;
  padding: 11px 13px;
  background: var(--bg);
  border: 1px solid var(--line);
  color: var(--bone);
  font-family: var(--font-body);
  font-size: 0.95rem;
}
.co-fields input:focus, .co-fields select:focus { outline: none; border-color: var(--rust); }
/* The State list, drawn by us: WebKit (every iPhone browser) ignores padding
   on a native select, which would leave it shorter than the boxes beside it.
   The chevron is --steel, #8a8f80. */
.co-fields select {
  -webkit-appearance: none;
  appearance: none;
  border-radius: 0;
  padding-right: 34px;
  text-overflow: ellipsis;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 12 8'%3E%3Cpath d='M1 1.5l5 5 5-5' fill='none' stroke='%238a8f80' stroke-width='1.6'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 12px center;
  background-size: 12px 8px;
}
.co-hint { margin: -10px 0 14px; color: var(--steel); font-size: 0.78rem; }

/* City / state / ZIP read as one line, because that is how an address is
   written and how it is checked. */
.co-row { display: grid; grid-template-columns: 2fr 1fr 1fr; gap: 12px; }
@media (max-width: 560px) { .co-row { grid-template-columns: 1fr; } }

/* The address check's question (js/checkout.js): what was found, and the
   customer's two ways forward. Never a dead end. */
.co-addr-check { margin: 0 0 18px; padding: 16px 18px; border: 1px solid var(--rust); background: var(--bg); }
.co-addr-check[hidden] { display: none; }
.co-addr-msg { margin: 0 0 12px; color: var(--bone); }
.co-addr-found { margin: 0 0 14px; }
.co-addr-label { display: block; margin-bottom: 4px; font-size: 0.72rem; text-transform: uppercase; letter-spacing: 0.1em; color: var(--steel); font-weight: 600; }
.co-addr-found address { font-style: normal; color: var(--bone); line-height: 1.5; }
.co-addr-found address span { display: block; }
.co-addr-actions { display: flex; flex-wrap: wrap; gap: 10px; }
.co-addr-actions .btn { padding: 12px 20px; cursor: pointer; font-family: inherit; }
/* .btn-ghost was written for links; a <button> brings the browser's own grey. */
.co-addr-actions .btn-ghost { background: transparent; }
@media (max-width: 560px) {
  .co-addr-actions .btn { flex: 1 1 100%; min-height: 44px; }
}

/* The cart's most-per-order note (js/cart-page.js). */
.cart-limit { margin: 6px 0 0; font-size: 0.82rem; color: var(--steel); }
.cart-limit.is-over { color: var(--rust-bright); }
.cart-limit a { color: var(--rust-bright); text-decoration: underline; }

.co-submit { width: 100%; margin-top: 4px; }
.co-pay-note { text-align: center; margin-top: 10px; }

/* ==========================================================
   The simulated payment page
   ==========================================================
   Loud on purpose. A fake payment page that nobody can tell is fake is the one
   outcome worth designing against — someone would eventually type a real card
   number into it.
   ========================================================== */
.sim-banner {
  display: block;
  margin-bottom: 28px;
  padding: 14px 18px;
  background: repeating-linear-gradient(45deg, #3a2a08, #3a2a08 12px, #2e2206 12px, #2e2206 24px);
  border: 2px dashed #d9a441;
  color: #f3e3c3;
}
.sim-banner strong {
  display: block;
  font-family: var(--font-display);
  font-size: 1.25rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: #ffd479;
}
.sim-banner span { font-size: 0.88rem; }

.sim-order { border: 1px solid var(--line); background: var(--bg-alt); padding: 16px 20px; margin-bottom: 22px; }
.sim-row { display: flex; justify-content: space-between; padding: 6px 0; }
.sim-row span:first-child { color: var(--steel); font-size: 0.82rem; text-transform: uppercase; letter-spacing: 0.1em; }
.sim-mode { font-family: var(--font-display); letter-spacing: 0.1em; color: #ffd479; }

.sim-ask { margin-bottom: 14px; }
.sim-actions { display: flex; flex-direction: column; gap: 12px; align-items: stretch; }
.sim-actions .linkish { align-self: center; margin-top: 4px; }
.sim-status { margin-top: 16px; color: var(--rust-bright); min-height: 1.2em; }

/* The order number, given the weight of the thing the customer will quote back. */
.op-number {
  text-align: center;
  padding: 24px;
  margin-bottom: 24px;
  background: var(--bg-alt);
  border: 1px solid var(--line);
}
.op-number span { display: block; color: var(--steel); font-size: 0.78rem; text-transform: uppercase; letter-spacing: 0.12em; }
.op-number strong {
  display: block;
  margin: 8px 0;
  font-family: var(--font-display);
  font-size: 2rem;
  letter-spacing: 0.1em;
  color: var(--rust-bright);
}
.op-test { color: #ffd479 !important; text-transform: none !important; letter-spacing: normal !important; }
.op-test[hidden] { display: none; }

/* ==========================================================
   Garment tiles — Option C, chosen by Ken
   ==========================================================
   Every garment and its price, up front, before a single tap. Size and color
   appear only once the customer has picked what they are buying. Shown only
   when an item offers more than one garment; a plain tee goes straight to
   size and color.
   ========================================================== */
.garment-tiles { display: grid; gap: 8px; margin: 0; }
.garment-tile {
  width: 100%;
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: 10px;
  padding: 12px 14px;
  text-align: left;
  background: var(--bg);
  color: var(--bone);
  border: 1px solid var(--line);
  font-family: var(--font-body);
  font-size: 0.95rem;
  text-transform: none;
  letter-spacing: normal;
  cursor: pointer;
}
.garment-tile:hover { border-color: var(--rust); background: var(--bg-alt); }
.garment-tile.is-chosen { border-color: var(--rust-bright); box-shadow: inset 3px 0 0 var(--rust-bright); }
.garment-tile:focus-visible { outline: 2px solid var(--rust-bright); outline-offset: 2px; }
.garment-tile-name { font-weight: 600; }
.garment-tile-price { text-align: right; white-space: nowrap; }
.garment-tile-price b {
  font-family: var(--font-display);
  font-size: 1.25rem;
  font-weight: 400;
  letter-spacing: 0.04em;
  color: var(--rust-bright);
}
.garment-tile-price small { display: block; color: var(--steel); font-size: 0.72rem; }

/* The same column and the same gap as .buy-controls around it. The pickers
   were wrapped in this container in #140 without either, which left the
   swatches touching the size box — 0px apart. Every block inside the controls
   now sits one gap from the next, whatever mix of them a card has. */
.buy-pickers { display: flex; flex-direction: column; gap: .55rem; }
.buy-pickers[hidden] { display: none; }
/* Room between the color circles and the size box, for thumbs. At the
   column's .55rem (9px) a tap aimed at the size box on a phone landed on a
   color often enough to change the shopper's pick without them noticing.
   1.5rem (24px) in all. Every width, not just phones: a taller card costs
   nothing on a desktop, and a phone that reports a desktop width still gets
   it. Only between these two — a hat (sizes, no colors) and a decal (colors,
   no sizes) are unchanged. */
.buy-swatches + .buy-row { margin-top: calc(1.5rem - .55rem); }
/* The same thumb room under the style tiles: at 9px, reaching for a color
   could land on a tile and switch the style instead. Only once the pickers
   show (a style is chosen); hidden, they take no space and the callout keeps
   its usual gap. Tiles and chips alike. */
.garment-tiles + .buy-pickers { margin-top: calc(1.5rem - .55rem); }
/* A Custom Order card's Request a quote: full width under its dropdowns, in
   the spot Add to cart takes on every other card. */
.buy-quote { display: block; text-align: center; }
/* "2XL–3XL: $29.99" — which sizes cost more, said once, under the picker.
   No margin of its own: the column's gap spaces it like everything else. */
.buy-note { margin: 0; color: var(--steel); font-size: 0.78rem; }
.buy-note[hidden] { display: none; }
/* "Pink? Good call. Pick a style and we'll show it off." (Chad, 2026-11-15):
   a small bubble under the style box, pointing up at it, only when a colour
   was picked before any style and the photo can't show it yet (buy.js
   needsStyleHint). Quiet by design: no icon, no close button, gone the moment
   a style is chosen. */
.buy-hint {
  position: relative;
  margin: .35rem 0 0;
  padding: .6rem .8rem;
  max-width: 22rem;
  background: var(--rust-bright);
  border-radius: 8px;
  color: #0a0c09;
  font-size: 0.9rem;
  font-weight: 700;
  line-height: 1.3;
  box-shadow: 0 4px 14px rgba(0, 0, 0, 0.45), 0 0 0 2px rgba(140, 198, 62, 0.25);
  animation: buy-hint-in .45s cubic-bezier(.2, 1.4, .4, 1);
}
/* the pointer, up at the style box */
.buy-hint::before {
  content: "";
  position: absolute;
  top: -7px;
  left: 1.1rem;
  width: 14px;
  height: 14px;
  background: var(--rust-bright);
  border-radius: 2px;
  transform: rotate(45deg);
}
.buy-hint[hidden] { display: none; }
/* One bounce when it appears, then still: obvious, not nagging. */
@keyframes buy-hint-in {
  0% { opacity: 0; transform: translateY(-8px) scale(.96); }
  60% { opacity: 1; transform: translateY(3px) scale(1.02); }
  100% { opacity: 1; transform: none; }
}
@media (prefers-reduced-motion: reduce) { .buy-hint { animation: none; } }
/* The bigger sizes' price ("2XL–3XL: $29.99") in bold, so the extra charge
   is seen before Add to cart (Chad, 2026-10-10). */
.buy-upcharge { font-weight: 700; }

/* Once the shop is open, cards in a row no longer match: one offering a tee and
   a hoodie grows tiles, the next may have none. The closed-shop layout lets the
   description absorb that height, which floated a neighbour's price 300px
   below its name. Open, the price stays under the description and the buy
   controls take the slack instead, so they line up along the bottom of the row.
   Scoped to when cards carry options — the open shop, or the options
   preview — so a site showing neither looks exactly as it did. */
.has-buy-controls .inv-card .desc { flex: 0 1 auto; }
/* Options sit one fixed gap under the price. They used to be pinned to the
   bottom of the card so buttons lined up across a row — which left an 84px hole
   under the price on a short card like the hats. Any spare height now collects
   at the bottom of the card, where it reads as space rather than as a gap. */
.has-buy-controls .inv-card .buy-controls { margin-top: .75rem; }

/* Line the cards up ACROSS a row, whatever the text. Each card was its own
   flex column, so a name that wrapped to two lines ("The Original Bad Apple
   Hoodies") pushed that card's price 35px below its neighbours'. One-line
   descriptions fixed half of it, but Ken can type any name or description in
   the console, so the layout has to absorb it rather than the copy.

   Subgrid: each card spans five of the grid's row tracks and shares them with
   every card beside it, so the tallest name in a row sets the name row for all
   of them, and the same for description, price and options. Each part is
   pinned to its row by class, because a card with no photo has no image block
   and would otherwise slide its name up into the photo row.

   Behind @supports so a browser without subgrid keeps the flex column above. */
@supports (grid-template-rows: subgrid) {
  .inv-card {
    display: grid;
    grid-row: span 5;
    grid-template-rows: subgrid;
    /* Overrides the 20px the grid puts between cards, inside the card only. */
    row-gap: 8px;
    align-content: start;
    /* WebKit (Safari, and every browser on iPhone) mis-sizes a subgrid whose
       container has side padding: it made the card's one column the full
       border-box width, so every card's contents ran ~49px past its right
       edge — on phones and desktop Safari alike, while Chromium was fine.
       An explicit minmax(0, 1fr) column plus side padding moved onto the
       children as margin fixes both engines; keeping the padding and only
       fixing the column left WebKit sizing the photo row for the wider box,
       a 63px hole under every photo. Verified in Playwright WebKit. */
    grid-template-columns: minmax(0, 1fr);
    padding-left: 0;
    padding-right: 0;
  }
  .inv-card > * { margin-left: 24px; margin-right: 24px; }
  .inv-card > .art-img      { grid-row: 1; }
  .inv-card > h3            { grid-row: 2; }
  .inv-card > .desc         { grid-row: 3; }
  .inv-card > .inv-meta     { grid-row: 4; align-self: start; }
  .inv-card > .buy-controls { grid-row: 5; align-self: start; }
}

/* Styles that all cost the same are compact chips — names only, wrapping —
   rather than full-width price tiles. Nine designs at one price would
   otherwise be nine tall boxes each saying "$4.99". */
.garment-tiles.is-chips { display: flex; flex-wrap: wrap; gap: 6px; }
.garment-tiles.is-chips .garment-tile { width: auto; padding: 7px 12px; font-size: 0.85rem; }
.garment-tiles.is-chips .garment-tile.is-chosen { box-shadow: none; background: var(--rust-dark); border-color: var(--rust-bright); }

/* The options preview's stand-in for Add to cart: says when, and where to go
   now. Quiet, like the size note — it is information, not a call to action
   competing with the choices above it. */
.buy-soon { margin: 0; font-size: 0.85rem; color: var(--bone); }
.buy-soon a { color: var(--rust-bright); text-decoration: underline; }

/* Editor test shopping (buy.js): says plainly that this tab is shopping in
   test mode, with the way out beside it. Only ever drawn for a signed-in
   editor who chose it in the Site Manager. */
.test-shopping-banner {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  gap: 6px 12px;
  padding: 8px 16px;
  background: var(--rust-dark);
  color: var(--bone);
  font-size: 0.9rem;
  text-align: center;
}
.test-shopping-banner strong { text-transform: uppercase; letter-spacing: 0.08em; }
.test-shopping-stop {
  min-height: 44px;
  padding: 8px 14px;
  border: 1px solid var(--bone);
  border-radius: 4px;
  background: transparent;
  color: var(--bone);
  font: inherit;
  cursor: pointer;
}
.test-shopping-stop:hover { background: rgba(232, 230, 220, 0.12); }
