/* ========================================
   DIMMY — Marketing Website Styles
   ======================================== */

/* --- Design Tokens --- */
:root {
  --bg: #0d0d14;
  --surface: #12121e;
  --surface-2: #1a1a2e;
  --text: #e5e7eb;
  --text-bright: #f8f9fa;
  --muted: #6b7280;
  --accent-teal: #41B0B1;
  --accent-blue: #5198C9;
  --accent-indigo: #818cf8;
  --gradient: linear-gradient(135deg, var(--accent-teal), var(--accent-blue), var(--accent-indigo));
  --gradient-h: linear-gradient(90deg, var(--accent-teal), var(--accent-blue), var(--accent-indigo));

  --font-body: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  --font-mono: 'SF Mono', 'Fira Code', 'Cascadia Code', monospace;

  --ease: cubic-bezier(0.33, 1, 0.68, 1);
  --ease-out: cubic-bezier(0.16, 1, 0.3, 1);
  --duration: 0.6s;
  --stagger: 0.08s;

  --space: 8px;
  --max-w: 1200px;
  --radius: 12px;
  --radius-lg: 24px;
}

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

html {
  font-size: 16px;
  -webkit-text-size-adjust: 100%;
  scroll-behavior: auto; /* Lenis handles smooth scroll */
}

body {
  font-family: var(--font-body);
  background: var(--bg);
  color: var(--text);
  line-height: 1.6;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

a {
  color: inherit;
  text-decoration: none;
}

button {
  font-family: inherit;
  border: none;
  background: none;
  cursor: pointer;
  color: inherit;
}

img, svg {
  display: block;
  max-width: 100%;
}

/* --- Noise Overlay --- */
.noise-overlay {
  position: fixed;
  inset: 0;
  z-index: 9999;
  pointer-events: none;
  opacity: 0.03;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 256 256' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)' opacity='1'/%3E%3C/svg%3E");
  background-repeat: repeat;
  background-size: 256px 256px;
}

/* --- Custom Cursor --- */
.cursor {
  position: fixed;
  top: 0;
  left: 0;
  width: 12px;
  height: 12px;
  border-radius: 50%;
  border: 1.5px solid var(--accent-teal);
  pointer-events: none;
  z-index: 10000;
  transform: translate(-50%, -50%);
  transition: width 0.3s var(--ease), height 0.3s var(--ease), border-color 0.3s var(--ease), background 0.3s var(--ease);
  mix-blend-mode: difference;
  will-change: transform;
}

.cursor.hover {
  width: 40px;
  height: 40px;
  border-color: var(--accent-indigo);
  background: rgba(129, 140, 248, 0.08);
}

.cursor-glow {
  position: fixed;
  top: 0;
  left: 0;
  width: 600px;
  height: 600px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(65, 176, 177, 0.06) 0%, transparent 70%);
  pointer-events: none;
  z-index: -1;
  transform: translate(-50%, -50%);
  will-change: transform;
}

/* --- Vertical Scroll Progress --- */
.scroll-progress-vertical {
  position: fixed;
  top: 0;
  right: 0;
  width: 3px;
  height: 100vh;
  height: 100dvh;
  z-index: 10001;
  pointer-events: none;
  background: rgba(255, 255, 255, 0.03);
}

.scroll-progress-fill {
  width: 100%;
  height: 0%;
  background: var(--gradient);
  border-radius: 0 0 2px 2px;
  will-change: height;
}

/* Hide native scrollbar */
html {
  scrollbar-width: none; /* Firefox */
}
html::-webkit-scrollbar {
  display: none; /* Chrome, Safari, Edge */
}

/* --- Navigation --- */
.nav {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 1000;
  padding: 0 calc(var(--space) * 3);
  transition: background 0.4s var(--ease), backdrop-filter 0.4s var(--ease);
}

.nav.scrolled {
  background: rgba(13, 13, 20, 0.85);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
}

/* Nav waveform — appears on scroll */
.nav-wave {
  position: absolute;
  bottom: 0;
  left: 0;
  width: 100%;
  height: 20px;
  opacity: 0;
  transition: opacity 0.6s var(--ease);
  pointer-events: none;
}

.nav.scrolled .nav-wave {
  opacity: 1;
}

.nav-inner {
  max-width: var(--max-w);
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 72px;
}

.nav-logo {
  display: flex;
  align-items: center;
  gap: 10px;
  font-weight: 600;
  font-size: 1.125rem;
  color: var(--text-bright);
  letter-spacing: -0.02em;
}

.nav-links {
  display: flex;
  align-items: center;
  gap: calc(var(--space) * 4);
}

.nav-link {
  font-size: 0.875rem;
  font-weight: 500;
  color: var(--muted);
  transition: color 0.3s var(--ease);
}

.nav-link:hover {
  color: var(--text-bright);
}

.nav-cta {
  font-size: 0.875rem;
  font-weight: 600;
  padding: 8px 20px;
  border-radius: var(--radius-lg);
  background: var(--gradient);
  color: var(--bg);
  transition: opacity 0.3s var(--ease), transform 0.3s var(--ease);
}

.nav-cta:hover {
  opacity: 0.9;
  transform: translateY(-1px);
}

.nav-toggle {
  display: none;
  flex-direction: column;
  gap: 5px;
  width: 24px;
  padding: 4px 0;
}

.nav-toggle span {
  display: block;
  width: 100%;
  height: 1.5px;
  background: var(--text);
  border-radius: 1px;
  transition: transform 0.3s var(--ease), opacity 0.3s var(--ease);
}

.nav-toggle.active span:first-child {
  transform: translateY(3.25px) rotate(45deg);
}
.nav-toggle.active span:last-child {
  transform: translateY(-3.25px) rotate(-45deg);
}

/* Mobile Menu */
.mobile-menu {
  position: fixed;
  inset: 0;
  z-index: 999;
  background: rgba(13, 13, 20, 0.97);
  backdrop-filter: blur(30px);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: calc(var(--space) * 4);
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.4s var(--ease);
}

.mobile-menu.open {
  opacity: 1;
  pointer-events: all;
}

.mobile-link {
  font-size: 1.5rem;
  font-weight: 600;
  color: var(--text);
  transition: color 0.3s var(--ease);
}

.mobile-link:hover {
  color: var(--accent-teal);
}

.mobile-cta {
  margin-top: calc(var(--space) * 2);
  padding: 14px 36px;
  border-radius: var(--radius-lg);
  background: var(--gradient);
  color: var(--bg);
  font-weight: 600;
  font-size: 1rem;
}

/* --- Container --- */
.container {
  max-width: var(--max-w);
  margin: 0 auto;
  padding: 0 calc(var(--space) * 3);
}

/* --- Typography --- */
.caption {
  font-size: 0.875rem;
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--accent-teal);
  margin-bottom: calc(var(--space) * 2);
}

.caption.revealed {
  animation: caption-spread 0.8s var(--ease-out) forwards;
}

@keyframes caption-spread {
  0% { letter-spacing: 0em; opacity: 0; }
  100% { letter-spacing: 0.15em; opacity: 1; }
}

.section-heading {
  font-size: clamp(2rem, 5vw, 4rem);
  font-weight: 600;
  line-height: 1.1;
  letter-spacing: -0.03em;
  color: var(--text-bright);
  margin-bottom: calc(var(--space) * 3);
}

.section-sub {
  font-size: 1.125rem;
  color: var(--muted);
  max-width: 560px;
  line-height: 1.6;
  margin-bottom: calc(var(--space) * 6);
}

/* --- Buttons --- */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 14px 28px;
  border-radius: var(--radius-lg);
  font-weight: 600;
  font-size: 0.9375rem;
  transition: transform 0.3s var(--ease), opacity 0.3s var(--ease), box-shadow 0.3s var(--ease);
  white-space: nowrap;
}

.btn:hover {
  transform: translateY(-2px);
}

.btn--primary {
  background: var(--gradient);
  color: var(--bg);
}

.btn--primary:hover {
  box-shadow: 0 8px 32px rgba(65, 176, 177, 0.25);
}

.btn--outline {
  border: 1px solid rgba(229, 231, 235, 0.15);
  color: var(--text);
  background: rgba(255, 255, 255, 0.03);
}

.btn--outline:hover {
  border-color: rgba(229, 231, 235, 0.3);
  background: rgba(255, 255, 255, 0.06);
}

.btn--large {
  padding: 18px 36px;
  font-size: 1rem;
}

/* --- Scroll Reveal base --- */
[data-scroll-reveal] {
  opacity: 0;
  transform: translateY(30px);
  transition: opacity var(--duration) var(--ease-out), transform var(--duration) var(--ease-out);
}

[data-scroll-reveal].revealed {
  opacity: 1;
  transform: translateY(0);
}

/* ==========================================
   HERO
   ========================================== */
.hero {
  position: relative;
  min-height: 100vh;
  min-height: 100dvh;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  overflow: hidden;
}

#hero-canvas {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  z-index: 0;
}

.hero-content {
  position: relative;
  z-index: 2;
  text-align: center;
  padding: 0 calc(var(--space) * 3);
  max-width: 900px;
}

/* Darken center of canvas so text is always readable */
.hero::before {
  content: '';
  position: absolute;
  inset: 0;
  z-index: 1;
  background: radial-gradient(ellipse 50% 40% at 50% 50%, rgba(13, 13, 20, 0.45) 0%, transparent 65%);
  pointer-events: none;
}

.hero-badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 6px 16px;
  border-radius: 100px;
  border: 1px solid rgba(65, 176, 177, 0.2);
  background: rgba(65, 176, 177, 0.06);
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.1em;
  color: var(--accent-teal);
  margin-bottom: calc(var(--space) * 5);
}

.recording-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: #22c55e;
  animation: pulse-dot 2s ease infinite;
}

@keyframes pulse-dot {
  0%, 100% { opacity: 1; box-shadow: 0 0 0 0 rgba(34, 197, 94, 0.4); }
  50% { opacity: 0.7; box-shadow: 0 0 0 6px rgba(34, 197, 94, 0); }
}

.hero-headline {
  font-size: clamp(3.5rem, 10vw, 8rem);
  font-weight: 700;
  line-height: 1;
  letter-spacing: -0.04em;
  color: var(--text-bright);
  margin-bottom: calc(var(--space) * 4);
}

.hero-line {
  display: block;
}

.hero-line--accent {
  color: var(--accent-teal);
  text-shadow:
    0 0 30px rgba(65, 176, 177, 0.5),
    0 0 60px rgba(65, 176, 177, 0.2);
  animation: accent-glow-pulse 3s ease-in-out infinite alternate;
}

@keyframes accent-glow-pulse {
  0% {
    color: var(--accent-teal);
    text-shadow:
      0 0 30px rgba(65, 176, 177, 0.5),
      0 0 60px rgba(65, 176, 177, 0.2);
  }
  100% {
    color: var(--accent-indigo);
    text-shadow:
      0 0 30px rgba(129, 140, 248, 0.5),
      0 0 60px rgba(129, 140, 248, 0.2);
  }
}

/* Split text chars */
.hero-line .char {
  display: inline-block;
  opacity: 0;
  transform: translateY(40px) rotate(3deg);
  transition: opacity 0.5s var(--ease-out), transform 0.5s var(--ease-out);
}

.hero-line .char.visible {
  opacity: 1;
  transform: translateY(0) rotate(0deg);
}

.hero-sub {
  font-size: clamp(1rem, 2.5vw, 1.25rem);
  color: var(--muted);
  max-width: 520px;
  margin: 0 auto calc(var(--space) * 5);
  line-height: 1.6;
}

.hero-ctas {
  display: flex;
  gap: calc(var(--space) * 2);
  justify-content: center;
  flex-wrap: wrap;
}

/* Scroll hint */
.scroll-hint {
  position: absolute;
  bottom: 40px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 3;
}

.scroll-hint-line {
  width: 1px;
  height: 48px;
  background: linear-gradient(to bottom, var(--accent-teal), transparent);
  animation: scroll-hint-anim 2s ease infinite;
}

@keyframes scroll-hint-anim {
  0% { opacity: 0; transform: scaleY(0); transform-origin: top; }
  40% { opacity: 1; transform: scaleY(1); transform-origin: top; }
  60% { opacity: 1; transform: scaleY(1); transform-origin: bottom; }
  100% { opacity: 0; transform: scaleY(0); transform-origin: bottom; }
}

/* ==========================================
   PRODUCT SHOWCASE
   ========================================== */
.product {
  padding: 160px 0;
  position: relative;
}

.product-inner {
  max-width: var(--max-w);
  margin: 0 auto;
  padding: 0 calc(var(--space) * 3);
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: calc(var(--space) * 8);
  align-items: center;
}

.product-text .caption,
.product-text .section-heading {
  opacity: 0;
  transform: translateY(30px);
}

.product-text .caption.revealed,
.product-text .section-heading.revealed {
  opacity: 1;
  transform: translateY(0);
  transition: opacity var(--duration) var(--ease-out), transform var(--duration) var(--ease-out);
}

.product-stages {
  display: flex;
  flex-direction: column;
  gap: calc(var(--space) * 3);
}

.product-stage {
  padding: calc(var(--space) * 2.5);
  border-radius: var(--radius);
  border: 1px solid transparent;
  transition: all 0.4s var(--ease);
  opacity: 0.35;
}

.product-stage.active {
  opacity: 1;
  border-color: rgba(65, 176, 177, 0.15);
  background: rgba(65, 176, 177, 0.04);
}

.product-stage h3 {
  font-size: 1.125rem;
  font-weight: 600;
  color: var(--text-bright);
  margin-bottom: 4px;
}

.product-stage p {
  font-size: 0.9375rem;
  color: var(--muted);
  line-height: 1.5;
}

/* The Pill */
.product-visual {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 300px;
}

.product-glow {
  position: absolute;
  width: 300px;
  height: 300px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(65, 176, 177, 0.12) 0%, transparent 70%);
  filter: blur(40px);
  animation: glow-pulse 4s ease infinite;
}

@keyframes glow-pulse {
  0%, 100% { transform: scale(1); opacity: 0.8; }
  50% { transform: scale(1.15); opacity: 1; }
}

.pill {
  position: relative;
  display: flex;
  align-items: center;
  gap: 10px;
  background: var(--surface-2);
  border: 1px solid rgba(255, 255, 255, 0.06);
  border-radius: 100px;
  padding: 10px 20px;
  min-width: 60px;
  height: 44px;
  transition: all 0.5s var(--ease);
  box-shadow: 0 4px 24px rgba(0, 0, 0, 0.4);
}

.pill.expanded {
  min-width: 200px;
  padding: 10px 24px;
}

.pill.recording {
  min-width: 240px;
  border-color: rgba(65, 176, 177, 0.3);
  box-shadow: 0 4px 24px rgba(0, 0, 0, 0.4), 0 0 40px rgba(65, 176, 177, 0.1);
}

.pill.done {
  min-width: 320px;
}

.pill-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--accent-teal);
  flex-shrink: 0;
  transition: background 0.3s var(--ease);
}

.pill.recording .pill-dot {
  background: #ef4444;
  animation: pulse-dot 1s ease infinite;
}

.pill-bars {
  display: flex;
  align-items: center;
  gap: 2px;
  height: 20px;
  opacity: 0;
  transition: opacity 0.3s var(--ease);
}

.pill.recording .pill-bars {
  opacity: 1;
}

.pill-bars span {
  width: 2px;
  height: 4px;
  background: var(--accent-teal);
  border-radius: 1px;
  animation: bar-dance 0.6s ease infinite alternate;
}

.pill-bars span:nth-child(1) { animation-delay: 0s; }
.pill-bars span:nth-child(2) { animation-delay: 0.1s; }
.pill-bars span:nth-child(3) { animation-delay: 0.2s; }
.pill-bars span:nth-child(4) { animation-delay: 0.15s; }
.pill-bars span:nth-child(5) { animation-delay: 0.05s; }

@keyframes bar-dance {
  0% { height: 4px; }
  100% { height: 18px; }
}

.pill-text {
  font-size: 0.8125rem;
  font-weight: 500;
  color: var(--text);
  white-space: nowrap;
  overflow: hidden;
  max-width: 0;
  transition: max-width 0.5s var(--ease);
}

.pill.done .pill-text {
  max-width: 250px;
}

/* ==========================================
   HOW IT WORKS
   ========================================== */
.how-it-works {
  padding: 120px 0 160px;
  background: var(--surface);
  position: relative;
}

.how-it-works::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 1px;
  background: linear-gradient(90deg, transparent, rgba(65, 176, 177, 0.2), transparent);
}

.moments {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: calc(var(--space) * 4);
  margin-top: calc(var(--space) * 6);
}

.moment {
  position: relative;
  padding: calc(var(--space) * 4);
  border-radius: var(--radius);
  background: rgba(255, 255, 255, 0.02);
  border: 1px solid rgba(255, 255, 255, 0.04);
  overflow: hidden;
  transition: border-color 0.4s var(--ease), background 0.4s var(--ease);
  animation: float-gentle 6s ease-in-out infinite;
}
.moment:nth-child(2) { animation-delay: -2s; }
.moment:nth-child(3) { animation-delay: -4s; }

@keyframes float-gentle {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-6px); }
}

.moment:hover {
  border-color: rgba(65, 176, 177, 0.15);
  background: rgba(255, 255, 255, 0.03);
}

.moment-number {
  position: absolute;
  top: -10px;
  right: -5px;
  font-size: clamp(5rem, 10vw, 8rem);
  font-weight: 700;
  line-height: 1;
  color: var(--accent-teal);
  opacity: 0.06;
  animation: number-glow 4s ease-in-out infinite alternate;
  pointer-events: none;
  user-select: none;
}
.moment:nth-child(2) .moment-number { animation-delay: -1.5s; }
.moment:nth-child(3) .moment-number { animation-delay: -3s; }

@keyframes number-glow {
  0% { color: var(--accent-teal); opacity: 0.05; }
  100% { color: var(--accent-indigo); opacity: 0.1; }
}

.moment-visual {
  height: 80px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: calc(var(--space) * 3);
}

/* Moment 01 bars */
.moment-bars {
  display: flex;
  align-items: center;
  gap: 3px;
  height: 60px;
}

.moment-bars span {
  width: 3px;
  border-radius: 2px;
  background: var(--accent-teal);
  animation: moment-bar 1.2s ease infinite alternate;
}

.moment-bars span:nth-child(1) { height: 15px; animation-delay: 0.0s; }
.moment-bars span:nth-child(2) { height: 25px; animation-delay: 0.08s; }
.moment-bars span:nth-child(3) { height: 40px; animation-delay: 0.16s; }
.moment-bars span:nth-child(4) { height: 30px; animation-delay: 0.24s; }
.moment-bars span:nth-child(5) { height: 50px; animation-delay: 0.32s; }
.moment-bars span:nth-child(6) { height: 35px; animation-delay: 0.40s; }
.moment-bars span:nth-child(7) { height: 55px; animation-delay: 0.48s; }
.moment-bars span:nth-child(8) { height: 20px; animation-delay: 0.56s; }
.moment-bars span:nth-child(9) { height: 45px; animation-delay: 0.64s; }
.moment-bars span:nth-child(10) { height: 30px; animation-delay: 0.72s; }
.moment-bars span:nth-child(11) { height: 15px; animation-delay: 0.80s; }
.moment-bars span:nth-child(12) { height: 35px; animation-delay: 0.88s; }
.moment-bars span:nth-child(13) { height: 50px; animation-delay: 0.96s; }
.moment-bars span:nth-child(14) { height: 25px; animation-delay: 1.04s; }
.moment-bars span:nth-child(15) { height: 40px; animation-delay: 0.12s; }
.moment-bars span:nth-child(16) { height: 20px; animation-delay: 0.20s; }
.moment-bars span:nth-child(17) { height: 30px; animation-delay: 0.28s; }
.moment-bars span:nth-child(18) { height: 55px; animation-delay: 0.36s; }
.moment-bars span:nth-child(19) { height: 15px; animation-delay: 0.44s; }
.moment-bars span:nth-child(20) { height: 25px; animation-delay: 0.52s; }

@keyframes moment-bar {
  0% { transform: scaleY(0.3); opacity: 0.4; }
  100% { transform: scaleY(1); opacity: 1; }
}

/* Moment 02 stream */
.moment-stream {
  font-family: var(--font-mono);
  font-size: 0.875rem;
  color: var(--accent-blue);
}

.stream-cursor {
  animation: blink-cursor 0.8s step-end infinite;
}

@keyframes blink-cursor {
  0%, 100% { opacity: 1; }
  50% { opacity: 0; }
}

/* Moment 03 morph */
.moment-morph {
  font-size: 1rem;
  font-weight: 500;
}

.morph-text {
  background: var(--gradient-h);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  transition: all 0.5s var(--ease);
}

.moment-title {
  font-size: 1.375rem;
  font-weight: 600;
  color: var(--text-bright);
  margin-bottom: calc(var(--space) * 1);
}

.moment-desc {
  font-size: 0.9375rem;
  color: var(--muted);
  line-height: 1.6;
}

/* ==========================================
   PROVIDERS
   ========================================== */
.providers {
  padding: 160px 0 120px;
  overflow: hidden;
}

/* Marquee */
.marquee {
  overflow: hidden;
  padding: calc(var(--space) * 6) 0;
  margin: calc(var(--space) * 2) 0 calc(var(--space) * 8);
}

.marquee-track {
  display: flex;
  align-items: center;
  gap: calc(var(--space) * 4);
  width: max-content;
  animation: marquee-scroll 25s linear infinite;
  transition: animation-duration 0.5s ease;
}

.marquee:hover .marquee-track {
  animation-duration: 60s;
}

.marquee-item {
  font-size: clamp(2rem, 5vw, 4rem);
  font-weight: 700;
  letter-spacing: -0.03em;
  color: rgba(255, 255, 255, 0.06);
  white-space: nowrap;
  user-select: none;
  transition: color 0.4s var(--ease);
}

.marquee-item:hover {
  color: rgba(255, 255, 255, 0.15);
}

.marquee-sep {
  font-size: 2rem;
  color: rgba(255, 255, 255, 0.04);
}

@keyframes marquee-scroll {
  0% { transform: translateX(0); }
  100% { transform: translateX(-50%); }
}

/* Provider Grid */
.provider-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: calc(var(--space) * 3);
}

.provider-card {
  position: relative;
  padding: calc(var(--space) * 4);
  border-radius: var(--radius);
  border: 1px solid rgba(255, 255, 255, 0.04);
  background: var(--surface);
  overflow: hidden;
  transition: border-color 0.4s var(--ease), transform 0.4s var(--ease);
}

/* Shimmer light sweep across card */
.provider-card::after {
  content: '';
  position: absolute;
  top: 0;
  left: -100%;
  width: 60%;
  height: 100%;
  background: linear-gradient(90deg, transparent, rgba(255,255,255,0.03), transparent);
  animation: card-shimmer 6s ease-in-out infinite;
  pointer-events: none;
}
.provider-card:nth-child(2)::after { animation-delay: -1s; }
.provider-card:nth-child(3)::after { animation-delay: -2s; }
.provider-card:nth-child(4)::after { animation-delay: -3s; }
.provider-card:nth-child(5)::after { animation-delay: -4s; }
.provider-card:nth-child(6)::after { animation-delay: -5s; }

@keyframes card-shimmer {
  0%, 100% { left: -100%; }
  50% { left: 150%; }
}

.provider-card:hover {
  border-color: rgba(65, 176, 177, 0.2);
  transform: translateY(-4px);
}

.provider-card-glow {
  position: absolute;
  inset: 0;
  background: radial-gradient(circle at 50% 0%, rgba(65, 176, 177, 0.08) 0%, transparent 60%);
  opacity: 0;
  transition: opacity 0.4s var(--ease);
}

.provider-card:hover .provider-card-glow {
  opacity: 1;
}

.provider-card h3 {
  font-size: 1.25rem;
  font-weight: 600;
  color: var(--text-bright);
  margin-bottom: calc(var(--space) * 1);
  position: relative;
}

.provider-type {
  display: inline-block;
  font-size: 0.6875rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--muted);
  padding: 2px 8px;
  border-radius: 4px;
  border: 1px solid rgba(255, 255, 255, 0.06);
  margin-bottom: calc(var(--space) * 1.5);
  position: relative;
}

.provider-badge {
  display: inline-block;
  font-size: 0.6875rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: #22c55e;
  padding: 2px 8px;
  border-radius: 4px;
  border: 1px solid rgba(34, 197, 94, 0.2);
  background: rgba(34, 197, 94, 0.06);
  margin-left: 6px;
  margin-bottom: calc(var(--space) * 1.5);
  position: relative;
}

.provider-card p {
  font-size: 0.875rem;
  color: var(--muted);
  line-height: 1.5;
  position: relative;
}

/* ==========================================
   STYLES
   ========================================== */
.styles {
  padding: 120px 0 160px;
  background: var(--surface);
  position: relative;
}

.styles::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 1px;
  background: linear-gradient(90deg, transparent, rgba(129, 140, 248, 0.2), transparent);
}

.style-demo {
  margin-top: calc(var(--space) * 2);
}

.style-output {
  position: relative;
  padding: calc(var(--space) * 5);
  border-radius: var(--radius);
  border: 1px solid rgba(255, 255, 255, 0.04);
  background: rgba(255, 255, 255, 0.02);
  margin-bottom: calc(var(--space) * 4);
  min-height: 140px;
  transition: border-color 0.6s var(--ease), box-shadow 0.6s var(--ease);
}

.style-output.glow {
  border-color: rgba(65, 176, 177, 0.25);
  box-shadow: 0 0 30px rgba(65, 176, 177, 0.06), inset 0 0 30px rgba(65, 176, 177, 0.02);
}

.style-output-label {
  position: absolute;
  top: calc(var(--space) * 2);
  left: calc(var(--space) * 2.5);
  font-size: 0.6875rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--muted);
}

.style-text {
  font-size: 1.125rem;
  line-height: 1.7;
  color: var(--text);
  transition: opacity 0.15s ease;
}

.style-text.morphing {
  opacity: 0;
}

.style-buttons {
  display: flex;
  flex-wrap: wrap;
  gap: calc(var(--space) * 1);
}

.style-btn {
  padding: 8px 18px;
  border-radius: 100px;
  font-size: 0.8125rem;
  font-weight: 500;
  color: var(--muted);
  border: 1px solid rgba(255, 255, 255, 0.06);
  background: rgba(255, 255, 255, 0.02);
  transition: all 0.3s var(--ease);
}

.style-btn:hover {
  color: var(--text);
  border-color: rgba(255, 255, 255, 0.12);
  background: rgba(255, 255, 255, 0.04);
}

.style-btn.active {
  color: var(--bg);
  background: var(--gradient);
  border-color: transparent;
}

/* ==========================================
   FEATURES
   ========================================== */
.features {
  padding: 160px 0 120px;
}

.features-grid {
  display: grid;
  grid-template-columns: repeat(12, 1fr);
  gap: calc(var(--space) * 3);
  margin-top: calc(var(--space) * 6);
}

.feature {
  padding: calc(var(--space) * 5);
  border-radius: var(--radius);
  border: 1px solid rgba(255, 255, 255, 0.04);
  background: var(--surface);
  transition: border-color 0.4s var(--ease), transform 0.4s var(--ease);
}

.feature:hover {
  border-color: rgba(65, 176, 177, 0.12);
  transform: translateY(-3px);
}

.feature h3 {
  font-size: 1.375rem;
  font-weight: 600;
  color: var(--text-bright);
  margin-bottom: calc(var(--space) * 1.5);
}

.feature p {
  font-size: 0.9375rem;
  color: var(--muted);
  line-height: 1.6;
}

.feature--large {
  grid-column: span 7;
}

.feature--offset-right {
  grid-column: span 5;
}

.feature--wide {
  grid-column: span 12;
}

.feature--offset-left {
  grid-column: span 5;
}

.feature--large:last-of-type {
  grid-column: span 7;
}

/* Feature internals */
.feature-icons {
  display: flex;
  gap: calc(var(--space) * 2);
  margin-bottom: calc(var(--space) * 3);
  color: var(--accent-teal);
}

.feature-os-icon {
  opacity: 0.6;
  transition: opacity 0.3s var(--ease), transform 0.3s var(--ease);
  animation: icon-breathe 4s ease-in-out infinite;
}
.feature-os-icon:nth-child(2) { animation-delay: -1.3s; }
.feature-os-icon:nth-child(3) { animation-delay: -2.6s; }

@keyframes icon-breathe {
  0%, 100% { transform: scale(1); opacity: 0.6; }
  50% { transform: scale(1.1); opacity: 0.8; }
}

.feature:hover .feature-os-icon {
  opacity: 1;
  transform: scale(1.15);
  animation: none;
}

.feature-lock {
  margin-bottom: calc(var(--space) * 3);
  animation: lock-pulse 3s ease-in-out infinite;
}

@keyframes lock-pulse {
  0%, 100% { filter: drop-shadow(0 0 0px transparent); }
  50% { filter: drop-shadow(0 0 12px rgba(65, 176, 177, 0.3)); }
}

.feature-oss {
  margin-bottom: calc(var(--space) * 3);
}

.feature-oss span {
  font-family: var(--font-mono);
  font-size: 0.8125rem;
  font-weight: 600;
  color: var(--accent-indigo);
  padding: 4px 12px;
  border-radius: 6px;
  border: 1px solid rgba(129, 140, 248, 0.2);
  background: rgba(129, 140, 248, 0.06);
  animation: badge-glow 3s ease-in-out infinite alternate;
}

@keyframes badge-glow {
  0% { box-shadow: 0 0 0 0 transparent; }
  100% { box-shadow: 0 0 16px rgba(129, 140, 248, 0.2); }
}

/* Feature wave demo */
.feature-wave-demo {
  display: flex;
  align-items: center;
  gap: calc(var(--space) * 4);
  margin-bottom: calc(var(--space) * 3);
  padding: calc(var(--space) * 2) 0;
}

.fw-bars {
  display: flex;
  align-items: center;
  gap: 2px;
  height: 32px;
}

.fw-bars span {
  width: 3px;
  border-radius: 2px;
  background: var(--accent-teal);
  animation: moment-bar 0.8s ease infinite alternate;
}

.fw-bars span:nth-child(1) { height: 8px; animation-delay: 0.0s; }
.fw-bars span:nth-child(2) { height: 16px; animation-delay: 0.06s; }
.fw-bars span:nth-child(3) { height: 24px; animation-delay: 0.12s; }
.fw-bars span:nth-child(4) { height: 12px; animation-delay: 0.18s; }
.fw-bars span:nth-child(5) { height: 28px; animation-delay: 0.24s; }
.fw-bars span:nth-child(6) { height: 20px; animation-delay: 0.30s; }
.fw-bars span:nth-child(7) { height: 32px; animation-delay: 0.36s; }
.fw-bars span:nth-child(8) { height: 10px; animation-delay: 0.42s; }
.fw-bars span:nth-child(9) { height: 22px; animation-delay: 0.48s; }
.fw-bars span:nth-child(10) { height: 14px; animation-delay: 0.54s; }
.fw-bars span:nth-child(11) { height: 8px; animation-delay: 0.60s; }
.fw-bars span:nth-child(12) { height: 18px; animation-delay: 0.66s; }
.fw-bars span:nth-child(13) { height: 26px; animation-delay: 0.72s; }
.fw-bars span:nth-child(14) { height: 12px; animation-delay: 0.78s; }
.fw-bars span:nth-child(15) { height: 20px; animation-delay: 0.84s; }

.fw-stream {
  font-family: var(--font-mono);
  font-size: 0.8125rem;
  color: var(--accent-blue);
}

.fw-cursor {
  animation: blink-cursor 0.8s step-end infinite;
}

/* ==========================================
   CTA / FOOTER
   ========================================== */
.cta-footer {
  position: relative;
  overflow: hidden;
}

.cta-bg {
  position: absolute;
  inset: 0;
  background: linear-gradient(135deg,
    rgba(65, 176, 177, 0.08) 0%,
    rgba(13, 13, 20, 0) 25%,
    rgba(81, 152, 201, 0.06) 50%,
    rgba(13, 13, 20, 0) 75%,
    rgba(129, 140, 248, 0.08) 100%
  );
  background-size: 300% 300%;
  animation: cta-shift 8s ease infinite;
}

@keyframes cta-shift {
  0% { background-position: 0% 0%; }
  50% { background-position: 100% 100%; }
  100% { background-position: 0% 0%; }
}

.cta-content {
  position: relative;
  text-align: center;
  padding: 160px 24px 120px;
}

.cta-heading {
  font-size: clamp(2.5rem, 6vw, 5rem);
  font-weight: 700;
  letter-spacing: -0.04em;
  color: var(--text-bright);
  margin-bottom: calc(var(--space) * 2);
}

.cta-sub {
  font-size: 1.125rem;
  color: var(--muted);
  margin-bottom: calc(var(--space) * 5);
}

.cta-buttons {
  display: flex;
  gap: calc(var(--space) * 2);
  justify-content: center;
  flex-wrap: wrap;
}

/* Footer bottom */
.footer-bottom {
  border-top: 1px solid rgba(255, 255, 255, 0.04);
  padding: calc(var(--space) * 4) 0;
}

.footer-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: calc(var(--space) * 3);
}

.footer-brand {
  display: flex;
  align-items: center;
  gap: 8px;
  font-weight: 600;
  font-size: 0.9375rem;
  color: var(--text-bright);
}

.footer-links {
  display: flex;
  gap: calc(var(--space) * 3);
}

.footer-links a {
  font-size: 0.875rem;
  color: var(--muted);
  transition: color 0.3s var(--ease);
}

.footer-links a:hover {
  color: var(--text);
}

.footer-copy {
  font-size: 0.8125rem;
  color: var(--muted);
}

/* ==========================================
   RESPONSIVE
   ========================================== */
/* ==========================================
   RESPONSIVE — TABLET (1024px)
   ========================================== */
@media (max-width: 1024px) {
  .product-inner {
    grid-template-columns: 1fr;
    gap: calc(var(--space) * 6);
  }

  .product-visual {
    min-height: 200px;
  }

  .moments {
    grid-template-columns: 1fr;
    gap: calc(var(--space) * 3);
  }

  .provider-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .features-grid {
    grid-template-columns: 1fr;
  }

  .feature--large,
  .feature--offset-right,
  .feature--wide,
  .feature--offset-left,
  .feature--large:last-of-type {
    grid-column: span 1;
  }

  .product {
    padding: 100px 0;
  }

  .providers {
    padding: 100px 0 80px;
  }

  .styles {
    padding: 80px 0 100px;
  }

  .features {
    padding: 100px 0 80px;
  }
}

/* ==========================================
   RESPONSIVE — MOBILE (768px)
   ========================================== */
@media (max-width: 768px) {
  /* Nav */
  .nav-links {
    display: none;
  }

  .nav-toggle {
    display: flex;
  }

  .nav-inner {
    height: 60px;
  }

  /* Hero */
  .hero {
    min-height: 100svh;
    padding: 80px 0 60px;
  }

  .hero-content {
    padding: 0 20px;
  }

  .hero-headline {
    font-size: clamp(2.5rem, 13vw, 4.5rem);
    margin-bottom: calc(var(--space) * 3);
  }

  .hero-badge {
    margin-bottom: calc(var(--space) * 3);
    font-size: 0.6875rem;
  }

  .hero-sub {
    font-size: 1rem;
    margin-bottom: calc(var(--space) * 4);
  }

  .scroll-hint {
    bottom: 24px;
  }

  /* Sections — tighter padding */
  .section-heading {
    font-size: clamp(1.75rem, 7vw, 2.5rem);
  }

  .product {
    padding: 80px 0;
  }

  .product-stages {
    gap: calc(var(--space) * 2);
  }

  .product-stage h3 {
    font-size: 0.875rem;
  }

  /* How it works */
  .moments {
    gap: calc(var(--space) * 4);
  }

  .moment {
    padding: calc(var(--space) * 3);
  }

  .moment-number {
    font-size: clamp(5rem, 20vw, 8rem);
  }

  .moment-title {
    font-size: 1.125rem;
  }

  /* Providers */
  .provider-grid {
    grid-template-columns: 1fr;
    gap: calc(var(--space) * 2);
  }

  .provider-card {
    padding: calc(var(--space) * 3);
  }

  .marquee-item {
    font-size: clamp(1.5rem, 8vw, 3rem);
  }

  /* Styles section */
  .style-output {
    padding: calc(var(--space) * 3);
    min-height: 120px;
  }

  .style-text {
    font-size: 1rem;
    line-height: 1.6;
  }

  .style-buttons {
    gap: 6px;
    /* Horizontal scroll on mobile for many buttons */
    flex-wrap: nowrap;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
    padding-bottom: 8px;
  }

  .style-buttons::-webkit-scrollbar {
    display: none;
  }

  .style-btn {
    padding: 8px 16px;
    font-size: 0.75rem;
    white-space: nowrap;
    flex-shrink: 0;
  }

  /* Features */
  .feature {
    padding: calc(var(--space) * 3);
  }

  .feature h3 {
    font-size: 1.125rem;
  }

  .feature-wave-demo {
    flex-direction: column;
    align-items: flex-start;
    gap: calc(var(--space) * 2);
  }

  /* CTA */
  .cta-content {
    padding: 100px 20px 80px;
  }

  .cta-heading {
    font-size: clamp(2rem, 8vw, 3.5rem);
  }

  /* Footer */
  .footer-inner {
    flex-direction: column;
    text-align: center;
  }

  .footer-links {
    flex-wrap: wrap;
    justify-content: center;
  }
}

/* ==========================================
   RESPONSIVE — SMALL MOBILE (480px)
   ========================================== */
@media (max-width: 480px) {
  .hero-headline {
    font-size: clamp(2.2rem, 14vw, 3.5rem);
  }

  .hero-ctas {
    flex-direction: column;
    align-items: stretch;
  }

  .hero-ctas .btn {
    text-align: center;
    justify-content: center;
  }

  .cta-buttons {
    flex-direction: column;
    align-items: stretch;
  }

  .cta-buttons .btn {
    text-align: center;
    justify-content: center;
  }

  .moment-number {
    font-size: 4rem;
  }

  .provider-card h3 {
    font-size: 1.0625rem;
  }

  .container {
    padding: 0 16px;
  }
}

/* ==========================================
   TOUCH DEVICES
   ========================================== */
@media (pointer: coarse) {
  /* Hide custom cursor */
  .cursor,
  .cursor-glow {
    display: none !important;
  }

  /* Larger tap targets */
  .style-btn {
    min-height: 44px;
    display: flex;
    align-items: center;
  }

  .nav-link {
    min-height: 44px;
    display: flex;
    align-items: center;
  }

  /* Disable hover effects that feel wrong on touch */
  .provider-card:hover {
    transform: none;
  }

  .feature:hover {
    transform: none;
  }

  /* Touch hint on hero canvas */
  .hero::after {
    content: 'touch & drag';
    position: absolute;
    bottom: 80px;
    left: 50%;
    transform: translateX(-50%);
    font-size: 0.6875rem;
    font-weight: 500;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    color: rgba(65, 176, 177, 0.3);
    z-index: 2;
    animation: fade-hint 4s ease forwards;
    pointer-events: none;
  }

  @keyframes fade-hint {
    0% { opacity: 0; }
    20% { opacity: 1; }
    80% { opacity: 1; }
    100% { opacity: 0; }
  }
}

/* --- Reduced Motion --- */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }

  .marquee-track {
    animation: none;
  }

  [data-scroll-reveal] {
    opacity: 1;
    transform: none;
  }

  .hero-line .char {
    opacity: 1;
    transform: none;
  }
}
