/* ============================================================
   TugaKits — Main Storefront Styles
   Colors: Portugal — dark burgundy (#2b0a14), red (#e4002b), gold (#f4c430)
   Fonts: Barlow Condensed (display/headings) + Barlow (body)
   ============================================================ */

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

/* ── Reset & Base ── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

:root {
  --navy: #2b0a14;
  --navy-light: #3d1220;
  --navy-mid: #4e1a2c;
  --white: #ffffff;
  --primary: #e4002b;
  --primary-dark: #c10024;
  --gold: #f4c430;
  --gold-dark: #d4a800;
  --grey-100: #f5f5f5;
  --grey-200: #e8e8e8;
  --grey-300: #d1d1d1;
  --grey-400: #999;
  --grey-500: #666;
  --red: #ff4757;
  --yellow: #ffc107;
  --blue: #2196f3;
  --purple: #9c27b0;
  --font-display: 'Barlow Condensed', sans-serif;
  --radius: 8px;
  --shadow: 0 2px 12px rgba(0,0,0,0.08);
  --shadow-lg: 0 8px 32px rgba(0,0,0,0.12);
  --transition: 0.2s ease;
}

html { scroll-behavior: smooth; }

body {
  font-family: 'Barlow', -apple-system, BlinkMacSystemFont, sans-serif;
  color: var(--navy);
  background: var(--white);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

a { color: inherit; text-decoration: none; }
img { max-width: 100%; height: auto; display: block; }
button { cursor: pointer; font-family: inherit; border: none; }
input, select, textarea { font-family: inherit; }

/* ── Loading Spinner ── */
.spinner {
  display: flex;
  justify-content: center;
  align-items: center;
  padding: 3rem;
}
.spinner::after {
  content: '';
  width: 36px;
  height: 36px;
  border: 3px solid var(--grey-200);
  border-top-color: var(--primary);
  border-radius: 50%;
  animation: spin 0.7s linear infinite;
}
@keyframes spin { to { transform: rotate(360deg); } }

/* ── Toast Notification ── */
.toast {
  position: fixed;
  bottom: 2rem;
  left: 50%;
  transform: translateX(-50%) translateY(20px);
  padding: 0.75rem 1.5rem;
  border-radius: var(--radius);
  color: var(--white);
  font-weight: 500;
  font-size: 0.9rem;
  z-index: 10000;
  opacity: 0;
  transition: opacity 0.3s ease, transform 0.3s ease;
  white-space: nowrap;
}
.toast.show { opacity: 1; transform: translateX(-50%) translateY(0); }
.toast-success { background: var(--primary-dark); color: var(--navy); }
.toast-error { background: var(--red); }
.toast-info { background: var(--blue); }

/* ── Modal ── */
.modal-overlay {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.5);
  align-items: center;
  justify-content: center;
  z-index: 9999;
}
.modal-overlay.active { display: flex; }
.modal {
  background: var(--white);
  border-radius: var(--radius);
  padding: 2rem;
  max-width: 480px;
  width: 90%;
  max-height: 90vh;
  overflow-y: auto;
  box-shadow: 0 8px 32px rgba(0,0,0,0.2);
}
.modal-title-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 1rem;
}
.modal-title-row h3 { margin: 0; font-size: 1.2rem; }
.modal-close-btn {
  background: none;
  border: none;
  font-size: 1.5rem;
  line-height: 1;
  cursor: pointer;
  color: var(--grey-500, #6b7280);
  padding: 0 0.25rem;
}
.modal-close-btn:hover { color: var(--navy); }
.modal-actions {
  display: flex;
  gap: 0.75rem;
  justify-content: flex-end;
  margin-top: 1.5rem;
  flex-wrap: wrap;
}

/* ── Navbar ── */
.navbar {
  position: sticky;
  top: 0;
  z-index: 1000;
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 0.6rem 2rem;
  background: #0d1b2a;
  color: var(--white);
}
.navbar-logo {
  display: flex;
  align-items: center;
  line-height: 1;
  text-decoration: none;
}
.navbar-logo-img {
  height: 64px;
  width: auto;
  display: block;
}
.navbar-logo-text {
  display: none;
}
@media (max-width: 480px) {
  .navbar-logo-img { height: 50px; }
}
.navbar-links { display: flex; gap: 2rem; align-items: center; }
.navbar-links a {
  color: var(--white);
  font-weight: 500;
  font-size: 0.9rem;
  transition: color var(--transition);
}
.navbar-links a:hover { color: var(--gold); }

/* ── Admin Link ── */
.admin-link {
  color: var(--gold) !important;
  font-weight: 600 !important;
  border: 1px solid var(--gold);
  padding: 0.25rem 0.75rem;
  border-radius: var(--radius);
  font-size: 0.85rem;
}
.admin-link:hover {
  background: var(--gold);
  color: var(--navy) !important;
}

/* ── User Auth ── */
.user-auth {
  display: flex;
  align-items: center;
}
.btn-sign-in {
  background: var(--gold);
  color: var(--navy);
  border: none;
  padding: 0.4rem 1rem;
  border-radius: var(--radius);
  font-weight: 600;
  font-size: 0.85rem;
  cursor: pointer;
  transition: background var(--transition);
}
.btn-sign-in:hover { background: var(--gold-dark); }
.user-menu {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}
.user-avatar {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  border: 2px solid var(--gold);
}
.user-name {
  color: var(--white);
  font-size: 0.85rem;
  font-weight: 500;
  max-width: 120px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.btn-sign-out {
  background: transparent;
  color: var(--grey-300);
  border: 1px solid var(--grey-400);
  padding: 0.25rem 0.6rem;
  border-radius: var(--radius);
  font-size: 0.75rem;
  cursor: pointer;
  transition: all var(--transition);
}
.btn-sign-out:hover {
  color: var(--white);
  border-color: var(--white);
}

/* ── Cart / Find-List Icon ── */
.cart-icon {
  position: relative;
  display: flex;
  align-items: center;
  color: var(--white);
  text-decoration: none;
  transition: color var(--transition);
}
.cart-icon:hover { color: var(--gold); }
.cart-icon svg {
  width: 30px;
  height: 30px;
}
.cart-badge {
  position: absolute;
  top: -7px;
  right: -10px;
  min-width: 19px;
  height: 19px;
  padding: 0 4px;
  background: #e53935;
  color: #fff;
  font-size: 0.68rem;
  font-weight: 700;
  line-height: 19px;
  border-radius: 10px;
  text-align: center;
  display: none;
  box-shadow: 0 0 0 2px #0d1b2a;
}
.cart-badge:not(:empty) { display: block; }

@keyframes cart-badge-pop {
  0%   { transform: scale(1); }
  35%  { transform: scale(1.6); }
  65%  { transform: scale(0.88); }
  100% { transform: scale(1); }
}
@keyframes cart-icon-shake {
  0%, 100% { transform: rotate(0deg); }
  20%       { transform: rotate(-12deg); }
  40%       { transform: rotate(10deg); }
  60%       { transform: rotate(-8deg); }
  80%       { transform: rotate(5deg); }
}
.cart-badge.pop {
  animation: cart-badge-pop 0.45s cubic-bezier(0.36, 0.07, 0.19, 0.97) both;
}
.cart-icon.shake svg {
  animation: cart-icon-shake 0.45s ease both;
}

.hamburger {
  display: none;
  flex-direction: column;
  gap: 5px;
  background: none;
  padding: 4px;
}
.hamburger span {
  width: 24px;
  height: 2px;
  background: var(--white);
  border-radius: 2px;
  transition: var(--transition);
}

/* ── Splash Screen ── */
#splash {
  position: fixed;
  inset: 0;
  z-index: 10001;
  background: #0d1b2a;
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 1;
  transition: opacity 0.6s ease;
}
#splash.hidden { opacity: 0; pointer-events: none; }
#splash.gone   { display: none; }
#splash-logo {
  width: 280px;
  height: 280px;
  object-fit: contain;
  animation: splashPop 0.5s ease forwards;
}
@keyframes splashPop {
  from { transform: scale(0.85); opacity: 0; }
  to   { transform: scale(1);    opacity: 1; }
}

/* ── Hero Section ── */
.hero {
  background: var(--navy);
  color: var(--white);
  min-height: 92vh;
  display: flex;
  align-items: stretch;
  overflow: hidden;
  position: relative;
}
.hero-inner {
  display: grid;
  grid-template-columns: 1fr 1fr;
  width: 100%;
  min-height: 92vh;
}

/* Left copy panel */
.hero-copy {
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: 5rem 4rem 5rem 6vw;
  background: var(--navy);
  background-image: repeating-linear-gradient(
    90deg,
    transparent,
    transparent 59px,
    rgba(255,255,255,0.018) 59px,
    rgba(255,255,255,0.018) 60px
  );
  position: relative;
  z-index: 1;
  animation: heroFadeUp 0.55s ease both;
}
@keyframes heroFadeUp {
  from { opacity: 0; transform: translateY(28px); }
  to   { opacity: 1; transform: translateY(0); }
}
@media (prefers-reduced-motion: reduce) {
  .hero-copy { animation: none; }
}

.hero-eyebrow {
  font-family: var(--font-display);
  font-size: 0.78rem;
  font-weight: 600;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--gold);
  margin-bottom: 1rem;
}
.hero-headline {
  font-family: var(--font-display);
  font-size: clamp(3.5rem, 5.5vw, 6rem);
  font-weight: 700;
  line-height: 1.0;
  letter-spacing: -0.01em;
  margin-bottom: 1.4rem;
  color: var(--white);
}
.hero-accent {
  color: var(--gold);
  display: block;
}
.hero-sub {
  font-size: 1.05rem;
  color: var(--grey-300);
  line-height: 1.65;
  max-width: 420px;
  margin-bottom: 2rem;
}
.hero-actions {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 0.75rem;
  margin-bottom: 2.5rem;
}

/* Stats bar */
.hero-stats {
  display: flex;
  align-items: center;
  gap: 1.25rem;
}
.hero-stat {
  display: flex;
  flex-direction: column;
  gap: 0.15rem;
}
.hero-stat-num {
  font-family: var(--font-display);
  font-size: 1.65rem;
  font-weight: 700;
  color: var(--gold);
  line-height: 1;
}
.hero-stat-label {
  font-size: 0.72rem;
  font-weight: 500;
  color: var(--grey-400);
  text-transform: uppercase;
  letter-spacing: 0.1em;
}
.hero-stat-divider {
  width: 1px;
  height: 2rem;
  background: rgba(255,255,255,0.15);
}

/* Right visual panel */
.hero-visual {
  position: relative;
  background: var(--primary);
  clip-path: polygon(8% 0, 100% 0, 100% 100%, 0 100%);
  overflow: hidden;
}
.hero-visual::before {
  content: '';
  position: absolute;
  inset: 0;
  background: repeating-linear-gradient(
    0deg,
    transparent,
    transparent 39px,
    rgba(0,0,0,0.08) 39px,
    rgba(0,0,0,0.08) 40px
  ),
  repeating-linear-gradient(
    90deg,
    transparent,
    transparent 39px,
    rgba(0,0,0,0.06) 39px,
    rgba(0,0,0,0.06) 40px
  );
  background-size: 40px 40px;
  pointer-events: none;
}
.hero-visual::after {
  content: '';
  position: absolute;
  inset: 0;
  background: radial-gradient(ellipse at 60% 40%, rgba(255,255,255,0.07) 0%, transparent 70%);
  pointer-events: none;
}
.hero-visual-inner {
  position: relative;
  z-index: 1;
  height: 100%;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 3rem 2rem 3rem 5rem;
}
.hero-visual-logo {
  width: clamp(180px, 24vw, 300px);
  height: auto;
  filter: drop-shadow(0 8px 32px rgba(0,0,0,0.4)) drop-shadow(0 2px 8px rgba(0,0,0,0.25));
  animation: heroLogoFloat 6s ease-in-out infinite;
}
@keyframes heroLogoFloat {
  0%, 100% { transform: translateY(0); }
  50%       { transform: translateY(-10px); }
}
.hero-badge {
  position: absolute;
  top: 2rem;
  right: 2rem;
  background: var(--gold);
  color: var(--navy);
  font-family: var(--font-display);
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  padding: 0.45rem 1rem;
  border-radius: 100px;
  white-space: nowrap;
}

/* Mobile */
@media (max-width: 768px) {
  .hero-inner {
    grid-template-columns: 1fr;
    grid-template-rows: auto 260px;
    min-height: unset;
  }
  .hero {
    min-height: unset;
  }
  .hero-copy {
    padding: 3.5rem 1.5rem 2rem;
    align-items: center;
    text-align: center;
  }
  .hero-headline { font-size: clamp(3rem, 10vw, 4.5rem); }
  .hero-sub { max-width: 100%; }
  .hero-actions { align-items: center; }
  .hero-stats { justify-content: center; }
  .hero-visual {
    clip-path: polygon(0 8%, 100% 0, 100% 100%, 0 100%);
  }
  .hero-visual-inner { padding: 2rem 1.5rem; }
  .hero-badge { top: 1rem; right: 1rem; }
}
.hero .btn:not(.btn-hero) {
  padding: 0.5rem 1.35rem;
  font-size: 0.64rem;
}
.btn {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.75rem 2rem;
  border-radius: var(--radius);
  font-weight: 600;
  font-size: 0.95rem;
  transition: all var(--transition);
}
.btn-primary {
  background: var(--primary);
  color: var(--white);
}
.btn-primary:hover {
  background: var(--primary-dark);
  transform: translateY(-1px);
  box-shadow: 0 4px 16px rgba(228, 0, 43, 0.3);
}
.btn-hero {
  font-size: 1.15rem;
  padding: 0.9rem 2.5rem;
  letter-spacing: 0.02em;
}
.btn-secondary {
  background: transparent;
  color: var(--white);
  border: 2px solid var(--white);
}
.btn-secondary:hover {
  background: var(--white);
  color: var(--navy);
}
.btn-ghost {
  background: transparent;
  color: var(--navy);
  border: 2px solid var(--navy);
}
.btn-ghost:hover {
  background: var(--navy);
  color: var(--white);
}
.btn-danger {
  background: var(--red);
  color: var(--white);
}
.btn-danger:hover { opacity: 0.9; }
.btn-sm { padding: 0.4rem 1rem; font-size: 0.85rem; }
.btn-outline {
  background: transparent;
  border: 2px solid var(--navy);
  color: var(--navy);
}
.btn-outline:hover {
  background: var(--navy);
  color: var(--white);
}
.clear-filters-btn {
  white-space: nowrap;
  background: var(--red) !important;
  color: var(--white) !important;
  font-weight: 600;
  padding: 0.5rem 1rem !important;
}
.clear-filters-btn:hover {
  background: #ff3341 !important;
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(255, 71, 87, 0.3);
}

.btn:disabled {
  opacity: 0.5;
  cursor: not-allowed;
  transform: none !important;
}

/* ── Hero Secondary CTA ── */
.hero-secondary-cta {
  display: inline-block;
  font-size: 0.9rem;
  color: rgba(255,255,255,0.55);
  transition: color var(--transition);
  cursor: pointer;
}
.hero-secondary-cta:hover { color: var(--gold); }

/* ── Section Titles ── */
.section {
  padding: 4rem 2rem;
  max-width: 1200px;
  margin: 0 auto;
}
.section-title {
  font-family: var(--font-display);
  font-size: 2rem;
  font-weight: 700;
  text-align: center;
  margin-bottom: 0.5rem;
  letter-spacing: 0.01em;
}
.section-subtitle {
  text-align: center;
  color: var(--grey-500);
  margin-bottom: 2.5rem;
}

/* ── Product Card Grid ── */
.product-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
  gap: 1.5rem;
}
.product-card {
  background: var(--white);
  border: 1px solid var(--grey-200);
  border-radius: var(--radius);
  overflow: hidden;
  transition: all var(--transition);
  position: relative;
  cursor: pointer;
}
.product-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-lg);
  border-color: var(--gold);
}
.product-card-img {
  width: 100%;
  aspect-ratio: 1;
  object-fit: cover;
  background: var(--grey-100);
}
.product-card-body {
  padding: 1rem;
}
.product-card-name {
  font-weight: 600;
  font-size: 0.9rem;
  margin-bottom: 0.25rem;
  overflow: hidden;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
}
.product-card-meta {
  font-size: 0.8rem;
  color: var(--grey-500);
  margin-bottom: 0.5rem;
}
.product-card-price {
  font-weight: 700;
  font-size: 1.1rem;
  color: var(--navy);
  margin-bottom: 0.5rem;
}

/* ── Badges ── */
.badge {
  display: inline-block;
  padding: 0.2rem 0.6rem;
  border-radius: 4px;
  font-size: 0.7rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}
.badge-pre {
  position: absolute;
  top: 0.75rem;
  right: 0.75rem;
  background: var(--yellow);
  color: var(--navy);
}
.badge-special-order {
  position: absolute;
  top: 0.75rem;
  right: 0.75rem;
  background: #6c5ce7;
  color: #fff;
}
.badge-featured {
  position: absolute;
  top: 0.75rem;
  left: 0.75rem;
  background: var(--primary);
  color: var(--navy);
}
.badge-trending {
  position: absolute;
  top: 0.75rem;
  left: 0.75rem;
  background: var(--gold);
  color: var(--navy);
}
.badge-pending { background: var(--yellow); color: var(--navy); }
.badge-confirmed, .badge-approved { background: var(--blue); color: var(--white); }
.badge-shipped { background: var(--purple); color: var(--white); }
.badge-delivered, .badge-received { background: var(--primary-dark); color: var(--navy); }
.badge-rejected { background: var(--red); color: var(--white); }
.badge-draft { background: var(--grey-300); color: var(--navy); }
.badge-partial { background: #ff9800; color: var(--white); }
.badge-sent { background: var(--blue); color: var(--white); }
.badge-paid { background: var(--primary-dark); color: var(--navy); }
.badge-warning { background: #ff9800; color: var(--white); cursor: default; }

/* ── How It Works ── */
.how-it-works {
  background: var(--grey-100);
  padding: 3rem 1.5rem;
}
.steps {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(165px, 1fr));
  gap: 1.5rem;
  max-width: 675px;
  margin: 0 auto;
}
.step {
  text-align: center;
  padding: 1.5rem 1.1rem;
  background: var(--white);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
}
.step-number {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: var(--gold);
  color: var(--navy);
  font-weight: 700;
  font-size: 0.9rem;
  margin-bottom: 0.75rem;
}
.step h3 { font-family: var(--font-display); font-size: 1.1rem; font-weight: 700; margin-bottom: 0.375rem; letter-spacing: 0.02em; }
.step p { font-size: 0.875rem; color: var(--grey-500); }

/* ── Filters Bar ── */
.filters {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  margin-bottom: 2rem;
  position: sticky;
  top: 68px;
  z-index: 100;
  background: var(--white);
  padding: 0.75rem 0;
  margin-left: -2rem;
  margin-right: -2rem;
  padding-left: 2rem;
  padding-right: 2rem;
  border-bottom: 1px solid var(--grey-200);
  box-shadow: 0 2px 8px rgba(0,0,0,0.06);
}
.filters select, .filters input {
  padding: 0.5rem 0.75rem;
  border: 1px solid var(--grey-300);
  border-radius: var(--radius);
  font-size: 0.85rem;
  background: var(--white);
}
.filters select:focus, .filters input:focus {
  outline: 2px solid var(--navy);
  outline-offset: 2px;
  border-color: var(--navy);
}
.filter-search { width: 140px; height: auto; line-height: normal; }
.filter-select { width: 130px; }
.filter-price-chips {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 6px;
}
.chips-label {
  font-size: 0.78rem;
  color: var(--grey-400);
  white-space: nowrap;
  margin-right: 2px;
}
.price-chip {
  padding: 4px 12px;
  border: 1px solid var(--grey-300);
  border-radius: 20px;
  background: var(--white);
  font-size: 0.78rem;
  cursor: pointer;
  transition: background 0.15s, border-color 0.15s, color 0.15s;
  line-height: 1.4;
}
.price-chip:hover {
  border-color: var(--primary);
  color: var(--primary);
}
.price-chip--active {
  background: var(--primary);
  border-color: var(--primary);
  color: var(--white);
}
.filter-toggle {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.85rem;
  font-weight: 500;
}
.toggle-switch {
  position: relative;
  width: 40px;
  height: 22px;
}
.toggle-switch input { opacity: 0; width: 0; height: 0; }
.toggle-slider {
  position: absolute;
  inset: 0;
  background: var(--grey-300);
  border-radius: 22px;
  cursor: pointer;
  transition: var(--transition);
}
.toggle-slider::before {
  content: '';
  position: absolute;
  width: 16px;
  height: 16px;
  left: 3px;
  top: 3px;
  background: var(--white);
  border-radius: 50%;
  transition: var(--transition);
}
.toggle-switch input:checked + .toggle-slider { background: var(--primary); }
.toggle-switch input:checked + .toggle-slider::before { transform: translateX(18px); }

/* ── Catalog Filter Rows ── */
.catalog-filter-row-1 {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  width: 100%;
  align-items: center;
}
.catalog-filter-row-2 {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  width: 100%;
  align-items: center;
}

/* ── Active Filter Highlighting ── */
.filter-select:focus {
  outline: none;
  border-color: var(--navy);
}
.filter-select[data-filtered="true"] {
  background: #a3e4d7;
  border-color: #7dd5c8;
  font-weight: 500;
}
.filter-select[data-filtered="true"]:focus {
  outline: none;
  border-color: #7dd5c8;
}

/* ── Shared tree picker (catalog + admin inventory/products) ── */
.treepick-host {
  position: relative;
  display: inline-block;
  width: 180px;
}
.treepick-button {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.5rem;
  padding: 0.4rem 0.6rem;
  background: #fff;
  border: 1px solid #ccc;
  border-radius: 4px;
  font-size: 0.9rem;
  font-family: inherit;
  cursor: pointer;
  text-align: left;
  line-height: 1.2;
}
.treepick-host[data-filtered="true"] .treepick-button {
  background: #a3e4d7;
  border-color: #7dd5c8;
  font-weight: 500;
}
.treepick-label {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  flex: 1;
}
.treepick-caret {
  color: #666;
  font-size: 0.8em;
}
.treepick-panel {
  position: absolute;
  top: calc(100% + 2px);
  left: 0;
  z-index: 50;
  min-width: 280px;
  max-height: 420px;
  overflow-y: auto;
  background: #fff;
  border: 1px solid #ccc;
  border-radius: 4px;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
  padding: 0.25rem 0;
}
.treepick-node {
  display: block;
  width: 100%;
  text-align: left;
  border: 0;
  background: transparent;
  padding: 0.35rem 0.75rem 0.35rem 0.5rem;
  font: inherit;
  cursor: pointer;
  color: inherit;
}
.treepick-node:hover { background: #f0f4f7; }
.treepick-node.treepick-inactive { color: #999; font-style: italic; }
.treepick-toggle {
  display: inline-block;
  width: 1em;
  text-align: center;
  color: #888;
}
.treepick-toggle.treepick-leaf { visibility: hidden; }
.treepick-children { border-left: 1px dashed #e0e0e0; margin-left: 0.75rem; }

/* ── Product Detail Page ── */
.product-detail {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 3rem;
  max-width: 1100px;
  margin: 0 auto;
  padding: 2rem;
}
.carousel {
  position: relative;
  border-radius: var(--radius);
  overflow: hidden;
  background: var(--grey-100);
}
.carousel-img {
  width: 100%;
  aspect-ratio: 1;
  object-fit: cover;
}
.carousel-btn {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  background: rgba(0,0,0,0.5);
  color: var(--white);
  width: 40px;
  height: 40px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.2rem;
  transition: var(--transition);
}
.carousel-btn:hover { background: rgba(0,0,0,0.8); }
.carousel-prev { left: 1rem; }
.carousel-next { right: 1rem; }
.carousel-dots {
  display: flex;
  justify-content: center;
  gap: 0.5rem;
  padding: 1rem;
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
}
.carousel-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: rgba(255,255,255,0.5);
  cursor: pointer;
  transition: var(--transition);
}
.carousel-dot.active { background: var(--white); }

.product-info h1 {
  font-family: var(--font-display);
  font-size: 2rem;
  font-weight: 700;
  margin-bottom: 0.5rem;
  letter-spacing: 0.01em;
}
.product-info .meta {
  font-size: 0.9rem;
  color: var(--grey-500);
  margin-bottom: 1rem;
}
.product-info .price {
  font-size: 2rem;
  font-weight: 700;
  color: var(--navy);
  margin-bottom: 1.5rem;
}
.stock-badge {
  display: inline-block;
  padding: 0.4rem 1rem;
  border-radius: var(--radius);
  font-weight: 600;
  font-size: 0.85rem;
  margin-bottom: 1.5rem;
}
.stock-badge--instock { background: #e8f5e9; color: #2e7d32; }
.stock-badge--preorder { background: #fff8e1; color: #f57f17; }
.stock-badge--oos { background: #e3f2fd; color: #1565c0; }
.stock-badge--soldout { background: #ffebee; color: #c62828; }

.badge-soldout {
  position: absolute;
  top: 0.75rem;
  right: 0.75rem;
  background: #c62828;
  color: #fff;
}

.prod-stock-badge {
  display: inline-block;
  padding: 0.15rem 0.5rem;
  border-radius: 3px;
  font-size: 0.7rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.4px;
  margin-left: 0.5rem;
}
.prod-stock-badge--in { background: #e8f5e9; color: #2e7d32; }
.prod-stock-badge--soldout { background: #ffebee; color: #c62828; }
.prod-stock-badge--archive { background: #eceff1; color: #546e7a; }

.size-label {
  font-size: 0.75rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--grey-400);
  margin-bottom: 0.4rem;
}
.size-selector {
  display: flex;
  gap: 0.5rem;
  margin-bottom: 0.5rem;
  flex-wrap: wrap;
}
.size-guide-link {
  display: inline-block;
  font-size: 0.8rem;
  color: var(--primary);
  text-decoration: underline;
  margin-bottom: 1.25rem;
}
.size-option {
  padding: 0.5rem 1.2rem;
  border: 2px solid var(--grey-300);
  border-radius: var(--radius);
  font-weight: 600;
  font-size: 0.9rem;
  background: var(--white);
  transition: var(--transition);
}
.size-option:hover:not(:disabled) {
  border-color: var(--primary);
}
.size-option.active {
  border-color: var(--primary);
  background: var(--primary);
  color: var(--navy);
}
.size-option:disabled {
  opacity: 0.35;
  cursor: not-allowed;
  text-decoration: line-through;
}
.size-preorder-label {
  font-size: 0.65rem;
  display: block;
  color: var(--yellow);
  font-weight: 500;
}

.qty-selector {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  margin-bottom: 1.5rem;
}
.qty-selector label { font-weight: 500; }
.qty-selector select {
  padding: 0.5rem;
  border: 1px solid var(--grey-300);
  border-radius: var(--radius);
}

.customization {
  margin-bottom: 1.5rem;
}
.customization-toggle {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  cursor: pointer;
  font-size: 0.95rem;
  font-weight: 600;
  margin-bottom: 0.75rem;
  user-select: none;
}
.customization-toggle input[type="checkbox"] {
  width: 1.1rem;
  height: 1.1rem;
  accent-color: var(--primary);
  cursor: pointer;
}
.customization-fee-badge {
  background: var(--gold);
  color: var(--navy);
  font-size: 0.75rem;
  font-weight: 700;
  padding: 0.15rem 0.5rem;
  border-radius: 999px;
}
.customization-fields {
  display: flex;
  gap: 1rem;
}
.customization-fields input {
  flex: 1;
  padding: 0.5rem 0.75rem;
  border: 1px solid var(--grey-300);
  border-radius: var(--radius);
  font-size: 0.9rem;
}
.customization-fields input:focus {
  outline: 2px solid var(--primary);
  outline-offset: 2px;
  border-color: var(--primary);
}
.customization-fee-label {
  color: var(--gold-dark);
  font-weight: 600;
}

/* ── Cart Page ── */
.cart-container {
  max-width: 900px;
  margin: 0 auto;
  padding: 2rem;
}
.cart-empty {
  text-align: center;
  padding: 4rem 2rem;
}
.cart-empty p { color: var(--grey-500); margin-bottom: 1.5rem; font-size: 1.1rem; }
.cart-items { margin-bottom: 2rem; }
.cart-item {
  display: grid;
  grid-template-columns: 80px 1fr auto auto;
  gap: 1rem;
  align-items: center;
  padding: 1rem 0;
  border-bottom: 1px solid var(--grey-200);
}
.cart-item-img {
  width: 80px;
  height: 80px;
  object-fit: cover;
  border-radius: var(--radius);
  background: var(--grey-100);
}
.cart-item-name { font-weight: 600; }
.cart-item-details { font-size: 0.85rem; color: var(--grey-500); }
.cart-item-qty select {
  padding: 0.4rem;
  border: 1px solid var(--grey-300);
  border-radius: 4px;
}
.cart-item-price { font-weight: 700; min-width: 70px; text-align: right; }
.cart-item-remove {
  background: none;
  color: var(--red);
  font-size: 1.2rem;
  padding: 0.25rem;
}

.cart-summary {
  background: var(--grey-100);
  padding: 1.5rem;
  border-radius: var(--radius);
  margin-bottom: 2rem;
}
.cart-summary-row {
  display: flex;
  justify-content: space-between;
  padding: 0.4rem 0;
}
.cart-summary-total {
  font-weight: 700;
  font-size: 1.2rem;
  border-top: 2px solid var(--grey-300);
  padding-top: 0.75rem;
  margin-top: 0.5rem;
}

/* ── Forms ── */
.form-section {
  background: var(--white);
  border: 1px solid var(--grey-200);
  border-radius: var(--radius);
  padding: 2rem;
}
.form-section h2 { font-size: 1.3rem; margin-bottom: 1.5rem; }
.form-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1rem;
  margin-bottom: 1rem;
}
.form-group { margin-bottom: 1rem; }
.form-group label {
  display: block;
  font-weight: 500;
  font-size: 0.85rem;
  margin-bottom: 0.3rem;
}
.form-group label .required { color: var(--red); }
.form-group input,
.form-group textarea,
.form-group select {
  width: 100%;
  padding: 0.6rem 0.75rem;
  border: 1px solid var(--grey-300);
  border-radius: var(--radius);
  font-size: 0.9rem;
  transition: border var(--transition);
}
.form-group input:focus,
.form-group textarea:focus,
.form-group select:focus {
  outline: 2px solid var(--primary);
  outline-offset: 2px;
  border-color: var(--primary);
}
.form-group textarea { resize: vertical; min-height: 80px; }
.whatsapp-flag {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.9rem;
  color: var(--grey-600);
  margin-bottom: 1rem;
  cursor: pointer;
}
.whatsapp-flag input[type="checkbox"] { width: auto; margin: 0; cursor: pointer; }

/* ── Kit Request (Product Page) ── */
.request-hint {
  font-size: 0.85rem;
  color: var(--grey-400);
  margin-top: 0.5rem;
}
.request-form {
  margin-top: 1.5rem;
  padding-top: 1.5rem;
  border-top: 1px solid var(--grey-200);
}
.request-form-intro {
  font-size: 0.9rem;
  color: var(--grey-500);
  margin-bottom: 1.25rem;
}
.request-success {
  text-align: center;
  padding: 2rem 0;
}
.request-success h3 {
  font-size: 1.3rem;
  margin: 0.75rem 0 0.5rem;
}
.request-success p {
  color: var(--grey-500);
  margin-bottom: 1.5rem;
}

/* ── Confirmation Page ── */
.confirmation {
  max-width: 600px;
  margin: 0 auto;
  padding: 4rem 2rem;
  text-align: center;
}
.confirmation-icon {
  width: 80px;
  height: 80px;
  background: var(--primary);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 1.5rem;
  font-size: 2rem;
}
.confirmation h1 { font-size: 1.8rem; margin-bottom: 0.5rem; }
.confirmation .ref-number {
  background: var(--grey-100);
  padding: 1rem;
  border-radius: var(--radius);
  font-family: monospace;
  font-size: 1.1rem;
  margin: 1.5rem 0;
}
.confirmation-items {
  text-align: left;
  background: var(--grey-100);
  border-radius: var(--radius);
  padding: 1rem 1.5rem;
  margin: 1.5rem 0;
}
.confirmation-items li {
  padding: 0.4rem 0;
  border-bottom: 1px solid var(--grey-200);
  list-style: none;
}
.confirmation-items li:last-child { border-bottom: none; }
.confirmation .message {
  color: var(--grey-500);
  margin: 1.5rem 0;
  font-size: 1rem;
  line-height: 1.6;
}

/* ── Footer ── */
.footer {
  background: var(--navy);
  color: var(--grey-300);
  padding: 3rem 2rem;
  text-align: center;
}
.footer a { color: var(--gold); }
.footer a:hover { text-decoration: underline; }
.footer-links {
  display: flex;
  justify-content: center;
  gap: 2rem;
  margin-bottom: 1rem;
}
.footer p { font-size: 0.85rem; }

/* ── Confirm Dialog ── */
.dialog-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.5);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 9999;
}
.dialog {
  background: var(--white);
  border-radius: var(--radius);
  padding: 2rem;
  max-width: 440px;
  width: 90%;
  box-shadow: var(--shadow-lg);
}
.dialog h3 { margin-bottom: 1rem; }
.dialog-actions {
  display: flex;
  gap: 0.75rem;
  justify-content: flex-end;
  margin-top: 1.5rem;
}

/* ── Catalog background-load banner ── */
.catalog-loading-more {
  text-align: center;
  padding: 0.75rem;
  color: var(--grey-500);
  font-size: 0.875rem;
}

/* ── No Results ── */
.no-results {
  text-align: center;
  padding: 3rem;
  color: var(--grey-500);
}

/* ── Mobile ── */
@media (max-width: 768px) {
  .navbar { padding: 0.75rem 1rem; }
  .navbar-links { display: none; }
  .navbar-links.open {
    display: flex;
    flex-direction: column;
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: var(--navy);
    padding: 1rem 2rem;
    gap: 1rem;
  }
  .hamburger { display: flex; }

  .hero { padding: 3rem 1.5rem; }
  .btn-hero { font-size: 1rem; padding: 0.75rem 1.75rem; letter-spacing: 0.02em; }
  .product-detail { grid-template-columns: 1fr; gap: 1.5rem; padding: 1rem; }
  .product-grid { grid-template-columns: repeat(auto-fill, minmax(160px, 1fr)); gap: 1rem; }

  .catalog-filter-row-1 input,
  .catalog-filter-row-1 select { width: auto; }
  .form-row { grid-template-columns: 1fr; }

  .cart-item {
    grid-template-columns: 60px 1fr;
    gap: 0.75rem;
  }
  .cart-item-qty, .cart-item-price { grid-column: 2; }
  .cart-item-remove { grid-column: 2; justify-self: end; }

  .filters { flex-direction: column; align-items: stretch; }
  .filters select, .filters input { width: 100%; }
  .catalog-filter-row-1 input,
  .catalog-filter-row-1 select { width: auto !important; }
  .filter-search { width: 100%; }
  .catalog-filter-row-1 .filter-search { width: 140px !important; }
  .filter-price-chips { width: 100%; }
}

/* ===== Newsletter Signup ===== */
.catalog-notify-row { margin: 0.75rem 0 1.25rem; text-align: center; }
.notify-btn {
  background: #0a1628;
  border: none;
  color: #fff;
  padding: 0.6rem 1.25rem;
  border-radius: 24px;
  font-size: 0.9rem;
  font-weight: 600;
  cursor: pointer;
  transition: background 0.2s;
  white-space: nowrap;
}
.notify-btn:hover {
  background: #1a2e4a;
}

/* Newsletter Modal */
.newsletter-overlay {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.65);
  z-index: 500;
  align-items: center;
  justify-content: center;
  padding: 1rem;
}
.newsletter-overlay.active { display: flex; }
.newsletter-box {
  background: #fff;
  border-radius: 12px;
  box-shadow: 0 8px 40px rgba(0,0,0,0.3);
  width: 100%;
  max-width: 400px;
}
.newsletter-box-header {
  background: linear-gradient(135deg, #0a1628, #1a2e4a);
  color: #fff;
  padding: 1.1rem 1.5rem;
  border-radius: 12px 12px 0 0;
  display: flex;
  justify-content: space-between;
  align-items: center;
}
.newsletter-box-header h2 { font-size: 1.05rem; margin: 0; }
.newsletter-close {
  background: none;
  border: none;
  color: #fff;
  font-size: 1.5rem;
  cursor: pointer;
  line-height: 1;
  opacity: 0.85;
  padding: 0.25rem 0.5rem;
  border-radius: 4px;
}
.newsletter-close:hover { opacity: 1; background: rgba(255,255,255,0.15); }
.newsletter-cancel {
  width: 100%;
  padding: 0.5rem;
  border: none;
  background: none;
  color: #6b7280;
  font-size: 0.85rem;
  cursor: pointer;
  margin-top: 0.4rem;
  border-radius: 6px;
}
.newsletter-cancel:hover { background: #f3f4f6; color: #374151; }
.newsletter-box-body { padding: 1.5rem; }
.newsletter-box-body p { font-size: 0.88rem; color: #6b7280; margin: 0 0 1rem; }
.newsletter-field { margin-bottom: 0.85rem; }
.newsletter-field label { display: block; font-size: 0.8rem; font-weight: 600; margin-bottom: 0.3rem; color: #374151; }
.newsletter-field input {
  width: 100%;
  padding: 0.6rem 0.85rem;
  border: 1.5px solid #d1d5db;
  border-radius: 8px;
  font-size: 0.9rem;
  font-family: inherit;
  box-sizing: border-box;
  transition: border-color 0.2s;
}
.newsletter-field input:focus { outline: 2px solid var(--gold, #d4af37); outline-offset: 2px; border-color: var(--gold, #d4af37); }
.newsletter-submit {
  width: 100%;
  padding: 0.75rem;
  border: none;
  border-radius: 8px;
  background: #0a1628;
  color: #fff;
  font-size: 0.95rem;
  font-weight: 700;
  cursor: pointer;
  transition: background 0.2s;
  margin-top: 0.25rem;
}
.newsletter-submit:hover:not(:disabled) { background: #1a2e4a; }
.newsletter-submit:disabled { opacity: 0.6; cursor: not-allowed; }
.newsletter-msg { font-size: 0.85rem; margin: 0.6rem 0 0; display: none; }
.newsletter-msg.error { color: #dc3545; }
.newsletter-msg.success { color: #22c55e; font-weight: 600; }

/* ── Motion animation initial states ── */
/* Elements start hidden; motion-effects.js animates them in */
.hero-badge,
.hero-visual-number,
.hero-visual-sub {
  opacity: 0;
  transform: translateY(16px);
}
.step {
  opacity: 0;
  transform: translateY(24px);
}
.section .section-title,
.section .section-subtitle {
  opacity: 0;
  transform: translateY(20px);
}
.product-card {
  opacity: 0;
  transform: translateY(20px);
}

/* ── Reduced Motion ── */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: 0.01ms !important; transition-duration: 0.01ms !important; }
  #splash-logo { animation: none; }
  .product-card:hover { transform: none; }
  html { scroll-behavior: auto; }
  .hero-badge, .hero-visual-number, .hero-visual-sub,
  .step,
  .section .section-title, .section .section-subtitle,
  .product-card {
    opacity: 1 !important;
    transform: none !important;
  }
}
