:root {
  --paper: #f7f4ef;
  --ink: #161112;
  --muted: #6f6266;
  --line: #e6dfd8;
  --card: #efe9e0;
  --accent: #e4bac3;
  --accent-text: #9b4a60;
  --on-accent: #2a1a1e;

  --plum: #211c1d;
  --plum-ink: #f7eee8;
  --plum-muted: #beacaf;
  --plum-line: #443839;
  --plum-soft: #322a2b;
  --plum-screen: #211c1d;

  --good: #5f7a56;

  --fs-100: 0.875rem;
  --fs-200: 1rem;
  --fs-300: 1.2rem;
  --fs-400: 1.7rem;
  --fs-500: clamp(1.9rem, 1.2rem + 2.8vw, 3.1rem);
  --fs-600: clamp(2.6rem, 1.5rem + 6.4vw, 5.4rem);

  --sp-1: 4px;
  --sp-2: 8px;
  --sp-3: 12px;
  --sp-4: 16px;
  --sp-5: 24px;
  --sp-6: 32px;
  --sp-7: 48px;
  --sp-8: 64px;
  --sp-9: 88px;

  --container: 1240px;
  --gutter: 20px;
  --radius-sm: 10px;
  --radius-md: 20px;
  --radius-lg: 28px;
  --card-radius: clamp(26px, 6vw, 44px);

  --ease: cubic-bezier(.22,.61,.36,1);
  color-scheme: light;
}

* { box-sizing: border-box; }
html { background: var(--paper); }
body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", system-ui, sans-serif;
  font-synthesis: none;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

img, video { display: block; max-width: 100%; }
button { font-family: inherit; }

.display, h1, h2, h3 {
  margin: 0;
  font-family: Georgia, "Times New Roman", serif;
  font-weight: 400;
  letter-spacing: -0.02em;
  line-height: 1.04;
}

em { font-style: italic; }
.hero-copy em, .final-cta em, .compare-copy-col em { color: var(--accent-text); }
.dark-card em { color: var(--accent); }

p { margin: 0; color: var(--muted); line-height: 1.6; }
a { color: inherit; }

.visually-hidden {
  position: absolute;
  width: 1px; height: 1px;
  overflow: hidden;
  clip: rect(0,0,0,0);
  white-space: nowrap;
}

.wrap {
  max-width: var(--container);
  margin: 0 auto;
  padding-left: var(--gutter);
  padding-right: var(--gutter);
}

.center { text-align: center; margin-left: auto; margin-right: auto; }

/* ---------- nav ---------- */

.topbar { position: relative; z-index: 5; }
.topbar .wrap {
  padding-top: var(--sp-4);
  padding-bottom: var(--sp-2);
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.wordmark { font-family: Georgia, serif; font-size: var(--fs-300); letter-spacing: -0.02em; }
.wordmark .dot { color: var(--accent-text); }

.topbar-link {
  font-size: var(--fs-100);
  color: var(--muted);
  text-decoration: none;
  border: 1px solid var(--line);
  border-radius: 30px;
  padding: 9px 18px;
  transition: background .15s var(--ease), color .15s var(--ease), border-color .15s var(--ease);
}
.topbar-link:hover { background: var(--card); color: var(--ink); border-color: var(--card); }
.topbar-link:focus-visible { outline: 2px solid var(--accent-text); outline-offset: 2px; }

main { display: block; }

/* ---------- buttons / forms (shared) ---------- */

.primary-btn {
  position: relative;
  isolation: isolate;
  overflow: hidden;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  min-height: 54px;
  border-radius: 999px;
  border: 0;
  background: linear-gradient(180deg, #2c2224, #140f10);
  color: #fbf6f1;
  font-size: var(--fs-200);
  font-weight: 600;
  letter-spacing: .005em;
  cursor: pointer;
  padding: 0 28px;
  box-shadow: inset 0 1px 0 rgba(255,255,255,.14), 0 1px 2px rgba(22,17,18,.3), 0 10px 26px -10px rgba(155,74,96,.55);
  transition: transform .2s var(--ease), box-shadow .2s var(--ease);
}
/* A slow light sweep across the button every few seconds. */
.primary-btn::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  background: linear-gradient(105deg, transparent 35%, rgba(228,186,195,.28) 50%, transparent 65%);
  transform: translateX(-120%);
  animation: btn-sheen 5.5s ease-in-out 1.2s infinite;
}
@keyframes btn-sheen { 0%, 62% { transform: translateX(-120%); } 82%, 100% { transform: translateX(120%); } }
.btn-arrow {
  display: grid;
  place-items: center;
  width: 38px;
  height: 38px;
  border-radius: 999px;
  background: var(--accent);
  transition: transform .25s var(--ease);
}
.btn-arrow::before {
  content: "";
  width: 14px;
  height: 14px;
  background: var(--on-accent);
  -webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 14 14'%3E%3Cpath d='M1 7h11M8 3l4 4-4 4' fill='none' stroke='black' stroke-width='1.8' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E") center / contain no-repeat;
          mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 14 14'%3E%3Cpath d='M1 7h11M8 3l4 4-4 4' fill='none' stroke='black' stroke-width='1.8' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E") center / contain no-repeat;
}
.primary-btn:hover { box-shadow: inset 0 1px 0 rgba(255,255,255,.18), 0 1px 2px rgba(22,17,18,.3), 0 14px 32px -10px rgba(155,74,96,.7); }
.primary-btn:hover .btn-arrow { transform: translateX(3px) rotate(-8deg); }
.primary-btn:active { transform: scale(.97); }
.primary-btn:disabled { opacity: .55; cursor: default; transform: none; }
.primary-btn:focus-visible { outline: 2px solid var(--accent-text); outline-offset: 3px; }

.ghost-btn {
  min-height: 44px;
  border-radius: 999px;
  border: 1px solid var(--line);
  background: transparent;
  color: var(--ink);
  font-size: var(--fs-100);
  font-weight: 600;
  cursor: pointer;
  padding: 0 var(--sp-5);
  transition: background .15s var(--ease), border-color .15s var(--ease), transform .15s var(--ease);
  white-space: nowrap;
}
.ghost-btn:hover { background: var(--card); border-color: var(--card); }
.ghost-btn:active { transform: scale(.97); }
.ghost-btn:focus-visible { outline: 2px solid var(--accent-text); outline-offset: 2px; }

.waitlist-form .field-row {
  display: flex;
  flex-direction: column;
  gap: var(--sp-3);
}

.email-input {
  width: 100%;
  min-height: 52px;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 999px;
  color: var(--ink);
  padding: 0 var(--sp-5);
  font-size: 16px;
  font-family: inherit;
}
.email-input::placeholder { color: var(--muted); }
.email-input:focus-visible { outline: 2px solid var(--accent-text); outline-offset: 2px; }

.hp-field { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0,0,0,0); }

.form-note { font-size: var(--fs-100); margin-top: var(--sp-3); color: var(--muted); }

.form-status {
  font-size: var(--fs-100);
  margin-top: var(--sp-2);
  min-height: 16px;
  color: var(--accent-text);
}
.form-status[data-state="error"] { color: #b0473f; }

/* ---------- waitlist success ---------- */

.waitlist-success {
  border: 1px solid var(--line);
  border-radius: var(--radius-md);
  padding: var(--sp-5);
  background: #fff;
}
.waitlist-success[hidden] { display: none; }
.success-position { font-family: Georgia, serif; font-size: var(--fs-400); color: var(--ink); letter-spacing: -0.01em; }
.success-position strong { color: var(--accent-text); font-weight: 400; }
.success-note { margin-top: var(--sp-2); font-size: var(--fs-100); max-width: 360px; }
.referral-link-row { margin-top: var(--sp-4); display: flex; gap: var(--sp-2); flex-wrap: wrap; }
.referral-link {
  flex: 1 1 180px;
  min-width: 0;
  min-height: 44px;
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: 999px;
  color: var(--muted);
  padding: 0 var(--sp-4);
  font-size: var(--fs-100);
  font-family: inherit;
}
.referral-link:focus-visible { outline: 2px solid var(--accent-text); outline-offset: 2px; }
.copy-status { margin-top: var(--sp-2); font-size: var(--fs-100); color: var(--good); min-height: 16px; }

/* ---------- hero ---------- */

.hero {
  position: sticky;
  top: 0;
  z-index: 1;
  min-height: 100svh;
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: var(--sp-5);
  background: var(--paper);
  padding-top: var(--sp-6);
  padding-bottom: var(--sp-6);
  overflow: hidden;
  transform: scale(1);
  opacity: 1;
  will-change: transform, opacity;
}

.hero-top { width: 100%; }
.hero-copy { width: min(640px, 100%); margin-inline: auto; }  /* fixed width, so the rotating word never shifts the layout */

.headline { font-size: var(--fs-600); margin: 0 0 var(--sp-4); }
.headline { line-height: .95; }
.headline em { font-size: 0.5em; display: block; line-height: 1.12; margin-top: 0.14em; }

.subhead { font-size: var(--fs-300); max-width: 460px; margin: 0 0 var(--sp-5); color: var(--muted); }

/* ---------- hero carousel ---------- */

.carousel {
  width: 100%;
  overflow: hidden;
  padding: 28px var(--gutter);
}

.carousel-track {
  display: flex;
  align-items: flex-start;
  gap: var(--sp-4);
  width: max-content;
  will-change: transform;
}

.tile {
  position: relative;
  flex: 0 0 auto;
  width: 62vw;
}

.tile-media {
  position: relative;
  aspect-ratio: 2 / 3;
  border-radius: var(--radius-lg);
  overflow: hidden;
  background: var(--card);
}
.tile-video { width: 100%; height: 100%; object-fit: cover; }

.carousel-track .tile:nth-child(8n+1) .tile-media { transform: translateY(0); }
.carousel-track .tile:nth-child(8n+2) .tile-media { transform: translateY(24px); }
.carousel-track .tile:nth-child(8n+3) .tile-media { transform: translateY(-14px); }
.carousel-track .tile:nth-child(8n+4) .tile-media { transform: translateY(16px); }
.carousel-track .tile:nth-child(8n+5) .tile-media { transform: translateY(-8px); }
.carousel-track .tile:nth-child(8n+6) .tile-media { transform: translateY(20px); }
.carousel-track .tile:nth-child(8n+7) .tile-media { transform: translateY(-18px); }
.carousel-track .tile:nth-child(8n) .tile-media { transform: translateY(10px); }

@media (min-width: 760px) {
  .tile { width: clamp(260px, 20vw, 300px); }
}

/* ---------- dark card ---------- */

.dark-card {
  position: relative;
  z-index: 2;
  background: var(--plum);
  color: var(--plum-ink);
  border-radius: var(--card-radius) var(--card-radius) 0 0;
  padding: var(--sp-8) 0 var(--sp-9);
  overflow: hidden;
  box-shadow: 0 -30px 60px rgba(0,0,0,.18);
}

.dark-card-inner {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: var(--sp-5);
}

.dark-heading { max-width: 560px; text-align: center; }
.dark-heading h2 { font-size: var(--fs-500); color: var(--plum-ink); }
.dh-word {
  display: inline-block;
  color: var(--plum-ink);
  opacity: .45;
  text-decoration: underline;
  text-decoration-thickness: 3px;
  text-underline-offset: .13em;
  text-decoration-color: transparent;
  transition: color .5s var(--ease), opacity .5s var(--ease), text-decoration-color .5s var(--ease);
}
.dh-word.is-active { color: var(--accent); opacity: 1; text-decoration-color: var(--accent); }
.dark-sub { margin-top: var(--sp-3); font-size: var(--fs-200); color: var(--plum-muted); }

.phone-stage { position: relative; display: flex; flex-direction: column; align-items: center; width: 100%; }

/* The render has transparent margins (the phone body is ~63% of the image width), so the box is
   oversized and centred with negative margins; the card's overflow:hidden crops its lower part. */
.phone-wrap {
  --pw: min(760px, 142vw);
  position: relative;
  width: var(--pw);
  aspect-ratio: 2 / 3;
  margin: calc(var(--pw) * -0.06) calc((100% - var(--pw)) / 2) calc(var(--pw) * -0.06);
  filter: drop-shadow(0 46px 60px rgba(0,0,0,.48)) drop-shadow(0 0 44px rgba(228,186,195,.3));
}

.phone-glow {
  position: absolute;
  left: 50%;
  top: 40%;
  width: 132%;
  height: 100%;
  transform: translate(-50%, -50%);
  background: radial-gradient(closest-side, rgba(228,186,195,.4), transparent 72%);
  z-index: 0;
  pointer-events: none;
}

/* ---------- floating piece cards beside the phone ---------- */

.piece-strip {
  display: flex;
  gap: var(--sp-3);
  width: 100%;
  max-width: 380px;
  margin: 0 auto var(--sp-5);
  padding: 0 var(--gutter);
  overflow-x: auto;
  scrollbar-width: none;
}
.piece-strip::-webkit-scrollbar { display: none; }

.piece-card {
  position: relative;
  flex: 0 0 auto;
  width: 96px;
  background: var(--plum-soft);
  border: 1px solid var(--plum-line);
  border-radius: 16px;
  padding: var(--sp-2);
  box-shadow: 0 12px 26px rgba(0,0,0,.3);
  transition: opacity .45s var(--ease), transform .45s var(--ease), box-shadow .3s ease, border-color .3s ease;
}
.piece-card-img { display: block; aspect-ratio: 1 / 1; border-radius: 10px; overflow: hidden; background: #4a3d3f; margin-bottom: 7px; }
.piece-card-img img { width: 100%; height: 100%; object-fit: cover; transition: opacity .3s ease; }
.piece-card-img img.is-fading { opacity: 0; }
.piece-card-name { display: block; font-size: 11.5px; color: var(--plum-ink); line-height: 1.25; }
.piece-card-price { display: block; font-size: 11px; color: var(--plum-muted); margin-top: 2px; }

.piece-card.is-out { opacity: 0; transform: translateY(-10px) scale(.92); }
.piece-card.is-in { animation: piece-in .5s var(--ease); }
@keyframes piece-in { from { opacity: 0; transform: translateY(10px) scale(.94); } to { opacity: 1; transform: none; } }
.piece-card.is-ring { border-color: var(--accent); box-shadow: 0 0 0 2px var(--accent), 0 12px 26px rgba(0,0,0,.3); }

@media (min-width: 1024px) {
  .piece-strip { position: absolute; inset: 0; max-width: none; margin: 0; padding: 0; overflow: visible; pointer-events: none; }
  .piece-card { position: absolute; width: 176px; padding: var(--sp-3); pointer-events: auto; }
  .piece-card-img { margin-bottom: 10px; }
  .piece-card-name { font-size: 14px; }
  .piece-card-price { font-size: 13px; }
  .piece-card[data-piece-slot="0"] { left: -4%; top: 6%; }
  .piece-card[data-piece-slot="1"] { left: 3%; top: 46%; }
  .piece-card[data-piece-slot="2"] { right: -4%; top: 24%; }
}

.phone-frame {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  z-index: 2;
  pointer-events: none;
}

.phone-screen {
  position: absolute;
  left: 20.21%;
  top: 6.38%;
  width: 59.57%;
  height: 86.91%;
  border-radius: 11% / 5%;
  overflow: hidden;
  background: var(--plum-screen);
  z-index: 1;
  container-type: size;
  container-name: phone-screen;
}

/* ---------- mini app mock (inside phone screen) ---------- */

.app-mock {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  padding: 5cqh 6cqw 4cqh;
  color: var(--plum-ink);
}

.app-header { display: flex; align-items: center; }
.app-back { font-size: 5.4cqw; line-height: 1; color: var(--plum-ink); }

.app-title {
  font-family: Georgia, serif;
  font-size: 6.4cqw;
  letter-spacing: -0.01em;
  color: var(--plum-ink);
  margin: 3.2cqh 0 3.6cqh;
  line-height: 1.1;
}
/* The stack peeks out below the front card, so the title keeps clean space above it. */
.app-card { transform-origin: 50% 100%; }

.app-stack { position: relative; flex: 1 1 auto; min-height: 0; touch-action: pan-y; user-select: none; -webkit-user-select: none; }
.app-card.role-top { cursor: grab; }

.app-card {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  aspect-ratio: 2 / 3;
  border-radius: 11px;
  overflow: hidden;
  background: #3a3032;
  box-shadow: 0 10px 22px rgba(0,0,0,.35);
  transition: transform .45s cubic-bezier(.34,1.56,.64,1), opacity .45s ease;
}
.app-card img { width: 100%; height: 100%; object-fit: cover; display: block; transition: opacity .3s ease; }
.app-card img.is-fading { opacity: 0; }

.app-card.role-top { transform: translate(0, 0) scale(1); opacity: 1; z-index: 3; }
.app-card.role-back1 { transform: translateY(2.4%) scale(.95); opacity: .7; z-index: 2; }
.app-card.role-back2 { transform: translateY(4.4%) scale(.9); opacity: .4; z-index: 1; }
.app-card.leaving-save { transform: translate(62%, -4%) rotate(10deg) scale(.92); opacity: 0; z-index: 4; }
.app-card.leaving-pass { transform: translate(-62%, -4%) rotate(-10deg) scale(.92); opacity: 0; z-index: 4; }
.app-card.snap { transition: none !important; }

.app-stamp {
  position: absolute;
  top: 6%;
  padding: 1.6cqh 3.4cqw;
  font: 800 6cqw/1 -apple-system, BlinkMacSystemFont, sans-serif;
  letter-spacing: .05em;
  border: 2px solid transparent;
  border-radius: 8px;
  opacity: 0;
  transform: scale(.8);
  transition: opacity .22s ease, transform .22s ease;
  pointer-events: none;
  z-index: 5;
}
.app-stamp.is-shown { opacity: 1; transform: scale(1); }
.app-stamp.is-save { right: 6%; color: var(--accent); border-color: var(--accent); }
.app-stamp.is-pass { left: 6%; color: var(--plum-muted); border-color: var(--plum-muted); }

.app-actions { display: flex; gap: 2.6cqw; padding-top: 4.2cqh; }
.app-btn {
  flex: 1;
  padding: 2cqh 0;
  border-radius: 999px;
  border: 1px solid var(--plum-line);
  background: transparent;
  color: var(--plum-ink);
  font-size: 3.8cqw;
  font-weight: 600;
}
.app-swap.is-active { background: var(--plum-soft); border-color: var(--accent); color: var(--accent); }
.app-save { background: var(--accent); border-color: var(--accent); color: var(--on-accent); }

.app-tabbar {
  display: flex;
  justify-content: space-between;
  gap: 2cqw;
  padding-top: 2.2cqh;
  margin-top: 2.4cqh;
  border-top: 1px solid var(--plum-line);
}
.app-tab {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: .8cqh;
  flex: 1;
  opacity: .55;
}
.app-tab.is-active { opacity: 1; }
.app-tab img { width: 6.6cqw; height: 6.6cqw; object-fit: contain; }
.app-tab b { font-size: 2.7cqw; font-weight: 600; color: var(--plum-ink); }
.app-tab-dot { position: absolute; top: -1cqh; right: 30%; width: 1.6cqw; height: 1.6cqw; border-radius: 50%; background: var(--accent); }

/* ---------- compare (before/after) ---------- */

.compare-section { position: relative; z-index: 2; background: var(--paper); padding: var(--sp-7) 0; }

.compare-layout {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: var(--sp-5);
  text-align: center;
}

.compare-copy-col { max-width: 420px; }
.compare-copy-col h2 { font-size: var(--fs-500); }
.compare-line { margin-top: var(--sp-3); font-size: var(--fs-200); }

.compare { width: 100%; max-width: 380px; }

.compare-frame {
  position: relative;
  max-width: 380px;
  width: 100%;
  margin: 0 auto;
  aspect-ratio: 2 / 3;
  border-radius: var(--radius-lg);
  overflow: hidden;
  background: var(--card);
  box-shadow: 0 30px 70px rgba(29,23,24,.14);
  touch-action: pan-y;
  user-select: none;
  -webkit-user-select: none;
}
.compare-frame img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.compare-clip { position: absolute; inset: 0; clip-path: inset(0 calc(100% - var(--pos, 50%)) 0 0); }
.compare-clip-img { position: static; }

.compare-pill {
  position: absolute;
  top: var(--sp-3);
  font-size: 11px;
  letter-spacing: 0.03em;
  color: #fff;
  background: rgba(29, 23, 24, 0.55);
  border-radius: 999px;
  padding: 6px 12px;
  pointer-events: none;
}
.compare-pill-before { left: var(--sp-3); }
.compare-pill-after { right: var(--sp-3); }

.compare-handle {
  position: absolute;
  top: 0; bottom: 0;
  left: var(--pos, 50%);
  width: 2px;
  background: rgba(255,255,255,.85);
  transform: translateX(-50%);
  cursor: ew-resize;
}
.compare-handle-grip {
  position: absolute;
  top: 50%; left: 50%;
  width: 44px; height: 44px;
  transform: translate(-50%, -50%);
  border-radius: 50%;
  background: #fff;
  box-shadow: 0 6px 18px rgba(29,23,24,.25);
}
.compare-handle-grip::before {
  content: "";
  position: absolute;
  top: 50%; left: 50%;
  width: 16px; height: 16px;
  transform: translate(-50%, -50%);
  background:
    linear-gradient(90deg, var(--ink) 2px, transparent 2px) 0 50% / 6px 2px no-repeat,
    linear-gradient(90deg, var(--ink) 2px, transparent 2px) 100% 50% / 6px 2px no-repeat;
}
.compare-handle:focus-visible .compare-handle-grip { outline: 2px solid var(--accent-text); outline-offset: 3px; }

/* ---------- bento ---------- */

.bento-section { position: relative; z-index: 2; background: var(--paper); padding: var(--sp-7) 0; border-top: 1px solid var(--line); }
.bento-heading { text-align: center; max-width: 520px; margin: 0 auto var(--sp-6); }
.bento-heading h2 { font-size: var(--fs-500); }

.bento-grid { display: grid; grid-template-columns: 1fr; gap: var(--sp-4); }

.bento-tile {
  background: #fbf8f4;
  border: 1px solid var(--line);
  border-radius: 26px;
  padding: var(--sp-6) var(--sp-5);
  transition: transform .25s var(--ease), box-shadow .25s var(--ease);
}
.bento-tile h3 { display: flex; align-items: center; gap: 8px; font-family: Georgia, serif; font-weight: 400; font-size: 1.3rem; letter-spacing: -0.01em; margin-bottom: var(--sp-2); color: var(--ink); }
.bento-icon { display: inline-flex; width: 22px; height: 22px; opacity: .8; }
.bento-icon img { width: 100%; height: 100%; object-fit: contain; }
.bento-tile p { font-size: var(--fs-100); max-width: 34ch; margin-bottom: var(--sp-5); }

.bento-visual { position: relative; }

.bento-icon-badge {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 46px;
  height: 46px;
  border-radius: 14px;
  background: #fff;
  border: 1px solid var(--line);
  margin-bottom: var(--sp-4);
  box-shadow: 0 6px 16px -8px rgba(29,23,24,.18);
}
.bento-icon-badge img { width: 30px; height: 30px; object-fit: contain; }

/* sizes */
.size-chips { display: flex; gap: 8px; flex-wrap: wrap; margin-bottom: var(--sp-4); }
.size-chip { font-size: 12px; padding: 7px 13px; border-radius: 999px; border: 1px solid var(--line); color: var(--muted); background: #fff; transition: background .35s ease, color .35s ease, border-color .35s ease; }
.size-chip.is-active { background: var(--ink); color: #fff; border-color: var(--ink); }
.size-card { display: flex; align-items: center; gap: 10px; padding: 8px; border: 1px solid var(--line); border-radius: 14px; background: #fff; }
.size-card-img { width: 44px; height: 44px; border-radius: 8px; overflow: hidden; background: var(--card); flex: 0 0 auto; }
.size-card-img img { width: 100%; height: 100%; object-fit: cover; }
.size-card-stock { font-size: 11px; color: var(--good); display: flex; align-items: center; gap: 6px; }
.size-card-stock i { width: 6px; height: 6px; border-radius: 50%; background: var(--good); display: block; }

/* swap */
.mini-outfit { display: flex; gap: 10px; }
.mini-piece { width: 30%; aspect-ratio: 1 / 1; border-radius: 12px; overflow: hidden; background: var(--card); }
.mini-piece img { width: 100%; height: 100%; object-fit: cover; transition: opacity .4s ease; }
.mini-piece img.is-fading { opacity: 0; }

/* bag */
.bag-list { display: flex; flex-direction: column; gap: 10px; margin-bottom: var(--sp-3); list-style: none; padding: 0; }
.bag-list li { display: flex; align-items: center; gap: 10px; font-size: 13px; }
.bag-icon { width: 26px; height: 26px; border-radius: 8px; background: var(--card); display: grid; place-items: center; flex: 0 0 auto; }
.bag-icon img { width: 16px; height: 16px; object-fit: contain; }
.bag-name { flex: 1; color: var(--ink); }
.bag-price { color: var(--muted); }
.bag-total { display: flex; justify-content: space-between; font-size: 13px; font-weight: 600; padding-top: 10px; border-top: 1px solid var(--line); color: var(--ink); }
.bag-note { margin-top: var(--sp-3); font-size: 11px; color: var(--muted); }

/* taste */
.taste-chips { display: flex; flex-wrap: wrap; gap: 8px; }
.taste-chip { font-size: 12px; padding: 7px 13px; border-radius: 999px; border: 1px solid var(--line); background: #fff; color: var(--muted); opacity: 0; transform: translateY(6px); transition: opacity .5s var(--ease), transform .5s var(--ease); }
.taste-chip.is-shown { opacity: 1; transform: none; }
.taste-chip.is-primary { background: var(--ink); color: #fff; border-color: var(--ink); }
.taste-caption { margin-top: var(--sp-4); font-size: 11px; color: var(--muted); }

/* saved */
.bento-tile-wide { }
.saved-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 10px; }
.saved-shot { aspect-ratio: 2 / 3; border-radius: 12px; overflow: hidden; background: var(--card); }
.saved-shot img { width: 100%; height: 100%; object-fit: cover; }

@media (min-width: 760px) {
  .bento-grid { grid-template-columns: repeat(3, 1fr); gap: var(--sp-5); }
  .bento-tile-wide { grid-column: span 2; }
  .bento-tile:hover { transform: translateY(-4px); box-shadow: 0 22px 40px -20px rgba(29,23,24,.18); }
}

/* ---------- final cta ---------- */

.final-cta { position: relative; z-index: 2; background: var(--paper); padding: var(--sp-8) 0 var(--sp-7); border-top: 1px solid var(--line); }
.final-cta-inner { max-width: 520px; margin: 0 auto; text-align: center; }
.final-cta h2 { font-size: var(--fs-500); margin-bottom: var(--sp-6); }
.final-cta .waitlist-form .field-row { align-items: stretch; }
.final-cta .form-status,
.final-cta .form-note { text-align: center; }
.final-cta .waitlist-success { text-align: left; }

/* ---------- footer ---------- */

.site-footer { position: relative; z-index: 2; background: var(--paper); padding: var(--sp-6) 0 var(--sp-7); }
.footer-meta {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--sp-4);
  font-size: var(--fs-100);
  color: var(--muted);
  padding-top: var(--sp-5);
  border-top: 1px solid var(--line);
}
.footer-meta a { color: var(--muted); text-decoration: underline; text-underline-offset: 2px; }
.footer-meta a:hover { color: var(--ink); }

/* ---------- entrance animation ---------- */

.reveal { opacity: 0; transform: translateY(18px); transition: opacity .7s var(--ease), transform .7s var(--ease); }
.reveal.in-view { opacity: 1; transform: translateY(0); }

@media (prefers-reduced-motion: reduce) {
  .reveal { opacity: 1; transform: none; transition: none; }
  .hero { transform: none !important; opacity: 1 !important; }
  .carousel-track { transform: none !important; }
  .app-card { transition: none !important; }
  .app-stamp { display: none !important; }
  .dh-word { transition: none !important; }
  .piece-card, .piece-card-img img { transition: none !important; animation: none !important; }
  .size-chip, .mini-piece img, .taste-chip { transition: none !important; }
  .taste-chip { opacity: 1 !important; transform: none !important; }
  .bento-tile { transition: none !important; }
  * { scroll-behavior: auto !important; }
}

/* ---------- desktop ---------- */

@media (min-width: 760px) {
  .wrap { padding-left: 40px; padding-right: 40px; }

  .carousel { padding: 30px 40px; }
  .carousel-track { gap: var(--sp-5); }

  .compare-layout { flex-direction: row; align-items: center; justify-content: center; gap: var(--sp-8); text-align: left; }
  .compare-copy-col { flex: 0 0 340px; }
  .compare { flex: 1 1 380px; min-width: 0; }
  .compare-frame { margin: 0; }

  .final-cta .waitlist-form .field-row { flex-direction: row; }
  .final-cta .email-input { flex: 1; }
}

@media (min-width: 900px) {
  .waitlist-form .field-row { flex-direction: row; }
  .email-input { flex: 1; }
  .primary-btn { white-space: nowrap; }
}

@media (min-width: 1000px) {
  .compare-line { font-size: var(--fs-300); }
}

/* ---------- short viewports: don't let the hero starve the fold ---------- */

@media (max-height: 700px) {
  .hero { padding-top: var(--sp-5); padding-bottom: var(--sp-5); gap: var(--sp-4); }
  .headline { margin-bottom: var(--sp-3); }
  .subhead { margin-bottom: var(--sp-4); }
}

/* ---------- headline word rotator ---------- */
.rotator { position: relative; display: inline-block; white-space: nowrap; vertical-align: bottom; transition: width .5s var(--ease); }
.rotator-word { display: inline-block; }
.rotator-word .ch { display: inline-block; transition: transform .55s cubic-bezier(.2,.8,.2,1), opacity .45s ease, filter .45s ease; }
.rotator-word .ch.is-out { transform: translateY(-.45em); opacity: 0; filter: blur(6px); }
.rotator-word .ch.is-pre { transform: translateY(.5em); opacity: 0; filter: blur(6px); transition: none; }
.rotator-swash { position: absolute; left: -2%; bottom: -.12em; width: 104%; height: .32em; overflow: visible; pointer-events: none; }
.rotator-swash path { fill: none; stroke: var(--accent); stroke-width: 5; stroke-linecap: round; stroke-dasharray: 340; stroke-dashoffset: 0; transition: stroke-dashoffset .8s cubic-bezier(.65,0,.35,1) .15s; }
.rotator.is-changing .rotator-swash path { stroke-dashoffset: 340; transition: stroke-dashoffset .35s ease; }

/* ---------- warmth: two soft lights and a fine paper grain ---------- */
.hero {
  background:
    radial-gradient(55% 45% at 12% 18%, rgba(228,186,195,.38), transparent 70%),
    radial-gradient(45% 40% at 92% 6%, rgba(244,208,176,.34), transparent 72%),
    var(--paper);
}
body::before {
  content: "";
  position: fixed;
  inset: 0;
  z-index: 100;
  pointer-events: none;
  opacity: .07;
  mix-blend-mode: multiply;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='160' height='160'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.9' numOctaves='2' stitchTiles='stitch'/%3E%3CfeColorMatrix values='0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1 0'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
}
.headline { color: var(--ink); }
@media (prefers-reduced-motion: reduce) {
  .primary-btn::after { animation: none; }
  .rotator, .rotator-word .ch, .rotator-swash path { transition: none !important; }
}

/* Let the hero's warm light run to the top edge: the bar floats over it. */
.topbar { position: absolute; top: 0; left: 0; right: 0; }
.hero { padding-top: calc(var(--sp-6) + 64px); }

/* ---------- bento, refined: one large icon per tile, soft borderless chips ---------- */
.bento-tile { display: flex; flex-direction: column; }
.bento-head { display: flex; align-items: flex-start; gap: 18px; margin-bottom: 24px; }
.bento-glyph { flex: none; width: 76px; height: 76px; object-fit: contain; margin: -6px 0 0 -6px; filter: drop-shadow(0 10px 14px rgba(120,70,80,.16)); transition: transform .35s var(--ease); }
.bento-tile:hover .bento-glyph { transform: translateY(-3px) rotate(-3deg); }
.bento-head h3 { margin: 4px 0 6px; }
.bento-head p { margin: 0; }
.bento-visual { margin-top: 4px; }
.bento-icon-badge, .bag-icon, .bento-icon { display: none !important; }
.size-chips, .taste-chips { display: flex; flex-wrap: wrap; gap: 8px; }
.size-chip, .taste-chip { border: 0 !important; background: #ece5dc; color: var(--ink); padding: 8px 14px; border-radius: 999px; font-size: var(--fs-100); box-shadow: none !important; }
.size-chip.is-active, .taste-chip.is-primary { background: var(--ink); color: #fbf6f1; }
.size-card { display: flex; align-items: center; gap: 14px; margin-top: 14px; border: 0 !important; background: #fbf8f4; border-radius: 16px; padding: 10px; box-shadow: 0 1px 0 rgba(22,17,18,.04), 0 8px 20px -14px rgba(22,17,18,.25); }
.size-card-img { flex: none; width: 56px; height: 56px; border-radius: 10px; overflow: hidden; background: #ece6de; }
.size-card-img img { width: 100%; height: 100%; object-fit: cover; }
.size-card-text { display: flex; flex-direction: column; gap: 3px; font-size: var(--fs-100); }
.size-card-text strong { font-weight: 600; color: var(--ink); }
.size-card-stock { display: inline-flex; align-items: center; gap: 6px; color: var(--good); }
.size-card-stock i { width: 6px; height: 6px; border-radius: 50%; background: var(--good); display: inline-block; }
.bag-list li { display: flex; justify-content: space-between; gap: 12px; padding: 9px 0; border-bottom: 1px solid rgba(22,17,18,.06); }
.taste-caption { margin-top: 12px; font-size: var(--fs-100); color: var(--muted); }

.mini-outfit { display: grid !important; grid-template-columns: repeat(3, 1fr); gap: 10px; }
.mini-piece { width: auto !important; height: auto !important; aspect-ratio: 1; border-radius: 14px; overflow: hidden; background: #ece6de; }
.mini-piece img { width: 100%; height: 100%; object-fit: cover; }
.taste-pieces { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; margin-top: 14px; }
.taste-pieces span { aspect-ratio: 1; border-radius: 14px; overflow: hidden; background: #ece6de; }
.taste-pieces img { width: 100%; height: 100%; object-fit: cover; }
.size-card { margin-top: 16px; }
.size-card-img { width: 72px; height: 72px; }

/* Card fills its slot (image covers), leaving a fixed gap for the stack peeking below. */
.app-card { top: 0; left: 0; right: 0; width: 100%; height: calc(100% - 2.6cqh); aspect-ratio: auto; }
.app-actions { padding-top: 2.2cqh; }

/* ---------- framed hero: the warm hero sits as a rounded card inside a thin near-black frame ---------- */
:root { --frame: #0e0a0b; --frame-gap: 8px; }
html, body { background: var(--frame); }
.compare-section, .bento-section, .final-cta, .site-footer { background: var(--paper); position: relative; z-index: 2; }
.hero {
  top: var(--frame-gap);
  margin: var(--frame-gap) var(--frame-gap) 0;
  /* svh, not dvh: dvh changes as the phone's toolbar collapses on scroll-down, relaying out the hero every frame. */
  min-height: calc(100svh - var(--frame-gap));
  border-radius: 16px 16px 0 0;
}

/* Where supported, the recede runs as a scroll-driven animation on the compositor, locked to the scroll.
   Range: dark card's top at the viewport bottom (entry 0%) to its top at the viewport top (exit-crossing 0%). */
@supports (animation-timeline: view()) and (timeline-scope: --x) {
  @media (prefers-reduced-motion: no-preference) {
    main { timeline-scope: --dark-card; }
    .dark-card { view-timeline: --dark-card block; }
    .hero {
      animation: hero-recede linear both;
      animation-timeline: --dark-card;
      animation-range: entry 0% exit-crossing 0%;
    }
  }
}
@keyframes hero-recede { from { transform: scale(1); } to { transform: scale(.95); } }
.topbar { top: var(--frame-gap); left: var(--frame-gap); right: var(--frame-gap); }
@media (max-width: 759.98px) { :root { --frame-gap: 6px; } .hero { border-radius: 14px 14px 0 0; } }

/* Against the dark frame a fading hero turns grey, so it only scales back as the card covers it. */
.hero { opacity: 1 !important; }

/* The bar lives inside the pinned hero card, so it moves with it and never collides with the frame. */
.hero > .topbar { position: absolute; top: 0; left: 0; right: 0; z-index: 5; }
.hero > .topbar .wrap { justify-content: space-between; align-items: center; }
.topbar-mark { display: block; width: 40px; height: 40px; border-radius: 10px; box-shadow: 0 6px 16px -6px rgba(22,17,18,.45); transition: transform .2s var(--ease); }
.topbar-mark img { width: 100%; height: 100%; display: block; border-radius: 10px; }
.topbar-mark:hover { transform: translateY(-1px) rotate(-3deg); }
