:root {
  --primary: #E5312A;
  --primary-light: #FF6A52;
  --primary-dark: #8F1B1B;
  --primary-tint: #FDEAE6;
  --secondary: #2B1416;
  --accent: #FF7A1A;
  --bg-grey: #FFF6F2;
  --text-primary: #2B1416;
  --text-secondary: #8C6E68;
  --text-tertiary: #B99590;
  --success: #1E9E6B;
  --success-tint: #E4F6EE;
  --error: #C4234A;
  --error-tint: #FBE7EC;
  --border: #F3DCD4;
  --radius-sm: 8px;
  --radius-md: 12px;
  --radius-lg: 18px;
  --radius-xl: 22px;
  --shadow-sm: 0 1px 2px rgba(43, 20, 22, 0.05);
  --shadow-md: 0 8px 24px rgba(43, 20, 22, 0.08);
  --shadow-lg: 0 16px 40px rgba(43, 20, 22, 0.12);
}

* { box-sizing: border-box; }

html { -webkit-font-smoothing: antialiased; -moz-osx-font-smoothing: grayscale; }

body {
  margin: 0;
  font-family: 'Plus Jakarta Sans', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  background: var(--bg-grey);
  color: var(--text-primary);
  font-size: 15px;
  line-height: 1.5;
}

a { color: inherit; text-decoration: none; }
h1, h2, h3 { letter-spacing: -0.01em; font-weight: 700; margin: 0; }
.display-face { font-family: 'Archivo Black', 'Plus Jakarta Sans', sans-serif; letter-spacing: -0.01em; }
.num { font-family: 'IBM Plex Mono', ui-monospace, monospace; font-variant-numeric: tabular-nums; }
button, input, textarea, select { font-family: inherit; }

.container {
  max-width: 1120px;
  margin: 0 auto;
  padding: 0 24px;
}

/* ---------- Header ---------- */
.site-header {
  background: linear-gradient(180deg, var(--primary) 0%, var(--primary-dark) 100%);
  position: sticky;
  top: 0;
  z-index: 20;
  box-shadow: 0 2px 14px rgba(43, 20, 22, 0.18);
}
.site-header .bar {
  display: flex;
  align-items: center;
  gap: 18px;
  padding: 14px 0;
}
.brand {
  display: flex;
  align-items: center;
  gap: 11px;
  font-family: 'Archivo Black', 'Plus Jakarta Sans', sans-serif;
  font-size: 17px;
  color: #fff;
  min-width: 0;
  flex-shrink: 0;
  letter-spacing: -0.01em;
}
.brand-icon {
  width: 36px;
  height: 36px;
  border-radius: 10px;
  background: #fff;
  color: var(--primary);
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: 'Archivo Black', 'Plus Jakarta Sans', sans-serif;
  font-size: 15px;
  flex-shrink: 0;
}
.brand span:last-child {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.header-actions { display: flex; align-items: center; gap: 10px; flex-shrink: 0; }

/* ---------- Header search ---------- */
.header-search {
  position: relative;
  flex: 1;
  min-width: 0;
  display: flex;
  align-items: center;
  background: #fff;
  border-radius: 999px;
  height: 42px;
  box-shadow: 0 4px 14px rgba(43, 20, 22, 0.22);
}
.header-search .search-icon { position: absolute; left: 15px; color: var(--text-tertiary); pointer-events: none; }
.header-search input {
  flex: 1;
  min-width: 0;
  border: none;
  outline: none;
  background: none;
  padding: 0 16px 0 40px;
  height: 100%;
  border-radius: inherit;
  font-family: inherit;
  font-size: 14px;
  color: var(--text-primary);
}
.header-search input::placeholder { color: var(--text-tertiary); }
.header-search .search-suggestions {
  top: calc(100% + 10px);
  border-radius: var(--radius-md);
}

.btn-signin {
  display: flex;
  align-items: center;
  gap: 8px;
  border: none;
  background: #fff;
  color: var(--primary-dark);
  padding: 9px 16px;
  border-radius: 999px;
  font-weight: 700;
  font-size: 13px;
  cursor: pointer;
  transition: transform 0.12s ease;
}
.btn-signin:hover { transform: translateY(-1px); }
.btn-signin:disabled { opacity: 0.6; cursor: not-allowed; }

.auth-user { position: relative; }
.auth-user-trigger {
  display: flex;
  align-items: center;
  gap: 8px;
  background: var(--primary-tint);
  border: none;
  padding: 6px 12px 6px 6px;
  border-radius: 999px;
  cursor: pointer;
  font-weight: 600;
  font-size: 13px;
  color: var(--text-primary);
}
.auth-user-trigger svg { color: var(--text-tertiary); flex-shrink: 0; }
.auth-avatar {
  width: 26px;
  height: 26px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--primary-light), var(--primary-dark));
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 11.5px;
  font-weight: 700;
  flex-shrink: 0;
}
.auth-dropdown {
  position: absolute;
  top: calc(100% + 8px);
  right: 0;
  background: #fff;
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-md);
  min-width: 160px;
  padding: 6px;
  z-index: 30;
  display: none;
  flex-direction: column;
}
.auth-dropdown.open { display: flex; }
.auth-dropdown a, .auth-dropdown button {
  display: block;
  width: 100%;
  text-align: left;
  padding: 9px 11px;
  border-radius: var(--radius-sm);
  border: none;
  background: none;
  font-size: 13.5px;
  font-weight: 500;
  color: var(--text-primary);
  cursor: pointer;
}
.auth-dropdown a:hover, .auth-dropdown button:hover { background: var(--bg-grey); }

.cart-link {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  color: #fff;
  position: relative;
  border-radius: 999px;
  transition: color 0.12s ease, background 0.12s ease;
}
.cart-link:hover { background: rgba(255, 255, 255, 0.16); }
.cart-badge {
  background: var(--accent);
  color: #fff;
  border-radius: 999px;
  font-size: 11px;
  font-weight: 700;
  min-width: 19px;
  height: 19px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0 5px;
  position: absolute;
  top: -6px;
  right: -6px;
  border: 2px solid #fff;
}

/* ---------- Navbar (second header row) ---------- */
.navbar-inline {
  display: flex;
  align-items: center;
  gap: 4px;
  border-top: 1px solid rgba(255, 255, 255, 0.16);
  padding: 9px 0 10px;
  overflow-x: auto;
  scrollbar-width: none;
}
.navbar-inline::-webkit-scrollbar { display: none; }
.nav-link {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 7px 12px;
  border-radius: 999px;
  font-size: 12.5px;
  font-weight: 600;
  color: rgba(255, 255, 255, 0.78);
  white-space: nowrap;
  flex-shrink: 0;
  transition: color 0.12s ease, background 0.12s ease;
}
.nav-link svg { flex-shrink: 0; opacity: 0.9; }
.nav-link:hover { color: #fff; background: rgba(255, 255, 255, 0.12); }
.nav-link.active { color: var(--primary-dark); background: #fff; }

@media (max-width: 760px) {
  .navbar-inline .nav-link-label { display: none; }
  .navbar-inline .nav-link { padding: 8px; }
  .navbar-inline { gap: 0; }
  .btn-signin-label { display: none; }
  .btn-signin { padding: 9px; }
}

/* ---------- Banner pill (hero meta) ---------- */
.banner-pill {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: rgba(255, 255, 255, 0.14);
  border: 1px solid rgba(255, 255, 255, 0.22);
  padding: 6px 13px;
  border-radius: 999px;
  font-size: 12.5px;
  font-weight: 500;
  backdrop-filter: blur(4px);
}
.banner-pill svg { flex-shrink: 0; opacity: 0.9; }

/* ---------- Promo ticker ---------- */
.promo-ticker {
  background: var(--primary-dark);
  color: #fff;
  overflow: hidden;
  white-space: nowrap;
}
.promo-ticker-track {
  display: inline-flex;
  gap: 40px;
  padding: 8px 0;
  animation: ticker-scroll 22s linear infinite;
  will-change: transform;
}
.promo-ticker-track span {
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.01em;
  opacity: 0.92;
  white-space: nowrap;
}
@keyframes ticker-scroll {
  from { transform: translateX(0); }
  to { transform: translateX(-50%); }
}
@media (prefers-reduced-motion: reduce) {
  .promo-ticker-track { animation: none; }
}

/* ---------- Hero ---------- */
.hero-section { padding-block: 18px 8px; }
.hero-grid {
  display: grid;
  grid-template-columns: 1.5fr 1fr;
  gap: 14px;
}
.hero-main {
  background: linear-gradient(135deg, var(--primary-dark), var(--primary) 70%);
  background-size: cover;
  background-position: center;
  border-radius: 16px;
  padding: 34px 30px;
  color: #fff;
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 12px;
  min-height: 260px;
  position: relative;
  overflow: hidden;
}
.hero-main::after {
  content: "";
  position: absolute; inset: -40% -10% auto auto; width: 260px; height: 260px;
  background: radial-gradient(circle, rgba(255, 255, 255, 0.16), transparent 70%);
  pointer-events: none;
}
.hero-main.has-image::before {
  content: "";
  position: absolute;
  inset: 0;
  /* Fixed px stops (not %) so the dark zone always covers the text column
     (h1/p max out around 460px in) regardless of the box's own width — a
     bright/light shop photo can never wash out the text. Only past that
     column does it fade out, to let the photo show through on the right. */
  background: linear-gradient(90deg, rgba(20, 6, 6, 0.85) 0px, rgba(20, 6, 6, 0.68) 480px, rgba(20, 6, 6, 0.15) 720px);
}
.hero-main > * { position: relative; z-index: 1; }
.hero-main.has-image h1,
.hero-main.has-image p,
.hero-main.has-image .hero-eyebrow,
.hero-main.has-image .banner-pill {
  text-shadow: 0 1px 4px rgba(0, 0, 0, 0.45);
}
.hero-eyebrow {
  display: inline-flex; align-items: center; gap: 6px; width: fit-content;
  background: rgba(255, 255, 255, 0.16); border: 1px solid rgba(255, 255, 255, 0.3);
  padding: 5px 12px; border-radius: 999px; font-size: 11.5px; font-weight: 700;
  backdrop-filter: blur(4px);
}
.hero-main h1 { font-family: 'Archivo Black', 'Plus Jakarta Sans', sans-serif; font-size: 32px; line-height: 1.08; max-width: 460px; }
.hero-main p {
  margin: 0;
  opacity: 0.9;
  font-size: 14px;
  max-width: 420px;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
.hero-meta { display: flex; gap: 10px; flex-wrap: wrap; }
.hero-cta {
  width: fit-content; background: #fff; color: var(--primary-dark);
  font-weight: 800; font-size: 13.5px; padding: 11px 22px; border-radius: 999px;
  margin-top: 4px; transition: transform 0.12s ease;
}
.hero-cta:hover { transform: translateY(-1px); }
.hero-side { display: grid; grid-template-rows: 1fr 1fr; gap: 14px; }
.hero-tile {
  border-radius: 16px; padding: 20px; color: #fff; display: flex; flex-direction: column;
  justify-content: space-between; min-height: 118px; transition: transform 0.12s ease;
}
.hero-tile:hover { transform: translateY(-2px); }
.hero-tile.gold { background: linear-gradient(135deg, #F0A93A, #C97A12); }
.hero-tile.ink { background: linear-gradient(135deg, #5C2320, var(--secondary)); }
.hero-tile-label { font-size: 11px; font-weight: 800; text-transform: uppercase; letter-spacing: 0.06em; opacity: 0.85; }
.hero-tile-title { font-family: 'Archivo Black', 'Plus Jakarta Sans', sans-serif; font-size: 19px; }

@media (max-width: 760px) {
  .hero-grid { grid-template-columns: 1fr; }
  .hero-main h1 { font-size: 26px; }
}

/* ---------- Section headers (landing page previews) ---------- */
.section-header {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 12px;
  margin: 28px 0 14px;
}
.section-title {
  font-family: 'Archivo Black', 'Plus Jakarta Sans', sans-serif;
  font-size: 18px;
  letter-spacing: -0.01em;
  color: var(--text-primary);
  margin: 0;
}
.view-all-link {
  font-size: 12.5px;
  font-weight: 700;
  color: var(--primary);
  white-space: nowrap;
  flex-shrink: 0;
}
.view-all-link:hover { color: var(--primary-dark); }

/* ---------- About card ---------- */
.about-card {
  background: #fff;
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 22px 24px;
  margin: 28px 0;
}
.about-card .section-title { margin-bottom: 10px; }
.about-card p {
  margin: 0;
  color: var(--text-secondary);
  font-size: 14px;
  line-height: 1.7;
  max-width: 720px;
}

/* ---------- Category grid ---------- */
.category-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
  gap: 14px;
  padding-bottom: 8px;
}
.category-card {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  gap: 6px;
  padding: 20px 12px;
  background: #fff;
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  transition: all 0.12s ease;
}
.category-card:hover { border-color: var(--primary); box-shadow: var(--shadow-md); transform: translateY(-2px); }
.category-card-icon {
  width: 44px;
  height: 44px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 12px;
  background: var(--primary-tint);
  color: var(--primary);
  font-weight: 800;
  font-size: 17px;
}
.category-card-name { font-weight: 700; font-size: 13.5px; color: var(--text-primary); }
.category-card-count { font-size: 12px; color: var(--text-tertiary); }

/* ---------- Category rail (homepage) ---------- */
.cat-rail {
  display: flex;
  gap: 12px;
  overflow-x: auto;
  padding-bottom: 6px;
  scrollbar-width: none;
}
.cat-rail::-webkit-scrollbar { display: none; }
.cat-pill {
  flex: 0 0 auto;
  width: 92px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  text-align: center;
}
.cat-pill-icon {
  width: 62px;
  height: 62px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: 'Archivo Black', 'Plus Jakarta Sans', sans-serif;
  font-size: 20px;
  color: #fff;
  box-shadow: 0 6px 16px rgba(43, 20, 22, 0.16);
  transition: transform 0.15s ease;
}
.cat-pill:hover .cat-pill-icon { transform: translateY(-3px); }
.cat-pill-name {
  font-weight: 700;
  font-size: 12px;
  color: var(--text-primary);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  max-width: 100%;
}
.cat-pill-count { font-size: 10.5px; color: var(--text-tertiary); font-weight: 600; }

/* Cosmetic accent palette the homepage cycles category icons through. */
.accent-0 { background: linear-gradient(135deg, var(--primary), var(--primary-dark)); }
.accent-1 { background: linear-gradient(135deg, var(--accent), #C9560A); }
.accent-2 { background: linear-gradient(135deg, #F0A93A, #B9791E); }
.accent-3 { background: linear-gradient(135deg, #C24B4B, #7A1F1F); }
.accent-4 { background: linear-gradient(135deg, var(--primary-light), var(--primary)); }
.accent-5 { background: linear-gradient(135deg, #6B2A28, var(--secondary)); }

/* ---------- Flash sale banner ---------- */
.flash-sale-banner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
  margin: 28px 0;
  padding: 16px 20px;
  background: linear-gradient(135deg, var(--accent), #E8890F);
  color: #fff;
  border-radius: var(--radius-lg);
  font-weight: 700;
  font-size: 14px;
  box-shadow: 0 8px 20px rgba(255, 159, 67, 0.28);
  transition: transform 0.12s ease;
}
.flash-sale-banner:hover { transform: translateY(-1px); }
.flash-sale-cta {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  font-size: 13px;
  white-space: nowrap;
}

/* ---------- Flash deals band (homepage strip) ---------- */
.flash-band {
  margin: 28px 0;
  padding: 18px 18px 6px;
  background: linear-gradient(180deg, #FFE9E2, var(--bg-grey) 75%);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
}
.flash-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
  margin-bottom: 14px;
}
.flash-title {
  display: flex;
  align-items: center;
  gap: 10px;
}
.flash-title h2 { color: #C4341C; }
.flash-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 34px;
  height: 34px;
  border-radius: 50%;
  background: var(--primary);
  color: #fff;
  font-size: 16px;
  animation: flash-pulse 1.8s ease-in-out infinite;
}
@keyframes flash-pulse {
  0%, 100% { box-shadow: 0 0 0 0 rgba(229, 49, 42, 0.38); }
  50% { box-shadow: 0 0 0 9px rgba(229, 49, 42, 0); }
}
@media (prefers-reduced-motion: reduce) {
  .flash-badge { animation: none; }
}

.scroll-strip {
  display: flex;
  gap: 14px;
  overflow-x: auto;
  padding-bottom: 16px;
  scroll-snap-type: x proximity;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: none;
  cursor: grab;
}
.scroll-strip:active { cursor: grabbing; }
.scroll-strip::-webkit-scrollbar { display: none; }
.scroll-strip-item {
  flex: 0 0 190px;
  scroll-snap-align: start;
}
.scroll-strip-item .product-card { height: 100%; }
@media (max-width: 480px) {
  .scroll-strip-item { flex-basis: 156px; }
}

/* ---------- Scroll-reveal ---------- */
.reveal { opacity: 0; transform: translateY(18px); transition: opacity 0.5s ease, transform 0.5s ease; }
.reveal-visible { opacity: 1; transform: none; }
@media (prefers-reduced-motion: reduce) {
  .reveal { opacity: 1; transform: none; transition: none; }
}

/* ---------- Product grid ---------- */
.product-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(210px, 1fr));
  gap: 18px;
}
@media (max-width: 480px) {
  /* Below this width, 210px minmax collapses to a single column — force a
     2-up grid instead so mobile still reads as a grid, not a stacked list. */
  .product-grid { grid-template-columns: repeat(2, 1fr); gap: 12px; }
}
.product-card {
  background: #fff;
  border-radius: 12px;
  border: 1px solid var(--border);
  overflow: hidden;
  display: flex;
  flex-direction: column;
  transition: box-shadow 0.18s ease, transform 0.18s ease;
}
.product-card:hover { box-shadow: var(--shadow-md); transform: translateY(-2px); }
.product-card .thumb {
  position: relative;
  width: 100%;
  aspect-ratio: 1 / 1;
  background: radial-gradient(circle at 50% 40%, #FFFFFF 0%, var(--primary-tint) 55%, #F3CBBD 100%);
  display: flex;
  align-items: center;
  justify-content: center;
  color: #A6503C;
  overflow: hidden;
}
.product-card .thumb img { width: 100%; height: 100%; object-fit: cover; transition: transform 0.35s ease; }
.product-card:hover .thumb img { transform: scale(1.08); }
.product-card .thumb svg {
  width: 42%;
  height: 42%;
  filter: drop-shadow(0 6px 10px rgba(43, 20, 22, 0.16));
}
.product-card .info { padding: 11px 12px 13px; display: flex; flex-direction: column; gap: 4px; flex: 1; }
.product-card .name {
  font-weight: 600;
  font-size: 12.5px;
  line-height: 1.35;
  color: var(--text-primary);
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  min-height: 32px;
}
.product-card .price,
.price-strike,
.product-detail .price-large,
.cart-item-row .item-subtotal,
.summary-card .row.total span:last-child,
.search-suggestion-price {
  font-family: 'IBM Plex Mono', ui-monospace, monospace;
  font-variant-numeric: tabular-nums;
}
.product-card .price { color: var(--primary); font-weight: 800; font-size: 16px; margin-top: 3px; letter-spacing: -0.01em; }
.price-strike {
  color: var(--text-tertiary);
  font-weight: 500;
  font-size: 12.5px;
  text-decoration: line-through;
  margin-right: 5px;
}
.badge-off {
  position: absolute;
  top: 8px;
  right: 8px;
  display: inline-block;
  background: linear-gradient(135deg, #E6302A, var(--accent));
  color: #fff;
  padding: 3px 8px;
  border-radius: 999px;
  font-size: 10.5px;
  font-weight: 700;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.18);
}
.badge-new {
  position: absolute;
  top: 8px;
  right: 8px;
  display: inline-block;
  background: var(--secondary);
  color: #fff;
  padding: 3px 9px;
  border-radius: 999px;
  font-size: 10.5px;
  font-weight: 700;
  letter-spacing: 0.03em;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.18);
}
.product-card .stock { font-size: 12px; color: var(--text-tertiary); }
.product-card .stock.out { color: var(--error); font-weight: 600; }
.product-card .stock.low { color: #C4341C; font-weight: 700; }
.product-card .add-btn {
  margin-top: 10px;
  border: none;
  background: var(--primary-tint);
  color: var(--primary);
  padding: 10px;
  border-radius: var(--radius-sm);
  font-weight: 700;
  font-size: 13px;
  cursor: pointer;
  transition: background 0.12s ease;
}
.product-card .add-btn:hover:not(:disabled) { background: var(--primary); color: #fff; }
.product-card .add-btn:disabled { background: var(--bg-grey); color: var(--text-tertiary); cursor: not-allowed; }

/* ---------- Trust strip ---------- */
.trust-strip { display: flex; gap: 10px; flex-wrap: wrap; margin: 4px 0 40px; }
.trust-chip {
  display: inline-flex; align-items: center; gap: 6px; background: var(--success-tint); color: var(--success);
  font-size: 11.5px; font-weight: 700; padding: 6px 12px; border-radius: 999px;
}

.empty-state {
  text-align: center;
  padding: 70px 20px;
  color: var(--text-secondary);
  background: #fff;
  border-radius: var(--radius-lg);
  border: 1px dashed var(--border);
  margin-bottom: 40px;
}
.empty-state .icon { font-size: 40px; margin-bottom: 12px; opacity: 0.5; }
.empty-state p { font-size: 14.5px; margin: 0 0 16px; }

/* ---------- Product detail ---------- */
.product-detail {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 40px;
  padding: 28px 0 64px;
}
@media (max-width: 720px) {
  .product-detail { grid-template-columns: 1fr; gap: 24px; }
}
.product-detail .thumb-large {
  position: relative;
  width: 100%;
  aspect-ratio: 1 / 1;
  background: #fff;
  border: 1px solid var(--border);
  border-radius: var(--radius-xl);
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  color: var(--text-tertiary);
}
.product-detail .thumb-large img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: opacity 0.15s ease;
}
.product-detail .thumb-large img.swapping { opacity: 0; }

/* Single-row, horizontally-scrolling strip — never wraps to a second row
   (which reads as cluttered on narrow screens), snaps neatly on touch, and
   hides its scrollbar without losing scrollability. */
.thumb-strip {
  display: flex;
  gap: 10px;
  margin-top: 12px;
  overflow-x: auto;
  scroll-snap-type: x proximity;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: none;
  padding-bottom: 2px;
}
.thumb-strip::-webkit-scrollbar { display: none; }
.thumb-strip-item {
  flex: 0 0 auto;
  width: 68px;
  height: 68px;
  padding: 0;
  border: none;
  border-radius: var(--radius-md);
  overflow: hidden;
  cursor: pointer;
  background: #fff;
  scroll-snap-align: start;
  position: relative;
  opacity: 0.6;
  transition: opacity 0.15s ease, box-shadow 0.15s ease, transform 0.15s ease;
  box-shadow: 0 0 0 1px var(--border) inset;
}
.thumb-strip-item img { width: 100%; height: 100%; object-fit: cover; display: block; }
.thumb-strip-item:hover { opacity: 0.85; }
.thumb-strip-item.active {
  opacity: 1;
  box-shadow: 0 0 0 2px var(--primary) inset;
}
@media (max-width: 480px) {
  .thumb-strip-item { width: 58px; height: 58px; }
}
.product-detail .category-tag {
  display: inline-block;
  font-size: 12px;
  font-weight: 700;
  color: var(--primary);
  background: var(--primary-tint);
  padding: 5px 12px;
  border-radius: 999px;
  margin-bottom: 12px;
}
.product-detail h1 { font-size: 25px; margin-bottom: 10px; }
.product-detail .price-large { color: var(--primary); font-weight: 800; font-size: 28px; margin: 4px 0 14px; letter-spacing: -0.02em; }
.product-detail .description { font-size: 14px; color: var(--text-secondary); line-height: 1.6; margin: 0 0 16px; }
.product-detail .stock { font-size: 13.5px; color: var(--text-secondary); margin: 0 0 4px; }
.product-detail .stock.out { color: var(--error); font-weight: 600; }

.field-error { color: var(--error); font-size: 12.5px; margin: 6px 0 0; font-weight: 500; }

.booking-calendar { width: 100%; }
.cal-header { display: flex; align-items: center; justify-content: space-between; margin-bottom: 14px; }
.cal-title { font-size: 14.5px; font-weight: 700; color: var(--text-primary); }
.cal-nav {
  width: 32px; height: 32px; border: 1px solid var(--border); background: #fff; border-radius: 8px;
  font-size: 16px; line-height: 1; cursor: pointer; color: var(--text-secondary);
}
.cal-nav:hover:not(:disabled) { border-color: var(--primary); color: var(--primary); }
.cal-nav:disabled { opacity: 0.35; cursor: default; }
.cal-weekdays, .cal-grid { display: grid; grid-template-columns: repeat(7, 1fr); gap: 4px; }
.cal-weekdays span { text-align: center; font-size: 11px; font-weight: 700; color: var(--text-tertiary); padding: 4px 0 8px; }
.cal-cell {
  aspect-ratio: 1; border: 1.5px solid transparent; background: var(--bg-grey); border-radius: 8px; font-size: 13.5px;
  color: var(--text-primary); cursor: pointer; font-weight: 600; transition: background 0.12s ease, border-color 0.12s ease;
}
.cal-cell:hover:not(.cal-cell-disabled) { background: var(--primary-tint); border-color: var(--primary-light); }
.cal-cell-empty { background: transparent; cursor: default; }
.cal-cell-today { background: #fff; border-color: var(--primary); color: var(--primary); font-weight: 700; }
.cal-cell-selected { background: var(--primary) !important; border-color: var(--primary) !important; color: #fff; font-weight: 700; }
.cal-cell-disabled { cursor: not-allowed; }
.cal-cell-past { background: transparent; color: var(--text-tertiary); opacity: 0.4; }
.cal-cell-blocked { background: var(--error-tint); border-color: var(--error-tint); color: var(--error); text-decoration: line-through; text-decoration-thickness: 1.5px; }
.cal-cell-closed { background: #fff; border: 1.5px dashed var(--border); color: var(--text-tertiary); }
.cal-note {
  margin: 12px 0 0; padding: 9px 11px; background: var(--error-tint); color: var(--error);
  font-size: 12.5px; font-weight: 600; border-radius: 8px; line-height: 1.4;
}
.cal-legend { display: flex; gap: 16px; margin-top: 14px; padding-top: 12px; border-top: 1px solid var(--border); }
.cal-legend span { display: flex; align-items: center; gap: 6px; font-size: 11.5px; color: var(--text-tertiary); }
.cal-dot { width: 9px; height: 9px; border-radius: 50%; display: inline-block; }
.cal-dot-blocked { background: var(--error); }
.cal-dot-closed { background: var(--text-tertiary); }

.qty-row { display: flex; align-items: center; gap: 14px; margin: 22px 0; }
.stepper { display: flex; align-items: center; background: #fff; border: 1px solid var(--border); border-radius: var(--radius-md); overflow: hidden; }
.stepper button {
  width: 42px; height: 42px; border: none; background: transparent; font-size: 18px; cursor: pointer;
  color: var(--primary); font-weight: 600; transition: background 0.12s ease;
}
.stepper button:hover { background: var(--primary-tint); }
.stepper input {
  width: 56px; text-align: center; border: none; border-left: 1px solid var(--border); border-right: 1px solid var(--border);
  padding: 10px 4px; font-size: 15px; font-weight: 600; color: var(--text-primary);
}
.qty-row .unit-label { font-size: 13px; color: var(--text-secondary); font-weight: 500; }

.action-row { display: flex; gap: 10px; margin-top: 8px; flex-wrap: wrap; }
.btn-primary {
  border: none; background: var(--primary); color: #fff; padding: 14px 26px;
  border-radius: var(--radius-md); font-weight: 700; font-size: 14.5px; cursor: pointer;
  box-shadow: 0 4px 14px rgba(229, 49, 42, 0.28); transition: transform 0.12s ease, box-shadow 0.12s ease;
}
.btn-primary:hover:not(:disabled) { transform: translateY(-1px); box-shadow: 0 6px 18px rgba(229, 49, 42, 0.34); }
.btn-primary:disabled { background: var(--text-tertiary); box-shadow: none; cursor: not-allowed; }
.btn-outline {
  border: 1.5px solid var(--border); background: #fff; color: var(--text-primary);
  padding: 14px 26px; border-radius: var(--radius-md); font-weight: 700; font-size: 14.5px; cursor: pointer;
  transition: border-color 0.12s ease, color 0.12s ease;
}
.btn-outline:hover { border-color: var(--primary); color: var(--primary); }

/* ---------- Cart ---------- */
.cart-layout { display: grid; grid-template-columns: 1fr 340px; gap: 24px; align-items: start; padding-bottom: 60px; }
@media (max-width: 800px) { .cart-layout { grid-template-columns: 1fr; } }

.item-thumb {
  width: 28px; height: 28px; border-radius: 6px; background: var(--bg-grey);
  border: 1px solid var(--border); display: flex; align-items: center; justify-content: center;
  color: var(--text-tertiary); overflow: hidden; flex-shrink: 0;
}
.item-thumb img { width: 100%; height: 100%; object-fit: cover; }

.cart-item-row {
  display: flex; align-items: center; gap: 14px; background: #fff; border: 1px solid var(--border);
  border-radius: var(--radius-md); padding: 14px 16px; margin-bottom: 10px;
}
.cart-item-row .item-thumb { width: 48px; height: 48px; border-radius: var(--radius-sm); }
.cart-item-row .item-name { font-weight: 600; font-size: 14px; }
.cart-item-row .item-price { font-size: 12.5px; color: var(--text-secondary); margin-top: 2px; }
.cart-item-row .item-booking-date { font-size: 12px; color: var(--primary); font-weight: 600; margin-top: 4px; display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.edit-date-link {
  background: none; border: none; padding: 0; margin: 0; color: var(--primary); font-weight: 700;
  font-size: 11.5px; text-decoration: underline; cursor: pointer;
}
.edit-date-link:hover { color: var(--primary-dark); }
.cart-item-row .item-main { flex: 1; min-width: 0; }
.cart-item-row .item-subtotal { font-weight: 700; color: var(--primary); font-size: 14.5px; min-width: 90px; text-align: right; }
.cart-item-row .stepper { flex-shrink: 0; }
.cart-item-row .stepper button { width: 32px; height: 32px; font-size: 15px; }
.cart-item-row .stepper input { width: 44px; padding: 6px 2px; font-size: 13.5px; }
.remove-link {
  color: var(--text-tertiary); background: none; border: none; cursor: pointer; font-size: 12px;
  display: flex; align-items: center; justify-content: center; width: 30px; height: 30px; border-radius: 8px;
  transition: color 0.12s ease, background 0.12s ease;
}
.remove-link:hover { color: var(--error); background: var(--error-tint); }

.summary-card {
  background: #fff; border: 1px solid var(--border); border-radius: var(--radius-lg); padding: 22px; position: sticky; top: 90px;
}
.summary-card h3 { font-size: 15px; margin-bottom: 16px; }
.summary-card .row { display: flex; justify-content: space-between; margin-bottom: 10px; font-size: 13.5px; color: var(--text-secondary); }
.summary-card .row.summary-item { align-items: flex-start; }
.summary-item-label { display: flex; align-items: flex-start; gap: 8px; min-width: 0; }
.summary-item-text { min-width: 0; }
.summary-date-note {
  font-size: 12px; color: var(--primary); font-weight: 600; margin-top: 3px;
  display: flex; align-items: center; gap: 8px; flex-wrap: wrap;
}
.summary-card .row.total { border-top: 1px solid var(--border); padding-top: 14px; margin-top: 6px; font-weight: 800; font-size: 17px; color: var(--text-primary); }
.summary-card .row.total span:last-child { color: var(--primary); }

/* ---------- Forms ---------- */
.form-group { margin-bottom: 17px; }
.form-group label { display: block; font-size: 12.5px; font-weight: 700; margin-bottom: 7px; color: var(--text-secondary); text-transform: uppercase; letter-spacing: 0.03em; }
.form-group input, .form-group textarea, .form-group select {
  width: 100%; padding: 13px 14px; border-radius: var(--radius-sm); border: 1.5px solid var(--border);
  font-size: 14.5px; font-family: inherit; color: var(--text-primary); transition: border-color 0.12s ease;
}
.form-group input:focus, .form-group textarea:focus { outline: none; border-color: var(--primary); }

.date-trigger {
  width: 100%; display: flex; align-items: center; justify-content: space-between; gap: 10px;
  padding: 13px 14px; border-radius: var(--radius-sm); border: 1.5px solid var(--border);
  background: #fff; font-size: 14.5px; font-family: inherit; font-weight: 600; color: var(--text-primary);
  cursor: pointer; transition: border-color 0.12s ease;
}
.date-trigger:hover { border-color: var(--primary); }
.date-trigger svg { color: var(--text-tertiary); flex-shrink: 0; }

.modal-overlay {
  display: none; position: fixed; inset: 0; background: rgba(16, 24, 23, 0.45);
  z-index: 100; align-items: center; justify-content: center; padding: 20px;
}
.modal-dialog {
  background: #fff; border-radius: var(--radius-lg); box-shadow: var(--shadow-lg);
  width: 100%; max-width: 360px; max-height: calc(100vh - 40px); overflow-y: auto;
  padding: 20px 22px 24px;
}
.modal-header { display: flex; align-items: center; justify-content: space-between; margin-bottom: 16px; }
.modal-header h3 { font-size: 16px; font-weight: 700; color: var(--text-primary); }
.modal-close {
  width: 30px; height: 30px; border: none; background: var(--bg-grey); border-radius: 50%;
  font-size: 20px; line-height: 1; color: var(--text-secondary); cursor: pointer;
}
.modal-close:hover { background: var(--border); color: var(--text-primary); }
.form-card { background: #fff; border: 1px solid var(--border); border-radius: var(--radius-lg); padding: 24px; }
.error-banner {
  background: var(--error-tint); color: var(--error); padding: 13px 15px; border-radius: var(--radius-sm);
  font-size: 13.5px; margin-bottom: 18px; display: none; font-weight: 500;
}
.error-banner.visible { display: block; }
.payment-note { font-size: 12.5px; color: var(--text-secondary); margin: 14px 0 0; display: flex; align-items: center; gap: 6px; }

/* ---------- Confirmation ---------- */
.confirmation-box {
  max-width: 460px; margin: 64px auto; background: #fff; border-radius: var(--radius-xl);
  border: 1px solid var(--border); box-shadow: var(--shadow-lg); padding: 44px 34px; text-align: center;
}
.confirmation-box .check-icon {
  width: 68px; height: 68px; border-radius: 50%; background: var(--success-tint); color: var(--success);
  display: flex; align-items: center; justify-content: center; margin: 0 auto 18px;
}
.confirmation-box h1 { font-size: 21px; margin-bottom: 8px; }
.confirmation-box .sub { color: var(--text-secondary); font-size: 14px; line-height: 1.55; }
.confirmation-detail {
  margin-top: 24px; text-align: left; border-top: 1px solid var(--border); padding-top: 18px; display: flex; flex-direction: column; gap: 9px;
}
.confirmation-detail .row { display: flex; justify-content: space-between; font-size: 13.5px; }
.confirmation-detail .row span:first-child { color: var(--text-secondary); }
.confirmation-detail .row span:last-child { font-weight: 700; }
.status-pill { display: inline-block; background: var(--primary-tint); color: var(--primary); padding: 3px 10px; border-radius: 999px; font-size: 12px; font-weight: 700; }

/* ---------- Footer ---------- */
.site-footer { background: var(--secondary); margin-top: 24px; }
.footer-grid {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr;
  gap: 32px;
  padding: 44px 24px 32px;
}
@media (max-width: 640px) {
  .footer-grid { grid-template-columns: 1fr; gap: 28px; }
}
.footer-col { display: flex; flex-direction: column; gap: 10px; }
.footer-col h4 {
  font-size: 12px; font-weight: 700; color: #C99992; text-transform: uppercase;
  letter-spacing: 0.06em; margin: 0 0 2px;
}
.footer-col a { color: #E9C9C3; font-size: 13.5px; transition: color 0.12s ease; opacity: 0.9; }
.footer-col a:hover { color: #fff; opacity: 1; }
.footer-col p { color: #E9C9C3; font-size: 13.5px; line-height: 1.6; margin: 0; opacity: 0.85; }
.footer-brand { display: flex; align-items: center; gap: 10px; font-family: 'Archivo Black', 'Plus Jakarta Sans', sans-serif; font-size: 15.5px; color: #fff; }
.footer-brand .brand-icon { width: 32px; height: 32px; font-size: 13px; border-radius: 9px; }
.footer-meta { display: flex; align-items: center; gap: 6px; color: #E9C9C3; font-size: 13.5px; }
.footer-meta svg { flex-shrink: 0; color: #C99992; }

.footer-bottom { border-top: 1px solid rgba(255, 255, 255, 0.1); }
.footer-bottom-inner {
  display: flex; justify-content: space-between; align-items: center; flex-wrap: wrap; gap: 8px;
  padding: 16px 24px; color: #B98F89; font-size: 12px;
}
.footer-bottom-inner strong { color: #E9C9C3; }

/* ---------- Account ---------- */
.account-profile {
  display: flex;
  align-items: center;
  gap: 16px;
  padding-bottom: 20px;
  border-bottom: 1px solid var(--border);
  margin-bottom: 16px;
}
.account-avatar-lg {
  width: 56px;
  height: 56px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--primary-light), var(--primary-dark));
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 22px;
  font-weight: 700;
  flex-shrink: 0;
}
.account-name { font-size: 17px; font-weight: 700; }
.account-email { font-size: 13.5px; color: var(--text-secondary); margin-top: 2px; }
.account-row {
  display: flex;
  justify-content: space-between;
  padding: 10px 0;
  font-size: 13.5px;
  color: var(--text-secondary);
}
.account-row strong { color: var(--text-primary); }

/* ---------- My Orders / sign-in gate ---------- */
.signin-prompt {
  text-align: center;
  padding: 70px 20px;
  background: #fff;
  border-radius: var(--radius-lg);
  border: 1px dashed var(--border);
}
.signin-prompt .icon { font-size: 40px; margin-bottom: 12px; opacity: 0.5; }
.signin-prompt p { font-size: 14.5px; color: var(--text-secondary); margin: 0 0 18px; }

.order-card {
  background: #fff;
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 18px 20px;
  margin-bottom: 14px;
}
.order-card-top {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 12px;
  margin-bottom: 12px;
}
.order-card-top .order-id { font-weight: 700; font-size: 14.5px; }
.order-card-top .order-date { font-size: 12.5px; color: var(--text-tertiary); margin-top: 2px; }
.order-status {
  display: inline-block;
  padding: 4px 11px;
  border-radius: 999px;
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.03em;
  white-space: nowrap;
}
.order-status.pending { background: #FFF4E5; color: var(--accent); }
.order-status.completed { background: var(--success-tint); color: var(--success); }
.order-status.rejected { background: var(--error-tint); color: var(--error); }

.order-card-items { display: flex; flex-direction: column; gap: 8px; margin-bottom: 12px; }
.order-item-row { display: flex; align-items: center; gap: 10px; }
.order-item-thumb {
  width: 34px;
  height: 34px;
  border-radius: 8px;
  background: var(--bg-grey);
  border: 1px solid var(--border);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--text-tertiary);
  overflow: hidden;
  flex-shrink: 0;
}
.order-item-thumb img { width: 100%; height: 100%; object-fit: cover; }
.order-item-name { font-size: 13px; color: var(--text-secondary); }

.order-card-meta {
  display: flex;
  justify-content: space-between;
  align-items: center;
  border-top: 1px solid var(--border);
  padding-top: 12px;
  font-size: 13.5px;
  color: var(--text-secondary);
}
.order-card-meta strong { color: var(--text-primary); font-size: 15px; }

.delivery-status {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 4px 10px;
  border-radius: 999px;
  font-size: 11.5px;
  font-weight: 700;
}
.delivery-status.pending { background: var(--bg-grey); color: var(--text-secondary); }
.delivery-status.confirmed { background: #EEF0FF; color: #4C51E0; }
.delivery-status.dispatched { background: #E7F1FE; color: #1C6FE0; }
.delivery-status.delivered { background: var(--success-tint); color: var(--success); }

.breadcrumb { font-size: 13px; color: var(--text-tertiary); margin: 20px 0 4px; }
.breadcrumb a { color: var(--text-secondary); font-weight: 600; }
.breadcrumb a:hover { color: var(--primary); }

.page-title { font-size: 22px; margin: 6px 0 20px; }

/* ---------- Product search / autocomplete ---------- */
.search-suggestions {
  position: absolute;
  top: calc(100% + 6px);
  left: 0;
  right: 0;
  z-index: 20;
  background: #fff;
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-lg);
  max-height: 360px;
  overflow-y: auto;
}
.search-suggestion-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 10px 14px;
  border-bottom: 1px solid var(--border);
}
.search-suggestion-item:last-child { border-bottom: none; }
.search-suggestion-item:hover { background: var(--bg-grey); }
.search-suggestion-thumb {
  width: 36px;
  height: 36px;
  flex-shrink: 0;
  border-radius: var(--radius-sm);
  background: var(--bg-grey);
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  color: var(--text-tertiary);
}
.search-suggestion-thumb img { width: 100%; height: 100%; object-fit: cover; }
.search-suggestion-info { flex: 1; min-width: 0; }
.search-suggestion-name {
  font-size: 13.5px;
  font-weight: 600;
  color: var(--text-primary);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.search-suggestion-price { font-size: 12.5px; color: var(--primary); font-weight: 700; margin-top: 1px; }
.search-suggestion-empty { padding: 16px 14px; font-size: 13px; color: var(--text-tertiary); text-align: center; }
