/*
 * Olfazeta Luxury — shared stylesheet.
 * Tokens below are taken directly from design-system/chogan-parfum-space/MASTER.md
 * (color palette, typography, spacing, shadows). Do not hardcode colors or
 * spacing elsewhere — always reference these custom properties.
 *
 * Text-color rule of thumb used throughout this file (see remapping notes in
 * the redesign brief): --color-primary/--color-accent are vibrant brand hues
 * reserved for CTAs, links, active states and short brand-emphasis moments
 * (prices, badges, active nav) where they sit on solid contrasting surfaces
 * or large/bold type. Everyday "ink" — headings, item names, table data,
 * form labels, long-running copy — uses --color-foreground (deep berry,
 * ~9.6:1 on light surfaces) or --color-muted-foreground so small text stays
 * comfortably legible against the new light, colorful palette.
 */

@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700&family=Playfair+Display:wght@400;500;600;700&display=swap');

:root {
  /* Color palette (MASTER.md) */
  --color-primary: #EC4899;
  --color-on-primary: #000000;
  --color-secondary: #F9A8D4;
  --color-on-secondary: #0F172A;
  --color-accent: #8B5CF6;
  --color-on-accent: #000000;
  --color-background: #FDF2F8;
  --color-foreground: #831843;
  --color-card: #FFFFFF;
  --color-card-foreground: #831843;
  --color-muted: #F1EEF5;
  --color-muted-foreground: #475569;
  --color-border: #FBCFE8;
  /* Conventional star-rating yellow — deliberately outside the brand
     palette above, since ratings read universally in yellow/gold rather
     than the brand's pink/lavender accents. */
  --color-star: #FBBF24;
  --color-destructive: #DC2626;
  --color-on-destructive: #FFFFFF;
  --color-ring: #EC4899;

  /* Typography */
  --font-display: 'Playfair Display', Georgia, serif;
  --font-body: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;

  /* Spacing */
  --space-xs: 0.25rem;
  --space-sm: 0.5rem;
  --space-md: 1rem;
  --space-lg: 1.5rem;
  --space-xl: 2rem;
  --space-2xl: 3rem;
  --space-3xl: 4rem;

  /* Shadows — warm plum-tinted, not flat black (Soft UI Evolution style:
     softer, warmer shadows read as "alive" instead of a dead drop-shadow). */
  --shadow-sm: 0 1px 3px rgba(139, 21, 56, 0.07);
  --shadow-md: 0 6px 16px rgba(139, 21, 56, 0.10);
  --shadow-lg: 0 14px 32px rgba(139, 21, 56, 0.14);
  --shadow-xl: 0 24px 48px rgba(139, 21, 56, 0.18);

  --radius-sm: 6px;
  --radius-md: 8px;
  --radius-lg: 12px;
  --radius-xl: 16px;

  --transition-fast: 150ms ease;
  --transition-base: 200ms ease;

  /* Motion curves (animation-review standard): ease-out for entrances/
     exits, ease-in-out for on-screen movement/morphing. Hover/color use the
     plain `ease` keyword; constant motion would use `linear` (none here). */
  --ease-out: cubic-bezier(0.23, 1, 0.32, 1);
  --ease-in-out: cubic-bezier(0.77, 0, 0.175, 1);

  /* Fixed header footprint — used to offset page content below the fixed
     .site-header, and to clear hero copy on the homepage where the header
     floats transparently over the hero instead. */
  --header-h: 120px;

  color-scheme: light;
}

/* Native cross-document View Transitions for this classic multi-page app —
   a subtle crossfade between page loads. No-ops gracefully in browsers
   that don't support it; no JS required. */
@view-transition {
  navigation: auto;
}

/* ---------------------------------------------------------------------- */
/* Reset                                                                   */
/* ---------------------------------------------------------------------- */

*, *::before, *::after { box-sizing: border-box; }

html {
  -webkit-text-size-adjust: 100%;
}

body {
  margin: 0;
  background: var(--color-background);
  color: var(--color-foreground);
  font-family: var(--font-body);
  font-size: 16px;
  line-height: 1.6;
  overflow-x: hidden;
  padding-top: var(--header-h);
}

/* Homepage: the header starts transparent over the hero, so the hero
   should reach the very top of the viewport instead of being pushed down
   by --header-h (the hero's own copy panel clears the header instead —
   see .hero__inner > div:first-child below). */
body.page--home {
  padding-top: 0;
}

img { max-width: 100%; display: block; }

h1, h2, h3, h4 {
  font-family: var(--font-display);
  font-weight: 600;
  line-height: 1.15;
  margin: 0 0 var(--space-md);
  color: var(--color-foreground);
}

h1 { font-size: clamp(2.25rem, 4vw, 3.25rem); }
h2 { font-size: clamp(1.75rem, 3vw, 2.5rem); }
h3 { font-size: 1.5rem; }
h4 { font-size: 1.15rem; }

p { margin: 0 0 var(--space-md); }

a {
  color: var(--color-primary);
  text-decoration: none;
}
a:hover { text-decoration: underline; }

ul { list-style: none; margin: 0; padding: 0; }

button { font-family: inherit; }

/* ---------------------------------------------------------------------- */
/* Accessibility utilities                                                 */
/* ---------------------------------------------------------------------- */

.sr-only {
  position: absolute;
  width: 1px; height: 1px;
  padding: 0; margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

.skip-link {
  position: absolute;
  left: var(--space-md);
  top: var(--space-md);
  background: var(--color-primary);
  color: var(--color-on-primary);
  padding: var(--space-sm) var(--space-md);
  border-radius: var(--radius-sm);
  z-index: 1000;
  transform: translateY(-150%);
  transition: transform 150ms var(--ease-out);
}
.skip-link:focus {
  transform: translateY(0);
  text-decoration: none;
}

:focus-visible {
  outline: 3px solid var(--color-accent);
  outline-offset: 2px;
}

/* Interactive elements: guarantee a real 44x44 touch target without
 * necessarily growing their visual box. */
a, button, summary, input[type="checkbox"], input[type="radio"] {
  cursor: pointer;
}

.container {
  width: 100%;
  max-width: 1280px;
  margin: 0 auto;
  padding-inline: var(--space-lg);
}

/* ---------------------------------------------------------------------- */
/* Buttons                                                                 */
/* ---------------------------------------------------------------------- */

.btn-primary, .btn-secondary, .btn-ghost {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: var(--space-sm);
  min-height: 44px;
  padding: 12px 24px;
  border-radius: var(--radius-md);
  font-weight: 600;
  font-size: 0.95rem;
  border: 2px solid transparent;
  /* Named properties only — hover/color transitions use `ease`; the
     transform (translateY on hover, scale on press) gets its own line so
     the two can carry different durations. */
  transition: background-color var(--transition-base) ease, color var(--transition-base) ease,
              border-color var(--transition-base) ease, opacity var(--transition-base) ease,
              transform 130ms ease;
  cursor: pointer;
  text-decoration: none;
  line-height: 1;
}

/* Press feedback (button-tap frequency: occasional, per click) — 130ms,
   scale only, no translate so it doesn't fight the hover lift. */
.btn-primary:active:not(:disabled),
.btn-secondary:active:not(:disabled),
.btn-ghost:active:not(:disabled) {
  transform: scale(0.97);
}

.btn-primary {
  background: var(--color-accent);
  color: var(--color-on-accent);
}
@media (hover: hover) and (pointer: fine) {
  .btn-primary:hover:not(:disabled) {
    opacity: 0.9;
    transform: translateY(-1px);
    text-decoration: none;
  }
}
.btn-primary:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}

.btn-secondary {
  background: transparent;
  color: var(--color-foreground);
  border-color: var(--color-foreground);
}
@media (hover: hover) and (pointer: fine) {
  .btn-secondary:hover:not(:disabled) {
    background: var(--color-foreground);
    color: var(--color-background);
    text-decoration: none;
  }
}

/* On the vibrant hero (dark copy panel), invert so the outline reads
   against the panel instead of disappearing (dark-on-dark). */
.hero .btn-secondary {
  color: #fff;
  border-color: rgba(255, 255, 255, 0.7);
}
@media (hover: hover) and (pointer: fine) {
  .hero .btn-secondary:hover:not(:disabled) {
    background: #fff;
    color: var(--color-foreground);
  }
}

.btn-ghost {
  background: transparent;
  color: var(--color-muted-foreground);
  border-color: var(--color-border);
}
@media (hover: hover) and (pointer: fine) {
  .btn-ghost:hover {
    border-color: var(--color-foreground);
    color: var(--color-foreground);
    text-decoration: none;
  }
}

.btn-block { width: 100%; }
.btn-sm { min-height: 40px; padding: 8px 16px; font-size: 0.85rem; }

.btn-destructive {
  background: transparent;
  color: var(--color-destructive);
  border: none;
  min-height: 44px;
  padding: 8px 12px;
  font-weight: 600;
  border-radius: var(--radius-md);
  transition: background var(--transition-fast);
}
.btn-destructive:hover { background: rgba(220,38,38,0.08); text-decoration: underline; }

/* ---------------------------------------------------------------------- */
/* Header / Nav                                                            */
/* ---------------------------------------------------------------------- */

/* Fixed on every page: light frosted bar by default (the "always scrolled"
   look required on pages with no hero behind it), transitioning bg/padding/
   shadow over 250ms. On the homepage the .site-header--transparent modifier
   (added by render_header()) starts it transparent with white text instead;
   a tiny scroll listener in main.js then adds .is-scrolled once the visitor
   scrolls past the hero, morphing it into this same light frosted state. */
.site-header {
  position: fixed;
  inset: 0 0 auto 0;
  z-index: 100;
  background: rgba(255, 255, 255, 0.92);
  backdrop-filter: blur(10px);
  color: var(--color-foreground);
  box-shadow: var(--shadow-sm);
  transition: background 250ms var(--ease-in-out), box-shadow 250ms var(--ease-in-out),
              padding 250ms var(--ease-in-out), color 250ms var(--ease-in-out);
}

.site-header--transparent:not(.is-scrolled) {
  background: transparent;
  backdrop-filter: none;
  color: #fff;
  box-shadow: none;
}

.site-header__bar {
  max-width: 1280px;
  margin: 0 auto;
  padding: var(--space-md) var(--space-lg);
  display: flex;
  align-items: center;
  gap: var(--space-lg);
}

.site-logo {
  display: inline-flex;
  align-items: center;
  gap: var(--space-sm);
  color: inherit;
  font-family: var(--font-display);
  font-size: 1.35rem;
  font-weight: 700;
  letter-spacing: 0.02em;
  margin-right: auto;
}
.site-logo:hover { text-decoration: none; opacity: 0.9; }
.site-logo__image { height: 88px; width: auto; display: block; }

.nav-toggle {
  display: none;
  background: transparent;
  border: none;
  color: inherit;
  min-width: 44px;
  min-height: 44px;
  align-items: center;
  justify-content: center;
  border-radius: var(--radius-sm);
}
.nav-toggle:hover { background: rgba(131, 24, 67, 0.08); }
.site-header--transparent:not(.is-scrolled) .nav-toggle:hover { background: rgba(255,255,255,0.14); }

.primary-nav__list {
  display: flex;
  align-items: center;
  gap: var(--space-lg);
}

.nav-dropdown { position: relative; }
.nav-dropdown[open] > .nav-dropdown__summary .nav-dropdown__chevron { transform: rotate(180deg); }

.nav-dropdown__summary {
  list-style: none;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  min-height: 44px;
  padding: var(--space-sm) 2px;
  color: inherit;
  font-weight: 500;
  user-select: none;
}
.nav-dropdown__summary::-webkit-details-marker { display: none; }
.nav-dropdown__summary:hover { color: var(--color-primary); }
.nav-dropdown__summary.is-active { color: var(--color-primary); }
.site-header--transparent:not(.is-scrolled) .nav-dropdown__summary:hover,
.site-header--transparent:not(.is-scrolled) .nav-dropdown__summary.is-active { color: #fff; text-decoration: underline; }

.primary-nav__link {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  padding: var(--space-sm) 2px;
  color: inherit;
  font-weight: 500;
}
.primary-nav__link:hover,
.primary-nav__link.is-active { color: var(--color-primary); text-decoration: none; }
.site-header--transparent:not(.is-scrolled) .primary-nav__link:hover,
.site-header--transparent:not(.is-scrolled) .primary-nav__link.is-active { color: #fff; text-decoration: underline; }
.nav-dropdown__chevron { transition: transform 200ms var(--ease-in-out); }

.nav-dropdown__menu {
  position: absolute;
  top: calc(100% + 8px);
  left: 0;
  min-width: 240px;
  background: var(--color-card);
  color: var(--color-card-foreground);
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-lg);
  padding: var(--space-sm);
  z-index: 50;
}
.nav-dropdown__menu li a {
  display: block;
  min-height: 44px;
  display: flex;
  align-items: center;
  padding: var(--space-sm) var(--space-md);
  border-radius: var(--radius-sm);
  color: var(--color-card-foreground);
  font-size: 0.9rem;
}
.nav-dropdown__menu li a:hover,
.nav-dropdown__menu li a.is-active {
  background: var(--color-muted);
  color: var(--color-primary);
  text-decoration: none;
}

/* Mega-menu (progressive enhancement over the native <details>/<summary>
   dropdown): the base list-style dropdown above stays the fallback for
   touch/no-JS/narrow viewports; at desktop with a real pointer, the panel
   widens into a two-column mega-menu that opens on hover OR focus-within
   OR a click (native `open` attribute) — whichever gets there first. */
.mega-menu__heading { display: none; }

@media (hover: hover) and (pointer: fine) and (min-width: 1024px) {
  .primary-nav__item.has-dropdown,
  .nav-dropdown {
    /* Break the positioning context so the panel below can anchor to the
       full-width <header> (already `position: fixed`) instead of this
       narrow nav item. */
    position: static;
  }

  .nav-dropdown__menu.mega-menu {
    /* Override the native details-closed `display:none` — author rules
       beat user-agent rules regardless of specificity, so this is safe
       even while the <details> has no `open` attribute. Visibility is
       then handled by opacity/visibility below so it can transition. */
    display: block;
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: var(--color-card);
    color: var(--color-card-foreground);
    box-shadow: var(--shadow-xl);
    border-top: 2px solid var(--color-primary);
    z-index: 90;
    opacity: 0;
    visibility: hidden;
    transform: translateY(-8px);
    transition: opacity 200ms ease, transform 200ms var(--ease-out), visibility 0ms linear 200ms;
  }

  .nav-dropdown:hover > .nav-dropdown__menu.mega-menu,
  .nav-dropdown:focus-within > .nav-dropdown__menu.mega-menu,
  .nav-dropdown[open] > .nav-dropdown__menu.mega-menu {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
    transition: opacity 200ms ease, transform 200ms var(--ease-out), visibility 0ms linear 0ms;
  }

  /* Compact dropdown (e.g. the "Contact" nav item's Our Story/FAQ/Contact
     links): a small anchored panel rather than the full-bleed mega-menu,
     so it needs its own local positioning context back — the rule above
     made every .nav-dropdown position: static for the mega-menu's sake,
     this restores it for this one (same specificity, later in the
     cascade wins). Same hover/focus/open-to-show transition as the
     mega-menu, just without the full-width treatment. */
  .nav-dropdown--compact { position: relative; }

  .nav-dropdown__menu--compact {
    display: block;
    opacity: 0;
    visibility: hidden;
    transform: translateY(-8px);
    transition: opacity 150ms ease, transform 150ms ease, visibility 0ms linear 150ms;
  }

  .nav-dropdown--compact:hover > .nav-dropdown__menu--compact,
  .nav-dropdown--compact:focus-within > .nav-dropdown__menu--compact,
  .nav-dropdown--compact[open] > .nav-dropdown__menu--compact {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
    transition: opacity 150ms ease, transform 150ms var(--ease-out), visibility 0ms linear 0ms;
  }

  .mega-menu__heading {
    display: block;
    font-size: 0.8rem;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    color: var(--color-muted-foreground);
    margin-bottom: var(--space-md);
  }

  .mega-menu__inner {
    max-width: 1280px;
    margin: 0 auto;
    padding: var(--space-2xl) var(--space-lg);
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: var(--space-2xl);
    /* Without this, grid's default stretch forces .mega-menu__promo to
       match the height of the (usually taller) links column next to it,
       which then centers the small fixed-size tile image in a lot of
       empty vertical space instead of sizing the tile to its content. */
    align-items: start;
  }

  .mega-menu__links ul { display: flex; flex-direction: column; gap: 2px; }
  .mega-menu__links-secondary {
    margin-top: var(--space-md);
    padding-top: var(--space-md);
    border-top: 1px solid var(--color-border);
  }
  .mega-menu__links li a {
    display: flex;
    align-items: center;
    min-height: 44px;
    padding: var(--space-sm) var(--space-md);
    border-radius: var(--radius-sm);
    color: var(--color-card-foreground);
    font-size: 1rem;
  }
  .mega-menu__links li a:hover,
  .mega-menu__links li a.is-active {
    background: var(--color-muted);
    color: var(--color-primary);
    text-decoration: none;
  }

  .mega-menu__promo { display: grid; grid-template-columns: 1fr 1fr; gap: var(--space-lg); }
}

.mega-menu__tile {
  display: flex;
  align-items: center;
  gap: var(--space-md);
  background: var(--color-background);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-lg);
  padding: var(--space-md);
  color: inherit;
  transition: border-color 150ms ease, transform 150ms ease;
}
@media (hover: hover) and (pointer: fine) {
  .mega-menu__tile:hover { border-color: var(--color-primary); transform: translateY(-2px); text-decoration: none; }
}
.mega-menu__tile-media {
  flex-shrink: 0;
  width: 120px;
  height: 120px;
  border-radius: var(--radius-md);
  background: var(--color-muted);
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
}
.mega-menu__tile-media img { width: 100%; height: 100%; object-fit: contain; }
.mega-menu__tile-body { display: flex; flex-direction: column; gap: 2px; }
.mega-menu__tile-name { font-weight: 600; color: var(--color-foreground); font-size: 0.9rem; }
.mega-menu__tile-price { color: var(--color-primary); font-weight: 700; font-size: 0.85rem; }

.mega-menu__tile--plain {
  flex-direction: column;
  align-items: flex-start;
  justify-content: center;
  gap: var(--space-sm);
  background: linear-gradient(135deg, var(--color-primary) 0%, var(--color-accent) 100%);
  border-color: transparent;
  color: var(--color-on-primary);
  min-height: 88px;
}
.mega-menu__tile--plain .mega-menu__tile-name { color: var(--color-on-primary); font-family: var(--font-display); font-size: 1.1rem; }
.mega-menu__tile-cta {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  color: var(--color-primary);
  font-weight: 600;
  font-size: 0.85rem;
}
/* On the gradient tile, the pink/lavender-colored CTA would nearly vanish
   against its own background — force it to the same dark on-primary tone
   used for the tile's heading instead. */
.mega-menu__tile--plain .mega-menu__tile-cta { color: var(--color-on-primary); }

.cart-link {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 44px;
  min-height: 44px;
  color: inherit;
  border-radius: var(--radius-sm);
}
.cart-link:hover { color: var(--color-primary); text-decoration: none; }
.site-header--transparent:not(.is-scrolled) .cart-link:hover { color: #fff; opacity: 0.8; }
.cart-link__badge {
  position: absolute;
  top: 2px;
  right: 0;
  background: var(--color-primary);
  color: var(--color-on-primary);
  font-size: 0.7rem;
  font-weight: 700;
  min-width: 18px;
  height: 18px;
  border-radius: 999px;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0 4px;
}

.favorite-link.has-favorites svg { color: var(--color-primary); }
.site-header--transparent:not(.is-scrolled) .favorite-link.has-favorites:hover svg { color: #fff; }

.account-icon-link.is-active svg { color: var(--color-primary); }

/* ---------------------------------------------------------------------- */
/* Hero                                                                    */
/* ---------------------------------------------------------------------- */

.hero {
  background: linear-gradient(135deg, var(--color-primary) 0%, var(--color-accent) 100%);
  color: #fff;
  padding: var(--space-3xl) 0;
}
.hero__inner {
  max-width: 1280px;
  margin: 0 auto;
  padding: 0 var(--space-lg);
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;
  gap: var(--space-2xl);
  align-items: center;
}
/* First hero slide sits directly under the transparent header on page load
   (no scroll-offset padding is applied to <body> on the homepage), so its
   copy needs its own clearance — plus a semi-opaque dark plum panel behind
   the text guarantees legible contrast no matter where the gradient (or,
   on slide 4, the photo) lands underneath it. */
.hero__inner > div:first-child {
  position: relative;
  background: rgba(131, 24, 67, 0.55);
  backdrop-filter: blur(8px);
  border-radius: var(--radius-xl);
  padding: var(--space-xl) var(--space-2xl);
}
.hero-carousel { margin-top: calc(-1 * var(--header-h)); }
.hero-carousel .hero { padding-top: calc(var(--space-3xl) + var(--header-h)); }

.hero__eyebrow {
  color: rgba(255, 255, 255, 0.85);
  text-transform: uppercase;
  letter-spacing: 0.15em;
  font-size: 0.8rem;
  font-weight: 700;
  margin-bottom: var(--space-md);
}
.hero h1 { color: #fff; text-shadow: 0 2px 16px rgba(0, 0, 0, 0.2); }
.hero__lede {
  color: rgba(255,255,255,0.88);
  font-size: 1.1rem;
  max-width: 46ch;
}
.hero__actions { display: flex; gap: var(--space-md); flex-wrap: wrap; margin-top: var(--space-lg); }
.hero__visual {
  aspect-ratio: 4 / 5;
  background: rgba(255,255,255,0.1);
  border: 1px solid rgba(255,255,255,0.22);
  border-radius: var(--radius-xl);
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: var(--shadow-xl);
}

/* ---------------------------------------------------------------------- */
/* Hero carousel (item 2)                                                  */
/* ---------------------------------------------------------------------- */

.hero-carousel { position: relative; overflow: hidden; }
.hero-carousel__viewport { overflow: hidden; }
.hero-carousel__track {
  display: flex;
  transition: transform 1000ms cubic-bezier(0.65, 0, 0.35, 1);
}
@media (prefers-reduced-motion: reduce) {
  .hero-carousel__track { transition: none; }
}
.hero-carousel__slide {
  flex: 0 0 100%;
  min-width: 100%;
}
/* Slides 2-4 have no illustration column — center the copy instead of
   leaving the second grid track empty. */
.hero__inner--centered {
  grid-template-columns: 1fr;
  max-width: 720px;
  text-align: center;
  margin: 0 auto;
}
.hero__inner--centered .hero__actions { justify-content: center; }
.hero__inner--centered .hero__lede { margin-inline: auto; }

.hero--slide-2 { background: linear-gradient(135deg, var(--color-secondary) 0%, var(--color-primary) 100%); }
.hero--slide-3 { background: linear-gradient(150deg, var(--color-accent) 0%, var(--color-primary) 55%, var(--color-secondary) 100%); }
.hero--slide-4 {
  background: linear-gradient(160deg, var(--color-foreground) 0%, var(--color-primary) 55%, var(--color-accent) 100%);
}

.hero-carousel__control {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  width: 44px;
  height: 44px;
  border-radius: 999px;
  background: rgba(255,255,255,0.16);
  border: 1px solid rgba(255,255,255,0.35);
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 5;
  transition: background-color 150ms ease, transform 150ms ease;
}
.hero-carousel__control--prev { left: var(--space-lg); }
.hero-carousel__control--next { right: var(--space-lg); }
@media (hover: hover) and (pointer: fine) {
  .hero-carousel__control:hover { background: rgba(255,255,255,0.3); }
}
.hero-carousel__control:active { transform: translateY(-50%) scale(0.92); }

.hero-carousel__dots {
  position: absolute;
  bottom: var(--space-lg);
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  gap: var(--space-sm);
  z-index: 5;
}
.hero-carousel__dot {
  width: 10px;
  height: 10px;
  padding: 0;
  border: none;
  border-radius: 999px;
  background: rgba(255,255,255,0.4);
  transition: background-color 150ms ease, transform 150ms ease;
}
.hero-carousel__dot.is-active { background: #fff; transform: scale(1.3); }

@media (max-width: 767px) {
  .hero-carousel__control { width: 36px; height: 36px; }
  .hero-carousel__control--prev { left: var(--space-sm); }
  .hero-carousel__control--next { right: var(--space-sm); }
}

/* ---------------------------------------------------------------------- */
/* Animated bottle illustration (item 5)                                   */
/* ---------------------------------------------------------------------- */

/* Two nested wrappers so the one-shot entrance (on .hero__visual, via the
   shared hero-enter keyframe below) and the continuous idle loop (on
   .bottle-illustration) each own `transform` independently — stacking two
   animations on the *same* element would have one silently override the
   other since both would target `transform`. */
.bottle-illustration {
  position: relative;
  width: 45%;
  height: 45%;
  animation: bottle-float 4.5s var(--ease-in-out) infinite;
}
.bottle-illustration__glow {
  position: absolute;
  inset: 8% 12%;
  border-radius: 999px;
  background: radial-gradient(circle, rgba(255,255,255,0.6) 0%, rgba(255,255,255,0) 70%);
  opacity: 0.4;
  animation: bottle-glow 4.5s var(--ease-in-out) infinite;
  pointer-events: none;
}
.bottle-illustration__svg {
  position: relative;
  width: 100%;
  height: 100%;
  display: block;
  color: rgba(255, 255, 255, 0.92);
}

@keyframes bottle-float {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-8px); }
}
@keyframes bottle-glow {
  0%, 100% { opacity: 0.35; }
  50% { opacity: 0.65; }
}

/* ---------------------------------------------------------------------- */
/* Trust badge strip (item 4)                                              */
/* ---------------------------------------------------------------------- */

.trust-strip {
  background: var(--color-card);
  border-bottom: 1px solid var(--color-border);
}
.trust-strip__grid {
  max-width: 1280px;
  margin: 0 auto;
  padding: var(--space-xl) var(--space-lg);
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: var(--space-lg);
}
.trust-strip__item { display: flex; align-items: center; gap: var(--space-md); }
.trust-strip__icon {
  flex-shrink: 0;
  width: 40px;
  height: 40px;
  border-radius: 999px;
  background: rgba(236, 72, 153, 0.1);
  color: var(--color-accent);
  display: flex;
  align-items: center;
  justify-content: center;
}
.trust-strip__label { font-weight: 600; font-size: 0.88rem; color: var(--color-muted-foreground); }

@media (max-width: 1023px) {
  .trust-strip__grid { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 480px) {
  .trust-strip__grid { grid-template-columns: 1fr; padding-block: var(--space-lg); }
}

/* ---------------------------------------------------------------------- */
/* Horizontally-scrolling product rows (item 3)                           */
/* ---------------------------------------------------------------------- */

.product-scroller {
  position: relative;
  display: flex;
  align-items: center;
  gap: var(--space-md);
}
.product-scroller__track {
  display: flex;
  gap: var(--space-lg);
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  scroll-behavior: smooth;
  padding-block: 2px var(--space-sm);
  scrollbar-width: none;
}
.product-scroller__track::-webkit-scrollbar { display: none; }
.product-scroller__item {
  flex: 0 0 240px;
  scroll-snap-align: start;
}
.product-scroller__arrow {
  flex-shrink: 0;
  width: 44px;
  height: 44px;
  border-radius: 999px;
  border: 1px solid var(--color-border);
  background: var(--color-card);
  color: var(--color-foreground);
  display: flex;
  align-items: center;
  justify-content: center;
  transition: opacity 150ms ease, transform 130ms ease, border-color 150ms ease, color 150ms ease;
}
@media (hover: hover) and (pointer: fine) {
  .product-scroller__arrow:hover:not(:disabled) { border-color: var(--color-primary); color: var(--color-primary); }
}
.product-scroller__arrow:active:not(:disabled) { transform: scale(0.92); }
.product-scroller__arrow:disabled { opacity: 0.35; cursor: not-allowed; }

@media (max-width: 480px) {
  .product-scroller__item { flex-basis: 168px; }
}

/* ---------------------------------------------------------------------- */
/* Section headings                                                        */
/* ---------------------------------------------------------------------- */

.section { padding: var(--space-3xl) 0; }
.section--muted { background: var(--color-card); }
.section__head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: var(--space-md);
  margin-bottom: var(--space-xl);
  flex-wrap: wrap;
}
.section__head h2 { margin-bottom: var(--space-xs); }
.section__subtitle { color: var(--color-muted-foreground); margin: 0; }

/* ---------------------------------------------------------------------- */
/* Customer testimonials                                                   */
/* ---------------------------------------------------------------------- */
.testimonials__heading {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  gap: 0.4em;
  text-align: center;
  max-width: 760px;
  margin: 0 auto var(--space-xl);
  font-size: clamp(1.8rem, 4vw, 2.6rem);
}
.testimonials__heading-thumb {
  display: inline-flex;
  width: 1.4em;
  height: 1.4em;
  border-radius: 50%;
  overflow: hidden;
  flex-shrink: 0;
  box-shadow: var(--shadow-sm);
}
.testimonials__heading-thumb img { width: 100%; height: 100%; object-fit: contain; background: var(--color-muted); }

.testimonial-card {
  display: flex;
  flex-direction: column;
  height: 100%;
  background: var(--color-card);
  border-radius: var(--radius-lg);
  overflow: hidden;
  box-shadow: var(--shadow-sm);
}
.testimonial-card__media {
  aspect-ratio: 4 / 3;
  background: var(--color-muted);
  display: flex;
  align-items: center;
  justify-content: center;
}
.testimonial-card__media img { width: 100%; height: 100%; object-fit: contain; }
.testimonial-card__body {
  padding: var(--space-lg);
  display: flex;
  flex-direction: column;
  gap: 6px;
  flex: 1;
}
.testimonial-card__author { display: flex; align-items: center; gap: var(--space-sm); flex-wrap: wrap; }
.testimonial-card__verified {
  font-size: 0.72rem;
  font-weight: 600;
  color: var(--color-accent);
  text-transform: uppercase;
  letter-spacing: 0.04em;
}
.testimonial-card__stars svg { width: 14px; height: 14px; }
.testimonial-card__quote {
  color: var(--color-muted-foreground);
  font-size: 0.92rem;
  flex: 1;
  margin: 0;
}
.testimonial-card__product {
  font-size: 0.82rem;
  font-weight: 600;
  color: var(--color-primary);
  text-decoration: underline;
  align-self: flex-start;
}

/* ---------------------------------------------------------------------- */
/* Category tiles                                                          */
/* ---------------------------------------------------------------------- */

.category-tiles {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: var(--space-lg);
}
.category-tile {
  background: linear-gradient(135deg, var(--color-primary) 0%, var(--color-accent) 100%);
  color: var(--color-on-primary);
  border-radius: var(--radius-lg);
  padding: var(--space-2xl) var(--space-xl);
  display: block;
  position: relative;
  overflow: hidden;
  box-shadow: var(--shadow-md);
  transition: box-shadow 150ms ease, transform 150ms ease;
  min-height: 180px;
}
@media (hover: hover) and (pointer: fine) {
  .category-tile:hover {
    box-shadow: var(--shadow-xl);
    transform: translateY(-2px);
    text-decoration: none;
  }
}
.category-tile--photo {
  background-size: cover;
  background-position: center;
}
.category-tile h3 { color: var(--color-on-primary); margin-bottom: var(--space-sm); }
.category-tile p { color: rgba(0, 0, 0, 0.65); margin: 0; }
.category-tile--photo h3 { color: #fff; }
.category-tile--photo p { color: rgba(255, 255, 255, 0.85); }
.category-tile__accent {
  position: absolute;
  bottom: -30px;
  right: -30px;
  width: 140px;
  height: 140px;
  border-radius: 999px;
  background: #fff;
  opacity: 0.18;
}

.gender-tiles {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: var(--space-lg);
}
.gender-card {
  display: block;
  position: relative;
  min-height: 340px;
  border-radius: var(--radius-lg);
  background-size: cover;
  background-position: center;
  box-shadow: var(--shadow-md);
  overflow: hidden;
  transition: box-shadow 150ms ease, transform 150ms ease;
}
@media (hover: hover) and (pointer: fine) {
  .gender-card:hover {
    box-shadow: var(--shadow-xl);
    transform: translateY(-2px);
    text-decoration: none;
  }
}
.gender-card__body {
  position: absolute;
  inset: auto 0 0 0;
  padding: var(--space-xl) var(--space-lg);
  display: flex;
  flex-direction: column;
  gap: var(--space-xs);
}
.gender-card__label {
  font-family: var(--font-display);
  font-size: 1.5rem;
  font-weight: 600;
  color: #fff;
}
.gender-card__tagline {
  color: rgba(255, 255, 255, 0.85);
  font-size: 0.9rem;
  line-height: 1.5;
}
.gender-card__cta {
  display: inline-flex;
  align-items: center;
  gap: var(--space-xs);
  margin-top: var(--space-sm);
  color: #fff;
  font-weight: 600;
  font-size: 0.9rem;
}
@media (max-width: 860px) {
  .gender-tiles { grid-template-columns: 1fr; }
}

.subcategory-chips {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-sm);
  margin-bottom: var(--space-xl);
}
.subcategory-chip {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  padding: var(--space-sm) var(--space-md);
  border-radius: 999px;
  border: 1px solid var(--color-border);
  background: var(--color-card);
  color: var(--color-muted-foreground);
  font-size: 0.9rem;
  font-weight: 500;
  transition: all var(--transition-fast);
}
.subcategory-chip:hover { border-color: var(--color-primary); color: var(--color-primary); text-decoration: none; }
.subcategory-chip.is-active {
  background: var(--color-primary);
  border-color: var(--color-primary);
  color: var(--color-on-primary);
}

/* ---------------------------------------------------------------------- */
/* Product grid & card                                                     */
/* ---------------------------------------------------------------------- */

.product-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
  gap: var(--space-lg);
}

.product-card {
  background: var(--color-card);
  border-radius: var(--radius-lg);
  overflow: hidden;
  box-shadow: var(--shadow-md);
  transition: box-shadow 150ms ease, transform 150ms ease;
  display: flex;
  flex-direction: column;
  height: 100%;
  position: relative;
}

/* The favorite-toggle form is a sibling of .product-card__link (see the
   comment in partials/product-card.php for why), positioned to sit visibly
   on top of the card's image corner without being a descendant of the <a>. */
.product-card__favorite-form {
  position: absolute;
  top: var(--space-sm);
  right: var(--space-sm);
  z-index: 2;
  margin: 0;
}
.product-card__favorite-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
  padding: 0;
  border: none;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.85);
  color: var(--color-foreground);
  box-shadow: var(--shadow-sm);
  cursor: pointer;
  transition: transform 130ms var(--ease-out), background 150ms ease, color 150ms ease;
}
.product-card__favorite-btn.is-active { color: var(--color-primary); }
@media (hover: hover) and (pointer: fine) {
  .product-card__favorite-btn:hover { background: #fff; transform: scale(1.08); }
}
.product-card__favorite-btn:active { transform: scale(0.92); }
/* Product card hover happens dozens of times a day while browsing — keep it
   near-imperceptible, and gate it behind real hover support so a touch tap
   never gets stuck in a fake "hovered" state. */
@media (hover: hover) and (pointer: fine) {
  .product-card:hover { box-shadow: var(--shadow-lg); transform: translateY(-2px); }
}

.product-card__link { color: inherit; display: flex; flex-direction: column; height: 100%; }
.product-card__link:hover { text-decoration: none; }

.product-card__media {
  aspect-ratio: 1 / 1;
  background: var(--color-muted);
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
}
.product-card__media img { width: 100%; height: 100%; object-fit: contain; }

.product-card__body {
  padding: var(--space-md) var(--space-lg) var(--space-lg);
  display: flex;
  flex-direction: column;
  gap: 4px;
  flex: 1;
}
.product-card__brand {
  display: block;
  font-size: 0.7rem;
  font-weight: 700;
  color: var(--color-accent);
  text-transform: uppercase;
  letter-spacing: 0.1em;
  margin-bottom: 2px;
}
.product-card__code {
  font-size: 0.75rem;
  color: var(--color-muted-foreground);
  text-transform: uppercase;
  letter-spacing: 0.08em;
}
.product-card__name {
  font-family: var(--font-display);
  font-size: 1.2rem;
  font-weight: 600;
  color: var(--color-foreground);
  margin: 0;
}
.product-card__price {
  margin-top: auto;
  padding-top: var(--space-sm);
  font-weight: 700;
  color: var(--color-primary);
}
.product-card__price small {
  font-weight: 500;
  color: var(--color-muted-foreground);
  margin-right: 4px;
}

.product-card__rating {
  display: flex;
  align-items: center;
  gap: 4px;
  margin-top: 2px;
}
.product-card__rating .star-rating__star { width: 13px; height: 13px; }
.product-card__rating-count { font-size: 0.75rem; color: var(--color-muted-foreground); }

/* Quick-add: shows every size ("contenance") right on the card, with an
   Add button — a sibling of .product-card__link, never nested inside it
   (see the comment at the top of partials/product-card.php). */
.product-card__quick-add {
  display: flex;
  align-items: center;
  gap: var(--space-sm);
  padding: 0 var(--space-lg) var(--space-lg);
  margin-top: calc(-1 * var(--space-sm));
}
.product-card__variant-pills {
  display: flex;
  flex-wrap: wrap;
  gap: 4px;
  flex: 1;
}
.product-card__variant-pill {
  position: relative;
  font-size: 0.72rem;
  font-weight: 600;
  color: var(--color-muted-foreground);
  border: 1px solid var(--color-border);
  border-radius: 999px;
  padding: 3px 9px;
  cursor: pointer;
  transition: border-color 130ms ease, color 130ms ease, background 130ms ease;
}
.product-card__variant-pill input {
  position: absolute;
  opacity: 0;
  width: 1px;
  height: 1px;
}
.product-card__variant-pill:has(input:checked) {
  border-color: var(--color-primary);
  color: var(--color-primary);
  background: var(--color-secondary);
}
.product-card__variant-pill:has(input:focus-visible) {
  outline: 2px solid var(--color-ring);
  outline-offset: 1px;
}
.product-card__add-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 4px;
  flex-shrink: 0;
  min-width: 44px;
  min-height: 36px;
  padding: 0 10px;
  border: none;
  border-radius: var(--radius-md);
  background: var(--color-primary);
  color: var(--color-on-primary);
  font-size: 0.78rem;
  font-weight: 700;
  cursor: pointer;
  transition: transform 130ms var(--ease-out), background 150ms ease;
}
.product-card__add-btn span { display: none; }
@media (hover: hover) and (pointer: fine) {
  .product-card__add-btn:hover { background: var(--color-accent); }
}
.product-card__add-btn:active { transform: scale(0.94); }

/* ---------------------------------------------------------------------- */
/* Filter / sort bar                                                       */
/* ---------------------------------------------------------------------- */

.filter-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-md);
  flex-wrap: wrap;
  margin-bottom: var(--space-lg);
}
.filter-bar__count { color: var(--color-muted-foreground); font-size: 0.9rem; }
.filter-bar__sort { display: flex; align-items: center; gap: var(--space-sm); }
.filter-bar__sort label { font-size: 0.9rem; color: var(--color-muted-foreground); font-weight: 500; }

.breadcrumbs {
  font-size: 0.85rem;
  color: var(--color-muted-foreground);
  margin-bottom: var(--space-lg);
}
.breadcrumbs a { color: var(--color-muted-foreground); }
.breadcrumbs a:hover { color: var(--color-primary); }
.breadcrumbs__sep { margin: 0 6px; }

/* ---------------------------------------------------------------------- */
/* Inputs / selects / textarea                                             */
/* ---------------------------------------------------------------------- */

label {
  display: block;
  font-weight: 600;
  font-size: 0.9rem;
  color: var(--color-foreground);
  margin-bottom: 6px;
}

.input, select.input, textarea.input {
  width: 100%;
  min-height: 44px;
  padding: 12px 16px;
  border: 1px solid var(--color-border);
  border-radius: var(--radius-md);
  font-size: 16px;
  font-family: inherit;
  background: var(--color-card);
  color: var(--color-foreground);
  transition: border-color var(--transition-base), box-shadow var(--transition-base);
}
textarea.input { min-height: 100px; resize: vertical; }
.input:focus {
  border-color: var(--color-primary);
  outline: none;
  box-shadow: 0 0 0 3px rgba(236, 72, 153, 0.15);
}
.input.has-error { border-color: var(--color-destructive); }

.form-field { margin-bottom: var(--space-lg); }
.form-error {
  color: var(--color-destructive);
  font-size: 0.85rem;
  margin-top: 4px;
}
.form-hint { color: var(--color-muted-foreground); font-size: 0.85rem; margin-top: 4px; }
.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: var(--space-lg); }

.alert {
  border-radius: var(--radius-md);
  padding: var(--space-md) var(--space-lg);
  margin-bottom: var(--space-lg);
  font-size: 0.95rem;
}
.alert--error {
  background: #FEF2F2;
  color: #7F1D1D;
  border: 1px solid #FCA5A5;
}
.alert--success {
  background: #F0FDF4;
  color: #14532D;
  border: 1px solid #86EFAC;
}

/* ---------------------------------------------------------------------- */
/* Product detail page                                                     */
/* ---------------------------------------------------------------------- */

.product-detail {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: var(--space-2xl);
  align-items: start;
}
.product-detail__gallery {
  position: sticky;
  top: calc(var(--header-h) + var(--space-lg));
}
.product-detail__media {
  aspect-ratio: 1 / 1;
  background: var(--color-card);
  border-radius: var(--radius-xl);
  box-shadow: var(--shadow-md);
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
}
.product-detail__media img { width: 100%; height: 100%; object-fit: contain; }
.product-detail__favorite-form {
  position: absolute;
  top: var(--space-md);
  right: var(--space-md);
  z-index: 2;
  margin: 0;
}
.product-detail__thumbs {
  display: flex;
  gap: var(--space-sm);
  margin-top: var(--space-sm);
  flex-wrap: wrap;
}
.product-detail__thumb {
  width: 64px;
  height: 64px;
  flex-shrink: 0;
  padding: 0;
  border: 2px solid transparent;
  border-radius: var(--radius-md);
  background: var(--color-card);
  box-shadow: var(--shadow-sm);
  cursor: pointer;
  overflow: hidden;
  transition: border-color 130ms ease;
}
.product-detail__thumb img { width: 100%; height: 100%; object-fit: contain; }
.product-detail__thumb.is-active { border-color: var(--color-primary); }
.product-detail__thumb:focus-visible { outline: 2px solid var(--color-ring); outline-offset: 1px; }

.product-detail__brand {
  color: var(--color-accent);
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  font-size: 0.8rem;
  margin-bottom: 4px;
}
.product-detail__code {
  color: var(--color-primary);
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  font-size: 0.85rem;
  margin-bottom: var(--space-sm);
}
.product-detail__desc { color: var(--color-muted-foreground); font-size: 1.02rem; }
.olfactory-pyramid {
  margin-top: var(--space-lg);
  padding: var(--space-md) var(--space-lg);
  background: var(--color-muted);
  border-radius: var(--radius-md);
}
.olfactory-pyramid__title {
  font-family: var(--font-body);
  font-size: 0.8rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--color-foreground);
  margin-bottom: var(--space-sm);
}
.olfactory-pyramid__list { list-style: none; padding: 0; margin: 0; display: flex; flex-direction: column; gap: 4px; }
.olfactory-pyramid__list li { color: var(--color-muted-foreground); font-size: 0.92rem; }
.olfactory-pyramid__list strong { color: var(--color-foreground); }
.olfactory-pyramid--with-media {
  display: grid;
  grid-template-columns: 1fr 1fr;
  align-items: center;
  gap: var(--space-lg);
  padding: var(--space-lg);
}
.olfactory-pyramid__media {
  aspect-ratio: 1 / 1;
  border-radius: var(--radius-md);
  overflow: hidden;
}
.olfactory-pyramid__media img { width: 100%; height: 100%; object-fit: cover; display: block; }
@media (max-width: 640px) {
  .olfactory-pyramid--with-media { grid-template-columns: 1fr; }
}
.product-detail__price {
  font-size: 1.6rem;
  font-weight: 700;
  color: var(--color-primary);
  margin: var(--space-md) 0;
}

.variant-selector { margin: var(--space-lg) 0; }
.variant-selector__legend {
  font-weight: 600;
  color: var(--color-foreground);
  margin-bottom: var(--space-sm);
  display: block;
}
.variant-selector__options {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-sm);
}
.variant-option { position: relative; }
.variant-option input[type="radio"] {
  position: absolute;
  opacity: 0;
  width: 44px;
  height: 44px;
  margin: 0;
  top: 0;
  left: 0;
  cursor: pointer;
}
.variant-option label {
  display: inline-flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  min-width: 88px;
  min-height: 56px;
  padding: var(--space-sm) var(--space-md);
  border: 2px solid var(--color-border);
  border-radius: var(--radius-md);
  font-weight: 600;
  font-size: 0.9rem;
  color: var(--color-muted-foreground);
  transition: all var(--transition-fast);
  margin: 0;
}
.variant-option label small { font-weight: 500; color: var(--color-muted-foreground); }
.variant-option input[type="radio"]:checked + label {
  border-color: var(--color-primary);
  background: rgba(236, 72, 153, 0.08);
  color: var(--color-foreground);
}
.variant-option input[type="radio"]:focus-visible + label {
  outline: 3px solid var(--color-primary);
  outline-offset: 2px;
}

.qty-stepper {
  display: inline-flex;
  align-items: stretch;
  border: 1px solid var(--color-border);
  border-radius: var(--radius-md);
  overflow: hidden;
}
.qty-stepper button {
  min-width: 44px;
  min-height: 44px;
  border: none;
  background: var(--color-card);
  color: var(--color-foreground);
  font-size: 1.1rem;
  font-weight: 600;
  transition: background-color var(--transition-fast), transform 120ms ease;
}
@media (hover: hover) and (pointer: fine) {
  .qty-stepper button:hover { background: var(--color-muted); }
}
/* Press feedback on the +/- stepper buttons — used often per checkout, so
   kept minimal: scale only, 120ms. */
.qty-stepper button:active { background: var(--color-muted); transform: scale(0.92); }
.qty-stepper input {
  width: 52px;
  min-height: 44px;
  border: none;
  border-left: 1px solid var(--color-border);
  border-right: 1px solid var(--color-border);
  text-align: center;
  font-weight: 600;
  font-size: 1rem;
  -moz-appearance: textfield;
}

.product-detail__actions {
  display: flex;
  align-items: center;
  gap: var(--space-md);
  margin-top: var(--space-lg);
  flex-wrap: wrap;
}

.trust-badges {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-lg);
  margin-top: var(--space-xl);
  padding-top: var(--space-xl);
  border-top: 1px solid var(--color-border);
}
.trust-badge { display: flex; align-items: center; gap: var(--space-sm); color: var(--color-muted-foreground); font-size: 0.85rem; }
.trust-badge svg { color: var(--color-accent); flex-shrink: 0; }

/* ---------------------------------------------------------------------- */
/* Star ratings + product reviews                                         */
/* ---------------------------------------------------------------------- */

.star-rating { display: inline-flex; align-items: center; gap: 2px; color: var(--color-border); }
.star-rating__star.is-filled { color: var(--color-star); }

.product-rating-badge {
  display: inline-flex;
  align-items: center;
  gap: var(--space-xs);
  margin: var(--space-sm) 0 var(--space-md);
  color: var(--color-foreground);
  font-weight: 700;
}
.product-rating-badge span { color: var(--color-muted-foreground); font-weight: 500; font-size: 0.9rem; }
@media (hover: hover) and (pointer: fine) {
  .product-rating-badge:hover { color: var(--color-primary); }
}

.reviews-section { border-top: 1px solid var(--color-border); }

.review-list { display: flex; flex-direction: column; gap: var(--space-lg); }
.review-item {
  background: var(--color-card);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-sm);
  padding: var(--space-lg);
}
.review-item__head { display: flex; align-items: center; flex-wrap: wrap; gap: var(--space-sm); margin-bottom: var(--space-sm); }
.review-item__name { color: var(--color-foreground); }
.review-item__date { color: var(--color-muted-foreground); font-size: 0.85rem; margin-left: auto; }
.review-item__body { margin: 0; color: var(--color-muted-foreground); }

.review-more { margin-top: var(--space-lg); }
.review-more__summary {
  cursor: pointer;
  font-weight: 600;
  color: var(--color-primary);
  list-style: none;
  min-height: 44px;
  display: inline-flex;
  align-items: center;
}
.review-more__summary::-webkit-details-marker { display: none; }
.review-list--more { margin-top: var(--space-lg); }
/* Revealed content fades/rises in on open — transform + opacity only,
   respects reduced-motion via the global rule at the bottom of this file. */
@keyframes review-reveal {
  from { opacity: 0; transform: translateY(-6px); }
  to { opacity: 1; transform: translateY(0); }
}
.review-more[open] .review-list--more { animation: review-reveal 220ms var(--ease-out) both; }

.review-form-wrap { margin-top: var(--space-2xl); max-width: 560px; }
.review-form {
  background: var(--color-card);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-sm);
  padding: var(--space-xl);
}
.review-form h3 { margin-bottom: var(--space-md); }
.review-login-prompt { color: var(--color-muted-foreground); }
.form-field-legend {
  font-weight: 600;
  color: var(--color-foreground);
  margin-bottom: var(--space-sm);
  padding: 0;
  display: block;
}

/* Star-select rating input: five radio+label pairs in reverse DOM order
   (5..1) laid out row-reverse so they read left-to-right as 1..5, letting
   ":checked ~ label" and ":hover ~ label" highlight every star up to and
   including the targeted one with plain sibling selectors, no JS. */
.star-select {
  display: flex;
  flex-direction: row-reverse;
  justify-content: flex-end;
  gap: 4px;
  border: none;
  margin: 0 0 var(--space-lg);
  padding: 0;
}
.star-select input {
  position: absolute;
  opacity: 0;
  width: 1px;
  height: 1px;
}
.star-select label {
  color: var(--color-border);
  cursor: pointer;
  min-width: 32px;
  min-height: 32px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  transition: color 150ms var(--ease-out);
}
.star-select input:checked ~ label { color: var(--color-star); }
.star-select input:focus-visible + label { outline: 3px solid var(--color-primary); outline-offset: 2px; border-radius: var(--radius-sm); }
@media (hover: hover) and (pointer: fine) {
  .star-select label:hover,
  .star-select label:hover ~ label { color: var(--color-star); }
}

/* ---------------------------------------------------------------------- */
/* Cart page                                                               */
/* ---------------------------------------------------------------------- */

.cart-layout {
  display: grid;
  grid-template-columns: 2fr 1fr;
  gap: var(--space-2xl);
  align-items: start;
}

.cart-item {
  display: grid;
  grid-template-columns: 72px 1fr auto;
  gap: var(--space-md);
  align-items: center;
  padding: var(--space-lg) 0;
  border-bottom: 1px solid var(--color-border);
}
.cart-item__media {
  width: 72px;
  height: 72px;
  border-radius: var(--radius-md);
  background: var(--color-muted);
  display: flex;
  align-items: center;
  justify-content: center;
}
.cart-item__media img { width: 100%; height: 100%; object-fit: contain; }
.cart-item__name { font-weight: 600; color: var(--color-foreground); }
.cart-item__meta { color: var(--color-muted-foreground); font-size: 0.85rem; }
.cart-item__controls {
  display: flex;
  align-items: center;
  gap: var(--space-md);
  flex-wrap: wrap;
  margin-top: var(--space-sm);
}
.cart-item__price { text-align: right; font-weight: 700; color: var(--color-foreground); white-space: nowrap; }

.cart-summary {
  background: var(--color-card);
  border-radius: var(--radius-lg);
  padding: var(--space-xl);
  box-shadow: var(--shadow-md);
  position: sticky;
  top: calc(var(--header-h) + var(--space-lg));
}
.cart-summary__row {
  display: flex;
  justify-content: space-between;
  margin-bottom: var(--space-sm);
  color: var(--color-muted-foreground);
}
.cart-summary__row--total {
  font-weight: 700;
  font-size: 1.2rem;
  color: var(--color-primary);
  padding-top: var(--space-md);
  margin-top: var(--space-md);
  border-top: 1px solid var(--color-border);
}

.empty-state {
  text-align: center;
  padding: var(--space-3xl) var(--space-lg);
  color: var(--color-muted-foreground);
}
.empty-state svg { color: var(--color-border); margin-bottom: var(--space-md); }

/* ---------------------------------------------------------------------- */
/* Checkout / confirmation                                                 */
/* ---------------------------------------------------------------------- */

.checkout-layout {
  display: grid;
  grid-template-columns: 1.4fr 1fr;
  gap: var(--space-2xl);
  align-items: start;
}

.order-summary-list { margin-bottom: var(--space-md); }
.order-summary-item {
  display: flex;
  align-items: center;
  gap: var(--space-md);
  padding: var(--space-sm) 0;
  border-bottom: 1px solid var(--color-border);
  font-size: 0.9rem;
}
.order-summary-item__media {
  width: 48px;
  height: 48px;
  border-radius: var(--radius-md);
  background: var(--color-muted);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  overflow: hidden;
}
.order-summary-item__media img { width: 100%; height: 100%; object-fit: contain; }
.order-summary-item__info { flex: 1; min-width: 0; }
.order-summary-item__price { flex-shrink: 0; }
.order-summary-item__name { color: var(--color-foreground); font-weight: 600; }
.order-summary-item__meta { color: var(--color-muted-foreground); }

/* Checkout sections — one <fieldset> per step (address, contact,
   delivery), each fading/rising in on load with a short stagger. The
   sitewide prefers-reduced-motion rule (top of this file) already forces
   every animation-duration to ~0, so no separate reduced-motion override
   is needed here. */
.checkout-fieldset {
  border: none;
  padding: 0;
  margin: 0 0 var(--space-xl);
  opacity: 0;
  transform: translateY(10px);
  animation: checkout-fieldset-enter 340ms cubic-bezier(0.23, 1, 0.32, 1) forwards;
}
form fieldset.checkout-fieldset:nth-of-type(1) { animation-delay: 0ms; }
form fieldset.checkout-fieldset:nth-of-type(2) { animation-delay: 70ms; }
form fieldset.checkout-fieldset:nth-of-type(3) { animation-delay: 140ms; }
/* .checkout-fieldset's own padding:0 (meant for <fieldset>s, which get
   their spacing from the form-field children instead) would otherwise
   strip .cart-summary's card padding too, since this element carries both
   classes — put it back at the same higher specificity used for its
   animation-delay override just above. */
aside.checkout-fieldset { animation-delay: 200ms; padding: var(--space-xl); }
@keyframes checkout-fieldset-enter {
  to { opacity: 1; transform: translateY(0); }
}
.checkout-fieldset__heading {
  display: flex;
  align-items: center;
  gap: var(--space-sm);
  font-family: var(--font-display);
  font-size: 1.05rem;
  color: var(--color-foreground);
  padding: 0;
  margin-bottom: var(--space-md);
}
.checkout-fieldset__icon {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background: var(--color-muted);
  color: var(--color-primary);
  flex-shrink: 0;
}

/* Phone: country-code + flag select paired with the number input. */
.phone-input {
  display: flex;
  gap: var(--space-sm);
}
select.phone-input__code {
  flex: 0 0 auto;
  width: 108px;
  min-height: 44px;
}
.phone-input > .combo { flex: 0 0 auto; width: 118px; }
.phone-input__number { flex: 1 1 0%; min-width: 0; width: auto; }

/* Delivery method cards. */
.shipping-options {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: var(--space-md);
}
.shipping-card {
  position: relative;
  display: flex;
  align-items: center;
  gap: var(--space-md);
  padding: var(--space-md) var(--space-lg);
  border: 2px solid var(--color-border);
  border-radius: var(--radius-lg);
  background: var(--color-card);
  cursor: pointer;
  transition: border-color 180ms ease, background-color 180ms ease, transform 180ms cubic-bezier(0.23, 1, 0.32, 1), box-shadow 180ms ease;
}
@media (hover: hover) and (pointer: fine) {
  .shipping-card:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-md);
    border-color: var(--color-primary);
  }
}
.shipping-card input[type="radio"] {
  position: absolute;
  inset: 0;
  opacity: 0;
  margin: 0;
  cursor: pointer;
}
.shipping-card:has(input:checked) {
  border-color: var(--color-primary);
  background: rgba(236, 72, 153, 0.06);
  box-shadow: var(--shadow-sm);
}
.shipping-card:has(input:focus-visible) {
  outline: 3px solid var(--color-primary);
  outline-offset: 2px;
}
.shipping-card__icon {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: var(--color-muted);
  color: var(--color-primary);
  flex-shrink: 0;
  transition: background-color 180ms ease, color 180ms ease, transform 180ms cubic-bezier(0.23, 1, 0.32, 1);
}
.shipping-card:has(input:checked) .shipping-card__icon {
  background: var(--color-primary);
  color: #fff;
  transform: scale(1.08);
}
.shipping-card__body { flex: 1; min-width: 0; }
.shipping-card__title { display: block; font-weight: 600; color: var(--color-foreground); }
.shipping-card__price { font-weight: 700; color: var(--color-foreground); white-space: nowrap; }
.shipping-card__check {
  position: absolute;
  top: 10px;
  right: 10px;
  width: 20px;
  height: 20px;
  border-radius: 50%;
  background: var(--color-primary);
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  transform: scale(0.6);
  transition: opacity 160ms ease-out, transform 160ms cubic-bezier(0.23, 1, 0.32, 1);
}
.shipping-card:has(input:checked) .shipping-card__check {
  opacity: 1;
  transform: scale(1);
}

/* Live total/shipping price update pulse — triggered by adding this
   class in main.js when the shown amount actually changes (see the
   shipping-method change handler). Text swap itself is instant (the
   correctness doesn't depend on the animation), this is a purely
   decorative highlight on top. */
@keyframes price-pulse {
  0% { transform: scale(1); }
  35% { transform: scale(1.1); color: var(--color-primary); }
  100% { transform: scale(1); }
}
.price-pulse { display: inline-block; animation: price-pulse 260ms cubic-bezier(0.23, 1, 0.32, 1); }

/* Submit button loading state (see main.js) — swaps in a small spinner
   next to the label instead of disabling with no feedback. */
.btn-primary[data-checkout-submit] { position: relative; }
.btn-primary[data-checkout-submit].is-loading { color: transparent; pointer-events: none; }
.btn-primary[data-checkout-submit].is-loading::after {
  content: '';
  position: absolute;
  top: 50%;
  left: 50%;
  width: 20px;
  height: 20px;
  margin: -10px 0 0 -10px;
  border: 2.5px solid rgba(0, 0, 0, 0.25);
  border-top-color: currentColor;
  color: var(--color-on-primary);
  border-radius: 50%;
  animation: btn-spin 700ms linear infinite;
}
@keyframes btn-spin {
  to { transform: rotate(360deg); }
}

.confirmation-hero {
  text-align: center;
  max-width: 640px;
  margin: 0 auto;
  padding: var(--space-2xl) 0;
}
.confirmation-hero__icon {
  width: 72px;
  height: 72px;
  border-radius: 999px;
  background: rgba(139, 92, 246, 0.14);
  color: var(--color-accent);
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto var(--space-lg);
}
.confirmation-order-number {
  font-family: var(--font-display);
  font-size: 1.6rem;
  color: var(--color-accent);
  font-weight: 700;
}

/* ---------------------------------------------------------------------- */
/* Order tracking                                                         */
/* ---------------------------------------------------------------------- */

.track-page { max-width: 760px; margin-inline: auto; }

.track-hero { text-align: center; padding-bottom: var(--space-xl); }
.track-hero__icon {
  width: 64px;
  height: 64px;
  border-radius: 999px;
  background: rgba(236, 72, 153, 0.12);
  color: var(--color-primary);
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto var(--space-md);
}
.track-hero h1 { margin-bottom: var(--space-xs); }
.track-hero .section__subtitle { max-width: 480px; margin-inline: auto; }

.track-search-card {
  background: var(--color-card);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-md);
  padding: var(--space-xl);
}
.track-search-form { margin: 0; }
.field-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: var(--space-lg);
}
.field-grid--single { grid-template-columns: 1fr; }
@media (max-width: 640px) {
  .field-grid { grid-template-columns: 1fr; }
}
.track-search-form__account-note {
  display: flex;
  align-items: center;
  gap: 6px;
  color: var(--color-muted-foreground);
  font-size: 0.88rem;
  margin: calc(-1 * var(--space-md)) 0 var(--space-lg);
}
.track-search-form__account-note svg { flex-shrink: 0; color: var(--color-primary); }
.track-search-form__submit { width: 100%; }
@media (min-width: 480px) {
  .track-search-form__submit { width: auto; }
}

.track-alert { margin-top: var(--space-lg); }

.track-result {
  background: var(--color-card);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-md);
  padding: var(--space-xl);
  margin-top: var(--space-lg);
}
.track-result__head {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-md);
  margin-bottom: var(--space-xl);
}
.track-result__label {
  font-family: var(--font-display);
  font-size: 1.3rem;
  font-weight: 700;
  color: var(--color-foreground);
}
.track-result__date { color: var(--color-muted-foreground); font-size: 0.9rem; margin-top: 2px; }
.track-result__hint {
  color: var(--color-muted-foreground);
  font-size: 0.88rem;
  text-align: center;
  margin-top: var(--space-md);
}
.track-result__details { margin-top: var(--space-2xl); padding-top: var(--space-xl); border-top: 1px solid var(--color-border); }

.order-status-track {
  display: flex;
  align-items: flex-start;
  justify-content: center;
  gap: 0;
  max-width: 360px;
  margin: 0 auto;
}
.order-status-step {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: var(--space-sm);
  text-align: center;
  width: 120px;
}
.order-status-step__icon {
  width: 36px;
  height: 36px;
  border-radius: 999px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--color-muted);
  color: var(--color-muted-foreground);
}
.order-status-step.is-complete .order-status-step__icon { background: #DCFCE7; color: #14532D; }
.order-status-step.is-current .order-status-step__icon { background: #FEF3C7; color: #92400E; }
.order-status-step.is-cancelled .order-status-step__icon { background: #FEE2E2; color: #7F1D1D; }
.order-status-step__label { font-size: 0.82rem; font-weight: 600; color: var(--color-foreground); }
.order-status-step__connector {
  height: 2px;
  flex: 1;
  background: var(--color-border);
  margin-top: 17px;
}
.order-status-step__connector.is-complete { background: #86EFAC; }
.order-status-step__connector.is-cancelled { background: #FCA5A5; }

/* ---------------------------------------------------------------------- */
/* Contact                                                                 */
/* ---------------------------------------------------------------------- */

.contact-page { max-width: 960px; margin-inline: auto; }
.contact-layout {
  display: grid;
  grid-template-columns: 1.6fr 1fr;
  gap: var(--space-2xl);
  align-items: start;
}
@media (max-width: 860px) {
  .contact-layout { grid-template-columns: 1fr; }
}
.contact-aside { display: flex; flex-direction: column; gap: var(--space-lg); }
.contact-aside__card {
  background: var(--color-card);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-sm);
  padding: var(--space-lg);
}
.contact-aside__card h2 { font-size: 1rem; margin-bottom: var(--space-xs); }
.contact-aside__card p { font-size: 0.9rem; margin-bottom: var(--space-md); }
.contact-aside__card:last-child p { margin-bottom: 0; }
.contact-aside__card .btn-secondary { margin-top: var(--space-xs); }

/* ---------------------------------------------------------------------- */
/* FAQ                                                                     */
/* ---------------------------------------------------------------------- */

.faq-page { max-width: 760px; margin-inline: auto; }
.faq-group { margin-top: var(--space-2xl); }
.faq-group__heading {
  font-size: 0.85rem;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--color-muted-foreground);
  margin-bottom: var(--space-md);
}
.faq-item {
  background: var(--color-card);
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-sm);
  margin-bottom: var(--space-sm);
  overflow: hidden;
}
.faq-item__question {
  list-style: none;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-md);
  padding: var(--space-md) var(--space-lg);
  font-weight: 600;
  color: var(--color-foreground);
  cursor: pointer;
}
.faq-item__question::-webkit-details-marker { display: none; }
.faq-item__question::after {
  content: '+';
  flex-shrink: 0;
  font-size: 1.3rem;
  line-height: 1;
  color: var(--color-primary);
  transition: transform 150ms ease;
}
.faq-item[open] .faq-item__question::after { transform: rotate(45deg); }
.faq-item__answer { padding: 0 var(--space-lg) var(--space-lg); }
.faq-item__answer p { color: var(--color-muted-foreground); margin: 0; }
.faq-item__answer a { color: var(--color-primary); }

/* ---------------------------------------------------------------------- */
/* Page banner (decorative photo atop a static content page)              */
/* ---------------------------------------------------------------------- */

.page-banner {
  border-radius: var(--radius-lg);
  overflow: hidden;
  margin-bottom: var(--space-xl);
  box-shadow: var(--shadow-md);
}
.page-banner img {
  display: block;
  width: 100%;
  height: 260px;
  object-fit: cover;
}
@media (max-width: 640px) {
  .page-banner img { height: 160px; }
}

/* ---------------------------------------------------------------------- */
/* Header account links / admin tab bar                                   */
/* ---------------------------------------------------------------------- */

.site-header__account {
  display: flex;
  align-items: center;
  gap: var(--space-md);
  font-size: 0.9rem;
}
.account-link { color: inherit; opacity: 0.85; min-height: 44px; display: inline-flex; align-items: center; }

.locale-switch { margin-right: var(--space-sm); }
.locale-switch__summary {
  font-size: 0.78rem;
  font-weight: 600;
  letter-spacing: 0.02em;
  gap: 6px;
  padding: var(--space-sm) var(--space-xs);
}
.locale-switch__menu {
  max-height: 320px;
  overflow-y: auto;
}
.locale-switch__menu li a.is-active {
  background: var(--color-muted);
  color: var(--color-primary);
  font-weight: 600;
}
.account-link:hover { opacity: 1; color: var(--color-primary); text-decoration: none; }
.site-header--transparent:not(.is-scrolled) .account-link:hover { color: #fff; }
.account-link--cta { color: var(--color-primary); font-weight: 600; opacity: 1; }
.site-header--transparent:not(.is-scrolled) .account-link--cta { color: #fff; text-decoration: underline; }
.account-link__name {
  color: inherit;
  opacity: 1;
  font-weight: 600;
  display: none;
}
@media (min-width: 640px) {
  .account-link__name { display: inline-flex; align-items: center; }
}

.site-logo__admin-tag {
  font-family: var(--font-body);
  font-size: 0.65rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--color-primary);
  border: 1px solid var(--color-primary);
  border-radius: 999px;
  padding: 2px 8px;
  vertical-align: middle;
}

/* Admin dashboard chrome stays calm and readable — light, always in the
   "scrolled" state (never transparent), pink/lavender used only for the
   active tab and stat highlights rather than the homepage's decorative
   gradient energy. */
.admin-tabs {
  display: flex;
  align-items: center;
  gap: var(--space-sm);
  flex-wrap: wrap;
}
.admin-tabs__link {
  color: var(--color-muted-foreground);
  font-weight: 500;
  padding: var(--space-sm) var(--space-md);
  border-radius: var(--radius-sm);
  min-height: 44px;
  display: inline-flex;
  align-items: center;
  transition: background-color var(--transition-fast) ease, color var(--transition-fast) ease;
}
.admin-tabs__link:hover { color: var(--color-foreground); text-decoration: none; background: var(--color-muted); }
.admin-tabs__link.is-active { color: var(--color-primary); background: rgba(236, 72, 153, 0.1); font-weight: 600; }
.admin-tabs__badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 18px;
  height: 18px;
  padding: 0 5px;
  margin-left: 6px;
  border-radius: 999px;
  background: var(--color-primary);
  color: var(--color-on-primary);
  font-size: 0.7rem;
  font-weight: 700;
}

/* ---------------------------------------------------------------------- */
/* Auth pages (login / register)                                          */
/* ---------------------------------------------------------------------- */

.auth-card {
  max-width: 440px;
  margin: 0 auto;
  background: var(--color-card);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-md);
  padding: var(--space-2xl);
}
.auth-card__switch {
  text-align: center;
  color: var(--color-muted-foreground);
  margin: var(--space-md) 0 0;
}

/* ---------------------------------------------------------------------- */
/* Client account dashboard                                                */
/* ---------------------------------------------------------------------- */

.account-layout {
  display: grid;
  grid-template-columns: 1fr 2fr;
  gap: var(--space-2xl);
  align-items: start;
}
.account-profile {
  background: var(--color-card);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-sm);
  padding: var(--space-xl);
}
.account-profile__list { margin: 0; }
.account-profile__list > div { padding: var(--space-sm) 0; border-bottom: 1px solid var(--color-border); }
.account-profile__list > div:last-child { border-bottom: none; }
.account-profile__list dt { font-size: 0.8rem; color: var(--color-muted-foreground); text-transform: uppercase; letter-spacing: 0.05em; }
.account-profile__list dd { margin: 2px 0 0; font-weight: 600; color: var(--color-foreground); }

.order-list { display: flex; flex-direction: column; gap: var(--space-md); }
.order-card {
  background: var(--color-card);
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-sm);
  overflow: hidden;
}
.order-card__summary {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: var(--space-md);
  padding: var(--space-md) var(--space-lg);
  list-style: none;
  cursor: pointer;
}
.order-card__summary::-webkit-details-marker { display: none; }
.order-card__number { font-weight: 700; color: var(--color-foreground); }
.order-card__date, .order-card__total { color: var(--color-muted-foreground); font-size: 0.9rem; }
.order-card__total { margin-left: auto; font-weight: 700; color: var(--color-foreground); }
.order-card__items { padding: 0 var(--space-lg) var(--space-lg); border-top: 1px solid var(--color-border); }
.order-card__items .order-summary-item:first-child { padding-top: var(--space-md); }

.status-badge {
  display: inline-flex;
  align-items: center;
  padding: 3px 10px;
  border-radius: 999px;
  font-size: 0.75rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}
.status-badge--pending { background: #FEF3C7; color: #92400E; }
.status-badge--confirmed { background: #DCFCE7; color: #14532D; }
.status-badge--cancelled { background: #FEE2E2; color: #7F1D1D; }

/* ---------------------------------------------------------------------- */
/* Admin dashboard                                                        */
/* ---------------------------------------------------------------------- */

.stat-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
  gap: var(--space-lg);
  margin-bottom: var(--space-2xl);
}
.stat-card {
  background: var(--color-card);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-sm);
  padding: var(--space-lg);
  display: flex;
  flex-direction: column;
  gap: var(--space-xs);
  border-top: 3px solid var(--color-primary);
}
.stat-card__label { font-size: 0.8rem; color: var(--color-muted-foreground); text-transform: uppercase; letter-spacing: 0.05em; }
.stat-card__value { font-family: var(--font-display); font-size: 2rem; font-weight: 700; color: var(--color-foreground); }

.stat-card--link { text-decoration: none; transition: transform 150ms ease, box-shadow 150ms ease; }
@media (hover: hover) and (pointer: fine) {
  .stat-card--link:hover { transform: translateY(-2px); box-shadow: var(--shadow-md); text-decoration: none; }
}

.admin-section { margin-top: var(--space-2xl); }

.admin-table-wrap { overflow-x: auto; background: var(--color-card); border-radius: var(--radius-lg); box-shadow: var(--shadow-sm); }
.admin-table { width: 100%; border-collapse: collapse; font-size: 0.9rem; }
.admin-table th, .admin-table td {
  text-align: left;
  padding: var(--space-md) var(--space-lg);
  border-bottom: 1px solid var(--color-border);
  vertical-align: middle;
}
.admin-table th { color: var(--color-muted-foreground); font-weight: 600; font-size: 0.8rem; text-transform: uppercase; letter-spacing: 0.04em; }
.admin-table tbody tr:last-child td { border-bottom: none; }
.admin-table__muted { color: var(--color-muted-foreground); font-size: 0.85rem; }

.admin-inline-form {
  display: flex;
  align-items: center;
  gap: var(--space-sm);
  flex-wrap: wrap;
}
.admin-inline-form__select { width: auto; min-height: 40px; padding: 8px 12px; }
.admin-inline-form__stock { width: auto; min-height: 40px; max-width: 90px; padding: 8px 12px; }
.admin-inline-form__checkbox { display: inline-flex; align-items: center; gap: 6px; font-size: 0.85rem; color: var(--color-muted-foreground); }

.admin-hero-move { display: flex; gap: 4px; }
.admin-hero-move .btn-sm { min-width: 32px; padding: 4px 8px; line-height: 1; }
.admin-hero-move .btn-sm:disabled { opacity: 0.35; cursor: not-allowed; }

.admin-edit-form { max-width: 760px; }
.admin-edit-form__grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: var(--space-lg);
}
@media (max-width: 640px) {
  .admin-edit-form__grid { grid-template-columns: 1fr; }
}
.admin-edit-form__fieldset {
  border: 1px solid var(--color-border);
  border-radius: var(--radius-lg);
  padding: var(--space-lg);
  margin: var(--space-xl) 0;
}
.admin-edit-form__fieldset legend {
  font-weight: 600;
  color: var(--color-foreground);
  padding: 0 var(--space-xs);
}
.admin-edit-form__image-row {
  display: flex;
  align-items: flex-start;
  gap: var(--space-lg);
  flex-wrap: wrap;
}
.admin-edit-form__image-preview {
  width: 120px;
  height: 120px;
  object-fit: contain;
  background: var(--color-muted);
  border-radius: var(--radius-md);
  flex-shrink: 0;
}
.admin-edit-form__image-preview--empty {
  width: 160px;
  height: 90px;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: var(--space-sm);
  font-size: 0.8rem;
  color: var(--color-muted-foreground);
  background: linear-gradient(135deg, var(--color-primary) 0%, var(--color-accent) 100%);
  border-radius: var(--radius-md);
  flex-shrink: 0;
}
.admin-edit-form__image-preview--empty { color: rgba(255,255,255,0.9); }

.admin-hero-thumb {
  width: 90px;
  height: 50px;
  object-fit: cover;
  border-radius: var(--radius-sm);
  background: var(--color-muted);
}
.admin-hero-thumb--empty {
  width: 90px;
  height: 50px;
  border-radius: var(--radius-sm);
  background: linear-gradient(135deg, var(--color-primary) 0%, var(--color-accent) 100%);
}

.admin-filter-tabs {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-sm);
  margin-bottom: var(--space-xl);
}
.admin-filter-tabs a {
  display: inline-flex;
  align-items: center;
  min-height: 40px;
  padding: 0 var(--space-md);
  border-radius: var(--radius-md);
  color: var(--color-muted-foreground);
  font-weight: 600;
  font-size: 0.9rem;
  background: var(--color-card);
  box-shadow: var(--shadow-sm);
}
.admin-filter-tabs a.is-active { color: var(--color-on-primary); background: var(--color-primary); }
@media (hover: hover) and (pointer: fine) {
  .admin-filter-tabs a:not(.is-active):hover { color: var(--color-primary); }
}

.review-admin-list { display: flex; flex-direction: column; gap: var(--space-lg); }
.review-admin-card {
  background: var(--color-card);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-sm);
  padding: var(--space-lg);
}
.review-admin-card__head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: var(--space-sm);
  margin-bottom: var(--space-sm);
}
.review-admin-card__meta { display: flex; align-items: center; gap: var(--space-sm); margin-bottom: var(--space-sm); }
.review-admin-card__edit { margin-top: var(--space-md); }
.review-admin-card__date { color: var(--color-muted-foreground); font-size: 0.85rem; }
.review-admin-card__body { color: var(--color-muted-foreground); margin-bottom: var(--space-md); }

/* ---------------------------------------------------------------------- */
/* Footer                                                                  */
/* ---------------------------------------------------------------------- */

/* A rich, grounded "dark" band — deep berry/plum, not literal black — with
   light pink/white text, consistent with a light-and-vibrant site that
   still wants one anchoring dark(ish) section. */
.site-footer {
  background: var(--color-foreground);
  color: rgba(255,255,255,0.85);
  padding: var(--space-2xl) 0 var(--space-lg);
  margin-top: var(--space-3xl);
}
.site-footer__grid {
  display: grid;
  grid-template-columns: 2fr repeat(4, 1fr);
  gap: var(--space-xl);
}
@media (max-width: 900px) {
  .site-footer__grid { grid-template-columns: repeat(2, 1fr); }
}
.site-footer__newsletter {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-lg);
  padding-bottom: var(--space-xl);
  margin-bottom: var(--space-xl);
  border-bottom: 1px solid rgba(255,255,255,0.15);
}
.site-footer__newsletter-form {
  display: flex;
  gap: var(--space-sm);
  flex-wrap: wrap;
}
.site-footer__newsletter-form .input {
  min-width: 240px;
  background: rgba(255,255,255,0.08);
  border-color: rgba(255,255,255,0.25);
  color: #fff;
}
.site-footer__newsletter-form .input::placeholder { color: rgba(255,255,255,0.5); }
.site-footer__newsletter-message {
  flex-basis: 100%;
  font-size: 0.85rem;
  margin: 0;
}
.site-footer__newsletter-message--success { color: #8fe3a8; }
.site-footer__newsletter-message--error { color: #f3a4a4; }
.site-footer__bottom {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-md);
  margin-top: var(--space-xl);
  padding-top: var(--space-lg);
  border-top: 1px solid rgba(255,255,255,0.15);
}
.site-footer__payments {
  display: flex;
  align-items: center;
  background: #fff;
  border-radius: var(--radius-sm);
  padding: var(--space-xs) var(--space-sm);
}
.site-footer__payments img {
  display: block;
  height: 48px;
  width: auto;
}
.site-footer__brand {
  font-family: var(--font-display);
  font-size: 1.4rem;
  font-weight: 700;
  color: #fff;
  margin-bottom: var(--space-sm);
}
.site-footer__tagline { color: rgba(255,255,255,0.65); max-width: 40ch; }
.site-footer__heading {
  font-family: var(--font-body);
  font-size: 0.85rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: #fff;
  margin-bottom: var(--space-md);
}
.site-footer__list li { margin-bottom: var(--space-sm); }
.site-footer__list a { color: rgba(255,255,255,0.75); min-height: 44px; display: inline-flex; align-items: center; }
.site-footer__list a:hover { color: var(--color-secondary); }
.site-footer__copyright {
  margin: 0;
  color: rgba(255,255,255,0.6);
  font-size: 0.8rem;
}

/* Simple prose pages: livraison, CGV, confidentialité, rétractation, plan
   du site. */
.static-page { max-width: 720px; }
.static-page h2 { margin-top: var(--space-xl); margin-bottom: var(--space-sm); font-size: 1.15rem; }
.static-page h2:first-child { margin-top: 0; }
.static-page p { color: var(--color-muted-foreground); }
.static-page .site-footer__list { list-style: none; padding: 0; margin: 0 0 var(--space-lg); }
.static-page .site-footer__list li { margin-bottom: var(--space-sm); }
.static-page .site-footer__list a { color: var(--color-primary); }
.static-page ul:not(.site-footer__list) { color: var(--color-muted-foreground); margin: 0 0 var(--space-md); padding-left: 1.2em; }
.static-page ul:not(.site-footer__list) li { margin-bottom: var(--space-xs); }

/* ---------------------------------------------------------------------- */
/* Motion: entrances & stagger                                            */
/* ---------------------------------------------------------------------- */

/* Hero, first load only — gentle fade + slight rise, no loop. Staggered
   ~80ms per element so the eyebrow/heading/lede/actions settle in turn
   instead of all snapping in at once. Transform + opacity only. */
@keyframes hero-enter {
  from { opacity: 0; transform: translateY(14px); }
  to { opacity: 1; transform: translateY(0); }
}
.hero__eyebrow, .hero h1, .hero__lede, .hero__actions, .hero__visual {
  animation: hero-enter 500ms var(--ease-out) both;
}
.hero__eyebrow { animation-delay: 0ms; }
.hero h1 { animation-delay: 60ms; }
.hero__lede { animation-delay: 120ms; }
.hero__actions { animation-delay: 180ms; }
.hero__visual { animation-delay: 240ms; }

/* "Added to cart" / status-change confirmations — occasional, symmetric
   entrance, well under the 200-300ms toast budget. Each page load renders
   a fresh .alert, so a keyframe here behaves the same as a transition
   would (no risk of re-trigger since there's nothing to interrupt). */
@keyframes alert-enter {
  from { opacity: 0; transform: translateY(-6px); }
  to { opacity: 1; transform: translateY(0); }
}
.alert { animation: alert-enter 220ms var(--ease-out) both; }

/* Admin/client dashboard stat cards on load — occasional page load, not a
   per-row re-render, so a small stagger here is fine per the frequency
   gate. 200ms per card, ease-out, 50ms stagger via nth-child. */
@keyframes card-enter {
  from { opacity: 0; transform: scale(0.95); }
  to { opacity: 1; transform: scale(1); }
}
.stat-card, .order-card {
  animation: card-enter 200ms var(--ease-out) both;
}
.stat-grid .stat-card:nth-child(1) { animation-delay: 0ms; }
.stat-grid .stat-card:nth-child(2) { animation-delay: 50ms; }
.stat-grid .stat-card:nth-child(3) { animation-delay: 100ms; }
.stat-grid .stat-card:nth-child(4) { animation-delay: 150ms; }
.stat-grid .stat-card:nth-child(5) { animation-delay: 200ms; }
.stat-grid .stat-card:nth-child(n+6) { animation-delay: 250ms; }
.order-list .order-card:nth-child(1) { animation-delay: 0ms; }
.order-list .order-card:nth-child(2) { animation-delay: 50ms; }
.order-list .order-card:nth-child(3) { animation-delay: 100ms; }
.order-list .order-card:nth-child(n+4) { animation-delay: 150ms; }

/* ---------------------------------------------------------------------- */
/* Responsive breakpoints: 375 / 768 / 1024 / 1440                         */
/* ---------------------------------------------------------------------- */

@media (max-width: 1023px) {
  .product-detail__media { position: static; }
  .cart-summary { position: static; }
}

@media (max-width: 1024px) {
  .hero__inner { grid-template-columns: 1fr; }
  .hero__visual { order: -1; max-width: 320px; margin: 0 auto; }
}

@media (max-width: 767px) {
  /* The 120px header/88px logo are sized for the desktop bar's extra nav
     links; unchanged on mobile they eat a large share of a small screen
     and the logo can look oversized next to the hamburger/account icons.
     Shrink both together so the logo still fills the bar's height. */
  :root { --header-h: 72px; }
  .site-header__bar { padding: var(--space-sm) var(--space-md); gap: var(--space-sm); }
  .site-logo__image { height: 40px; }

  .nav-toggle { display: inline-flex; }

  .primary-nav {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: var(--color-card);
    color: var(--color-foreground);
    box-shadow: var(--shadow-lg);
    padding: var(--space-md) var(--space-lg) var(--space-lg);
  }
  .primary-nav.is-open { display: block; }
  .primary-nav__list { flex-direction: column; align-items: stretch; gap: 0; }
  .nav-dropdown__summary { color: var(--color-foreground); }
  .nav-dropdown__menu { position: static; box-shadow: none; background: transparent; padding-left: var(--space-md); }
  .nav-dropdown__menu li a { color: var(--color-muted-foreground); }
  .nav-dropdown__menu li a:hover, .nav-dropdown__menu li a.is-active { background: var(--color-muted); color: var(--color-primary); }
  /* Mobile nav panel is space-constrained — keep it to the plain
     subcategory list (the mega-menu's promo tiles are a desktop-hover
     enhancement, not part of the touch/no-JS fallback). */
  .mega-menu__promo { display: none; }
  .mega-menu__inner { padding: 0; }

  .category-tiles { grid-template-columns: 1fr; }
  .product-detail { grid-template-columns: 1fr; }
  .cart-layout { grid-template-columns: 1fr; }
  .checkout-layout { grid-template-columns: 1fr; }
  .form-row { grid-template-columns: 1fr; }
  .cart-item { grid-template-columns: 56px 1fr; }
  .cart-item__price { grid-column: 1 / -1; text-align: left; }
  .site-footer__grid { grid-template-columns: 1fr; }
  .account-layout { grid-template-columns: 1fr; }
  .order-card__summary { gap: var(--space-sm); }
  .order-card__total { margin-left: 0; }
}

@media (max-width: 480px) {
  .hero { padding: var(--space-2xl) 0; }
  .hero-carousel .hero { padding-top: calc(var(--space-2xl) + var(--header-h)); }
  .section { padding: var(--space-2xl) 0; }
  .product-grid { grid-template-columns: repeat(auto-fill, minmax(155px, 1fr)); gap: var(--space-md); }
}

/* ---------------------------------------------------------------------- */
/* Blog                                                                     */
/* ---------------------------------------------------------------------- */

.blog-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: var(--space-lg);
}
.blog-card {
  background: var(--color-card);
  border-radius: var(--radius-lg);
  border-top: 4px solid var(--color-primary);
  box-shadow: var(--shadow-md);
  padding: var(--space-xl);
  display: flex;
  flex-direction: column;
  gap: var(--space-sm);
  transition: box-shadow 150ms ease, transform 150ms ease;
  text-decoration: none;
  color: inherit;
}
@media (hover: hover) and (pointer: fine) {
  .blog-card:hover { box-shadow: var(--shadow-xl); transform: translateY(-2px); }
}
.blog-card--tint-1 { border-top-color: var(--color-accent); }
.blog-card--tint-2 { border-top-color: var(--color-secondary); }
.blog-card--tint-3 { border-top-color: var(--color-star); }
.blog-card__eyebrow {
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--color-primary);
}
.blog-card__title {
  margin: 0;
  font-size: 1.05rem;
  color: var(--color-foreground);
}
.blog-card__excerpt {
  margin: 0;
  color: var(--color-muted-foreground);
  flex: 1;
}
.blog-card__meta {
  font-size: 0.82rem;
  color: var(--color-muted-foreground);
}

.blog-post { max-width: 720px; margin: 0 auto var(--space-2xl); }
.blog-post__eyebrow {
  display: inline-block;
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--color-primary);
  margin-bottom: var(--space-sm);
}
.blog-post__meta {
  color: var(--color-muted-foreground);
  font-size: 0.9rem;
  margin-bottom: var(--space-lg);
}
.blog-post__body { color: var(--color-foreground); }
.blog-post__body p { color: var(--color-muted-foreground); margin-bottom: var(--space-md); }
.blog-post__body h2 { margin-top: var(--space-xl); margin-bottom: var(--space-sm); font-size: 1.15rem; }
.blog-post__body ul { list-style: disc; margin: 0 0 var(--space-md); padding-left: 1.2em; color: var(--color-muted-foreground); }
.blog-post__body li { margin-bottom: var(--space-xs); }

/* ---------------------------------------------------------------------- */
/* Reduced motion                                                          */
/* ---------------------------------------------------------------------- */

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.001ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.001ms !important;
    scroll-behavior: auto !important;
  }
}

/* Mobile: the generic max-width:767px rule above flattens every
   .nav-dropdown__menu (static + transparent) for the hamburger panel,
   but the language switcher lives in the header bar, not in that panel —
   restore its floating card so the options stay readable. */
@media (max-width: 767px) {
  .locale-switch > .nav-dropdown__menu {
    position: absolute;
    top: calc(100% + 8px);
    left: 0;
    min-width: 180px;
    background: var(--color-card);
    color: var(--color-card-foreground);
    border-radius: var(--radius-md);
    box-shadow: var(--shadow-lg);
    padding: var(--space-sm);
    z-index: 60;
  }
  .locale-switch > .nav-dropdown__menu li a { color: var(--color-card-foreground); }
  .locale-switch > .nav-dropdown__menu li a:hover,
  .locale-switch > .nav-dropdown__menu li a.is-active { background: var(--color-muted); color: var(--color-primary); }
}

/* Mobile: the product page stacks to one column here, so the desktop
   sticky gallery would stay pinned over the details while scrolling. */
@media (max-width: 767px) {
  .product-detail__gallery { position: static; }
}

/* Searchable country / phone-code picker (see main.js — replaces the
   native <select> visually; the select itself stays in the form). */
.combo { position: relative; }
.combo__toggle {
  width: 100%;
  min-height: 44px;
  display: flex;
  align-items: center;
  gap: 8px;
  text-align: left;
  cursor: pointer;
  padding-right: 32px;
  white-space: nowrap;
  overflow: hidden;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12'%3E%3Cpath d='M2 4L6 8L10 4' stroke='%236B7280' stroke-width='1.5' fill='none' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 12px center;
}
.combo.is-open .combo__toggle {
  border-color: var(--color-primary);
  box-shadow: 0 0 0 3px rgba(236, 72, 153, 0.15);
}
.combo__panel {
  position: absolute;
  top: calc(100% + 6px);
  left: 0;
  width: 100%;
  min-width: 280px;
  max-width: calc(100vw - 32px);
  background: var(--color-card);
  color: var(--color-card-foreground);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-lg);
  padding: var(--space-sm);
  z-index: 70;
}
.combo__search { width: 100%; margin-bottom: var(--space-xs); }
.combo__list {
  list-style: none;
  margin: 0;
  padding: 0;
  max-height: 260px;
  overflow-y: auto;
  overscroll-behavior: contain;
}
.combo__option {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px var(--space-md);
  border-radius: var(--radius-sm);
  cursor: pointer;
  font-size: 0.92rem;
}
.combo__option[hidden] { display: none; }
/* Each .checkout-fieldset animates in (transform), which makes it its own
   stacking context — lift the one holding an open picker above the
   fieldsets after it so the list isn't drawn underneath them. */
.checkout-fieldset:has(.combo.is-open) { position: relative; z-index: 20; }
.combo__option:hover,
.combo__option.is-active { background: var(--color-muted); }
.combo__option[aria-selected="true"] { color: var(--color-primary); font-weight: 600; }
.combo__flag {
  width: 20px;
  height: 15px;
  flex: 0 0 auto;
  border-radius: 2px;
  object-fit: cover;
  box-shadow: 0 0 0 1px rgba(0, 0, 0, 0.1);
}
.combo__text { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.combo__empty { padding: 10px var(--space-md); color: var(--color-muted-foreground); font-size: 0.9rem; margin: 0; }

/* Checkout: optional "create an account" offer for guests (main.js
   reveals it once an email is typed) — the password field only shows
   once the box is ticked. */
.checkout-account {
  margin-bottom: var(--space-lg);
  padding: var(--space-md);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-md);
  background: var(--color-muted);
}
.checkout-account[hidden] { display: none; }
.checkout-account.is-entering { animation: checkout-account-enter 240ms cubic-bezier(0.23, 1, 0.32, 1); }
@keyframes checkout-account-enter {
  from { opacity: 0; transform: translateY(-6px); }
  to { opacity: 1; transform: translateY(0); }
}
.checkout-account__toggle {
  display: flex;
  align-items: flex-start;
  gap: var(--space-sm);
  min-height: 44px;
  cursor: pointer;
}
.checkout-account__toggle input { width: 18px; height: 18px; margin-top: 2px; accent-color: var(--color-primary); flex: 0 0 auto; }
.checkout-account__title { display: block; font-weight: 600; }
.checkout-account__hint { display: block; font-size: 0.85rem; color: var(--color-muted-foreground); margin-top: 2px; }
.checkout-account__password { display: none; margin-top: var(--space-md); margin-bottom: 0; }
.checkout-account:has(input[name="create_account"]:checked) .checkout-account__password { display: block; }
.checkout-account .input { background: var(--color-card); }
@media (prefers-reduced-motion: reduce) {
  .checkout-account.is-entering { animation: none; }
}
input.input[readonly] { background: var(--color-muted); color: var(--color-muted-foreground); cursor: default; }

/* ---------------------------------------------------------------------- */
/* Right-to-left (Arabic — see RTL_LOCALES in includes/i18n.php)          */
/* ---------------------------------------------------------------------- */
/* Flex/grid layouts mirror on their own under dir="rtl"; these rules flip
   the handful of physical left/right values used above, and swap in fonts
   that carry Arabic glyphs (Inter / Playfair Display have none). */
[dir="rtl"] {
  --font-body: 'Tajawal', 'Segoe UI', Tahoma, sans-serif;
  --font-display: 'Amiri', 'Times New Roman', serif;
}
[dir="rtl"] body { letter-spacing: 0; }

[dir="rtl"] .skip-link { left: auto; right: var(--space-md); }
[dir="rtl"] .site-logo { margin-right: 0; margin-left: auto; }
[dir="rtl"] .locale-switch { margin-right: 0; margin-left: var(--space-sm); }
[dir="rtl"] .nav-dropdown__menu { left: auto; right: 0; }
[dir="rtl"] .cart-link__badge { right: auto; left: 0; }
[dir="rtl"] .category-tile__accent { right: auto; left: -30px; }
[dir="rtl"] .product-card__favorite-form { right: auto; left: var(--space-sm); }
[dir="rtl"] .product-card__price small { margin-right: 0; margin-left: 4px; }
[dir="rtl"] .product-detail__favorite-form { right: auto; left: var(--space-md); }
[dir="rtl"] .variant-option input[type="radio"] { left: auto; right: 0; }
[dir="rtl"] .review-item__date { margin-left: 0; margin-right: auto; }
[dir="rtl"] .cart-item__price { text-align: left; }
[dir="rtl"] .shipping-card__check { right: auto; left: 10px; }
[dir="rtl"] .order-card__total { margin-left: 0; margin-right: auto; }
[dir="rtl"] .static-page ul:not(.site-footer__list),
[dir="rtl"] .blog-post__body ul { padding-left: 0; padding-right: 1.2em; }
[dir="rtl"] .combo__toggle { text-align: right; padding-right: var(--space-md); padding-left: 32px; background-position: left 12px center; }
[dir="rtl"] .combo__panel { left: auto; right: 0; }
/* Phone numbers and dial codes read left-to-right even inside Arabic. */
[dir="rtl"] input[type="tel"],
[dir="rtl"] input[type="email"],
[dir="rtl"] .phone-input__code + .combo__toggle,
[dir="rtl"] .combo--compact .combo__toggle { direction: ltr; }
[dir="rtl"] .combo--compact .combo__toggle { text-align: left; }
[dir="rtl"] input[type="tel"], [dir="rtl"] input[type="email"] { text-align: right; }

/* Carousels and product rows: their JS drives position with translateX /
   scrollLeft, which assumes a left-to-right track. Keep the track itself
   LTR (cards still read right-to-left inside) so arrows, swipe and
   auto-scroll behave exactly as in the other languages. */
[dir="rtl"] .hero-carousel__viewport,
[dir="rtl"] .product-scroller__track { direction: ltr; }
[dir="rtl"] .hero-carousel__slide,
[dir="rtl"] .product-scroller__item { direction: rtl; }

@media (max-width: 767px) {
  [dir="rtl"] .locale-switch > .nav-dropdown__menu { left: auto; right: 0; }
  [dir="rtl"] .nav-dropdown__menu { padding-left: 0; padding-right: var(--space-md); }
  [dir="rtl"] .cart-item__price { text-align: right; }
  [dir="rtl"] .order-card__total { margin-right: 0; }
}
/* "Discover →" style arrows point the reading direction. */
[dir="rtl"] .gender-card__cta svg,
[dir="rtl"] .mega-menu__tile-cta svg { transform: scaleX(-1); }

/* .section's `padding: … 0` (declared after .container) wipes the
   container's side gutter on every `container section` page, so on
   screens narrower than the max-width, content ran edge to edge. Restore
   it there; wider screens keep the centered max-width unchanged. */
@media (max-width: 1327px) {
  .container.section { padding-inline: var(--space-lg); }
}
@media (max-width: 767px) {
  .container.section { padding-inline: var(--space-md); }
}

/* Footer link groups (<details> — see main.js): plain columns on desktop,
   tap-to-open sections on phones so the footer doesn't run on and on. */
.site-footer__summary { list-style: none; cursor: default; }
.site-footer__summary::-webkit-details-marker { display: none; }
.site-footer__chevron { display: none; }
@media (max-width: 767px) {
  .site-footer__grid { gap: 0; }
  .site-footer__grid > .site-footer__col:first-child { margin-bottom: var(--space-lg); }
  .site-footer__group { border-top: 1px solid rgba(255, 255, 255, 0.12); }
  /* Email + button on one row, and tighter spacing around it. */
  .site-footer__newsletter { gap: var(--space-md); padding-bottom: var(--space-lg); margin-bottom: var(--space-lg); }
  .site-footer__newsletter-form { flex-wrap: nowrap; width: 100%; }
  .site-footer__newsletter-form .input { min-width: 0; flex: 1 1 auto; }
  .site-footer__newsletter-form .btn-primary { flex: 0 0 auto; }
  .site-footer__summary {
    display: flex;
    align-items: center;
    justify-content: space-between;
    min-height: 52px;
    cursor: pointer;
  }
  .site-footer__summary .site-footer__heading { margin: 0; }
  .site-footer__chevron { display: block; color: rgba(255, 255, 255, 0.7); transition: transform 200ms var(--ease-in-out); }
  .site-footer__group[open] .site-footer__chevron { transform: rotate(180deg); }
  .site-footer__group .site-footer__list { padding-bottom: var(--space-sm); }
  .site-footer__group .site-footer__list li { margin-bottom: 0; }
}

/* Add-to-cart confirmation toast (main.js) — the page no longer reloads,
   so this is the visible confirmation. Bottom-center on phones (thumb
   reach, clear of the header), bottom-right on wider screens. */
.cart-toast {
  position: fixed;
  left: 50%;
  bottom: calc(16px + env(safe-area-inset-bottom, 0px));
  z-index: 200;
  display: flex;
  align-items: center;
  gap: var(--space-md);
  width: max-content;
  max-width: calc(100vw - 32px);
  padding: 12px 16px;
  border-radius: var(--radius-md);
  background: #1f1a1d;
  color: #fff;
  font-size: 0.9rem;
  box-shadow: var(--shadow-lg);
  opacity: 0;
  visibility: hidden;
  transform: translate(-50%, 12px);
  transition: opacity 200ms ease, transform 200ms var(--ease-out), visibility 0ms linear 200ms;
}
.cart-toast.is-visible {
  opacity: 1;
  visibility: visible;
  transform: translate(-50%, 0);
  transition: opacity 200ms ease, transform 200ms var(--ease-out), visibility 0ms linear 0ms;
}
.cart-toast--error { background: var(--color-destructive); }
.cart-toast__link {
  color: #fff;
  font-weight: 600;
  text-decoration: underline;
  white-space: nowrap;
  min-height: 32px;
  display: inline-flex;
  align-items: center;
}
.cart-link__badge.is-bumped { animation: cart-badge-bump 300ms var(--ease-out); }
@keyframes cart-badge-bump {
  0% { transform: scale(1); }
  40% { transform: scale(1.35); }
  100% { transform: scale(1); }
}
[type="submit"].is-loading { opacity: 0.6; cursor: progress; }
@media (prefers-reduced-motion: reduce) {
  .cart-toast, .cart-toast.is-visible { transition: none; }
  .cart-link__badge.is-bumped { animation: none; }
}

/* Account page: "please confirm your email" reminder with resend button. */
.verify-banner {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-md);
  margin-bottom: var(--space-lg);
  padding: var(--space-md) var(--space-lg);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-md);
  background: #FFF7ED;
}
.verify-banner__text { margin: 0; color: var(--color-foreground); flex: 1 1 280px; }
.verify-banner__form { margin: 0; }

/* Admin messages: "mark as read" + "delete" side by side. */
.admin-message-actions { display: flex; flex-wrap: wrap; gap: var(--space-sm); align-items: center; }
