/* ============================================================
   AVISSEE — Storefront theme
   Premium editorial look · warm ivory + berry + charcoal
   ============================================================ */

:root {
  --bg: #faf7f3;
  --surface: #ffffff;
  --surface-soft: #f4ede6;
  --ink: #241f1c;
  --ink-soft: #554c45;
  --muted: #857a70;
  --line: #e8dfd6;
  --accent: #9c3f5c;
  --accent-dark: #7d2f48;
  --accent-soft: #f6e7ec;
  --gold: #b9924f;
  --success: #2e7d5b;
  --success-soft: #e4f1ea;
  --danger: #b3392f;
  --danger-soft: #fbeae7;
  --info: #3a6ea5;
  --info-soft: #e7f0f9;
  --warn: #b07a2c;
  --warn-soft: #fbf1e0;
  --radius: 14px;
  --radius-lg: 22px;
  --shadow-sm: 0 2px 10px rgba(36, 31, 28, .06);
  --shadow-md: 0 12px 32px rgba(36, 31, 28, .10);
  --shadow-lg: 0 24px 60px rgba(36, 31, 28, .16);
  --font-body: 'Plus Jakarta Sans', system-ui, -apple-system, Segoe UI, Roboto, sans-serif;
  --font-display: 'Playfair Display', Georgia, 'Times New Roman', serif;
  --maxw: 1240px;
}

* { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; text-size-adjust: 100%; }
body {
  font-family: var(--font-body);
  background: var(--bg);
  color: var(--ink);
  line-height: 1.6;
  font-size: 16px;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}
img { max-width: 100%; display: block; }
a { color: inherit; text-decoration: none; }
button { font-family: inherit; cursor: pointer; }
input, select, textarea { font-family: inherit; font-size: 15px; }
h1, h2, h3, h4 { line-height: 1.2; letter-spacing: -.01em; }

.container { max-width: var(--maxw); margin: 0 auto; padding: 0 20px; }

/* ---------- Announcement bar ---------- */
.announcement-bar {
  background: var(--ink);
  color: #f2ece5;
  text-align: center;
  font-size: 12.5px;
  letter-spacing: .04em;
  padding: 9px 16px;
}
.announcement-bar strong { color: #e9c98f; }

/* ---------- Header ---------- */
.site-header {
  position: sticky; top: 0; z-index: 60;
  background: rgba(250, 247, 243, .92);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--line);
}
.header-inner { display: flex; align-items: center; gap: 24px; padding-top: 14px; padding-bottom: 14px; }
.logo { display: flex; align-items: center; gap: 10px; min-width: 0; }
.logo-mark {
  width: 40px; height: 40px; border-radius: 50%;
  background: var(--accent);
  color: #fff;
  font-family: var(--font-display);
  font-size: 22px; font-weight: 700;
  display: grid; place-items: center;
}
.logo-mark.logo-img { background: transparent !important; border-radius: 8px; object-fit: contain; }
.logo-text { font-family: 'Quicksand', var(--font-display); font-size: 22px; font-weight: 700; line-height: 1; display: flex; flex-direction: column; }
.logo-text small { font-family: var(--font-body); font-size: 10px; letter-spacing: .22em; text-transform: uppercase; color: var(--muted); font-weight: 600; margin-top: 2px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; max-width: 100%; }

.main-nav { display: flex; align-items: center; gap: 6px; margin-left: auto; }
.main-nav > a, .has-sub > a {
  padding: 9px 13px; font-size: 14px; font-weight: 600; color: var(--ink-soft);
  border-radius: 10px; transition: all .2s;
}
.main-nav > a:hover, .has-sub > a:hover, .main-nav a.active { color: var(--accent); background: var(--accent-soft); }

.has-sub { position: relative; }
.sub-menu {
  position: absolute; top: 100%; left: -40px;
  display: none;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: var(--shadow-lg);
  padding: 22px; gap: 28px;
  min-width: 460px;
}
.has-sub:hover .sub-menu { display: grid; grid-template-columns: 1fr 1fr 1fr; }
.sub-menu-col strong { display: block; font-size: 11px; letter-spacing: .16em; text-transform: uppercase; color: var(--muted); margin-bottom: 10px; }
.sub-menu-col a { display: block; padding: 5px 0; font-size: 14px; color: var(--ink-soft); }
.sub-menu-col a:hover { color: var(--accent); }
.sub-menu-col .sub-cta { color: var(--accent); font-weight: 700; margin-top: 8px; }

.header-actions { display: flex; align-items: center; gap: 4px; }
.icon-link { position: relative; display: grid; place-items: center; width: 42px; height: 42px; border-radius: 50%; color: var(--ink); transition: all .2s; }
.icon-link:hover { background: var(--surface-soft); color: var(--accent); }
.cart-count {
  position: absolute; top: 2px; right: 0;
  min-width: 18px; height: 18px; padding: 0 4px;
  background: var(--accent); color: #fff; border-radius: 999px;
  font-size: 11px; font-weight: 700; display: grid; place-items: center;
}

.nav-toggle { display: none; background: none; border: 0; width: 42px; height: 42px; flex-direction: column; align-items: center; justify-content: center; gap: 5px; }
.nav-toggle span { width: 20px; height: 2px; background: var(--ink); border-radius: 2px; transition: .3s; }

/* Search panel */
.search-panel { display: none; border-top: 1px solid var(--line); background: var(--surface); }
.search-panel.open { display: block; animation: fadeIn .2s ease; }
.search-form { display: flex; gap: 10px; padding: 18px 20px; }
.search-form input { flex: 1; border: 1px solid var(--line); border-radius: 12px; padding: 13px 16px; background: var(--bg); }
.search-form input:focus { outline: 2px solid var(--accent-soft); border-color: var(--accent); }
.search-form button { background: var(--ink); color: #fff; border: 0; border-radius: 12px; padding: 0 26px; font-weight: 600; }

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  border: 0; border-radius: 12px; padding: 13px 26px;
  font-size: 14.5px; font-weight: 700; letter-spacing: .01em;
  transition: all .2s; cursor: pointer; text-align: center;
}
.btn-lg { padding: 16px 32px; font-size: 15.5px; }
.btn-sm { padding: 9px 16px; font-size: 13px; }
.btn-primary { background: var(--accent); color: #fff; }
.btn-primary:hover { background: var(--accent-dark); transform: translateY(-1px); box-shadow: var(--shadow-md); }
.btn-light { background: #fff; color: var(--ink); }
.btn-light:hover { background: var(--surface-soft); }
.btn-ghost { background: transparent; color: var(--ink); border: 1.5px solid var(--line); }
.btn-ghost:hover { border-color: var(--ink); }
.btn-outline { background: transparent; color: var(--accent); border: 1.5px solid var(--accent); }
.btn-outline:hover { background: var(--accent-soft); }
.btn-danger { background: var(--danger-soft); color: var(--danger); border: 1px solid transparent; }
.btn-danger:hover { background: var(--danger); color: #fff; }
.w-100 { width: 100%; }
.text-link { color: var(--accent); font-weight: 700; font-size: 14px; }
.text-link:hover { text-decoration: underline; }
.danger-link { color: var(--danger); }

/* ---------- Badges / alerts ---------- */
.badge {
  display: inline-flex; align-items: center; padding: 4px 10px;
  border-radius: 999px; font-size: 11px; font-weight: 700; letter-spacing: .03em;
}
.badge-success { background: var(--success-soft); color: var(--success); }
.badge-danger { background: var(--danger-soft); color: var(--danger); }
.badge-info { background: var(--info-soft); color: var(--info); }
.badge-warn { background: var(--warn-soft); color: var(--warn); }
.badge-muted { background: var(--surface-soft); color: var(--muted); }

.alert {
  display: flex; align-items: flex-start; gap: 10px;
  padding: 13px 16px; border-radius: 12px; font-size: 14px; margin-bottom: 16px;
}
.alert-icon { font-weight: 700; }
.alert-success { background: var(--success-soft); color: var(--success); }
.alert-error { background: var(--danger-soft); color: var(--danger); }
.alert-info { background: var(--info-soft); color: var(--info); }
.alert a { color: inherit; font-weight: 700; }

/* ---------- Hero ---------- */
.hero { position: relative; overflow: hidden; background: linear-gradient(180deg, #f6ede6 0%, var(--bg) 100%); }
.hero-inner { display: grid; grid-template-columns: 1.1fr .9fr; gap: 40px; align-items: center; padding-top: 70px; padding-bottom: 70px; }
.eyebrow {
  display: inline-block; font-size: 11.5px; letter-spacing: .2em; text-transform: uppercase;
  color: var(--accent); font-weight: 700; margin-bottom: 14px;
}
.hero h1 {
  font-family: var(--font-display);
  font-size: clamp(38px, 5vw, 60px);
  font-weight: 600; line-height: 1.08;
}
.hero h1 em { font-style: italic; color: var(--accent); }
.hero-copy p { color: var(--ink-soft); font-size: 17px; max-width: 470px; margin: 20px 0 28px; }
.hero-cta { display: flex; gap: 12px; flex-wrap: wrap; }
.hero-stats { display: flex; gap: 34px; margin-top: 44px; }
.hero-stats strong { display: block; font-family: var(--font-display); font-size: 24px; color: var(--ink); }
.hero-stats span { font-size: 12.5px; color: var(--muted); }

.hero-art { position: relative; height: 460px; }
.hero-ring {
  position: absolute; inset: 0; margin: auto;
  width: 380px; height: 380px; border-radius: 50%;
  border: 1px solid rgba(156, 63, 92, .25);
  animation: spin 40s linear infinite;
}
.hero-ring::after {
  content: ""; position: absolute; inset: -34px; border-radius: 50%;
  border: 1px dashed rgba(185, 146, 79, .35);
}
.hero-card {
  position: absolute; width: 250px; height: 340px; border-radius: var(--radius-lg);
  box-shadow: var(--shadow-lg); background: linear-gradient(160deg, #f2c9d4, #d97f9b);
  display: flex; align-items: flex-end; padding: 18px;
  background-size: cover; background-position: center;
}
.hero-card .badge { margin-bottom: auto; }
.card-a { left: 8px; top: 30px; transform: rotate(-7deg); background-image: linear-gradient(160deg,#ecc4d0,#c77f98); }
.card-b { right: 0; top: 100px; transform: rotate(5deg); background-image: linear-gradient(160deg,#d9c9b2,#a98a5f); }
.card-c { left: 70px; bottom: 0; transform: rotate(-3deg); background-image: linear-gradient(160deg,#b9d0d2,#5f8f96); }

@keyframes spin { to { transform: rotate(360deg); } }
@keyframes fadeIn { from { opacity: 0; transform: translateY(6px); } to { opacity: 1; transform: none; } }

/* ---------- Sections ---------- */
.section { padding: 64px 0; }
.section-soft { background: var(--surface-soft); }
.section-head { margin-bottom: 30px; }
.section-head h2 { font-family: var(--font-display); font-size: 30px; font-weight: 600; }
.section-head p { color: var(--muted); margin-top: 6px; }
.row-between { display: flex; align-items: flex-end; justify-content: space-between; gap: 16px; }

/* ---------- Category cards ---------- */
.gender-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; }
.gender-card {
  position: relative; border-radius: var(--radius-lg); overflow: hidden;
  min-height: 260px; color: #fff;
  box-shadow: var(--shadow-md); transition: transform .25s ease, box-shadow .25s ease;
}
.gender-card:hover { transform: translateY(-4px); box-shadow: var(--shadow-lg); }
.gender-womens { background: linear-gradient(160deg, #d88aa1, #8f3a58); }
.gender-mens { background: linear-gradient(160deg, #5c6b76, #2c3a44); }
.gender-kids { background: linear-gradient(160deg, #e0b46b, #b06f2e); }
.gender-inner { position: absolute; inset: 0; padding: 28px; display: flex; flex-direction: column; justify-content: flex-end; }
.gender-label { font-family: var(--font-display); font-size: 30px; font-weight: 700; }
.gender-sub { font-size: 13.5px; opacity: .9; margin: 4px 0 12px; }
.gender-cta { font-size: 13px; font-weight: 700; border-bottom: 1.5px solid rgba(255,255,255,.7); padding-bottom: 3px; align-self: flex-start; }

/* ---------- Product grid / cards ---------- */
.product-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 22px; }
.product-card {
  background: var(--surface); border-radius: var(--radius);
  border: 1px solid var(--line); overflow: hidden;
  transition: transform .22s ease, box-shadow .22s ease;
  display: flex; flex-direction: column;
}
.product-card:hover { transform: translateY(-5px); box-shadow: var(--shadow-md); }
.product-media { position: relative; height: 0; padding-bottom: 120%; overflow: hidden; background: var(--surface-soft); }
@supports (aspect-ratio: 3/3.6) { .product-media { aspect-ratio: 3/3.6; height: auto; padding-bottom: 0; } }
.product-media img { width: 100%; height: 100%; object-fit: cover; position: absolute; top: 0; left: 0; transition: transform .4s ease; }
.product-card:hover .product-media img { transform: scale(1.05); }
.product-media .badge { position: absolute; top: 12px; left: 12px; }
.product-media .badge-danger { top: 12px; left: 12px; }
.product-media .badge-success { top: 12px; right: 12px; left: auto; }
.quick-view {
  position: absolute; inset: auto 0 0 0; padding: 11px;
  background: rgba(36,31,28,.82); color: #fff; font-size: 13px; font-weight: 600;
  text-align: center; opacity: 0; transform: translateY(100%); transition: all .25s ease;
}
.product-card:hover .quick-view { opacity: 1; transform: none; }
.product-info { padding: 16px 16px 18px; display: flex; flex-direction: column; gap: 6px; flex: 1; }
.product-cat { font-size: 11px; letter-spacing: .14em; text-transform: uppercase; color: var(--muted); font-weight: 600; }
.product-info h3 { font-size: 15px; font-weight: 600; }
.product-info h3 a:hover { color: var(--accent); }
.price-row { display: flex; align-items: center; gap: 10px; }
.price { font-weight: 700; font-size: 16px; }
.price.sale { color: var(--accent); }
.price.compare { color: var(--muted); text-decoration: line-through; font-size: 14px; font-weight: 500; }
.price-row-lg { font-size: 22px; }
.card-add { margin-top: 8px; }

/* ---------- Banner offer ---------- */
.banner-offer { background: var(--accent); }
.banner-offer-inner { display: flex; align-items: center; justify-content: space-between; gap: 30px; padding: 20px 0; color: #fff; }
.banner-offer h2 { font-family: var(--font-display); font-size: 40px; }
.banner-offer p { margin: 10px 0 22px; opacity: .95; max-width: 560px; }
.banner-offer .eyebrow { color: #f0d9a0; }

/* ---------- Perks ---------- */
.perks { border-top: 1px solid var(--line); background: var(--surface); }
.perks-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; padding: 30px 0; }
.perks-grid div { text-align: center; }
.perks-grid strong { display: block; font-size: 14.5px; }
.perks-grid span { font-size: 12.5px; color: var(--muted); }

/* ---------- Story ---------- */
.story { background: var(--bg); }
.story-inner { display: grid; grid-template-columns: 1fr 1.4fr; gap: 48px; align-items: center; }
.story-art { position: relative; display: flex; align-items: center; justify-content: center; min-height: 260px; }
.story-ring { width: 200px; height: 200px; border-radius: 50%; background: linear-gradient(135deg, var(--accent), #d9a3b4); opacity: .9; }
.story-year { position: absolute; font-family: var(--font-display); font-size: 30px; font-weight: 600; color: var(--bg); text-align: center; line-height: 1.2; }
.story-copy p { color: var(--muted); margin-top: 12px; max-width: 560px; }
.story-copy .btn { margin-top: 20px; }
@media (max-width: 860px) {
  .story-inner { grid-template-columns: 1fr; gap: 24px; }
  .story-art { min-height: 180px; }
}

/* ---------- Page hero ---------- */
.page-hero { background: linear-gradient(180deg, #f3e9e0, var(--bg)); padding: 44px 0; }
.page-hero h1 { font-family: var(--font-display); font-size: 38px; font-weight: 600; }
.page-hero p { color: var(--muted); margin-top: 6px; }
.page-hero-mini { padding: 32px 0; }
.page-hero-mini h1 { font-size: 30px; }

/* ---------- Shop layout ---------- */
.shop-layout { display: grid; grid-template-columns: 250px 1fr; gap: 34px; padding: 40px 20px; }
.filters { align-self: start; position: sticky; top: 96px; }
.filters-head { display: none; }
.filter-group { margin-bottom: 26px; }
.filter-group h4 { font-size: 12px; letter-spacing: .14em; text-transform: uppercase; color: var(--muted); margin-bottom: 12px; }
.filter-link { display: block; padding: 7px 12px; border-radius: 9px; font-size: 14px; color: var(--ink-soft); }
.filter-link:hover { background: var(--surface-soft); }
.filter-link.on { background: var(--accent-soft); color: var(--accent); font-weight: 700; }
.size-filter { display: flex; flex-wrap: wrap; gap: 8px; }
.size-pill {
  min-width: 40px; text-align: center; padding: 8px 10px; border-radius: 9px;
  border: 1px solid var(--line); font-size: 13px; font-weight: 600; color: var(--ink-soft);
}
.size-pill:hover { border-color: var(--ink); }
.size-pill.on { background: var(--ink); color: #fff; border-color: var(--ink); }

.results-toolbar { display: flex; align-items: center; gap: 16px; margin-bottom: 26px; flex-wrap: wrap; }
.results-toolbar > span { color: var(--muted); font-size: 14px; }
.sort-select { margin-left: auto; display: flex; align-items: center; gap: 8px; }
.sort-select label { font-size: 13px; color: var(--muted); }
.sort-select select, .filters select, .filters input, .field select, .field input, .field textarea, .auth-card input, .auth-card select, .auth-card textarea {
  width: 100%; border: 1px solid var(--line); border-radius: 11px; padding: 12px 14px; background: var(--surface); color: var(--ink);
}
.sort-select select:focus, .field input:focus, .field select:focus, .field textarea:focus, .auth-card input:focus { outline: 2px solid var(--accent-soft); border-color: var(--accent); }
.filters-open { display: none; }

.pagination { display: flex; justify-content: center; gap: 8px; margin-top: 36px; }
.page-link {
  min-width: 40px; height: 40px; display: grid; place-items: center;
  border: 1px solid var(--line); border-radius: 10px; font-weight: 600; font-size: 14px;
}
.page-link:hover { border-color: var(--ink); }
.page-link.on { background: var(--ink); color: #fff; border-color: var(--ink); }

.empty-state { text-align: center; padding: 70px 20px; }
.empty-state h2, .empty-state h3 { font-family: var(--font-display); font-size: 26px; margin-bottom: 8px; }
.empty-state p { color: var(--muted); margin-bottom: 22px; }
.empty-note { color: var(--muted); padding: 10px 0; }

/* ---------- Breadcrumbs ---------- */
.breadcrumbs { display: flex; align-items: center; gap: 10px; padding: 22px 20px 4px; font-size: 13px; color: var(--muted); overflow-x: auto; -webkit-overflow-scrolling: touch; white-space: nowrap; }
.breadcrumbs a:hover { color: var(--accent); }

/* ---------- Product page ---------- */
.product-page { display: grid; grid-template-columns: 1fr 1fr; gap: 50px; padding: 30px 20px 60px; }
.product-gallery { position: sticky; top: 100px; align-self: start; }
.gallery-main { position: relative; border-radius: var(--radius-lg); overflow: hidden; background: var(--surface-soft); }
.gallery-main img { width: 100%; aspect-ratio: 1/1.15; height: auto; object-fit: cover; }
.gallery-badge { position: absolute; top: 16px; left: 16px; }
.gallery-thumbs { display: flex; gap: 10px; margin-top: 12px; overflow-x: auto; -webkit-overflow-scrolling: touch; padding-bottom: 4px; }
.gallery-thumbs .thumb { width: 72px; height: 82px; border-radius: 10px; overflow: hidden; border: 2px solid transparent; background: var(--surface-soft); }
.gallery-thumbs .thumb img { width: 100%; height: 100%; object-fit: cover; }
.gallery-thumbs .thumb.on { border-color: var(--accent); }

.product-summary h1 { font-family: var(--font-display); font-size: 30px; font-weight: 600; margin: 8px 0 14px; }
.price-note { font-size: 12px; color: var(--muted); margin: 6px 0 16px; }
.product-short { color: var(--ink-soft); margin-bottom: 14px; }
.fabric-chip {
  display: inline-block; background: var(--surface-soft); border-radius: 999px;
  padding: 8px 16px; font-size: 13px; color: var(--ink-soft); margin-bottom: 20px;
}
.buy-form { margin-top: 6px; }
.field { margin-bottom: 18px; }
.field label { display: block; font-size: 13px; font-weight: 700; margin-bottom: 8px; }
.size-options { display: flex; flex-wrap: wrap; gap: 10px; }
.size-option input { position: absolute; opacity: 0; pointer-events: none; }
.size-option span {
  display: grid; place-items: center; min-width: 52px; height: 46px; padding: 0 12px;
  border: 1.5px solid var(--line); border-radius: 10px; font-weight: 700; font-size: 14px;
  cursor: pointer; transition: all .15s;
}
.size-option input:checked + span { border-color: var(--accent); background: var(--accent); color: #fff; }
.size-option.sold-out span { opacity: .4; cursor: not-allowed; text-decoration: line-through; }
.pack-option span { min-width: 64px; }
.pack-field .pack-save { color: var(--success); font-weight: 600; }
.colour-options { display: flex; gap: 10px; flex-wrap: wrap; }
.colour-swatch {
  width: 34px; height: 34px; border-radius: 50%; cursor: pointer;
  border: 2px solid var(--line); padding: 0; position: relative;
}
.colour-swatch.on { border-color: var(--accent); box-shadow: 0 0 0 3px var(--accent-soft); }

.buy-row { display: flex; flex-wrap: wrap; gap: 14px; margin-top: 24px; }
.qty { display: flex; align-items: center; border: 1.5px solid var(--line); border-radius: 12px; overflow: hidden; }
.qty button { width: 44px; height: 52px; border: 0; background: none; font-size: 20px; color: var(--ink); }
.qty button:hover { background: var(--surface-soft); }
.qty input { width: 48px; border: 0; text-align: center; font-weight: 700; -moz-appearance: textfield; }
.qty input::-webkit-outer-spin-button, .qty input::-webkit-inner-spin-button { -webkit-appearance: none; }
.qty-sm button { width: 44px; height: 44px; font-size: 16px; }
.qty-sm input { width: 44px; height: 44px; }
.stock-note { margin-top: 10px; font-size: 13px; font-weight: 600; color: var(--success); }

.assurance { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; margin-top: 26px; border-top: 1px solid var(--line); padding-top: 20px; }
.assurance strong { display: block; font-size: 13px; }
.assurance span { font-size: 12px; color: var(--muted); }

.product-desc { display: grid; grid-template-columns: 1.5fr 1fr; gap: 40px; }
.product-desc h2 { font-family: var(--font-display); font-size: 24px; margin-bottom: 14px; }
.feature-list { margin: 16px 0 0 18px; color: var(--ink-soft); }
.feature-list li { margin-bottom: 6px; }
.care-card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 24px; }
.care-card h3 { font-size: 16px; margin-bottom: 12px; }
.care-card li { color: var(--ink-soft); font-size: 14px; margin-bottom: 6px; }

/* ---------- Info / policy pages ---------- */
.prose-page { max-width: 760px; padding: 40px 20px 80px; }
.prose-block { padding: 22px 0; border-bottom: 1px solid var(--line); }
.prose-block:last-child { border-bottom: 0; }
.prose-block h2 { font-family: var(--font-display); font-size: 22px; margin-bottom: 10px; }
.prose-block p { color: var(--ink-soft); margin: 10px 0; line-height: 1.75; }
.prose-block a { color: var(--accent); text-decoration: underline; }
.prose-block .feature-list { margin: 12px 0 0 18px; }

/* ---------- Cart ---------- */
.cart-layout { display: grid; grid-template-columns: 1fr 360px; gap: 40px; padding: 36px 20px 70px; }
.cart-item { display: flex; gap: 18px; padding: 20px 0; border-bottom: 1px solid var(--line); }
.cart-thumb { width: 92px; height: 112px; border-radius: 12px; overflow: hidden; background: var(--surface-soft); flex-shrink: 0; }
.cart-thumb img { width: 100%; height: 100%; object-fit: cover; }
.cart-detail { flex: 1; }
.cart-detail h3 { font-size: 15.5px; margin-bottom: 4px; }
.cart-detail h3 a:hover { color: var(--accent); }
.cart-meta { font-size: 13px; color: var(--muted); }
.cart-price { font-weight: 700; margin: 8px 0; }
.cart-controls { display: flex; align-items: center; gap: 16px; flex-wrap: wrap; }
.cart-controls .qty { margin-right: auto; }

.summary {
  background: var(--surface); border: 1px solid var(--line);
  border-radius: var(--radius-lg); padding: 26px; align-self: start;
  position: sticky; top: 100px;
}
.summary h3 { font-family: var(--font-display); font-size: 20px; margin-bottom: 18px; }
.summary-row { display: flex; justify-content: space-between; padding: 7px 0; font-size: 14.5px; }
.summary-row.total { border-top: 1px solid var(--line); margin-top: 8px; padding-top: 14px; font-size: 17px; font-weight: 700; }
.summary-row.green { color: var(--success); font-weight: 600; }
.green { color: var(--success); font-weight: 600; }
.summary hr { border: 0; border-top: 1px solid var(--line); margin: 12px 0; }
.summary-item { display: flex; justify-content: space-between; gap: 14px; font-size: 13.5px; padding: 4px 0; }
.summary-item small { color: var(--muted); }
.secure-note { font-size: 12px; color: var(--muted); margin-top: 14px; text-align: center; }
.offer-form { margin: 18px 0; }
.offer-row { display: flex; gap: 8px; }
.offer-row input { flex: 1; border: 1px solid var(--line); border-radius: 10px; padding: 10px 12px; text-transform: uppercase; }
.summary .btn { margin-bottom: 10px; }

/* ---------- Auth ---------- */
.auth-wrap { display: flex; justify-content: center; padding: 40px 20px 80px; }
.auth-card {
  width: 100%; max-width: 440px; background: var(--surface);
  border: 1px solid var(--line); border-radius: var(--radius-lg);
  padding: 34px; box-shadow: var(--shadow-sm);
}
.auth-alt { text-align: center; margin-top: 18px; font-size: 14px; color: var(--ink-soft); }
.auth-alt a { color: var(--accent); font-weight: 700; }
.terms-note { font-size: 12px; color: var(--muted); text-align: center; margin-top: 12px; }
.gender-options { display: flex; flex-direction: column; gap: 8px; }
.gender-option { display: flex; align-items: center; gap: 10px; padding: 10px 12px; border: 1.5px solid var(--line); border-radius: 10px; cursor: pointer; font-size: 14px; }
.gender-option input { width: auto; }
.gender-option:has(input:checked) { border-color: var(--accent); background: var(--accent-soft); font-weight: 700; }
.row-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
.row-3 { display: grid; grid-template-columns: 1.4fr 1fr 1fr; gap: 14px; }
.checkbox-field { display: flex; align-items: center; }
.check { display: flex; align-items: center; gap: 8px; font-size: 14px; cursor: pointer; }
.check input { width: auto; }

/* ---------- Checkout ---------- */
.checkout-layout { display: grid; grid-template-columns: 1fr 360px; gap: 40px; padding: 36px 20px 80px; }
.card-section {
  background: var(--surface); border: 1px solid var(--line);
  border-radius: var(--radius-lg); padding: 26px; margin-bottom: 20px;
}
.card-section h2 { font-size: 17px; margin-bottom: 16px; }
.card-section h3 { font-size: 15px; }
.muted { color: var(--muted); font-size: 13.5px; }
.hidden { display: none; }

.address-options { display: flex; flex-direction: column; gap: 10px; margin-bottom: 16px; }
.address-option { display: flex; gap: 12px; align-items: flex-start; padding: 14px 16px; border: 1.5px solid var(--line); border-radius: 12px; cursor: pointer; font-size: 14px; }
.address-option input { width: auto; margin-top: 3px; }
.address-option:has(input:checked) { border-color: var(--accent); background: var(--accent-soft); }
.address-option em { font-style: normal; font-size: 10px; background: var(--info-soft); color: var(--info); border-radius: 999px; padding: 2px 8px; margin-left: 6px; }
.address-option.new { border-style: dashed; justify-content: center; font-weight: 600; color: var(--ink-soft); }

.payment-options { display: flex; flex-direction: column; gap: 10px; }
.payment-option { display: flex; align-items: center; gap: 12px; padding: 16px; border: 1.5px solid var(--line); border-radius: 12px; cursor: pointer; }
.payment-option input { width: auto; }
.payment-option:has(input:checked) { border-color: var(--accent); background: var(--accent-soft); }
.payment-option strong { display: block; font-size: 14.5px; }
.payment-option small { color: var(--muted); }
.secure-tag { margin-left: auto; font-size: 11px; font-weight: 700; color: var(--success); background: var(--success-soft); border-radius: 999px; padding: 4px 10px; }

/* ---------- Payment page ---------- */
.payment-layout { display: grid; grid-template-columns: 360px 1fr; gap: 40px; padding: 40px 20px 80px; }
.payment-box h2 { font-size: 20px; margin-bottom: 8px; }
.pay-methods { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 20px; }
.pay-methods span { font-size: 12px; font-weight: 700; color: var(--muted); border: 1px solid var(--line); border-radius: 8px; padding: 6px 12px; background: var(--bg); }

/* ---------- Order success ---------- */
.order-success { padding: 60px 0 90px; text-align: center; }
.order-success-inner { max-width: 560px; margin: 0 auto; }
.success-mark { color: var(--success); margin-bottom: 20px; }
.order-success h1 { font-family: var(--font-display); font-size: 34px; margin-bottom: 10px; }
.order-success .summary { text-align: left; margin-top: 30px; }
.success-cta { display: flex; gap: 12px; justify-content: center; margin-top: 26px; }

/* ---------- Account ---------- */
.account-layout { display: grid; grid-template-columns: 230px 1fr; gap: 36px; padding: 40px 20px 80px; }
.account-nav { display: flex; flex-direction: column; gap: 4px; align-self: start; position: sticky; top: 96px; }
.account-nav a { padding: 11px 16px; border-radius: 11px; font-size: 14.5px; font-weight: 600; color: var(--ink-soft); }
.account-nav a:hover { background: var(--surface-soft); }
.account-nav a.on { background: var(--accent); color: #fff; }
.stat-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; margin-bottom: 24px; }
.stat-card {
  background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius);
  padding: 20px; display: flex; flex-direction: column;
}
.stat-card span { font-size: 12.5px; color: var(--muted); font-weight: 600; }
.stat-card strong { font-family: var(--font-display); font-size: 28px; }
.stat-card small { font-size: 12px; color: var(--muted); }
.stat-card.warn { border-color: var(--warn); }
.stat-card.warn strong { color: var(--warn); }

.order-list { display: flex; flex-direction: column; }
.order-row {
  display: grid; grid-template-columns: 1.4fr 1fr .8fr .7fr; gap: 12px;
  align-items: center; padding: 14px 10px; border-bottom: 1px solid var(--line);
  font-size: 14px; transition: background .15s;
}
.order-row:hover { background: var(--surface-soft); }
.order-row strong, .order-row > div { display: flex; flex-direction: column; }
.order-row small { color: var(--muted); font-size: 12px; }
.order-row .badge { align-self: flex-start; }
.order-list-lg .order-row { grid-template-columns: 1.4fr 1fr .8fr .6fr; }

/* ---------- Support tickets (customer) ---------- */
.ticket-list { display: flex; flex-direction: column; }
.ticket-row {
  padding: 16px 6px; border-bottom: 1px solid var(--line);
}
.ticket-head { display: flex; justify-content: space-between; align-items: center; gap: 12px; }
.ticket-head strong, .ticket-head span { display: flex; flex-direction: column; }
.ticket-head span { color: var(--muted); font-size: 12px; }
.ticket-meta { margin-top: 8px; display: flex; flex-direction: column; gap: 2px; }
.ticket-subject { font-weight: 600; font-size: 14.5px; }
.ticket-reply {
  margin-top: 12px; padding: 12px 14px; background: var(--surface-soft);
  border-left: 3px solid var(--success); border-radius: var(--radius);
}
.ticket-reply p { margin-top: 6px; color: var(--muted); font-size: 13.5px; white-space: pre-line; }

.account-form { margin-top: 8px; max-width: 560px; }
.account-form .field:last-child { margin-bottom: 0; }

.address-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); gap: 16px; }
.address-card { border: 1px solid var(--line); border-radius: var(--radius); padding: 18px; }
.address-card h4 { font-size: 15px; margin-bottom: 8px; }
.address-card p { font-size: 13.5px; color: var(--ink-soft); }
.address-card .muted { margin-bottom: 8px; }
.address-card.add {
  border-style: dashed; display: grid; place-items: center; color: var(--muted);
  font-weight: 600; font-size: 14px;
}
.address-card.add:hover { border-color: var(--accent); color: var(--accent); }
.profile-form .field input { max-width: 420px; }

/* ---------- Order detail ---------- */
.order-detail-layout { display: grid; grid-template-columns: 1fr 340px; gap: 36px; padding: 36px 20px 80px; }
.status-steps { display: flex; justify-content: space-between; margin: 10px 0 4px; position: relative; }
.status-steps::before { content: ""; position: absolute; top: 12px; left: 0; right: 0; height: 2px; background: var(--line); }
.status-steps li { display: flex; flex-direction: column; align-items: center; gap: 8px; font-size: 12px; color: var(--muted); z-index: 1; text-align: center; width: 20%; }
.status-steps .dot { width: 26px; height: 26px; border-radius: 50%; background: var(--surface); border: 2px solid var(--line); position: relative; }
.status-steps li.done .dot { background: var(--success); border-color: var(--success); }
.status-steps li.done .dot::after { content: "✓"; color: #fff; position: absolute; inset: 0; display: grid; place-items: center; font-size: 12px; }
.status-steps li.current .dot { box-shadow: 0 0 0 4px var(--success-soft); }
.status-steps li.done { color: var(--success); font-weight: 600; }
.order-item { display: flex; align-items: center; gap: 14px; padding: 10px 0; border-bottom: 1px solid var(--line); }
.order-item:last-child { border-bottom: 0; }
.order-item-img { width: 56px; height: 66px; border-radius: 10px; overflow: hidden; background: var(--surface-soft); flex-shrink: 0; }
.order-item-img img { width: 100%; height: 100%; object-fit: cover; }
.order-item-detail { flex: 1; display: flex; flex-direction: column; font-size: 14px; }
.order-detail-side { position: sticky; top: 100px; align-self: start; }

/* ---------- Contact ---------- */
.contact-layout { display: grid; grid-template-columns: 1fr 320px; gap: 40px; padding: 40px 20px 80px; max-width: 900px; margin: 0 auto; }
.contact-info h3 { margin-bottom: 14px; }
.contact-info p { margin-bottom: 14px; font-size: 14.5px; }

/* ---------- Footer ---------- */
.site-footer { background: var(--ink); color: #d8cfc6; margin-top: 40px; }
.footer-grid { display: grid; grid-template-columns: 1.6fr 1fr 1fr 1.2fr; gap: 40px; padding: 60px 20px 40px; }
.footer-brand p { font-size: 13.5px; margin-top: 16px; max-width: 300px; color: #b3a89c; }
.footer-brand .footer-since { font-size: 12.5px; margin-top: 6px; color: #9c8f84; }
.logo-light .logo-text { color: #fff; }
.logo-light .logo-text small { color: #b3a89c; }
.footer-col h4 { color: #fff; font-size: 14px; margin-bottom: 16px; }
.footer-col a { display: block; padding: 4px 0; font-size: 13.5px; color: #b3a89c; }
.footer-col a:hover { color: #e9c98f; }
.footer-col .info-tile { display: block; padding: 4px 0; font-size: 13.5px; color: #b3a89c; text-decoration: none; font-weight: 400; text-align: left; }
.footer-col .info-tile:hover { color: #e9c98f; }
.pay-badges { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 14px; }
.pay-badges span { font-size: 11px; border: 1px solid rgba(255,255,255,.2); border-radius: 7px; padding: 5px 10px; color: #d8cfc6; }
.footer-bottom { display: flex; justify-content: space-between; gap: 14px; padding: 20px; border-top: 1px solid rgba(255,255,255,.12); font-size: 12.5px; color: #9c9084; }

/* ---------- Size guide ---------- */
.size-tables { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; }
.size-table { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 20px; }
.size-table h4 { margin-bottom: 12px; font-size: 14px; }
.size-table table { width: 100%; border-collapse: collapse; font-size: 13px; }
.size-table th, .size-table td { border: 1px solid var(--line); padding: 8px; text-align: center; }
.size-table th { background: var(--surface-soft); }

/* ---------- Info tile (modal popover) ---------- */
.info-tile {
  color: var(--accent); font-weight: 700; font-size: 14px;
  text-decoration: underline; text-underline-offset: 3px; cursor: pointer;
  background: none; border: 0; padding: 0;
}
.info-tile:hover { color: var(--accent-dark); }

.tile-backdrop {
  position: fixed; inset: 0; z-index: 200;
  background: rgba(36, 31, 28, .5);
  display: flex; align-items: center; justify-content: center;
  padding: 20px; opacity: 0; pointer-events: none; transition: opacity .2s;
}
.tile-backdrop.open { opacity: 1; pointer-events: auto; }
.tile-modal {
  background: var(--surface); border-radius: var(--radius-lg);
  box-shadow: var(--shadow-lg); max-width: 520px; width: 100%;
  max-height: 82vh; overflow: auto; transform: translateY(14px) scale(.98);
  transition: transform .2s;
}
.tile-backdrop.open .tile-modal { transform: none; }
.tile-head {
  display: flex; align-items: center; justify-content: space-between;
  gap: 12px; padding: 20px 24px; border-bottom: 1px solid var(--line);
  position: sticky; top: 0; background: var(--surface);
}
.tile-head h3 { font-family: var(--font-display); font-size: 20px; }
.tile-close {
  width: 34px; height: 34px; border-radius: 50%; border: 0;
  background: var(--surface-soft); color: var(--ink); font-size: 18px;
  display: grid; place-items: center; flex-shrink: 0;
}
.tile-close:hover { background: var(--line); }
.tile-body { padding: 22px 24px 26px; font-size: 14.5px; color: var(--ink-soft); }
.tile-body h4 { font-size: 14px; color: var(--ink); margin: 14px 0 6px; }
.tile-body p { margin: 8px 0; line-height: 1.7; }
.tile-body ul { margin: 8px 0 0 18px; }
.tile-body li { margin-bottom: 6px; }
.tile-body .tile-link { display: inline-block; margin-top: 14px; }
.tile-note {
  margin-top: 16px; padding: 10px 12px; border-radius: 10px;
  background: var(--warn-soft); color: var(--warn); font-size: 13px;
}

/* ---------- Responsive ---------- */
@media (max-width: 1024px) {
  .product-grid { grid-template-columns: repeat(3, 1fr); }
  .main-nav { display: none; }
  .nav-toggle { display: flex; }
  .main-nav.open { display: flex; position: fixed; inset: 0 0 0 0; background: var(--bg); flex-direction: column; align-items: flex-start; padding: 90px 28px; gap: 6px; z-index: 70; }
  .main-nav.open > a, .main-nav.open .has-sub > a { font-size: 20px; padding: 12px 0; }
  .main-nav.open .sub-menu { position: static; display: block; box-shadow: none; border: 0; padding: 4px 0 4px 14px; min-width: 0; }
  .main-nav.open .sub-menu-col { margin-bottom: 8px; }
  .hero-inner { grid-template-columns: 1fr; padding-top: 44px; }
  .hero-art { display: none; }
  .checkout-layout, .cart-layout, .payment-layout, .account-layout, .order-detail-layout { grid-template-columns: 1fr; }
  .summary, .account-nav, .product-gallery, .order-detail-side { position: static; }
  .footer-grid { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 720px) {
  .product-grid { grid-template-columns: repeat(2, 1fr); gap: 14px; }
  .gender-grid { grid-template-columns: 1fr; }
  .product-page { grid-template-columns: 1fr; gap: 24px; padding: 16px 16px 40px; }
  .product-gallery { position: static; }
  .product-summary h1 { font-size: 22px; }
  .product-desc { grid-template-columns: 1fr; gap: 24px; }
  .assurance { grid-template-columns: 1fr; gap: 12px; }
  .shop-layout { grid-template-columns: 1fr; padding-top: 20px; }
  .filters { position: fixed; inset: 0; background: var(--bg); padding: 20px; z-index: 80; overflow-y: auto; transform: translateX(-100%); transition: transform .25s; }
  .filters.open { transform: none; }
  .filters-head { display: flex; justify-content: space-between; align-items: center; margin-bottom: 18px; }
  .filters-close { background: none; border: 0; font-size: 20px; }
  .filters-open { display: inline-flex; }
  .perks-grid { grid-template-columns: 1fr 1fr; }
  .perks-grid div:nth-child(3) { grid-column: 1 / -1; }
  .size-tables { grid-template-columns: 1fr; }
  .row-2, .row-3 { grid-template-columns: 1fr; }
  .footer-grid { grid-template-columns: 1fr; padding-top: 40px; }
  .footer-bottom { flex-direction: column; text-align: center; }
  .stat-grid { grid-template-columns: 1fr 1fr; }
  .order-row, .order-list-lg .order-row { grid-template-columns: 1fr; gap: 6px; }
  .hero-stats { gap: 20px; }
  .announcement-bar { font-size: 12px; line-height: 1.5; }
  .product-info { padding: 12px 12px 14px; }
  .product-info h3 { font-size: 13px; }
  .price { font-size: 14px; }
  .cart-thumb { width: 72px; height: 88px; }
  .quick-view { display: none; }
  .hero { padding: 60px 16px 40px; }
  .hero h1 { font-size: 28px; }
  .section { padding: 40px 0; }
  .section-title { font-size: 22px; }
  .section-head h2 { font-size: 24px; }
  .container { padding: 0 16px; }
  .gallery-main img { aspect-ratio: 1/1; }
  .gallery-thumbs .thumb { width: 56px; height: 64px; }
  /* 16px inputs stop iOS Safari auto-zooming on focus */
  input, select, textarea { font-size: 16px; }
  .qty button, .qty input { font-size: 16px; }
  /* Contain size-guide tables instead of stretching the page */
  .size-table { overflow-x: auto; -webkit-overflow-scrolling: touch; }
  .size-table table { min-width: 330px; }
  .size-table th, .size-table td { font-size: 12px; padding: 6px 5px; white-space: nowrap; }
  .page-hero h1 { font-size: 30px; }
  .sort-select { margin-left: 0; width: 100%; }
  .sort-select select { width: auto; flex: 1; }
  .buy-row .btn { width: 100%; }
}
@media (max-width: 400px) {
  .product-grid { grid-template-columns: 1fr 1fr; gap: 10px; }
  .product-info { padding: 10px; gap: 4px; }
  .product-info h3 { font-size: 12px; }
  .price { font-size: 13px; }
  .btn-sm.card-add { font-size: 11px; padding: 6px 8px; }
  .cart-controls { gap: 10px; }
  .qty-sm { transform: scale(.9); transform-origin: left center; }
}
@media (max-width: 480px) {
  .header-inner { gap: 10px; padding-top: 10px; padding-bottom: 10px; }
  .header-actions { gap: 2px; }
  .icon-link { width: 38px; height: 38px; }
  .logo-text { font-size: 20px; }
  .results-toolbar { gap: 10px; }
  .main-nav.open { padding: 80px 20px; }
  .filters { padding: 16px; }
}
@media (max-width: 380px) {
  .icon-link, .nav-toggle { width: 34px; height: 34px; }
  .icon-link svg { width: 20px; height: 20px; }
  .main-nav.open { padding: 72px 16px; }
  .page-hero h1 { font-size: 26px; }
  .product-grid { gap: 8px; }
  .btn-sm.card-add { font-size: 11px; padding: 8px 6px; }
  .size-table table { min-width: 310px; }
}
