:root {
  --paper: #f4f0e8;
  --card: #fffdf8;
  --ink: #24221f;
  --muted: #777068;
  --wine: #74443f;
  --sage: #697365;
  --line: rgba(36, 34, 31, .11);
  --shadow: 0 18px 60px rgba(48, 39, 31, .10);
}
* { box-sizing: border-box; }
body {
  margin: 0; background: var(--paper); color: var(--ink);
  font-family: Inter, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  -webkit-font-smoothing: antialiased;
}
button { font: inherit; }
.app-shell { max-width: 760px; margin: 0 auto; min-height: 100vh; padding: 0 18px 108px; }
.topbar { display: flex; align-items: center; justify-content: space-between; padding: 24px 2px 20px; }
.topbar h1 { font-family: Georgia, serif; font-size: 28px; font-weight: 500; margin: 2px 0 0; letter-spacing: -.5px; }
.eyebrow { font-size: 9px; letter-spacing: 2.2px; color: var(--muted); }
.avatar { width: 42px; height: 42px; border-radius: 50%; display: grid; place-items: center; color: white; background: var(--wine); font-family: Georgia, serif; }
.hero { position: relative; overflow: hidden; border-radius: 28px; padding: 30px 26px; color: white; background: linear-gradient(145deg, #25221f, #60433e); box-shadow: var(--shadow); }
.dna-visual { margin-bottom: 16px; }
.visual-title { display: grid; gap: 6px; margin: 2px 2px 14px; }
.visual-title span { font-size: 9px; letter-spacing: 2.2px; color: var(--wine); }
.visual-title b { font: 400 27px/1.12 Georgia, serif; }
.inspiration-rail { display: grid; grid-auto-flow: column; grid-auto-columns: 82%; gap: 10px; overflow-x: auto; scroll-snap-type: x mandatory; scrollbar-width: none; margin: 0 -18px 18px; padding: 0 18px; }
.inspiration-rail::-webkit-scrollbar { display: none; }
.inspiration-slide { position: relative; margin: 0; height: min(68vh, 610px); border-radius: 25px; overflow: hidden; scroll-snap-align: center; background: #ddd4c8; }
.inspiration-slide img { width: 100%; height: 100%; display: block; object-fit: cover; }
.inspiration-slide::after { content: ""; position: absolute; inset: 60% 0 0; background: linear-gradient(transparent, rgba(20,18,17,.45)); }
.inspiration-slide figcaption { position: absolute; z-index: 2; left: 18px; bottom: 16px; color: white; font: 400 26px Georgia, serif; }
.hero::after { content: ""; position: absolute; width: 220px; height: 220px; border: 1px solid rgba(255,255,255,.14); border-radius: 50%; right: -95px; top: -80px; }
.hero-label { color: rgba(255,255,255,.68); font-size: 11px; letter-spacing: 1.7px; }
.hero h2 { font: 400 32px/1.08 Georgia, serif; max-width: 520px; margin: 18px 0 14px; }
.hero p { color: rgba(255,255,255,.75); line-height: 1.55; font-size: 14px; max-width: 560px; }
.priority-row { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 20px; }
.pill { padding: 8px 12px; border: 1px solid rgba(255,255,255,.22); border-radius: 99px; font-size: 12px; background: rgba(255,255,255,.07); }
.section-head { display: flex; align-items: end; justify-content: space-between; margin: 30px 2px 14px; }
.section-head h3 { margin: 0; font: 400 23px Georgia, serif; }
.section-head span { color: var(--muted); font-size: 12px; }
.card { background: var(--card); border: 1px solid var(--line); border-radius: 22px; padding: 20px; box-shadow: 0 9px 30px rgba(48,39,31,.05); }
.insight-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.insight-card { min-height: 145px; }
.icon { width: 34px; height: 34px; border-radius: 12px; display: grid; place-items: center; background: #ece7db; color: var(--wine); margin-bottom: 20px; }
.insight-card h4 { margin: 0 0 7px; font-size: 14px; }
.insight-card p { margin: 0; color: var(--muted); font-size: 12px; line-height: 1.45; }
.analytics-grid { display: grid; grid-template-columns: 1.25fr .9fr; gap: 12px; }
.analytics-grid h4, .gaps-card h4 { margin: 0 0 7px; font-size: 14px; }
.analytics-grid p { color: var(--muted); font-size: 11px; line-height: 1.4; margin: 0; }
.match-card { display: flex; align-items: center; gap: 13px; padding: 16px; }
.match-ring { --value: 0; flex: 0 0 66px; width: 66px; height: 66px; display: grid; place-items: center; border-radius: 50%; background: conic-gradient(var(--wine) calc(var(--value) * 1%), #e5dfd5 0); position: relative; }
.match-ring::after { content: ""; position: absolute; width: 50px; height: 50px; border-radius: 50%; background: var(--card); }
.match-ring b { position: relative; z-index: 1; font-size: 13px; }
.palette-card { padding: 16px; }
.outfit-stat { grid-column: 1 / -1; display: flex; align-items: center; gap: 15px; padding: 16px; }
.outfit-stat > span { font: 400 40px Georgia,serif; color: var(--wine); }.outfit-stat h4 { margin: 0 0 4px; }
.swatches { display: flex; margin: 13px 0 9px; }
.swatches span { width: 30px; height: 30px; border-radius: 50%; background: var(--swatch); border: 2px solid white; margin-left: -7px; box-shadow: 0 2px 8px rgba(0,0,0,.12); }
.swatches span:first-child { margin-left: 0; }
.gaps-card { margin-top: 12px; }
.upload-button { display: grid; place-items: center; min-height: 54px; margin-top: 12px; color: white; background: var(--wine); border-radius: 18px; font-size: 13px; cursor: pointer; }
.preview-strip { display: grid; grid-template-columns: repeat(5, 1fr); gap: 7px; }
.preview-strip img { width: 100%; aspect-ratio: .72; object-fit: contain; padding: 5px; background: #eee9df; border-radius: 12px; }
.wardrobe-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 12px; }
.filter-row { display: flex; gap: 8px; overflow-x: auto; margin: -2px -18px 16px; padding: 2px 18px; scrollbar-width: none; }
.filter-button { white-space: nowrap; border: 1px solid var(--line); background: var(--card); color: var(--muted); padding: 9px 14px; border-radius: 99px; font-size: 12px; }
.filter-button.active { color: white; background: var(--ink); }
.item-card { padding: 0; overflow: hidden; position: relative; }
.item-card > img { width: 100%; aspect-ratio: .82; display: block; object-fit: contain; padding: 12px; background: #eee9df; }
.score { position: absolute; right: 10px; top: 10px; width: 43px; height: 43px; display: grid; place-items: center; color: white; border-radius: 50%; background: rgba(36,34,31,.82); backdrop-filter: blur(8px); font-size: 12px; font-weight: 700; border: 2px solid rgba(255,255,255,.7); }
.item-copy { padding: 14px; }
.item-copy b { display: block; font-size: 13px; margin-bottom: 5px; }
.item-copy p { margin: 0; font-size: 11px; line-height: 1.42; color: var(--muted); }
.match-badge { position: absolute; left: 9px; top: 9px; padding: 6px 8px; border-radius: 99px; font-size: 9px; color: white; backdrop-filter: blur(8px); }
.match-badge.yes { background: rgba(75,103,74,.85); }.match-badge.no { background: rgba(121,67,61,.85); }
.drawer-backdrop { position: fixed; z-index: 60; inset: 0; background: rgba(25,22,20,.48); display: flex; align-items: end; backdrop-filter: blur(6px); }
.item-drawer { width: min(100%,760px); max-height: 92vh; margin: 0 auto; overflow-y: auto; border-radius: 28px 28px 0 0; background: var(--paper); position: relative; }
.item-drawer > img { width: 100%; height: min(52vh,520px); object-fit: cover; display: block; }
.item-drawer > img.drawer-cutout { object-fit: contain; padding: 20px; background: #eee9df; }
.drawer-close { position: absolute; z-index: 2; right: 14px; top: 14px; width: 38px; height: 38px; border: 0; border-radius: 50%; background: rgba(255,255,255,.9); font-size: 24px; }
.drawer-copy { padding: 24px 20px 42px; }
.drawer-copy h2 { margin: 13px 0 8px; font: 400 28px Georgia,serif; }.drawer-copy h3 { margin: 25px 0 7px; font: 400 19px Georgia,serif; }
.drawer-copy > p, .drawer-copy dd { color: var(--muted); font-size: 13px; line-height: 1.55; }
.drawer-tags { display: flex; flex-wrap: wrap; gap: 6px; }.drawer-tags span { padding: 7px 9px; background: #e8e1d5; border-radius: 99px; font-size: 10px; }
.drawer-copy dl { display: grid; grid-template-columns: 80px 1fr; gap: 8px; margin-top: 20px; }.drawer-copy dt { font-size: 12px; font-weight: 700; }.drawer-copy dd { margin: 0; }
.look-card { margin-bottom: 12px; }
.section-intro { color: var(--muted); font-size: 13px; line-height: 1.5; margin: -4px 2px 16px; }
.visual-look { padding: 0; overflow: hidden; }
.visual-look > img { width: 100%; display: block; aspect-ratio: .68; object-fit: cover; background: #e4ded3; }
.look-copy { padding: 20px; }
.generated-look-rail { display: grid; grid-auto-flow: column; grid-auto-columns: 84%; gap: 12px; overflow-x: auto; scroll-snap-type: x mandatory; scrollbar-width: none; margin: 0 -18px; padding: 0 18px 8px; }
.generated-look-rail::-webkit-scrollbar { display: none; }.generated-look-rail .visual-look { scroll-snap-align: center; margin: 0; }
.stylist-board-grid { display: grid; grid-template-columns: 1fr; gap: 12px; }
.stylist-board { background: var(--card); border: 1px solid var(--line); border-radius: 22px; padding: 14px; }
.board-images { height: 240px; display: flex; align-items: center; justify-content: center; gap: 5px; overflow: hidden; border-radius: 15px; background: #eee9df; }
.board-images figure { flex: 1; min-width: 0; height: 88%; margin: 0; position: relative; }
.board-images img { width: 100%; height: 100%; object-fit: contain; }
.board-images figcaption { display: none; }.plus { flex: 0; color: var(--wine); font-size: 18px; }
.stylist-board h4 { margin: 13px 0 4px; font: 400 18px Georgia,serif; }.stylist-board p { margin: 0; color: var(--muted); font-size: 10px; line-height: 1.4; }
.drawer-outfits { display: grid; gap: 10px; }.stylist-board.compact .board-images { height: 180px; }.stylist-board.compact h4 { font-size: 16px; }
.pinterest-reference { display: grid; grid-template-columns: 94px 1fr; gap: 13px; align-items: center; color: inherit; text-decoration: none; background: white; border: 1px solid var(--line); border-radius: 17px; overflow: hidden; }
.pinterest-reference img { width: 94px; height: 112px; object-fit: cover; }.pinterest-reference span { display: grid; gap: 7px; padding-right: 12px; }.pinterest-reference b { font-size: 12px; }.pinterest-reference small { color: var(--muted); font-size: 10px; line-height: 1.35; }
.look-number { color: var(--wine); font: 400 34px Georgia, serif; }
.look-card h4 { margin: 5px 0 8px; font: 400 19px Georgia, serif; }
.look-card p { margin: 0; color: var(--muted); line-height: 1.55; font-size: 13px; }
.action-list { list-style: none; padding: 0; margin: 0; }
.action-list li { padding: 13px 0; border-bottom: 1px solid var(--line); line-height: 1.45; font-size: 13px; }
.action-list li:last-child { border: 0; }
.bottom-nav { position: fixed; z-index: 20; bottom: max(12px, env(safe-area-inset-bottom)); left: 50%; transform: translateX(-50%); width: min(calc(100% - 28px), 710px); display: grid; grid-template-columns: repeat(3, 1fr); padding: 7px; border: 1px solid rgba(255,255,255,.7); border-radius: 22px; background: rgba(255,253,248,.88); backdrop-filter: blur(18px); box-shadow: 0 15px 50px rgba(36,34,31,.15); }
.nav-button { border: 0; background: transparent; color: var(--muted); padding: 9px; border-radius: 16px; font-size: 10px; display: grid; gap: 3px; place-items: center; }
.nav-button span { font-size: 18px; }
.nav-button.active { background: var(--ink); color: white; }
.loading-card { padding: 30px; background: var(--card); border-radius: 26px; }
.shimmer { height: 15px; width: 70%; border-radius: 20px; margin: 14px 0; background: linear-gradient(90deg,#e9e3d8,#f7f3eb,#e9e3d8); background-size: 200%; animation: loading 1.2s infinite; }
.shimmer.wide { height: 170px; width: 100%; }.shimmer.short { width: 42%; }
.empty, .error { text-align: center; padding: 60px 24px; color: var(--muted); }
@keyframes loading { to { background-position: -200% 0; } }
@media (min-width: 620px) { .wardrobe-grid { grid-template-columns: repeat(3, 1fr); } .insight-grid { grid-template-columns: repeat(4, 1fr); } .stylist-board-grid { grid-template-columns: 1fr 1fr; } }
