/* Look, by Amazon — Design System
   Inspired by Amazon Luxury / mShop Store Mode
   Mobile-first, minimal, editorial */

/* === FONTS (Amazon Ember via CDN) === */
@font-face {
  font-family: 'Amazon Ember';
  font-weight: 200;
  font-style: normal;
  font-display: swap;
  src: url('https://m.media-amazon.com/images/S/sash/Dv1WQ5DdeMS5qP7.woff2') format('woff2'),
       url('https://m.media-amazon.com/images/S/sash/e0LnMbFWJC-TMQz.woff') format('woff');
}
@font-face {
  font-family: 'Amazon Ember';
  font-weight: 400;
  font-style: normal;
  font-display: swap;
  src: url('https://m.media-amazon.com/images/S/sash/McBk3F-ov1ILKN-.woff2') format('woff2'),
       url('https://m.media-amazon.com/images/S/sash/YAEPfuhs1l-argd.woff') format('woff');
}
@font-face {
  font-family: 'Amazon Ember';
  font-weight: 700;
  font-style: normal;
  font-display: swap;
  src: url('https://m.media-amazon.com/images/S/sash/KFPk-9IF4FqAqY-.woff2') format('woff2'),
       url('https://m.media-amazon.com/images/S/sash/mzVbGSgvdBfRLX9.woff') format('woff');
}
@font-face {
  font-family: 'Amazon Ember';
  font-weight: 700;
  font-style: italic;
  font-display: swap;
  src: url('https://m.media-amazon.com/images/S/sash/2SazJx$EeTHfhMN.woff2') format('woff2'),
       url('https://m.media-amazon.com/images/S/sash/CjbL$jCCegyfqZ7.woff') format('woff');
}

:root {
  --black: #0f1111;
  --white: #ffffff;
  --gray-50: #fafafa;
  --gray-100: #f3f3f3;
  --gray-200: #e8e8e8;
  --gray-300: #d5d5d5;
  --gray-400: #999999;
  --gray-500: #6b6b6b;
  --gray-600: #4a4a4a;
  --gold-dark: #876629;
  --gold-light: #DBC895;
  --gold-gradient: linear-gradient(270deg, #876629 0%, #DBC895 100%);
  --gold-border: linear-gradient(120deg, #E6D9BB, #8E7C59, #FAE3B6, #A59069);
  --font: 'Amazon Ember', -apple-system, BlinkMacSystemFont, "Helvetica Neue", Arial, sans-serif;
  --font-light: 'Amazon Ember', -apple-system, BlinkMacSystemFont, "Helvetica Neue", Arial, sans-serif;
  --font-serif: Georgia, serif;
  --font-display: 'Amazon Ember', Georgia, serif;
  --radius: 0;
  --space-xs: 4px;
  --space-sm: 8px;
  --space-md: 16px;
  --space-lg: 24px;
  --space-xl: 40px;
  --max-width: 480px;
}

* { margin: 0; padding: 0; box-sizing: border-box; }

body {
  font-family: var(--font);
  font-size: 14px;
  line-height: 1.5;
  color: var(--black);
  background: var(--white);
  -webkit-font-smoothing: antialiased;
  max-width: var(--max-width);
  margin: 0 auto;
  overflow-y: scroll;
  scrollbar-width: none;
}
body::-webkit-scrollbar { display: none; }

/* === HEADER === */
header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: var(--white);
  border-bottom: 1px solid var(--gray-200);
  padding: 6px var(--space-md);
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.header-left { display: flex; align-items: center; gap: 10px; }
.header-left a { display: flex; align-items: center; }
.header-left svg { display: block; }
.header-logo { position: absolute; left: 50%; top: 50%; transform: translate(-50%, -50%); display: flex; align-items: center; }
.header-back { background: none; border: 0; padding: 0 8px 0 0; margin: 0; display: flex; align-items: center; color: var(--black); cursor: pointer; }
header > .header-bell, header > span { min-width: 24px; display: flex; justify-content: flex-end; }

header a { color: var(--black); text-decoration: none; }
header img { height: 24px; }

/* === BOTTOM NAV === */
nav[role="tablist"] {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  max-width: var(--max-width);
  margin: 0 auto;
  background: rgba(255, 255, 255, 0.82);
  -webkit-backdrop-filter: saturate(180%) blur(14px);
  backdrop-filter: saturate(180%) blur(14px);
  border-top: 1px solid var(--gray-200);
  display: flex;
  justify-content: space-around;
  padding: var(--space-md) 0;
  z-index: 100;
}
.standalone nav[role="tablist"] { padding-bottom: calc(var(--space-xl) + env(safe-area-inset-bottom)); }

nav[role="tablist"] a {
  position: relative;
  flex: 1 1 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 2px;
  font-size: 10px;
  color: var(--gray-400);
  text-decoration: none;
}

nav[role="tablist"] a[aria-selected="true"] { color: var(--black); font-weight: 600; }
nav[role="tablist"] a[aria-selected="true"]::before {
  content: "";
  position: absolute;
  top: calc(-1 * var(--space-md) + 2px);
  left: 22%;
  right: 22%;
  height: 3px;
  background: var(--black);
  border-radius: 0 0 3px 3px;
}

/* === MAIN CONTENT === */
main {
  padding: var(--space-md);
  padding-bottom: 80px; /* space for bottom nav */
}

/* === TYPOGRAPHY === */
h1 { font-family: var(--font-serif); font-size: 28px; font-weight: 200; letter-spacing: -0.3px; line-height: 1.2; margin-bottom: var(--space-md); }
h2 { font-family: var(--font); font-size: 18px; font-weight: 700; margin-bottom: var(--space-sm); }
h3 { font-family: var(--font); font-size: 15px; font-weight: 700; line-height: 20px; margin-bottom: var(--space-xs); }
p { font-family: var(--font-light); font-size: 15px; line-height: 20px; font-weight: 200; margin-bottom: var(--space-md); color: var(--gray-600); }

/* === SECTION HEADERS (like "New arrivals  Shop now") === */
.section-header {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  margin: var(--space-xl) 0 var(--space-md);
}

.section-header h2 { margin: 0; }
.section-header a { font-size: 13px; text-decoration: underline; color: var(--black); }

/* === HORIZONTAL SCROLL (product cards) === */
.scroll-row {
  display: flex;
  gap: var(--space-sm);
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  -webkit-overflow-scrolling: touch;
  margin: 0 calc(-1 * var(--space-md));
  padding: 0 var(--space-md);
}

.scroll-row::-webkit-scrollbar { display: none; }

/* === CARDS === */
.scroll-row .card {
  flex: 0 0 160px;
  scroll-snap-align: start;
  text-decoration: none;
  color: var(--black);
}

.scroll-row .card img {
  width: 100%;
  aspect-ratio: 1;
  object-fit: cover;
  background: var(--gray-100);
  display: block;
}

.card-body {
  padding: var(--space-sm) 0;
}

.card-body .brand { font-weight: 700; font-size: 13px; }
.card-body .title { font-size: 12px; color: var(--gray-600); }
.card-body .price { font-size: 12px; margin-top: 2px; }

/* === HERO / FEATURE IMAGE === */
.hero {
  position: relative;
  margin: 0 calc(-1 * var(--space-md));
  aspect-ratio: 3/4;
  overflow: hidden;
}

.hero img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.hero-overlay {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  padding: var(--space-lg);
  background: linear-gradient(transparent, rgba(0,0,0,0.6));
  color: var(--white);
}

.hero-overlay h1 { font-family: var(--font-serif); font-size: 32px; font-weight: 400; color: var(--white); margin-bottom: var(--space-sm); line-height: 1.15; }
.hero-overlay p { font-family: var(--font-light); color: rgba(255,255,255,0.85); margin-bottom: var(--space-md); }

/* === BUTTONS === */
.btn {
  display: inline-block;
  padding: 10px 20px;
  border: 1.5px solid var(--black);
  background: transparent;
  color: var(--black);
  font-family: var(--font);
  font-size: 13px;
  font-weight: 500;
  text-decoration: none;
  cursor: pointer;
  transition: background 0.15s, color 0.15s;
}

.btn:hover, .btn:active { background: var(--black); color: var(--white); }
.btn-filled { background: var(--black); color: var(--white); border-color: var(--black); }
.btn-filled:hover { background: var(--gray-600); }
.btn-white { border-color: var(--white); color: var(--white); }
.btn-white:hover { background: var(--white); color: var(--black); }
.btn-gold { border-color: var(--gold-dark); color: var(--gold-dark); }
.btn-gold:hover { background: var(--gold-dark); color: var(--white); }

/* === GRID (2-col for browse) === */
.grid-2 {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: var(--space-sm);
}

.grid-3 {
  display: grid;
  grid-template-columns: 1fr 1fr 1fr;
  gap: var(--space-sm);
}

/* === AVATAR === */
.avatar {
  width: 48px;
  height: 48px;
  border-radius: 50%;
  object-fit: cover;
}

.avatar-lg { width: 80px; height: 80px; border-radius: 50%; object-fit: cover; }
.avatar-sm { width: 32px; height: 32px; border-radius: 50%; object-fit: cover; }

/* === LIST ITEMS === */
.list-item {
  display: flex;
  gap: var(--space-md);
  padding: var(--space-md) 0;
  border-bottom: 1px solid var(--gray-200);
  text-decoration: none;
  color: var(--black);
}

.list-item img { width: 64px; height: 64px; object-fit: cover; flex-shrink: 0; }

/* === FORMS === */
input, textarea, select {
  width: 100%;
  padding: 12px;
  border: 1px solid var(--gray-300);
  font-size: 16px;
  font-family: var(--font);
  margin-bottom: var(--space-md);
  appearance: none;
  border-radius: 0;
}

input:focus, textarea:focus, select:focus {
  outline: none;
  border-color: var(--black);
}

label {
  display: block;
  font-size: 12px;
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  color: var(--gray-500);
  margin-bottom: var(--space-xs);
}

/* === TABS === */
.tabs {
  display: flex;
  border-bottom: 1px solid var(--gray-200);
  margin-bottom: var(--space-lg);
}

.tabs a {
  flex: 1;
  text-align: center;
  padding: var(--space-md) var(--space-sm);
  font-size: 13px;
  text-decoration: none;
  color: var(--gray-400);
  border-bottom: 2px solid transparent;
}

.tabs a[aria-selected="true"] {
  color: var(--black);
  border-bottom-color: var(--black);
}

/* === DIVIDER === */
div[role="separator"] {
  height: 1px;
  background: var(--gold-gradient);
  margin: var(--space-lg) 0;
}

/* === BADGE === */
.badge {
  display: inline-block;
  font-size: 10px;
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  padding: 2px 6px;
  background: var(--gray-100);
  color: var(--gray-600);
}

/* === FOOTER === */
footer {
  padding: var(--space-xl) var(--space-md);
  text-align: center;
  font-size: 11px;
  color: var(--gray-400);
  border-top: 1px solid var(--gray-200);
}

footer a { color: var(--gray-500); text-decoration: none; }

/* === UTILITIES === */
.text-center { text-align: center; }
.text-sm { font-size: 12px; }
.text-xs { font-size: 11px; }
.text-muted { color: var(--gray-500); }
.text-gold { color: var(--gold-dark); }
.mt-lg { margin-top: var(--space-lg); }
.mb-lg { margin-bottom: var(--space-lg); }
.gap-sm { gap: var(--space-sm); }
.flex { display: flex; }
.flex-col { flex-direction: column; }
.items-center { align-items: center; }
.justify-between { justify-content: space-between; }

/* === PREMIUM ACCENTS (Bond) === */
.gold-divider { height: 1px; background: var(--gold-gradient); }
.gold-border { border: 1px solid; border-image: var(--gold-border) 1; }
.section-premium { font-family: var(--font-serif); letter-spacing: 0.5px; }

/* === DARK SECTION (editorial hero) === */
.dark-section {
  background: var(--black);
  color: var(--white);
  padding: var(--space-xl) var(--space-md);
}
.dark-section h1, .dark-section h2 { color: var(--white); }
.dark-section p { color: rgba(255,255,255,0.7); }
.dark-section a { color: var(--gold-light); }

/* === FEED === */
main:has(.feed) { padding-top: var(--space-xs); padding-left: 0; padding-right: 0; }
.feed { padding: 0 0 100px; display: flex; flex-direction: column; gap: 12px; }

.card {
  background: #fff;
  border-radius: 12px;
  box-shadow: 0 1px 3px rgba(0,0,0,.08);
  overflow: hidden;
  position: relative;
}

.card-header {
  display: flex; align-items: center; gap: 8px;
  padding: 10px 12px;
  font-size: 13px;
}
.card-header img { width: 32px; height: 32px; border-radius: 50%; object-fit: cover; }

.card-username { font-weight: 700; color: #0f1111; text-decoration: none; }
.card-meta { color: #565959; }

.card-image { display: block; }
.card-image > img:first-child { width: 100%; display: block; }
/* Item-thumbnail collage for image-less "quick log" outfits (no hero photo). */
.outfit-collage { display: grid; gap: 2px; aspect-ratio: 1/1; width: 100%; background: var(--surface, #1a1a1a); }
.outfit-collage[data-count="1"] { grid-template-columns: 1fr; }
.outfit-collage[data-count="0"], .outfit-collage[data-count="2"] { grid-template-columns: 1fr 1fr; }
.outfit-collage[data-count="3"], .outfit-collage[data-count="4"] { grid-template-columns: 1fr 1fr; grid-template-rows: 1fr 1fr; }
.outfit-collage-cell { overflow: hidden; }
.outfit-collage-cell img { width: 100%; height: 100%; object-fit: cover; display: block; }
.outfit-collage[data-count="3"] .outfit-collage-cell:first-child { grid-column: span 2; }
.outfit-collage-empty { grid-column: 1 / -1; display: flex; align-items: center; justify-content: center; color: var(--muted, #888); font-size: 14px; }
.outfit-addimage-btn { position: absolute; bottom: var(--space-md); right: var(--space-md); background: rgba(0,0,0,.6); color: #fff; padding: 8px 14px; border-radius: 20px; font-size: 14px; cursor: pointer; }
.card-items { display: flex; gap: 6px; overflow-x: auto; padding: 6px 10px; margin-top: -56px; position: relative; z-index: 2; }
.card-items[hidden] { display: none; }
.card-item-thumb { flex-shrink: 0; }
.card-item-thumb img { width: 44px; height: 44px; border-radius: 8px; object-fit: cover; background: #fff; box-shadow: 0 2px 6px rgba(0,0,0,.4); }
.card-desc.clamped { display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; cursor: pointer; }
.see-more { display: none; font-size: .85rem; color: #888; text-decoration: none; }

.card-body { padding: 10px 12px 14px; font-size: 14px; line-height: 1.4; }
.card-body strong { display: block; margin-bottom: 4px; }
.card-body p { margin: 0; color: #333; }
.card-date { display: block; font-size: 12px; color: var(--gray-500); margin-top: 6px; }

/* Trigger A — event-recap credit ("✨ winning look … styled by @them") on the AI host's recap post. */
.card-recap-credit { font-size: 13px; color: var(--gray-600, #555); padding: 8px 14px 12px; line-height: 1.4; }
.card-recap-credit a { color: var(--accent, #c45500); font-weight: 600; text-decoration: none; }
.outfit-recap-credit { font-size: 14px; color: var(--gray-600, #555); margin: 8px 0 0; line-height: 1.5; }
.outfit-recap-credit a { color: var(--accent, #c45500); font-weight: 600; text-decoration: none; }

/* Event card */
.card-event-tall { min-height: 380px; display: flex; flex-direction: column; }
.card-event-body {
  display: block; padding: 12px;
  text-decoration: none; color: inherit;
  background: linear-gradient(135deg, #fef8f0, #fff8ee);
  margin: 0 12px 10px; border-radius: 8px;
}
.card-event-title { font-size: 16px; font-weight: 700; display: block; }
.card-event-body p { margin: 4px 0 0; color: #555; font-size: 13px; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.card-event-time { font-size: 12px; color: #c45500; font-weight: 600; margin-top: 6px; display: inline-block; }
.event-carousel { display: flex; overflow-x: auto; scroll-snap-type: x mandatory; gap: 12px; padding: 0 0 12px; flex: 1; -webkit-overflow-scrolling: touch; }
.event-carousel .event-slide:first-child { border-left: 12px solid transparent; }
.event-carousel::-webkit-scrollbar { display: none; }
.event-slide { scroll-snap-align: start; flex: 0 0 160px; display: flex; flex-direction: column; align-items: center; gap: 6px; }
.event-collage { display: grid; grid-template-columns: 1fr 1fr; gap: 3px; width: 160px; height: 160px; border-radius: 10px; overflow: hidden; }
.event-collage img { width: 100%; height: 100%; object-fit: cover; }
/* When a submission has a real AI collage hero, show it as one full-bleed image (override the 2x2 flat-lay grid). */
.event-collage-hero { display: block; }
.event-vote-btn { border: none; background: #f5f5f5; border-radius: 16px; padding: 4px 12px; font-size: 13px; font-weight: 600; cursor: pointer; }
.event-vote-btn.voted { background: #c45500; color: #fff; }
.event-sub-user { font-size: 11px; color: #888; }
.event-slide-footer { display: flex; align-items: center; gap: 6px; }
.event-slide-add { text-decoration: none; }
.event-add-btn { display: flex; flex-direction: column; align-items: center; justify-content: center; font-size: 40px; font-style: normal; color: #999; background: #f0f0f0; }
.event-add-btn span { font-style: normal; line-height: 1; }

/* "Just ended" shoppable-moment card (a finished event: final look + shop + follow). */
.card-just-ended { display: flex; flex-direction: column; }
.card-just-ended-body { display: block; text-decoration: none; color: inherit; padding: 4px 0 8px; }
.just-ended-badge { display: inline-block; background: #efe7ff; color: #6b3fb8; font-size: 11px; font-weight: 700; letter-spacing: .02em; padding: 2px 8px; border-radius: 12px; margin-bottom: 6px; }
.just-ended-collage { display: grid; grid-template-columns: 1fr 1fr; gap: 3px; width: 100%; max-width: 220px; aspect-ratio: 1/1; border-radius: 10px; overflow: hidden; }
.just-ended-collage img { width: 100%; height: 100%; object-fit: cover; }
.just-ended-footer { display: flex; gap: 8px; margin-top: 10px; flex-wrap: wrap; }
.just-ended-shop, .just-ended-follow { text-decoration: none; font-size: 13px; font-weight: 600; padding: 6px 12px; border-radius: 16px; }
.just-ended-shop { background: #c45500; color: #fff; }
.just-ended-follow { background: #f5f5f5; color: #333; }
.event-add-btn small { font-size: 11px; color: #555; font-style: normal; margin-top: 4px; }

/* Wardrobe-add digest card ("added N new pieces") */
.card-wardrobe-digest { display: flex; flex-direction: column; }
.wardrobe-digest-body { display: block; text-decoration: none; color: inherit; padding: 2px 12px 8px; }
.wardrobe-digest-headline { font-size: 15px; font-weight: 700; color: #222; line-height: 1.3; }
.wardrobe-digest-items { display: flex; gap: 6px; overflow-x: auto; padding: 2px 0 8px 12px; -webkit-overflow-scrolling: touch; }
.wardrobe-digest-items::-webkit-scrollbar { display: none; }
.wardrobe-digest-items img { width: 72px; height: 72px; flex: 0 0 auto; border-radius: 10px; object-fit: cover; background: #f2f2f2; }


/* New users carousel */
.new-users-title { font-size: 15px; font-weight: 700; padding: 12px 16px 4px; }
.new-users-carousel { display: flex; overflow-x: auto; gap: 12px; padding: 8px 16px 12px; -webkit-overflow-scrolling: touch; }
.new-users-carousel::-webkit-scrollbar { display: none; }
.new-user-chip { display: flex; flex-direction: column; align-items: center; gap: 4px; text-decoration: none; flex: 0 0 auto; }
.new-user-avatar { width: 72px; height: 72px; border-radius: 50%; object-fit: cover; }
.new-user-chip span { font-size: 11px; color: #555; white-space: nowrap; }

/* Need help card */
.need-help-title { font-size: 15px; font-weight: 700; padding: 12px 16px 8px; }
.need-help-row { display: flex; align-items: center; gap: 10px; padding: 8px 16px; text-decoration: none; color: inherit; }
.need-help-avatar { width: 44px; height: 44px; border-radius: 50%; object-fit: cover; flex-shrink: 0; }
.need-help-text { flex: 1; overflow: hidden; }
.need-help-text strong { display: block; font-size: 13px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.need-help-text span { display: block; font-size: 12px; color: #666; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.need-help-btn { width: 36px; height: 36px; border-radius: 10px; background: #f0f0f0; display: flex; align-items: center; justify-content: center; font-size: 18px; flex-shrink: 0; }
.card-action {
  display: block; text-align: center; padding: 10px;
  font-weight: 700; font-size: 14px; color: #c45500;
  text-decoration: none; border-top: 1px solid #f0f0f0;
}

/* User card */
.card-user-row {
  display: flex; align-items: center; gap: 12px;
  padding: 12px; text-decoration: none; color: inherit;
}
.card-user-avatar { width: 48px; height: 48px; min-width: 48px; min-height: 48px; border-radius: 50%; object-fit: cover; flex-shrink: 0; }
.card-user-info { min-width: 0; }
.card-user-info strong { display: block; font-size: 15px; color: #0f1111; }
.card-user-info .card-username { font-size: 13px; font-weight: 400; color: #565959; }
.card-user-info p { margin: 4px 0 0; font-size: 13px; color: #333; overflow: hidden; text-overflow: ellipsis; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; }

/* Loading indicator */
.feed-loading { text-align: center; padding: 20px; color: #888; font-size: 14px; }

/* Favorite button */
.card-fav {
  margin-left: auto; background: none; border: none;
  font-size: 22px; color: #aaa; cursor: pointer; padding: 0 4px;
  line-height: 1; transition: color .15s;
}
.card-fav.active { color: #e44; }
.card .card-fav { position: absolute; top: 18px; right: 12px; }
.card-share { background: none; border: none; font-size: 19px; color: #aaa; cursor: pointer; padding: 0 4px; line-height: 1; }
.card .card-share { position: absolute; top: 19px; right: 42px; }

/* Post page */
.post-page { padding: 24px 16px; }
.post-page h1 { font-size: 20px; margin: 0 0 16px; }
.post-types { display: flex; flex-direction: column; gap: 12px; }
.post-type-card { display: flex; align-items: center; gap: 12px; padding: 16px; border-radius: 12px; background: #f8f8f8; text-decoration: none; color: inherit; }
.post-type-card strong { display: block; font-size: 15px; }
.post-type-card span { font-size: 13px; color: #666; }

/* ═══════════ EVENT DETAIL PAGE ═══════════ */
.event-page { padding-bottom: 100px; }

/* Hero */
.event-hero-top { position: sticky; top: 44px; z-index: 11; background: #fff; display: flex; align-items: center; gap: 12px; padding: 10px 0; border-bottom: 1px solid #f0f0f0; }
.event-hero-avatar { flex: 0 0 auto; position: relative; display: inline-flex; }
.event-hero-avatar img { width: 40px; height: 40px; border-radius: 50%; object-fit: cover; }
.event-hero-title { font-size: 18px; margin: 0; line-height: 1.25; }
.event-hero-body { padding: 10px 0 14px; }
.event-hero-desc { font-size: 14px; color: #444; margin: 0 0 6px; }
.event-hero-meta { display: flex; gap: 10px; font-size: 12px; color: #888; }
.event-hero-timer { color: #c45500; font-weight: 600; }
.event-hero-ended { color: #999; font-weight: 600; }

/* Tabs */
.event-tabs { display: flex; border-bottom: 1px solid #eee; position: sticky; top: 105px; background: #fff; z-index: 10; }
.event-tabs a { flex: 1; text-align: center; padding: 12px 0; font-size: 13px; font-weight: 600; color: #888; text-decoration: none; border-bottom: 2px solid transparent; }
.event-tabs a.active { color: #000; border-bottom-color: #000; }

/* Empty state */
.event-empty { text-align: center; padding: 48px 24px; }
.event-empty-icon { font-size: 40px; margin: 0 0 8px; }
.event-empty p { color: #666; margin: 0 0 16px; }
.btn-primary { display: inline-block; background: #c45500; color: #fff; border: none; border-radius: 20px; padding: 10px 24px; font-size: 14px; font-weight: 600; text-decoration: none; cursor: pointer; }

/* Vote section */
.toast { position: fixed; left: 50%; bottom: 88px; transform: translateX(-50%); max-width: 88%; background: rgba(15,17,17,0.92); color: #fff; padding: 10px 16px; border-radius: 20px; font-size: 13px; line-height: 1.3; text-align: center; z-index: 200; box-shadow: 0 2px 12px rgba(0,0,0,0.25); animation: toast-in .2s ease; }
.toast-hide { opacity: 0; transition: opacity .4s ease; }
@keyframes toast-in { from { opacity: 0; transform: translateX(-50%) translateY(10px); } to { opacity: 1; transform: translateX(-50%) translateY(0); } }
.event-submissions { padding: 8px 0; }
.submission-card { padding: 16px; border-bottom: 1px solid #f0f0f0; }
.submission-leader { background: #fffbf5; }
.submission-header { display: flex; align-items: center; gap: 8px; margin-bottom: 10px; }
.submission-avatar { width: 28px; height: 28px; border-radius: 50%; object-fit: cover; }
.submission-user { font-size: 13px; font-weight: 600; flex: 1; }
.submission-badge { font-size: 14px; }
.submission-grid { display: flex; gap: 8px; overflow-x: auto; padding-bottom: 8px; -webkit-overflow-scrolling: touch; }
.submission-grid::-webkit-scrollbar { display: none; }
.submission-item img { width: 80px; height: 80px; border-radius: 8px; object-fit: cover; }
.submission-comment { font-size: 13px; color: #555; font-style: italic; margin: 8px 0 0; }
.submission-actions { display: flex; align-items: center; gap: 10px; margin-top: 10px; }
.vote-form { display: inline; }
.vote-btn { background: #f5f5f5; border: 1.5px solid #ddd; border-radius: 16px; padding: 6px 14px; font-size: 13px; font-weight: 600; cursor: pointer; color: #333; }
.vote-btn:active { background: #c45500; color: #fff; border-color: #c45500; }
.vote-count { font-size: 13px; color: #888; }
.vote-count.voted { color: #c45500; font-weight: 600; }
.vote-count.vote-own { color: var(--gray-400); cursor: default; }

/* Build section */
.event-build-ended { text-align: center; padding: 16px; color: #888; font-size: 14px; }
.build-preview { padding: 16px; background: #fafafa; border-bottom: 1px solid #eee; }
.build-preview-label { font-size: 13px; font-weight: 600; margin-bottom: 10px; }
.build-error { background: #fdecea; color: #b3261e; border: 1px solid #f5c6c0; padding: 8px 12px; border-radius: 10px; font-size: 13px; line-height: 1.35; margin-bottom: 10px; }
.build-empty { padding: 24px; text-align: center; border: 2px dashed #ddd; border-radius: 12px; }
.build-empty p { color: #999; margin: 0; font-size: 14px; }
.build-items { display: flex; gap: 8px; overflow-x: auto; padding: 8px 0 10px; -webkit-overflow-scrolling: touch; }
.build-items::-webkit-scrollbar { display: none; }
.build-item { position: relative; flex: 0 0 auto; }
.build-item img { width: 64px; height: 64px; border-radius: 8px; object-fit: cover; }
.build-item-remove { position: absolute; top: -6px; right: -6px; width: 20px; height: 20px; border-radius: 50%; background: #333; color: #fff; border: none; font-size: 12px; line-height: 1; cursor: pointer; }
.build-submit-form { display: flex; gap: 8px; margin-top: 12px; align-items: center; }
.build-submit-form .btn-primary { white-space: nowrap; padding: 0 16px; font-size: 13px; height: 38px; line-height: 38px; box-sizing: border-box; }
.build-comment-input { flex: 1; border: 1px solid #ddd; border-radius: 20px; padding: 0 14px; font-size: 14px; outline: none; height: 38px; box-sizing: border-box; }
.build-wardrobe { padding: 12px 16px; }
.build-cats { display: flex; gap: 8px; overflow-x: auto; padding-bottom: 10px; -webkit-overflow-scrolling: touch; }
.build-cats::-webkit-scrollbar { display: none; }
.build-cat { padding: 6px 14px; border-radius: 16px; background: #f0f0f0; font-size: 13px; font-weight: 500; text-decoration: none; color: #555; white-space: nowrap; }
.build-cat.active { background: #000; color: #fff; }
.build-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; }
.build-grid-empty { grid-column: 1/-1; text-align: center; color: #999; padding: 24px; }
.build-grid-item button { border: none; background: none; padding: 0; cursor: pointer; width: 100%; }
.build-grid-item img { width: 100%; aspect-ratio: 1; border-radius: 8px; object-fit: cover; }
.build-grid-item-ext button { position: relative; }
.build-ext-label { position: absolute; bottom: 4px; left: 4px; right: 4px; background: rgba(0,0,0,0.6); color: #fff; font-size: 10px; border-radius: 4px; padding: 2px 4px; text-align: center; }
.build-item-external { border: 2px solid #c45500; border-radius: 10px; }
.build-ext-badge { position: absolute; bottom: 2px; left: 2px; font-size: 12px; }
.build-suggest-hint { font-size: 12px; color: #888; margin: 0 0 10px; }
.build-suggest-section { margin-top: 16px; padding-top: 12px; border-top: 1px dashed #ddd; }
.build-grid-item-shop button { position: relative; opacity: 0.7; }
.build-shop-label { position: absolute; bottom: 4px; left: 4px; right: 4px; background: rgba(196,85,0,0.85); color: #fff; font-size: 10px; border-radius: 4px; padding: 2px 4px; text-align: center; }

/* ── Outfit collage (shared build-collage partial: builder previews + event voting) ── */
/* A white-background flat-lay: products are laid out (object-fit: contain, never cropped) on a clean
   card, with the first piece featured larger for visual interest. */
.build-collage { display: grid; gap: 6px; background: #fff; border: 1px solid #ececec; border-radius: 14px; padding: 8px; aspect-ratio: 1 / 1; grid-template-columns: repeat(2, 1fr); grid-auto-rows: 1fr; box-shadow: 0 1px 4px rgba(0,0,0,0.06); }
.build-collage[data-count="1"] { grid-template-columns: 1fr; }
/* AI-generated collage hero for a submission (square, matches the flat-lay card framing). */
.submission-hero { display: block; width: 100%; aspect-ratio: 1 / 1; object-fit: cover; border-radius: 14px; border: 1px solid #ececec; box-shadow: 0 1px 4px rgba(0,0,0,0.06); }
.build-collage[data-count="5"], .build-collage[data-count="6"], .build-collage[data-count="7"], .build-collage[data-count="8"] { grid-template-columns: repeat(3, 1fr); }
/* Featured hero (first piece) — only for counts that tile cleanly into the square. */
.build-collage[data-count="3"] .build-collage-cell:first-child { grid-row: span 2; }
.build-collage[data-count="6"] .build-collage-cell:first-child { grid-column: span 2; grid-row: span 2; }
.build-collage-cell { position: relative; background: #fff; border-radius: 8px; overflow: hidden; display: flex; align-items: center; justify-content: center; min-width: 0; min-height: 0; }
.build-collage-cell img { width: 100%; height: 100%; object-fit: contain; display: block; }
.build-collage-cell-empty { font-size: 28px; opacity: 0.25; }
.build-collage-cell-ext { box-shadow: inset 0 0 0 2px #c45500; border-radius: 8px; }
.build-collage-badge { position: absolute; top: 4px; left: 4px; font-size: 13px; filter: drop-shadow(0 1px 1px rgba(0,0,0,0.35)); }
.build-collage-remove-form { position: absolute; top: 4px; right: 4px; margin: 0; }
.build-collage-remove { width: 22px; height: 22px; border-radius: 50%; background: rgba(0,0,0,0.6); color: #fff; border: none; font-size: 14px; line-height: 1; cursor: pointer; display: flex; align-items: center; justify-content: center; padding: 0; }

/* "Magically enhancing" opportunistic builder collage: indicator + swapped-in AI hero. */
#build-collage-wrap { position: relative; }
.build-collage-hero { display: block; width: 100%; aspect-ratio: 1 / 1; object-fit: cover; border-radius: 14px; border: 1px solid #ececec; box-shadow: 0 1px 4px rgba(0,0,0,0.06); }
.collage-enhancing { display: flex; align-items: center; justify-content: center; gap: 7px; margin-top: 8px; font-size: 13px; color: #6b3fa0; }
/* The HTML `hidden` attribute must win over the author display:flex above (same [hidden]-vs-author
   footgun as .card-items[hidden]) — else the indicator lingers after the collage swaps in. */
.collage-enhancing[hidden] { display: none; }
.collage-enhancing-spinner { width: 13px; height: 13px; border: 2px solid #d9c7ef; border-top-color: #6b3fa0; border-radius: 50%; animation: collage-spin 0.8s linear infinite; }
@keyframes collage-spin { to { transform: rotate(360deg); } }

/* ── Built-outfit carousel (shared component: event submissions + notifications) ──
   A horizontally-swipeable scroll-snap carousel of up-to-3 square cards (collage · VTO · shop). */
.boc { position: relative; }
.boc-track { display: flex; overflow-x: auto; scroll-snap-type: x mandatory; -webkit-overflow-scrolling: touch; scrollbar-width: none; }
.boc-track::-webkit-scrollbar { display: none; }
.boc-slide { flex: 0 0 100%; scroll-snap-align: start; min-width: 0; }
/* Collage / VTO hero — square, matches the flat-lay card framing. */
.boc-hero { display: block; width: 100%; aspect-ratio: 1 / 1; object-fit: cover; border-radius: 14px; border: 1px solid #ececec; box-shadow: 0 1px 4px rgba(0,0,0,0.06); }
/* Shoppable grid card — the pieces as product thumbnails on a clean white card (home outfit-card aesthetic). */
.boc-shop { aspect-ratio: 1 / 1; background: #fff; border: 1px solid #ececec; border-radius: 14px; box-shadow: 0 1px 4px rgba(0,0,0,0.06); padding: 10px; display: grid; grid-template-columns: repeat(3, 1fr); grid-auto-rows: min-content; gap: 8px; align-content: start; overflow-y: auto; box-sizing: border-box; }
.boc-shop-item { position: relative; aspect-ratio: 1; border-radius: 8px; overflow: hidden; background: #f7f7f7; display: flex; align-items: center; justify-content: center; }
.boc-shop-item img { width: 100%; height: 100%; object-fit: contain; display: block; }
.boc-shop-empty { font-size: 24px; opacity: 0.25; }
.boc-shop-tag { position: absolute; bottom: 0; left: 0; right: 0; background: rgba(196,85,0,.85); color: #fff; font-size: 9px; font-weight: 600; text-align: center; padding: 1px 0; letter-spacing: .03em; }
/* Dot indicators (decoration — the carousel swipes without JS; built-outfit-carousel.js syncs the active dot). */
.boc-dots { display: flex; justify-content: center; gap: 6px; margin-top: 8px; }
.boc-dot { width: 6px; height: 6px; border-radius: 50%; background: #d4d4d4; cursor: pointer; transition: background .15s, transform .15s; }
.boc-dot.active { background: #c45500; transform: scale(1.25); }

/* Discuss section */
.discuss-thread { padding: 16px; display: flex; flex-direction: column; gap: 12px; }
.discuss-msg { display: flex; gap: 8px; align-items: flex-start; }
.discuss-avatar { width: 32px; height: 32px; border-radius: 50%; object-fit: cover; }
.discuss-bubble { background: #f5f5f5; border-radius: 14px; padding: 8px 12px; max-width: 80%; }
.discuss-user { font-size: 11px; font-weight: 600; color: #888; }
.discuss-bubble p { margin: 2px 0 0; font-size: 14px; }
.discuss-input { display: flex; gap: 8px; padding: 12px 16px; border-top: 1px solid #eee; position: sticky; bottom: 60px; background: #fff; }
.discuss-field { flex: 1; border: 1px solid #ddd; border-radius: 20px; padding: 8px 14px; font-size: 14px; outline: none; }
.discuss-send { width: 36px; height: 36px; border-radius: 50%; background: #c45500; color: #fff; border: none; font-size: 16px; font-weight: 700; cursor: pointer; }

/* ═══════════ OUTFIT DETAIL PAGE ═══════════ */
.outfit-page { padding: 0 0 100px; }
.outfit-image-wrap { position: relative; width: 100%; }
.outfit-hero-img { width: 100%; display: block; }
.outfit-nav { position: absolute; top: 50%; transform: translateY(-50%); width: 36px; height: 36px; border-radius: 50%; background: rgba(255,255,255,0.85); display: flex; align-items: center; justify-content: center; font-size: 20px; color: #333; text-decoration: none; box-shadow: 0 1px 4px rgba(0,0,0,0.15); }
.outfit-nav-prev { left: 10px; }
.outfit-nav-next { right: 10px; }

.outfit-author { display: flex; align-items: center; gap: 10px; padding: 12px 16px; }
.outfit-author-avatar { width: 36px; height: 36px; border-radius: 50%; object-fit: cover; }
.outfit-author-info { flex: 1; }
.outfit-author-name { font-size: 14px; font-weight: 600; text-decoration: none; color: #000; display: block; }
.outfit-author-date { font-size: 12px; color: #888; }
.outfit-fav-btn { border: none; background: none; font-size: 24px; cursor: pointer; padding: 4px; }
.outfit-fav-active { color: #e33; }
.outfit-edit-btn { font-size: 13px; color: #c45500; text-decoration: none; font-weight: 600; }

.outfit-body { padding: 0 16px 12px; }
.outfit-title { font-size: 20px; margin: 0 0 6px; }
.outfit-desc { font-size: 14px; color: #444; margin: 0; line-height: 1.5; }
/* Private (owner-only) outfit indicator + post toggle */
.outfit-private-badge { display: inline-block; font-size: 11px; font-weight: 600; color: #555; background: #eee; border-radius: 10px; padding: 2px 8px; vertical-align: middle; }
.outfit-private-toggle { display: flex; align-items: center; gap: 8px; font-size: 14px; color: #444; padding: 4px 2px; cursor: pointer; }
.outfit-private-toggle input { width: 18px; height: 18px; }

.outfit-items-section { padding: 12px 16px; border-top: 1px solid #f0f0f0; }
.outfit-items-title { font-size: 14px; font-weight: 700; margin: 0 0 10px; }
.outfit-items-grid { display: flex; gap: 10px; overflow-x: auto; -webkit-overflow-scrolling: touch; padding-bottom: 4px; }
.outfit-items-grid::-webkit-scrollbar { display: none; }
.outfit-item-card { flex: 0 0 100px; text-decoration: none; color: inherit; }
.outfit-item-card img { width: 100px; height: 100px; border-radius: 10px; object-fit: cover; }
.outfit-item-name { display: block; font-size: 11px; font-weight: 600; margin-top: 4px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; max-width: 100px; }
.outfit-item-brand { display: block; font-size: 10px; color: #888; }

.outfit-comments-section { padding: 12px 16px; border-top: 1px solid #f0f0f0; }
.outfit-comments-title { font-size: 14px; font-weight: 700; margin: 0 0 12px; }
.outfit-no-comments { font-size: 13px; color: #999; }
.outfit-comments-list { display: flex; flex-direction: column; gap: 10px; }
.outfit-comment { display: flex; gap: 8px; align-items: flex-start; }
.outfit-comment-avatar { width: 28px; height: 28px; border-radius: 50%; object-fit: cover; }
.outfit-comment-bubble { background: #f5f5f5; border-radius: 14px; padding: 8px 12px; max-width: 80%; }
.outfit-comment-user { font-size: 11px; font-weight: 600; color: #888; }
.outfit-comment-bubble p { margin: 2px 0 0; font-size: 14px; }
.outfit-comment-form { display: flex; gap: 8px; margin-top: 12px; }
.outfit-comment-input { flex: 1; border: 1px solid #ddd; border-radius: 20px; padding: 8px 14px; font-size: 14px; outline: none; }
.outfit-comment-send { width: 36px; height: 36px; border-radius: 50%; background: #c45500; color: #fff; border: none; font-size: 16px; font-weight: 700; cursor: pointer; }

/* ═══════════ ME PAGE ═══════════ */
.me-page { padding-bottom: 100px; }
.me-profile { display: flex; flex-direction: column; align-items: center; padding: 24px 16px 12px; }
.me-avatar { width: 72px; height: 72px; border-radius: 50%; object-fit: cover; }
.me-avatar-wrap { position: relative; cursor: pointer; }
.me-avatar-edit { position: absolute; bottom: 0; right: 0; width: 24px; height: 24px; background: #fff; border-radius: 50%; display: flex; align-items: center; justify-content: center; font-size: 12px; box-shadow: 0 1px 3px rgba(0,0,0,0.2); }
.me-name { font-size: 18px; margin: 8px 0 2px; }
.me-points { font-size: 13px; color: #c45500; font-weight: 600; }
.me-edit { font-size: 12px; color: #888; text-decoration: none; margin-top: 4px; }

.me-actions { display: flex; gap: 8px; padding: 0 16px 16px; justify-content: center; }
.me-action-btn { padding: 8px 14px; border-radius: 18px; background: #f0f0f0; font-size: 13px; font-weight: 600; text-decoration: none; color: #333; }

.me-section { padding: 12px 16px; border-top: 1px solid #f0f0f0; }
.me-section-header { display: flex; justify-content: space-between; align-items: center; margin-bottom: 10px; }
.me-section-header h2 { font-size: 16px; margin: 0; }
.me-section-header a { font-size: 13px; color: #c45500; text-decoration: none; }

.me-outfit-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 4px; }
.me-outfit-thumb img { width: 100%; aspect-ratio: 1; object-fit: cover; border-radius: 6px; }

.me-events-list { display: flex; flex-direction: column; gap: 6px; }
.me-event-row { display: flex; justify-content: space-between; align-items: center; padding: 10px 12px; background: #fafafa; border-radius: 10px; text-decoration: none; color: inherit; }

/* === My Events page === */
.events-page { padding-bottom: 100px; }
.events-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 4px; }
.events-h1 { font-size: 24px; margin: 0; }
.events-new-btn { flex: 0 0 auto; font-size: 13px; font-weight: 600; padding: 8px 14px; border-radius: 16px; background: var(--black); color: #fff; text-decoration: none; white-space: nowrap; }
.events-section { margin-top: 20px; }
.events-section-title { font-size: 12px; font-weight: 700; text-transform: uppercase; letter-spacing: .5px; color: var(--gray-500); margin: 0 0 10px; }
.events-count { display: inline-block; min-width: 18px; padding: 0 5px; margin-left: 4px; border-radius: 9px; background: var(--gray-100); color: var(--gray-600); font-size: 11px; font-weight: 700; text-align: center; }
.ev-card { background: #fff; border: 1px solid var(--gray-200); border-radius: 14px; padding: 14px; margin-bottom: 10px; box-shadow: 0 1px 3px rgba(0,0,0,.05); }
.ev-card-ended { background: var(--gray-50); }
.ev-card-top { display: flex; align-items: flex-start; gap: 8px; }
.ev-card-title { flex: 1; font-size: 16px; font-weight: 700; color: var(--black); text-decoration: none; line-height: 1.3; }
.ev-badge { flex: 0 0 auto; font-size: 11px; font-weight: 700; padding: 3px 9px; border-radius: 11px; white-space: nowrap; }
.ev-badge-active { background: #fde9d9; color: #c45500; }
.ev-badge-ended { background: var(--gray-200); color: var(--gray-600); }
.ev-card-meta { font-size: 13px; color: var(--gray-500); margin: 6px 0 0; }
.ev-card-meta-empty { font-style: italic; }
.ev-leading { margin-top: 10px; }
.ev-leading-label { display: inline-block; font-size: 12px; font-weight: 600; color: #c45500; margin-bottom: 6px; }
.ev-winner-label { color: var(--gold-dark); }
.ev-thumbs { display: flex; gap: 6px; flex-wrap: wrap; }
.ev-thumbs img { width: 48px; height: 48px; border-radius: 8px; object-fit: cover; background: var(--gray-100); border: 1px solid var(--gray-200); display: block; }
.ev-card-actions { display: flex; align-items: center; gap: 8px; margin-top: 12px; }
.ev-action { font-size: 13px; font-weight: 600; padding: 7px 14px; border-radius: 16px; text-decoration: none; border: 1px solid var(--gray-300); color: var(--black); }
.ev-action-primary { background: var(--black); color: #fff; border-color: var(--black); }
.ev-delete-form { margin-left: auto; }
.ev-postlook-form { display: contents; }
.ev-delete { background: var(--gray-100); border: none; border-radius: 50%; width: 32px; height: 32px; font-size: 14px; color: var(--gray-500); cursor: pointer; line-height: 1; flex: 0 0 auto; }
.events-empty { text-align: center; padding: 56px 24px; }
.events-empty-icon { font-size: 44px; margin-bottom: 12px; }
.events-empty-title { font-size: 17px; font-weight: 700; margin: 0 0 6px; }
.events-empty-sub { font-size: 14px; color: var(--gray-500); margin: 0 0 18px; }
.me-event-title { font-size: 14px; font-weight: 500; }
.me-event-time { font-size: 12px; color: #c45500; font-weight: 600; }

.me-empty { font-size: 13px; color: #999; }
.me-empty a { color: #c45500; }

.me-inbox { display: flex; flex-direction: column; gap: 6px; }
.me-inbox-item { font-size: 13px; color: #555; padding: 8px 0; border-bottom: 1px solid #f5f5f5; }

/* ═══════════ ITEM DETAIL PAGE ═══════════ */
.item-page { padding-bottom: 100px; }
.item-image-wrap { width: 100%; background: #f8f8f8; display: flex; justify-content: center; }
.item-hero-img { width: 100%; max-height: 400px; object-fit: contain; }

.item-owner { display: flex; align-items: center; gap: 10px; padding: 12px 16px; }
.item-owner-avatar { width: 32px; height: 32px; border-radius: 50%; object-fit: cover; }
.item-owner-name { flex: 1; font-size: 13px; font-weight: 600; color: #333; text-decoration: none; }
.item-wish-btn { border: none; background: none; font-size: 22px; cursor: pointer; }
.item-shop-btn { font-size: 20px; text-decoration: none; }
.item-shop-linked { background: #f0f8e8; border-radius: 50%; width: 32px; height: 32px; display: flex; align-items: center; justify-content: center; }
.item-wish-active { color: #e33; }
.item-edit-link { font-size: 13px; color: #c45500; text-decoration: none; font-weight: 600; }

.item-body { padding: 0 16px 12px; }
.item-title { font-size: 20px; margin: 0 0 4px; }
.item-brand { font-size: 14px; color: #888; }
.item-details { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 10px; }
.item-tag { padding: 4px 10px; border-radius: 12px; background: #f0f0f0; font-size: 12px; color: #555; }
.item-desc { font-size: 14px; color: #444; margin: 12px 0 0; line-height: 1.5; }

.item-outfits-section { padding: 12px 16px; border-top: 1px solid #f0f0f0; }
.item-outfits-section h3 { font-size: 14px; font-weight: 700; margin: 0 0 10px; }
.item-outfits-row { display: flex; gap: 8px; overflow-x: auto; -webkit-overflow-scrolling: touch; }
.item-outfits-row::-webkit-scrollbar { display: none; }
.item-outfit-thumb img { width: 104px; aspect-ratio: 3/4; height: auto; border-radius: 8px; object-fit: cover; display: block; }

.item-comments-section { padding: 12px 16px; border-top: 1px solid #f0f0f0; }
.item-comments-section h3 { font-size: 14px; font-weight: 700; margin: 0 0 12px; }

/* ═══════════ WARDROBE PAGE ═══════════ */
.wardrobe-page { padding-bottom: 100px; }

.wardrobe-tips { padding: 10px 16px; background: #fafafa; border-top: 1px solid #f0f0f0; border-bottom: 1px solid #f0f0f0; }
.closet-starter { margin: 16px; padding: 20px 18px; border-radius: 16px; background: linear-gradient(160deg, #fffdf7, #fbf5e9); border: 1px solid var(--gold-light); text-align: center; }
.closet-starter-title { font-family: var(--font-serif); font-size: 20px; font-weight: 400; margin: 0 0 6px; color: var(--black); }
.closet-starter-sub { font-size: 14px; color: var(--gray-600); margin: 0 0 14px; }
.closet-starter-sub strong { color: var(--gold-dark); }
.closet-starter-feats { list-style: none; margin: 0 auto 16px; padding: 0; max-width: 320px; text-align: left; display: flex; flex-direction: column; gap: 10px; }
.closet-starter-feats li { font-size: 13px; color: var(--gray-600); line-height: 1.35; display: flex; gap: 8px; align-items: flex-start; }
.closet-starter-feat-text { flex: 1; }
.closet-starter-feats li strong { color: var(--black); }
.closet-starter-ico { flex: 0 0 auto; }
.closet-starter-cta { display: inline-block; padding: 11px 26px; border-radius: 24px; background: var(--black); color: #fff; font-size: 14px; font-weight: 600; text-decoration: none; }
.wardrobe-tips-title { font-size: 14px; font-weight: 600; margin: 0 0 6px; }
.wardrobe-tips-sub { font-size: 13px; color: #888; margin: 0; }
.wardrobe-sync-row { display: flex; gap: 8px; overflow-x: auto; }
.wardrobe-sync-row::-webkit-scrollbar { display: none; }
.wardrobe-sync-btn { padding: 8px 12px; border-radius: 16px; background: #fff; border: 1px solid #ddd; font-size: 12px; text-decoration: none; color: #333; white-space: nowrap; }

/* Wardrobe cleanout / replace */
.wardrobe-cleanout-cta { display: flex; align-items: center; justify-content: space-between; gap: 8px; padding: 10px 14px; margin-bottom: 10px; border-radius: 12px; background: linear-gradient(90deg,#fff7ed,#fef2f2); border: 1px solid #fde0c8; font-size: 14px; font-weight: 600; color: #9a3412; text-decoration: none; }
.wardrobe-cleanout-arrow { font-size: 16px; }
.cleanout-page { padding: 16px; max-width: 720px; margin: 0 auto 80px; }
.cleanout-title { font-size: 22px; margin: 4px 0 2px; }
.cleanout-sub { font-size: 14px; color: #666; margin: 0 0 16px; }
.cleanout-list { display: flex; flex-direction: column; gap: 12px; }
.cleanout-card { display: flex; gap: 12px; background: #fff; border: 1px solid #eee; border-left-width: 4px; border-radius: 12px; padding: 12px; box-shadow: 0 1px 6px rgba(0,0,0,.04); }
.cleanout-card.cleanout-cleanout { border-left-color: #f59e0b; }
.cleanout-card.cleanout-replace { border-left-color: #3b82f6; }
.cleanout-card.cleanout-keep { border-left-color: #10b981; }
.cleanout-itemimg { flex: 0 0 72px; width: 72px; height: 72px; border-radius: 10px; overflow: hidden; background: #f3f3f3; display: flex; align-items: center; justify-content: center; }
.cleanout-itemimg img { width: 100%; height: 100%; object-fit: cover; }
.cleanout-thumb-empty { font-size: 10px; color: #999; padding: 4px; text-align: center; }
.cleanout-body { flex: 1; min-width: 0; }
.cleanout-head { display: flex; align-items: center; gap: 8px; margin-bottom: 4px; }
.cleanout-badge { font-size: 11px; font-weight: 700; padding: 2px 8px; border-radius: 10px; text-transform: uppercase; letter-spacing: .3px; }
.cleanout-badge-cleanout { background: #fef3c7; color: #92400e; }
.cleanout-badge-replace { background: #dbeafe; color: #1e40af; }
.cleanout-badge-keep { background: #d1fae5; color: #065f46; }
.cleanout-itemname { font-size: 14px; font-weight: 600; color: #222; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.cleanout-reason { font-size: 13px; color: #555; margin: 4px 0 0; line-height: 1.4; }
.cleanout-replacements { margin-top: 10px; }
.cleanout-replace-label { font-size: 12px; font-weight: 600; color: #1e40af; }
.cleanout-replace-thumbs { display: flex; gap: 8px; margin-top: 6px; overflow-x: auto; }
.cleanout-replace-thumb { flex: 0 0 auto; width: 96px; text-decoration: none; color: #333; }
.cleanout-replace-thumb img { width: 96px; height: 96px; object-fit: cover; border-radius: 8px; background: #f3f3f3; }
.cleanout-replace-name { display: block; font-size: 11px; color: #555; margin-top: 4px; line-height: 1.3; }
.cleanout-foot { margin-top: 18px; font-size: 13px; }
.cleanout-foot a, .cleanout-page .event-empty a { color: #666; }

/* Wardrobe gap recommendations (shop the gaps) */
.gaps-page { padding: 16px; max-width: 720px; margin: 0 auto 80px; }
.gaps-title { font-size: 22px; margin: 4px 0 2px; }
.gaps-sub { font-size: 14px; color: #666; margin: 0 0 16px; }
.gaps-list { display: flex; flex-direction: column; gap: 12px; }
.gaps-card { background: #fff; border: 1px solid #eee; border-left: 4px solid #8b5cf6; border-radius: 12px; padding: 12px; box-shadow: 0 1px 6px rgba(0,0,0,.04); }
.gaps-head { display: flex; align-items: center; gap: 8px; margin-bottom: 4px; }
.gaps-badge { font-size: 11px; font-weight: 700; padding: 2px 8px; border-radius: 10px; text-transform: uppercase; letter-spacing: .3px; background: #ede9fe; color: #5b21b6; }
.gaps-reason { font-size: 13px; color: #555; margin: 4px 0 0; line-height: 1.4; }
.gaps-products { display: flex; gap: 8px; margin-top: 10px; overflow-x: auto; }
.gaps-product { flex: 0 0 auto; width: 96px; text-decoration: none; color: #333; }
.gaps-product img { width: 96px; height: 96px; object-fit: cover; border-radius: 8px; background: #f3f3f3; }
.gaps-thumb-empty { display: flex; align-items: center; justify-content: center; width: 96px; height: 96px; border-radius: 8px; background: #f3f3f3; font-size: 10px; color: #999; text-align: center; }
.gaps-product-name { display: block; font-size: 11px; color: #555; margin-top: 4px; line-height: 1.3; }
.gaps-foot { margin-top: 18px; font-size: 13px; }
.gaps-foot a, .gaps-page .event-empty a:not(.btn-primary) { color: #666; }

.wardrobe-filters { padding: 10px 8px; position: sticky; top: 44px; background: #fff; z-index: 5; }
.wardrobe-cats { display: flex; gap: 8px; overflow-x: auto; -webkit-overflow-scrolling: touch; }
.wardrobe-cats::-webkit-scrollbar { display: none; }

.wardrobe-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 3px; padding: 0 3px; }
.wardrobe-item img { width: 100%; aspect-ratio: 1; object-fit: cover; border-radius: 4px; display: block; }

.wardrobe-fab { position: fixed; bottom: 80px; right: 20px; width: 52px; height: 52px; border-radius: 50%; background: #c45500; display: flex; align-items: center; justify-content: center; font-size: 22px; text-decoration: none; box-shadow: 0 3px 10px rgba(0,0,0,0.2); z-index: 50; }

.wardrobe-organizing { display: inline-flex; align-items: center; gap: 4px; font-size: 12px; color: #666; padding: 6px 8px; }
.wardrobe-organizing .ai-spinner { display: inline-block; animation: spin 1s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }
.wardrobe-section-label { font-size: 13px; font-weight: 700; color: #333; padding: 14px 3px 6px; }
.wardrobe-bucket { margin-bottom: 10px; }
.wardrobe-bucket-count { font-size: 13px; font-weight: 500; color: #999; }

/* ═══════════ ACCOUNT/EDIT PROFILE ═══════════ */
.account-page { padding: 0 16px 100px; }
.account-title { font-size: 20px; margin: 16px 0 12px; }
.account-error { color: #c00; font-size: 13px; }
.account-avatar-section { display: flex; justify-content: center; margin-bottom: 16px; }
.account-avatar-wrap { position: relative; cursor: pointer; }
.account-avatar { width: 80px; height: 80px; border-radius: 50%; object-fit: cover; }
.account-avatar-badge { position: absolute; bottom: 0; right: 0; width: 26px; height: 26px; background: #fff; border-radius: 50%; display: flex; align-items: center; justify-content: center; font-size: 13px; box-shadow: 0 1px 3px rgba(0,0,0,0.2); }
.account-form { display: flex; flex-direction: column; gap: 14px; margin-bottom: 24px; }
.account-form-pw { border-top: 1px solid #eee; padding-top: 20px; }
.account-subtitle { font-size: 16px; margin: 0; }
.account-field { display: flex; flex-direction: column; gap: 4px; }
.account-field span { font-size: 12px; font-weight: 600; color: #555; }
.account-field input, .account-field textarea { width: 100%; border: 1px solid #ddd; border-radius: 10px; padding: 10px 12px; font-size: 16px; outline: none; box-sizing: border-box; }
.account-field textarea { resize: vertical; }
.account-save { width: 100%; padding: 12px; font-size: 15px; margin-top: 4px; }

/* Thanks page */
.thanks-page { padding-bottom: 100px; }
.thanks-hero { text-align: center; padding: 40px 24px 24px; }
.thanks-icon { font-size: 48px; margin: 0 0 8px; }
.thanks-hero h1 { font-size: 22px; margin: 0 0 6px; }
.thanks-sub { font-size: 14px; color: #666; margin: 0 0 20px; }
.thanks-actions { display: flex; flex-direction: column; gap: 12px; align-items: center; }
.thanks-link { font-size: 14px; color: #c45500; text-decoration: none; font-weight: 600; }
.thanks-more { padding: 16px; border-top: 1px solid #f0f0f0; }
.thanks-more h2 { font-size: 15px; font-weight: 700; margin: 0 0 12px; }

/* Search page */
.search-page { padding-bottom: 100px; }
.search-bar { padding: 12px 16px; position: sticky; top: 44px; background: #fff; z-index: 5; }
.search-bar input { width: 100%; border: 1px solid #ddd; border-radius: 20px; padding: 10px 16px; font-size: 16px; outline: none; box-sizing: border-box; background: #f8f8f8; }
.search-empty { text-align: center; color: #999; padding: 32px 16px; font-size: 14px; }
#search-results > div { display: flex; align-items: center; gap: 10px; padding: 10px 16px; border-bottom: 1px solid #f5f5f5; }
#search-results > div img { width: 44px; height: 44px; border-radius: 8px; object-fit: cover; }
#search-results > div a { text-decoration: none; color: inherit; }
#search-results > div > div:nth-child(2) { flex: 1; overflow: hidden; }
#search-results > div > div:nth-child(2) > div:first-child { font-size: 14px; font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
#search-results > div > div:nth-child(2) > div:nth-child(2) { font-size: 12px; color: #888; }
#search-results > div > span:last-child { font-size: 16px; }

/* ═══════════ PUBLIC PROFILE ═══════════ */
.profile-page { padding-bottom: 100px; }
.profile-header { display: flex; gap: 14px; padding: 20px 16px 14px; align-items: center; position: sticky; top: 38px; background: rgba(255,255,255,0.82); -webkit-backdrop-filter: saturate(180%) blur(14px); backdrop-filter: saturate(180%) blur(14px); z-index: 5; }
.profile-avatar { width: 72px; height: 72px; border-radius: 50%; object-fit: cover; }
.profile-info { flex: 1; }
.profile-name { font-size: 18px; margin: 0; }
.profile-handle { font-size: 13px; color: #888; }
.profile-location { font-size: 12px; color: #888; display: block; margin-top: 2px; }
.profile-storefront { display: inline-block; margin-top: 6px; font-size: 13px; font-weight: 600; color: #fff; background: #c45500; padding: 5px 12px; border-radius: 16px; text-decoration: none; }

.profile-stats { display: flex; justify-content: space-around; padding: 12px 16px; border-top: 1px solid #f0f0f0; border-bottom: 1px solid #f0f0f0; }
.profile-stat { text-align: center; }
.profile-stat strong { display: block; font-size: 16px; }
.profile-stat span { font-size: 11px; color: #888; }

.profile-actions { display: flex; gap: 10px; padding: 12px 16px; align-items: center; }
.profile-actions form { display: inline; }
.profile-follow-btn { height: 36px; padding: 0 20px; border-radius: 18px; background: #c45500; color: #fff; border: none; font-size: 14px; font-weight: 600; cursor: pointer; }
.profile-follow-btn.following { background: #fff; color: #333; border: 1px solid #ccc; }
.profile-action-link { height: 36px; line-height: 36px; padding: 0 16px; border-radius: 18px; background: #f0f0f0; text-align: center; font-size: 14px; font-weight: 600; text-decoration: none; color: #333; display: inline-block; box-sizing: border-box; }

.profile-bio { padding: 8px 16px 12px; }
.profile-bio p { font-size: 14px; color: #333; margin: 0 0 4px; line-height: 1.4; }
.profile-brands { font-size: 13px; color: #888; }

.profile-section { padding: 12px 16px; border-top: 1px solid #f0f0f0; }
.profile-outfit-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 6px; }
.profile-outfit-thumb { display: block; background: #fff; border: 1px solid var(--gray-300); border-radius: 10px; overflow: hidden; }
.profile-outfit-thumb img { width: 100%; aspect-ratio: 1; object-fit: contain; display: block; padding: 10px; }

.profile-following { display: flex; gap: 12px; overflow-x: auto; -webkit-overflow-scrolling: touch; }
.profile-following::-webkit-scrollbar { display: none; }
.profile-follow-chip { display: flex; flex-direction: column; align-items: center; gap: 4px; text-decoration: none; }
.profile-follow-chip img { width: 48px; height: 48px; border-radius: 50%; object-fit: cover; }
.profile-follow-chip span { font-size: 11px; color: #555; }

.profile-outfit-feed { display: flex; flex-direction: column; gap: 12px; }
.profile-outfit-feed .card { margin: 0; border-radius: 0; box-shadow: none; }
.profile-outfit-feed .card-image img { width: 100%; display: block; }
.profile-outfit-feed .card-body { padding: 10px 16px; }
.profile-outfit-feed .card-title { font-size: 15px; }
.profile-outfit-feed .card-desc { font-size: 13px; color: #555; margin: 4px 0 0; }

/* Comment replies */
.reply-btn { border: none; background: none; font-size: 11px; color: #888; cursor: pointer; padding: 2px 0; margin-top: 2px; }
.reply-form { display: flex; gap: 8px; margin: 4px 0 8px 36px; }
.discuss-reply, .outfit-comment-reply { margin-left: 36px; }

/* ═══════════ NOTIFICATIONS ═══════════ */
.notif-page { padding: 0 0 100px; }
.notif-title { font-size: 20px; padding: 16px 16px 8px; margin: 0; }
.notif-empty { text-align: center; padding: 48px 24px; }
.notif-empty-icon { font-size: 40px; margin: 0 0 8px; }
.notif-empty p { color: #888; margin: 0; }
.notif-list { display: flex; flex-direction: column; }
.notif-item { display: flex; align-items: flex-start; gap: 12px; padding: 14px 16px; border-bottom: 1px solid #f5f5f5; }
.notif-icon { width: 32px; height: 32px; border-radius: 50%; background: #f0f0f0; display: flex; align-items: center; justify-content: center; font-size: 14px; flex-shrink: 0; }
.notif-content { flex: 1; }
.notif-text { font-size: 14px; margin: 0 0 2px; line-height: 1.4; }
.notif-time { font-size: 11px; color: #999; }
.notif-outfit { margin: 8px 0; max-width: 260px; }
.notif-dismiss { flex-shrink: 0; }
.notif-dismiss button { border: none; background: none; color: #ccc; font-size: 16px; cursor: pointer; padding: 4px; }

/* Connections */
.connections-list { display: flex; flex-direction: column; }
.connection-row { display: flex; align-items: center; gap: 10px; padding: 10px 0; text-decoration: none; color: inherit; border-bottom: 1px solid #f5f5f5; }
.connection-icon { width: 32px; height: 32px; border-radius: 8px; background: #f0f0f0; display: flex; align-items: center; justify-content: center; font-size: 16px; flex-shrink: 0; }
.connection-info { flex: 1; }
.connection-info strong { display: block; font-size: 14px; }
.connection-status { font-size: 12px; color: #888; }
.connection-badge { color: #2a7; font-weight: 700; font-size: 14px; }
.connection-cta { font-size: 13px; color: #c45500; font-weight: 600; }
.connection-active { background: #f8fdf8; border-radius: 8px; padding: 10px; margin-bottom: 4px; }
.connection-sub { flex-direction: column; align-items: flex-start; gap: 4px; padding: 4px 10px 10px; }
.connection-detail { font-size: 12px; color: #888; }

/* ═══════════ CAMERA POST ═══════════ */
.camera-page { padding-bottom: 80px; }
.camera-area { position: relative; width: 100%; aspect-ratio: 3/4; background: #000; overflow: hidden; }
.camera-area video, .camera-area img { width: 100%; height: 100%; object-fit: cover; }
.camera-controls { position: absolute; bottom: 20px; left: 0; right: 0; display: flex; justify-content: space-around; align-items: center; padding: 0 40px; }
.camera-shutter { width: 64px; height: 64px; border-radius: 50%; border: 4px solid #fff; background: rgba(255,255,255,0.3); cursor: pointer; }
.camera-shutter:active { background: rgba(255,255,255,0.7); }
.camera-lib-btn { cursor: pointer; }
.camera-flip { border: none; background: none; cursor: pointer; }
.camera-retake { position: absolute; bottom: 20px; left: 0; right: 0; display: flex; justify-content: center; gap: 12px; padding: 0 24px; }
.camera-results { padding: 16px; }
.camera-results-header h2 { font-size: 16px; margin: 0 0 4px; }
.camera-results-sub { font-size: 12px; color: #888; margin: 0 0 12px; }
.camera-items { display: flex; gap: 8px; overflow-x: auto; padding-bottom: 12px; -webkit-overflow-scrolling: touch; }
.camera-items::-webkit-scrollbar { display: none; }
.camera-item { position: relative; flex: 0 0 80px; text-align: center; }
.camera-item img { width: 80px; height: 80px; border-radius: 8px; object-fit: cover; }
.camera-item span { display: block; font-size: 10px; margin-top: 4px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.camera-item-remove { position: absolute; top: -4px; right: -4px; width: 18px; height: 18px; border-radius: 50%; background: #333; color: #fff; border: none; font-size: 10px; cursor: pointer; }
.camera-item-new { border: 2px dashed #c45500; border-radius: 10px; padding: 2px; }
.camera-item-placeholder { width: 80px; height: 80px; border-radius: 8px; background: #f8f0e8; display: flex; align-items: center; justify-content: center; font-size: 24px; color: #c45500; }
.camera-section-label { font-size: 12px; font-weight: 600; color: #888; margin: 8px 0 6px; }
.camera-add-new-btn { border: none; background: none; color: #c45500; font-size: 14px; font-weight: 600; cursor: pointer; padding: 8px 0; }
.camera-post-form { display: flex; flex-direction: column; gap: 10px; margin-top: 12px; }
.camera-title-input { border: 1px solid #ddd; border-radius: 10px; padding: 10px 12px; font-size: 16px; outline: none; box-sizing: border-box; width: 100%; }
.camera-desc-input { border: 1px solid #ddd; border-radius: 10px; padding: 10px 12px; font-size: 16px; outline: none; box-sizing: border-box; width: 100%; resize: none; }
.camera-post-btn { width: 100%; padding: 12px; font-size: 15px; }

/* Match-confirm carousel — one row per recognized garment */
.recog-row { display: flex; align-items: center; gap: 10px; margin-bottom: 14px; }
.recog-shot { flex: 0 0 56px; text-align: center; }
.recog-shot img { width: 56px; height: 56px; border-radius: 8px; object-fit: cover; }
.recog-shot span { display: block; font-size: 9px; color: #888; margin-top: 3px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.recog-track-wrap { position: relative; flex: 1; min-width: 0; }
.recog-frame { position: absolute; top: 0; bottom: 14px; left: calc(50% - 56px); width: 112px; border: 2px solid #c45500; border-radius: 12px; pointer-events: none; z-index: 2; }
.recog-track { display: flex; gap: 8px; overflow-x: auto; scroll-snap-type: x mandatory; padding: 0 calc(50% - 52px) 14px; -webkit-overflow-scrolling: touch; }
.recog-track::-webkit-scrollbar { display: none; }
.recog-card { flex: 0 0 104px; scroll-snap-align: center; text-align: center; opacity: .45; transition: opacity .15s, transform .15s; cursor: pointer; }
.recog-card.is-sel { opacity: 1; transform: scale(1.04); }
.recog-card img { width: 104px; height: 104px; border-radius: 10px; object-fit: cover; background: #f4f4f4; }
.recog-glyph { width: 104px; height: 104px; border-radius: 10px; background: #f8f0e8; display: flex; align-items: center; justify-content: center; font-size: 30px; color: #c45500; }
.recog-card-title { font-size: 11px; font-weight: 600; margin-top: 4px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.recog-card-tag { font-size: 9px; color: #888; }

.camera-manual { text-align: center; padding: 12px; }
.camera-manual-btn { border: none; background: none; color: #c45500; font-size: 14px; font-weight: 600; cursor: pointer; text-decoration: underline; }

.event-date-options { display: flex; gap: 8px; margin-top: 6px; }
.event-date-pill { padding: 8px 12px; border-radius: 16px; background: #f0f0f0; font-size: 13px; cursor: pointer; white-space: nowrap; }
.event-date-pill input { display: none; }
.event-date-pill:has(input:checked) { background: #000; color: #fff; }

.event-checkbox { display: flex; align-items: center; gap: 8px; font-size: 14px; color: #333; cursor: pointer; margin: 12px 0; text-transform: none; position: relative; z-index: 1; }
.event-checkbox input { width: 18px; height: 18px; accent-color: #c45500; cursor: pointer; }

/* Event context pills */
.event-context-pills { padding: 8px 0; }
.context-row { margin-bottom: 10px; }
.context-label { font-size: 12px; font-weight: 600; color: #888; display: block; margin-bottom: 4px; }
.context-options { display: flex; flex-wrap: wrap; gap: 6px; }
.context-pill { border: 1px solid #ddd; background: #fff; border-radius: 14px; padding: 6px 12px; font-size: 13px; cursor: pointer; transition: all 0.15s; }
.context-pill.selected { background: #000; color: #fff; border-color: #000; }

/* Trending card */
.card-trending { padding: 12px 16px; }
.trending-title { font-size: 15px; font-weight: 700; margin: 0 0 10px; }
.trending-list { display: flex; flex-direction: column; gap: 8px; }
.trending-row { display: flex; align-items: center; gap: 10px; text-decoration: none; color: inherit; }
.trending-rank { width: 20px; font-size: 14px; font-weight: 700; color: #c45500; text-align: center; }
.trending-avatar { width: 48px; height: 48px; border-radius: 50%; object-fit: cover; }
.trending-name { flex: 1; font-size: 14px; font-weight: 500; }
.trending-stat { font-size: 12px; color: #c45500; font-weight: 600; }

/* Submission CTA card */
.submission-cta-card { display: flex; align-items: center; gap: 14px; padding: 20px 16px; margin-top: 8px; background: linear-gradient(135deg, #fff8f0, #fef0e0); border: 2px dashed #c45500; border-radius: 12px; text-decoration: none; color: inherit; }
.submission-cta-emoji { font-size: 32px; }
.submission-cta-text strong { display: block; font-size: 15px; color: #333; }
.submission-cta-text span { font-size: 13px; color: #888; }

.profile-header-actions { display: flex; flex-direction: column; gap: 6px; flex: 0 0 auto; align-self: flex-start; }
.profile-action-btn { font-size: 12px; font-weight: 600; padding: 6px 10px; border: 1px solid var(--gray-300); border-radius: 14px; color: var(--black); background: #fff; text-decoration: none; white-space: nowrap; text-align: center; }

/* Card item detail slide */
/* Fixed square hero box reserves height from first paint (no layout shift as the
   lazy image loads) and shows a subtle CSS shimmer placeholder until it paints.
   Square + object-fit:cover crops the (dominant) 512x512 generated heroes to zero. */
.card-image-wrap { position: relative; display: flex; overflow: hidden; aspect-ratio: 1 / 1; background: #ececec; }
.card-image-wrap:not(.has-lqip):not(:has(> .card-image > img.loaded))::before {
  content: ""; position: absolute; inset: 0;
  background: linear-gradient(100deg, rgba(255,255,255,0) 35%, rgba(255,255,255,.6) 50%, rgba(255,255,255,0) 65%);
  background-size: 200% 100%; background-repeat: no-repeat;
  animation: feed-shimmer 1.5s ease-in-out infinite;
}
@keyframes feed-shimmer { from { background-position: 150% 0; } to { background-position: -150% 0; } }
/* Blur-up LQIP: an inline data-URI preview (var(--lqip)) blurred behind the image until it loads,
   replacing the generic shimmer for assets that have one (same progressive-enhancement path). */
.card-image-wrap.has-lqip:not(:has(> .card-image > img.loaded))::before {
  content: ""; position: absolute; inset: 0;
  background: var(--lqip) center / cover no-repeat;
  filter: blur(16px); transform: scale(1.2);
}
.card-image-wrap .card-image { flex: 1 1 100%; min-width: 0; transition: flex 0.3s ease; display: block; }
.card-image-wrap .card-image img { width: 100%; height: 100%; object-fit: cover; display: block; }
/* Progressive fade-in (JS adds .img-fade then .loaded; images stay visible without JS). */
.card-image > img.img-fade { opacity: 0; transition: opacity .4s ease; }
.card-image > img.img-fade.loaded { opacity: 1; }
.card-item-detail { flex: 0 0 0; width: 0; overflow: hidden; transition: flex 0.3s ease, width 0.3s ease, opacity 0.3s ease, padding 0.3s ease; display: flex; flex-direction: column; padding: 0; background: #fff; opacity: 0; visibility: hidden; }
.card-image-wrap.open .card-image { flex: 0 0 30%; }
.card-image-wrap.open .card-item-detail { flex: 0 0 70%; width: 70%; padding: 0 12px 12px; opacity: 1; visibility: visible; }
.card-item-detail-close { align-self: flex-end; border: none; background: #f0f0f0; border-radius: 50%; width: 28px; height: 28px; font-size: 14px; cursor: pointer; flex-shrink: 0; }
.card-item-detail-link { display: block; }
.card-item-detail-img { width: 100%; aspect-ratio: 1; object-fit: contain; border-radius: 8px; margin: 0 0 8px; }
.card-item-detail-info { font-size: 13px; flex: 1; overflow-y: auto; text-align: right; }
.card-item-detail-info strong { display: block; font-size: 14px; margin-bottom: 4px; }
.card-item-detail-info span { color: #888; display: block; margin-bottom: 6px; }
.card-item-thumb { border: none; background: none; padding: 0; cursor: pointer; }
.card-item-more { width: 44px; height: 44px; border-radius: 8px; background: #f0f0f0; display: flex; align-items: center; justify-content: center; font-size: 12px; font-weight: 600; color: #555; }
.card-items-overflow { margin-top: 4px; }

/* Favorites row */
.favorites-row { display: flex; gap: 8px; overflow-x: auto; -webkit-overflow-scrolling: touch; padding-bottom: 4px; }
.favorites-row::-webkit-scrollbar { display: none; }
.favorites-thumb img { width: 56px; height: 56px; border-radius: 8px; object-fit: cover; display: block; }
.favorites-thumb-user img { border-radius: 50%; }

/* === Favorites Page === */
.fav-section { margin-bottom: 24px; }
.fav-section-title { font-size: 15px; font-weight: 600; margin-bottom: 12px; }
.fav-grid { display: grid; gap: 8px; }
.fav-grid-outfits { grid-template-columns: repeat(2, 1fr); }
.fav-grid-items { grid-template-columns: repeat(3, 1fr); }
.fav-card { display: block; border-radius: 10px; overflow: hidden; background: #f5f5f5; position: relative; }
.fav-card-img { width: 100%; aspect-ratio: 1; object-fit: cover; display: block; }
.fav-grid-outfits .fav-card-img { aspect-ratio: 3/4; }
.fav-card-label { position: absolute; bottom: 0; left: 0; right: 0; padding: 6px 8px; font-size: 12px; background: linear-gradient(transparent, rgba(0,0,0,.6)); color: #fff; }
.fav-list-people { display: flex; flex-direction: column; gap: 12px; }
.fav-person { display: flex; align-items: center; gap: 12px; }
.fav-person-link { display: flex; align-items: center; gap: 10px; flex: 1; text-decoration: none; color: inherit; }
.fav-person-avatar { width: 44px; height: 44px; border-radius: 50%; object-fit: cover; }
.fav-person-name { font-size: 14px; font-weight: 500; }
.fav-person-action { margin-left: auto; }
.btn-sm { font-size: 12px; padding: 4px 12px; border-radius: 16px; cursor: pointer; }
.btn-outline { background: none; border: 1px solid #ccc; color: #333; }

/* === Edit Item === */
.edit-item-hero { text-align: center; margin-bottom: 20px; }
.edit-item-img { width: 140px; height: 140px; object-fit: cover; border-radius: 12px; }
.edit-form { display: flex; flex-direction: column; gap: 14px; }
.form-group { display: flex; flex-direction: column; gap: 4px; }
.form-label { font-size: 12px; font-weight: 600; color: #666; text-transform: uppercase; letter-spacing: 0.5px; }
.form-input { padding: 10px 12px; border: 1px solid #ddd; border-radius: 8px; font-size: 15px; background: #fafafa; }
.form-input:focus { outline: none; border-color: #333; background: #fff; }
.form-row { display: flex; gap: 12px; }
.form-half { flex: 1; }
.edit-actions { display: flex; gap: 12px; margin-top: 8px; }
.edit-actions .btn-primary { flex: 1; }
.edit-actions .btn-secondary { flex: 0; padding: 10px 20px; background: none; border: 1px solid #ccc; border-radius: 20px; text-decoration: none; color: #333; text-align: center; font-size: 14px; }
.edit-delete-form { margin-top: 32px; padding-top: 20px; border-top: 1px solid #eee; }
.btn-danger { width: 100%; padding: 12px; background: none; border: 1px solid #e53935; color: #e53935; border-radius: 20px; font-size: 14px; font-weight: 500; cursor: pointer; }

/* === Share Button === */
.outfit-share-btn { width: 36px; height: 36px; border-radius: 50%; border: 1px solid #ddd; background: #fff; font-size: 18px; cursor: pointer; display: flex; align-items: center; justify-content: center; }

/* Standardized user-type identity badge (real users get none; AI/influencer labeled). */
.avatar-badge-host { position: relative; display: inline-block; }
*:has(> .user-badge) { position: relative; }
.user-badge {
  position: absolute; bottom: -2px; right: -2px;
  width: 14px; height: 14px; box-sizing: border-box;
  display: flex; align-items: center; justify-content: center;
  font-size: 9px; line-height: 1; border-radius: 50%;
  border: 1.5px solid #fff; color: #fff; pointer-events: none; z-index: 1;
}
.user-badge--ai { background: #6b4eff; }
.user-badge--influencer { background: #c45500; }

/* === Dress Me === */
.dressme-page { padding: 16px 0 80px; }
.dressme-title { font-size: 24px; margin: 0 16px 4px; }
.dressme-sub { font-size: 13px; color: #888; margin: 0 16px 16px; }
.dressme-carousel { display: flex; gap: 12px; overflow-x: auto; scroll-snap-type: x mandatory; padding: 0 16px 8px; -webkit-overflow-scrolling: touch; }
.dressme-card { scroll-snap-align: center; flex: 0 0 82%; max-width: 360px; background: #fff; border: 1px solid #eee; border-radius: 14px; padding: 14px; box-shadow: 0 2px 10px rgba(0,0,0,.05); }
.dressme-sourcing { display: inline-block; font-size: 11px; font-weight: 600; color: #c45500; text-transform: uppercase; letter-spacing: .04em; }
.dressme-card-title { font-size: 17px; margin: 6px 0 4px; }
.dressme-rationale { font-size: 13px; color: #555; margin: 0 0 10px; }
.dressme-thumbs { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 10px; }
.dressme-thumb { position: relative; width: 64px; height: 64px; border-radius: 8px; overflow: hidden; background: #f4f4f4; display: flex; align-items: center; justify-content: center; }
.dressme-thumb img { width: 100%; height: 100%; object-fit: cover; }
.dressme-thumb-empty { font-size: 10px; color: #999; text-align: center; padding: 4px; }
.dressme-thumb-tag { position: absolute; bottom: 0; left: 0; right: 0; background: rgba(196,85,0,.85); color: #fff; font-size: 9px; text-align: center; }
.dressme-nudge { font-size: 12px; color: #7a5; background: #f6faf2; border-radius: 8px; padding: 6px 8px; margin: 0 0 8px; }
.dressme-actions { display: flex; gap: 8px; }
.dressme-actions .btn-primary { flex: 1; }
.dressme-ask { background: #fff; border: 1px solid #c45500; color: #c45500; border-radius: 8px; padding: 8px 12px; font-weight: 600; cursor: pointer; }
.dressme-refine { margin: 16px; }
.dressme-chips { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 10px; }
.dressme-chip { background: #f2f2f2; border: 1px solid #e2e2e2; border-radius: 16px; padding: 6px 12px; font-size: 13px; cursor: pointer; }
.dressme-chip:hover { background: #ebebeb; }
.dressme-tellmore { display: flex; gap: 8px; }
.dressme-tellmore input { flex: 1; padding: 10px 12px; border: 1px solid #ddd; border-radius: 8px; font-size: 14px; }
.dressme-foot { text-align: center; margin: 20px 16px; font-size: 13px; }
.dressme-foot a { color: #c45500; text-decoration: none; }
/* Async-render states: the carousel shows a loading spinner until proposals arrive, an empty-state
   when there are no looks, and a tap-to-retry affordance on a load failure (never blank). */
.dressme-loading { flex: 1; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 12px; min-height: 180px; color: #888; font-size: 14px; text-align: center; padding: 24px 16px; }
.dressme-spinner { width: 28px; height: 28px; border: 3px solid #eee; border-top-color: #c45500; border-radius: 50%; animation: dressme-spin .8s linear infinite; }
@keyframes dressme-spin { to { transform: rotate(360deg); } }
.dressme-empty { flex: 1; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 12px; min-height: 180px; color: #888; font-size: 14px; text-align: center; padding: 24px 16px; }
.dressme-retry { flex: 1; min-height: 120px; margin: 0 16px; background: #fff; border: 1px dashed #d99; border-radius: 12px; color: #c33; font-size: 14px; font-weight: 600; cursor: pointer; }
.dressme-retry:hover { background: #fff6f6; }

/* ===== Login CTA (the body of the private-beta shell page, pages/shell.ejs) ===== */
.login-cta { display: flex; flex-direction: column; align-items: center; text-align: center; gap: 12px; padding: 8px 4px; }
.login-cta-mark { margin-bottom: 4px; opacity: .9; }
.login-cta-title { font-size: 20px; font-weight: 700; margin: 0; }
.login-cta-msg { color: #666; font-size: 14px; margin: 0 0 8px; max-width: 320px; }
.login-cta-btn { width: 100%; max-width: 280px; text-align: center; box-sizing: border-box; }
.login-cta .btn-secondary { background: none; border: 1px solid #ccc; border-radius: 20px; padding: 10px 24px; font-size: 14px; font-weight: 600; color: #333; text-decoration: none; }

/* "Report a problem" affordance — discreet, below comments on UGC pages */
.report-affordance { margin: 28px 16px 40px; text-align: center; }
.report-trigger { display: inline-block; background: none; border: none; padding: 4px 8px; font: inherit; font-size: 12px; color: #999; cursor: pointer; text-decoration: underline; }
.report-trigger:hover { color: #666; }
.report-disclosure { display: inline-block; max-width: 360px; width: 100%; }
.report-disclosure[open] .report-trigger { color: #666; margin-bottom: 10px; }
.report-form { display: flex; flex-direction: column; gap: 8px; text-align: left; padding: 12px; border: 1px solid #eee; border-radius: 12px; background: #fafafa; }
.report-reason { padding: 8px; border: 1px solid #ddd; border-radius: 8px; font-size: 14px; background: #fff; }
.report-note { padding: 8px; border: 1px solid #ddd; border-radius: 8px; font-size: 14px; resize: vertical; font-family: inherit; }
.report-submit { align-self: flex-end; background: #c45500; color: #fff; border: none; border-radius: 8px; padding: 8px 16px; font-size: 13px; font-weight: 600; cursor: pointer; }
.report-submit:hover { background: #a84800; }
