/* ── DM Sans from Google Fonts ──────────────────────────────────────────────── */
@import url('https://fonts.googleapis.com/css2?family=DM+Sans:ital,opsz,wght@0,9..40,300;0,9..40,400;0,9..40,500;0,9..40,600;0,9..40,700;1,9..40,300;1,9..40,400&family=DM+Serif+Display:ital@0;1&display=swap');

/* ── Design Tokens ───────────────────────────────────────────────────────────── */
:root {
  /* Palette – deep ink, warm gold, cream, slate */
  --ink:       #0D0C0A;
  --ink-soft:  #1A1916;
  --ink-mid:   #2B2925;
  --gold:      #C9A84C;
  --gold-lt:   #E2C97A;
  --gold-dim:  #8A6B24;
  --cream:     #F5F0E8;
  --cream-dim: #E8E1D4;
  --slate:     #8C8680;
  --slate-lt:  #BAB5AE;
  --white:     #FDFCFA;
  --error:     #C0392B;
  --success:   #2D7A4F;
  --tier1:     #4A7FB5;
  --tier2:     #C9A84C;
  --eco-green: #3A7D44;
  --eco-lt:    #6AAE78;

  /* Type */
  --font-sans:    'DM Sans', system-ui, sans-serif;
  --font-display: 'DM Serif Display', Georgia, serif;

  /* Spacing */
  --sp-1: 0.25rem; --sp-2: 0.5rem;  --sp-3: 0.75rem;
  --sp-4: 1rem;    --sp-6: 1.5rem;  --sp-8: 2rem;
  --sp-10: 2.5rem; --sp-12: 3rem;   --sp-16: 4rem;
  --sp-20: 5rem;   --sp-24: 6rem;

  /* Radius */
  --r-sm: 4px; --r-md: 8px; --r-lg: 16px; --r-xl: 24px; --r-pill: 999px;

  /* Shadow */
  --shadow-sm: 0 1px 3px rgba(0,0,0,.25);
  --shadow-md: 0 4px 16px rgba(0,0,0,.35);
  --shadow-lg: 0 12px 40px rgba(0,0,0,.45);
  --shadow-gold: 0 0 0 2px rgba(201,168,76,.4);

  /* Transition */
  --ease: cubic-bezier(.4,0,.2,1);
  --dur-fast: 150ms; --dur-mid: 250ms; --dur-slow: 400ms;
}

/* ── Reset ───────────────────────────────────────────────────────────────────── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { font-size: 16px; scroll-behavior: smooth; -webkit-tap-highlight-color: transparent; }
body {
  font-family: var(--font-sans);
  background: var(--ink);
  color: var(--cream);
  line-height: 1.6;
  min-height: 100dvh;
  -webkit-font-smoothing: antialiased;
}
img, svg { display: block; max-width: 100%; }
a { color: inherit; text-decoration: none; }
button, input, select, textarea { font-family: inherit; }
ul, ol { list-style: none; }

/* ── Typography ──────────────────────────────────────────────────────────────── */
.t-display { font-family: var(--font-display); font-size: clamp(2rem, 5vw, 3.5rem); line-height: 1.1; letter-spacing: -.01em; }
.t-title   { font-family: var(--font-display); font-size: clamp(1.4rem, 3vw, 2rem); line-height: 1.2; }
.t-heading { font-size: 1.125rem; font-weight: 600; letter-spacing: .01em; }
.t-body    { font-size: 0.9375rem; font-weight: 400; line-height: 1.65; }
.t-small   { font-size: 0.8125rem; color: var(--slate-lt); }
.t-label   { font-size: 0.6875rem; font-weight: 600; letter-spacing: .1em; text-transform: uppercase; color: var(--slate); }
.t-gold    { color: var(--gold); }
.t-cream   { color: var(--cream); }
.t-slate   { color: var(--slate-lt); }

/* ── Layout ──────────────────────────────────────────────────────────────────── */
.container { width: 100%; max-width: 1100px; margin-inline: auto; padding-inline: var(--sp-6); }
.container-sm { max-width: 640px; }
.container-md { max-width: 800px; }

/* ── Gold Divider ────────────────────────────────────────────────────────────── */
.gold-rule { width: 48px; height: 2px; background: var(--gold); border: none; margin-block: var(--sp-4); }
.gold-rule--center { margin-inline: auto; }

/* ── Buttons ─────────────────────────────────────────────────────────────────── */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: var(--sp-2);
  padding: .7rem 1.5rem; border-radius: var(--r-md); border: none;
  font-family: var(--font-sans); font-size: .9375rem; font-weight: 600;
  cursor: pointer; transition: all var(--dur-mid) var(--ease); white-space: nowrap;
  letter-spacing: .01em; -webkit-user-select: none; user-select: none;
}
.btn:active { transform: scale(.97); }
.btn--primary {
  background: var(--gold); color: var(--ink);
}
.btn--primary:hover { background: var(--gold-lt); box-shadow: 0 4px 20px rgba(201,168,76,.35); }
.btn--ghost {
  background: transparent; color: var(--cream); border: 1px solid rgba(255,255,255,.15);
}
.btn--ghost:hover { border-color: var(--gold); color: var(--gold); }
.btn--ink {
  background: var(--ink-mid); color: var(--cream); border: 1px solid rgba(255,255,255,.08);
}
.btn--ink:hover { background: var(--ink-soft); border-color: rgba(255,255,255,.15); }
.btn--danger  { background: var(--error); color: #fff; }
.btn--danger:hover { filter: brightness(1.1); }
.btn--sm { padding: .45rem 1rem; font-size: .8125rem; border-radius: var(--r-sm); }
.btn--full { width: 100%; }
.btn--pill { border-radius: var(--r-pill); }
.btn:disabled { opacity: .45; cursor: not-allowed; transform: none !important; }

/* ── OAuth Buttons ───────────────────────────────────────────────────────────── */
.btn-oauth {
  display: flex; align-items: center; gap: var(--sp-3);
  padding: .85rem 1.5rem; border-radius: var(--r-md);
  font-size: .9375rem; font-weight: 500; cursor: pointer;
  transition: all var(--dur-mid) var(--ease); border: none; width: 100%;
}
.btn-oauth:active { transform: scale(.98); }
.btn-helix {
  background: linear-gradient(135deg, #1a1a2e 0%, #16213e 100%);
  color: #fff; border: 1px solid rgba(148,130,255,.3);
}
.btn-helix:hover { border-color: rgba(148,130,255,.6); box-shadow: 0 4px 20px rgba(148,130,255,.2); }
.btn-google {
  background: #fff; color: #1a1a1a; border: 1px solid #e0e0e0;
}
.btn-google:hover { box-shadow: 0 4px 12px rgba(0,0,0,.15); }
.oauth-icon { width: 22px; height: 22px; flex-shrink: 0; }

/* ── Card ────────────────────────────────────────────────────────────────────── */
.card {
  background: var(--ink-soft); border-radius: var(--r-lg);
  border: 1px solid rgba(255,255,255,.06); padding: var(--sp-6);
}
.card--gold-border { border-color: rgba(201,168,76,.25); }
.card--hover { transition: all var(--dur-mid) var(--ease); cursor: pointer; }
.card--hover:hover { border-color: rgba(201,168,76,.4); transform: translateY(-2px); box-shadow: var(--shadow-md); }

/* ── Form ────────────────────────────────────────────────────────────────────── */
.form-group { display: flex; flex-direction: column; gap: var(--sp-2); }
.form-label { font-size: .8125rem; font-weight: 600; color: var(--slate-lt); letter-spacing: .03em; }
.form-input, .form-select, .form-textarea {
  background: var(--ink-mid); border: 1px solid rgba(255,255,255,.1);
  border-radius: var(--r-md); padding: .7rem 1rem;
  font-family: var(--font-sans); font-size: .9375rem; color: var(--cream);
  transition: border-color var(--dur-fast) var(--ease), box-shadow var(--dur-fast) var(--ease);
  width: 100%;
}
.form-input:focus, .form-select:focus, .form-textarea:focus {
  outline: none; border-color: var(--gold); box-shadow: var(--shadow-gold);
}
.form-input::placeholder { color: var(--slate); }
.form-select { appearance: none; background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'%3E%3Cpath d='M1 1l5 5 5-5' stroke='%238C8680' stroke-width='1.5' fill='none' stroke-linecap='round'/%3E%3C/svg%3E"); background-repeat: no-repeat; background-position: right 1rem center; padding-right: 2.5rem; cursor: pointer; }
.form-select option { background: var(--ink-mid); }
.form-textarea { resize: vertical; min-height: 100px; line-height: 1.6; }
.form-error { color: var(--error); font-size: .8125rem; }
.form-hint  { color: var(--slate); font-size: .8125rem; }

/* ── Checkbox / Radio ────────────────────────────────────────────────────────── */
.check-group { display: flex; align-items: flex-start; gap: var(--sp-3); cursor: pointer; }
.check-group input[type=checkbox], .check-group input[type=radio] {
  appearance: none; width: 18px; height: 18px; flex-shrink: 0;
  border: 2px solid rgba(255,255,255,.2); border-radius: 4px;
  background: var(--ink-mid); cursor: pointer; margin-top: 1px;
  transition: all var(--dur-fast) var(--ease); position: relative;
}
.check-group input[type=radio] { border-radius: 50%; }
.check-group input[type=checkbox]:checked, .check-group input[type=radio]:checked {
  background: var(--gold); border-color: var(--gold);
}
.check-group input[type=checkbox]:checked::after {
  content: ''; position: absolute; top: 2px; left: 5px;
  width: 5px; height: 9px; border: 2px solid var(--ink);
  border-top: none; border-left: none; transform: rotate(45deg);
}
.check-group input[type=radio]:checked::after {
  content: ''; position: absolute; top: 3px; left: 3px;
  width: 8px; height: 8px; background: var(--ink); border-radius: 50%;
}
.check-group label { font-size: .9375rem; color: var(--cream-dim); cursor: pointer; line-height: 1.5; }

/* ── Range / Rating ──────────────────────────────────────────────────────────── */
.rating-group { display: flex; gap: var(--sp-3); align-items: center; }
.rating-btn {
  width: 44px; height: 44px; border-radius: 50%; border: 1px solid rgba(255,255,255,.15);
  background: var(--ink-mid); color: var(--slate-lt); font-size: .9375rem; font-weight: 600;
  cursor: pointer; transition: all var(--dur-fast) var(--ease); display: flex; align-items: center; justify-content: center;
}
.rating-btn.active, .rating-btn:hover { background: var(--gold); border-color: var(--gold); color: var(--ink); }

/* ── Badge / Pill ────────────────────────────────────────────────────────────── */
.badge {
  display: inline-flex; align-items: center; gap: 4px;
  padding: 3px 10px; border-radius: var(--r-pill);
  font-size: .6875rem; font-weight: 700; letter-spacing: .06em; text-transform: uppercase;
}
.badge--gold    { background: rgba(201,168,76,.15); color: var(--gold); border: 1px solid rgba(201,168,76,.3); }
.badge--tier1   { background: rgba(74,127,181,.15); color: var(--tier1); border: 1px solid rgba(74,127,181,.3); }
.badge--tier2   { background: rgba(201,168,76,.2); color: var(--gold); border: 1px solid rgba(201,168,76,.4); }
.badge--eco     { background: rgba(58,125,68,.2); color: var(--eco-lt); border: 1px solid rgba(58,125,68,.3); }
.badge--success { background: rgba(45,122,79,.2); color: #6dcf9a; border: 1px solid rgba(45,122,79,.3); }
.badge--error   { background: rgba(192,57,43,.2); color: #e88; border: 1px solid rgba(192,57,43,.3); }
.badge--pending { background: rgba(180,150,60,.15); color: #d4b060; border: 1px solid rgba(180,150,60,.3); }
.badge--info    { background: rgba(74,127,181,.15); color: #88b8e8; border: 1px solid rgba(74,127,181,.3); }

/* ── Navigation Bar ──────────────────────────────────────────────────────────── */
.navbar {
  position: sticky; top: 0; z-index: 100;
  background: rgba(13,12,10,.92); backdrop-filter: blur(20px);
  border-bottom: 1px solid rgba(255,255,255,.06);
  padding: var(--sp-4) 0;
}
.navbar__inner {
  display: flex; align-items: center; justify-content: space-between; gap: var(--sp-4);
}
.navbar__brand {
  display: flex; flex-direction: column; line-height: 1;
}
.navbar__brand-main {
  font-family: var(--font-display); font-size: 1.2rem; color: var(--gold); letter-spacing: .02em;
}
.navbar__brand-sub { font-size: .65rem; letter-spacing: .15em; color: var(--slate); text-transform: uppercase; }
.navbar__links {
  display: flex; align-items: center; gap: var(--sp-6);
}
.navbar__link {
  font-size: .875rem; font-weight: 500; color: var(--slate-lt);
  transition: color var(--dur-fast) var(--ease); position: relative;
}
.navbar__link:hover, .navbar__link.active { color: var(--cream); }
.navbar__link.active::after {
  content: ''; position: absolute; bottom: -4px; left: 0; right: 0;
  height: 2px; background: var(--gold); border-radius: 1px;
}
.navbar__right { display: flex; align-items: center; gap: var(--sp-3); }
.navbar__avatar {
  width: 36px; height: 36px; border-radius: 50%;
  border: 2px solid rgba(201,168,76,.4); object-fit: cover;
  transition: border-color var(--dur-fast) var(--ease);
}
.navbar__avatar:hover { border-color: var(--gold); }
.navbar__avatar-fallback {
  width: 36px; height: 36px; border-radius: 50%;
  background: var(--gold-dim); display: flex; align-items: center; justify-content: center;
  font-size: .875rem; font-weight: 700; color: var(--ink);
}
.navbar__menu-btn {
  display: none; background: none; border: none; cursor: pointer;
  color: var(--cream); padding: var(--sp-2);
}

/* ── Mobile Nav ──────────────────────────────────────────────────────────────── */
.mobile-nav {
  display: none; position: fixed; inset: 0; z-index: 200;
  background: var(--ink); padding: var(--sp-8) var(--sp-6);
  flex-direction: column; gap: var(--sp-6);
}
.mobile-nav.open { display: flex; }
.mobile-nav__close {
  align-self: flex-end; background: none; border: none; cursor: pointer; color: var(--cream);
}
.mobile-nav__links { display: flex; flex-direction: column; gap: var(--sp-4); }
.mobile-nav__link { font-size: 1.25rem; font-weight: 500; color: var(--cream-dim); padding-block: var(--sp-2); border-bottom: 1px solid rgba(255,255,255,.06); }
.mobile-nav__link.active { color: var(--gold); }

/* ── Bottom Tab Bar (PWA) ────────────────────────────────────────────────────── */
.tab-bar {
  display: none; position: fixed; bottom: 0; left: 0; right: 0; z-index: 100;
  background: rgba(13,12,10,.96); backdrop-filter: blur(20px);
  border-top: 1px solid rgba(255,255,255,.08);
  padding: var(--sp-2) 0; padding-bottom: calc(var(--sp-2) + env(safe-area-inset-bottom));
}
.tab-bar__inner { display: flex; justify-content: space-around; }
.tab-bar__item {
  display: flex; flex-direction: column; align-items: center; gap: 3px;
  font-size: .65rem; font-weight: 600; letter-spacing: .04em; text-transform: uppercase;
  color: var(--slate); padding: var(--sp-2) var(--sp-3);
  transition: color var(--dur-fast) var(--ease); cursor: pointer; background: none; border: none;
}
.tab-bar__item.active { color: var(--gold); }
.tab-bar__item svg { width: 22px; height: 22px; }

/* ── Page Header ─────────────────────────────────────────────────────────────── */
.page-header { padding: var(--sp-10) 0 var(--sp-8); }
.page-header__eyebrow { margin-bottom: var(--sp-3); }

/* ── Stats / Metric Cards ────────────────────────────────────────────────────── */
.metric-card { display: flex; flex-direction: column; gap: var(--sp-2); }
.metric-card__value { font-family: var(--font-display); font-size: 2rem; color: var(--gold); line-height: 1; }
.metric-card__label { font-size: .75rem; font-weight: 600; letter-spacing: .06em; text-transform: uppercase; color: var(--slate); }
.metric-card__sub { font-size: .8125rem; color: var(--slate-lt); }

/* ── Progress Bar ────────────────────────────────────────────────────────────── */
.progress-bar { height: 4px; background: rgba(255,255,255,.08); border-radius: 2px; overflow: hidden; }
.progress-bar__fill { height: 100%; background: linear-gradient(90deg, var(--gold-dim), var(--gold)); border-radius: 2px; transition: width .6s var(--ease); }
.progress-bar--eco .progress-bar__fill { background: linear-gradient(90deg, var(--eco-green), var(--eco-lt)); }

/* ── Circular Badge ──────────────────────────────────────────────────────────── */
.eco-badge {
  display: inline-flex; align-items: center; gap: var(--sp-2);
  background: rgba(58,125,68,.12); border: 1px solid rgba(58,125,68,.25);
  border-radius: var(--r-pill); padding: var(--sp-2) var(--sp-4);
  font-size: .8125rem; font-weight: 600; color: var(--eco-lt);
}
.eco-badge svg { width: 16px; height: 16px; flex-shrink: 0; }

/* ── Toast / Alert ───────────────────────────────────────────────────────────── */
.toast-container { position: fixed; top: var(--sp-4); right: var(--sp-4); z-index: 9999; display: flex; flex-direction: column; gap: var(--sp-2); pointer-events: none; }
.toast {
  background: var(--ink-soft); border: 1px solid rgba(255,255,255,.1);
  border-radius: var(--r-md); padding: var(--sp-4) var(--sp-5);
  font-size: .875rem; min-width: 260px; max-width: 340px;
  box-shadow: var(--shadow-lg); pointer-events: all;
  animation: slideIn var(--dur-mid) var(--ease);
}
.toast--success { border-color: rgba(45,122,79,.4); }
.toast--error   { border-color: rgba(192,57,43,.4); }
@keyframes slideIn { from { opacity: 0; transform: translateX(20px); } to { opacity: 1; transform: translateX(0); } }

/* ── Alert boxes ─────────────────────────────────────────────────────────────── */
.alert { padding: var(--sp-4); border-radius: var(--r-md); border: 1px solid; font-size: .9rem; }
.alert--error   { background: rgba(192,57,43,.1); border-color: rgba(192,57,43,.3); color: #e88; }
.alert--success { background: rgba(45,122,79,.1); border-color: rgba(45,122,79,.3); color: #6dcf9a; }
.alert--info    { background: rgba(74,127,181,.1); border-color: rgba(74,127,181,.3); color: #88b8e8; }

/* ── Empty State ─────────────────────────────────────────────────────────────── */
.empty-state {
  text-align: center; padding: var(--sp-16) var(--sp-8);
  display: flex; flex-direction: column; align-items: center; gap: var(--sp-4);
}
.empty-state__icon { width: 64px; height: 64px; color: var(--slate); margin-inline: auto; opacity: .5; }
.empty-state__title { font-family: var(--font-display); font-size: 1.25rem; color: var(--cream-dim); }
.empty-state__body  { font-size: .9rem; color: var(--slate-lt); max-width: 320px; }

/* ── Grid ────────────────────────────────────────────────────────────────────── */
.grid-2 { display: grid; grid-template-columns: 1fr 1fr; gap: var(--sp-4); }
.grid-3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: var(--sp-4); }
.grid-4 { display: grid; grid-template-columns: repeat(4, 1fr); gap: var(--sp-4); }
.grid-auto { display: grid; grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); gap: var(--sp-4); }

/* ── Flex helpers ────────────────────────────────────────────────────────────── */
.flex        { display: flex; }
.flex-col    { flex-direction: column; }
.items-center { align-items: center; }
.items-start  { align-items: flex-start; }
.justify-between { justify-content: space-between; }
.justify-center  { justify-content: center; }
.gap-2 { gap: var(--sp-2); } .gap-3 { gap: var(--sp-3); } .gap-4 { gap: var(--sp-4); }
.gap-6 { gap: var(--sp-6); } .gap-8 { gap: var(--sp-8); }

/* ── Spacing helpers ─────────────────────────────────────────────────────────── */
.mt-2 { margin-top: var(--sp-2); } .mt-3 { margin-top: var(--sp-3); }
.mt-4 { margin-top: var(--sp-4); } .mt-6 { margin-top: var(--sp-6); }
.mt-8 { margin-top: var(--sp-8); } .mt-10 { margin-top: var(--sp-10); }
.mb-2 { margin-bottom: var(--sp-2); } .mb-4 { margin-bottom: var(--sp-4); }
.mb-6 { margin-bottom: var(--sp-6); } .mb-8 { margin-bottom: var(--sp-8); }

/* ── Loading Spinner ─────────────────────────────────────────────────────────── */
.spinner {
  width: 24px; height: 24px; border: 2px solid rgba(201,168,76,.2);
  border-top-color: var(--gold); border-radius: 50%; animation: spin .6s linear infinite;
}
@keyframes spin { to { transform: rotate(360deg); } }
.spinner--sm { width: 16px; height: 16px; border-width: 2px; }

/* ── Tabs ────────────────────────────────────────────────────────────────────── */
.tabs { display: flex; gap: 0; border-bottom: 1px solid rgba(255,255,255,.08); }
.tab {
  padding: var(--sp-3) var(--sp-4); font-size: .875rem; font-weight: 500;
  color: var(--slate-lt); cursor: pointer; border-bottom: 2px solid transparent;
  margin-bottom: -1px; background: none; border-left: none; border-right: none; border-top: none;
  transition: all var(--dur-fast) var(--ease);
}
.tab:hover { color: var(--cream); }
.tab.active { color: var(--gold); border-bottom-color: var(--gold); }
.tab-panel { display: none; padding-top: var(--sp-6); }
.tab-panel.active { display: block; }

/* ── Table ───────────────────────────────────────────────────────────────────── */
.table-wrap { overflow-x: auto; border-radius: var(--r-md); border: 1px solid rgba(255,255,255,.06); }
table { width: 100%; border-collapse: collapse; }
thead { background: var(--ink-mid); }
th { padding: var(--sp-3) var(--sp-4); font-size: .75rem; font-weight: 600; letter-spacing: .06em; text-transform: uppercase; color: var(--slate); text-align: left; }
td { padding: var(--sp-3) var(--sp-4); font-size: .875rem; color: var(--cream-dim); border-top: 1px solid rgba(255,255,255,.04); }
tr:hover td { background: rgba(255,255,255,.02); }

/* ── Modal ───────────────────────────────────────────────────────────────────── */
.modal-overlay {
  position: fixed; inset: 0; z-index: 300;
  background: rgba(0,0,0,.7); backdrop-filter: blur(4px);
  display: flex; align-items: center; justify-content: center; padding: var(--sp-4);
}
.modal {
  background: var(--ink-soft); border-radius: var(--r-xl);
  border: 1px solid rgba(255,255,255,.1); width: 100%; max-width: 520px;
  max-height: 90dvh; overflow-y: auto; padding: var(--sp-8);
  box-shadow: var(--shadow-lg);
}
.modal__header { display: flex; align-items: flex-start; justify-content: space-between; gap: var(--sp-4); margin-bottom: var(--sp-6); }
.modal__close { background: none; border: none; cursor: pointer; color: var(--slate-lt); padding: var(--sp-1); }
.modal__close:hover { color: var(--cream); }

/* ── Survey Rating Stars ─────────────────────────────────────────────────────── */
.star-rating { display: flex; gap: var(--sp-2); }
.star { font-size: 1.5rem; cursor: pointer; color: var(--slate); transition: color var(--dur-fast); }
.star.active, .star:hover { color: var(--gold); }

/* ── Wardrobe Grid ───────────────────────────────────────────────────────────── */
.wardrobe-card {
  background: var(--ink-soft); border: 1px solid rgba(255,255,255,.06);
  border-radius: var(--r-lg); overflow: hidden;
  transition: all var(--dur-mid) var(--ease); cursor: pointer;
}
.wardrobe-card:hover { border-color: rgba(201,168,76,.3); transform: translateY(-3px); box-shadow: var(--shadow-md); }
.wardrobe-card__img { aspect-ratio: 1; background: var(--ink-mid); display: flex; align-items: center; justify-content: center; color: var(--slate); }
.wardrobe-card__img img { width: 100%; height: 100%; object-fit: cover; }
.wardrobe-card__body { padding: var(--sp-4); }
.wardrobe-card__name { font-size: .9375rem; font-weight: 600; color: var(--cream); margin-bottom: var(--sp-1); }
.wardrobe-card__meta { font-size: .75rem; color: var(--slate-lt); }

/* ── Install Banner ──────────────────────────────────────────────────────────── */
.install-banner {
  position: fixed; bottom: 0; left: 0; right: 0; z-index: 500;
  background: var(--ink-soft); border-top: 1px solid rgba(201,168,76,.25);
  padding: var(--sp-4) var(--sp-6);
  display: flex; align-items: center; justify-content: space-between; gap: var(--sp-4);
  box-shadow: 0 -8px 32px rgba(0,0,0,.4);
  transform: translateY(100%); transition: transform var(--dur-slow) var(--ease);
}
.install-banner.show { transform: translateY(0); }
.install-banner__text { font-size: .875rem; }
.install-banner__title { font-weight: 600; color: var(--cream); }
.install-banner__sub { font-size: .8rem; color: var(--slate-lt); }
.install-banner__actions { display: flex; gap: var(--sp-2); flex-shrink: 0; }

/* ── Offline Banner ──────────────────────────────────────────────────────────── */
.offline-banner {
  position: fixed; top: 0; left: 0; right: 0; z-index: 999;
  background: var(--error); color: #fff; text-align: center;
  padding: var(--sp-2); font-size: .875rem; font-weight: 500;
  transform: translateY(-100%); transition: transform var(--dur-mid) var(--ease);
}
.offline-banner.show { transform: translateY(0); }

/* ── Scrollbar ───────────────────────────────────────────────────────────────── */
::-webkit-scrollbar { width: 6px; height: 6px; }
::-webkit-scrollbar-track { background: var(--ink); }
::-webkit-scrollbar-thumb { background: var(--ink-mid); border-radius: 3px; }
::-webkit-scrollbar-thumb:hover { background: var(--slate); }

/* ── Responsive ──────────────────────────────────────────────────────────────── */
@media (max-width: 768px) {
  .navbar__links { display: none; }
  .navbar__menu-btn { display: flex; }
  .tab-bar { display: flex; }
  .grid-2, .grid-3, .grid-4 { grid-template-columns: 1fr; }
  .grid-auto { grid-template-columns: repeat(auto-fill, minmax(160px, 1fr)); }
  body { padding-bottom: 80px; }
  .container { padding-inline: var(--sp-4); }
  .modal { padding: var(--sp-6) var(--sp-4); }
  .hide-mobile { display: none !important; }
}
@media (max-width: 480px) {
  .grid-auto { grid-template-columns: 1fr 1fr; }
}
@media (min-width: 769px) {
  .hide-desktop { display: none !important; }
}

/* ── Dark mode (already dark, this ensures consistency) ──────────────────────── */
@media (prefers-color-scheme: light) {
  /* App is intentionally always dark — brand identity */
}

/* ── Reduced motion ──────────────────────────────────────────────────────────── */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .01ms !important; transition-duration: .01ms !important; }
}

/* ── Print ───────────────────────────────────────────────────────────────────── */
@media print {
  .navbar, .tab-bar, .install-banner { display: none; }
  body { background: #fff; color: #000; }
}

/* ═══════════════════════════════════════════════════════════════════════════
   NEW COMPONENTS — Bespoke / Membership / Survey / Landing / AI Stylist
   ═══════════════════════════════════════════════════════════════════════════ */

/* ── Stepper (multi-step forms: bespoke, survey) ───────────────────────────── */
.step-indicator { display: flex; align-items: center; gap: var(--sp-2); margin-bottom: var(--sp-8); }
.step-indicator span {
  flex: 1; height: 3px; background: rgba(255,255,255,.08); border-radius: 2px;
  transition: background var(--dur-mid) var(--ease);
}
.step-indicator span.active { background: var(--gold); }
[data-step], [data-section] { display: none; }
[data-step].active, [data-section].active { display: block; animation: fadeUp var(--dur-mid) var(--ease); }
@keyframes fadeUp { from { opacity: 0; transform: translateY(8px); } to { opacity: 1; transform: translateY(0); } }
.step-actions { display: flex; justify-content: space-between; gap: var(--sp-3); margin-top: var(--sp-8); }

/* ── Selectable Option Cards (product type, fabric, pathway) ───────────────── */
.option-card {
  display: block; cursor: pointer; padding: var(--sp-5); border-radius: var(--r-lg);
  border: 1px solid rgba(255,255,255,.08); background: var(--ink-mid);
  transition: all var(--dur-fast) var(--ease); position: relative;
}
.option-card input { position: absolute; opacity: 0; pointer-events: none; }
.option-card:hover { border-color: rgba(201,168,76,.35); }
.option-card.selected, .option-card:has(input:checked) {
  border-color: var(--gold); background: rgba(201,168,76,.07); box-shadow: var(--shadow-gold);
}
.option-card__title { font-weight: 600; color: var(--cream); margin-bottom: var(--sp-1); }
.option-card__price { color: var(--gold); font-weight: 700; font-family: var(--font-display); font-size: 1.1rem; }
.option-card__desc { font-size: .8125rem; color: var(--slate-lt); margin-top: var(--sp-2); }

/* ── Pricing Cards (membership tiers) ───────────────────────────────────────── */
.pricing-card {
  background: var(--ink-soft); border: 1px solid rgba(255,255,255,.08); border-radius: var(--r-xl);
  padding: var(--sp-8); display: flex; flex-direction: column; gap: var(--sp-5); position: relative;
}
.pricing-card--featured { border-color: rgba(201,168,76,.45); box-shadow: var(--shadow-gold); }
.pricing-card__ribbon {
  position: absolute; top: var(--sp-5); right: var(--sp-5); background: var(--gold); color: var(--ink);
  font-size: .65rem; font-weight: 700; letter-spacing: .08em; text-transform: uppercase;
  padding: 4px 10px; border-radius: var(--r-pill);
}
.pricing-card__price { font-family: var(--font-display); font-size: 2.4rem; color: var(--cream); }
.pricing-card__price span { font-family: var(--font-sans); font-size: .9rem; color: var(--slate-lt); font-weight: 400; }
.pricing-card__perks { display: flex; flex-direction: column; gap: var(--sp-3); flex: 1; }
.pricing-card__perks li { display: flex; gap: var(--sp-2); align-items: flex-start; font-size: .875rem; color: var(--cream-dim); list-style: none; }
.pricing-card__perks svg { width: 16px; height: 16px; color: var(--gold); flex-shrink: 0; margin-top: 2px; }

/* ── Measurement Grid (bespoke form) ────────────────────────────────────────── */
.measure-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: var(--sp-4); }
@media (max-width: 768px) { .measure-grid { grid-template-columns: repeat(2, 1fr); } }
.measure-field { position: relative; }
.measure-field .form-input { padding-right: 2.4rem; }
.measure-field__unit {
  position: absolute; right: var(--sp-3); top: 2.3rem; font-size: .75rem; color: var(--slate);
}

/* ── AI Stylist Panel (wardrobe Smart Styling) ──────────────────────────────── */
.ai-panel {
  background: linear-gradient(135deg, rgba(148,130,255,.06) 0%, rgba(201,168,76,.04) 100%);
  border: 1px solid rgba(148,130,255,.2); border-radius: var(--r-lg); padding: var(--sp-6);
}
.ai-panel__head { display: flex; align-items: center; gap: var(--sp-3); margin-bottom: var(--sp-4); }
.ai-panel__icon {
  width: 36px; height: 36px; border-radius: 50%; flex-shrink: 0;
  background: rgba(148,130,255,.15); display: flex; align-items: center; justify-content: center; color: #9482FF;
}
.ai-panel__result {
  background: var(--ink); border-radius: var(--r-md); padding: var(--sp-5);
  font-size: .9rem; line-height: 1.7; color: var(--cream-dim); border: 1px solid rgba(255,255,255,.06);
}
.ai-panel__result p { margin-bottom: var(--sp-2); }
.ai-panel__result:empty::before { content: 'Tap "Get Suggestion" and our AI Stylist will pair items from your Virtual Closet.'; color: var(--slate); }

/* ── Order Summary Box ──────────────────────────────────────────────────────── */
.order-summary { background: var(--ink-mid); border-radius: var(--r-md); padding: var(--sp-5); }
.order-summary__row { display: flex; justify-content: space-between; padding-block: var(--sp-2); font-size: .875rem; }
.order-summary__row.total { border-top: 1px solid rgba(255,255,255,.1); margin-top: var(--sp-2); padding-top: var(--sp-3); font-weight: 700; color: var(--cream); font-size: 1rem; }
.order-summary__row.discount { color: var(--eco-lt); }

/* ── Landing / Marketing Page ────────────────────────────────────────────────── */
.hero { padding: var(--sp-24) 0 var(--sp-16); text-align: center; position: relative; overflow: hidden; }
.hero__bg {
  position: absolute; inset: 0; z-index: -1;
  background: radial-gradient(ellipse 70% 50% at 50% -10%, rgba(201,168,76,.12) 0%, transparent 65%),
              radial-gradient(ellipse 50% 40% at 90% 100%, rgba(148,130,255,.06) 0%, transparent 60%);
}
.hero__eyebrow { display: inline-block; margin-bottom: var(--sp-5); }
.hero__title { margin-bottom: var(--sp-5); }
.hero__sub { max-width: 560px; margin: 0 auto var(--sp-8); color: var(--slate-lt); font-size: 1.0625rem; }
.hero__actions { display: flex; gap: var(--sp-4); justify-content: center; flex-wrap: wrap; }
.feature-row { display: grid; grid-template-columns: repeat(2, 1fr); gap: var(--sp-6); padding-block: var(--sp-16); }
@media (max-width: 768px) { .feature-row { grid-template-columns: 1fr; } .hero { padding: var(--sp-16) 0 var(--sp-10); } }
.feature-card { padding: var(--sp-6); }
.feature-card__icon { width: 40px; height: 40px; color: var(--gold); margin-bottom: var(--sp-4); }
.arch-diagram { display: flex; flex-direction: column; align-items: center; gap: var(--sp-3); padding: var(--sp-8) 0; }
.arch-diagram__split { display: flex; gap: var(--sp-6); flex-wrap: wrap; justify-content: center; }
.arch-node { padding: var(--sp-5) var(--sp-6); border-radius: var(--r-lg); border: 1px solid rgba(255,255,255,.1); background: var(--ink-soft); text-align: center; min-width: 200px; }
.arch-node--root { border-color: rgba(201,168,76,.4); background: rgba(201,168,76,.06); }
.arch-line { width: 1px; height: 28px; background: rgba(255,255,255,.15); }
.site-footer { padding: var(--sp-10) 0; border-top: 1px solid rgba(255,255,255,.06); text-align: center; color: var(--slate); font-size: .8125rem; }
.site-footer a { color: var(--slate-lt); margin-inline: var(--sp-3); }
.site-footer a:hover { color: var(--gold); }

/* ── Consultation Slot Picker ────────────────────────────────────────────────── */
.slot-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: var(--sp-3); }
@media (max-width: 600px) { .slot-grid { grid-template-columns: repeat(2, 1fr); } }
.slot-btn {
  padding: var(--sp-3); border-radius: var(--r-md); border: 1px solid rgba(255,255,255,.1);
  background: var(--ink-mid); color: var(--cream-dim); font-size: .8125rem; cursor: pointer;
  transition: all var(--dur-fast) var(--ease); text-align: center;
}
.slot-btn.active, .slot-btn:hover { border-color: var(--gold); color: var(--gold); background: rgba(201,168,76,.08); }

/* ── Legal / Doc Pages ───────────────────────────────────────────────────────── */
.doc-content h2 { font-family: var(--font-display); font-size: 1.3rem; color: var(--gold-lt); margin: var(--sp-8) 0 var(--sp-3); }
.doc-content h3 { font-size: 1rem; font-weight: 700; color: var(--cream); margin: var(--sp-5) 0 var(--sp-2); }
.doc-content p, .doc-content li { font-size: .9rem; color: var(--cream-dim); line-height: 1.75; margin-bottom: var(--sp-3); }
.doc-content ul { padding-left: var(--sp-5); list-style: disc; }
.doc-content strong { color: var(--cream); }
.doc-meta { font-size: .8rem; color: var(--slate); margin-bottom: var(--sp-8); }

/* ── Profile ──────────────────────────────────────────────────────────────────── */
.profile-avatar { width: 88px; height: 88px; border-radius: 50%; object-fit: cover; border: 3px solid rgba(201,168,76,.4); }
.profile-avatar-fallback {
  width: 88px; height: 88px; border-radius: 50%; background: var(--gold-dim);
  display: flex; align-items: center; justify-content: center; font-size: 2rem; font-weight: 700; color: var(--ink);
}
