/* ==========================================================================
   3DFuse Official Design System (v1.0)
   Aesthetic: Industrial Additive Manufacturing, High-Contrast Graphite & Orange
   ========================================================================== */

:root {
  /* Core Brand & Industrial Charcoal Theme Tokens (Bambu Lab / Prusa / Linear Standard) */
  --brand-primary: #FF6B00;
  --brand-primary-hover: #FF8126;
  --brand-primary-soft: rgba(255, 107, 0, 0.11);
  --background: #0B0C0E;
  --surface: #121418;
  --surface-elevated: #181B21;
  --border: #242830;
  --border-subtle: rgba(255, 255, 255, 0.07);
  --text: #F4F4F6;
  --text-muted: #989EA8;
  --success: #10B981;
  --warning: #F59E0B;
  --danger: #EF4444;
  --info: #3B82F6;

  /* Spacing Scale */
  --space-1: 0.25rem;
  --space-2: 0.5rem;
  --space-3: 0.75rem;
  --space-4: 1rem;
  --space-5: 1.25rem;
  --space-6: 1.5rem;
  --space-8: 2rem;
  --space-10: 2.5rem;
  --space-12: 3rem;
  --space-16: 4rem;

  /* Border Radius Tokens — Crisp Architectural Geometry */
  --radius-sm: 6px;
  --radius-md: 8px;
  --radius-lg: 12px;
  --radius-xl: 16px;
  --radius-full: 9999px;

  /* Elevation & Shadows — Subtle Tonal & Crisp Borders */
  --shadow-sm: 0 1px 3px rgba(0, 0, 0, 0.4), 0 1px 2px rgba(0, 0, 0, 0.3);
  --shadow-md: 0 8px 24px rgba(0, 0, 0, 0.55);
  --shadow-lg: 0 20px 44px rgba(0, 0, 0, 0.72);
  --shadow-glow: 0 0 0 1px rgba(255, 107, 0, 0.35), 0 6px 18px rgba(255, 107, 0, 0.18);

  /* Typography */
  --font-sans: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  --font-mono: 'JetBrains Mono', ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;

  /* Transitions & Interactive States */
  --transition-fast: 140ms cubic-bezier(0.22, 1, 0.36, 1);
  --transition-normal: 220ms cubic-bezier(0.22, 1, 0.36, 1);
  --focus-ring: 0 0 0 2px rgba(255, 107, 0, 0.42);
  --disabled-opacity: 0.45;
}

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

[hidden] {
  display: none !important;
}

html {
  font-size: 16px;
  scroll-behavior: smooth;
  background-color: var(--background);
  color: var(--text);
  font-family: var(--font-sans);
  font-feature-settings: 'cv02', 'cv03', 'cv04', 'cv11';
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

body {
  min-height: 100vh;
  background-color: var(--background);
  color: var(--text);
  line-height: 1.5;
  letter-spacing: -0.008em;
  overflow-x: clip;
}

h1,
h2,
h3,
h4 {
  letter-spacing: -0.024em;
  line-height: 1.22;
  color: var(--text);
}

a {
  color: inherit;
  text-decoration: none;
  transition: color var(--transition-fast);
}

a:focus-visible,
button:focus-visible,
input:focus-visible,
select:focus-visible,
textarea:focus-visible {
  outline: none;
  box-shadow: var(--focus-ring);
}

/* ================= LAYOUT CONTAINERS ================= */
.container {
  width: 100%;
  max-width: 1320px;
  margin: 0 auto;
  padding: 0 var(--space-4);
}

@media (min-width: 768px) {
  .container {
    padding: 0 var(--space-6);
  }
}

/* ================= HEADER (PUBLIC) & CATEGORIES DROPDOWN ================= */
.site-header {
  position: sticky;
  top: 0;
  z-index: 1000;
  background: rgba(9, 9, 11, 0.94);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border-bottom: 1px solid var(--border);
  transition: box-shadow var(--transition-normal), border-color var(--transition-normal), background var(--transition-normal);
}

.site-header.scrolled {
  background: rgba(9, 9, 11, 0.98);
  border-bottom-color: rgba(255, 107, 0, 0.35);
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.72);
}

.header-inner {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  min-height: 64px;
  padding-top: 0.45rem;
  padding-bottom: 0.45rem;
  gap: 0.45rem var(--space-3);
  transition: gap 280ms cubic-bezier(0.4, 0, 0.2, 1);
}

.brand-logo {
  display: inline-flex;
  align-items: center;
  gap: var(--space-2);
  flex-shrink: 0;
  transition: transform 260ms cubic-bezier(0.4, 0, 0.2, 1);
}

.brand-logo img {
  height: 36px;
  width: auto;
  border-radius: 6px;
}

@media (min-width: 768px) {
  .brand-logo img {
    height: 44px;
  }
}

.nav-links {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.35rem;
  order: 3;
  width: 100%;
  padding-top: 0.4rem;
  border-top: 1px solid rgba(255, 255, 255, 0.06);
  justify-content: flex-start;
  overflow: visible;
  transition: all 280ms cubic-bezier(0.4, 0, 0.2, 1);
}

@media (min-width: 768px) {
  .nav-links {
    order: 0;
    width: auto;
    padding-top: 0;
    border-top: none;
    justify-content: flex-start;
    overflow: visible;
    flex-wrap: nowrap;
    gap: var(--space-3);
  }
}

.nav-link {
  font-size: 0.82rem;
  font-weight: 600;
  color: var(--text-muted);
  padding: 0.35rem 0.6rem;
  border-radius: var(--radius-sm);
  background: transparent;
  border: none;
  cursor: pointer;
  font-family: var(--font-sans);
  display: inline-flex;
  align-items: center;
  gap: 0.25rem;
  white-space: nowrap;
  transition: all 260ms cubic-bezier(0.4, 0, 0.2, 1);
}

@media (min-width: 768px) {
  .nav-link {
    font-size: 0.93rem;
    padding: var(--space-2) var(--space-3);
  }
}

/* Compress header writings when search magnifier expands to the left */
.header-inner.search-expanded .nav-links {
  gap: 0.15rem;
}

.header-inner.search-expanded .nav-link {
  font-size: 0.8rem;
  padding: 0.28rem 0.45rem;
  letter-spacing: -0.02em;
}

.header-inner.search-expanded .brand-logo {
  transform: scale(0.93);
  transform-origin: left center;
}

.header-inner.search-expanded #header-account-btn {
  padding: 0.3rem 0.55rem;
  font-size: 0.76rem;
}

@media (max-width: 767px) {
  .header-inner {
    padding-top: 0.5rem;
    padding-bottom: 0.5rem;
    gap: 0.45rem 0.4rem;
  }
  .brand-logo img {
    height: 32px;
  }
  .header-actions {
    flex-wrap: wrap;
    justify-content: flex-end;
    gap: 0.32rem;
    max-width: 100%;
  }
  .header-actions .btn-sm {
    min-height: 32px;
    padding: 0.26rem 0.52rem;
    font-size: 0.73rem;
    white-space: nowrap;
  }
  .nav-links {
    justify-content: space-between;
    gap: 0.25rem;
  }
  .nav-link {
    font-size: 0.78rem;
    padding: 0.32rem 0.5rem;
  }
  .header-inner.search-expanded #header-account-btn {
    display: none;
  }
}

.nav-link:hover,
.nav-link.active {
  color: var(--text);
  background: var(--surface-elevated);
}

/* Click-to-Toggle Dropdown for Categories (Strictly controlled by .open) */
.nav-dropdown {
  position: relative;
  display: inline-flex;
  align-items: center;
}

.nav-dropdown-trigger {
  user-select: none;
}

.nav-dropdown-caret {
  font-size: 0.72rem;
  transition: transform var(--transition-fast), color var(--transition-fast);
}

.nav-dropdown.open .nav-dropdown-caret {
  transform: rotate(180deg);
  color: var(--brand-primary);
}

.nav-dropdown-menu {
  position: absolute;
  top: calc(100% + 6px);
  left: 0;
  min-width: 240px;
  max-width: calc(100vw - 2rem);
  background: var(--surface-elevated);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-lg);
  padding: 0.4rem;
  display: flex;
  flex-direction: column;
  gap: 0.12rem;
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transform: translateY(4px);
  transition: opacity var(--transition-fast), transform var(--transition-fast), visibility var(--transition-fast);
  z-index: 2500;
}

.nav-dropdown.open .nav-dropdown-menu {
  opacity: 1;
  visibility: visible;
  pointer-events: auto;
  transform: translateY(0);
}

@media (max-width: 767px) {
  .nav-dropdown-menu {
    left: 50%;
    transform: translate(-50%, 4px);
    min-width: 220px;
  }
  .nav-dropdown.open .nav-dropdown-menu {
    transform: translate(-50%, 0);
  }
}

.nav-dropdown-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0.5rem 0.75rem;
  border-radius: var(--radius-sm);
  font-size: 0.85rem;
  font-weight: 500;
  color: var(--text-muted);
  transition: background var(--transition-fast), color var(--transition-fast);
}

.nav-dropdown-item:hover,
.nav-dropdown-item.active {
  background: var(--brand-primary-soft);
  color: var(--brand-primary);
  font-weight: 600;
}

.header-actions {
  display: flex;
  align-items: center;
  gap: 0.45rem;
}

@media (min-width: 768px) {
  .header-actions {
    gap: var(--space-3);
  }
}

/* ================= REUSABLE BUTTONS (Section 3) ================= */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.45rem;
  min-height: 40px;
  padding: 0.55rem 1.1rem;
  font-family: var(--font-sans);
  font-size: 0.875rem;
  font-weight: 600;
  letter-spacing: -0.005em;
  border-radius: var(--radius-md);
  border: 1px solid transparent;
  cursor: pointer;
  transition: background var(--transition-fast), border-color var(--transition-fast), color var(--transition-fast), box-shadow var(--transition-fast), transform var(--transition-fast);
  white-space: nowrap;
  user-select: none;
}

.btn:disabled {
  opacity: var(--disabled-opacity);
  cursor: not-allowed;
}

.btn-primary {
  background: var(--brand-primary);
  color: #0B0C0E;
  font-weight: 600;
}

.btn-primary:hover:not(:disabled) {
  background: var(--brand-primary-hover);
  box-shadow: var(--shadow-glow);
}

.btn-secondary {
  background: var(--surface-elevated);
  color: var(--text);
  border-color: var(--border);
}

.btn-secondary:hover:not(:disabled) {
  background: #1F232B;
  border-color: rgba(255, 255, 255, 0.22);
  color: #FFFFFF;
}

.btn-danger {
  background: rgba(239, 68, 68, 0.1);
  color: #FCA5A5;
  border-color: rgba(239, 68, 68, 0.28);
}

.btn-danger:hover:not(:disabled) {
  background: var(--danger);
  border-color: var(--danger);
  color: #FFFFFF;
}

.btn-sm {
  min-height: 34px;
  padding: 0.35rem 0.78rem;
  font-size: 0.8rem;
}

.btn-block {
  width: 100%;
}

/* ================= FORMS: INPUT, SELECT, TEXTAREA, SWITCH ================= */
.form-group {
  display: flex;
  flex-direction: column;
  gap: 0.38rem;
  margin-bottom: 0.95rem;
}

.form-label {
  font-size: 0.8rem;
  font-weight: 600;
  color: #D4D7DD;
  letter-spacing: 0.005em;
}

.form-input,
.form-select,
.form-textarea {
  width: 100%;
  min-height: 40px;
  padding: 0.55rem 0.8rem;
  background: var(--background);
  color: var(--text);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  font-family: var(--font-sans);
  font-size: 0.88rem;
  color-scheme: dark;
  transition: border-color var(--transition-fast), box-shadow var(--transition-fast), background var(--transition-fast);
}

.form-select option {
  background-color: var(--surface-elevated);
  color: var(--text);
}

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

.form-input:hover,
.form-select:hover,
.form-textarea:hover {
  border-color: #363C48;
}

.form-input:focus,
.form-select:focus,
.form-textarea:focus {
  border-color: var(--brand-primary);
  box-shadow: var(--focus-ring);
}

.form-input:disabled,
.form-select:disabled,
.form-textarea:disabled {
  opacity: var(--disabled-opacity);
  cursor: not-allowed;
}

.form-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 0.85rem;
}

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

/* ================= CARDS, KPI CARDS, PRICE CARDS ================= */
.card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 1.25rem;
  box-shadow: var(--shadow-sm);
}

.card-elevated {
  background: var(--surface-elevated);
}

.kpi-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 0.85rem;
}

@media (min-width: 640px) {
  .kpi-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (min-width: 1024px) {
  .kpi-grid {
    grid-template-columns: repeat(4, 1fr);
  }
}

.kpi-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 1.15rem 1.25rem;
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
  position: relative;
  overflow: hidden;
}

.kpi-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 3px;
  height: 100%;
  background: var(--brand-primary);
}

.kpi-label {
  font-size: 0.72rem;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--text-muted);
  font-weight: 600;
}

.kpi-value {
  font-size: 1.55rem;
  font-weight: 700;
  color: var(--text);
  font-family: var(--font-mono);
  font-variant-numeric: tabular-nums;
}

.kpi-sub {
  font-size: 0.76rem;
  color: var(--text-muted);
}

/* ================= BADGES & STATUS BADGES ================= */
.badge {
  display: inline-flex;
  align-items: center;
  gap: 0.3rem;
  padding: 0.2rem 0.55rem;
  font-size: 0.7rem;
  font-weight: 600;
  border-radius: var(--radius-sm);
  letter-spacing: 0.04em;
  text-transform: uppercase;
  font-variant-numeric: tabular-nums;
}

.badge-brand {
  background: rgba(255, 107, 0, 0.12);
  color: #FF852B;
  border: 1px solid rgba(255, 107, 0, 0.28);
}

.badge-success {
  background: rgba(16, 185, 129, 0.12);
  color: #34D399;
  border: 1px solid rgba(16, 185, 129, 0.28);
}

.badge-warning {
  background: rgba(245, 158, 11, 0.12);
  color: #FBBF24;
  border: 1px solid rgba(245, 158, 11, 0.28);
}

.badge-danger {
  background: rgba(239, 68, 68, 0.12);
  color: #F87171;
  border: 1px solid rgba(239, 68, 68, 0.28);
}

.badge-info {
  background: rgba(59, 130, 246, 0.12);
  color: #60A5FA;
  border: 1px solid rgba(59, 130, 246, 0.28);
}

.badge-neutral {
  background: var(--surface-elevated);
  color: var(--text-muted);
  border: 1px solid var(--border);
}

/* ================= HERO SECTION ================= */
.hero {
  padding: var(--space-10) 0 var(--space-8);
  border-bottom: 1px solid var(--border);
  background: radial-gradient(circle at 80% 20%, rgba(255, 107, 0, 0.13), transparent 55%);
}

.hero-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--space-8);
  align-items: center;
}

@media (min-width: 1024px) {
  .hero-grid {
    grid-template-columns: 1.2fr 0.8fr;
  }
}

.hero-eyebrow {
  display: inline-flex;
  align-items: center;
  gap: var(--space-2);
  padding: 0.35rem 0.85rem;
  border-radius: var(--radius-full);
  background: var(--brand-primary-soft);
  color: var(--brand-primary);
  font-size: 0.8rem;
  font-weight: 700;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  margin-bottom: var(--space-4);
}

.hero-title {
  font-size: clamp(2rem, 4.5vw, 3.35rem);
  font-weight: 800;
  line-height: 1.1;
  letter-spacing: -0.03em;
  margin-bottom: var(--space-4);
}

.hero-title span {
  color: var(--brand-primary);
}

.hero-subtitle {
  font-size: 1.05rem;
  color: var(--text-muted);
  max-width: 600px;
  margin-bottom: var(--space-6);
}

.hero-ctas {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-3);
}

/* ================= ROTATING HERO BANNER CAROUSEL & E-COMMERCE PRODUCT GRID ================= */
.hero-banner-section {
  padding: 0.85rem 0 0.5rem;
}

@media (min-width: 768px) {
  .hero-banner-section {
    padding: 1.35rem 0 0.75rem;
  }
}

.hero-carousel {
  position: relative;
  width: 100%;
  border-radius: var(--radius-lg);
  overflow: hidden;
  border: 1px solid var(--border);
  background: #0D0D12;
  box-shadow: var(--shadow-md);
  aspect-ratio: 1320 / 420;
  min-height: 120px;
  max-height: 420px;
}

@media (min-width: 768px) {
  .hero-carousel {
    aspect-ratio: 1320 / 420;
    border-radius: var(--radius-xl);
  }
}

.hero-slide {
  position: absolute;
  inset: 0;
  opacity: 0;
  pointer-events: none;
  transition: opacity 480ms ease-in-out;
  display: flex;
  align-items: flex-end;
  justify-content: flex-start;
}

.hero-slide.active {
  opacity: 1;
  pointer-events: auto;
  z-index: 2;
}

.hero-slide-img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  object-position: center;
  display: block;
  background: #0D0D12;
}

@media (min-width: 768px) {
  .hero-slide-img {
    object-fit: cover;
  }
}

.production-leadtime-banner {
  padding: 0.75rem 0.95rem;
  border-radius: var(--radius-md);
  border: 1px solid rgba(255, 107, 0, 0.38);
  background: rgba(255, 107, 0, 0.09);
  color: var(--text);
  font-size: 0.85rem;
  line-height: 1.4;
}

.production-leadtime-banner strong {
  color: var(--brand-primary);
}

.hero-slide-caption {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  padding: 0.45rem 0.75rem 1.35rem;
  background: linear-gradient(to top, rgba(9, 9, 11, 0.92) 0%, rgba(9, 9, 11, 0.52) 60%, transparent 100%);
  display: flex;
  flex-direction: column;
  gap: 0.15rem;
}

@media (max-width: 639px) {
  .hero-slide-title {
    font-size: 0.82rem;
  }
  .hero-slide-subtitle {
    font-size: 0.68rem;
    -webkit-line-clamp: 1;
  }
  .hero-carousel-arrow {
    width: 28px;
    height: 28px;
    font-size: 1rem;
  }
}

@media (min-width: 768px) {
  .hero-slide-caption {
    padding: 1.5rem 2.25rem 2.35rem;
  }
}

.hero-slide-title {
  font-size: clamp(1rem, 2.5vw, 1.65rem);
  font-weight: 800;
  color: var(--text);
  line-height: 1.2;
  text-shadow: 0 2px 10px rgba(0, 0, 0, 0.8);
}

.hero-slide-subtitle {
  font-size: clamp(0.75rem, 1.5vw, 0.96rem);
  color: #D4D4D8;
  max-width: 720px;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.hero-carousel-arrow {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  z-index: 5;
  width: 34px;
  height: 34px;
  border-radius: 50%;
  border: 1px solid rgba(255, 255, 255, 0.22);
  background: rgba(9, 9, 11, 0.72);
  color: var(--text);
  font-size: 1.25rem;
  font-weight: 700;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: background var(--transition-fast), border-color var(--transition-fast);
}

@media (min-width: 768px) {
  .hero-carousel-arrow {
    width: 42px;
    height: 42px;
    font-size: 1.45rem;
  }
}

.hero-carousel-arrow:hover {
  background: var(--brand-primary);
  color: #09090B;
  border-color: var(--brand-primary);
}

.hero-carousel-arrow.prev {
  left: 0.6rem;
}

.hero-carousel-arrow.next {
  right: 0.6rem;
}

.hero-carousel-dots {
  position: absolute;
  bottom: 0.55rem;
  left: 50%;
  transform: translateX(-50%);
  z-index: 5;
  display: flex;
  align-items: center;
  gap: 0.45rem;
  padding: 0.25rem 0.6rem;
  border-radius: var(--radius-full);
  background: rgba(9, 9, 11, 0.65);
}

.hero-carousel-dot {
  width: 8px;
  height: 8px;
  border-radius: var(--radius-full);
  border: none;
  background: rgba(255, 255, 255, 0.35);
  cursor: pointer;
  padding: 0;
  transition: all var(--transition-fast);
}

.hero-carousel-dot.active {
  width: 22px;
  background: var(--brand-primary);
}

.catalog-section {
  padding-top: 0.75rem;
}

.catalog-toolbar {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.65rem;
  margin: 0.75rem 0 1.15rem;
  padding: 0.85rem;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
}

.catalog-toolbar-search {
  grid-column: 1 / -1;
}

@media (min-width: 768px) {
  .catalog-toolbar {
    display: flex;
    flex-direction: row;
    align-items: center;
    justify-content: space-between;
    gap: var(--space-4);
    padding: var(--space-4);
    margin: var(--space-4) 0 var(--space-6);
  }
  .catalog-toolbar-search {
    flex: 1;
    min-width: 220px;
  }
  .catalog-toolbar-field:not(.catalog-toolbar-search) {
    min-width: 185px;
  }
}

/* Mobile-First 2-Column E-Commerce Product Grid (Mercado Livre / Shopee / Bambu Lab style) */
.product-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0.65rem;
  margin-bottom: var(--space-10);
}

@media (min-width: 640px) {
  .product-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: var(--space-5);
  }
}

@media (min-width: 960px) {
  .product-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: var(--space-6);
  }
}

@media (min-width: 1240px) {
  .product-grid {
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: var(--space-6);
  }
}

.product-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  overflow: hidden;
  display: flex;
  flex-direction: column;
  transition: transform var(--transition-normal), border-color var(--transition-normal), box-shadow var(--transition-normal);
}

@media (min-width: 768px) {
  .product-card {
    border-radius: var(--radius-lg);
  }
}

.product-card:hover {
  transform: translateY(-4px);
  border-color: rgba(255, 107, 0, 0.55);
  box-shadow: var(--shadow-md);
}

.product-thumb-wrap {
  position: relative;
  aspect-ratio: 1 / 1;
  background: #0D0D11;
  border-bottom: 1px solid var(--border);
  overflow: hidden;
}

.product-discount-badge {
  position: absolute;
  top: 0.55rem;
  left: 0.55rem;
  z-index: 3;
  padding: 0.2rem 0.55rem;
  border-radius: var(--radius-sm);
  background: var(--success);
  color: #09090B;
  font-family: var(--font-mono);
  font-size: 0.72rem;
  font-weight: 800;
  letter-spacing: 0.03em;
  box-shadow: var(--shadow-sm);
}

@media (min-width: 640px) {
  .product-thumb-wrap {
    aspect-ratio: 4 / 3;
  }
}

.product-thumb {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 300ms ease;
}

.product-card:hover .product-thumb {
  transform: scale(1.03);
}

.product-body {
  padding: 0.65rem;
  display: flex;
  flex-direction: column;
  flex: 1;
  gap: 0.35rem;
}

@media (min-width: 640px) {
  .product-body {
    padding: var(--space-4);
    gap: var(--space-2);
  }
}

.product-title {
  font-size: 0.88rem;
  font-weight: 700;
  color: var(--text);
  line-height: 1.3;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  min-height: 2.3em;
}

@media (min-width: 640px) {
  .product-title {
    font-size: 1.02rem;
  }
}

.product-short-desc {
  color: var(--text-muted);
  font-size: 0.78rem;
  line-height: 1.35;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

@media (max-width: 480px) {
  .product-short-desc {
    -webkit-line-clamp: 1;
    font-size: 0.74rem;
  }
}

.product-meta-list {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-2);
  font-size: 0.78rem;
  color: var(--text-muted);
}

.product-price-row {
  margin-top: auto;
  padding-top: 0.45rem;
  border-top: 1px solid var(--border);
  display: flex;
  flex-direction: column;
  align-items: stretch;
  gap: 0.45rem;
}

@media (min-width: 640px) {
  .product-price-row {
    padding-top: var(--space-3);
    flex-direction: row;
    align-items: center;
    justify-content: space-between;
  }
}

.product-price-stack {
  display: flex;
  flex-direction: column;
  gap: 0.1rem;
}

.product-price-original {
  font-size: 0.78rem;
  font-weight: 500;
  color: var(--text-muted);
  text-decoration: line-through;
  font-family: var(--font-mono);
  font-variant-numeric: tabular-nums;
}

.product-price-main-line {
  display: flex;
  align-items: center;
  gap: 0.45rem;
  flex-wrap: wrap;
}

.product-price {
  font-size: 1.05rem;
  font-weight: 800;
  color: var(--brand-primary);
  font-family: var(--font-mono);
  font-variant-numeric: tabular-nums;
}

@media (min-width: 640px) {
  .product-price {
    font-size: 1.25rem;
  }
}

.product-price-discount-tag {
  display: inline-flex;
  align-items: center;
  padding: 0.12rem 0.42rem;
  border-radius: 5px;
  background: rgba(16, 185, 129, 0.14);
  border: 1px solid rgba(16, 185, 129, 0.35);
  color: #34D399;
  font-family: var(--font-mono);
  font-size: 0.7rem;
  font-weight: 700;
}

.product-card-cta {
  width: 100%;
  font-size: 0.76rem;
  padding: 0.35rem 0.55rem;
  min-height: 32px;
}

@media (min-width: 640px) {
  .product-card-cta {
    width: auto;
    font-size: 0.8rem;
    padding: 0.38rem 0.75rem;
  }
}

/* Interactive Material & Color Pill Selector */
.selector-pills {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-2);
}

.pill-btn {
  padding: 0.35rem 0.7rem;
  font-size: 0.78rem;
  font-weight: 600;
  border-radius: var(--radius-sm);
  background: var(--background);
  color: var(--text-muted);
  border: 1px solid var(--border);
  cursor: pointer;
  transition: all var(--transition-fast);
}

.pill-btn:hover {
  border-color: var(--text-muted);
  color: var(--text);
}

.pill-btn.active {
  background: var(--brand-primary-soft);
  color: var(--brand-primary);
  border-color: var(--brand-primary);
}

/* ================= TABLES (RESPONSIVE) ================= */
.table-container {
  width: 100%;
  overflow-x: auto;
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  background: var(--surface);
}

.data-table {
  width: 100%;
  border-collapse: collapse;
  text-align: left;
  font-size: 0.9rem;
}

.data-table th {
  background: var(--surface-elevated);
  color: var(--text-muted);
  font-weight: 600;
  font-size: 0.78rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  padding: 0.85rem 1rem;
  border-bottom: 1px solid var(--border);
}

.data-table td {
  padding: 0.9rem 1rem;
  border-bottom: 1px solid var(--border);
  color: var(--text);
  vertical-align: middle;
}

.data-table tr:last-child td {
  border-bottom: none;
}

.data-table tr:hover td {
  background: rgba(255, 255, 255, 0.02);
}

/* ================= TIMELINE (Section 17 & 50) ================= */
.timeline {
  display: flex;
  flex-direction: column;
  gap: var(--space-4);
  margin: var(--space-4) 0;
}

.timeline-step {
  display: flex;
  align-items: flex-start;
  gap: var(--space-4);
  padding: var(--space-3) var(--space-4);
  border-radius: var(--radius-md);
  background: var(--background);
  border: 1px solid var(--border);
}

.timeline-step.done {
  border-color: rgba(16, 185, 129, 0.4);
}

.timeline-step.current {
  border-color: var(--brand-primary);
  background: var(--brand-primary-soft);
}

.timeline-marker {
  width: 28px;
  height: 28px;
  border-radius: var(--radius-full);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-weight: 800;
  font-size: 0.85rem;
  flex-shrink: 0;
  background: var(--surface-elevated);
  color: var(--text-muted);
}

.timeline-step.done .timeline-marker {
  background: var(--success);
  color: #09090B;
}

.timeline-step.current .timeline-marker {
  background: var(--brand-primary);
  color: #09090B;
}

/* ================= MODAL & CONFIRMATION DIALOG ================= */
.modal-backdrop {
  position: fixed;
  inset: 0;
  z-index: 250;
  background: rgba(0, 0, 0, 0.78);
  backdrop-filter: blur(4px);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: var(--space-4);
}

.modal-backdrop[hidden] {
  display: none !important;
}

.modal-box {
  width: 100%;
  max-width: 640px;
  max-height: 90vh;
  overflow-y: auto;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-xl);
  padding: var(--space-6);
  box-shadow: var(--shadow-lg);
}

.modal-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-4);
  margin-bottom: var(--space-4);
  padding-bottom: var(--space-3);
  border-bottom: 1px solid var(--border);
}

.modal-title {
  font-size: 1.2rem;
  font-weight: 700;
}

.modal-footer {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: var(--space-3);
  margin-top: var(--space-6);
  padding-top: var(--space-4);
  border-top: 1px solid var(--border);
}

/* ================= TOAST & ALERT ================= */
.toast-container {
  position: fixed;
  bottom: var(--space-5);
  right: var(--space-5);
  z-index: 400;
  display: flex;
  flex-direction: column;
  gap: var(--space-3);
  max-width: 380px;
}

.toast {
  padding: var(--space-4);
  border-radius: var(--radius-md);
  background: var(--surface-elevated);
  border-left: 4px solid var(--brand-primary);
  color: var(--text);
  box-shadow: var(--shadow-md);
  font-size: 0.9rem;
  font-weight: 500;
}

.toast-success {
  border-left-color: var(--success);
}

.toast-danger {
  border-left-color: var(--danger);
}

/* ================= ADMIN SHELL & SIDEBAR ================= */
.admin-layout {
  display: flex;
  min-height: 100vh;
}

.admin-sidebar {
  width: 265px;
  background: var(--surface);
  border-right: 1px solid var(--border);
  display: flex;
  flex-direction: column;
  flex-shrink: 0;
  position: fixed;
  top: 0;
  bottom: 0;
  left: 0;
  z-index: 150;
  transform: translateX(-100%);
  transition: transform var(--transition-normal);
}

.admin-sidebar.open {
  transform: translateX(0);
}

@media (min-width: 1024px) {
  .admin-sidebar {
    position: sticky;
    top: 0;
    height: 100vh;
    transform: translateX(0);
  }
}

.sidebar-brand {
  padding: var(--space-5);
  border-bottom: 1px solid var(--border);
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.sidebar-nav {
  padding: var(--space-4);
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
  overflow-y: auto;
  flex: 1;
}

.sidebar-btn {
  display: flex;
  align-items: center;
  gap: var(--space-3);
  width: 100%;
  padding: 0.7rem 0.9rem;
  border-radius: var(--radius-md);
  border: none;
  background: transparent;
  color: var(--text-muted);
  font-family: var(--font-sans);
  font-size: 0.9rem;
  font-weight: 600;
  text-align: left;
  cursor: pointer;
  transition: all var(--transition-fast);
}

.sidebar-btn:hover {
  background: var(--surface-elevated);
  color: var(--text);
}

.sidebar-btn.active {
  background: var(--brand-primary-soft);
  color: var(--brand-primary);
  border-left: 3px solid var(--brand-primary);
}

.admin-main {
  flex: 1;
  min-width: 0;
  display: flex;
  flex-direction: column;
}

.admin-topbar {
  min-height: 68px;
  padding: 0 var(--space-5);
  background: var(--surface);
  border-bottom: 1px solid var(--border);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-4);
}

.admin-content {
  padding: var(--space-5);
  max-width: 1440px;
  width: 100%;
  margin: 0 auto;
}

.mobile-menu-toggle {
  display: inline-flex;
}

@media (min-width: 1024px) {
  .mobile-menu-toggle {
    display: none;
  }
}

.price-breakdown-box {
  background: var(--background);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: var(--space-5);
  display: flex;
  flex-direction: column;
  gap: var(--space-3);
}

.price-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 0.92rem;
  color: var(--text-muted);
}

.price-row.highlight {
  padding-top: var(--space-3);
  border-top: 1px solid var(--border);
  font-size: 1.2rem;
  font-weight: 800;
  color: var(--brand-primary);
}

.empty-state {
  text-align: center;
  padding: var(--space-10) var(--space-4);
  color: var(--text-muted);
  border: 1px dashed var(--border);
  border-radius: var(--radius-lg);
}

/* ================= COLOR SWATCHES & CHIP SELECTORS ================= */
.color-dot {
  display: inline-block;
  width: 14px;
  height: 14px;
  border-radius: 50%;
  border: 1.5px solid rgba(255, 255, 255, 0.45);
  box-shadow: 0 0 0 1px rgba(0, 0, 0, 0.6);
  flex-shrink: 0;
  vertical-align: middle;
}

.chip-selector-grid {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
}

.chip-check {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  padding: 0.4rem 0.75rem;
  border-radius: var(--radius-md);
  border: 1px solid var(--border);
  background: var(--background);
  color: var(--text-muted);
  font-size: 0.85rem;
  font-weight: 600;
  cursor: pointer;
  user-select: none;
  transition: all var(--transition-fast);
}

.chip-check:hover {
  border-color: var(--brand-primary);
  color: var(--text);
}

.chip-check.selected {
  border-color: var(--brand-primary);
  background: var(--brand-primary-soft);
  color: var(--text);
  box-shadow: 0 0 0 1px var(--brand-primary);
}

/* ================= EXECUTIVE COMMERCIAL QUOTE PDF SHEET ================= */
.quote-pdf-sheet {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 1.75rem;
}

.quote-pdf-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  flex-wrap: wrap;
  gap: 1.25rem;
  padding-bottom: 1.25rem;
  margin-bottom: 1.25rem;
  border-bottom: 2px solid var(--brand-primary);
}

.quote-pdf-brand {
  display: flex;
  align-items: center;
  gap: 1rem;
}

.quote-pdf-logo {
  height: 48px;
  width: auto;
}

.quote-pdf-meta-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 1rem;
  margin-bottom: 1.25rem;
}

.quote-pdf-box {
  background: var(--background);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  padding: 0.9rem 1.1rem;
}

.quote-pdf-terms {
  margin-top: 1.25rem;
  padding-top: 1rem;
  border-top: 1px solid var(--border);
  font-size: 0.8rem;
  color: var(--text-muted);
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 1rem;
}

.quote-pdf-signatures {
  margin-top: 2rem;
  padding-top: 1.5rem;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 2rem;
  text-align: center;
  font-size: 0.82rem;
  color: var(--text-muted);
}

.quote-pdf-sig-line {
  border-top: 1px solid var(--border);
  padding-top: 0.45rem;
  margin-top: 1.5rem;
}

/* ================= PRINT / PDF EXPORT STYLES ================= */
@media print {
  @page {
    size: A4;
    margin: 12mm;
  }
  body {
    background: #ffffff !important;
    color: #111111 !important;
  }
  .admin-sidebar,
  .admin-topbar,
  .site-header,
  .toast-container,
  #close-admin-modal,
  .modal-header,
  .no-print,
  .admin-only-col {
    display: none !important;
  }
  .modal-backdrop:not([hidden]) {
    position: static !important;
    background: #ffffff !important;
    padding: 0 !important;
  }
  .modal-backdrop:not([hidden]) ~ *,
  body:has(.modal-backdrop:not([hidden])) .admin-layout {
    display: none !important;
  }
  .modal-dialog {
    max-width: 100% !important;
    max-height: none !important;
    padding: 0 !important;
    border: none !important;
    box-shadow: none !important;
    background: #ffffff !important;
    color: #111111 !important;
  }
  .quote-pdf-sheet {
    background: #ffffff !important;
    color: #111111 !important;
    border: 1px solid #d4d4d8 !important;
    padding: 1.25rem !important;
  }
  .quote-pdf-box,
  .price-breakdown-box {
    background: #f8fafc !important;
    color: #111111 !important;
    border: 1px solid #cbd5e1 !important;
  }
  .data-table th {
    background: #f1f5f9 !important;
    color: #0f172a !important;
    border-bottom: 2px solid #94a3b8 !important;
  }
  .data-table td {
    color: #1e293b !important;
    border-bottom: 1px solid #e2e8f0 !important;
  }
  .quote-pdf-terms,
  .quote-pdf-signatures,
  .price-row {
    color: #334155 !important;
  }
  .quote-pdf-sig-line {
    border-top-color: #475569 !important;
  }
  .printable-quote .btn {
    display: none !important;
  }
}

/* ================= HEADER MAGNIFIER SEARCH (LEFT EXPANSION ANIMATION) ================= */
.header-search-widget {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: flex-end;
}

.header-search-toggle {
  width: 38px;
  height: 38px;
  border-radius: var(--radius-full);
  border: 1px solid var(--border);
  background: var(--surface-elevated);
  color: var(--text);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  flex-shrink: 0;
  transition: all var(--transition-fast);
}

.header-search-toggle:hover,
.header-search-toggle.active,
.header-search-widget.is-open .header-search-toggle {
  border-color: var(--brand-primary);
  color: var(--brand-primary);
  background: var(--brand-primary-soft);
}

/* Expands smoothly to the LEFT of the magnifier button */
.header-search-expand {
  display: inline-flex;
  align-items: center;
  background: var(--surface);
  border: 0px solid var(--brand-primary);
  border-radius: var(--radius-full);
  max-width: 0;
  opacity: 0;
  padding: 0;
  margin-right: 0;
  overflow: hidden;
  pointer-events: none;
  transition:
    max-width 280ms cubic-bezier(0.4, 0, 0.2, 1),
    opacity 220ms ease,
    padding 220ms ease,
    margin 220ms ease,
    border-width 150ms ease;
}

.header-search-widget.is-open .header-search-expand {
  max-width: 230px;
  opacity: 1;
  padding: 0.25rem 0.8rem;
  margin-right: 0.35rem;
  border-width: 1px;
  pointer-events: auto;
  box-shadow: var(--shadow-md);
}

.header-search-input {
  background: transparent;
  border: none;
  color: var(--text);
  font-family: var(--font-sans);
  font-size: 0.85rem;
  width: 195px;
  outline: none;
}

@media (max-width: 640px) {
  .header-search-widget.is-open .header-search-expand {
    max-width: 165px;
    padding: 0.22rem 0.65rem;
  }
  .header-search-input {
    width: 140px;
    font-size: 0.8rem;
  }
}

.header-search-clear-btn {
  margin-left: 0.35rem;
  border-color: rgba(255, 107, 0, 0.45);
  color: var(--brand-primary);
  background: rgba(255, 107, 0, 0.1);
  padding: 0.28rem 0.65rem;
  min-height: 34px;
  font-size: 0.78rem;
  border-radius: var(--radius-full);
}

.header-search-clear-btn:hover {
  background: var(--brand-primary);
  color: #09090B;
}

/* ================= FREE SHIPPING PROGRESS & COUPON BOX ================= */
.free-shipping-banner {
  padding: 0.85rem 1rem;
  border-radius: var(--radius-md);
  border: 1px solid var(--border);
  background: var(--surface-elevated);
}

.free-shipping-banner.achieved {
  border-color: rgba(16, 185, 129, 0.4);
  background: rgba(16, 185, 129, 0.08);
}

.free-shipping-track {
  width: 100%;
  height: 6px;
  border-radius: var(--radius-full);
  background: var(--background);
  border: 1px solid var(--border);
  overflow: hidden;
}

.free-shipping-fill {
  height: 100%;
  border-radius: var(--radius-full);
  background: var(--brand-primary);
  transition: width 320ms ease;
}

.free-shipping-banner.achieved .free-shipping-fill {
  background: var(--success);
}

.coupon-box {
  padding: 0.9rem 1rem;
  border-radius: var(--radius-md);
  background: var(--surface-elevated);
  border: 1px solid var(--border);
}

/* ================= FIRST ORDER 10% WELCOME POPUP ================= */
.welcome-popup-backdrop {
  position: fixed;
  inset: 0;
  z-index: 1200;
  background: rgba(5, 6, 8, 0.78);
  backdrop-filter: blur(6px);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1rem;
}

.welcome-popup-card {
  width: 100%;
  max-width: 430px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 1.75rem 1.5rem;
  text-align: center;
  box-shadow: var(--shadow-lg);
  position: relative;
}

.welcome-coupon-pill {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  margin: 1rem auto;
  padding: 0.55rem 1.15rem;
  border-radius: var(--radius-sm);
  border: 1px solid rgba(255, 107, 0, 0.35);
  background: rgba(255, 107, 0, 0.1);
  color: var(--brand-primary);
  font-family: var(--font-mono);
  font-size: 1.15rem;
  font-weight: 700;
  letter-spacing: 0.08em;
}

/* ================= PRINTER ROI PAYBACK BAR ================= */
.payoff-progress-track {
  width: 100%;
  height: 8px;
  border-radius: var(--radius-full);
  background: var(--background);
  border: 1px solid var(--border);
  overflow: hidden;
  margin-top: 0.3rem;
}

.payoff-progress-fill {
  height: 100%;
  border-radius: var(--radius-full);
  background: linear-gradient(90deg, #FF6B00, #10B981);
  transition: width 350ms ease;
}

/* ================= ADMIN QUICK FILTER PILLS & GAUGE DASHBOARDS ================= */
.status-pills-bar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.45rem;
  margin-bottom: 1rem;
}

.status-pill-btn {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  padding: 0.42rem 0.85rem;
  border-radius: var(--radius-full);
  border: 1px solid var(--border);
  background: var(--surface);
  color: var(--text-muted);
  font-size: 0.82rem;
  font-weight: 600;
  cursor: pointer;
  transition: all var(--transition-fast);
}

.status-pill-btn:hover {
  border-color: var(--brand-primary);
  color: var(--text);
}

.status-pill-btn.active {
  background: var(--brand-primary);
  border-color: var(--brand-primary);
  color: #09090B;
  font-weight: 700;
}

.gauge-grid,
.filament-gauge-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(168px, 1fr));
  gap: 0.75rem;
}

.gauge-card,
.filament-gauge-card {
  background: var(--background);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  padding: 0.75rem 0.65rem;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  gap: 0.25rem;
  transition: border-color var(--transition-fast), transform var(--transition-fast);
}

.filament-gauge-card:hover {
  border-color: rgba(255, 107, 0, 0.45);
  transform: translateY(-2px);
}

.filament-gauge-svg {
  width: 116px;
  height: 68px;
  max-width: 100%;
  display: block;
  margin: 0.1rem auto;
  flex-shrink: 0;
}

@media (max-width: 640px) {
  .gauge-grid,
  .filament-gauge-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 0.5rem;
  }
  .filament-gauge-card {
    padding: 0.55rem 0.45rem;
  }
  .filament-gauge-svg {
    width: 96px;
    height: 58px;
  }
}

.city-search-wrapper {
  position: relative;
  width: 100%;
  max-width: 680px;
}

.city-search-dropdown {
  position: absolute;
  top: calc(100% + 6px);
  left: 0;
  width: 100%;
  max-width: 680px;
  max-height: 280px;
  overflow-y: auto;
  background: #14141B;
  border: 1.5px solid var(--brand-primary);
  border-radius: var(--radius-md);
  box-shadow: 0 18px 42px rgba(0, 0, 0, 0.85);
  z-index: 320;
  padding: 0.4rem;
}

.city-search-dropdown[hidden] {
  display: none !important;
}

.city-search-dropdown-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.5rem;
  padding: 0.35rem 0.6rem 0.45rem;
  margin-bottom: 0.25rem;
  border-bottom: 1px solid var(--border);
  font-size: 0.74rem;
  color: var(--text-muted);
  position: sticky;
  top: -0.4rem;
  background: #14141B;
  z-index: 2;
}

.city-search-option {
  width: 100%;
  text-align: left;
  background: transparent;
  border: 1px solid transparent;
  color: var(--text);
  padding: 0.5rem 0.65rem;
  border-radius: var(--radius-sm);
  cursor: pointer;
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  align-items: center;
  gap: 0.4rem;
  font-family: var(--font-sans);
  font-size: 0.84rem;
  transition: all var(--transition-fast);
}

.city-search-option:hover,
.city-search-option:focus {
  background: var(--brand-primary-soft);
  border-color: rgba(255, 107, 0, 0.35);
  color: var(--brand-primary);
  outline: none;
}

@media (max-width: 640px) {
  .city-search-dropdown {
    max-height: 230px;
  }
  .city-search-option {
    flex-direction: column;
    align-items: flex-start;
    gap: 0.25rem;
    padding: 0.5rem;
  }
}

/* ================= 3DFUSE MINI CALENDAR POPOVER (FINANCE CUSTOM PERIOD) ================= */
.fuse-date-picker-wrap {
  position: relative;
  display: inline-block;
  min-width: 158px;
}

.fuse-date-picker-trigger {
  cursor: pointer !important;
  padding-right: 2rem !important;
  user-select: none;
}

.fuse-calendar-popover {
  position: absolute;
  top: calc(100% + 6px);
  left: 0;
  width: 262px;
  background: #14141C;
  border: 1.5px solid var(--brand-primary);
  border-radius: var(--radius-lg);
  box-shadow: 0 18px 45px rgba(0, 0, 0, 0.88);
  padding: 0.75rem;
  z-index: 420;
}

.fuse-calendar-popover[hidden] {
  display: none !important;
}

.fuse-calendar-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.35rem;
  margin-bottom: 0.55rem;
  padding-bottom: 0.45rem;
  border-bottom: 1px solid var(--border);
}

.fuse-calendar-nav-btn {
  width: 28px;
  height: 28px;
  border-radius: var(--radius-sm);
  border: 1px solid var(--border);
  background: var(--surface);
  color: var(--text);
  font-weight: 800;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.fuse-calendar-nav-btn:hover {
  border-color: var(--brand-primary);
  color: var(--brand-primary);
}

.fuse-calendar-weekdays {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  gap: 2px;
  text-align: center;
  font-size: 0.68rem;
  font-weight: 700;
  color: var(--text-muted);
  margin-bottom: 0.3rem;
}

.fuse-calendar-grid {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  gap: 3px;
}

.fuse-calendar-day {
  height: 30px;
  border-radius: var(--radius-sm);
  border: 1px solid transparent;
  background: transparent;
  color: var(--text);
  font-size: 0.78rem;
  font-family: var(--font-mono);
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0;
}

.fuse-calendar-day:hover:not(:disabled) {
  background: var(--brand-primary-soft);
  border-color: var(--brand-primary);
  color: var(--brand-primary);
}

.fuse-calendar-day.is-selected {
  background: var(--brand-primary);
  color: #09090B;
  font-weight: 800;
}

.fuse-calendar-day.is-today {
  border-color: rgba(255, 107, 0, 0.55);
}

.fuse-calendar-day:disabled {
  opacity: 0.22;
  cursor: default;
}

.birthdate-dynamic-row {
  display: grid;
  grid-template-columns: 1fr 1.35fr 1.15fr;
  gap: 0.45rem;
  margin-top: 0.35rem;
}

/* ================= SAVED CUSTOMER ADDRESSES BOOK (CHECKOUT STEP 2) ================= */
.saved-addresses-box {
  margin-bottom: 1.1rem;
  padding: 0.9rem;
  border-radius: var(--radius-md);
  background: var(--surface-elevated);
  border: 1px solid var(--border);
}

.saved-addresses-header {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 0.5rem;
  margin-bottom: 0.7rem;
}

.saved-addresses-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
  gap: 0.6rem;
}

.saved-address-card {
  position: relative;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  gap: 0.45rem;
  padding: 0.75rem 0.85rem;
  border-radius: var(--radius-sm);
  border: 1px solid var(--border);
  background: var(--background);
  cursor: pointer;
  transition: border-color var(--transition-fast), background var(--transition-fast);
}

.saved-address-card:hover {
  border-color: rgba(255, 255, 255, 0.22);
}

.saved-address-card.active {
  border-color: var(--brand-primary);
  background: rgba(255, 107, 0, 0.06);
}

.saved-address-bar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
  padding: 0.75rem 0.9rem;
  margin-bottom: 1rem;
  border-radius: var(--radius-md);
  background: var(--surface-elevated);
  border: 1px solid var(--border);
}

/* Custom Segmented Control for Address Label (Eliminates native OS dropdown overlay) */
.segmented-label-group {
  display: inline-flex;
  align-items: center;
  background: var(--background);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 2px;
  gap: 2px;
}

.segmented-label-btn {
  padding: 0.28rem 0.68rem;
  font-size: 0.76rem;
  font-weight: 600;
  font-family: var(--font-sans);
  color: var(--text-muted);
  background: transparent;
  border: none;
  border-radius: 4px;
  cursor: pointer;
  transition: background var(--transition-fast), color var(--transition-fast);
  user-select: none;
}

.segmented-label-btn:hover {
  color: var(--text);
}

.segmented-label-btn.active {
  background: var(--surface-elevated);
  color: var(--brand-primary);
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.35);
}

