/* ============================================================
   LUMIÈRE — Premium E-Commerce Catalogue
   CSS Stylesheet · HTML & CSS Only · No JavaScript
   ============================================================ */

/* ─── CSS Custom Properties ─── */
:root {
  --cream:     #FAF8F5;
  --white:     #FFFFFF;
  --gray-50:   #F5F4F1;
  --gray-100:  #EDECEA;
  --gray-200:  #D8D6D2;
  --gray-400:  #9E9B96;
  --gray-600:  #6B6864;
  --gray-800:  #2E2D2B;
  --ink:       #1A1917;

  --accent:    hsl(32, 67%, 51%);      /* Deep forest green */
  --accent-lt: #4A7C43;
  --accent-bg: #EFF5EE;
  --gold:      #B8973A;
  --red:       #C0392B;
  --green:     #27AE60;

  --font-display: 'Playfair Display', Georgia, serif;
  --font-body:    'DM Sans', system-ui, sans-serif;

  --radius-sm:  6px;
  --radius-md:  12px;
  --radius-lg:  20px;
  --radius-xl:  32px;

  --shadow-sm:  0 1px 4px rgba(26,25,23,0.06);
  --shadow-md:  0 4px 16px rgba(26,25,23,0.1);
  --shadow-lg:  0 12px 40px rgba(26,25,23,0.14);
  --shadow-xl:  0 24px 64px rgba(26,25,23,0.18);

  --header-h:  70px;
  --transition: 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

/* ─── Reset ─── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; font-size: 16px; }
body {
  font-family: var(--font-body);
  background: var(--cream);
  color: var(--ink);
  line-height: 1.6;
  overflow-x: hidden;
}
img { max-width: 100%; display: block; }
a { text-decoration: none; color: inherit; }
button { cursor: pointer; font-family: var(--font-body); border: none; }
ul { list-style: none; }
input, textarea { font-family: var(--font-body); }
[hidden] { display: none !important; }

/* ─── Utilities ─── */
.container {
  max-width: 1240px;
  margin: 0 auto;
  padding: 0 24px;
}
.section {
  padding: 96px 0;
}
.section-head {
  text-align: center;
  margin-bottom: 56px;
}
.section-label {
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: 8px;
}
.section-title {
  font-family: var(--font-display);
  font-size: clamp(2rem, 4vw, 3rem);
  font-weight: 700;
  color: var(--ink);
  line-height: 1.15;
  margin-bottom: 16px;
}
.section-desc {
  font-size: 1.05rem;
  color: var(--gray-600);
  max-width: 520px;
  margin: 0 auto;
}

/* ─── Buttons ─── */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 14px 32px;
  border-radius: var(--radius-sm);
  font-size: 0.9rem;
  font-weight: 600;
  letter-spacing: 0.04em;
  transition: all var(--transition);
  white-space: nowrap;
  border: 2px solid transparent;
}
.btn-primary {
  background: var(--accent);
  color: var(--white);
  border-color: var(--accent);
}
.btn-primary:hover {
  background: var(--accent-lt);
  border-color: var(--accent-lt);
  transform: translateY(-1px);
  box-shadow: 0 8px 24px rgba(45,90,39,0.3);
}
.btn-ghost {
  background: transparent;
  color: var(--white);
  border-color: rgba(255,255,255,0.5);
}
.btn-ghost:hover {
  background: rgba(255,255,255,0.15);
  border-color: var(--white);
}
.btn-outline {
  background: transparent;
  color: var(--accent);
  border-color: var(--accent);
}
.btn-outline:hover {
  background: var(--accent);
  color: var(--white);
  transform: translateY(-1px);
}
.btn-full { width: 100%; justify-content: center; }

.text-green { color: var(--green); font-weight: 500; }
.text-red   { color: var(--red);   font-weight: 500; }

/* ============================================================
   HEADER
   ============================================================ */
.site-header {
  position: sticky;
  top: 0;
  z-index: 1000;
  background: var(--white);
  border-bottom: 1px solid var(--gray-100);
  box-shadow: var(--shadow-sm);
}
.header-inner {
  display: flex;
  align-items: center;
  gap: 24px;
  height: var(--header-h);
  max-width: 1240px;
  margin: 0 auto;
  padding: 0 24px;
}
.headline {
    font-family: 'Allura', google;
    font-size: 36px;
    color: #d19234;
    letter-spacing: 1px;
    flex-shrink: 0;
    white-space: nowrap;
}


/* Logo */
.logo {
  display: flex;
  align-items: center;
  flex-shrink: 0;
}
.logo-img {
  display: block;
  height: 120px;
  width: auto;
  object-fit: contain;
}
.logo-mark {
  font-size: 1.15rem;
  color: var(--accent);
}
.logo-text {
  font-family: var(--font-display);
  font-size: 2.4rem;
  font-weight: 00;
  letter-spacing: 0.1em;
  color: var(--ink);
}
.logo-light .logo-text { color: var(--white); }
.logo-light .logo-mark { color: var(--gold); }

/* Nav */
.main-nav {
  display: flex;
  align-items: center;
  gap: 24px;
  margin-left: auto;
}
.nav-link {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 8px 16px;
  border-radius: var(--radius-sm);
  font-size: .9rem;
  font-weight: 500;
  color: var(--gray-600);
  transition: all var(--transition);
  position: relative;
}
.nav-link:hover, .nav-link.active {
  color: var(--ink);
  background: var(--gray-50);
}
.cart-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 18px;
  height: 18px;
  background: var(--accent);
  color: var(--white);
  border-radius: 50%;
  font-size: 0.65rem;
  font-weight: 700;
}

/* Search */
.header-search { flex-shrink: 0; }
.search-wrap {
  position: relative;
  display: flex;
  align-items: center;
}
.search-icon {
  position: absolute;
  left: 12px;
  width: 16px;
  height: 16px;
  color: var(--gray-400);
  pointer-events: none;
}
.search-input {
  padding: 10px 14px 10px 38px;
  border: 1.5px solid var(--gray-200);
  border-radius: var(--radius-sm);
  font-size: 0.875rem;
  background: var(--gray-50);
  color: var(--ink);
  width: 220px;
  transition: all var(--transition);
  outline: none;
}
.search-input:focus {
  border-color: var(--accent);
  background: var(--white);
  box-shadow: 0 0 0 3px rgba(45,90,39,0.1);
  width: 260px;
}
.search-input::placeholder { color: var(--gray-400); }

/* Search Suggestions */
.search-suggestions {
  position: absolute;
  top: 100%;
  left: 0;
  right: 0;
  background: var(--white);
  border: 1px solid var(--gray-200);
  border-top: none;
  border-radius: 0 0 var(--radius-sm) var(--radius-sm);
  box-shadow: var(--shadow-md);
  z-index: 1100;
  max-height: 280px;
  overflow-y: auto;
  display: none;
}
.search-suggestions.is-visible { display: block; }
.suggestion-item {
  padding: 12px 16px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  font-size: 0.85rem;
  color: var(--ink);
  cursor: pointer;
  border-bottom: 1px solid var(--gray-50);
  transition: background var(--transition);
}
.suggestion-item:last-child { border-bottom: none; }
.suggestion-item:hover { background: var(--gray-50); color: var(--accent); }
.suggestion-cat {
  font-size: 0.7rem;
  font-weight: 700;
  text-transform: uppercase;
  color: var(--gray-400);
  letter-spacing: 0.05em;
}

@keyframes productHighlight {
  0% { box-shadow: 0 0 0 0 rgba(184, 151, 58, 0); }
  50% { box-shadow: 0 0 0 4px var(--gold); transform: scale(1.02); }
  100% { box-shadow: 0 0 0 0 rgba(184, 151, 58, 0); }
}
.product-card.highlight-search {
  animation: productHighlight 1.5s ease-out;
  z-index: 10;
}

/* Mobile hamburger */
.menu-toggle-input { display: none; }
.hamburger {
  display: none;
  flex-direction: column;
  gap: 5px;
  cursor: pointer;
  padding: 8px;
  position: absolute;
  top: 50%;
  right: 24px;
  transform: translateY(-50%);
  z-index: 1001;
}
.hamburger span {
  display: block;
  width: 22px;
  height: 2px;
  background: var(--ink);
  border-radius: 2px;
  transition: all var(--transition);
}

/* Hamburger animation */
.menu-toggle-input:checked + .hamburger span:nth-child(1) {
  transform: rotate(45deg) translate(6px, 6px);
  background: var(--accent);
}
.menu-toggle-input:checked + .hamburger span:nth-child(2) {
  opacity: 0;
}
.menu-toggle-input:checked + .hamburger span:nth-child(3) {
  transform: rotate(-45deg) translate(6px, -6px);
  background: var(--accent);
}

/* Mobile nav */
.mobile-nav {
  display: none;
  flex-direction: column;
  padding: 16px 24px 20px;
  border-top: 1px solid var(--gray-100);
  gap: 4px;
  background: var(--white);
  position: absolute;
  top: 100%;
  left: 0;
  right: 0;
  box-shadow: var(--shadow-md);
  z-index: 999;
}
.mobile-nav-link {
  padding: 12px 16px;
  border-radius: var(--radius-sm);
  font-size: 0.95rem;
  font-weight: 500;
  color: var(--gray-600);
  transition: all var(--transition);
  position: relative;
  overflow: hidden;
}
.mobile-nav-link:hover { background: var(--gray-50); color: var(--ink); }

/* Close mobile nav when clicking on links */
.mobile-nav-link:active,
.mobile-nav-link:focus {
  background: var(--accent-bg);
  color: var(--accent);
}
.mobile-search {
  position: relative;
  display: flex;
  align-items: center;
  margin-top: 8px;
}
.mobile-search .search-input { width: 100%; }
.mobile-search .search-icon { left: 12px; }

.menu-toggle-input:checked + .hamburger ~ .mobile-nav { display: flex; }

/* ============================================================
   HERO
   ============================================================ */
.hero {
  position: relative;
  min-height: calc(100vh - var(--header-h));
  min-height: 600px;
  display: left;
  align-items: center;
  overflow: hidden;
}
.hero-bg {
  position: absolute;
  inset: 0;
}
.hero-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
  transform-origin: center;
  animation: heroZoom 18s ease-in-out infinite alternate;
}
@keyframes heroZoom {
  from { transform: scale(1); }
  to   { transform: scale(1.06); }
}
.hero-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(
    105deg,
    rgba(26,25,23,0.72) 0%,
    rgba(26,25,23,0.45) 55%,
    rgba(26,25,23,0.2) 100%
  );
}
.hero-content {
  position: relative;
  z-index: 2;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  justify-content: center;
  gap: 18px;
  margin: 0 auto;
  width: 100%;
  max-width: px;
  padding:  24px;
  padding-left: max(24px, calc((100vw - 1240px)/2 + 24px));
  animation: heroFade 1.2s ease both;
}
@keyframes heroFade {
  from { opacity: 0; transform: translateY(24px); }
  to   { opacity: 1; transform: translateY(0); }
}
.hero-eyebrow {
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--gold);
  margin: 0;
  display: flex;
  align-items: center;
  gap: 12px;
}
.hero-eyebrow::before {
  content: '';
  display: block;
  width: 32px;
  height: 1px;
  background: var(--gold);
}
.hero-title {
  font-family: var(--font-display);
  font-size: clamp(2.8rem, 6vw, 4.8rem);
  font-weight: 700;
  color: var(--white);
  line-height: 1.1;
  margin: 0;
  text-wrap: balance;
}
.hero-title em {
  font-style: italic;
  color: var(--gold);
}
.hero-subtitle {
  font-size: 1.1rem;
  color: rgba(255,255,255,0.8);
  max-width: 520px;
  margin: 0;
  line-height: 1.7;
}
.hero-actions {
  display: flex;
  gap: 16px;
  flex-wrap: wrap;
  align-items: center;
  margin-top: 10px;
}

/* Scroll hint */
.hero-scroll-hint {
  position: absolute;
  bottom: 40px;
  right: max(24px, calc((100vw - 1240px)/2 + 24px));
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
  color: rgba(255,255,255,0.6);
  font-size: 0.7rem;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  animation: scrollBounce 2s ease-in-out infinite;
}
.scroll-line {
  width: 1px;
  height: 48px;
  background: linear-gradient(to bottom, rgba(255,255,255,0.6), transparent);
}
@keyframes scrollBounce {
  0%, 100% { transform: translateY(0); }
  50%       { transform: translateY(8px); }
}

/* ============================================================
   MARQUEE STRIP
   ============================================================ */
.marquee-strip {
  background: var(--accent);
  color: var(--white);
  padding: 12px 0;
  overflow: hidden;
}
.marquee-track {
  display: flex;
  gap: 48px;
  white-space: nowrap;
  animation: marquee 28s linear infinite;
  width: max-content;
}
.marquee-track span {
  font-size: 0.8rem;
  font-weight: 500;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}
.marquee-track .dot {
  color: var(--gold);
  font-size: 0.6rem;
}
@keyframes marquee {
  from { transform: translateX(0); }
  to   { transform: translateX(-50%); }
}

/* ============================================================
   CATEGORIES
   ============================================================ */
.categories-section { background: var(--white); }

.category-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
}
.category-card {
  display: block;
  border-radius: var(--radius-md);
  overflow: hidden;
  background: var(--gray-50);
  transition: all var(--transition);
  box-shadow: var(--shadow-sm);
}
.category-card:hover {
  transform: translateY(-6px);
  box-shadow: var(--shadow-lg);
}
.category-img-wrap {
  position: relative;
  overflow: hidden;
  aspect-ratio: 4/3;
}
.category-img-wrap img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.6s cubic-bezier(0.4,0,0.2,1);
}
.category-card:hover .category-img-wrap img {
  transform: scale(1.08);
}
.category-overlay {
  position: absolute;
  inset: 0;
  background: rgba(45,90,39,0.55);
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  transition: opacity var(--transition);
}
.category-card:hover .category-overlay { opacity: 1; }
.category-cta {
  color: var(--white);
  font-size: 0.9rem;
  font-weight: 600;
  letter-spacing: 0.05em;
  border: 1.5px solid rgba(255,255,255,0.7);
  padding: 10px 24px;
  border-radius: var(--radius-sm);
  backdrop-filter: blur(4px);
  transition: all var(--transition);
}
.category-card:hover .category-cta {
  border-color: var(--white);
  background: rgba(255,255,255,0.15);
}
.category-info {
  padding: 18px 20px;
}
.category-name {
  font-family: var(--font-display);
  font-size: 1.2rem;
  font-weight: 600;
  color: var(--ink);
  margin-bottom: 4px;
}
.category-count {
  font-size: 0.82rem;
  color: var(--gray-400);
  font-weight: 500;
}

/* ============================================================
   PROMO BANNER
   ============================================================ */
.promo-banner {
  background: var(--ink);
  display: flex;
  align-items: stretch;
  overflow: hidden;
  min-height: 360px;
}
.promo-content {
  flex: 1;
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: 64px max(40px, calc((100vw - 1240px)/2 + 40px));
  gap: 24px;
}
.promo-tag {
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--gold);
}
.promo-title {
  font-family: var(--font-display);
  font-size: clamp(2rem, 4vw, 3.2rem);
  color: var(--white);
  line-height: 1.15;
}
.promo-title span {
  color: var(--gold);
  font-style: italic;
}
.promo-img-wrap {
  flex: 0 0 45%;
  max-width: 45%;
  overflow: hidden;
  position: relative;
}
.promo-img-wrap img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.8s ease;
}
.promo-banner:hover .promo-img-wrap img {
  transform: scale(1.04);
}

/* ============================================================
   PRODUCTS
   ============================================================ */
.products-section { background: var(--cream); }

/* Filter Tabs */
.filter-tabs {
  display: flex;
  gap: 8px;
  justify-content: center;
  margin-bottom: 48px;
  flex-wrap: wrap;
}
.filter-tab {
  padding: 10px 24px;
  border-radius: 50px;
  font-size: 0.875rem;
  font-weight: 500;
  color: var(--gray-600);
  background: var(--white);
  border: 1.5px solid var(--gray-200);
  cursor: pointer;
  transition: all var(--transition);
  user-select: none;
}
.filter-tab:hover,
.filter-tab.active-tab {
  background: var(--accent);
  color: var(--white);
  border-color: var(--accent);
}

/* Product Grid */
.product-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 24px;
}
.product-card {
  background: var(--white);
  border-radius: var(--radius-md);
  overflow: hidden;
  box-shadow: var(--shadow-sm);
  transition: all var(--transition);
  display: flex;
  flex-direction: column;
  cursor: pointer;
}
.product-card:hover {
  transform: translateY(-6px);
  box-shadow: var(--shadow-lg);
}
.product-card:hover .product-name {
  color: var(--accent);
}

.category-panel {
  display: none !important;
}

.category-panel.is-open {
  display: block !important;
}

/* Specifically force textile-products to be hidden */
#textile-products {
  display: none !important;
}

#textile-products.is-open {
  display: block !important;
}

/* Product Image */
.product-img-wrap {
  position: relative;
  overflow: hidden;
  aspect-ratio: 1 / 1;
  background: var(--gray-50);
}
.product-img-wrap img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.6s cubic-bezier(0.4,0,0.2,1);
}
.product-card:hover .product-img-wrap img {
  transform: scale(1.08);
}

/* Badges */
.product-badges {
  position: absolute;
  top: 12px;
  left: 12px;
  display: flex;
  flex-direction: column;
  gap: 6px;
  z-index: 2;
}
.badge {
  padding: 4px 10px;
  border-radius: 4px;
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}
.badge-new  { background: var(--accent); color: var(--white); }
.badge-sale { background: var(--red);    color: var(--white); }

/* Quick view overlay */
.product-overlay {
  position: absolute;
  inset: 0;
  background: rgba(26,25,23,0.5);
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  transition: opacity var(--transition);
}
.product-card:hover .product-overlay { opacity: 1; }
.overlay-btn {
  background: var(--white);
  color: var(--ink);
  border: none;
  padding: 10px 24px;
  border-radius: var(--radius-sm);
  font-size: 0.85rem;
  font-weight: 600;
  transition: all var(--transition);
}
.overlay-btn:hover {
  background: var(--accent);
  color: var(--white);
}

/* Product Info */
.product-info {
  padding: 18px 20px;
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 6px;
}
.product-category {
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--accent);
}
.product-name {
  font-family: var(--font-display);
  font-size: 1rem;
  font-weight: 600;
  color: var(--ink);
  line-height: 1.3;
}
.product-rating {
  display: none;
  align-items: center;
  gap: 6px;
}
.stars { color: var(--gold); font-size: 0.75rem; letter-spacing: 1px; }
.review-count { font-size: 0.75rem; color: var(--gray-400); }

.product-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-top: auto;
  padding-top: 14px;
  border-top: 1px solid var(--gray-100);
}
.product-stock {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin: 10px 0 0;
  font-size: 0.82rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}
.product-stock::before {
  content: "";
  width: 9px;
  height: 9px;
  border-radius: 50%;
  background: currentColor;
  box-shadow: 0 0 0 4px rgba(0, 0, 0, 0.05);
}
.stock-in { color: #177245; }
.stock-out { color: #c0392b; }
.product-price {
  display: flex;
  flex-direction: column;
  gap: 2px;
}
.price-current {
  font-size: 1.05rem;
  font-weight: 700;
  color: var(--ink);
}
.price-original {
  font-size: 0.8rem;
  color: var(--gray-400);
  text-decoration: line-through;
}
.catalog-qty {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 6px;
  border: 1px solid var(--gray-200);
  border-radius: 999px;
  background: var(--gray-50);
}
.catalog-qty-btn {
  width: 32px;
  height: 32px;
  border: none;
  border-radius: 50%;
  background: var(--white);
  color: var(--ink);
  font-size: 1rem;
  font-weight: 700;
  line-height: 1;
  cursor: pointer;
  transition: transform var(--transition-fast), background var(--transition-fast), color var(--transition-fast);
}
.catalog-qty-btn:hover {
  background: var(--accent);
  color: var(--white);
  transform: translateY(-1px);
}
.catalog-qty-btn:disabled {
  background: #eceae5;
  color: #9a978f;
  cursor: not-allowed;
  transform: none;
}
.catalog-qty-val {
  min-width: 24px;
  text-align: center;
  font-size: 0.92rem;
  font-weight: 700;
  color: var(--ink);
}
.btn-cart {
  padding: 9px 16px;
  background: var(--accent-bg);
  color: var(--accent);
  border: 1.5px solid var(--accent);
  border-radius: var(--radius-sm);
  font-size: 0.78rem;
  font-weight: 600;
  letter-spacing: 0.03em;
  transition: all var(--transition);
  white-space: nowrap;
  flex-shrink: 0;
}
.btn-cart:hover {
  background: var(--accent);
  color: var(--white);
  transform: scale(1.04);
}
.btn-cart:disabled {
  background: #d9d8d4;
  color: #6e6b66;
  border-color: #d9d8d4;
  cursor: not-allowed;
  transform: none;
}

.product-detail-section {
  min-height: 100vh;
  display: flex;
  align-items: center;
  background:
    radial-gradient(circle at top left, rgba(193, 154, 107, 0.14), transparent 30%),
    linear-gradient(180deg, #fcfaf6 0%, #f4efe7 100%);
}
.product-detail-section .container {
  max-width: min(1600px, 96vw);
  width: 100%;
}
.detail-layout {
  display: grid;
  grid-template-columns: minmax(0, 1.2fr) minmax(380px, 0.8fr);
  gap: 32px;
  align-items: stretch;
}
.detail-media,
.detail-content {
  background: rgba(255, 255, 255, 0.82);
  border: 1px solid rgba(193, 154, 107, 0.18);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-md);
  backdrop-filter: blur(10px);
}
.detail-media {
  padding: 24px;
  min-height: 78vh;
  display: flex;
  flex-direction: column;
}
.detail-image-frame {
  position: relative;
  flex: 1;
  min-height: 0;
  overflow: hidden;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 12px 56px;
  border-radius: calc(var(--radius-lg) - 6px);
  background: linear-gradient(145deg, #fffdf9 0%, #efe7da 100%);
}
.detail-image {
  width: 100%;
  height: 100%;
  max-width: 100%;
  max-height: 100%;
  object-fit: contain;
  object-position: center;
}
.detail-gallery-nav {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  z-index: 2;
  width: 42px;
  height: 42px;
  border: none;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.88);
  color: var(--ink);
  box-shadow: var(--shadow-md);
  font-size: 1.8rem;
  line-height: 1;
  cursor: pointer;
}
.detail-gallery-prev {
  left: 14px;
}
.detail-gallery-next {
  right: 14px;
}
.detail-gallery-nav:hover {
  background: var(--white);
}
.detail-thumbs {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(72px, 1fr));
  gap: 12px;
  margin-top: 16px;
}
.detail-thumb {
  border: 2px solid transparent;
  border-radius: var(--radius-md);
  padding: 0;
  overflow: hidden;
  background: #fffdf9;
  cursor: pointer;
  transition: border-color var(--transition-fast), transform var(--transition-fast), box-shadow var(--transition-fast);
}
.detail-thumb:hover,
.detail-thumb.is-active {
  border-color: var(--accent);
  transform: translateY(-2px);
  box-shadow: var(--shadow-md);
}
.detail-thumb img {
  width: 100%;
  aspect-ratio: 1 / 1;
  display: block;
  object-fit: cover;
}
.detail-content {
  padding: 30px;
  display: flex;
  flex-direction: column;
  gap: 22px;
}
.detail-category {
  font-size: 0.76rem;
  font-weight: 700;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--accent);
}
.detail-title {
  font-family: var(--font-display);
  font-size: clamp(1.9rem, 3vw, 2.8rem);
  line-height: 1.05;
  color: var(--ink);
}
.detail-stock {
  display: inline-flex;
  width: fit-content;
  padding: 8px 14px;
  border-radius: 999px;
  background: rgba(23, 114, 69, 0.12);
  color: #177245;
  font-size: 0.85rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
}
.detail-stock.stock-out {
  background: rgba(192, 57, 43, 0.12);
  color: #c0392b;
}
.detail-description {
  color: var(--gray-600);
  line-height: 1.7;
}
.detail-block {
  display: flex;
  flex-direction: column;
  gap: 14px;
  padding-top: 18px;
  border-top: 1px solid var(--gray-100);
}
.detail-label-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}
.detail-label,
.detail-selection {
  font-size: 0.9rem;
  font-weight: 700;
  color: var(--ink);
}
.detail-selection {
  color: var(--accent);
}
.detail-colors {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}
.detail-color-btn {
  min-width: 46px;
  height: 46px;
  border: 2px solid transparent;
  border-radius: 999px;
  padding: 0 14px;
  display: inline-flex;
  align-items: center;
  gap: 10px;
  background: var(--white);
  color: var(--ink);
  box-shadow: var(--shadow-sm);
  cursor: pointer;
  transition: transform var(--transition-fast), border-color var(--transition-fast), box-shadow var(--transition-fast);
}
.detail-color-btn:hover,
.detail-color-btn.is-active {
  border-color: var(--accent);
  transform: translateY(-1px);
  box-shadow: var(--shadow-md);
}
.detail-color-swatch {
  width: 16px;
  height: 16px;
  border-radius: 50%;
  border: 1px solid rgba(0,0,0,0.08);
}
.detail-color-name {
  font-size: 0.82rem;
  font-weight: 600;
}
.detail-qty {
  display: inline-flex;
  align-items: center;
  gap: 14px;
  width: fit-content;
  padding: 8px 10px;
  border: 1px solid var(--gray-200);
  border-radius: 999px;
  background: var(--white);
}
.detail-qty-btn {
  width: 38px;
  height: 38px;
  border: none;
  border-radius: 50%;
  background: var(--accent-bg);
  color: var(--accent);
  font-size: 1.1rem;
  font-weight: 700;
  cursor: pointer;
}
.detail-qty-number {
  min-width: 24px;
  text-align: center;
  font-size: 1rem;
  font-weight: 700;
  color: var(--ink);
}
.detail-specs {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}
.detail-spec-item {
  padding: 14px 16px;
  border-radius: var(--radius-md);
  background: #fffdf9;
  border: 1px solid var(--gray-100);
  display: flex;
  flex-direction: column;
  gap: 6px;
}
.detail-spec-item span {
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--gray-500);
}
.detail-spec-item strong {
  font-size: 0.96rem;
  color: var(--ink);
}
.detail-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
}

.detail-theme-electronics {
  background:
    radial-gradient(circle at top right, rgba(214, 155, 69, 0.14), transparent 26%),
    radial-gradient(circle at left center, rgba(44, 57, 85, 0.08), transparent 28%),
    linear-gradient(180deg, #f7f1e7 0%, #efe6d7 100%);
}
.detail-layout-electronics {
  grid-template-columns: 1fr;
  gap: 28px;
}
.detail-theme-electronics .detail-media {
  min-height: auto;
  padding: 18px 18px 22px;
  background: rgba(255, 255, 255, 0.64);
  border-color: rgba(182, 140, 83, 0.2);
  box-shadow: 0 28px 50px rgba(80, 57, 26, 0.08);
}
.detail-theme-electronics .detail-image-frame {
  min-height: clamp(440px, 72vh, 780px);
  padding: 14px 58px;
  border-radius: 28px;
  background:
    linear-gradient(180deg, rgba(255,255,255,0.98) 0%, rgba(253,250,244,0.96) 100%);
  box-shadow:
    inset 0 0 0 1px rgba(202, 173, 132, 0.18),
    0 18px 36px rgba(108, 84, 49, 0.08);
}
.detail-theme-electronics .detail-image {
  max-width: min(100%, 860px);
}
.detail-theme-electronics .detail-gallery-nav {
  width: 48px;
  height: 48px;
  background: rgba(255, 255, 255, 0.96);
  color: #43311d;
  box-shadow: 0 16px 30px rgba(80, 57, 26, 0.12);
}
.detail-theme-electronics .detail-gallery-prev {
  left: 14px;
}
.detail-theme-electronics .detail-gallery-next {
  right: 14px;
}
.detail-theme-electronics .detail-thumbs {
  display: flex;
  align-items: stretch;
  gap: 18px;
  margin-top: 18px;
  padding: 8px 2px 2px;
  overflow-x: auto;
  scrollbar-width: thin;
  scrollbar-color: rgba(196, 141, 57, 0.45) transparent;
}
.detail-theme-electronics .detail-thumb {
  flex: 0 0 clamp(92px, 12vw, 160px);
  border: 2px solid rgba(223, 212, 194, 0.88);
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.92);
  box-shadow: 0 10px 20px rgba(80, 57, 26, 0.06);
}
.detail-theme-electronics .detail-thumb:hover,
.detail-theme-electronics .detail-thumb.is-active {
  border-color: #d28a2b;
  transform: translateY(-3px);
  box-shadow: 0 16px 28px rgba(128, 84, 23, 0.14);
}
.detail-theme-electronics .detail-thumb img {
  aspect-ratio: 1 / 1;
  object-fit: contain;
  padding: 10px;
  background: linear-gradient(180deg, #ffffff 0%, #fbf6ef 100%);
}
.detail-theme-electronics .detail-content {
  padding: 28px 30px;
  background: rgba(255, 255, 255, 0.9);
}
.detail-theme-electronics .detail-title {
  max-width: 18ch;
}
.detail-theme-electronics .detail-spec-item {
  background: linear-gradient(180deg, #fffdfa 0%, #f8f0e5 100%);
}

.load-more-wrap {
  text-align: center;
  margin-top: 56px;
}

/* ============================================================
   TRUST STRIP
   ============================================================ */
.trust-strip {
  background: var(--gray-50);
  border-top: 1px solid var(--gray-100);
  border-bottom: 1px solid var(--gray-100);
  padding: 48px 0;
}
.trust-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 32px;
}
.trust-item {
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
}
.trust-icon {
  font-size: 2rem;
  line-height: 1;
}
.trust-item h4 {
  font-size: 0.95rem;
  font-weight: 700;
  color: var(--ink);
}
.trust-item p {
  font-size: 0.82rem;
  color: var(--gray-600);
  line-height: 1.5;
}

/* ============================================================
   CART
   ============================================================ */
.cart-section { background: var(--white); }

.cart-layout {
  display: grid;
  grid-template-columns: 1fr 360px;
  gap: 40px;
  align-items: start;
}

/* Cart items */
.cart-items {
  display: flex;
  flex-direction: column;
  gap: 16px;
}
.cart-item {
  display: flex;
  align-items: center;
  gap: 20px;
  padding: 20px;
  background: var(--gray-50);
  border-radius: var(--radius-md);
  border: 1px solid var(--gray-100);
  transition: box-shadow var(--transition);
}
.cart-item:hover { box-shadow: var(--shadow-md); }
.cart-item-img {
  width: 88px;
  height: 88px;
  object-fit: cover;
  border-radius: var(--radius-sm);
  flex-shrink: 0;
  background: var(--gray-100);
}
.cart-item-info { flex: 1; min-width: 0; }
.cart-item-cat {
  font-size: 0.7rem;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: 4px;
}
.cart-item-name {
  font-family: var(--font-display);
  font-size: 1rem;
  font-weight: 600;
  color: var(--ink);
  margin-bottom: 4px;
}
.cart-item-price {
  font-size: 0.875rem;
  color: var(--gray-600);
}
.cart-item-controls {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
}
.qty-box {
  display: flex;
  align-items: center;
  gap: 0;
  border: 1.5px solid var(--gray-200);
  border-radius: var(--radius-sm);
  overflow: hidden;
}
.qty-btn {
  width: 32px;
  height: 32px;
  background: var(--white);
  color: var(--ink);
  font-size: 1rem;
  font-weight: 500;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background var(--transition);
}
.qty-btn:hover { background: var(--gray-100); }
.qty-val {
  width: 36px;
  text-align: center;
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--ink);
  border-left: 1px solid var(--gray-200);
  border-right: 1px solid var(--gray-200);
  line-height: 32px;
}
.remove-btn {
  background: none;
  color: var(--gray-400);
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.05em;
  transition: color var(--transition);
  padding: 2px 4px;
}
.remove-btn:hover { color: var(--red); }
.cart-item-total {
  font-size: 1.05rem;
  font-weight: 700;
  color: var(--ink);
  min-width: 72px;
  text-align: right;
}

/* Cart Summary */
.cart-summary {
  background: var(--gray-50);
  border: 1px solid var(--gray-100);
  border-radius: var(--radius-md);
  padding: 28px;
  display: flex;
  flex-direction: column;
  gap: 16px;
  position: sticky;
  top: calc(var(--header-h) + 20px);
}
.summary-title {
  font-family: var(--font-display);
  font-size: 1.3rem;
  font-weight: 700;
  color: var(--ink);
  padding-bottom: 16px;
  border-bottom: 1px solid var(--gray-200);
}
.summary-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 0.9rem;
  color: var(--gray-600);
}
.summary-total {
  font-size: 1.1rem;
  font-weight: 700;
  color: var(--ink);
}
.summary-divider {
  height: 1px;
  background: var(--gray-200);
  margin: 4px 0;
}
.coupon-box {
  display: flex;
  gap: 8px;
}
.coupon-input {
  flex: 1;
  padding: 10px 14px;
  border: 1.5px solid var(--gray-200);
  border-radius: var(--radius-sm);
  font-size: 0.85rem;
  outline: none;
  transition: border-color var(--transition);
  background: var(--white);
}
.coupon-input:focus { border-color: var(--accent); }
.coupon-btn {
  padding: 10px 16px;
  background: var(--ink);
  color: var(--white);
  border-radius: var(--radius-sm);
  font-size: 0.82rem;
  font-weight: 600;
  transition: all var(--transition);
  white-space: nowrap;
}
.coupon-btn:hover { background: var(--accent); }
.cart-helper-text {
  font-size: 0.8rem;
  color: var(--gray-600);
  min-height: 1.2em;
}

/* ============================================================
   CHECKOUT
   ============================================================ */
.checkout-section { background: var(--cream); }

.checkout-layout {
  display: grid;
  grid-template-columns: 1fr 400px;
  gap: 40px;
  align-items: start;
}
.checkout-form-wrap {
  display: flex;
  flex-direction: column;
  gap: 24px;
}
.form-card {
  background: var(--white);
  border: 1px solid var(--gray-100);
  border-radius: var(--radius-md);
  padding: 32px;
}
.form-card-title {
  font-family: var(--font-display);
  font-size: 1.2rem;
  font-weight: 700;
  color: var(--ink);
  margin-bottom: 24px;
  padding-bottom: 16px;
  border-bottom: 1px solid var(--gray-100);
}
.form-group {
  display: flex;
  flex-direction: column;
  gap: 6px;
  margin-bottom: 20px;
}
.form-group:last-child { margin-bottom: 0; }
.form-label {
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--gray-600);
  letter-spacing: 0.05em;
  text-transform: uppercase;
}
.form-input {
  padding: 12px 16px;
  border: 1.5px solid var(--gray-200);
  border-radius: var(--radius-sm);
  font-size: 0.9rem;
  color: var(--ink);
  background: var(--gray-50);
  outline: none;
  transition: all var(--transition);
}
.form-input:focus {
  border-color: var(--accent);
  background: var(--white);
  box-shadow: 0 0 0 3px rgba(45,90,39,0.1);
}
.form-input::placeholder { color: var(--gray-400); }

.form-row { display: grid; gap: 16px; }
.form-row-2 { grid-template-columns: 1fr 1fr; }
.form-row-3 { grid-template-columns: 1fr 1fr 1fr; }

/* Payment options */
.payment-options {
  display: flex;
  flex-direction: column;
  gap: 12px;
}
.payment-option {
  cursor: pointer;
}
.payment-option input[type="radio"] {
  position: absolute;
  opacity: 0;
  pointer-events: none;
}
.payment-option-box {
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 16px 20px;
  border: 1.5px solid var(--gray-200);
  border-radius: var(--radius-sm);
  background: var(--gray-50);
  transition: all var(--transition);
  cursor: pointer;
}
.payment-option input:checked + .payment-option-box {
  border-color: var(--accent);
  background: var(--accent-bg);
  box-shadow: 0 0 0 3px rgba(45,90,39,0.1);
}
.payment-option-box:hover {
  border-color: var(--accent);
}
.payment-icon { font-size: 1.5rem; flex-shrink: 0; }
.payment-option-box strong {
  display: block;
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--ink);
  margin-bottom: 2px;
}
.payment-option-box p {
  font-size: 0.78rem;
  color: var(--gray-400);
}

.btn-place-order {
  font-size: 1rem;
  padding: 16px 32px;
  letter-spacing: 0.05em;
}

/* Checkout order review */
.checkout-order-review { position: sticky; top: calc(var(--header-h) + 20px); }

.review-item {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 14px 0;
  border-bottom: 1px solid var(--gray-100);
}
.review-item:last-of-type { border-bottom: none; }
.review-item img {
  width: 56px;
  height: 56px;
  object-fit: cover;
  border-radius: var(--radius-sm);
  flex-shrink: 0;
}
.review-item-name {
  font-size: 0.875rem;
  font-weight: 600;
  color: var(--ink);
}
.review-item-meta {
  font-size: 0.78rem;
  color: var(--gray-400);
  margin-top: 2px;
}
.review-item-price {
  font-size: 0.9rem;
  font-weight: 700;
  color: var(--ink);
  margin-left: auto;
  flex-shrink: 0;
}

/* ============================================================
   FOOTER
   ============================================================ */
.site-footer {
  background: var(--ink);
  color: rgba(255,255,255,0.7);
}
.footer-top { padding: 72px 0; }
.footer-grid {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr 1.4fr;
  gap: 48px;
}
.footer-tagline {
  font-size: 0.875rem;
  line-height: 1.7;
  color: rgba(255,255,255,0.55);
  margin-top: 16px;
  max-width: 280px;
}
.social-links {
  display: flex;
  gap: 12px;
  margin-top: 24px;
}
.social-link {
  width: 38px;
  height: 38px;
  border-radius: 50%;
  border: 1px solid rgba(255,255,255,0.2);
  display: flex;
  align-items: center;
  justify-content: center;
  color: rgba(255,255,255,0.6);
  transition: all var(--transition);
}
.social-link:hover {
  border-color: var(--gold);
  color: var(--gold);
  background: rgba(184,151,58,0.1);
}
.social-link svg { width: 16px; height: 16px; }

.footer-col-title {
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--white);
  margin-bottom: 20px;
}
.footer-links {
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.footer-links a {
  font-size: 0.875rem;
  color: rgba(255,255,255,0.55);
  transition: color var(--transition);
}
.footer-links a:hover { color: var(--white); }

.footer-contact-list {
  display: flex;
  flex-direction: column;
  gap: 14px;
}
.footer-contact-list li {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  font-size: 0.85rem;
  color: rgba(255,255,255,0.55);
  line-height: 1.5;
}
.footer-contact-list li svg { flex-shrink: 0; margin-top: 2px; }

/* Footer bottom */
.footer-bottom {
  border-top: 1px solid rgba(255,255,255,0.08);
  padding: 20px 0;
}
.footer-bottom .container {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 16px;
  flex-wrap: wrap;
}
.footer-bottom p {
  font-size: 0.8rem;
  color: rgba(255,255,255,0.35);
}
.footer-legal {
  display: flex;
  gap: 24px;
}
.footer-legal a {
  font-size: 0.8rem;
  color: rgba(255,255,255,0.35);
  transition: color var(--transition);
}
.footer-legal a:hover { color: rgba(255,255,255,0.7); }

/* ============================================================
   RESPONSIVE — TABLET (≤ 1024px)
   ============================================================ */
@media (max-width: 1024px) {
  .product-grid       { grid-template-columns: repeat(3, 1fr); }
  .category-grid      { grid-template-columns: repeat(2, 1fr); }
  .detail-layout      { grid-template-columns: 1fr; }
  .cart-layout        { grid-template-columns: 1fr; }
  .cart-summary       { position: static; }
  .checkout-layout    { grid-template-columns: 1fr; }
  .checkout-order-review { position: static; }
  .footer-grid        { grid-template-columns: 1fr 1fr; gap: 36px; }
  .trust-grid         { grid-template-columns: repeat(2, 1fr); gap: 24px; }
  .main-nav           { display: none; }
  .header-search      { display: none; }
  .hamburger          { display: flex; }
}

/* ============================================================
   RESPONSIVE — MOBILE (≤ 640px)
   ============================================================ */
@media (max-width: 640px) {
  :root { --header-h: 60px; }
  .logo-img { height: 52px; }
  .headline { font-size: 24px; }
  
  .header-inner {
    padding: 0 16px;
    gap: 12px;
  }
  
  .site-header {
    position: relative;
  }

  .section { padding: 64px 0; }
  .section-head { margin-bottom: 36px; }

  /* Hero */
  .hero { min-height: 90vh; }
  .hero-actions {
    width: 100%;
    flex-direction: column;
    align-items: center;
  }
  .hero-actions .btn {
    width: min(260px, 100%);
    justify-content: center;
  }
  .hero-scroll-hint { display: none; }

  /* Categories */
  .category-grid { grid-template-columns: repeat(2, 1fr); gap: 14px; }

  /* Promo banner */
  .promo-banner { flex-direction: column; }
  .promo-img-wrap { flex: none; max-width: 100%; height: 220px; }
  .promo-content { padding: 40px 24px; }

  /* Products */
  .product-grid { grid-template-columns: repeat(2, 1fr); gap: 14px; }
  .product-info { padding: 14px 14px; }
  .product-footer { flex-direction: column; align-items: flex-start; gap: 10px; }
  .btn-cart { width: 100%; justify-content: center; }
  .detail-content { padding: 24px; }
  .detail-specs { grid-template-columns: 1fr; }
  .detail-label-row { flex-direction: column; align-items: flex-start; }
  .detail-theme-electronics .detail-media { padding: 12px 12px 16px; }
  .detail-theme-electronics .detail-image-frame {
    min-height: 360px;
    padding: 10px 42px;
    border-radius: 22px;
  }
  .detail-theme-electronics .detail-gallery-nav {
    width: 42px;
    height: 42px;
  }
  .detail-theme-electronics .detail-thumb {
    flex-basis: 96px;
    border-radius: 16px;
  }
  .detail-theme-electronics .detail-content {
    padding: 22px 18px;
  }

  /* Trust */
  .trust-grid { grid-template-columns: repeat(2, 1fr); gap: 20px; }

  /* Cart */
  .cart-item {
    flex-wrap: wrap;
    gap: 14px;
  }
  .cart-item-img { width: 72px; height: 72px; }
  .cart-item-total { margin-left: auto; }

  /* Checkout */
  .form-row-2, .form-row-3 { grid-template-columns: 1fr; }
  .form-card { padding: 24px; }

  /* Footer */
  .footer-grid { grid-template-columns: 1fr; gap: 28px; }
  .footer-top  { padding: 48px 0; }
  .footer-bottom .container { flex-direction: column; align-items: flex-start; }
}

/* ============================================================
   TINY SCREEN (≤ 380px)
   ============================================================ */
@media (max-width: 380px) {
  .product-grid   { grid-template-columns: 1fr; }
  .category-grid  { grid-template-columns: 1fr; }
  .detail-theme-electronics .detail-image-frame {
    min-height: 300px;
    padding-inline: 38px;
  }
  .detail-theme-electronics .detail-thumbs {
    gap: 12px;
  }
  .detail-theme-electronics .detail-thumb {
    flex-basis: 82px;
  }
}
