/* C² Tides — blue / red / black / white chrome */
:root {
  --c2-blue: #1B4F8C;
  --c2-blue-light: #2563eb;
  --c2-red: #dc2626;
  --c2-black: #0a0a0a;
  --c2-white: #ffffff;
  --header-h: 3.5rem;
}

@media (min-width: 640px) {
  :root { --header-h: 4.25rem; }
}

html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }

/* Compact nav on all legacy pages */
nav.sticky.top-0 > div > div.flex {
  padding-top: 0.5rem !important;
  padding-bottom: 0.5rem !important;
  min-height: var(--header-h);
}

nav.sticky.top-0 img.w-12,
nav.sticky.top-0 img.h-12 {
  width: 2rem !important;
  height: 2rem !important;
}

nav.sticky.top-0 h1.text-2xl,
nav.sticky.top-0 .text-2xl.font-bold {
  font-size: 1rem !important;
  line-height: 1.25rem !important;
}

nav.sticky.top-0 label[for="menu-toggle"] {
  font-size: 1.5rem !important;
}

nav.sticky.top-0 svg.h-8 {
  width: 1.5rem !important;
  height: 1.5rem !important;
}

/* Checkout / large headers */
header.gradient-bg,
header.py-4 {
  padding-top: 0.625rem !important;
  padding-bottom: 0.625rem !important;
}

header.gradient-bg img.h-12,
header.py-4 img.h-12 {
  height: 2rem !important;
  width: 2rem !important;
}

header.gradient-bg h1,
header.py-4 h1 {
  font-size: 1rem !important;
}

/* Hero sections — less padding on mobile */
section.py-20,
section.py-16 {
  padding-top: 2.5rem !important;
  padding-bottom: 2.5rem !important;
}

@media (min-width: 768px) {
  section.py-20 { padding-top: 5rem !important; padding-bottom: 5rem !important; }
  section.py-16 { padding-top: 4rem !important; padding-bottom: 4rem !important; }
}

section h2.text-5xl,
section h2.text-4xl {
  font-size: 1.75rem !important;
  line-height: 2.1rem !important;
}

@media (min-width: 768px) {
  section h2.text-5xl { font-size: 3rem !important; line-height: 1.1 !important; }
  section h2.text-4xl { font-size: 2.25rem !important; }
}

/* Glow title — blue to red */
.glow-text {
  background: linear-gradient(135deg, #60a5fa, #1B4F8C, #dc2626, #ef4444);
  background-size: 300% 300%;
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  animation: c2GlowShift 4s ease infinite;
  filter: drop-shadow(0 0 12px rgba(220, 38, 38, 0.3));
}

.glow-text-soft {
  background: linear-gradient(135deg, #2563eb, #dc2626);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

@keyframes c2GlowShift {
  0%, 100% { background-position: 0% 50%; }
  50% { background-position: 100% 50%; }
}

/* Site banner */
.site-banner {
  background: var(--c2-black);
  color: #fff;
  font-size: 0.625rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  padding: 0.35rem 0.5rem;
  text-align: center;
  line-height: 1.3;
}

@media (min-width: 640px) {
  .site-banner { font-size: 0.7rem; padding: 0.4rem 0.75rem; }
}

.site-banner .sparkle { color: var(--c2-red); }

/* Touch targets */
button, .cart-fab, .nav-menu-btn {
  min-height: 44px;
  min-width: 44px;
}

/* Orange → teal floating cart — single button site-wide */
.cart-fab,
a#floating-cart-button {
  position: fixed;
  right: 1rem;
  bottom: max(1rem, env(safe-area-inset-bottom));
  z-index: 9999;
  width: 3.5rem;
  height: 3.5rem;
  border-radius: 9999px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: linear-gradient(135deg, #F56A3D 0%, #18C4D8 55%, #0e8fa0 100%) !important;
  background-size: 180% 180%;
  color: #fff !important;
  font-size: 1.35rem;
  box-shadow:
    0 18px 40px rgba(0, 0, 0, 0.28),
    0 0 18px rgba(245, 106, 61, 0.45),
    0 0 26px rgba(24, 196, 216, 0.4);
  border: 2px solid rgba(255, 255, 255, 0.7);
  text-decoration: none;
  transition: transform 0.2s ease, box-shadow 0.25s ease;
  animation: c2CartPulse 2.6s ease-in-out infinite, c2CartGradient 4s ease-in-out infinite;
}

@media (min-width: 640px) {
  .cart-fab {
    right: 1.25rem;
    width: 4rem;
    height: 4rem;
  }
}

.cart-fab:hover {
  transform: translateY(-3px) scale(1.05);
  box-shadow:
    0 24px 52px rgba(0, 0, 0, 0.34),
    0 0 22px rgba(245, 106, 61, 0.45),
    0 0 30px rgba(24, 196, 216, 0.5);
}

.cart-fab-badge {
  position: absolute;
  top: -0.25rem;
  right: -0.25rem;
  min-width: 1.5rem;
  height: 1.5rem;
  padding: 0 0.35rem;
  border-radius: 9999px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: #18C4D8;
  color: #041018;
  font-size: 0.8rem;
  font-weight: 800;
  line-height: 1;
  border: 2px solid #fff;
}

.cart-fab-badge[data-count="0"] {
  display: none;
}

@keyframes c2CartPulse {
  0%, 100% { transform: scale(1); }
  50% { transform: scale(1.05); }
}

@keyframes c2CartGradient {
  0%, 100% { background-position: 0% 50%; }
  50% { background-position: 100% 50%; }
}

/* Hide legacy green/purple cart button — never hide .cart-fab */
.floating-cart-button:not(.cart-fab),
a.floating-cart-button:not(.cart-fab) {
  display: none !important;
  visibility: hidden !important;
  pointer-events: none !important;
  opacity: 0 !important;
}

/* Product grids mobile */
.grid.gap-8 { gap: 1rem !important; }
@media (min-width: 768px) { .grid.gap-8 { gap: 2rem !important; } }

/* Prevent horizontal overflow */
html, body { overflow-x: hidden; max-width: 100%; }
img, video, canvas, svg { max-width: 100%; height: auto; }

/* Floating UI safe area */
.research-bot-fab { bottom: calc(max(1rem, env(safe-area-inset-bottom)) + 4.75rem); }

/* Compact mobile headers (overrides huge 7rem logos) */
@media (max-width: 640px) {
  .site-header-inner {
    height: 4.25rem !important;
    min-height: 4.25rem !important;
  }
  .nav-logo {
    height: 3.25rem !important;
    max-height: 3.25rem !important;
  }
  .pd-logo {
    height: 2.75rem !important;
  }
  main, .shop-wrap, .pd-wrap {
    padding-bottom: calc(5.5rem + env(safe-area-inset-bottom)) !important;
  }
  input, select, textarea, button {
    font-size: 16px; /* prevent iOS zoom on focus */
  }
}

@media (min-width: 641px) and (max-width: 900px) {
  .site-header-inner { height: 5rem !important; }
  .nav-logo { height: 4rem !important; }
}

/* ── Sitewide promo ticker ─────────────────────────────────────────────── */
:root { --sl-ticker-h: 2.25rem; }

.sl-ticker {
  position: sticky;
  top: 0;
  z-index: 70;
  width: 100%;
  height: var(--sl-ticker-h);
  overflow: hidden;
  background: linear-gradient(90deg, #0B1320 0%, #1B4F8C 55%, #0f766e 100%);
  color: #F5F3EF;
  border-bottom: 1px solid rgba(255, 255, 255, 0.12);
  display: flex;
  align-items: center;
}

.sl-ticker__track {
  display: inline-flex;
  align-items: center;
  gap: 2.5rem;
  white-space: nowrap;
  width: max-content;
  padding-left: 1rem;
  animation: sl-ticker-scroll 42s linear infinite;
  font-family: Outfit, system-ui, sans-serif;
  font-size: 0.78rem;
  font-weight: 600;
  letter-spacing: 0.02em;
  text-transform: none;
}

.sl-ticker__track span {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
}

.sl-ticker__track span::before {
  content: '';
  width: 0.35rem;
  height: 0.35rem;
  border-radius: 999px;
  background: #18C4D8;
  flex-shrink: 0;
}

@keyframes sl-ticker-scroll {
  from { transform: translateX(0); }
  to { transform: translateX(-50%); }
}

body.has-sl-ticker {
  /* ticker is in-flow + sticky; no extra padding needed */
}

@media (prefers-reduced-motion: reduce) {
  .sl-ticker__track {
    animation: none;
    flex-wrap: wrap;
    white-space: normal;
    justify-content: center;
    width: 100%;
    gap: 0.75rem 1.25rem;
    padding: 0.35rem 0.75rem;
  }
  .sl-ticker { height: auto; min-height: var(--sl-ticker-h); }
}

@media (max-width: 640px) {
  .sl-ticker__track { font-size: 0.7rem; gap: 1.75rem; animation-duration: 36s; }
}

