/* ── Design Tokens ─────────────────────────────── */

:root {
  /*
   * Contrast ratios verified 2026-04-19 against WCAG 4.5:1 (AA):
   * --color-text (#F5F5F5) on --color-bg (#121212):              17.18:1 ✓
   * --color-text-muted (#A0A0B0) on --color-bg (#121212):         7.27:1 ✓
   * --color-silver (#C0C0C8) on --color-bg (#121212):            10.36:1 ✓
   * --color-silver-light (#E8E8F0) on --color-bg (#121212):      15.37:1 ✓
   * --color-silver-light (#E8E8F0) on --color-surface (#1C1C1E): 13.96:1 ✓
   * btn--whatsapp: var(--color-bg)/#121212 on #25D366:            9.45:1 ✓
   *   (NOTE: #ffffff on #25D366 = 1.98:1 — fails. Dark text used instead.)
   */

  /* Background & Surface — NOT #000 (AMOLED flicker) */
  --color-bg:           #121212;
  --color-surface:      #1C1C1E;
  --color-border:       #2A2A35;

  /* Text — verified ≥4.5:1 on --color-bg */
  --color-text:         #F5F5F5;   /* ~17:1 on #121212 */
  --color-text-muted:   #A0A0B0;   /* ~6.5:1 on #121212 */

  /* Brand Silver */
  --color-silver:       #C0C0C8;   /* ~7:1 on #121212 */
  --color-silver-light: #E8E8F0;   /* ~13:1 on #121212 */

  /* Warm Accent */
  --color-gold-whisper: #D4AF7A;
  --color-accent:       #D4AF7A;   /* alias — used by admin buttons/links; 8.7:1 on --color-bg ✓ */

  /* Typography */
  --font-display:       'Cormorant Garamond', Georgia, serif;
  --font-body:          'Inter', system-ui, sans-serif;
  --font-size-base:     1rem;
  --line-height-body:   1.7;

  /* Spacing scale */
  --space-xs:           0.5rem;
  --space-sm:           1rem;
  --space-md:           2rem;
  --space-lg:           4rem;
  --space-xl:           8rem;

  /* Motion */
  --ease-luxury:        cubic-bezier(0.25, 0.46, 0.45, 0.94);
  --duration-base:      0.6s;
  --transition-base:    0.25s ease;

  /* Layout */
  --radius-card:        4px;
  --container-max:      1200px;
}

/* ── Reset ─────────────────────────────────────── */

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

html {
  scroll-behavior: smooth;
  overflow-x: clip; /* prevent horizontal scroll — sticky nav hamburger stays in viewport */
}

/* ── Base Typography ────────────────────────────── */

body {
  background-color: var(--color-bg);
  color: var(--color-text);
  font-family: var(--font-body);
  font-size: var(--font-size-base);
  line-height: var(--line-height-body);
  -webkit-font-smoothing: antialiased;
}

h1, h2, h3, h4 {
  font-family: var(--font-display);
  font-weight: 300;
  line-height: 1.2;
  color: var(--color-silver-light);
}

a {
  color: inherit;
  text-decoration: none;
}

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

ul {
  list-style: none;
}

/* ── Container ──────────────────────────────────── */

.container {
  width: 100%;
  max-width: var(--container-max);
  margin-inline: auto;
  padding-inline: var(--space-md);
}

@media (max-width: 767px) {
  .container {
    padding-inline: var(--space-sm);
  }
}

/* ── Navigation ─────────────────────────────── */

.nav {
  position: sticky;
  top: 0;
  z-index: 100;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-sm);
  padding: var(--space-sm) var(--space-md);
  background: transparent;
  transition: background var(--transition-base), border-color var(--transition-base);
}

/* Scrolled state — JS adds this class in Phase 5. Test manually via DevTools during Phase 1 QA. */
.nav--scrolled {
  background: var(--color-surface);
  border-bottom: 1px solid var(--color-border);
}

.nav__logo {
  font-family: var(--font-display);
  font-size: 1.5rem;
  font-weight: 300;
  letter-spacing: 0.1em;
  color: var(--color-silver-light);
  white-space: nowrap;
  flex-shrink: 0;
}

.nav__links {
  display: flex;
  align-items: center;
}

.nav__links ul {
  display: flex;
  gap: var(--space-md);
}

.nav__links a {
  font-family: var(--font-body);
  font-size: 0.875rem;
  font-weight: 400;
  letter-spacing: 0.05em;
  color: var(--color-text-muted);
  transition: color var(--transition-base);
  text-transform: uppercase;
}

.nav__links a:hover,
.nav__links a:focus-visible {
  color: var(--color-silver-light);
}

/* Hamburger button — visible mobile only */
.nav__hamburger {
  display: none;
  background: none;
  border: none;
  cursor: pointer;
  padding: var(--space-xs);
  color: var(--color-silver-light);
  font-size: 1.5rem;
  line-height: 1;
  flex-shrink: 0;
}

/* ── WhatsApp Button ─────────────────────────── */

.btn--whatsapp {
  display: inline-flex;
  align-items: center;
  gap: var(--space-xs);
  padding: 0.6rem 1.2rem;
  background: #25D366;    /* WhatsApp brand green — intentionally hardcoded, not a token */
  color: var(--color-bg); /* #121212 — dark text on green achieves 9.45:1 (WCAG AA ✓); #fff only 1.98:1 */
  border-radius: 2rem;
  font-family: var(--font-body);
  font-size: 0.875rem;
  font-weight: 500;
  letter-spacing: 0.02em;
  transition: background var(--transition-base);
  white-space: nowrap;
  flex-shrink: 0;
  text-decoration: none;
}

.btn--whatsapp:hover,
.btn--whatsapp:focus-visible {
  background: #20bd5a;
}

.btn--whatsapp i {
  font-size: 1.1rem;
  line-height: 1;
}

/* On very narrow viewports (below 480px), hide the WhatsApp text label — keep the icon + pill shape */
@media (max-width: 479px) {
  .btn--whatsapp span {
    display: none;
  }
  .btn--whatsapp {
    padding: 0.6rem 0.8rem;
  }
}

/* ── Responsive Breakpoints ──────────────────── */

/* ── Mobile base (375px+) — nav layout ── */

/* On mobile: hide nav links, show hamburger */
@media (max-width: 767px) {
  .nav__links {
    display: none;         /* JS Phase 5 will toggle .nav__links--open to show */
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: var(--color-surface);
    border-bottom: 1px solid var(--color-border);
    padding: var(--space-sm) var(--space-md);
    flex-direction: column;
  }

  .nav__links.nav__links--open {
    display: flex;         /* JS Phase 5 adds this class */
  }

  .nav__links ul {
    flex-direction: column;
    gap: var(--space-sm);
  }

  .nav__hamburger {
    display: block;
  }
}

/* ── Tablet (768px+) ── */
@media (min-width: 768px) {
  .nav__links {
    display: flex;
  }

  .nav__hamburger {
    display: none;
  }

  /* Mobile-only search — hidden on desktop; shown only inside hamburger dropdown */
  .nav__search-mobile-item {
    display: none;
  }
}

/* ── Desktop (1280px+) ── */
@media (min-width: 1280px) {
  .nav {
    padding: var(--space-sm) var(--space-lg);
  }

  .nav__logo {
    font-size: 1.75rem;
  }
}

/* ── Hero ──────────────────────── Phase 2 ── */

.hero {
  position: relative;
  min-height: 100vh;    /* fallback for older browsers */
  min-height: 100svh;   /* preferred — accounts for mobile browser chrome; Baseline June 2025 */
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
}

.hero__bg {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
  z-index: 0;
}

.hero__overlay {
  position: absolute;
  inset: 0;
  background: rgba(18, 18, 18, 0.55); /* 55% — balanced per CONTEXT.md decision; #121212 = --color-bg value */
  z-index: 1;
}

.hero__content {
  position: relative;
  z-index: 2;
  text-align: center;
  padding: var(--space-md);
  max-width: 700px;
}

.hero__brand {
  font-family: var(--font-display);
  font-weight: 300;           /* Light — luxury elegance; Claude's discretion: weight 300 chosen */
  font-size: clamp(3.5rem, 10vw, 7rem); /* fluid — no media query needed; readable at 375px+ */
  letter-spacing: 0.15em;     /* wide tracking = premium signal */
  color: var(--color-silver-light); /* #E8E8F0 — 15.37:1 contrast on #121212 ✓ */
  text-transform: uppercase;
  margin-bottom: var(--space-sm);
  line-height: 1;
}

.hero__tagline {
  font-family: var(--font-display);
  font-weight: 300;
  font-style: italic;
  font-size: clamp(1.1rem, 3vw, 1.5rem);
  letter-spacing: 0.1em;
  color: var(--color-silver);  /* #C0C0C8 — 10.36:1 on #121212 ✓ */
  margin-bottom: var(--space-xs);
}

.hero__subtitle {
  font-family: var(--font-body);
  font-weight: 300;
  font-size: 0.85rem;
  letter-spacing: 0.08em;
  color: var(--color-text-muted); /* #A0A0B0 — 7.27:1 on #121212 ✓ */
  text-transform: uppercase;
  margin-bottom: var(--space-md);
}

/* ── Products ──────────────────── Phase 2 ── */

.products {
  padding: var(--space-xl) 0;
  background: var(--color-bg);
}

.products__grid {
  display: grid;
  grid-template-columns: 1fr;   /* mobile: single column stack */
  gap: var(--space-md);
}

@media (min-width: 768px) {
  .products__grid {
    grid-template-columns: repeat(3, 1fr);  /* desktop: 3 equal columns */
  }
}

.product-card {
  background: var(--color-surface);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-card);
  overflow: hidden;
  display: flex;
  flex-direction: column;
}

.product-card__image-wrap {
  position: relative;
  overflow: hidden;           /* clip the hover scale effect within the card */
  aspect-ratio: 4 / 3;       /* reserves space before image loads — prevents layout shift (CLS) */
}

.product-card__img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
  transition: transform var(--duration-base) var(--ease-luxury);
  display: block;
}

.product-card:hover .product-card__img {
  transform: scale(1.03);    /* subtle zoom — luxury feel; locked decision */
}

.product-card__body {
  padding: var(--space-md);
  display: flex;
  flex-direction: column;
  gap: var(--space-sm);
  flex: 1;                   /* push CTA to bottom of card when cards have varying desc lengths */
}

.product-card__title {
  font-family: var(--font-display);
  font-weight: 300;
  font-size: 1.4rem;
  letter-spacing: 0.05em;
  color: var(--color-silver-light);  /* #E8E8F0 — 13.96:1 on --color-surface ✓ */
}

.product-card__desc {
  font-family: var(--font-body);
  font-size: 0.875rem;
  font-weight: 300;
  color: var(--color-text-muted);    /* #A0A0B0 — verified WCAG AA ✓ */
  line-height: 1.5;
  flex: 1;
}

.product-card__cta {
  align-self: flex-start;    /* button left-aligns within card body, does not stretch full width */
  margin-top: auto;          /* pushes to bottom when desc is short */
}

/* ── Shared section heading — used by Why Junik and Testimonials ── */
.section-heading {
  font-family: var(--font-display);
  font-weight: 300;
  font-size: clamp(2rem, 5vw, 3rem);
  letter-spacing: 0.08em;
  color: var(--color-silver-light);   /* 15.37:1 on --color-bg; 13.96:1 on --color-surface ✓ */
  text-align: center;
  margin-bottom: var(--space-lg);
}

/* ── Why Junik ─────────────────── Phase 3 ── */

.why-junik {
  padding: var(--space-xl) 0;
  background: var(--color-surface);  /* alternates from --color-bg products section */
}

.trust-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--space-md);
  margin-bottom: var(--space-lg);
}

@media (min-width: 768px) {
  .trust-grid {
    grid-template-columns: repeat(3, 1fr);
  }
}

.trust-card {
  background: var(--color-bg);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-card);
  padding: var(--space-md);
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: var(--space-sm);
}

.trust-card__icon {
  font-size: 2.5rem;
  color: var(--color-gold-whisper);  /* warm accent; decorative, aria-hidden — no WCAG text contrast applies */
  line-height: 1;
}

.trust-card__title {
  font-family: var(--font-display);
  font-weight: 400;
  font-size: 1.2rem;
  letter-spacing: 0.05em;
  color: var(--color-silver-light);  /* 15.37:1 on --color-bg ✓ */
}

.trust-card__desc {
  font-family: var(--font-body);
  font-size: 0.875rem;
  font-weight: 300;
  color: var(--color-text-muted);    /* 7.27:1 on --color-bg ✓ */
  line-height: 1.6;
}

/* ── Occasions list ── */

.occasions {
  text-align: center;
  padding-top: var(--space-md);
  border-top: 1px solid var(--color-border);
}

.occasions__heading {
  font-family: var(--font-display);
  font-weight: 300;
  font-style: italic;
  font-size: 1.1rem;
  letter-spacing: 0.06em;
  color: var(--color-silver);        /* 9.3:1 on --color-surface ✓ */
  margin-bottom: var(--space-sm);
}

.occasions__list {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: var(--space-xs);
  list-style: none;
  padding: 0;
  margin: 0;
}

.occasions__list li {
  font-family: var(--font-body);
  font-size: 0.8rem;
  font-weight: 400;
  letter-spacing: 0.04em;
  color: var(--color-text-muted);    /* 6.6:1 on --color-surface ✓ */
  padding: 0.3rem 0.75rem;
  border: 1px solid var(--color-border);
  border-radius: 2rem;
  white-space: nowrap;
}

/* ── Testimonials ──────────────── Phase 3 ── */

.testimonials {
  padding: var(--space-xl) 0;
  background: var(--color-bg);  /* alternates from --color-surface Why Junik section */
}

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

@media (min-width: 768px) {
  .testimonials__grid {
    grid-template-columns: repeat(3, 1fr);
  }
}

.testimonial-card {
  background: var(--color-surface);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-card);
  padding: var(--space-md);
  display: flex;
  flex-direction: column;
  gap: var(--space-sm);
}

.testimonial-card__stars {
  color: var(--color-gold-whisper);  /* warm gold — decorative stars, aria-hidden */
  font-size: 1.1rem;
  letter-spacing: 0.1em;
}

.testimonial-card__quote {
  font-family: var(--font-display);
  font-weight: 300;
  font-style: italic;
  font-size: 1rem;
  line-height: 1.7;
  color: var(--color-text);           /* 16.0:1 on --color-surface ✓ */
  flex: 1;
  margin: 0;
}

.testimonial-card__footer {
  display: flex;
  flex-direction: column;
  gap: 0.2rem;
  border-top: 1px solid var(--color-border);
  padding-top: var(--space-sm);
}

.testimonial-card__name {
  font-family: var(--font-body);
  font-size: 0.875rem;
  font-weight: 500;
  letter-spacing: 0.04em;
  color: var(--color-silver-light);   /* 13.96:1 on --color-surface ✓ */
}

.testimonial-card__occasion {
  font-family: var(--font-body);
  font-size: 0.75rem;
  font-weight: 300;
  letter-spacing: 0.03em;
  color: var(--color-text-muted);     /* ~6.6:1 on --color-surface ✓ */
  text-transform: uppercase;
}

/* ── Footer ────────────────────── Phase 3 ── */

.footer {
  background: var(--color-surface);
  border-top: 1px solid var(--color-border);
  padding: var(--space-md) 0;
}

.footer__inner {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-sm);
}

.footer__link {
  font-family: var(--font-body);
  font-size: 0.8rem;
  font-weight: 400;
  letter-spacing: 0.03em;
  color: var(--color-text-muted);    /* 6.6:1 on --color-surface ✓ */
  text-decoration: underline;
  transition: color var(--transition-base);
}

.footer__link:hover,
.footer__link:focus-visible {
  color: var(--color-silver-light);
}

.footer__contact {
  display: inline-flex;
  align-items: center;
  gap: 0.3rem;
  text-decoration: none;
}

.footer__credit {
  font-family: var(--font-body);
  font-size: 0.8rem;
  font-weight: 300;
  color: var(--color-text-muted);
  margin: 0;
}

@media (max-width: 767px) {
  .footer__inner {
    flex-direction: column;
    align-items: center;
    text-align: center;
  }
}

/* ── Privacy Policy ─────────────── Phase 4 ── */

.privacy-policy {
  padding: var(--space-xl) 0;
  background: var(--color-bg);
}

.policy-content {
  max-width: 720px;        /* optimal prose line length ~65–75 chars */
  margin: 0 auto;
}

.policy-content h1 {
  font-family: var(--font-display);
  font-weight: 300;
  font-size: clamp(2rem, 5vw, 3rem);
  letter-spacing: 0.08em;
  color: var(--color-silver-light);  /* 15.37:1 on --color-bg ✓ */
  margin-bottom: var(--space-sm);
}

.policy-meta {
  font-family: var(--font-body);
  font-size: 0.8rem;
  color: var(--color-text-muted);
  margin-bottom: var(--space-lg);
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.policy-content h2 {
  font-family: var(--font-display);
  font-weight: 400;
  font-size: 1.4rem;
  letter-spacing: 0.05em;
  color: var(--color-silver-light);
  margin-top: var(--space-lg);
  margin-bottom: var(--space-sm);
}

.policy-content p,
.policy-content li {
  font-family: var(--font-body);   /* Inter — NOT Cormorant for body text */
  font-size: 0.9375rem;            /* 15px — readable prose size */
  font-weight: 300;
  color: var(--color-text);        /* #F5F5F5 — 17.18:1 on --color-bg ✓ */
  line-height: 1.8;
  margin-bottom: var(--space-sm);
}

.policy-content ul {
  padding-left: var(--space-md);
  margin-bottom: var(--space-sm);
}

.policy-content a {
  color: var(--color-silver-light);
  text-decoration: underline;
}

.policy-content a:hover,
.policy-content a:focus-visible {
  color: var(--color-text);
}

/* ── Floating WhatsApp ─────────────────────────────── Phase 5 ── */

.floating-wa {
  position: fixed;
  bottom: calc(1.5rem + env(safe-area-inset-bottom, 0px));
  right: 1.5rem;
  z-index: 200;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 56px;
  height: 56px;
  border-radius: 50%;
  background: #25D366;
  color: var(--color-bg);
  font-size: 1.75rem;
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.4);
  transition: transform var(--transition-base), background var(--transition-base);
  text-decoration: none;
}

.floating-wa:hover,
.floating-wa:focus-visible {
  background: #20bd5a;
  transform: scale(1.08);
}

@media (prefers-reduced-motion: reduce) {
  .floating-wa {
    transition: none;
  }
}

/* ── Scroll Animations ──────────────────────────────── Phase 5 ── */

[data-animate] {
  opacity: 0;
  transform: translateY(20px);
  transition: opacity 0.6s var(--ease-luxury), transform 0.6s var(--ease-luxury);
}

[data-animate].is-visible {
  opacity: 1;
  transform: translateY(0);
}

@media (prefers-reduced-motion: reduce) {
  [data-animate] {
    opacity: 1;
    transform: none;
    transition: none;
  }
}

/* ── Products Page ─────────────────────────── Phase 8 ── */

/* Screen-reader-only utility — needed for search label */
.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;
}

/* Products page section padding */
.products-page {
  padding: var(--space-xl) 0;
}

/* Filter pills row — PROD-02 */
.filter-pills {
  display: flex;
  gap: 0.5rem;
  flex-wrap: wrap;
  margin-bottom: var(--space-md);
}

.filter-pill {
  padding: 0.4rem 1rem;
  border: 1px solid var(--color-border);
  border-radius: 2rem;
  background: transparent;
  color: var(--color-text-muted);
  font-family: var(--font-body);
  font-size: 0.85rem;
  cursor: pointer;
  transition: border-color var(--transition-base), color var(--transition-base);
  white-space: nowrap;
}

.filter-pill.active,
.filter-pill:hover,
.filter-pill:focus-visible {
  border-color: var(--color-accent);
  color: var(--color-accent);
}

/* Navbar search — PROD-11 — desktop-only inline, hidden on mobile */
.nav__search-wrap {
  display: none; /* hidden on mobile — search is inside hamburger dropdown */
  align-items: center;
  gap: 0.4rem;
}

@media (min-width: 768px) {
  .nav__search-wrap {
    display: flex;
  }
}

.nav__search {
  background: transparent;
  border: none;
  border-bottom: 1px solid var(--color-border);
  color: var(--color-text);
  font-family: var(--font-body);
  font-size: 0.85rem;
  padding: 0.25rem 0.5rem;
  width: 160px;
  transition: border-color var(--transition-base), width var(--transition-base);
}

.nav__search:focus {
  outline: none;
  border-color: var(--color-accent);
  width: 200px;
}

.nav__search::placeholder {
  color: var(--color-text-muted);
}

/* Product grid with PROD-01 breakpoints — separate class from homepage .products__grid */
.products-page__grid {
  display: grid;
  grid-template-columns: 1fr;       /* 375px: 1 column */
  gap: var(--space-md);
}

@media (min-width: 600px) {
  .products-page__grid {
    grid-template-columns: repeat(2, 1fr);  /* 600px: 2 columns (PROD-01) */
  }
}

@media (min-width: 1024px) {
  .products-page__grid {
    grid-template-columns: repeat(3, 1fr);  /* 1024px: 3 columns (PROD-01) */
  }
}

/* Product cards on products page — cursor indicates Phase 9 click interactivity */
.products-page__grid .product-card {
  cursor: pointer;
}

/* Price line on product card — PROD-10 */
.product-card__price {
  font-family: var(--font-body);
  font-size: 1rem;
  font-weight: 500;
  color: var(--color-accent);
  margin-top: auto;
}

/* Empty state — shown when no products match or during loading */
.products-empty {
  color: var(--color-text-muted);
  font-size: 0.9rem;
  text-align: center;
  padding: var(--space-lg) 0;
  grid-column: 1 / -1;
}

/* Gray bg placeholder when product has no thumbnail image */
.product-card__image-wrap--no-thumb {
  background-color: var(--color-surface);
}

/* Mobile search inside nav dropdown */
.nav__search-mobile-item {
  padding: var(--space-sm) 0;
}

.nav__search-mobile-item .nav__search {
  width: 100%;
  border-bottom: 1px solid var(--color-border);
}

/* ── Image Carousel Dialog ──────────────────── Phase 9 ── */

/* Dialog container — top-layer rendering; showModal() places above sticky nav (z-index:100) automatically */
.carousel-dialog {
  background: var(--color-surface);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-card);
  padding: 0;
  width: min(92vw, 820px);
  max-height: 90dvh;        /* dvh: accounts for mobile browser chrome */
  overflow: hidden;
  color: var(--color-text);
  margin: auto;             /* centers dialog in viewport (native <dialog> needs this) */
}

/* Native dialog backdrop — rgba hardcoded because var() inside rgba() requires color-mix (not added) */
.carousel-dialog::backdrop {
  background: rgba(18, 18, 18, 0.85);
  backdrop-filter: blur(4px);
}

/* Remove default browser dialog focus outline */
.carousel-dialog:focus {
  outline: none;
}

/* Inner wrapper — stops click propagation so only true backdrop clicks reach the dialog element */
.carousel-dialog__inner {
  display: flex;
  flex-direction: column;
  position: relative;
  max-height: 90dvh;
  overflow: hidden;
}

/* Close button — top-right absolute */
.carousel-dialog__close {
  position: absolute;
  top: 0.75rem;
  right: 0.75rem;
  z-index: 2;
  background: transparent;
  border: none;
  color: var(--color-text-muted);
  font-size: 1.25rem;
  cursor: pointer;
  padding: 0.25rem;
  line-height: 1;
  transition: color var(--transition-base);
}

.carousel-dialog__close:hover,
.carousel-dialog__close:focus-visible {
  color: var(--color-silver-light);
  outline: none;
}

/* Carousel track — PROD-05: scroll-snap for native touch swipe (no JS touch events needed) */
.carousel-dialog__track {
  display: flex;
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  scroll-behavior: smooth;
  -webkit-overflow-scrolling: touch;  /* iOS momentum scroll */
  scrollbar-width: none;              /* Firefox: hide scrollbar */
  width: 100%;
}

.carousel-dialog__track::-webkit-scrollbar {
  display: none;                      /* Chrome/Safari: hide scrollbar */
}

/* Each image slide */
.carousel-dialog__slide {
  flex-shrink: 0;
  width: 100%;
  scroll-snap-align: start;
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 280px;
  background: var(--color-bg);
}

/* Carousel images — object-fit: contain (not cover) to show full product without cropping */
.carousel-dialog__slide img {
  max-width: 100%;
  max-height: 60vh;
  object-fit: contain;
  display: block;
}

/* Prev / Next arrow buttons — positioned absolute over the track */
.carousel-dialog__arrow {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  background: rgba(28, 28, 30, 0.75);  /* --color-surface at 75% */
  border: 1px solid var(--color-border);
  border-radius: 50%;
  color: var(--color-silver-light);
  font-size: 1.1rem;
  width: 2.25rem;
  height: 2.25rem;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  z-index: 2;
  transition: background var(--transition-base), color var(--transition-base);
}

.carousel-dialog__arrow:hover,
.carousel-dialog__arrow:focus-visible {
  background: var(--color-surface);
  color: var(--color-accent);
  outline: none;
}

.carousel-dialog__arrow--prev {
  left: 0.75rem;
}

.carousel-dialog__arrow--next {
  right: 0.75rem;
}

/* Footer strip below carousel — title + WhatsApp CTA */
.carousel-dialog__footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: 0.875rem 1.25rem;
  border-top: 1px solid var(--color-border);
  flex-shrink: 0;
  flex-wrap: wrap;
}

/* Meta group — stacks title + price vertically, takes up available space */
.carousel-dialog__meta {
  display: flex;
  flex-direction: column;
  gap: 0.2rem;
  flex: 1;
  min-width: 0;             /* prevents text overflow from stretching the footer */
}

/* Product title in footer */
.carousel-dialog__title {
  font-family: var(--font-display);
  font-size: 1.1rem;
  font-weight: 400;
  color: var(--color-silver-light);
  margin: 0;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

/* Product price in footer — accent color to match product card style */
.carousel-dialog__price {
  font-size: 0.95rem;
  font-weight: 600;
  color: var(--color-accent);
  margin: 0;
  letter-spacing: 0.01em;
}

/* WhatsApp CTA — reuses .btn--whatsapp from Phase 1/5; this adds size adjustments */
.carousel-dialog__cta {
  flex-shrink: 0;
  font-size: 0.85rem;
  padding: 0.5rem 1rem;
}

/* Responsive: on very small screens stack footer vertically */
@media (max-width: 400px) {
  .carousel-dialog__footer {
    flex-direction: column;
    align-items: flex-start;
  }
  .carousel-dialog__cta {
    width: 100%;
    justify-content: center;
  }
}

/* ── Product card — Sold Out badge ────────────────────────────────────── */
.product-card__badge--sold-out {
  position: absolute;
  top: 0.5rem;
  left: 0.5rem;
  background: rgba(18, 18, 18, 0.82);
  color: #D4AF7A;
  font-size: 0.65rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  padding: 0.2rem 0.5rem;
  border-radius: 3px;
  pointer-events: none;
  z-index: 1;
}
