
/* The hidden attribute must beat component display rules (.orders-shell { display: grid }
   and similar have equal specificity to [hidden] and would otherwise win on source order). */
[hidden] { display: none !important; }
/* ============================================================
   SILVI SAREE HOUSE — COMPONENTS
   ============================================================ */

/* ─── BUTTONS ─── */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: var(--space-2);
  font-family: var(--font-body);
  font-size: var(--text-sm);
  font-weight: 500;
  letter-spacing: var(--tracking-wide);
  text-transform: uppercase;
  padding: 14px 32px;
  border-radius: var(--radius-sm);
  cursor: pointer;
  transition: all var(--duration-base) var(--ease-elegant);
  white-space: nowrap;
  position: relative;
  overflow: hidden;
  border: 1.5px solid transparent;
}

.btn::after {
  content: '';
  position: absolute;
  inset: 0;
  background: rgba(255,255,255,0.08);
  opacity: 0;
  transition: opacity var(--duration-fast);
}

.btn:hover::after { opacity: 1; }
.btn:active { transform: scale(0.98); }

/* Primary Button */
.btn--primary {
  background: var(--color-primary);
  color: var(--color-ivory);
  border-color: var(--color-primary);
}

.btn--primary:hover {
  background: var(--color-primary-dark);
  border-color: var(--color-primary-dark);
  box-shadow: 0 4px 16px rgba(88,8,40,0.25);
}

/* Secondary / Outline */
.btn--outline {
  background: transparent;
  color: var(--color-primary);
  border-color: var(--color-primary);
}

.btn--outline:hover {
  background: var(--color-primary);
  color: var(--color-ivory);
}

/* Ghost on dark */
.btn--ghost-light {
  background: transparent;
  color: var(--color-ivory);
  border-color: rgba(245,237,216,0.5);
}

.btn--ghost-light:hover {
  background: rgba(245,237,216,0.15);
  border-color: var(--color-ivory);
}

/* Outline light */
.btn--outline-light {
  background: var(--color-ivory);
  color: var(--color-primary);
  border-color: var(--color-ivory);
}

.btn--outline-light:hover {
  background: transparent;
  color: var(--color-ivory);
}

/* Sizes */
.btn--sm {
  font-size: var(--text-xs);
  padding: 10px 20px;
}

.btn--lg {
  font-size: var(--text-base);
  padding: 18px 44px;
}

/* Icon button */
.btn-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
  border-radius: var(--radius-full);
  background: transparent;
  color: var(--color-text-primary);
  transition: all var(--duration-fast) var(--ease-default);
  position: relative;
}

.btn-icon:hover {
  background: var(--color-surface-warm);
  color: var(--color-primary);
}

.btn-icon svg {
  width: 20px;
  height: 20px;
  flex-shrink: 0;
}

/* ─── BADGE ─── */
.badge {
  display: inline-flex;
  align-items: center;
  padding: 3px 10px;
  border-radius: var(--radius-full);
  font-size: 10px;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.badge--new {
  background: var(--color-primary-subtle);
  color: var(--color-primary);
}

.badge--bestseller {
  background: rgba(196,149,106,0.15);
  color: var(--color-secondary-dark);
}

.badge--limited {
  background: rgba(88,8,40,0.08);
  color: var(--color-primary);
}

.badge--out-of-stock {
  background: var(--color-surface-warm);
  color: var(--color-text-tertiary);
}

/* ─── PRODUCT CARD ─── */
.product-card {
  position: relative;
  display: flex;
  flex-direction: column;
}

.product-card__media {
  position: relative;
  overflow: hidden;
  aspect-ratio: 3/4;
  background: var(--color-surface);
  border-radius: var(--radius-md);
}

.product-card__media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform var(--duration-slow) var(--ease-elegant);
}

.product-card__media .img-hover {
  position: absolute;
  inset: 0;
  opacity: 0;
  transition: opacity var(--duration-slow) var(--ease-elegant);
}

.product-card__image-link {
  display: block;
  width: 100%;
  height: 100%;
}

.product-card:hover .img-hover {
  opacity: 1;
}

.product-card:hover .product-card__media img:first-child {
  transform: scale(1.04);
}

.product-card__actions {
  position: absolute;
  top: var(--space-3);
  right: var(--space-3);
  display: flex;
  flex-direction: column;
  gap: var(--space-2);
  opacity: 0;
  transform: translateX(8px);
  transition: all var(--duration-base) var(--ease-elegant);
}

.product-card:hover .product-card__actions {
  opacity: 1;
  transform: translateX(0);
}

.product-card__action-btn {
  width: 36px;
  height: 36px;
  border-radius: var(--radius-full);
  background: white;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: var(--shadow-sm);
  color: var(--color-text-primary);
  transition: all var(--duration-fast);
}

.product-card__action-btn:hover {
  background: var(--color-primary);
  color: var(--color-ivory);
}

.product-card__action-btn svg {
  width: 16px;
  height: 16px;
}

.product-card__badges {
  position: absolute;
  top: var(--space-3);
  left: var(--space-3);
  display: flex;
  flex-direction: column;
  gap: var(--space-1);
}

.product-card__quick-view {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  background: rgba(36,4,22,0.85);
  color: var(--color-ivory);
  text-align: center;
  padding: 12px;
  font-size: var(--text-xs);
  font-weight: 500;
  letter-spacing: var(--tracking-wide);
  text-transform: uppercase;
  opacity: 0;
  transform: translateY(100%);
  transition: all var(--duration-base) var(--ease-elegant);
  border-radius: 0 0 var(--radius-md) var(--radius-md);
}

.product-card:hover .product-card__quick-view {
  opacity: 1;
  transform: translateY(0);
}

.product-card__info {
  padding: var(--space-4) 0 0;
}

.product-card__name {
  font-family: var(--font-display);
  font-size: var(--text-lg);
  font-weight: 400;
  color: var(--color-wine-deep);
  margin-bottom: var(--space-1);
  line-height: var(--leading-snug);
}

.product-card__descriptor {
  font-size: var(--text-sm);
  color: var(--color-text-secondary);
  margin-bottom: var(--space-3);
}

.product-card__price {
  display: flex;
  align-items: center;
  gap: var(--space-3);
}

.product-card__price-current {
  font-family: var(--font-body);
  font-size: var(--text-base);
  font-weight: 500;
  color: var(--color-wine-deep);
}

.product-card__price-original {
  font-size: var(--text-sm);
  color: var(--color-text-tertiary);
  text-decoration: line-through;
}

.product-card__swatches {
  display: flex;
  gap: 6px;
  margin-top: var(--space-3);
}

.swatch {
  width: 18px;
  height: 18px;
  border-radius: var(--radius-full);
  border: 1.5px solid transparent;
  cursor: pointer;
  transition: transform var(--duration-fast);
}

.swatch:hover,
.swatch.active {
  border-color: var(--color-primary);
  transform: scale(1.15);
}

/* ─── OCCASION CARD ─── */
.occasion-card {
  position: relative;
  overflow: hidden;
  border-radius: var(--radius-lg);
  cursor: pointer;
  display: block;
}

.occasion-card__media {
  aspect-ratio: 3/4;
  position: relative;
  overflow: hidden;
}

.occasion-card__media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform var(--duration-slow) var(--ease-elegant);
}

.occasion-card:hover .occasion-card__media img {
  transform: scale(1.06);
}

.occasion-card__overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(to top, rgba(36,4,22,0.75) 0%, rgba(36,4,22,0.1) 50%, transparent 100%);
  transition: opacity var(--duration-base);
}

.occasion-card__content {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  padding: var(--space-6);
  color: var(--color-ivory);
}

.occasion-card__name {
  font-family: var(--font-display);
  font-size: var(--text-2xl);
  font-weight: 400;
  line-height: 1.2;
  margin-bottom: var(--space-2);
}

.occasion-card__desc {
  font-size: var(--text-sm);
  color: rgba(245,237,216,0.8);
  margin-bottom: var(--space-4);
  line-height: var(--leading-relaxed);
}

.occasion-card__cta {
  display: inline-flex;
  align-items: center;
  gap: var(--space-2);
  font-size: var(--text-xs);
  font-weight: 500;
  letter-spacing: var(--tracking-wide);
  text-transform: uppercase;
  color: var(--color-secondary-light);
  text-decoration: none;
  transition: gap var(--duration-fast);
}

.occasion-card:hover .occasion-card__cta {
  gap: var(--space-3);
}

/* ─── FABRIC CARD ─── */
.fabric-card {
  text-align: center;
  cursor: pointer;
}

.fabric-card__media {
  aspect-ratio: 1;
  border-radius: var(--radius-full);
  overflow: hidden;
  margin-bottom: var(--space-4);
  border: 2px solid var(--color-border-light);
  transition: border-color var(--duration-base), transform var(--duration-base) var(--ease-spring);
}

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

.fabric-card:hover .fabric-card__media {
  border-color: var(--color-primary);
  transform: scale(1.03);
}

.fabric-card__name {
  font-family: var(--font-display);
  font-size: var(--text-xl);
  font-weight: 400;
  color: var(--color-wine-deep);
  margin-bottom: var(--space-2);
}

.fabric-card__desc {
  font-size: var(--text-sm);
  color: var(--color-text-secondary);
  line-height: var(--leading-relaxed);
}

/* ─── PRICE CARD ─── */
.price-card {
  background: var(--color-surface);
  border: 1px solid var(--color-border-light);
  border-radius: var(--radius-lg);
  padding: var(--space-10) var(--space-8);
  text-align: center;
  cursor: pointer;
  transition: all var(--duration-base) var(--ease-elegant);
  position: relative;
  overflow: hidden;
}

.price-card::before {
  content: '';
  position: absolute;
  inset: 0;
  background: var(--color-primary);
  opacity: 0;
  transition: opacity var(--duration-base);
}

.price-card:hover {
  border-color: var(--color-primary);
  box-shadow: var(--shadow-lg);
  transform: translateY(-4px);
}

.price-card:hover::before {
  opacity: 0.03;
}

.price-card__range {
  font-family: var(--font-display);
  font-size: var(--text-3xl);
  font-weight: 500;
  color: var(--color-primary);
  display: block;
  margin-bottom: var(--space-2);
  letter-spacing: -0.01em;
}

.price-card__label {
  font-size: var(--text-sm);
  color: var(--color-text-secondary);
  font-weight: 400;
}

/* ─── JOURNAL CARD ─── */
.journal-card {
  display: flex;
  flex-direction: column;
}

.journal-card__media {
  aspect-ratio: 4/3;
  overflow: hidden;
  border-radius: var(--radius-md);
  margin-bottom: var(--space-5);
}

.journal-card__media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform var(--duration-slow) var(--ease-elegant);
}

.journal-card:hover .journal-card__media img {
  transform: scale(1.04);
}

.journal-card__category {
  font-size: var(--text-xs);
  font-weight: 500;
  letter-spacing: var(--tracking-wider);
  text-transform: uppercase;
  color: var(--color-secondary);
  margin-bottom: var(--space-2);
}

.journal-card__title {
  font-family: var(--font-display);
  font-size: var(--text-xl);
  font-weight: 400;
  color: var(--color-wine-deep);
  line-height: var(--leading-snug);
  margin-bottom: var(--space-3);
  transition: color var(--duration-fast);
}

.journal-card:hover .journal-card__title {
  color: var(--color-primary);
}

.journal-card__excerpt {
  font-size: var(--text-sm);
  color: var(--color-text-secondary);
  line-height: var(--leading-relaxed);
  flex: 1;
  margin-bottom: var(--space-4);
}

.journal-card__meta {
  display: flex;
  align-items: center;
  gap: var(--space-3);
  font-size: var(--text-xs);
  color: var(--color-text-tertiary);
}

/* ─── ANNOUNCEMENT BAR ─── */
.announcement-bar {
  background: var(--color-primary);
  color: var(--color-ivory);
  height: var(--announcement-height);
  display: flex;
  align-items: center;
  overflow: hidden;
  position: relative;
  z-index: var(--z-sticky);
}

.announcement-bar__track {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  position: relative;
  height: 100%;
}

.announcement-bar__item {
  position: absolute;
  width: 100%;
  text-align: center;
  font-size: var(--text-xs);
  letter-spacing: var(--tracking-wide);
  display: flex;
  align-items: center;
  justify-content: center;
  gap: var(--space-4);
  padding: 0 var(--space-8);
  opacity: 0;
  transform: translateY(100%);
  transition: opacity 0.5s, transform 0.5s var(--ease-elegant);
}

.announcement-bar__item.active {
  opacity: 1;
  transform: translateY(0);
}

.announcement-bar__item.exit {
  opacity: 0;
  transform: translateY(-100%);
}

.announcement-bar__close {
  position: absolute;
  right: var(--space-4);
  top: 50%;
  transform: translateY(-50%);
  background: transparent;
  border: none;
  color: var(--color-ivory);
  cursor: pointer;
  opacity: 0.7;
  padding: 4px;
}

/* ─── HEADER ─── */
.header {
  position: fixed;
  top: var(--announcement-height);
  left: 0;
  right: 0;
  /* Keep header-owned dropdowns above page-level sticky navigation bars. */
  z-index: var(--z-overlay);
  transition: background var(--duration-base) var(--ease-elegant),
              box-shadow var(--duration-base),
              top var(--duration-base);
  height: var(--header-height);
}

.header.transparent {
  background: transparent;
}

.header.solid {
  background: rgba(253,250,247,0.97);
  backdrop-filter: blur(8px);
  box-shadow: 0 1px 0 var(--color-border-light);
}

.header.announcement-hidden {
  top: 0;
}

.header > .container {
  height: 100%;
}

.header__inner {
  height: 100%;
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  gap: var(--space-4);
}

.header__logo {
  justify-self: start;
  display: flex;
  align-items: center;
}

.header__logo img,
.header__logo svg {
  height: 40px;
  width: auto;
  transition: filter var(--duration-base);
}

.header__logo .header__logo-image {
  height: 48px;
  width: auto;
  max-width: 150px;
  display: block;
  object-fit: contain;
}

.header.transparent .header__logo-dark { display: block; filter: brightness(0) invert(1); }
.header.solid     .header__logo-dark { filter: none; }

.header__nav {
  display: flex;
  align-items: center;
  gap: var(--space-2);
}

.header__nav-item {
  position: relative;
}

.header__nav-link {
  font-size: var(--text-sm);
  font-weight: 400;
  letter-spacing: 0.02em;
  color: #000;
  padding: var(--space-2) var(--space-3);
  border-radius: var(--radius-sm);
  transition: color var(--duration-fast), background var(--duration-fast);
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 4px;
  white-space: nowrap;
}

.header.transparent .header__nav-link {
  color: #000;
}

.header__nav-link:hover {
  color: #000;
  background: rgba(88,8,40,0.05);
}

.header.transparent .header__nav-link:hover {
  background: rgba(255,255,255,0.1);
  color: #000;
}

.header__actions {
  justify-self: end;
  display: flex;
  align-items: center;
  gap: var(--space-1);
}

.header__cart-count {
  position: absolute;
  top: -4px;
  right: -4px;
  width: 16px;
  height: 16px;
  border-radius: var(--radius-full);
  background: var(--color-primary);
  color: var(--color-ivory);
  font-size: 9px;
  font-weight: 600;
  display: flex;
  align-items: center;
  justify-content: center;
}

/* ─── ACCOUNT MENU ─── */
/* Without JS this stays a plain link to the account page, so the popup
   semantics and behaviour are added by script rather than declared here. */
.account-menu {
  position: relative;
  display: flex;
}

.account-menu__panel {
  position: absolute;
  top: calc(100% + 10px);
  right: 0;
  z-index: var(--z-dropdown);
  width: 260px;
  padding: var(--space-2);
  border: 1px solid var(--color-border-light);
  border-radius: var(--radius-lg);
  background: white;
  box-shadow: var(--shadow-lg);
  opacity: 0;
  /* visibility rather than display: it animates, and it takes the closed panel
     out of the accessibility tree and the tab order without needing script to
     toggle [hidden] on every open. */
  visibility: hidden;
  transform: translateY(-6px);
  /* visibility is deliberately not transitioned. Delaying it to cover a
     fade-out leaves the panel unfocusable for the length of the delay on open,
     and leaves it visible if transitions do not run at all. */
  transition: opacity var(--duration-base) var(--ease-elegant),
              transform var(--duration-base) var(--ease-elegant);
}

/* Only until the script runs; a visitor without JS never sees the panel. */
.account-menu__panel[hidden] { display: none; }

.account-menu.is-open .account-menu__panel {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}

/* The caret overlaps the panel border, so it takes two triangles: the border
   colour behind, the fill one pixel lower. */
.account-menu__panel::before,
.account-menu__panel::after {
  content: '';
  position: absolute;
  right: 14px;
  border: 7px solid transparent;
}

.account-menu__panel::before {
  bottom: 100%;
  border-bottom-color: var(--color-border-light);
}

.account-menu__panel::after {
  bottom: calc(100% - 1px);
  border-bottom-color: white;
}

.account-menu__head {
  padding: var(--space-3) var(--space-3) var(--space-4);
  margin-bottom: var(--space-2);
  border-bottom: 1px solid var(--color-border-light);
}

.account-menu__greeting {
  color: var(--color-text-tertiary);
  font-size: 10px;
  font-weight: 700;
  letter-spacing: var(--tracking-wider);
  text-transform: uppercase;
}

.account-menu__name {
  margin-top: 4px;
  color: var(--color-wine-deep);
  font: 500 var(--text-lg)/1.2 var(--font-display);
}

.account-menu__email,
.account-menu__prompt {
  overflow: hidden;
  margin-top: 4px;
  color: var(--color-text-secondary);
  font-size: var(--text-xs);
  text-overflow: ellipsis;
  white-space: nowrap;
}

.account-menu__prompt {
  white-space: normal;
  line-height: var(--leading-relaxed);
}

.account-menu__item {
  display: flex;
  align-items: center;
  gap: var(--space-3);
  width: 100%;
  padding: 10px var(--space-3);
  border-radius: var(--radius-md);
  color: var(--color-text-secondary);
  font-size: var(--text-sm);
  font-weight: 500;
  text-align: left;
}

.account-menu__item:hover,
.account-menu__item:focus-visible {
  color: var(--color-primary);
  background: var(--color-surface);
}

.account-menu__item svg { flex-shrink: 0; color: var(--color-secondary-dark); }

.account-menu__item:hover svg,
.account-menu__item:focus-visible svg { color: var(--color-primary); }

.account-menu__badge {
  margin-left: auto;
  padding: 1px 8px;
  border-radius: var(--radius-full);
  background: var(--color-surface-warm);
  color: var(--color-text-secondary);
  font-size: var(--text-xs);
  font-weight: 600;
}

.account-menu__cta { width: 100%; margin-bottom: var(--space-2); }

/* .btn declares `transition: all`, so the visibility the panel passes down is
   animated too - and a discrete property mid-transition still computes as
   hidden, leaving the CTA unfocusable for half the duration. Restrict it to
   the properties actually worth animating here. */
.account-menu__panel .btn {
  transition-property: color, background-color, border-color, box-shadow;
}

.account-menu__divider {
  height: 1px;
  margin: var(--space-2) var(--space-3);
  background: var(--color-border-light);
}

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

/* A 260px panel anchored to the icon overflows a narrow viewport. */
@media (max-width: 640px) {
  .account-menu__panel {
    position: fixed;
    top: auto;
    right: var(--space-4);
    left: var(--space-4);
    width: auto;
  }
  .account-menu__panel::before,
  .account-menu__panel::after { display: none; }
}

/* ─── MEGA MENU ─── */
.mega-menu {
  position: absolute;
  top: 100%;
  right: 0;
  left: 0;
  overflow: hidden;
  background: #fffdf7;
  border-top: 1px solid var(--color-border-light);
  border-bottom: 1px solid var(--color-border-light);
  box-shadow: var(--shadow-xl);
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transform: translateY(-8px);
  transition: opacity var(--duration-base) var(--ease-elegant),
              transform var(--duration-base) var(--ease-elegant);
  z-index: var(--z-dropdown);
}

.mega-menu.is-open {
  opacity: 1;
  visibility: visible;
  pointer-events: all;
  transform: translateY(0);
}

.header.mega-menu-open {
  background: rgba(253,250,247,0.98);
  box-shadow: 0 1px 0 var(--color-border-light);
}

.header__nav-link[aria-haspopup="true"]::after {
  content: '';
  width: 5px;
  height: 5px;
  margin-left: 2px;
  border-right: 1px solid currentColor;
  border-bottom: 1px solid currentColor;
  transform: translateY(-2px) rotate(45deg);
  transition: transform var(--duration-fast);
}

.header__nav-item.is-mega-active .header__nav-link {
  color: var(--color-primary);
  background: rgba(88,8,40,0.06);
}

.header__nav-item.is-mega-active .header__nav-link::after {
  transform: translateY(1px) rotate(225deg);
}

.mega-menu__inner {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(340px, 0.36fr);
  gap: clamp(var(--space-8), 5vw, 72px);
  width: min(100% - 64px, 1320px);
  min-height: 330px;
  max-height: calc(100vh - var(--header-height) - var(--announcement-height) - 56px);
  margin-inline: auto;
  padding: var(--space-8) 0 var(--space-6);
}

.mega-menu__columns {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(130px, 1fr));
  align-content: start;
  gap: var(--space-8);
}

.mega-menu__col-title {
  margin-bottom: var(--space-4);
  color: var(--color-wine-deep);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: var(--tracking-wider);
  text-transform: uppercase;
}

.mega-menu__col ul {
  display: flex;
  flex-direction: column;
  gap: 9px;
}

.mega-menu__col a {
  display: inline-block;
  padding: 1px 0;
  color: var(--color-text-secondary);
  font-size: var(--text-sm);
  line-height: 1.35;
  transition: color var(--duration-fast), transform var(--duration-fast);
}

.mega-menu__col a:hover,
.mega-menu__col a:focus-visible {
  color: var(--color-primary);
  transform: translateX(4px);
}

.mega-menu__promos {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: var(--space-4);
}

.mega-menu__promo {
  display: flex;
  min-width: 0;
  flex-direction: column;
  color: var(--color-text-primary);
}

.mega-menu__image {
  display: block;
  aspect-ratio: 4/5;
  overflow: hidden;
  border-radius: var(--radius-sm);
  background: var(--color-surface-warm);
}

.mega-menu__image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform var(--duration-slow) var(--ease-elegant);
}

.mega-menu__promo:hover .mega-menu__image img,
.mega-menu__promo:focus-visible .mega-menu__image img {
  transform: scale(1.025);
}

.mega-menu__promo-copy {
  display: flex;
  flex-direction: column;
  gap: 2px;
  padding-top: var(--space-3);
}

.mega-menu__promo-copy strong {
  color: var(--color-wine-deep);
  font: 500 var(--text-base)/1.25 var(--font-display);
}

.mega-menu__promo-copy span {
  color: var(--color-text-tertiary);
  font-size: 11px;
  line-height: 1.4;
}

.mega-menu__footer {
  border-top: 1px solid var(--color-border-light);
}

.mega-menu__footer a {
  display: block;
  width: min(100% - 64px, 1320px);
  margin-inline: auto;
  padding: 13px 0 14px;
  color: var(--color-primary);
  font-size: var(--text-xs);
  font-weight: 600;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

@media (max-width: 1180px) {
  .mega-menu__inner {
    grid-template-columns: minmax(0, 1fr) 300px;
    gap: var(--space-6);
    width: calc(100% - 40px);
  }

  .mega-menu__columns { gap: var(--space-5); }
  .mega-menu__footer a { width: calc(100% - 40px); }
}

@media (max-width: 1024px) {
  .mega-menu { display: none; }
}

@media (prefers-reduced-motion: reduce) {
  .mega-menu,
  .mega-menu__image img { transition: none; }
}

/* ─── MOBILE MENU ─── */
.mobile-menu {
  position: fixed;
  inset: 0;
  z-index: var(--z-modal);
  pointer-events: none;
}

.mobile-menu__overlay {
  position: absolute;
  inset: 0;
  background: rgba(36,4,22,0.5);
  opacity: 0;
  transition: opacity var(--duration-slow);
  backdrop-filter: blur(2px);
}

.mobile-menu__panel {
  position: absolute;
  top: 0;
  left: 0;
  bottom: 0;
  width: min(320px, 85vw);
  background: white;
  transform: translateX(-100%);
  transition: transform var(--duration-slow) var(--ease-elegant);
  overflow-y: auto;
  padding: var(--space-6);
  display: flex;
  flex-direction: column;
  gap: var(--space-6);
}

.mobile-menu.open {
  pointer-events: all;
}

.mobile-menu.open .mobile-menu__overlay {
  opacity: 1;
}

.mobile-menu.open .mobile-menu__panel {
  transform: translateX(0);
}

.mobile-menu__header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding-bottom: var(--space-4);
  border-bottom: 1px solid var(--color-border-light);
}

.mobile-menu__nav {
  display: flex;
  flex-direction: column;
  flex: 1;
}

.mobile-menu__item {
  border-bottom: 1px solid var(--color-border-light);
}

.mobile-menu__link {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: var(--space-4) 0;
  font-size: var(--text-base);
  font-weight: 400;
  color: var(--color-text-primary);
}

.mobile-menu__link:hover {
  color: var(--color-primary);
}

.mobile-menu__sub {
  padding: 0 0 var(--space-4) var(--space-4);
  display: flex;
  flex-direction: column;
  gap: var(--space-3);
  display: none;
}

.mobile-menu__item.expanded .mobile-menu__sub {
  display: flex;
}

.mobile-menu__sub a {
  font-size: var(--text-sm);
  color: var(--color-text-secondary);
}

.mobile-menu__sub a:hover {
  color: var(--color-primary);
}

.mobile-menu__footer {
  display: flex;
  flex-direction: column;
  gap: var(--space-4);
  padding-top: var(--space-4);
  border-top: 1px solid var(--color-border-light);
}

.mobile-menu__social {
  display: flex;
  gap: var(--space-4);
  align-items: center;
}

/* ─── CART DRAWER ─── */
.cart-drawer {
  position: fixed;
  inset: 0;
  z-index: var(--z-modal);
  pointer-events: none;
}

.cart-drawer__overlay {
  position: absolute;
  inset: 0;
  background: rgba(36,4,22,0.4);
  opacity: 0;
  transition: opacity var(--duration-slow);
  backdrop-filter: blur(2px);
}

.cart-drawer__panel {
  position: absolute;
  top: 0;
  right: 0;
  bottom: 0;
  width: min(420px, 90vw);
  background: white;
  transform: translateX(100%);
  transition: transform var(--duration-slow) var(--ease-elegant);
  display: flex;
  flex-direction: column;
}

.cart-drawer.open {
  pointer-events: all;
}

.cart-drawer.open .cart-drawer__overlay { opacity: 1; }
.cart-drawer.open .cart-drawer__panel { transform: translateX(0); }

.cart-drawer__header {
  padding: var(--space-6);
  border-bottom: 1px solid var(--color-border-light);
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-shrink: 0;
}

.cart-drawer__title {
  font-family: var(--font-display);
  font-size: var(--text-xl);
  font-weight: 400;
}

.cart-drawer__items {
  flex: 1;
  overflow-y: auto;
  padding: var(--space-6);
  display: flex;
  flex-direction: column;
  gap: var(--space-6);
}

.cart-item {
  display: grid;
  grid-template-columns: 80px 1fr;
  gap: var(--space-4);
}

.cart-item__image {
  aspect-ratio: 3/4;
  border-radius: var(--radius-sm);
  overflow: hidden;
  background: var(--color-surface);
}

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

.cart-item__info {
  display: flex;
  flex-direction: column;
  gap: var(--space-2);
}

.cart-item__name {
  font-family: var(--font-display);
  font-size: var(--text-base);
  font-weight: 400;
  line-height: 1.3;
}

.cart-item__detail {
  font-size: var(--text-xs);
  color: var(--color-text-secondary);
}

.cart-item__qty {
  display: flex;
  align-items: center;
  gap: var(--space-2);
}

.qty-btn {
  width: 28px;
  height: 28px;
  border: 1px solid var(--color-border);
  border-radius: var(--radius-sm);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: var(--text-sm);
  cursor: pointer;
  background: white;
  transition: all var(--duration-fast);
}

.qty-btn:hover {
  border-color: var(--color-primary);
  color: var(--color-primary);
}

.qty-value {
  min-width: 24px;
  text-align: center;
  font-size: var(--text-sm);
}

.cart-item__price {
  font-weight: 500;
  font-size: var(--text-base);
  margin-top: auto;
}

.cart-drawer__footer {
  padding: var(--space-6);
  border-top: 1px solid var(--color-border-light);
  flex-shrink: 0;
}

.cart-total {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: var(--space-4);
  font-size: var(--text-base);
}

.cart-total__value {
  font-weight: 600;
  font-size: var(--text-lg);
}

/* ─── MODAL ─── */
.modal {
  position: fixed;
  inset: 0;
  z-index: var(--z-modal);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: var(--space-6);
  pointer-events: none;
  opacity: 0;
  transition: opacity var(--duration-base);
}

.modal.open {
  pointer-events: all;
  opacity: 1;
}

.modal__overlay {
  position: absolute;
  inset: 0;
  background: rgba(36,4,22,0.5);
  backdrop-filter: blur(4px);
}

.modal__content {
  position: relative;
  background: white;
  border-radius: var(--radius-xl);
  max-width: 900px;
  width: 100%;
  max-height: 90vh;
  overflow-y: auto;
  box-shadow: var(--shadow-xl);
  transform: scale(0.95) translateY(16px);
  transition: transform var(--duration-base) var(--ease-spring);
}

.modal.open .modal__content {
  transform: scale(1) translateY(0);
}

.modal__close {
  position: absolute;
  top: var(--space-4);
  right: var(--space-4);
  z-index: 1;
  width: 36px;
  height: 36px;
  border-radius: var(--radius-full);
  background: var(--color-surface);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: background var(--duration-fast);
}

.modal__close:hover {
  background: var(--color-cream);
}

/* ─── FORM ELEMENTS ─── */
.form-group {
  display: flex;
  flex-direction: column;
  gap: var(--space-2);
}

.form-label {
  font-size: var(--text-sm);
  font-weight: 500;
  color: var(--color-text-primary);
}

.form-input,
.form-select,
.form-textarea {
  width: 100%;
  padding: 12px 16px;
  border: 1.5px solid var(--color-border);
  border-radius: var(--radius-md);
  font-size: var(--text-base);
  color: var(--color-text-primary);
  background: white;
  transition: border-color var(--duration-fast), box-shadow var(--duration-fast);
  outline: none;
}

.form-input:focus,
.form-select:focus,
.form-textarea:focus {
  border-color: var(--color-primary);
  box-shadow: 0 0 0 3px rgba(88,8,40,0.1);
}

.form-input::placeholder,
.form-textarea::placeholder {
  color: var(--color-text-tertiary);
}

.form-textarea {
  resize: vertical;
  min-height: 120px;
}

.form-hint {
  font-size: var(--text-xs);
  color: var(--color-text-tertiary);
}

.form-error-msg {
  font-size: var(--text-xs);
  color: var(--color-error);
}

/* ─── ACCORDION ─── */
.accordion-item {
  border-bottom: 1px solid var(--color-border-light);
}

.accordion-trigger {
  width: 100%;
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: var(--space-5) 0;
  font-size: var(--text-base);
  font-weight: 500;
  color: var(--color-text-primary);
  cursor: pointer;
  transition: color var(--duration-fast);
  text-align: left;
}

.accordion-trigger:hover {
  color: var(--color-primary);
}

.accordion-icon {
  width: 20px;
  height: 20px;
  flex-shrink: 0;
  color: var(--color-text-secondary);
  transition: transform var(--duration-base) var(--ease-elegant);
}

.accordion-item.open .accordion-icon {
  transform: rotate(180deg);
}

.accordion-content {
  max-height: 0;
  overflow: hidden;
  transition: max-height var(--duration-slow) var(--ease-elegant),
              padding var(--duration-slow) var(--ease-elegant);
}

.accordion-item.open .accordion-content {
  max-height: 800px;
}

.accordion-body {
  padding-bottom: var(--space-5);
  font-size: var(--text-sm);
  color: var(--color-text-secondary);
  line-height: var(--leading-relaxed);
}

/* ─── BREADCRUMB ─── */
.breadcrumb {
  display: flex;
  align-items: center;
  gap: var(--space-2);
  font-size: var(--text-sm);
  color: var(--color-text-secondary);
}

.breadcrumb a {
  transition: color var(--duration-fast);
}

.breadcrumb a:hover {
  color: var(--color-primary);
}

.breadcrumb__sep {
  color: var(--color-text-tertiary);
}

/* ─── TOAST ─── */
.toast-container {
  position: fixed;
  bottom: var(--space-6);
  right: var(--space-6);
  z-index: var(--z-toast);
  display: flex;
  flex-direction: column;
  gap: var(--space-3);
}

.toast {
  display: flex;
  align-items: center;
  gap: var(--space-3);
  background: var(--color-wine-deep);
  color: var(--color-ivory);
  padding: var(--space-4) var(--space-5);
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-lg);
  font-size: var(--text-sm);
  max-width: 320px;
  opacity: 0;
  transform: translateX(16px);
  transition: all var(--duration-base) var(--ease-elegant);
}

.toast.show {
  opacity: 1;
  transform: translateX(0);
}

.toast--success {
  background: var(--color-primary);
}

/* ─── SKELETON LOADERS ─── */
.skeleton {
  background: linear-gradient(90deg, var(--color-surface) 25%, var(--color-cream) 50%, var(--color-surface) 75%);
  background-size: 200% 100%;
  animation: skeleton-loading 1.5s ease-in-out infinite;
  border-radius: var(--radius-sm);
}

@keyframes skeleton-loading {
  0% { background-position: 200% 0; }
  100% { background-position: -200% 0; }
}

/* ─── TRUST STRIP ─── */
.trust-strip {
  border-top: 1px solid var(--color-border-light);
  border-bottom: 1px solid var(--color-border-light);
  padding-block: var(--space-5);
  background: var(--color-bg);
}

.trust-strip__items {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: var(--space-10);
  flex-wrap: wrap;
}

.trust-item {
  display: flex;
  align-items: center;
  gap: var(--space-3);
  color: var(--color-text-secondary);
}

.trust-item__icon {
  width: 20px;
  height: 20px;
  color: var(--color-secondary);
  flex-shrink: 0;
}

.trust-item__text {
  font-size: var(--text-sm);
  font-weight: 400;
  white-space: nowrap;
}

/* ─── RATING STARS ─── */
.stars {
  display: flex;
  gap: 2px;
  color: var(--color-secondary);
}

.stars svg {
  width: 14px;
  height: 14px;
}

/* ─── MOBILE BOTTOM NAV ─── */
.mobile-bottom-nav {
  display: none;
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  background: white;
  border-top: 1px solid var(--color-border-light);
  z-index: var(--z-sticky);
  padding-bottom: env(safe-area-inset-bottom);
}

.mobile-bottom-nav__items {
  display: flex;
  align-items: center;
  justify-content: space-around;
  height: 60px;
}

.mobile-bottom-nav__item {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
  color: var(--color-text-secondary);
  font-size: 10px;
  font-weight: 500;
  cursor: pointer;
  transition: color var(--duration-fast);
  padding: 8px;
  position: relative;
}

.mobile-bottom-nav__item svg {
  width: 22px;
  height: 22px;
}

.mobile-bottom-nav__item.active,
.mobile-bottom-nav__item:hover {
  color: var(--color-primary);
}

@media (max-width: 768px) {
  .mobile-bottom-nav { display: block; }
  body { padding-bottom: 60px; }
}

/* ─── FILTER SIDEBAR ─── */
.filter-sidebar {
  width: 240px;
  flex-shrink: 0;
}

.filter-group {
  border-bottom: 1px solid var(--color-border-light);
  padding-block: var(--space-5);
}

.filter-group__title {
  font-size: var(--text-sm);
  font-weight: 600;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  color: var(--color-text-primary);
  margin-bottom: var(--space-4);
  cursor: pointer;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.filter-option {
  display: flex;
  align-items: center;
  gap: var(--space-3);
  margin-bottom: var(--space-3);
  cursor: pointer;
}

.filter-option input[type="checkbox"] {
  appearance: none;
  width: 16px;
  height: 16px;
  border: 1.5px solid var(--color-border);
  border-radius: 3px;
  cursor: pointer;
  transition: all var(--duration-fast);
  flex-shrink: 0;
}

.filter-option input[type="checkbox"]:checked {
  background: var(--color-primary);
  border-color: var(--color-primary);
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='10' height='10' viewBox='0 0 10 10'%3E%3Cpath d='M1 5l3 3 5-5' stroke='white' stroke-width='1.5' fill='none' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: center;
}

.filter-option label {
  font-size: var(--text-sm);
  color: var(--color-text-secondary);
  cursor: pointer;
}

/* ─── PAGE HERO ─── */
.page-hero {
  background: var(--color-primary);
  color: var(--color-ivory);
  padding: var(--space-16) 0 var(--space-12);
  text-align: center;
}

.page-hero h1 {
  font-family: var(--font-display);
  font-size: clamp(var(--text-3xl), 5vw, var(--text-6xl));
  font-weight: 400;
  margin-bottom: var(--space-4);
  line-height: var(--leading-tight);
}

.page-hero p {
  font-size: var(--text-md);
  color: rgba(245,237,216,0.75);
  max-width: 500px;
  margin-inline: auto;
  line-height: var(--leading-relaxed);
}

/* ─── WISHLIST BUTTON ─── */
.wishlist-btn {
  background: none;
  border: none;
  cursor: pointer;
  color: var(--color-text-secondary);
  display: flex;
  align-items: center;
  justify-content: center;
  transition: color var(--duration-fast);
}

.wishlist-btn:hover,
.wishlist-btn.active {
  color: var(--color-primary);
}

.wishlist-btn.active svg {
  fill: var(--color-primary);
}

/* ─── STEP TRACKER ─── */
.step-tracker {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0;
  margin-bottom: var(--space-12);
}

.step {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: var(--space-2);
  position: relative;
}

.step:not(:last-child)::after {
  content: '';
  position: absolute;
  top: 16px;
  left: calc(50% + 16px);
  width: calc(100% - 32px);
  height: 1px;
  background: var(--color-border);
}

.step.completed:not(:last-child)::after {
  background: var(--color-primary);
}

.step__circle {
  width: 32px;
  height: 32px;
  border-radius: var(--radius-full);
  border: 1.5px solid var(--color-border);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: var(--text-sm);
  font-weight: 500;
  color: var(--color-text-tertiary);
  background: white;
  z-index: 1;
}

.step.active .step__circle {
  border-color: var(--color-primary);
  color: var(--color-primary);
  background: var(--color-primary-subtle);
}

.step.completed .step__circle {
  background: var(--color-primary);
  border-color: var(--color-primary);
  color: white;
}

.step__label {
  font-size: 11px;
  color: var(--color-text-tertiary);
  white-space: nowrap;
}

.step.active .step__label {
  color: var(--color-primary);
  font-weight: 500;
}

/* ─── FOOTER ─── */
.footer {
  background: #4e0f22;
  color: #fff;
}

.footer svg {
  color: #fff !important;
}

.footer__main {
  padding: var(--space-16) 0 var(--space-12);
  display: grid;
  grid-template-columns: 1.5fr 1fr 1fr 1fr;
  gap: var(--space-10);
}

.footer__main > div:first-child > svg {
  display: none;
}

.footer__main > div:first-child::before {
  content: "";
  display: block;
  width: 180px;
  max-width: 100%;
  aspect-ratio: 600 / 241;
  background: url("../images/brand/silvi-logo-footer.silvi.webp") left center / contain no-repeat;
}

.footer__brand-desc {
  font-size: var(--text-sm);
  color: #fff;
  line-height: var(--leading-relaxed);
  margin-top: var(--space-4);
  max-width: 260px;
}

.footer__col-title {
  font-size: var(--text-xs);
  font-weight: 600;
  letter-spacing: var(--tracking-wider);
  text-transform: uppercase;
  color: #fff;
  margin-bottom: var(--space-5);
}

.footer__links {
  display: flex;
  flex-direction: column;
  gap: var(--space-3);
}

.footer__links li:has(> a[href="shop.html"]) {
  display: none;
}

.footer__links a[href="shop.html"] {
  display: none;
}

.footer__links a {
  font-size: var(--text-sm);
  color: #fff;
  transition: color var(--duration-fast);
}

.footer__links a:hover {
  color: #fff;
}

.footer__social {
  display: flex;
  gap: var(--space-4);
  margin-top: var(--space-6);
}

.footer__social a {
  width: 36px;
  height: 36px;
  border: 1px solid rgba(245,237,216,0.2);
  border-radius: var(--radius-full);
  display: flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  transition: all var(--duration-fast);
}

.footer__social a:hover {
  border-color: #fff;
  color: #fff;
  background: rgba(255,255,255,0.1);
}

.footer__bottom {
  border-top: 1px solid rgba(245,237,216,0.1);
  padding: var(--space-6) 0;
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: var(--space-4);
}

.footer__copyright {
  font-size: var(--text-xs);
  color: #fff;
}

.footer__legal-links {
  display: flex;
  gap: var(--space-5);
}

.footer__legal-links a {
  font-size: var(--text-xs);
  color: #fff;
  transition: color var(--duration-fast);
}

.footer__legal-links a:hover {
  color: #fff;
}

@media (max-width: 1024px) {
  .footer__main {
    grid-template-columns: 1fr 1fr;
    gap: var(--space-8);
  }
}

@media (max-width: 600px) {
  .footer__main {
    grid-template-columns: 1fr;
  }
  .footer__bottom {
    flex-direction: column;
    align-items: flex-start;
  }
}

/* ─── SEARCH OVERLAY ─── */
.search-overlay {
  position: fixed;
  inset: 0;
  z-index: var(--z-modal);
  display: flex;
  justify-content: center;
  align-items: flex-start;
  padding: 24px var(--space-4);
  background: rgba(52,8,21,0.48);
  backdrop-filter: blur(6px);
  opacity: 0;
  pointer-events: none;
  transition: opacity var(--duration-base);
}

.search-overlay.open {
  opacity: 1;
  pointer-events: all;
}

.search-overlay__box {
  width: min(720px, 100%);
  max-width: 720px;
  margin: 0;
  padding: 0;
  background: transparent;
  transform: translateY(-12px);
  transition: transform var(--duration-base) var(--ease-elegant);
}

.search-overlay.open .search-overlay__box {
  transform: translateY(0);
}

.search-input-wrap {
  display: flex;
  align-items: center;
  gap: var(--space-3);
  min-height: 58px;
  padding: 7px 10px 7px 18px;
  border: 1.5px solid #4e0f22;
  border-radius: 999px;
  background: #fffdf1;
  box-shadow: none !important;
  filter: none !important;
  transition: border-color var(--duration-fast), background var(--duration-fast);
}

.search-input-wrap:focus-within {
  border-color: #340815;
  background: #fff6e5;
  box-shadow: none !important;
  filter: none !important;
  outline: none;
}

.search-input-wrap > svg {
  width: 20px;
  height: 20px;
  color: #4e0f22 !important;
}

.search-input-wrap input {
  flex: 1;
  min-width: 0;
  border: none;
  outline: none;
  font-family: var(--font-body);
  font-size: var(--text-base);
  font-weight: 400;
  color: #340815;
  background: transparent;
}

.search-input-wrap input::placeholder {
  color: rgba(78,15,34,0.58);
}

.search-input-wrap .search-close-btn {
  width: 42px;
  height: 42px;
  flex-shrink: 0;
  color: #4e0f22;
  border-radius: 50%;
}

.search-input-wrap .search-close-btn:hover {
  background: #fff6e5;
  color: #340815;
}

.search-results:not(:empty) {
  max-height: min(62vh, 520px);
  margin-top: var(--space-3);
  padding: var(--space-3) var(--space-4);
  overflow-y: auto;
  border: 1px solid rgba(78,15,34,0.12);
  border-radius: 24px;
  background: #fffdf1;
  box-shadow: 0 14px 34px rgba(52,8,21,0.2);
}

@media (max-width: 600px) {
  .search-overlay {
    padding: 16px 12px;
  }

  .search-input-wrap {
    min-height: 52px;
    padding-left: 14px;
  }

  .search-input-wrap .search-close-btn {
    width: 38px;
    height: 38px;
  }
}

.search-suggestions {
  margin-top: var(--space-8);
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: var(--space-8);
}

/* ─── WHATSAPP FLOAT ─── */
.whatsapp-float {
  position: fixed;
  bottom: calc(var(--space-6) + 60px);
  right: var(--space-6);
  z-index: var(--z-toast);
  width: 48px;
  height: 48px;
  border-radius: var(--radius-full);
  background: #25D366;
  color: white;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 4px 16px rgba(37,211,102,0.35);
  transition: transform var(--duration-fast) var(--ease-spring),
              box-shadow var(--duration-fast);
  cursor: pointer;
}

.whatsapp-float:hover {
  transform: scale(1.1);
  box-shadow: 0 6px 20px rgba(37,211,102,0.45);
}

@media (min-width: 769px) {
  .whatsapp-float {
    bottom: var(--space-8);
    right: var(--space-8);
    width: 52px;
    height: 52px;
  }
}

/* ─── PROGRESS BAR (QUIZ) ─── */
.progress-bar {
  height: 3px;
  background: var(--color-border-light);
  border-radius: var(--radius-full);
  overflow: hidden;
}

.progress-bar__fill {
  height: 100%;
  background: var(--color-primary);
  border-radius: var(--radius-full);
  transition: width var(--duration-slow) var(--ease-elegant);
}

/* ─── RESPONSIVE HEADER ─── */
@media (max-width: 1024px) {
  .header__nav { display: none; }
  .header { height: var(--header-height-mobile); }
}

@media (min-width: 1025px) {
  .btn-icon.menu-toggle { display: none; }
}

/* ── Guest order lookup ─────────────────────────────────────────────── */
.guest-lookup { display: grid; gap: var(--space-8); max-width: 44rem; margin: 0 auto var(--space-12); }
.guest-lookup__card { padding: var(--space-8); border: 1px solid var(--color-border-light); border-radius: var(--radius-lg); background: var(--color-surface); }
.guest-lookup__eyebrow { color: var(--color-primary); font-size: var(--text-xs); font-weight: 700; letter-spacing: .08em; text-transform: uppercase; margin-bottom: var(--space-2); }
.guest-lookup__card h1 { color: var(--color-wine-deep); margin-bottom: var(--space-3); }
.guest-lookup__copy { color: var(--color-text-secondary); line-height: 1.6; margin-bottom: var(--space-6); }
.guest-lookup__form { display: grid; gap: var(--space-4); }
.guest-lookup__recent { margin-bottom: var(--space-6); }
.guest-lookup__recent-label { color: var(--color-text-tertiary); font-size: var(--text-xs); font-weight: 700; letter-spacing: .06em; text-transform: uppercase; margin-bottom: var(--space-2); }
.guest-lookup__recent-list { list-style: none; margin: 0; padding: 0; display: grid; gap: var(--space-2); }
.guest-lookup__recent-item { display: flex; justify-content: space-between; align-items: baseline; gap: var(--space-3); width: 100%; text-align: left; padding: var(--space-3) var(--space-4); border: 1px solid var(--color-border-light); border-radius: var(--radius-md); background: var(--color-surface); color: var(--color-wine-deep); font-family: inherit; font-size: var(--text-sm); font-weight: 600; cursor: pointer; transition: border-color .2s ease, background .2s ease; }
.guest-lookup__recent-item:hover { border-color: var(--color-primary); background: var(--color-surface-alt, var(--color-surface)); }
.guest-lookup__recent-item span { color: var(--color-text-tertiary); font-weight: 400; font-size: var(--text-xs); }
.guest-lookup__alt { margin-top: var(--space-5); color: var(--color-text-tertiary); font-size: var(--text-sm); }
.guest-lookup__result:empty { display: none; }
.guest-lookup__detail { margin-top: var(--space-6); padding: var(--space-6); border: 1px solid var(--color-border-light); border-radius: var(--radius-lg); background: var(--color-surface); }
.guest-lookup__detail h2 { color: var(--color-wine-deep); font-size: var(--text-base); margin: var(--space-5) 0 var(--space-3); }
.guest-lookup__detail h2:first-child { margin-top: 0; }
.guest-lookup__timeline { list-style: none; margin: 0; padding: 0; display: grid; gap: var(--space-3); }
.guest-lookup__timeline li { padding-left: var(--space-5); border-left: 2px solid var(--color-border-light); }
.guest-lookup__timeline strong { display: block; color: var(--color-wine-deep); font-size: var(--text-sm); }
.guest-lookup__timeline span { color: var(--color-text-tertiary); font-size: var(--text-xs); }
.guest-lookup__timeline p { color: var(--color-text-secondary); font-size: var(--text-sm); margin-top: var(--space-1); }
.guest-lookup__shipment, .guest-lookup__address { color: var(--color-text-secondary); font-size: var(--text-sm); line-height: 1.6; }
.guest-lookup__note { margin-top: var(--space-5); padding-top: var(--space-4); border-top: 1px solid var(--color-border-light); color: var(--color-text-tertiary); font-size: var(--text-sm); }
@media (max-width: 640px) { .guest-lookup__card, .guest-lookup__detail { padding: var(--space-5); } }

/* ── MODAL DIALOG LAYOUT ── */
/*
 * Pins the heading and the actions, and scrolls only the fields between them.
 *
 * Capping the dialog's height and letting the whole element scroll moved the
 * title out of view and pushed Save and Cancel below the fold on a short
 * window - the address form is ten fields. A dialog whose primary action can
 * scroll away is worse than one that overflows, because nothing signals the
 * button is still there.
 *
 * Written against `dialog:modal > form`, which both dialogs use, so the two
 * cannot drift apart. The higher specificity is deliberate: the per-page rules
 * that set padding on the body load after components.css.
 */
dialog:modal {
  display: flex;
  flex-direction: column;
  /* The form owns the scrolling now, so the dialog itself must not. */
  overflow: hidden;
}

dialog:modal > form {
  display: flex;
  flex-direction: column;
  /* Without this a flex child refuses to shrink below its content height and
     the inner scroll region never engages. */
  min-height: 0;
  max-height: 100%;
  /* Padding moves onto the sections so the scroll boundary sits flush against
     the pinned header and footer rather than inside a padded box. */
  padding: 0;
}

dialog:modal > form > .order-request-dialog__head {
  flex: 0 0 auto;
  padding: var(--space-7) var(--space-7) var(--space-4);
  margin-bottom: 0;
}

/* The scrolling region: everything between the heading and the actions. */
dialog:modal > form > .address-dialog__fields,
dialog:modal > form > .order-request-dialog__fields,
dialog:modal > form > .order-request-dialog__content {
  flex: 1 1 auto;
  min-height: 0;
  overflow-y: auto;
  overscroll-behavior: contain;
  padding: var(--space-1) var(--space-7) var(--space-5);
}

dialog:modal > form > .address-dialog__feedback,
dialog:modal > form > .order-request-dialog__feedback {
  flex: 0 0 auto;
  padding: 0 var(--space-7);
}

dialog:modal > form > .order-request-dialog__actions {
  flex: 0 0 auto;
  padding: var(--space-4) var(--space-7) var(--space-6);
  margin-top: 0;
  /* Separates the pinned actions from content scrolling beneath them. */
  border-top: 1px solid var(--color-border-light);
  background: inherit;
}

/* Anything else in the form keeps the horizontal rhythm of the padded sections. */
dialog:modal > form > *:not(.order-request-dialog__head):not(.order-request-dialog__actions):not([class*="__fields"]):not([class*="__content"]):not([class*="__feedback"]) {
  padding-left: var(--space-7);
  padding-right: var(--space-7);
}
