/* ==========================================================================
   CARVOICE.SI — APPLE-GRADE AUTOMOTIVE SUPERINTELLIGENCE STYLESHEET
   Pure black minimalism, frosted glass, surgical Swiss watchmaker tachometer
   ========================================================================== */

:root {
  --bg-black: #000000;
  --bg-elevated: #161618;
  --bg-surface: #1c1c1e;
  --bg-pill: rgba(255, 255, 255, 0.08);
  
  --border-subtle: rgba(255, 255, 255, 0.08);
  --border-focus: rgba(255, 255, 255, 0.25);
  
  --text-primary: #f5f5f7;
  --text-secondary: #86868b;
  --text-tertiary: #6e6e73;
  
  --accent-red: #ff3b30;
  --accent-amber: #ff9f0a;
  --accent-green: #30d158;
  --accent-white: #ffffff;
  
  --font-system: -apple-system, BlinkMacSystemFont, "SF Pro Display", "SF Pro Text", "Inter", sans-serif;
  --font-mono: "Space Grotesk", -apple-system, monospace, sans-serif;
  
  --radius-sm: 8px;
  --radius-md: 14px;
  --radius-lg: 22px;
  --radius-pill: 980px;
  
  --ease-apple: cubic-bezier(0.16, 1, 0.3, 1);
}

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

html {
  scroll-behavior: smooth;
  font-family: var(--font-system);
  background-color: var(--bg-black);
  color: var(--text-primary);
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

body {
  position: relative;
  min-height: 100vh;
  background-color: var(--bg-black);
  color: var(--text-primary);
  overflow-x: hidden;
}

.container {
  width: 100%;
  max-width: 1140px;
  margin: 0 auto;
  padding: 0 24px;
}

/* Subtle Apple Ambient Glow */
.ambient-glow {
  position: fixed;
  top: -15%;
  left: 50%;
  transform: translateX(-50%);
  width: 800px;
  height: 500px;
  background: radial-gradient(circle, rgba(255, 255, 255, 0.04) 0%, transparent 65%);
  pointer-events: none;
  z-index: 0;
}

/* Header */
.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  background: rgba(0, 0, 0, 0.75);
  border-bottom: 1px solid var(--border-subtle);
  padding: 14px 0;
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.brand-logo {
  display: flex;
  align-items: center;
  gap: 10px;
  text-decoration: none;
  color: var(--text-primary);
}

.logo-mark {
  width: 24px;
  height: 24px;
  color: var(--text-primary);
}

.logo-text {
  font-size: 1.15rem;
  font-weight: 600;
  letter-spacing: -0.02em;
}

.tld-badge {
  font-size: 0.75rem;
  font-weight: 500;
  color: var(--text-secondary);
  margin-left: 2px;
}

.header-right {
  display: flex;
  align-items: center;
  gap: 20px;
}

.status-indicator {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 0.75rem;
  color: var(--text-secondary);
  font-weight: 400;
}

.indicator-dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background-color: var(--accent-green);
  box-shadow: 0 0 8px rgba(48, 209, 88, 0.5);
}

.lang-selector {
  display: flex;
  align-items: center;
  gap: 6px;
  background: var(--bg-pill);
  padding: 3px 8px;
  border-radius: var(--radius-pill);
  border: 1px solid var(--border-subtle);
}

.lang-btn {
  background: transparent;
  border: none;
  color: var(--text-secondary);
  font-size: 0.75rem;
  font-weight: 600;
  cursor: pointer;
  padding: 3px 6px;
  border-radius: var(--radius-sm);
  transition: all 0.2s;
}

.lang-btn:hover { color: var(--text-primary); }
.lang-btn.active {
  background: rgba(255, 255, 255, 0.15);
  color: #fff;
}

.lang-sep { color: var(--text-tertiary); font-size: 0.7rem; }

/* Hero Section */
.hero-section {
  position: relative;
  z-index: 10;
  padding: 80px 0 60px;
}

.hero-content {
  text-align: center;
  max-width: 820px;
  margin: 0 auto;
}

.hero-badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: var(--bg-pill);
  border: 1px solid var(--border-subtle);
  padding: 6px 14px;
  border-radius: var(--radius-pill);
  font-size: 0.8rem;
  color: var(--text-secondary);
  margin-bottom: 28px;
}

.badge-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--accent-red);
}

.hero-title {
  font-size: clamp(2.8rem, 5.5vw, 4.4rem);
  font-weight: 700;
  letter-spacing: -0.03em;
  line-height: 1.08;
  margin-bottom: 24px;
}

.title-top {
  color: var(--text-secondary);
  font-weight: 600;
}

.title-gradient {
  background: linear-gradient(180deg, #ffffff 30%, #86868b 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

.hero-subtitle {
  font-size: 1.25rem;
  color: var(--text-secondary);
  font-weight: 400;
  line-height: 1.6;
  max-width: 680px;
  margin: 0 auto 40px;
}

/* Clean Apple Waitlist Input Pill */
.waitlist-container {
  max-width: 540px;
  margin: 0 auto 60px;
}

.input-pill {
  display: flex;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid var(--border-subtle);
  backdrop-filter: blur(20px);
  padding: 6px;
  border-radius: var(--radius-pill);
  transition: all 0.25s var(--ease-apple);
}

.input-pill:focus-within {
  border-color: var(--border-focus);
  box-shadow: 0 0 0 4px rgba(255, 255, 255, 0.05);
}

.input-pill input {
  flex: 1;
  background: transparent;
  border: none;
  outline: none;
  color: var(--text-primary);
  padding: 12px 20px;
  font-size: 0.95rem;
  font-family: var(--font-system);
}

.input-pill input::placeholder {
  color: var(--text-tertiary);
}

.cta-pill {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: var(--text-primary);
  color: #000000;
  font-family: var(--font-system);
  font-weight: 600;
  font-size: 0.9rem;
  border: none;
  cursor: pointer;
  padding: 12px 24px;
  border-radius: var(--radius-pill);
  text-decoration: none;
  transition: all 0.2s var(--ease-apple);
}

.cta-pill:hover {
  background: #ffffff;
  transform: scale(1.02);
}

.cta-pill.large {
  padding: 16px 36px;
  font-size: 1rem;
}

.form-feedback {
  margin-top: 12px;
  font-size: 0.85rem;
  min-height: 20px;
}
.form-feedback.success { color: var(--accent-green); }
.form-feedback.error { color: var(--accent-red); }

.waitlist-stats {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  font-size: 0.85rem;
  color: var(--text-tertiary);
  margin-top: 14px;
}

.stats-sep { color: var(--border-subtle); }

/* ==========================================================================
   COCKPIT PRECISION INSTRUMENT CLUSTER
   ========================================================================== */
.cockpit-showcase {
  margin-top: 20px;
}

.instrument-deck {
  background: var(--bg-elevated);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-lg);
  padding: 32px;
  box-shadow: 0 30px 80px rgba(0, 0, 0, 0.8);
}

.deck-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding-bottom: 24px;
  border-bottom: 1px solid var(--border-subtle);
  margin-bottom: 32px;
}

.mode-tag {
  display: block;
  font-size: 0.7rem;
  font-weight: 600;
  letter-spacing: 0.08em;
  color: var(--text-tertiary);
  margin-bottom: 2px;
}

.mode-title {
  font-size: 1.05rem;
  font-weight: 600;
  color: var(--text-primary);
}

.action-btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: var(--bg-pill);
  border: 1px solid var(--border-subtle);
  color: var(--text-primary);
  font-size: 0.8rem;
  font-weight: 500;
  padding: 8px 16px;
  border-radius: var(--radius-pill);
  cursor: pointer;
  transition: all 0.2s;
}

.action-btn:hover {
  background: rgba(255, 255, 255, 0.12);
}

.action-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--accent-red);
}

.instrument-grid {
  display: grid;
  grid-template-columns: 260px 1fr 260px;
  gap: 32px;
  align-items: center;
  margin-bottom: 32px;
}

/* Telemetry Cards */
.telemetry-card {
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.card-metric {
  background: rgba(255, 255, 255, 0.02);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  padding: 16px;
}

.metric-label {
  display: block;
  font-size: 0.7rem;
  font-weight: 600;
  letter-spacing: 0.06em;
  color: var(--text-tertiary);
  margin-bottom: 6px;
}

.metric-val {
  display: block;
  font-family: var(--font-mono);
  font-size: 1.4rem;
  font-weight: 700;
  color: var(--text-primary);
  line-height: 1.2;
}

.metric-val small {
  font-size: 0.75rem;
  color: var(--text-secondary);
  font-weight: 400;
}

.metric-bar {
  height: 4px;
  background: rgba(255, 255, 255, 0.06);
  border-radius: var(--radius-pill);
  margin-top: 10px;
  overflow: hidden;
}

.metric-fill {
  height: 100%;
  background: var(--text-primary);
  border-radius: var(--radius-pill);
  transition: width 0.4s var(--ease-apple);
}

/* The Swiss-Precision Tachometer */
.tachometer-module {
  display: flex;
  justify-content: center;
}

.tachometer-housing {
  position: relative;
  width: 320px;
  height: 320px;
  border-radius: 50%;
  background: radial-gradient(circle at 50% 50%, #1c1c1e 0%, #101012 100%);
  border: 1px solid rgba(255, 255, 255, 0.12);
  box-shadow: inset 0 2px 6px rgba(255, 255, 255, 0.08), 0 20px 50px rgba(0, 0, 0, 0.9);
}

.dial-inner {
  position: absolute;
  inset: 0;
}

.dial-svg {
  width: 100%;
  height: 100%;
}

.dial-digit {
  font-family: var(--font-mono);
  font-size: 14px;
  font-weight: 600;
  fill: #86868b;
  text-anchor: middle;
  dominant-baseline: central;
}

.redline-digit {
  fill: var(--accent-red);
}

.dial-brand {
  font-family: var(--font-mono);
  font-size: 10px;
  font-weight: 700;
  fill: rgba(255, 255, 255, 0.25);
  letter-spacing: 2px;
  text-anchor: middle;
}

.dial-unit {
  font-size: 8px;
  font-weight: 500;
  fill: var(--text-tertiary);
  text-anchor: middle;
}

/* Needle */
.needle-assembly {
  position: absolute;
  top: 50%;
  left: 50%;
  width: 2px;
  height: 115px;
  margin-left: -1px;
  margin-top: -115px;
  transform-origin: 50% 100%;
  transform: rotate(-130deg); /* 0 RPM default */
  transition: transform 0.25s var(--ease-apple);
  z-index: 10;
  pointer-events: none;
}

.needle-line {
  width: 100%;
  height: 100%;
  background: var(--accent-red);
  border-radius: 2px;
  box-shadow: 0 0 8px rgba(255, 59, 48, 0.5);
}

/* Center Titanium Hub */
.dial-center-hub {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 106px;
  height: 106px;
  border-radius: 50%;
  background: #161618;
  border: 1px solid rgba(255, 255, 255, 0.15);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  z-index: 15;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.6);
}

.hub-gear {
  font-family: var(--font-mono);
  font-size: 1.35rem;
  font-weight: 700;
  color: var(--accent-red);
  line-height: 1;
}

.hub-rpm {
  font-family: var(--font-mono);
  font-size: 0.9rem;
  font-weight: 700;
  color: var(--text-primary);
  margin-top: 2px;
}

.hub-rpm small {
  font-size: 0.55rem;
  color: var(--text-tertiary);
  font-weight: 400;
}

.hub-speed {
  font-size: 0.7rem;
  color: var(--text-secondary);
}

/* Right Telemetry Column */
.g-force-box {
  background: rgba(255, 255, 255, 0.02);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  padding: 16px;
  text-align: center;
}

.g-circle {
  width: 50px;
  height: 50px;
  border-radius: 50%;
  border: 1px solid var(--border-subtle);
  margin: 10px auto 8px;
  position: relative;
}

.g-vector {
  position: absolute;
  top: 50%;
  left: 50%;
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--text-primary);
  transform: translate(-50%, -50%);
  transition: all 0.2s;
}

.g-readout {
  font-family: var(--font-mono);
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--text-primary);
}

.countdown-subdeck {
  background: rgba(255, 255, 255, 0.02);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  padding: 16px;
}

.countdown-digits {
  display: flex;
  justify-content: space-between;
  margin-top: 8px;
}

.c-unit span {
  font-family: var(--font-mono);
  font-size: 1.25rem;
  font-weight: 700;
  color: var(--text-primary);
}

.c-unit small {
  font-size: 0.7rem;
  color: var(--text-tertiary);
  margin-left: 2px;
}

/* Acoustic Wave Bar (Siri Harmonic Fluid Wave) */
.acoustic-bar {
  padding-top: 20px;
  border-top: 1px solid var(--border-subtle);
}

.acoustic-meta {
  display: flex;
  justify-content: space-between;
  font-size: 0.75rem;
  color: var(--text-tertiary);
  margin-bottom: 8px;
}

.meta-tag {
  font-weight: 600;
  letter-spacing: 0.05em;
  color: var(--text-secondary);
}

#neuralCanvas {
  width: 100%;
  height: 90px;
  display: block;
}

/* ==========================================================================
   SCENARIOS SECTION (APPLE SEGMENTED CONTROLS)
   ========================================================================== */
.scenarios-section {
  padding: 100px 0 60px;
}

.section-heading {
  margin-bottom: 48px;
}

.section-tag {
  font-size: 0.8rem;
  font-weight: 600;
  letter-spacing: 0.08em;
  color: var(--text-tertiary);
  margin-bottom: 8px;
}

.section-title {
  font-size: clamp(2rem, 3.8vw, 3rem);
  font-weight: 700;
  letter-spacing: -0.02em;
  margin-bottom: 14px;
}

.section-desc {
  font-size: 1.15rem;
  color: var(--text-secondary);
  max-width: 620px;
  margin: 0 auto;
}

.scenario-deck {
  max-width: 860px;
  margin: 0 auto;
}

.segmented-control {
  display: flex;
  background: rgba(255, 255, 255, 0.06);
  padding: 4px;
  border-radius: var(--radius-pill);
  gap: 4px;
  margin-bottom: 24px;
}

.seg-btn {
  flex: 1;
  background: transparent;
  border: none;
  color: var(--text-secondary);
  font-family: var(--font-system);
  font-size: 0.85rem;
  font-weight: 500;
  padding: 10px 16px;
  border-radius: var(--radius-pill);
  cursor: pointer;
  transition: all 0.2s var(--ease-apple);
}

.seg-btn:hover { color: var(--text-primary); }
.seg-btn.active {
  background: rgba(255, 255, 255, 0.15);
  color: #fff;
}

.dialog-hud {
  background: var(--bg-elevated);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-lg);
  padding: 28px;
}

.hud-bar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding-bottom: 18px;
  border-bottom: 1px solid var(--border-subtle);
  margin-bottom: 24px;
}

.hud-pill {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 0.75rem;
  color: var(--text-secondary);
}

.hud-pill strong { color: var(--text-primary); }

.hud-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--accent-green);
}

.voice-play-pill {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: var(--text-primary);
  color: #000;
  font-family: var(--font-system);
  font-size: 0.8rem;
  font-weight: 600;
  border: none;
  cursor: pointer;
  padding: 8px 18px;
  border-radius: var(--radius-pill);
  transition: all 0.2s;
}

.voice-play-pill:hover {
  background: #fff;
  transform: scale(1.02);
}

.dialog-flow {
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.speech-bubble {
  padding: 16px;
  border-radius: var(--radius-md);
  background: rgba(255, 255, 255, 0.02);
  border: 1px solid var(--border-subtle);
}

.bubble-sender {
  font-size: 0.65rem;
  font-weight: 600;
  letter-spacing: 0.05em;
  color: var(--text-tertiary);
  margin-bottom: 6px;
}

.bubble-text {
  font-size: 1.05rem;
  color: var(--text-secondary);
  line-height: 1.5;
}

.ai-bubble .bubble-sender {
  color: var(--accent-red);
}

.ai-bubble .bubble-text {
  color: var(--text-primary);
  font-weight: 500;
}

/* ==========================================================================
   FEATURES GRID (APPLE 3-COLUMN)
   ========================================================================== */
.features-section {
  padding: 80px 0 100px;
}

.features-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
}

.feature-card {
  background: var(--bg-elevated);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-lg);
  padding: 36px 28px;
  transition: transform 0.3s var(--ease-apple);
}

.feature-card:hover {
  transform: translateY(-4px);
  border-color: var(--border-focus);
}

.feature-icon {
  width: 44px;
  height: 44px;
  border-radius: var(--radius-sm);
  background: rgba(255, 255, 255, 0.05);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--text-primary);
  margin-bottom: 24px;
}

.feature-card h3 {
  font-size: 1.25rem;
  font-weight: 600;
  letter-spacing: -0.01em;
  margin-bottom: 12px;
}

.feature-card p {
  font-size: 0.95rem;
  color: var(--text-secondary);
  line-height: 1.6;
}

/* Final CTA */
.final-cta {
  padding: 80px 0 120px;
}

.final-title {
  font-size: clamp(2rem, 4vw, 3rem);
  font-weight: 700;
  letter-spacing: -0.02em;
  margin-bottom: 16px;
}

.final-desc {
  font-size: 1.15rem;
  color: var(--text-secondary);
  max-width: 580px;
  margin: 0 auto 36px;
}

/* Footer */
.site-footer {
  border-top: 1px solid var(--border-subtle);
  padding: 40px 0;
}

.footer-inner {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 20px;
}

.footer-logo {
  font-size: 1rem;
  font-weight: 600;
}

.footer-legal {
  font-size: 0.75rem;
  color: var(--text-tertiary);
  margin-top: 4px;
}

.footer-links {
  display: flex;
  gap: 24px;
}

.footer-links a {
  color: var(--text-secondary);
  text-decoration: none;
  font-size: 0.85rem;
  transition: color 0.2s;
}

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

/* Responsive */
@media (max-width: 992px) {
  .instrument-grid {
    grid-template-columns: 1fr;
    gap: 24px;
  }
  .left-telemetry, .right-telemetry {
    display: grid;
    grid-template-columns: 1fr 1fr;
  }
  .features-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 768px) {
  .hero-section { padding: 50px 0 30px; }
  .header-right .status-indicator { display: none; }
  .input-pill {
    flex-direction: column;
    border-radius: var(--radius-lg);
  }
  .cta-pill { width: 100%; justify-content: center; }
  .segmented-control { flex-direction: column; border-radius: var(--radius-lg); }
  .left-telemetry, .right-telemetry { grid-template-columns: 1fr; }
  .footer-inner { flex-direction: column; text-align: center; }
  .footer-links { justify-content: center; }
}
