/* ==========================================================================
   BoxBeauty v3 — Editorial modern system
   Paper / ink / vermilion. Display: Bricolage Grotesque. Serif accent: Instrument Serif.
   ========================================================================== */

:root {
  --paper: #f4f1ea;
  --paper-2: #ece7dc;
  --card: #fbf9f4;
  --ink: #14120f;
  --ink-2: #100e0c;
  --muted: #6f685c;
  --line: #d9d2c3;
  --accent: #e4522b;
  --accent-deep: #c23f1d;
  --on-ink: #f2ede3;
  --on-ink-muted: #a49b8b;
  --line-ink: #322d26;

  --font-display: "Bricolage Grotesque", "Inter Tight", system-ui, sans-serif;
  --font-serif: "Instrument Serif", Georgia, serif;
  --font-body: "Inter Tight", system-ui, -apple-system, sans-serif;

  --wrap: 1240px;
  --gutter: clamp(20px, 4vw, 56px);
  --radius: 18px;
  --header-h: 76px;

  --ease: cubic-bezier(.22,.75,.28,1);
}

/* ---------- reset ---------- */
*, *::before, *::after { box-sizing: border-box; }
* { margin: 0; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
body {
  font-family: var(--font-body);
  font-size: 17px;
  line-height: 1.6;
  color: var(--ink);
  background: var(--paper);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  overflow-x: clip;
}
img, svg, video { display: block; max-width: 100%; }
a { color: inherit; text-decoration: none; }
ul, ol { list-style: none; padding: 0; }
button { font: inherit; color: inherit; background: none; border: 0; cursor: pointer; }
::selection { background: var(--accent); color: #fff; }

:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 3px;
  border-radius: 4px;
}

.sr-only {
  position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px;
  overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0;
}
.skip-link {
  position: absolute; left: 12px; top: -60px; z-index: 200;
  background: var(--ink); color: #fff; padding: 10px 18px; border-radius: 99px;
  font-size: 14px; transition: top .2s var(--ease);
}
.skip-link:focus { top: 12px; }

/* ---------- layout ---------- */
.wrap {
  width: 100%;
  max-width: var(--wrap);
  margin-inline: auto;
  padding-inline: var(--gutter);
}
section { scroll-margin-top: calc(var(--header-h) + 12px); }

/* ---------- typography ---------- */
h1, h2, h3 {
  font-family: var(--font-display);
  font-weight: 600;
  letter-spacing: -0.03em;
  line-height: 0.98;
  text-wrap: balance;
}
h1 { font-size: clamp(46px, 7.6vw, 104px); font-weight: 700; }
h2 { font-size: clamp(34px, 5vw, 68px); max-width: 20ch; }
h3 { font-size: clamp(22px, 2.4vw, 30px); line-height: 1.08; letter-spacing: -0.02em; }
h1 em, h2 em, h3 em, .big-claim em {
  font-family: var(--font-serif);
  font-style: italic;
  font-weight: 400;
  letter-spacing: -0.01em;
}
h1 em, h2 em { color: var(--accent); }

.kicker, .eyebrow {
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--muted);
  display: flex;
  align-items: center;
  gap: 10px;
}
.kicker { margin-bottom: 22px; }
.section-ink .kicker, .careers .kicker { color: var(--on-ink-muted); }

.sec-head { margin-bottom: clamp(40px, 6vw, 88px); }

/* ---------- header ---------- */
.site-header {
  position: fixed; inset: 0 0 auto 0; z-index: 100;
  height: var(--header-h);
  display: flex; align-items: center;
  transition: background .35s var(--ease), box-shadow .35s var(--ease), border-color .35s var(--ease);
  border-bottom: 1px solid transparent;
}
.site-header.is-scrolled, .site-header[class*="is-"] {
  background: color-mix(in srgb, var(--paper) 82%, transparent);
  backdrop-filter: blur(14px) saturate(1.4);
  -webkit-backdrop-filter: blur(14px) saturate(1.4);
  border-bottom-color: var(--line);
}
.header-inner {
  width: 100%; max-width: var(--wrap); margin-inline: auto;
  padding-inline: var(--gutter);
  display: flex; align-items: center; gap: clamp(16px, 3vw, 44px);
}
.brand { display: flex; align-items: center; gap: 11px; flex: none; }
.brand-mark {
  width: 26px; height: 26px; border-radius: 8px;
  background: var(--ink);
  position: relative; flex: none;
  transition: transform .4s var(--ease), background .3s;
}
.brand-mark::after {
  content: ""; position: absolute; inset: 7px 7px auto auto;
  width: 9px; height: 9px; border-radius: 50%; background: var(--accent);
}
.brand:hover .brand-mark { transform: rotate(-8deg) scale(1.06); }
.brand-name {
  font-family: var(--font-display); font-weight: 700; font-size: 19px; letter-spacing: -0.02em;
}
.site-nav { display: flex; gap: clamp(14px, 2vw, 30px); margin-left: auto; }
.site-nav a {
  font-size: 14.5px; font-weight: 500; color: var(--muted);
  position: relative; padding: 6px 2px; transition: color .25s;
}
.site-nav a::after {
  content: ""; position: absolute; left: 0; bottom: 2px; height: 1.5px; width: 0;
  background: var(--accent); transition: width .3s var(--ease);
}
.site-nav a:hover { color: var(--ink); }
.site-nav a:hover::after { width: 100%; }

.header-side { display: flex; align-items: center; gap: 16px; margin-left: auto; flex: none; }
.site-nav + .header-side { margin-left: clamp(16px, 3vw, 40px); }
.header-meta {
  font-size: 11px; letter-spacing: 0.18em; color: var(--muted); font-weight: 500;
  white-space: nowrap;
}
.pill-cta {
  display: inline-flex; align-items: center; gap: 8px;
  padding: 10px 20px; border-radius: 99px;
  background: var(--ink); color: var(--paper);
  font-size: 14px; font-weight: 600; white-space: nowrap;
  transition: transform .3s var(--ease), background .3s;
}
.pill-cta:hover { background: var(--accent); transform: translateY(-1px); }

.menu-button {
  display: none; width: 42px; height: 42px; border-radius: 12px;
  border: 1px solid var(--line); flex-direction: column;
  align-items: center; justify-content: center; gap: 6px;
}
.menu-button span { width: 18px; height: 1.8px; background: var(--ink); transition: transform .3s var(--ease), opacity .3s; }
.menu-button[aria-expanded="true"] span:first-child { transform: translateY(3.9px) rotate(45deg); }
.menu-button[aria-expanded="true"] span:last-child { transform: translateY(-3.9px) rotate(-45deg); }

/* ---------- buttons ---------- */
.btn-solid, .btn-line {
  display: inline-flex; align-items: center; gap: 10px;
  padding: 15px 28px; border-radius: 99px;
  font-size: 15.5px; font-weight: 600; letter-spacing: -0.01em;
  transition: transform .3s var(--ease), background .3s, color .3s, border-color .3s;
}
.btn-solid { background: var(--ink); color: var(--paper); }
.btn-solid:hover { background: var(--accent); transform: translateY(-2px); }
.btn-solid span { transition: transform .3s var(--ease); }
.btn-solid:hover span { transform: translateY(3px); }
.btn-line { border: 1.5px solid var(--ink); color: var(--ink); }
.btn-line i, .btn-line span { transition: transform .3s var(--ease); font-style: normal; }
.btn-line:hover { border-color: var(--accent); color: var(--accent); transform: translateY(-2px); }
.btn-line:hover i, .btn-line:hover span { transform: translateX(4px); }

/* ---------- media slots ---------- */
.media-slot {
  aspect-ratio: var(--ar, 16/9);
  border-radius: var(--radius);
  overflow: hidden;
  position: relative;
  background:
    repeating-linear-gradient(-45deg, rgba(20,18,15,.045) 0 10px, transparent 10px 20px),
    linear-gradient(160deg, var(--card), var(--paper-2));
  border: 1.5px dashed color-mix(in srgb, var(--ink) 26%, transparent);
  display: flex;
  transition: border-color .35s, transform .5s var(--ease);
}
.media-slot:hover { border-color: var(--accent); }
.section-ink .media-slot {
  background:
    repeating-linear-gradient(-45deg, rgba(244,241,234,.05) 0 10px, transparent 10px 20px),
    linear-gradient(160deg, #1c1915, #141210);
  border-color: rgba(244,241,234,.22);
}
.slot-inner {
  position: absolute; inset: 0;
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  gap: 12px; padding: clamp(16px, 3vw, 30px); text-align: center;
}
.slot-badge {
  font-size: 10.5px; font-weight: 700; letter-spacing: 0.16em;
  color: var(--accent);
  border: 1px solid color-mix(in srgb, var(--accent) 45%, transparent);
  background: color-mix(in srgb, var(--accent) 8%, transparent);
  padding: 5px 12px; border-radius: 99px; white-space: nowrap;
}
.slot-play {
  width: 58px; height: 58px; border-radius: 50%;
  border: 1.5px solid color-mix(in srgb, var(--ink) 35%, transparent);
  display: grid; place-items: center;
  font-size: 15px; color: var(--ink); padding-left: 3px;
  transition: transform .4s var(--ease), border-color .3s, background .3s, color .3s;
}
.slot-play:hover { transform: scale(1.1); background: var(--accent); border-color: var(--accent); color: #fff; }
.section-ink .slot-play { border-color: rgba(244,241,234,.4); color: var(--on-ink); }
.slot-desc {
  font-size: 12.5px; line-height: 1.5; color: var(--muted); max-width: 34ch;
}
.slot-desc strong { display: block; color: var(--ink); font-size: 13.5px; margin-bottom: 3px; }
.section-ink .slot-desc { color: var(--on-ink-muted); }
.section-ink .slot-desc strong { color: var(--on-ink); }

/* when a real image/video is dropped in, it simply covers the slot */
.media-slot img, .media-slot video {
  position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; z-index: 2;
}
.media-slot:has(img), .media-slot:has(video) { border-style: solid; border-color: transparent; }
.media-slot:has(img) .slot-inner, .media-slot:has(video) .slot-inner { display: none; }

/* ---------- hero ---------- */
.hero {
  padding-top: calc(var(--header-h) + clamp(28px, 6vw, 72px));
  padding-bottom: clamp(48px, 8vw, 110px);
  position: relative;
  overflow: clip;
}
.hero::before {
  content: ""; position: absolute; z-index: -1;
  top: -10%; right: -18%; width: 60vw; height: 60vw; max-width: 860px; max-height: 860px;
  background: radial-gradient(closest-side, color-mix(in srgb, var(--accent) 12%, transparent), transparent 72%);
  border-radius: 50%; pointer-events: none;
}
.hero-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.35fr) minmax(0, 0.85fr);
  gap: clamp(28px, 5vw, 72px);
  align-items: end;
}
.hero-copy { display: flex; flex-direction: column; gap: clamp(20px, 2.6vw, 30px); }
.pulse-dot {
  width: 8px; height: 8px; border-radius: 50%; background: var(--accent); flex: none;
  box-shadow: 0 0 0 0 color-mix(in srgb, var(--accent) 60%, transparent);
  animation: pulse 2.4s infinite;
}
@keyframes pulse {
  0% { box-shadow: 0 0 0 0 color-mix(in srgb, var(--accent) 55%, transparent); }
  70% { box-shadow: 0 0 0 11px transparent; }
  100% { box-shadow: 0 0 0 0 transparent; }
}
.hero h1 { max-width: 14ch; }
.hero h1 .h1-top,
.hero h1 .h1-mid,
.hero h1 em { display: block; }
.hero h1 .h1-top { color: var(--accent); }
.hero h1 .h1-mid {
  font-size: 0.55em; font-weight: 600; color: var(--ink);
  letter-spacing: -0.02em; line-height: 1.1;
  margin: 0.16em 0 0.12em;
}
.hero-lead { font-size: clamp(17px, 1.7vw, 20px); color: var(--muted); max-width: 52ch; }
.hero-lead p + p { margin-top: 0.75em; }
.hero-actions { display: flex; flex-wrap: wrap; gap: 14px; }
.hero-index {
  margin-top: clamp(14px, 2vw, 26px);
  display: flex; flex-wrap: wrap; gap: 8px 10px;
  border-top: 1px solid var(--line); padding-top: 22px;
}
.hero-index li {
  font-size: 12px; font-weight: 600; letter-spacing: 0.08em; text-transform: uppercase;
  color: var(--muted);
  border: 1px solid var(--line); border-radius: 99px; padding: 7px 14px;
  background: color-mix(in srgb, var(--card) 60%, transparent);
  transition: color .25s, border-color .25s, transform .3s var(--ease);
}
.hero-index li:hover { color: var(--accent); border-color: var(--accent); transform: translateY(-2px); }
.slot-tall { align-self: center; min-height: 420px; }

/* ---------- stats ---------- */
.stats { border-block: 1px solid var(--line); background: var(--card); }
.stats-grid {
  display: grid; grid-template-columns: repeat(4, 1fr);
}
.stat {
  padding: clamp(30px, 4vw, 52px) clamp(14px, 2vw, 28px);
  display: flex; flex-direction: column; gap: 8px;
  border-left: 1px solid var(--line);
}
.stat:first-child { border-left: 0; }
.stat strong {
  font-family: var(--font-display); font-weight: 700; letter-spacing: -0.03em;
  font-size: clamp(38px, 5vw, 66px); line-height: 1;
  font-variant-numeric: tabular-nums;
}
.stat strong::after { content: ""; display: block; width: 26px; height: 4px; background: var(--accent); border-radius: 2px; margin-top: 14px; }
.stat p { font-size: 14px; color: var(--muted); line-height: 1.45; max-width: 24ch; }

/* ---------- generic section ---------- */
.section { padding-block: clamp(72px, 10vw, 140px); }

/* ---------- studio craft rows ---------- */
.craft-row {
  display: grid;
  grid-template-columns: minmax(0, 0.9fr) minmax(0, 1.1fr);
  gap: clamp(24px, 4.5vw, 68px);
  align-items: center;
  padding-block: clamp(34px, 4.5vw, 58px);
  border-top: 1px solid var(--line);
}
.craft-row:last-child { border-bottom: 1px solid var(--line); }
.craft-row.flip .craft-text { order: 2; }
.craft-row.flip .media-slot { order: 1; }
.craft-text { display: flex; flex-direction: column; gap: 16px; max-width: 46ch; }
.craft-num {
  font-family: var(--font-serif); font-style: italic;
  font-size: 40px; color: var(--accent); line-height: 1;
}
.craft-text p { color: var(--muted); font-size: 16.5px; }
.craft-tag {
  font-size: 12.5px; font-weight: 600; letter-spacing: 0.04em;
  color: var(--ink); border-left: 3px solid var(--accent); padding-left: 12px;
}

/* ---------- slate (dark) ---------- */
.section-ink {
  background: var(--ink-2); color: var(--on-ink);
  padding-bottom: clamp(64px, 8vw, 110px);
}
.section-ink h2 { color: var(--on-ink); }
.section-ink h2 em { color: var(--accent); }
.slate-head-row {
  display: flex; flex-wrap: wrap; align-items: flex-end; justify-content: space-between;
  gap: 20px 40px;
}
.slate-head-row .sec-head { margin-bottom: clamp(36px, 5vw, 64px); }
.slate-note {
  max-width: 40ch; font-size: 14.5px; color: var(--on-ink-muted); line-height: 1.55;
  padding-bottom: 6px;
}
.slate-note strong { color: var(--accent); font-weight: 600; }

.rail-wrap { position: relative; }
.poster-rail {
  display: flex; gap: clamp(16px, 2.2vw, 28px);
  overflow-x: auto; scroll-snap-type: x mandatory;
  scroll-padding-inline: max(var(--gutter), calc((100vw - var(--wrap)) / 2 + var(--gutter)));
  padding-inline: max(var(--gutter), calc((100vw - var(--wrap)) / 2 + var(--gutter)));
  padding-bottom: 8px;
  scrollbar-width: none; cursor: grab;
  -webkit-overflow-scrolling: touch;
}
.poster-rail::-webkit-scrollbar { display: none; }
.poster-rail.is-dragging { cursor: grabbing; scroll-snap-type: none; scroll-behavior: auto; }
.poster-rail.is-dragging * { pointer-events: none; }
.poster { flex: 0 0 clamp(220px, 24vw, 290px); scroll-snap-align: start; }
.poster .media-slot { border-radius: 14px; }
.poster-meta { padding-top: 16px; display: flex; flex-direction: column; gap: 3px; }
.poster-meta h3 { font-size: 19px; color: var(--on-ink); }
.poster-meta p { font-size: 13px; color: var(--on-ink-muted); }

.rail-progress {
  margin-top: clamp(22px, 3vw, 34px);
  max-width: var(--wrap); margin-inline: auto; padding-inline: var(--gutter);
  height: 2px; background: var(--line-ink); border-radius: 2px;
}
.rail-progress span {
  display: block; height: 100%; width: 18%;
  background: var(--accent); border-radius: 2px;
  transition: transform .15s linear;
  transform-origin: left;
}
.rail-hint {
  margin-top: 18px; font-size: 12.5px; color: var(--on-ink-muted);
}

/* ---------- factory ---------- */
.factory-grid {
  display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.05fr);
  gap: clamp(28px, 5vw, 72px); align-items: center;
  margin-bottom: clamp(44px, 6vw, 76px);
}
.factory-copy { display: flex; flex-direction: column; gap: 22px; }
.big-claim {
  font-family: var(--font-display); font-weight: 500;
  font-size: clamp(22px, 2.6vw, 31px); line-height: 1.22; letter-spacing: -0.02em;
  text-wrap: balance;
}
.big-claim em { color: var(--accent); }
.factory-copy p:not(.big-claim) { color: var(--muted); max-width: 46ch; }

.pipeline {
  display: grid; grid-template-columns: repeat(7, 1fr);
  border-top: 1px solid var(--line); border-bottom: 1px solid var(--line);
  margin-bottom: clamp(44px, 6vw, 76px);
}
.pipeline li {
  padding: 22px clamp(10px, 1.4vw, 20px);
  font-size: 13.5px; font-weight: 600; line-height: 1.35;
  border-left: 1px solid var(--line);
  display: flex; flex-direction: column; gap: 10px;
  transition: background .3s;
}
.pipeline li:first-child { border-left: 0; }
.pipeline li:hover { background: var(--card); }
.pipeline li span {
  font-family: var(--font-serif); font-style: italic; font-weight: 400;
  font-size: 17px; color: var(--accent);
}
.slot-wide { min-height: clamp(0px, 18vw, 240px); }

/* ---------- story ---------- */
.story-grid {
  display: grid; grid-template-columns: minmax(0, 1.15fr) minmax(0, 0.85fr);
  gap: clamp(28px, 5vw, 72px); align-items: start;
}
.story-copy { display: flex; flex-direction: column; gap: 18px; }
.story-copy p { color: var(--muted); font-size: 16.5px; max-width: 58ch; }
.story-copy h2 { margin-bottom: clamp(6px, 1vw, 12px); }
#story .sec-head { margin-bottom: 0; }
.story-creed {
  font-family: var(--font-display);
  font-style: normal;
  font-weight: 700;
  font-size: clamp(26px, 3.9vw, 46px);
  line-height: 0.98;
  letter-spacing: -0.032em;
  color: var(--ink);
  /* same grid row as the timeline (align-items:start): pull the cap top
     up to the row top so it lines up with the timeline's top rule
     (cap sits .16*fontSize below the line-box top at line-height .98) */
  margin-top: calc(-0.16 * clamp(26px, 3.9vw, 46px));
}
.story-creed em { font-style: normal; color: var(--accent); }
.story-side { display: flex; flex-direction: column; }
.story-timeline { display: flex; flex-direction: column; border-top: 1px solid var(--line); }
.story-timeline li {
  display: grid; grid-template-columns: 78px minmax(0, 1fr); gap: 14px; align-items: baseline;
  padding: 13px 2px; border-bottom: 1px solid var(--line);
  font-size: 14px; font-weight: 500; line-height: 1.4; color: var(--ink);
  transition: background .3s;
}
.story-timeline li:hover { background: var(--card); }
.story-timeline li span {
  font-family: var(--font-serif); font-style: italic; font-weight: 400;
  font-size: 15.5px; color: var(--accent);
}

/* ---------- partners ---------- */
.section-band { background: var(--paper-2); border-block: 1px solid var(--line); }
.partner-list { border-top: 1px solid var(--line); }
.partner-row {
  display: grid;
  grid-template-columns: 64px minmax(0, 0.9fr) minmax(0, 1.2fr) auto;
  gap: clamp(14px, 2.5vw, 36px);
  align-items: center;
  padding-block: clamp(26px, 3.4vw, 40px);
  border-bottom: 1px solid var(--line);
  position: relative;
  transition: padding-left .4s var(--ease);
}
.partner-row:hover { padding-left: 14px; }
.pr-num {
  font-family: var(--font-serif); font-style: italic; font-size: 26px; color: var(--muted);
  transition: color .3s;
}
.pr-title {
  font-family: var(--font-display); font-weight: 600; letter-spacing: -0.02em;
  font-size: clamp(24px, 3vw, 38px); line-height: 1.02;
  transition: color .3s;
}
.pr-desc { font-size: 15px; color: var(--muted); max-width: 44ch; }
.pr-go {
  display: inline-flex; align-items: center; gap: 8px; white-space: nowrap;
  font-size: 14px; font-weight: 600; color: var(--ink);
  border: 1.5px solid var(--line); border-radius: 99px; padding: 10px 18px;
  transition: all .35s var(--ease);
}
.pr-go i { font-style: normal; transition: transform .3s var(--ease); }
.partner-row:hover .pr-num { color: var(--accent); }
.partner-row:hover .pr-title { color: var(--accent); }
.partner-row:hover .pr-go { background: var(--accent); border-color: var(--accent); color: #fff; }
.partner-row:hover .pr-go i { transform: translateX(4px); }

/* ---------- careers ---------- */
.careers {
  background: var(--ink-2); color: var(--on-ink);
  padding-block: clamp(80px, 11vw, 150px);
  position: relative; overflow: hidden;
}
.careers::after {
  content: ""; position: absolute; bottom: -30%; left: -10%; width: 55vw; height: 55vw;
  max-width: 760px; max-height: 760px; border-radius: 50%;
  background: radial-gradient(closest-side, color-mix(in srgb, var(--accent) 16%, transparent), transparent 70%);
  pointer-events: none;
}
.careers-inner {
  display: grid; grid-template-columns: minmax(0, 1.15fr) minmax(0, 0.85fr);
  gap: clamp(28px, 5vw, 72px); align-items: end; position: relative; z-index: 1;
}
.careers h2 { color: var(--on-ink); }
.careers h2 em { color: var(--accent); }
.careers-side { display: flex; flex-direction: column; gap: 24px; }
.careers-side p { color: var(--on-ink-muted); font-size: 16px; max-width: 40ch; }
.careers .btn-solid { background: var(--paper); color: var(--ink); align-self: flex-start; }
.careers .btn-solid:hover { background: var(--accent); color: #fff; }

/* ---------- contact ---------- */
.contact { padding-block: clamp(84px, 12vw, 160px); text-align: center; }
.contact .kicker { justify-content: center; }
.contact h2 { max-width: none; }
.contact h2 { font-size: clamp(40px, 6.4vw, 92px); }
.contact-mail {
  display: inline-block; margin-top: clamp(26px, 3.5vw, 44px);
  font-family: var(--font-display); font-weight: 600; letter-spacing: -0.03em;
  font-size: clamp(20px, 3.4vw, 42px);
  color: var(--ink);
  border-bottom: 3px solid var(--accent);
  padding-bottom: 6px;
  transition: color .3s, transform .4s var(--ease);
  overflow-wrap: anywhere;
}
.contact-mail:hover { color: var(--accent); transform: translateY(-2px); }
.contact-routes {
  margin-top: clamp(40px, 5vw, 64px);
  display: grid; grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 1px; background: var(--line);
  border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden;
  max-width: 860px; margin-inline: auto; text-align: left;
}
.contact-routes > div { background: var(--card); padding: clamp(20px, 3vw, 30px); transition: background .3s; }
.contact-routes > div:hover { background: var(--paper); }
.contact-routes dt { font-size: 12px; font-weight: 600; letter-spacing: 0.14em; text-transform: uppercase; color: var(--muted); margin-bottom: 8px; }
.contact-routes dd { font-size: 16.5px; font-weight: 600; }
.contact-routes dd a { border-bottom: 1px solid var(--line); transition: color .25s, border-color .25s; }
.contact-routes dd a:hover { color: var(--accent); border-color: var(--accent); }
.contact-note { margin-top: 26px; font-size: 14px; color: var(--muted); }
.contact-note a { color: var(--ink); font-weight: 600; border-bottom: 1px solid var(--accent); }
.contact-note a:hover { color: var(--accent); }

/* ---------- footer ---------- */
.site-footer { border-top: 1px solid var(--line); background: var(--card); padding-block: clamp(44px, 5vw, 64px); }
.footer-grid {
  display: grid; grid-template-columns: minmax(0, 1fr) auto minmax(0, 1fr);
  gap: 32px; align-items: start;
}
.footer-brand { display: flex; flex-direction: column; gap: 6px; }
.footer-brand .brand-mark { width: 30px; height: 30px; margin-bottom: 10px; }
.footer-brand p { font-family: var(--font-display); font-weight: 700; font-size: 19px; letter-spacing: -0.02em; }
.footer-brand small { font-size: 12.5px; color: var(--muted); letter-spacing: 0.02em; }
.footer-nav { display: flex; flex-direction: column; gap: 10px; }
.footer-nav a { font-size: 14.5px; color: var(--muted); transition: color .25s, transform .3s var(--ease); }
.footer-nav a:hover { color: var(--accent); transform: translateX(3px); }
.footer-meta { text-align: right; display: flex; flex-direction: column; gap: 6px; font-size: 13.5px; color: var(--muted); }
.footer-meta a { border-bottom: 1px solid transparent; transition: color .25s, border-color .25s; }
.footer-meta a:hover { color: var(--accent); border-color: var(--accent); }
.footer-meta p:first-child { font-weight: 600; color: var(--ink); font-size: 15px; }
.legal-links { margin-top: 8px; }

/* ---------- legal pages ---------- */
.nav-cta {
  display: inline-flex; align-items: center; padding: 10px 20px; border-radius: 99px;
  background: var(--ink); color: var(--paper); font-size: 14px; font-weight: 600;
  transition: background .3s, transform .3s var(--ease);
}
.nav-cta:hover { background: var(--accent); transform: translateY(-1px); }
.legal-page { padding: calc(var(--header-h) + clamp(48px, 8vw, 96px)) 0 clamp(72px, 10vw, 120px); }
.legal-wrap {
  width: 100%; max-width: 760px; margin-inline: auto; padding-inline: var(--gutter);
  font-size: 16.5px; line-height: 1.78; color: #2c2822;
}
.legal-wrap h1 {
  font-size: clamp(38px, 5.4vw, 56px); margin: 14px 0 6px; line-height: 1.02;
}
.legal-updated { color: var(--muted); font-size: 14px; margin-bottom: clamp(34px, 5vw, 52px); }
.legal-wrap h2 {
  font-size: clamp(20px, 2.4vw, 26px); margin: clamp(32px, 4.5vw, 46px) 0 12px;
  line-height: 1.2; letter-spacing: -0.02em;
}
.legal-wrap p { margin-bottom: 16px; }
.legal-wrap a { color: var(--accent-deep); border-bottom: 1px solid color-mix(in srgb, var(--accent) 40%, transparent); transition: color .25s; }
.legal-wrap a:hover { color: var(--accent); }
.legal-back {
  display: inline-flex; align-items: center; gap: 8px;
  margin-top: clamp(40px, 6vw, 60px); font-size: 14.5px; font-weight: 600;
  border: 1.5px solid var(--line); border-radius: 99px; padding: 11px 22px;
  transition: border-color .3s, color .3s, transform .3s var(--ease);
}
.legal-back:hover { border-color: var(--accent); color: var(--accent); transform: translateX(-3px); }

/* ---------- reveal animation ---------- */
.reveal {
  opacity: 0; transform: translateY(26px);
  transition: opacity .8s var(--ease), transform .8s var(--ease);
  transition-delay: var(--d, 0s);
}
.reveal.is-in { opacity: 1; transform: none; }

/* ---------- responsive ---------- */
@media (max-width: 1080px) {
  .hero-grid { grid-template-columns: 1fr; align-items: stretch; }
  .slot-tall { min-height: 380px; max-width: 560px; }
  .factory-grid, .story-grid, .careers-inner { grid-template-columns: 1fr; align-items: stretch; }
  .careers-side { max-width: 52ch; }
  .pipeline { grid-template-columns: repeat(4, 1fr); }
  .pipeline li:nth-child(4n+1) { border-left: 0; }
  .pipeline li:nth-child(n+5) { border-top: 1px solid var(--line); }
}
@media (max-width: 900px) {
  .site-nav, .header-meta { display: none; }
  .menu-button { display: flex; }
  .header-side { margin-left: auto; }
  .site-nav.is-open {
    display: flex; position: fixed; inset: var(--header-h) 0 auto 0; z-index: 99;
    flex-direction: column; gap: 0; margin: 0;
    background: color-mix(in srgb, var(--paper) 96%, transparent);
    backdrop-filter: blur(18px); -webkit-backdrop-filter: blur(18px);
    border-bottom: 1px solid var(--line);
    padding: 10px var(--gutter) 22px;
  }
  .site-nav.is-open a { padding: 14px 0; border-bottom: 1px solid var(--line); font-size: 17px; color: var(--ink); }
  .site-nav.is-open a:last-child { border-bottom: 0; }
  .craft-row, .craft-row.flip { grid-template-columns: 1fr; }
  .craft-row.flip .craft-text { order: 1; }
  .craft-row.flip .media-slot { order: 2; }
  .partner-row { grid-template-columns: 40px 1fr; }
  .pr-desc { grid-column: 2; }
  .pr-go { grid-column: 2; justify-self: start; }
  .stats-grid { grid-template-columns: repeat(2, 1fr); }
  .stat:nth-child(2n+1) { border-left: 0; }
  .stat:nth-child(n+3) { border-top: 1px solid var(--line); }
  .footer-grid { grid-template-columns: 1fr; }
  .footer-meta { text-align: left; }
}
@media (max-width: 560px) {
  body { font-size: 16px; }
  .pill-cta { display: none; }
  .contact-routes { grid-template-columns: 1fr; }
  .pipeline { grid-template-columns: repeat(2, 1fr); }
  .pipeline li:nth-child(2n+1) { border-left: 0; }
  .pipeline li:nth-child(n+3) { border-top: 1px solid var(--line); }
  .pipeline li:nth-child(n+3):nth-child(2n) { border-left: 1px solid var(--line); }
  .hero-actions .btn-solid, .hero-actions .btn-line { width: 100%; justify-content: center; }
}

/* ---------- motion preference ---------- */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation-duration: .01ms !important; transition-duration: .01ms !important; }
  .reveal { opacity: 1; transform: none; }
}

/* ---------- print ---------- */
@media print {
  .site-header, .footer-nav, .menu-button, .slot-play { display: none; }
  body { background: #fff; color: #000; }
}

/* ==========================================================================
   M13 · AI try-on demo — COMPONENT ONLY
   Prefix: .tryon-*   No dependency on the site stylesheet.
   When merging into `boxbeauty site v2/styles.css`, copy this whole block
   and change nothing except the asset paths (they live in the HTML).
   Geometry below is measured from iPhone17ProMax_FRAME4.png (343 x 657, RGBA
   with a real transparent screen hole). All in-screen sizes use cqi so the
   fake app UI stays proportional at any phone width.
   ========================================================================== */

.tryon {
  --a: #e4522b;                 /* vermilion, matches site --accent */
  /* Screen hole measured from the PNG: x 28..305, y 24..632, corner radius 36.
     The layer is pushed out 1px on every side and its radius is set slightly
     under the hole's, so no paper background can peek through the corners
     (verified programmatically: 0 leaked pixels). */
  --hole-l: 7.8717%;            /* 27 / 343  */
  --hole-t: 3.5008%;            /* 23 / 657  */
  --hole-w: 81.6327%;           /* 280 / 343 */
  --hole-h: 92.9985%;           /* 611 / 657 */
  --font-ui: -apple-system, BlinkMacSystemFont, "SF Pro Text", "Inter Tight", system-ui, sans-serif;

  container-type: inline-size;
  position: relative;
  width: var(--tw, 300px);
  aspect-ratio: 343 / 657;
  isolation: isolate;
  font-family: var(--font-ui);
  -webkit-font-smoothing: antialiased;
}

/* ---------- screen (the transparent hole) ---------- */
.tryon-screen {
  position: absolute;
  left: var(--hole-l); top: var(--hole-t);
  width: var(--hole-w); height: var(--hole-h);
  border-radius: 26px;                       /* fallback */
  border-radius: 9.62cqi;                    /* 33px on a 343px-wide frame */
  overflow: hidden;
  background: #0b0a09;
  z-index: 1;
  contain: paint;
}

/* ---------- photo layers: bare -> press-on ---------- */
.tryon-img {
  position: absolute; inset: 0;
  width: 100%; height: 100%;
  object-fit: cover;
  display: block;
}
.tryon-img-bare { opacity: 1; }
.tryon-img-on   { opacity: 0; transition: opacity .95s cubic-bezier(.4,0,.2,1); }
.tryon[data-phase="result"] .tryon-img-on { opacity: 1; }
.tryon[data-phase="idle"]   .tryon-img-on { opacity: 0; }

/* soft vignette so the white UI text always reads (sits under the UI) */
.tryon-screen::after {
  content: "";
  position: absolute; inset: 0; z-index: 1; pointer-events: none;
  background:
    linear-gradient(to bottom, rgba(10,8,7,.42) 0, rgba(10,8,7,0) 16%),
    linear-gradient(to top,    rgba(10,8,7,.55) 0, rgba(10,8,7,0) 30%);
}

/* ---------- glass reflection (sells the "device" read) ---------- */
.tryon-glare {
  position: absolute; inset: 0; z-index: 4; pointer-events: none;
  background: linear-gradient(122deg,
    rgba(255,255,255,.16) 0%, rgba(255,255,255,.05) 16%,
    rgba(255,255,255,0) 34%, rgba(255,255,255,0) 62%,
    rgba(255,255,255,.06) 82%, rgba(255,255,255,0) 100%);
  mix-blend-mode: screen;
}

/* ---------- shutter flash: also covers the cut between hands ---------- */
.tryon-flash {
  position: absolute; inset: 0; z-index: 6; pointer-events: none;
  background: #fff; opacity: 0;
}
.tryon[data-phase="capture"] .tryon-flash { animation: tryonFlash .62s ease-out both; }
@keyframes tryonFlash {
  0%   { opacity: 0; }
  14%  { opacity: .92; }
  100% { opacity: 0; }
}

/* ---------- AI scan sweep while generating ---------- */
.tryon-scan {
  position: absolute; left: 0; right: 0; top: 0; height: 26%; z-index: 5;
  pointer-events: none; opacity: 0;
  background: linear-gradient(to bottom,
    rgba(228,82,43,0) 0%, rgba(228,82,43,.10) 46%,
    rgba(255,214,196,.95) 50%, rgba(228,82,43,.10) 54%, rgba(228,82,43,0) 100%);
}
.tryon[data-phase="generate"] .tryon-scan {
  opacity: 1;
  animation: tryonScan 1.05s cubic-bezier(.5,0,.5,1) infinite;
}
@keyframes tryonScan {
  0%   { transform: translateY(-110%); }
  100% { transform: translateY(390%); }
}

/* ---------- device frame (has a real hole + opaque island) ---------- */
.tryon-frame {
  position: absolute; inset: 0; z-index: 7;
  width: 100%; height: 100%;
  pointer-events: none;
  filter: drop-shadow(0 14px 26px rgba(20,18,15,.24))
          drop-shadow(0 4px 9px rgba(20,18,15,.13));
}

/* ==========================================================================
   Fake app UI — all of it is real text, so it stays crisp and accessible
   ========================================================================== */
.tryon-ui {
  position: absolute; inset: 0; z-index: 2;
  color: #fff;
}

/* status bar: left/right groups sit around the opaque island */
.tryon-status {
  position: absolute; top: 0; left: 0; right: 0; height: 6.1%;
  display: flex; align-items: center; justify-content: space-between;
  padding-inline: 9.5%;
  font-size: 3.3cqi; font-weight: 600; letter-spacing: .01em;
}
.tryon-status-right { display: flex; align-items: center; gap: 1.5cqi; }
.tryon-signal { display: flex; align-items: flex-end; gap: .5cqi; height: 2.4cqi; }
.tryon-signal i { width: .8cqi; background: #fff; border-radius: .3cqi; opacity: .95; }
.tryon-signal i:nth-child(1) { height: 40%; }
.tryon-signal i:nth-child(2) { height: 62%; }
.tryon-signal i:nth-child(3) { height: 82%; }
.tryon-signal i:nth-child(4) { height: 100%; opacity: .45; }
.tryon-batt {
  position: relative; width: 5.4cqi; height: 2.6cqi;
  border: .35cqi solid rgba(255,255,255,.7); border-radius: .9cqi;
}
.tryon-batt::before {
  content: ""; position: absolute; inset: .35cqi;
  background: #fff; border-radius: .4cqi; width: 72%;
}
.tryon-batt::after {
  content: ""; position: absolute; right: -.95cqi; top: 50%;
  width: .6cqi; height: 1cqi; transform: translateY(-50%);
  background: rgba(255,255,255,.7); border-radius: 0 .3cqi .3cqi 0;
}

/* app bar */
.tryon-appbar {
  position: absolute; top: 7.4%; left: 0; right: 0;
  display: flex; align-items: center; justify-content: space-between;
  padding-inline: 5.5%;
}
.tryon-back {
  width: 5.6cqi; height: 5.6cqi; border-radius: 50%;
  background: rgba(255,255,255,.16);
  display: grid; place-items: center;
}
.tryon-back::before {
  content: ""; width: 2cqi; height: 2cqi;
  border-left: .55cqi solid #fff; border-bottom: .55cqi solid #fff;
  transform: rotate(45deg) translate(.35cqi, -.35cqi);
  border-radius: .15cqi;
}
.tryon-brand {
  text-align: center; line-height: 1.15;
}
.tryon-brand b {
  display: block; font-size: 3.5cqi; font-weight: 700; letter-spacing: .16em;
}
.tryon-brand span {
  display: block; font-size: 2.5cqi; letter-spacing: .22em;
  color: rgba(255,255,255,.62); margin-top: .3cqi;
}
.tryon-spark {
  width: 5.6cqi; height: 5.6cqi; border-radius: 50%;
  background: rgba(228,82,43,.9);
  display: grid; place-items: center;
  box-shadow: 0 0 0 .35cqi rgba(228,82,43,.28);
}
.tryon-spark::before {
  content: ""; width: 2.6cqi; height: 2.6cqi; background: #fff;
  clip-path: polygon(50% 0, 61% 39%, 100% 50%, 61% 61%, 50% 100%, 39% 61%, 0 50%, 39% 39%);
}

/* ---------- bottom sheet ---------- */
.tryon-sheet {
  position: absolute; left: 3.6%; right: 3.6%; bottom: 2.6%;
  border-radius: 5.4cqi;
  padding: 3.6cqi 4cqi 4cqi;
  background: rgba(14,12,11,.72);
  -webkit-backdrop-filter: blur(18px) saturate(160%);
  backdrop-filter: blur(18px) saturate(160%);
  box-shadow: inset 0 0 0 .3cqi rgba(255,255,255,.13),
              0 2cqi 5cqi rgba(0,0,0,.34);
}

/* one pane per step; the active phase decides which one shows */
.tryon-pane { display: none; }
.tryon[data-phase="capture"]  .tryon-pane-capture,
.tryon[data-phase="upload"]   .tryon-pane-upload,
.tryon[data-phase="generate"] .tryon-pane-generate,
.tryon[data-phase="result"]   .tryon-pane-result { display: block; }

.tryon-pane-capture  { animation: tryonPaneIn .42s var(--tryon-ease, cubic-bezier(.22,.75,.28,1)) both; }
.tryon-pane-upload   { animation: tryonPaneIn .42s cubic-bezier(.22,.75,.28,1) both; }
.tryon-pane-generate { animation: tryonPaneIn .42s cubic-bezier(.22,.75,.28,1) both; }
.tryon-pane-result   { animation: tryonPaneIn .55s cubic-bezier(.22,.75,.28,1) both; }
@keyframes tryonPaneIn {
  from { opacity: 0; transform: translateY(2.4cqi); }
  to   { opacity: 1; transform: none; }
}

.tryon-eyebrow {
  display: flex; align-items: center; gap: 1.6cqi;
  font-size: 2.4cqi; letter-spacing: .18em; text-transform: uppercase;
  color: rgba(255,255,255,.6); font-weight: 600;
}
.tryon-eyebrow i {
  width: 1.3cqi; height: 1.3cqi; border-radius: 50%;
  background: rgba(255,255,255,.28);
}
.tryon-eyebrow i.on { background: var(--a); }

.tryon-title {
  margin-top: 1.6cqi;
  font-size: 4.6cqi; font-weight: 700; letter-spacing: -.012em; line-height: 1.15;
}
.tryon-sub {
  margin-top: .9cqi;
  font-size: 2.9cqi; font-weight: 400; line-height: 1.35;
  color: rgba(255,255,255,.66);
}

/* progress */
.tryon-bar {
  position: relative; margin-top: 2.8cqi; height: 1.5cqi;
  border-radius: 99px; background: rgba(255,255,255,.16); overflow: hidden;
}
.tryon-bar-fill {
  position: absolute; inset: 0 auto 0 0; width: 0;
  border-radius: 99px; background: linear-gradient(90deg, #ff7a4d, var(--a));
}
/* the upload fill width is driven by JS so the % label can never drift */
.tryon-bar-fill { transition: none; }

/* indeterminate bar during generation */
.tryon-bar-indet {
  position: absolute; top: 0; bottom: 0; width: 38%;
  border-radius: 99px; background: linear-gradient(90deg, rgba(255,255,255,0), var(--a), rgba(255,255,255,0));
}
.tryon[data-phase="generate"] .tryon-bar-indet {
  animation: tryonSlide 1.15s cubic-bezier(.5,0,.5,1) infinite;
}
@keyframes tryonSlide {
  0%   { transform: translateX(-110%); }
  100% { transform: translateX(310%); }
}

.tryon-pct {
  position: absolute; right: 0; top: -4.6cqi;
  font-size: 2.6cqi; font-variant-numeric: tabular-nums; color: rgba(255,255,255,.72);
}

/* file row + thumbnail */
.tryon-file {
  display: flex; align-items: center; gap: 2.6cqi; margin-top: 2.8cqi;
}
.tryon-thumb {
  position: relative; flex: 0 0 auto;
  width: 11.5cqi; height: 15cqi; border-radius: 2.4cqi;
  overflow: hidden; background: #1a1715;
  box-shadow: inset 0 0 0 .3cqi rgba(255,255,255,.2);
}
.tryon-thumb img { width: 100%; height: 100%; object-fit: cover; display: block; }
.tryon[data-phase="capture"] .tryon-thumb { animation: tryonThumbIn .5s cubic-bezier(.22,.75,.28,1) both; }
@keyframes tryonThumbIn {
  from { opacity: 0; transform: scale(.72) rotate(-5deg); }
  to   { opacity: 1; transform: none; }
}
.tryon-file-meta { min-width: 0; }
.tryon-file-name {
  font-size: 3cqi; font-weight: 600; letter-spacing: -.005em;
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.tryon-file-size { font-size: 2.6cqi; color: rgba(255,255,255,.56); margin-top: .5cqi; }

/* result: swatch strip */
.tryon-swatches {
  display: flex; align-items: center; gap: 1.9cqi; margin-top: 2.8cqi;
}
.tryon-swatches i {
  width: 4.6cqi; height: 4.6cqi; border-radius: 50%;
  box-shadow: inset 0 0 0 .3cqi rgba(255,255,255,.24);
  transition: transform .3s cubic-bezier(.22,.75,.28,1), box-shadow .3s;
}
.tryon-swatches i.on {
  transform: scale(1.22);
  box-shadow: 0 0 0 .55cqi rgba(255,255,255,.9), inset 0 0 0 .3cqi rgba(0,0,0,.15);
}
.tryon-swatches-cap {
  font-size: 2.4cqi; letter-spacing: .14em; text-transform: uppercase;
  color: rgba(255,255,255,.5); margin-top: 2.6cqi;
}

/* CTA */
.tryon-cta {
  margin-top: 3cqi; height: 11cqi; border-radius: 99px;
  display: flex; align-items: center; justify-content: center; gap: 1.8cqi;
  background: #fff; color: #14120f;
  font-size: 3.4cqi; font-weight: 700; letter-spacing: -.01em;
}
.tryon-cta::after {
  content: ""; width: 1.7cqi; height: 1.7cqi;
  border-top: .5cqi solid #14120f; border-right: .5cqi solid #14120f;
  border-radius: .15cqi; transform: rotate(45deg);
}
.tryon-price {
  margin-top: 1.8cqi; text-align: center;
  font-size: 2.6cqi; color: rgba(255,255,255,.55);
}
.tryon-price b { color: #fff; font-weight: 600; }

/* result name gets a small accent rule */
.tryon-pane-result .tryon-title { display: flex; align-items: baseline; gap: 2cqi; }
.tryon-pane-result .tryon-title::before {
  content: ""; flex: 0 0 auto; width: 4.4cqi; height: .7cqi;
  border-radius: 99px; background: var(--a); transform: translateY(-.5cqi);
}

/* live region for screen readers */
.tryon-live { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); }

/* ---------- idle / reduced-motion: collapse the sheet ---------- */
.tryon-sheet { transition: opacity .45s, transform .45s cubic-bezier(.22,.75,.28,1); }
.tryon[data-phase="idle"] .tryon-sheet {
  opacity: 0; transform: translateY(4cqi); pointer-events: none;
}

.tryon[data-static="1"] .tryon-scan,
.tryon[data-static="1"] .tryon-flash { display: none; }

@media (prefers-reduced-motion: reduce) {
  .tryon *, .tryon *::before, .tryon *::after {
    animation-duration: .001ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: .001ms !important;
  }
}

/* ---------- story side: try-on demo placement (M13) ---------- */
.story-tryon { --tw: min(300px, 74%); margin-inline: auto; }
@media (max-width: 1080px) {
  .story-tryon { --tw: 260px; margin-inline: 0; }
}
