/* ============================================================
   ATELIER CHUNCHUN — couture stylesheet
   ivory paper · ink · antique gold · oxblood seal
   ============================================================ */
@font-face { font-family: 'Bodoni'; src: url('fonts/bodoni-moda-latin-400-normal.woff2') format('woff2'); font-weight: 400; font-style: normal; font-display: swap; }
@font-face { font-family: 'Bodoni'; src: url('fonts/bodoni-moda-latin-400-italic.woff2') format('woff2'); font-weight: 400; font-style: italic; font-display: swap; }
@font-face { font-family: 'Bodoni'; src: url('fonts/bodoni-moda-latin-500-normal.woff2') format('woff2'); font-weight: 500; font-style: normal; font-display: swap; }
@font-face { font-family: 'Bodoni'; src: url('fonts/bodoni-moda-latin-500-italic.woff2') format('woff2'); font-weight: 500; font-style: italic; font-display: swap; }
@font-face { font-family: 'Jost'; src: url('fonts/jost-latin-300-normal.woff2') format('woff2'); font-weight: 300; font-display: swap; }
@font-face { font-family: 'Jost'; src: url('fonts/jost-latin-400-normal.woff2') format('woff2'); font-weight: 400; font-display: swap; }
@font-face { font-family: 'Jost'; src: url('fonts/jost-latin-500-normal.woff2') format('woff2'); font-weight: 500; font-display: swap; }

:root {
  --paper: #F6F1E8;
  --paper-2: #EFE7DA;
  --card: #FBF8F2;
  --ink: #1C1814;
  --ink-2: #4E463E;
  --mute: #8C8176;
  --line: #E0D5C4;
  --line-2: #CFC1AC;
  --gold: #A07E46;
  --gold-2: #C8AC77;
  --gold-3: #E9DCC2;
  --seal: #6B1E28;
  --seal-2: #8E2C38;
  --ok: #4F6B45;
  --serif: 'Bodoni', 'Didot', 'Bodoni 72', Georgia, serif;
  --sans: 'Jost', -apple-system, 'Helvetica Neue', Arial, sans-serif;
  --ease: cubic-bezier(.2, .7, .15, 1);
  --nav-h: 64px;
  --sat: env(safe-area-inset-top, 0px);
  --sab: env(safe-area-inset-bottom, 0px);
  color-scheme: light;
}

* { box-sizing: border-box; -webkit-tap-highlight-color: transparent; }
html, body { margin: 0; padding: 0; background: var(--paper); color: var(--ink); }
body {
  font-family: var(--sans); font-weight: 300; font-size: 15px; line-height: 1.55;
  -webkit-font-smoothing: antialiased; text-rendering: optimizeLegibility;
  overscroll-behavior-y: none; min-height: 100vh; min-height: 100dvh;
}
body::before { /* paper grain */
  content: ''; position: fixed; inset: 0; pointer-events: none; z-index: 0; opacity: .5;
  background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='160' height='160'><filter id='n'><feTurbulence type='fractalNoise' baseFrequency='.9' numOctaves='2' stitchTiles='stitch'/><feColorMatrix values='0 0 0 0 .45  0 0 0 0 .38  0 0 0 0 .3  0 0 0 .07 0'/></filter><rect width='100%' height='100%' filter='url(%23n)'/></svg>");
}
button, input, select, textarea { font: inherit; color: inherit; }
button { cursor: pointer; background: none; border: 0; padding: 0; }
img { display: block; max-width: 100%; }
::selection { background: var(--gold-3); }

/* ---------- type ---------- */
.eyebrow { font-family: var(--sans); font-weight: 500; font-size: 10.5px; letter-spacing: .24em; text-transform: uppercase; color: var(--mute); }
.eyebrow.gold { color: var(--gold); }
.display { font-family: var(--serif); font-weight: 400; font-size: 40px; line-height: 1.04; letter-spacing: -.01em; margin: 0; }
.display em, .h1 em, .h2 em { font-style: italic; }
.h1 { font-family: var(--serif); font-weight: 400; font-size: 32px; line-height: 1.08; margin: 0; letter-spacing: -.005em; }
.h2 { font-family: var(--serif); font-weight: 400; font-size: 24px; line-height: 1.15; margin: 0; }
.h3 { font-family: var(--serif); font-weight: 400; font-size: 19px; line-height: 1.2; margin: 0; }
.lede { font-family: var(--serif); font-style: italic; font-size: 16px; color: var(--ink-2); line-height: 1.45; margin: 8px 0 0; }
.small { font-size: 13px; color: var(--mute); }
.serif { font-family: var(--serif); }
.italic { font-style: italic; }
.center { text-align: center; }
.gold-rule { height: 1px; background: linear-gradient(90deg, transparent, var(--gold-2), transparent); border: 0; margin: 22px 0; }
.rule { height: 1px; background: var(--line); border: 0; margin: 20px 0; }
.num { font-family: var(--serif); font-style: italic; color: var(--gold); }

/* ---------- layout ---------- */
#app { position: relative; z-index: 1; min-height: 100vh; min-height: 100dvh; }
.view {
  padding: calc(var(--sat) + 22px) 20px calc(var(--nav-h) + var(--sab) + 32px);
  max-width: 560px; margin: 0 auto;
  animation: viewIn .55s var(--ease) both;
}
.view.no-nav { padding-bottom: calc(var(--sab) + 40px); }
@keyframes viewIn { from { opacity: 0; transform: translateY(10px); } to { opacity: 1; transform: none; } }
.stagger > * { animation: viewIn .6s var(--ease) both; animation-delay: calc(var(--i, 0) * 70ms); }
.head { margin-bottom: 22px; }
.head .eyebrow { margin-bottom: 10px; display: block; }
.row { display: flex; align-items: center; gap: 12px; }
.row.between { justify-content: space-between; }
.stack > * + * { margin-top: 14px; }
.grid2 { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.grid3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; }
.spacer { height: 18px; }
.hide { display: none !important; }

/* ---------- top bar (inner screens) ---------- */
.topbar { display: flex; align-items: center; justify-content: space-between; margin-bottom: 18px; min-height: 36px; }
.back { display: inline-flex; align-items: center; gap: 8px; font-size: 11px; letter-spacing: .22em; text-transform: uppercase; color: var(--ink-2); padding: 8px 0; }
.back svg { width: 16px; height: 16px; }
.mono { width: 34px; height: 34px; border-radius: 50%; border: 1px solid var(--gold-2); display: grid; place-items: center; font-family: var(--serif); font-style: italic; color: var(--gold); font-size: 17px; position: relative; }
.mono::after { content: ''; position: absolute; inset: 3px; border-radius: 50%; border: 1px solid var(--gold-3); }

/* ---------- buttons ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 10px;
  height: 52px; padding: 0 22px; width: 100%;
  background: var(--ink); color: var(--paper);
  font-family: var(--sans); font-weight: 500; font-size: 11.5px; letter-spacing: .22em; text-transform: uppercase;
  transition: transform .15s ease, background .3s ease, opacity .3s;
}
.btn:active { transform: scale(.985); }
.btn[disabled] { opacity: .35; pointer-events: none; }
.btn.ghost { background: transparent; color: var(--ink); border: 1px solid var(--ink); }
.btn.gold { background: transparent; color: var(--gold); border: 1px solid var(--gold-2); }
.btn.seal { background: var(--seal); color: #F6E9D8; }
.btn.sm { height: 40px; font-size: 10.5px; padding: 0 16px; width: auto; }
.btn.link { background: none; color: var(--ink-2); height: auto; padding: 10px 0; width: auto; border-bottom: 1px solid var(--line-2); border-radius: 0; letter-spacing: .2em; }
.btn svg { width: 16px; height: 16px; }
.btns { display: grid; gap: 10px; }

/* ---------- chips ---------- */
.chips { display: flex; flex-wrap: wrap; gap: 8px; }
.chips.scroll { flex-wrap: nowrap; overflow-x: auto; margin: 0 -20px; padding: 2px 20px 6px; scrollbar-width: none; }
.chips.scroll::-webkit-scrollbar { display: none; }
.chip {
  flex: none; display: inline-flex; align-items: center; gap: 7px;
  height: 34px; padding: 0 14px; border: 1px solid var(--line-2); border-radius: 999px;
  font-size: 11px; letter-spacing: .14em; text-transform: uppercase; font-weight: 400; color: var(--ink-2);
  background: rgba(255,255,255,.35); transition: all .25s var(--ease); white-space: nowrap;
}
.chip.on { background: var(--ink); border-color: var(--ink); color: var(--paper); }
.chip .dot { width: 10px; height: 10px; border-radius: 50%; border: 1px solid rgba(0,0,0,.12); }
.chip.lg { height: 44px; padding: 0 18px; font-size: 11.5px; }

/* ---------- option tiles ---------- */
.opt-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.opt {
  border: 1px solid var(--line); background: var(--card); padding: 16px 14px; text-align: left; position: relative;
  transition: border-color .25s, box-shadow .25s, transform .15s; min-height: 76px;
}
.opt:active { transform: scale(.985); }
.opt .t { font-family: var(--serif); font-size: 17px; display: block; }
.opt .s { font-size: 12px; color: var(--mute); display: block; margin-top: 3px; line-height: 1.35; }
.opt.on { border-color: var(--ink); box-shadow: inset 0 0 0 1px var(--ink); }
.opt.on::after { content: '✦'; position: absolute; top: 10px; right: 12px; color: var(--gold); font-size: 12px; }
.opt.wide { grid-column: 1 / -1; }

/* ---------- cards ---------- */
.card { background: var(--card); border: 1px solid var(--line); padding: 20px; position: relative; }
.card.framed { outline: 1px solid var(--line); outline-offset: 4px; margin: 5px; }
.card.gold { border-color: var(--gold-2); }
.card + .card { margin-top: 14px; }
.card .eyebrow { display: block; margin-bottom: 8px; }

/* ---------- bottom nav ---------- */
.nav {
  position: fixed; left: 0; right: 0; bottom: 0; z-index: 30;
  padding: 6px 6px calc(var(--sab) + 6px);
  background: rgba(246, 241, 232, .92); backdrop-filter: blur(18px) saturate(1.2); -webkit-backdrop-filter: blur(18px) saturate(1.2);
  border-top: 1px solid var(--line);
  display: grid; grid-template-columns: repeat(5, 1fr);
}
.nav button { display: flex; flex-direction: column; align-items: center; gap: 5px; padding: 8px 0 4px; color: var(--mute); position: relative; }
.nav svg { width: 22px; height: 22px; stroke: currentColor; fill: none; stroke-width: 1.15; }
.nav span { font-size: 9px; letter-spacing: .2em; text-transform: uppercase; font-weight: 500; }
.nav button.on { color: var(--ink); }
.nav button.on::before { content: ''; position: absolute; top: -7px; width: 18px; height: 1px; background: var(--gold); }

/* ---------- home ---------- */
.home-hello { margin: 6px 0 26px; }
.home-hello .display { font-size: 46px; }
.home-hello .name { font-style: italic; color: var(--ink); display: block; }
.brandline { display: flex; align-items: center; justify-content: space-between; margin-bottom: 26px; }
.wordmark { font-family: var(--serif); font-size: 13px; letter-spacing: .42em; text-transform: uppercase; }
.wordmark i { font-style: italic; letter-spacing: .08em; text-transform: none; font-size: 16px; color: var(--gold); margin-left: 4px; }
.hero-colour { display: grid; grid-template-columns: 112px 1fr; gap: 18px; align-items: stretch; }
.fabric {
  position: relative; overflow: hidden; background: var(--c, #ccc);
  box-shadow: inset 0 0 0 1px rgba(0,0,0,.05);
}
.fabric::before { /* twill weave */
  content: ''; position: absolute; inset: 0; opacity: .22; mix-blend-mode: soft-light;
  background-image: repeating-linear-gradient(135deg, rgba(255,255,255,.55) 0 1px, transparent 1px 4px), repeating-linear-gradient(45deg, rgba(0,0,0,.25) 0 1px, transparent 1px 5px);
}
.fabric::after { /* sheen */
  content: ''; position: absolute; inset: 0;
  background: linear-gradient(115deg, rgba(255,255,255,0) 30%, rgba(255,255,255,.22) 48%, rgba(255,255,255,0) 62%), linear-gradient(180deg, rgba(255,255,255,.08), rgba(0,0,0,.10));
}
.fabric.silk::after { background: linear-gradient(110deg, rgba(255,255,255,0) 20%, rgba(255,255,255,.35) 42%, rgba(255,255,255,0) 58%, rgba(255,255,255,.12) 72%, rgba(255,255,255,0) 85%), linear-gradient(180deg, rgba(255,255,255,.06), rgba(0,0,0,.12)); }
.hero-colour .fabric { min-height: 148px; }
.qa { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.qa button { background: var(--card); border: 1px solid var(--line); padding: 18px 14px 16px; text-align: left; min-height: 116px; display: flex; flex-direction: column; justify-content: space-between; transition: transform .15s, border-color .25s; }
.qa button:active { transform: scale(.98); border-color: var(--ink); }
.qa svg { width: 26px; height: 26px; stroke: var(--gold); fill: none; stroke-width: 1.1; }
.qa .t { font-family: var(--serif); font-size: 18px; line-height: 1.15; display: block; }
.qa .s { font-size: 11.5px; color: var(--mute); display: block; margin-top: 2px; }
.banner { border: 1px solid var(--gold-2); padding: 22px 20px; background: linear-gradient(180deg, #FBF6EC, #F6EEDD); position: relative; overflow: hidden; }
.banner.bday { text-align: center; background: radial-gradient(120% 90% at 50% 0%, #FFF8EA 0%, #F4E9D3 70%); }
.banner .sparkle { position: absolute; color: var(--gold-2); font-size: 12px; animation: twinkle 3s ease-in-out infinite; }
@keyframes twinkle { 0%,100% { opacity: .2; transform: scale(.8);} 50% { opacity: 1; transform: scale(1.15);} }
.navratri { display: grid; grid-template-columns: 64px 1fr; gap: 16px; align-items: center; }
.navratri .fabric { height: 64px; border-radius: 50%; }
.howto ol { margin: 6px 0 0; padding: 0; list-style: none; counter-reset: h; }
.howto li { counter-increment: h; display: grid; grid-template-columns: 30px 1fr; padding: 10px 0; border-top: 1px solid var(--line); font-size: 14px; }
.howto li:first-child { border-top: 0; }
.howto li::before { content: counter(h, decimal-leading-zero); font-family: var(--serif); font-style: italic; color: var(--gold); }
.tip { font-family: var(--serif); font-size: 19px; line-height: 1.35; font-style: italic; margin: 6px 0 0; }

/* ---------- occasion list ---------- */
.search { position: relative; margin-bottom: 14px; }
.search input { width: 100%; height: 48px; border: 0; border-bottom: 1px solid var(--line-2); background: transparent; padding: 0 0 0 30px; font-size: 16px; font-family: var(--serif); font-style: italic; outline: none; border-radius: 0; }
.search input::placeholder { color: var(--mute); }
.search svg { position: absolute; left: 0; top: 15px; width: 18px; height: 18px; stroke: var(--mute); fill: none; stroke-width: 1.3; }
.occ-group { margin-top: 22px; }
.occ-group > .eyebrow { display: flex; align-items: center; gap: 10px; margin-bottom: 4px; }
.occ-group > .eyebrow::after { content: ''; flex: 1; height: 1px; background: var(--line); }
.occ { display: grid; grid-template-columns: 26px 1fr 14px; gap: 10px; align-items: center; width: 100%; text-align: left; padding: 14px 0; border-bottom: 1px solid var(--line); transition: padding .25s var(--ease); }
.occ:active { padding-left: 6px; }
.occ .g { font-family: var(--serif); color: var(--gold); font-size: 15px; text-align: center; }
.occ .n { font-family: var(--serif); font-size: 18px; display: block; line-height: 1.2; }
.occ .d { font-size: 12px; color: var(--mute); display: block; margin-top: 2px; line-height: 1.35; }
.occ svg { width: 14px; height: 14px; stroke: var(--line-2); fill: none; stroke-width: 1.5; }

/* ---------- look card ---------- */
.look { background: var(--card); border: 1px solid var(--line); margin-bottom: 18px; position: relative; overflow: hidden; }
.look-head { padding: 20px 20px 14px; display: flex; justify-content: space-between; align-items: flex-start; gap: 10px; }
.look-head .h2 { font-style: italic; margin-top: 6px; }
.look-body { display: grid; grid-template-columns: 92px 1fr; gap: 16px; padding: 0 20px; }
.swatchbook { display: flex; flex-direction: column; gap: 3px; min-height: 180px; }
.swatchbook .fabric { flex: var(--w, 1); min-height: 34px; }
.swatchbook .fabric.photo { background-size: cover; background-position: center; }
.pieces { list-style: none; margin: 0; padding: 0; }
.pieces li { padding: 9px 0; border-bottom: 1px solid var(--line); display: grid; grid-template-columns: 12px 1fr; gap: 10px; align-items: start; }
.pieces li:last-child { border-bottom: 0; }
.pieces .dot { width: 12px; height: 12px; border-radius: 50%; margin-top: 5px; box-shadow: inset 0 0 0 1px rgba(0,0,0,.12); }
.pieces .nm { font-family: var(--serif); font-size: 16px; line-height: 1.25; display: block; }
.pieces .cl { font-size: 10.5px; letter-spacing: .16em; text-transform: uppercase; color: var(--mute); display: block; margin-top: 2px; }
.own { display: inline-block; font-size: 9px; letter-spacing: .18em; text-transform: uppercase; color: var(--gold); border: 1px solid var(--gold-2); padding: 1px 6px; margin-left: 6px; vertical-align: 2px; font-family: var(--sans); }
.finish { margin: 14px 20px 0; padding: 14px 0 0; border-top: 1px solid var(--line); display: grid; grid-template-columns: 1fr 1fr; gap: 12px 16px; }
.finish div .eyebrow { display: block; font-size: 9.5px; margin-bottom: 3px; }
.finish div span:not(.eyebrow) { font-size: 13.5px; line-height: 1.4; display: block; }
.finish .full { grid-column: 1 / -1; }
.reason { margin: 16px 20px 0; padding: 14px 16px; background: var(--paper); border-left: 1px solid var(--gold-2); font-family: var(--serif); font-style: italic; font-size: 15.5px; line-height: 1.45; color: var(--ink-2); }
.reason p { margin: 0; }
.reason p + p { margin-top: 6px; }
.repeat { margin: 12px 20px 0; font-size: 12px; color: var(--seal); }
.look-actions { display: grid; grid-template-columns: 1fr 52px; gap: 8px; padding: 16px 20px 20px; }
.heart { height: 52px; border: 1px solid var(--line-2); display: grid; place-items: center; }
.heart svg { width: 20px; height: 20px; stroke: var(--ink); fill: none; stroke-width: 1.2; transition: all .3s; }
.heart.on svg { fill: var(--seal); stroke: var(--seal); transform: scale(1.08); }
.look.compact .look-body { grid-template-columns: 64px 1fr; }
.look.compact .swatchbook { min-height: 120px; }

/* ---------- loading ---------- */
.loading { position: fixed; inset: 0; z-index: 80; background: rgba(246,241,232,.94); backdrop-filter: blur(6px); -webkit-backdrop-filter: blur(6px); display: grid; place-items: center; animation: fade .3s ease both; }
.loading .inner { text-align: center; }
.loading .mono { width: 64px; height: 64px; font-size: 30px; margin: 0 auto 22px; animation: breathe 1.8s ease-in-out infinite; }
.loading p { font-family: var(--serif); font-style: italic; font-size: 18px; margin: 0; }
.loading .bar { width: 120px; height: 1px; background: var(--line); margin: 18px auto 0; position: relative; overflow: hidden; }
.loading .bar::after { content: ''; position: absolute; inset: 0; width: 40%; background: var(--gold); animation: slide 1.1s var(--ease) infinite; }
@keyframes breathe { 0%,100% { transform: scale(1); opacity: .8; } 50% { transform: scale(1.06); opacity: 1; } }
@keyframes slide { from { transform: translateX(-100%); } to { transform: translateX(260%); } }
@keyframes fade { from { opacity: 0; } to { opacity: 1; } }

/* ---------- sheet ---------- */
.scrim { position: fixed; inset: 0; z-index: 60; background: rgba(28,24,20,.32); animation: fade .3s ease both; }
.sheet {
  position: fixed; left: 0; right: 0; bottom: 0; z-index: 61; max-height: 90vh; max-height: 90dvh;
  background: var(--paper); border-top: 1px solid var(--line); display: flex; flex-direction: column;
  animation: sheetUp .45s var(--ease) both; max-width: 640px; margin: 0 auto;
  box-shadow: 0 -20px 60px rgba(28,24,20,.12);
}
.sheet.out { animation: sheetDown .3s ease both; }
@keyframes sheetUp { from { transform: translateY(100%); } to { transform: none; } }
@keyframes sheetDown { to { transform: translateY(100%); } }
.sheet .grab { width: 38px; height: 3px; background: var(--line-2); border-radius: 3px; margin: 10px auto 0; flex: none; }
.sheet .sh-head { padding: 14px 20px 10px; display: flex; justify-content: space-between; align-items: center; flex: none; }
.sheet .sh-body { padding: 4px 20px calc(var(--sab) + 26px); overflow-y: auto; -webkit-overflow-scrolling: touch; }
.x { width: 36px; height: 36px; display: grid; place-items: center; border: 1px solid var(--line); border-radius: 50%; }
.x svg { width: 14px; height: 14px; stroke: var(--ink); stroke-width: 1.5; }

/* ---------- toast ---------- */
.toast { position: fixed; left: 50%; bottom: calc(var(--nav-h) + var(--sab) + 18px); transform: translateX(-50%); z-index: 90; background: var(--ink); color: var(--paper); padding: 13px 20px; font-size: 12px; letter-spacing: .12em; text-transform: uppercase; white-space: nowrap; animation: toast 2.6s var(--ease) both; }
@keyframes toast { 0% { opacity: 0; transform: translate(-50%, 10px); } 12%, 82% { opacity: 1; transform: translate(-50%, 0); } 100% { opacity: 0; transform: translate(-50%, 6px); } }

/* ---------- forms ---------- */
.field { display: block; margin-top: 18px; }
.field > .eyebrow { display: block; margin-bottom: 10px; }
.input { width: 100%; height: 48px; border: 0; border-bottom: 1px solid var(--line-2); background: transparent; font-family: var(--serif); font-size: 19px; outline: none; border-radius: 0; padding: 0; }
.input:focus { border-color: var(--ink); }
.stepper { display: inline-flex; align-items: center; border: 1px solid var(--line-2); }
.stepper button { width: 46px; height: 46px; font-size: 20px; font-family: var(--serif); }
.stepper span { min-width: 54px; text-align: center; font-family: var(--serif); font-size: 22px; }
.toggle { display: grid; grid-template-columns: 1fr 1fr; border: 1px solid var(--ink); }
.toggle button { height: 46px; font-size: 11px; letter-spacing: .18em; text-transform: uppercase; font-weight: 500; transition: all .25s; }
.toggle button.on { background: var(--ink); color: var(--paper); }

/* ---------- photo / fit check ---------- */
.photo-frame { position: relative; background: var(--paper-2); border: 1px solid var(--line); padding: 8px; }
.photo-frame canvas, .photo-frame img { width: 100%; height: auto; display: block; touch-action: manipulation; }
.photo-frame canvas { width: auto; max-width: 100%; max-height: 50vh; margin: 0 auto; }
.photo-frame .hint { position: absolute; left: 50%; bottom: 18px; transform: translateX(-50%); background: rgba(28,24,20,.78); color: var(--paper); font-size: 11px; letter-spacing: .14em; text-transform: uppercase; padding: 9px 14px; white-space: nowrap; pointer-events: none; animation: fade .3s both; }
.photo-frame.picking { outline: 2px solid var(--gold); outline-offset: -2px; }
.loupe { position: absolute; width: 46px; height: 46px; border-radius: 50%; border: 2px solid #fff; box-shadow: 0 0 0 1px rgba(0,0,0,.25), 0 6px 18px rgba(0,0,0,.25); transform: translate(-50%, -50%); pointer-events: none; animation: pop .35s var(--ease) both; }
@keyframes pop { from { transform: translate(-50%,-50%) scale(.4); opacity: 0; } to { transform: translate(-50%,-50%) scale(1); opacity: 1; } }
.drop { border: 1px dashed var(--line-2); padding: 34px 20px; text-align: center; background: rgba(255,255,255,.3); }
.drop svg { width: 40px; height: 40px; stroke: var(--gold); fill: none; stroke-width: 1; margin: 0 auto 14px; display: block; }
.piece-row { display: grid; grid-template-columns: 34px 1fr 32px; gap: 12px; align-items: center; padding: 12px 0; border-bottom: 1px solid var(--line); }
.piece-row .sw { width: 34px; height: 34px; border-radius: 50%; box-shadow: inset 0 0 0 1px rgba(0,0,0,.12); position: relative; }
.piece-row .sw.empty { background: repeating-linear-gradient(45deg, var(--line) 0 2px, transparent 2px 6px); box-shadow: inset 0 0 0 1px var(--line-2); }
.piece-row .nm { font-family: var(--serif); font-size: 17px; display: block; }
.piece-row .cl { font-size: 10.5px; letter-spacing: .16em; text-transform: uppercase; color: var(--mute); }
.palette-chips { display: flex; gap: 8px; flex-wrap: wrap; margin-top: 12px; }
.pchip { width: 38px; height: 38px; border-radius: 50%; box-shadow: inset 0 0 0 1px rgba(0,0,0,.12); border: 2px solid transparent; outline: 1px solid transparent; transition: transform .15s; }
.pchip:active { transform: scale(.9); }
.verdict { text-align: center; padding: 8px 0 4px; }
.verdict .display { font-style: italic; font-size: 44px; }
.score { display: inline-flex; align-items: baseline; gap: 4px; font-family: var(--serif); margin-top: 10px; }
.score b { font-weight: 400; font-size: 30px; }
.score i { color: var(--mute); font-size: 15px; }
.dims { margin-top: 6px; }
.dim { display: grid; grid-template-columns: 96px 1fr 30px; gap: 12px; align-items: center; padding: 8px 0; }
.dim .eyebrow { font-size: 9.5px; }
.dim .track { height: 2px; background: var(--line); position: relative; }
.dim .track i { position: absolute; left: 0; top: 0; bottom: 0; background: var(--ink); width: 0; transition: width 1.1s var(--ease); }
.dim .v { font-family: var(--serif); font-size: 14px; text-align: right; }
.compliment { font-family: var(--serif); font-size: 21px; line-height: 1.35; margin: 0; }
.tweak { display: grid; grid-template-columns: 22px 1fr; gap: 8px; padding: 12px 0; border-top: 1px solid var(--line); font-size: 15px; line-height: 1.45; }
.tweak .num { font-size: 15px; }

/* ---------- wardrobe ---------- */
.w-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; }
.w-item { position: relative; aspect-ratio: 3 / 4; background: var(--paper-2); overflow: hidden; border: 1px solid var(--line); text-align: left; }
.w-item img { width: 100%; height: 100%; object-fit: cover; }
.w-item .fabric { position: absolute; inset: 0; }
.w-item .cap { position: absolute; left: 0; right: 0; bottom: 0; padding: 22px 8px 7px; background: linear-gradient(transparent, rgba(28,24,20,.6)); color: #fff; font-size: 11px; line-height: 1.25; }
.w-item .cap b { font-weight: 400; display: block; font-family: var(--serif); font-size: 13px; }
.w-item .swdot { position: absolute; top: 7px; right: 7px; width: 14px; height: 14px; border-radius: 50%; border: 1.5px solid #fff; box-shadow: 0 1px 3px rgba(0,0,0,.2); }
.w-add { aspect-ratio: 3 / 4; border: 1px dashed var(--line-2); display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 8px; color: var(--gold); background: rgba(255,255,255,.3); }
.w-add svg { width: 26px; height: 26px; stroke: currentColor; stroke-width: 1.1; fill: none; }
.w-add span { font-size: 10px; letter-spacing: .2em; text-transform: uppercase; }
.empty { text-align: center; padding: 34px 16px; border: 1px solid var(--line); background: var(--card); }
.empty .h3 { font-style: italic; }
.empty p { color: var(--mute); font-size: 14px; margin: 8px auto 18px; max-width: 300px; }
.cat-list button { display: flex; justify-content: space-between; width: 100%; padding: 13px 0; border-bottom: 1px solid var(--line); font-family: var(--serif); font-size: 17px; text-align: left; }
.cat-list button span { font-family: var(--sans); color: var(--line-2); }

/* ---------- studio ---------- */
.studio-list button { display: grid; grid-template-columns: 44px 1fr 14px; gap: 6px; align-items: center; width: 100%; text-align: left; padding: 18px 0; border-bottom: 1px solid var(--line); }
.studio-list .num { font-size: 15px; }
.studio-list .t { font-family: var(--serif); font-size: 21px; display: block; line-height: 1.15; }
.studio-list .s { font-size: 12.5px; color: var(--mute); display: block; margin-top: 3px; }
.studio-list svg { width: 14px; height: 14px; stroke: var(--line-2); fill: none; stroke-width: 1.5; }
.palette-hero { text-align: center; padding: 6px 0 10px; }
.palette-hero .display { font-style: italic; }
.power { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; margin-top: 18px; }
.power .fabric { aspect-ratio: 3 / 4; }
.power .lbl { font-size: 10.5px; letter-spacing: .16em; text-transform: uppercase; margin-top: 7px; color: var(--ink-2); text-align: center; }
.sw-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 10px 8px; }
.sw-grid button { text-align: center; }
.sw-grid .fabric { aspect-ratio: 1; border-radius: 50%; }
.sw-grid span { display: block; font-size: 10.5px; margin-top: 6px; color: var(--ink-2); line-height: 1.2; }
.pair { display: grid; grid-template-columns: 72px 1fr; gap: 14px; align-items: center; padding: 12px 0; border-bottom: 1px solid var(--line); }
.pair .duo { display: flex; height: 54px; }
.pair .duo .fabric { flex: 1; }
.note-body ul { padding: 0; margin: 0; list-style: none; }
.note-body li { padding: 13px 0 13px 22px; border-bottom: 1px solid var(--line); position: relative; font-size: 15px; }
.note-body li::before { content: '✦'; position: absolute; left: 0; top: 14px; color: var(--gold); font-size: 10px; }
.fest { display: grid; grid-template-columns: 58px 1fr auto; gap: 12px; align-items: center; padding: 14px 0; border-bottom: 1px solid var(--line); }
.fest .date { text-align: center; border-right: 1px solid var(--line); padding-right: 10px; }
.fest .date b { font-family: var(--serif); font-weight: 400; font-size: 24px; display: block; line-height: 1; }
.fest .date span { font-size: 10px; letter-spacing: .18em; text-transform: uppercase; color: var(--mute); }
.fest .n { font-family: var(--serif); font-size: 17px; display: block; }
.fest .d { font-size: 12px; color: var(--mute); display: block; }
.diary-e { display: grid; grid-template-columns: 64px 1fr; gap: 14px; padding: 14px 0; border-bottom: 1px solid var(--line); align-items: center; }
.diary-e .th { width: 64px; height: 80px; background: var(--paper-2); overflow: hidden; display: flex; flex-direction: column; }
.diary-e .th img { width: 100%; height: 100%; object-fit: cover; }
.diary-e .th .fabric { flex: 1; }
.check { display: grid; grid-template-columns: 24px 1fr auto; gap: 10px; align-items: center; padding: 11px 0; border-bottom: 1px solid var(--line); width: 100%; text-align: left; }
.check .bx { width: 18px; height: 18px; border: 1px solid var(--line-2); display: grid; place-items: center; font-size: 11px; color: var(--paper); }
.check.on .bx { background: var(--ink); border-color: var(--ink); }
.check.on .tx { text-decoration: line-through; color: var(--mute); }
.day { border: 1px solid var(--line); background: var(--card); margin-bottom: 10px; }
.day summary { list-style: none; padding: 16px 18px; display: flex; justify-content: space-between; align-items: center; cursor: pointer; }
.day summary::-webkit-details-marker { display: none; }
.day[open] summary { border-bottom: 1px solid var(--line); }
.day .inner { padding: 6px 18px 16px; }

/* ---------- unboxing ---------- */
.unbox { position: fixed; inset: 0; z-index: 100; background: radial-gradient(140% 90% at 50% 10%, #FBF7EF 0%, #F2E9DA 60%, #EADFCB 100%); display: flex; flex-direction: column; align-items: center; justify-content: center; padding: calc(var(--sat) + 30px) 28px calc(var(--sab) + 30px); text-align: center; overflow: hidden; }
.unbox .eyebrow { color: var(--gold); }
.unbox .for { font-family: var(--serif); font-style: italic; font-size: 30px; margin: 10px 0 40px; }
.env { position: relative; width: 290px; height: 196px; perspective: 900px; }
.env .back { position: absolute; inset: 0; background: #E8DCC6; box-shadow: 0 30px 60px -20px rgba(80,55,20,.35), inset 0 0 0 1px rgba(160,126,70,.25); }
.env .letter { position: absolute; left: 14px; right: 14px; top: 12px; height: 170px; background: #FFFDF8; box-shadow: 0 2px 8px rgba(0,0,0,.08); transition: transform 1.1s var(--ease) .55s; display: flex; align-items: center; justify-content: center; }
.env .letter i { font-family: var(--serif); color: var(--gold); font-size: 22px; }
.env .front { position: absolute; inset: 0; background: linear-gradient(160deg, #F1E6D2, #E6D7BD); clip-path: polygon(0 0, 50% 52%, 100% 0, 100% 100%, 0 100%); box-shadow: inset 0 0 0 1px rgba(160,126,70,.2); z-index: 2; }
.env .front::after { content: ''; position: absolute; inset: 0; background: linear-gradient(20deg, transparent 49.6%, rgba(160,126,70,.25) 50%, transparent 50.4%), linear-gradient(-20deg, transparent 49.6%, rgba(160,126,70,.25) 50%, transparent 50.4%); }
.env .flap { position: absolute; left: 0; right: 0; top: 0; height: 112px; background: linear-gradient(180deg, #EBDDC4, #E2D1B3); clip-path: polygon(0 0, 100% 0, 50% 100%); transform-origin: top; transition: transform .8s var(--ease), z-index 0s .4s; z-index: 3; box-shadow: inset 0 0 0 1px rgba(160,126,70,.2); }
.env .seal { position: absolute; left: 50%; top: 96px; width: 62px; height: 62px; transform: translate(-50%, -50%); z-index: 4; border-radius: 50%; background: radial-gradient(circle at 35% 30%, #A23A47, var(--seal) 55%, #4A121A); box-shadow: 0 4px 10px rgba(70,15,20,.4), inset 0 0 0 4px rgba(0,0,0,.08); display: grid; place-items: center; transition: transform .5s var(--ease), opacity .5s; animation: sealPulse 2.4s ease-in-out infinite; }
.env .seal::before { content: ''; position: absolute; inset: 7px; border-radius: 50%; border: 1px solid rgba(232,196,140,.55); }
.env .seal b { font-family: var(--serif); font-style: italic; font-weight: 400; color: #E8C48C; font-size: 28px; position: relative; top: -1px; }
@keyframes sealPulse { 0%,100% { transform: translate(-50%,-50%) scale(1);} 50% { transform: translate(-50%,-50%) scale(1.05);} }
.env.open .seal { animation: none; transform: translate(-50%, -50%) scale(1.5); opacity: 0; }
.env.open .flap { transform: rotateX(180deg); z-index: 0; }
.env.open .letter { transform: translateY(-150px); }
.unbox .tap { margin-top: 46px; font-size: 11px; letter-spacing: .26em; text-transform: uppercase; color: var(--ink-2); animation: twinkle 2.4s ease-in-out infinite; }
.letter-view { position: fixed; inset: 0; z-index: 100; background: var(--paper); overflow-y: auto; padding: calc(var(--sat) + 34px) 22px calc(var(--sab) + 34px); }
.paper { max-width: 460px; margin: 0 auto; background: #FFFDF8; border: 1px solid var(--line); outline: 1px solid var(--gold-3); outline-offset: -10px; padding: 46px 30px 40px; position: relative; box-shadow: 0 30px 70px -40px rgba(80,55,20,.4); }
.paper .crest { text-align: center; margin-bottom: 26px; }
.paper .crest .mono { margin: 0 auto 12px; width: 46px; height: 46px; font-size: 22px; }
.paper h1 { font-family: var(--serif); font-weight: 400; font-size: 34px; line-height: 1.1; margin: 0 0 24px; text-align: center; }
.paper h1 em { color: var(--gold); }
.paper p { font-family: var(--serif); font-size: 18px; line-height: 1.6; margin: 0 0 18px; color: var(--ink-2); }
.paper .sig { font-style: italic; font-size: 22px; color: var(--ink); text-align: right; margin-top: 26px; }
.paper .ln { opacity: 0; animation: viewIn .9s var(--ease) both; }

/* ---------- onboarding ---------- */
.ob-progress { display: flex; gap: 4px; margin-bottom: 26px; }
.ob-progress i { flex: 1; height: 1px; background: var(--line); }
.ob-progress i.on { background: var(--ink); }
.skin-opts { display: grid; grid-template-columns: repeat(5, 1fr); gap: 8px; }
.skin-opts button { text-align: center; }
.skin-opts .c { width: 100%; aspect-ratio: 1; border-radius: 50%; border: 1px solid rgba(0,0,0,.06); transition: transform .2s, box-shadow .2s; }
.skin-opts button.on .c { box-shadow: 0 0 0 2px var(--paper), 0 0 0 3px var(--ink); transform: scale(1.05); }
.skin-opts span { display: block; font-size: 10px; letter-spacing: .1em; text-transform: uppercase; color: var(--ink-2); margin-top: 7px; }
.selfie-circle { width: 200px; height: 200px; border-radius: 50%; margin: 10px auto 18px; border: 1px solid var(--gold-2); overflow: hidden; background: var(--paper-2); display: grid; place-items: center; position: relative; }
.selfie-circle img { width: 100%; height: 100%; object-fit: cover; }
.selfie-circle svg { width: 60px; height: 60px; stroke: var(--gold-2); fill: none; stroke-width: 1; }
.qblock { margin-top: 26px; }
.qblock .q { font-family: var(--serif); font-size: 19px; margin-bottom: 12px; display: block; }

/* install page */
.install { min-height: 100vh; min-height: 100dvh; display: flex; flex-direction: column; justify-content: center; padding: calc(var(--sat) + 30px) 26px calc(var(--sab) + 30px); max-width: 480px; margin: 0 auto; }
.install ol { list-style: none; padding: 0; margin: 26px 0 30px; counter-reset: s; }
.install li { counter-increment: s; display: grid; grid-template-columns: 34px 1fr; padding: 14px 0; border-top: 1px solid var(--line); font-size: 15.5px; align-items: center; }
.install li::before { content: counter(s, decimal-leading-zero); font-family: var(--serif); font-style: italic; color: var(--gold); }
.install li svg { width: 18px; height: 18px; vertical-align: -3px; stroke: #2F7BF6; fill: none; stroke-width: 1.6; margin: 0 2px; }

@media (min-width: 600px) {
  .view { padding-left: 28px; padding-right: 28px; }
  .chips.scroll { margin: 0 -28px; padding-left: 28px; padding-right: 28px; }
}
@media (prefers-reduced-motion: reduce) { *, *::before, *::after { animation-duration: .01ms !important; transition-duration: .01ms !important; } }
