:root {
  --bg-primary: #ffffff;
  --bg-secondary: #fafafa;
  --bg-tertiary: #f2f2f5;
  --bg-card: #ffffff;
  
  --border-color: #12151a;
  --border-muted: #e2e8f0;
  
  --accent: #ea5b0c;
  --accent-hover: #ff7324;
  --accent-rgb: 234, 91, 12;
  
  --text-primary: #12151a;
  --text-secondary: #4a505c;
  --text-muted: #8a92a0;
  
  --font-display: Inter, Arial, Helvetica, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  --font-mono: SFMono-Regular, Consolas, "Liberation Mono", Menlo, Courier, monospace;
  --font-body: Inter, Arial, Helvetica, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  
  --transition: all 0.25s cubic-bezier(0.16, 1, 0.3, 1);
  --max-width: 1300px;
}

html {
  overflow-x: hidden;
  scroll-behavior: smooth;
}

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

body {
  font-family: var(--font-body);
  background-color: var(--bg-primary);
  color: var(--text-primary);
  line-height: 1.6;
  overflow-x: hidden;
}

/* Custom Scrollbar */
::-webkit-scrollbar {
  width: 8px;
}
::-webkit-scrollbar-track {
  background: var(--bg-secondary);
}
::-webkit-scrollbar-thumb {
  background: var(--border-color);
}

/* Typography & Structural Elements */
h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-display);
  font-weight: 800;
  letter-spacing: -0.04em; /* Tight editorial letter spacing */
  text-transform: uppercase;
  color: var(--text-primary);
}

p {
  color: var(--text-secondary);
}

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

img {
  max-width: 100%;
  height: auto;
  display: block;
}

.container {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 40px;
}

.text-accent {
  color: var(--accent);
}

/* Structural Badges */
.badge {
  display: inline-block;
  font-family: var(--font-mono);
  font-size: 0.75rem;
  font-weight: 700;
  text-transform: uppercase;
  color: var(--accent);
  background: transparent;
  border: 1px solid var(--accent);
  padding: 4px 10px;
  margin-bottom: 20px;
  letter-spacing: 0.05em;
}

.mono-label {
  font-family: var(--font-mono);
  font-size: 0.75rem;
  text-transform: uppercase;
  color: var(--text-muted);
  letter-spacing: 0.1em;
}

/* Custom Buttons (Editorial look) */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 16px 32px;
  font-family: var(--font-mono);
  font-weight: 700;
  font-size: 0.8rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  cursor: pointer;
  transition: var(--transition);
  border-radius: 0;
  border: 1px solid var(--border-color);
  gap: 12px;
}

.btn-primary {
  background-color: var(--border-color);
  color: #ffffff;
}

.btn-primary:hover {
  background-color: var(--accent);
  border-color: var(--accent);
}

.btn-secondary {
  background-color: transparent;
  color: var(--text-primary);
}

.btn-secondary:hover {
  background-color: var(--bg-tertiary);
}

/* Header & Navigation */
header {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  z-index: 1000;
  background: rgba(255, 255, 255, 0.9);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--border-color);
  transition: var(--transition);
}

header.scrolled {
  padding: 5px 0;
}

.header-container {
  display: flex;
  justify-content: space-between;
  align-items: center;
  height: 90px;
  transition: var(--transition);
}

header.scrolled .header-container {
  height: 70px;
}

.logo-wrapper {
  display: flex;
  align-items: center;
  margin-right: 45px;
}

.logo-wrapper img {
  height: 54px;
  width: auto;
  object-fit: contain;
}

header.scrolled .logo-wrapper img {
  height: 44px;
}

nav {
  margin-left: auto;
  margin-right: auto;
}

nav ul {
  display: flex;
  list-style: none;
  border-left: 1px solid var(--border-color);
}

nav ul li {
  border-right: 1px solid var(--border-color);
}

nav ul li a {
  display: block;
  padding: 12px 24px;
  font-family: var(--font-body);
  font-weight: 700;
  font-size: 0.8rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--text-secondary);
  white-space: nowrap;
}

nav ul li a:hover, nav ul li a.active {
  color: var(--accent);
  background: var(--bg-secondary);
}

.mobile-nav-toggle {
  display: none;
  background: transparent;
  border: 1px solid var(--border-color);
  width: 44px;
  height: 44px;
  color: var(--text-primary);
  font-size: 1.2rem;
  cursor: pointer;
  align-items: center;
  justify-content: center;
}

/* Main Area */
main {
  margin-top: 90px;
}

.page-section {
  display: none;
  opacity: 0;
  transition: opacity 0.4s ease;
  padding: 100px 0;
}

#home.page-section {
  padding: 0;
}

.page-section.active {
  display: block;
  opacity: 1;
}

/* ----------------- SECTION: HOME ----------------- */
/* Hero Section (Centered Dark Layout) */
.hero {
  position: relative;
  min-height: 85vh;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  border-bottom: 1px solid var(--border-color);
  overflow: hidden;
}

.hero-slideshow {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: 1;
  overflow: hidden;
  background-color: #0c0d10; /* Dark background prevents white-flashing during transitions */
}

.hero-slide {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-size: cover;
  background-position: center 38%; /* Vertically centers the drivers' faces/helmets */
  transform-origin: center 38%;    /* Zooms in/out directly from the faces to prevent cropping during animation */
  opacity: 0;
  transition: opacity 1.5s ease-in-out; /* Smooth cross-fade transition */
  filter: brightness(0.32) contrast(1.05); /* Darkened for strong contrast */
  transform: scale(1.02);
  animation: slowZoom 20s infinite alternate ease-in-out; /* Continuous zoom prevents snapping on class toggle */
}

.hero-slide.active {
  opacity: 1;
}

.hero-gradient-overlay {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: 2;
  background: rgba(18, 21, 26, 0.45); /* Extra dark layer */
}

.hero-container-inner {
  position: relative;
  z-index: 3;
  width: 100%;
  display: flex;
  justify-content: center;
}

.hero-content-wrapper {
  max-width: 850px;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
}

.hero h1 {
  font-size: 4rem;
  line-height: 0.95;
  margin-bottom: 24px;
  font-weight: 800;
  color: #ffffff !important;
}

.hero .text-gradient {
  background: linear-gradient(135deg, #ffffff 45%, #ffb380 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

.hero .sub-headline {
  font-size: 1.25rem;
  color: #e2e8f0; /* Crisp light silver for readability */
  margin-bottom: 40px;
  max-width: 650px;
}

.hero-ctas {
  display: flex;
  justify-content: center;
  gap: 20px;
}

.hero-ctas .btn-primary {
  background-color: var(--accent) !important;
  border-color: var(--accent) !important;
  color: #ffffff !important;
}

.hero-ctas .btn-primary:hover {
  background-color: var(--accent-hover) !important;
  border-color: var(--accent-hover) !important;
}

.hero-ctas .btn-secondary {
  color: var(--text-primary) !important;
  border: 1px solid var(--border-color) !important;
  background: transparent !important;
}

.hero-ctas .btn-secondary:hover {
  background: var(--border-color) !important;
  color: #ffffff !important;
  border-color: var(--border-color) !important;
}

/* Overrides specifically for the dark Hero background */
.hero .hero-ctas .btn-secondary {
  color: #ffffff !important;
  border: 1px solid rgba(255, 255, 255, 0.5) !important;
  background: rgba(255, 255, 255, 0.08) !important;
}

.hero .hero-ctas .btn-secondary:hover {
  background: #ffffff !important;
  color: #000000 !important;
  border-color: #ffffff !important;
}

/* Trust Banner (Datasheet layout) */
.trust-banner {
  background: var(--bg-secondary);
  border-bottom: 1px solid var(--border-color);
}

.trust-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
}

.trust-item {
  padding: 40px;
  border-right: 1px solid var(--border-color);
  text-align: center;
}

.trust-item:last-child {
  border-right: none;
}

.trust-number {
  font-family: var(--font-display);
  font-size: 3rem;
  font-weight: 800;
  color: var(--accent);
  line-height: 1;
  margin-bottom: 10px;
  display: block;
}

.trust-text {
  font-family: var(--font-mono);
  font-size: 0.7rem;
  color: var(--text-secondary);
  text-transform: uppercase;
  letter-spacing: 0.05em;
  font-weight: 700;
  display: block;
}

/* Offering / Bento Grid (Strict Outlines) */
.offering-section {
  padding: 120px 0;
  border-bottom: 1px solid var(--border-color);
}

.section-header-editorial {
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
  margin-bottom: 60px;
  border-bottom: 1px solid var(--border-color);
  padding-bottom: 30px;
}

.section-title {
  font-size: 3rem;
}

.grid-cards {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  border: 1px solid var(--border-color);
}

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

.card {
  background: var(--bg-card);
  padding: 50px 40px;
  border-right: 1px solid var(--border-color);
  transition: var(--transition);
  display: flex;
  flex-direction: column;
}

.card:last-child {
  border-right: none;
}

.card:hover {
  background: var(--bg-secondary);
}

.card-icon {
  font-size: 2.5rem;
  color: var(--accent);
  margin-bottom: 30px;
}

.card h3 {
  font-size: 1.6rem;
  margin-bottom: 16px;
}

.card p {
  font-size: 0.95rem;
  margin-bottom: 30px;
  flex-grow: 1;
}

.card-list {
  list-style: none;
  margin-bottom: 40px;
}

.card-list li {
  font-family: var(--font-mono);
  font-size: 0.75rem;
  color: var(--text-secondary);
  margin-bottom: 12px;
  display: flex;
  align-items: center;
  gap: 12px;
}

.card-list li::before {
  content: '→';
  color: var(--accent);
  font-weight: bold;
}

/* Timeline Flow (Structural Grid) */
.process-section {
  padding: 120px 0;
  border-bottom: 1px solid var(--border-color);
}

.timeline {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  border: 1px solid var(--border-color);
  margin-top: 60px;
}

.timeline-step {
  padding: 40px 30px;
  border-right: 1px solid var(--border-color);
  position: relative;
  transition: var(--transition);
}

.timeline-step:last-child {
  border-right: none;
}

.timeline-step:hover {
  background: var(--bg-secondary);
}

.timeline-number {
  font-family: var(--font-mono);
  font-size: 2.5rem;
  font-weight: 700;
  color: var(--accent);
  margin-bottom: 20px;
  opacity: 0.3;
  transition: var(--transition);
}

.timeline-step:hover .timeline-number {
  opacity: 1;
}

.timeline-step h4 {
  font-size: 1.1rem;
  margin-bottom: 12px;
}

.timeline-step p {
  font-size: 0.85rem;
}

/* Case Study Teaser Box (Editorial Asymmetrical) */
.case-study-teaser {
  padding: 120px 0;
  border-bottom: 1px solid var(--border-color);
}

.teaser-box {
  display: grid;
  grid-template-columns: 1.1fr 1fr;
  border: 1px solid var(--border-color);
}

.teaser-image {
  height: 100%;
  min-height: 500px;
  background-size: cover;
  background-position: center top; /* Align to top to prevent cropping heads or cars */
  border-right: 1px solid var(--border-color);
}

.teaser-content {
  padding: 60px;
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.teaser-content h3 {
  font-size: 2.2rem;
  margin-bottom: 20px;
  line-height: 1.1;
}

.teaser-content p {
  margin-bottom: 40px;
}

/* Call to Action Block */
.cta-block {
  text-align: center;
  padding: 150px 40px;
  background: var(--bg-secondary);
  border-bottom: 1px solid var(--border-color);
}

.cta-block h2 {
  font-size: 3.5rem;
  line-height: 0.95;
  margin-bottom: 24px;
}

.cta-block p {
  max-width: 600px;
  margin: 0 auto 40px;
  font-size: 1.1rem;
}

/* ----------------- SECTION: PROGRAM ----------------- */
.phases-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  border: 1px solid var(--border-color);
  margin-top: 60px;
  margin-bottom: 80px;
}

.phase-card {
  padding: 50px 40px;
  border-right: 1px solid var(--border-color);
  background: var(--bg-card);
}

.phase-card:last-child {
  border-right: none;
}

.phase-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
  margin-bottom: 30px;
  border-bottom: 1px solid var(--border-color);
  padding-bottom: 20px;
}

.phase-number {
  font-family: var(--font-mono);
  font-size: 2rem;
  color: var(--accent);
  opacity: 0.5;
}

.phase-card h3 {
  font-size: 1.5rem;
}

.phase-list {
  list-style: none;
}

.phase-list li {
  font-size: 0.95rem;
  color: var(--text-secondary);
  padding: 12px 0;
  border-bottom: 1px solid var(--border-muted);
  display: flex;
  align-items: flex-start;
  gap: 12px;
}

.phase-list li:last-child {
  border-bottom: none;
}

.phase-list li::before {
  content: '▸';
  color: var(--accent);
}

/* Parent Info Center */
.parent-info-box {
  border: 1px solid var(--border-color);
  padding: 60px;
  margin: 80px 0;
  background: var(--bg-secondary);
}

.parent-info-content h3 {
  font-size: 2rem;
  margin-bottom: 20px;
  display: flex;
  align-items: center;
  gap: 16px;
}

.parent-info-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 40px;
  margin-top: 40px;
}

.parent-item h4 {
  font-size: 1.15rem;
  margin-bottom: 12px;
}

.parent-item p {
  font-size: 0.9rem;
}

/* Pathways & Pricing */
.pathway-section {
  padding: 100px 0;
}

.pricing-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  border: 1px solid var(--border-color);
  margin-top: 60px;
}

.partner-pricing .pricing-grid {
  grid-template-columns: repeat(3, 1fr);
}

.price-card {
  background: var(--bg-card);
  padding: 40px 30px;
  border-right: 1px solid var(--border-color);
  text-align: left;
  display: flex;
  flex-direction: column;
  position: relative;
}

.price-card:last-child {
  border-right: none;
}

.price-card.featured {
  background: var(--bg-secondary);
}

.price-card.featured::after {
  content: '[ BEST OPTION ]';
  position: absolute;
  top: 24px;
  right: 24px;
  font-family: var(--font-mono);
  font-weight: 700;
  font-size: 0.65rem;
  color: var(--accent);
}

.price-card h3 {
  font-size: 1.3rem;
  margin-bottom: 8px;
}

.price-card p {
  font-size: 0.9rem;
  color: var(--text-secondary);
  line-height: 1.5;
  min-height: 65px; /* Ensures all descriptions take up the same vertical space for perfect grid alignment */
  margin-bottom: 20px;
}

.price-tag {
  font-family: var(--font-mono);
  font-size: 1.25rem;
  font-weight: 700;
  color: var(--accent);
  margin: 20px 0;
  border-bottom: 1px solid var(--border-color);
  padding-bottom: 10px;
}

.price-features {
  list-style: none;
  margin-bottom: 30px;
  flex-grow: 1;
}

.price-features li {
  font-size: 0.85rem;
  color: var(--text-secondary);
  margin-bottom: 12px;
  display: flex;
  gap: 8px;
}

.price-features li::before {
  content: '·';
  color: var(--accent);
  font-weight: 900;
}

/* ----------------- SECTION: FAHRER ----------------- */
.case-study-hero {
  display: grid;
  grid-template-columns: 1.1fr 1fr;
  border: 1px solid var(--border-color);
  margin-top: 60px;
  margin-bottom: 60px;
}

.case-study-media {
  display: flex;
}

.case-study-media img {
  width: 100%;
  height: 100%;
  min-height: 500px;
  object-fit: cover;
  object-position: center top; /* Prevent Mathilda's head from being cut off in portrait photo */
  border-right: 1px solid var(--border-color);
}

.case-study-text {
  padding: 60px;
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.case-study-text h2 {
  font-size: 2.5rem;
  margin-bottom: 20px;
  line-height: 1.05;
}

.driver-stats-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  border: 1px solid var(--border-color);
  margin-bottom: 100px;
}

.stats-card {
  padding: 50px;
  border-right: 1px solid var(--border-color);
}

.stats-card:last-child {
  border-right: none;
}

.stats-card h3 {
  font-size: 1.5rem;
  margin-bottom: 24px;
  border-bottom: 1px solid var(--border-color);
  padding-bottom: 15px;
}

.stats-list li {
  display: flex;
  justify-content: space-between;
  padding: 12px 0;
  border-bottom: 1px solid var(--border-muted);
  font-size: 0.95rem;
}

.stats-label {
  font-family: var(--font-mono);
  font-size: 0.75rem;
  color: var(--text-muted);
}

.stats-value {
  font-weight: 700;
}

/* Image Slider Gallery */
.gallery-section {
  padding: 100px 0;
  border-top: 1px solid var(--border-color);
}

.carousel-container {
  position: relative;
  margin-top: 60px;
  border: 1px solid var(--border-color);
  overflow: hidden;
}

.carousel-track {
  display: flex;
  transition: transform 0.5s cubic-bezier(0.16, 1, 0.3, 1);
  height: 600px;
}

.carousel-slide {
  min-width: 100%;
  height: 100%;
  position: relative;
}

.carousel-slide img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.carousel-caption {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  background: linear-gradient(transparent, rgba(18, 21, 26, 0.9));
  padding: 40px;
  color: #ffffff;
}

.carousel-caption h4 {
  font-size: 1.5rem;
  margin-bottom: 8px;
  color: #ffffff;
}

.carousel-caption p {
  color: var(--border-muted);
}

.carousel-btn {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  background: var(--border-color);
  border: none;
  color: #ffffff;
  width: 60px;
  height: 60px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  z-index: 10;
  font-size: 1.2rem;
  transition: var(--transition);
}

.carousel-btn:hover {
  background: var(--accent);
}

.carousel-btn.prev {
  left: 0;
}

.carousel-btn.next {
  right: 0;
}

/* ----------------- SECTION: PARTNER ----------------- */
.partner-pitch {
  display: grid;
  grid-template-columns: 1.2fr 1fr;
  border: 1px solid var(--border-color);
  margin-top: 60px;
  margin-bottom: 60px;
}

.pitch-text {
  padding: 60px;
  display: flex;
  flex-direction: column;
  justify-content: center;
  border-right: 1px solid var(--border-color);
}

.pitch-text h2 {
  font-size: 2.5rem;
  margin-bottom: 20px;
}

.pitch-image {
  height: 100%;
  min-height: 500px;
  background-size: cover;
  background-position: center;
}

.options-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  border: 1px solid var(--border-color);
}

.option-card {
  padding: 50px 40px;
  border-right: 1px solid var(--border-color);
  background: var(--bg-card);
}

.option-card:last-child {
  border-right: none;
}

.option-icon {
  font-size: 2.5rem;
  color: var(--accent);
  margin-bottom: 24px;
}

.option-card h3 {
  font-size: 1.4rem;
  margin-bottom: 12px;
}

/* Logos list style */
.logo-showcase {
  padding: 100px 0;
  border-top: 1px solid var(--border-color);
}

.logo-grid {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  border: 1px solid var(--border-color);
  margin-top: 50px;
}

.logo-item {
  background: var(--bg-card);
  border-right: 1px solid var(--border-color);
  padding: 30px;
  display: flex;
  align-items: center;
  justify-content: center;
  height: 120px;
  transition: var(--transition);
}

.logo-item:last-child {
  border-right: none;
}

.logo-item img {
  max-height: 50px;
  max-width: 100%;
  object-fit: contain;
  filter: grayscale(1) contrast(1.2);
  opacity: 0.6;
  transition: var(--transition);
}

.logo-item:hover img {
  filter: grayscale(0) contrast(1);
  opacity: 1;
}

/* ----------------- SECTION: BEWERBUNG ----------------- */
.forms-container {
  max-width: 800px;
  margin: 60px auto 0;
}

.form-toggle-wrapper {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  border: 1px solid var(--border-color);
  margin-bottom: 40px;
}

.form-toggle-btn {
  padding: 18px;
  background: transparent;
  border: none;
  color: var(--text-secondary);
  font-family: var(--font-mono);
  font-weight: 700;
  font-size: 0.8rem;
  cursor: pointer;
  transition: var(--transition);
  text-transform: uppercase;
  letter-spacing: 0.05em;
  border-right: 1px solid var(--border-color);
}

.form-toggle-btn:last-child {
  border-right: none;
}

.form-toggle-btn.active {
  background: var(--border-color);
  color: #ffffff;
}

.contact-form-section {
  display: none;
  border: 1px solid var(--border-color);
  padding: 50px;
  background: var(--bg-card);
}

.contact-form-section.active {
  display: block;
}

.contact-form-section h3 {
  font-size: 1.8rem;
  margin-bottom: 30px;
  border-bottom: 1px solid var(--border-color);
  padding-bottom: 15px;
}

.form-group {
  margin-bottom: 24px;
}

.form-row {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 24px;
}

label {
  display: block;
  font-family: var(--font-mono);
  font-size: 0.7rem;
  font-weight: 700;
  text-transform: uppercase;
  margin-bottom: 8px;
  color: var(--text-secondary);
  letter-spacing: 0.05em;
}

input[type="text"],
input[type="email"],
input[type="number"],
input[type="tel"],
select,
textarea {
  width: 100%;
  padding: 16px;
  background: var(--bg-secondary);
  border: 1px solid var(--border-color);
  border-radius: 0;
  color: var(--text-primary);
  font-family: var(--font-body);
  font-size: 0.9rem;
  transition: var(--transition);
}

input:focus,
select:focus,
textarea:focus {
  outline: none;
  border-color: var(--accent);
  background: var(--bg-primary);
}

.file-upload-wrapper {
  border: 1px dashed var(--border-color);
  padding: 40px;
  text-align: center;
  background: var(--bg-secondary);
  cursor: pointer;
  transition: var(--transition);
}

.file-upload-wrapper:hover {
  background: var(--bg-tertiary);
}

.file-upload-wrapper i {
  font-size: 2rem;
  color: var(--text-muted);
  margin-bottom: 12px;
  display: block;
}

.form-feedback {
  margin-top: 30px;
  padding: 24px;
  border: 1px solid var(--border-color);
  display: none;
}

.form-feedback.success {
  background: rgba(234, 91, 12, 0.05);
  border-color: var(--accent);
  color: var(--text-primary);
  display: block;
}

.form-feedback.error {
  background: rgba(220, 38, 38, 0.05);
  border-color: #dc2626;
  color: var(--text-primary);
  display: block;
}

/* ----------------- SECTION: FAQS ----------------- */
.faq-search {
  max-width: 600px;
  margin: 50px auto 40px;
}

.faq-search input {
  padding: 16px 24px;
  font-family: var(--font-mono);
}

.faq-list {
  max-width: 800px;
  margin: 0 auto;
  border-top: 1px solid var(--border-color);
}

.faq-item, .f4-faq-item {
  border-bottom: 1px solid var(--border-color);
  background: var(--bg-card);
  transition: var(--transition);
}

.faq-question, .f4-faq-question {
  padding: 24px;
  cursor: pointer;
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-family: var(--font-display);
  font-weight: 800;
  font-size: 1.1rem;
}

.faq-answer, .f4-faq-answer {
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.4s cubic-bezier(0.16, 1, 0.3, 1);
  background: var(--bg-secondary);
  border-top: 1px solid transparent;
}

.faq-answer-inner, .f4-faq-answer-inner {
  padding: 24px 30px;
  font-size: 0.95rem;
  color: var(--text-secondary);
}

.faq-item.active .faq-answer, .f4-faq-item.active .f4-faq-answer {
  max-height: 500px;
  border-top-color: var(--border-color);
}

.faq-toggle-icon, .f4-faq-toggle-icon {
  font-family: var(--font-mono);
  font-size: 1.2rem;
  color: var(--text-muted);
  transition: var(--transition);
}

.faq-item.active .faq-toggle-icon, .f4-faq-item.active .f4-faq-toggle-icon {
  transform: rotate(45deg);
  color: var(--accent);
}

/* ----------------- FOOTER ----------------- */
footer {
  background: var(--border-color);
  color: #ffffff;
  padding: 80px 0 40px;
  margin-top: 120px;
}

.footer-grid {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr 1.5fr;
  gap: 40px;
  margin-bottom: 60px;
}

.footer-col h4 {
  font-family: var(--font-mono);
  font-size: 0.8rem;
  margin-bottom: 24px;
  color: var(--accent);
  letter-spacing: 0.05em;
}

.footer-col p {
  font-size: 0.9rem;
  margin-bottom: 20px;
  color: var(--border-muted);
}

.footer-col p a {
  color: inherit;
  text-decoration: none;
  transition: var(--transition);
}

.footer-col p a:hover {
  color: var(--accent);
}

.footer-links {
  list-style: none;
}

.footer-links li {
  margin-bottom: 12px;
}

.footer-links li a {
  font-family: var(--font-mono);
  font-size: 0.75rem;
  color: var(--border-muted);
  text-transform: uppercase;
}

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

.social-links {
  display: flex;
  gap: 12px;
}

.social-btn {
  width: 40px;
  height: 40px;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.1);
  display: flex;
  align-items: center;
  justify-content: center;
  transition: var(--transition);
  color: #ffffff;
}

.social-btn:hover {
  background: var(--accent);
  border-color: var(--accent);
  color: #000000;
}

.footer-bottom {
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  padding-top: 40px;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.footer-bottom p {
  font-size: 0.8rem;
  color: var(--border-muted);
}

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

.footer-legal-links a {
  font-family: var(--font-mono);
  font-size: 0.75rem;
  color: var(--border-muted);
  text-transform: uppercase;
}

/* Header Contact Buttons */
.header-contact {
  display: flex;
  align-items: center;
  gap: 10px;
}

.contact-btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-family: var(--font-mono);
  font-size: 0.75rem;
  font-weight: 700;
  color: var(--text-primary);
  border: 1px solid var(--border-color);
  padding: 4px 10px;
  transition: var(--transition);
  text-transform: uppercase;
}

.contact-btn:hover {
  border-color: var(--accent);
  color: var(--accent);
}

.contact-btn i {
  font-size: 0.8rem;
}

/* Language Switcher */
.lang-switcher {
  display: flex;
  align-items: center;
  font-family: var(--font-mono);
  font-size: 0.75rem;
  font-weight: 700;
  margin-left: 20px;
  border: 1px solid var(--border-color);
  padding: 4px 8px;
}

.lang-btn {
  background: transparent;
  border: none;
  color: var(--text-muted);
  cursor: pointer;
  transition: var(--transition);
  padding: 2px 4px;
}

.lang-btn.active, .lang-btn:hover {
  color: var(--accent);
}

.lang-separator {
  color: var(--border-color);
  margin: 0 4px;
}

/* Responsive adjustments */
@media (max-width: 1024px) {
  /* Mobile Menu Toggling at 1024px Breakpoint to prevent crowding */
  nav {
    display: none;
  }
  nav.open {
    display: block;
    position: absolute;
    top: 100%;
    left: 0;
    width: 100%;
    background: #ffffff;
    border-bottom: 1px solid var(--border-color);
    z-index: 999;
  }
  nav.open ul {
    flex-direction: column;
    border-left: none;
  }
  nav.open ul li {
    border-right: none;
    border-bottom: 1px solid var(--border-muted);
  }
  nav.open ul li:last-child {
    border-bottom: none;
  }
  nav.open ul li a {
    padding: 16px 24px;
  }
  .logo-wrapper img {
    height: 44px;
  }
  header.scrolled .logo-wrapper img {
    height: 38px;
  }
  .mobile-nav-toggle {
    display: flex;
  }
  .header-contact {
    margin-left: auto;
    margin-right: 10px;
  }
  .lang-switcher {
    margin-left: 0;
    margin-right: 15px;
  }

  /* Bento grid layouts -> 1 column */
  .grid-cards,
  .phases-grid,
  .options-grid {
    grid-template-columns: 1fr;
    border-bottom: none;
  }
  .card,
  .phase-card,
  .option-card {
    border-right: none !important;
    border-bottom: 1px solid var(--border-color) !important;
  }
  .card:last-child,
  .phase-card:last-child,
  .option-card:last-child {
    border-bottom: none !important;
  }

  /* Trust grid -> 2 columns */
  .trust-grid {
    grid-template-columns: repeat(2, 1fr);
  }
  .trust-item {
    border-right: 1px solid var(--border-color) !important;
    border-bottom: 1px solid var(--border-color) !important;
  }
  .trust-item:nth-child(2n) {
    border-right: none !important;
  }
  .trust-item:nth-child(3),
  .trust-item:nth-child(4) {
    border-bottom: none !important;
  }

  /* Logo grid -> 3 columns */
  .logo-grid {
    grid-template-columns: repeat(3, 1fr);
  }
  .logo-item {
    border-right: 1px solid var(--border-color) !important;
    border-bottom: 1px solid var(--border-color) !important;
  }
  .logo-item:nth-child(3n) {
    border-right: none !important;
  }
  .logo-item:nth-child(4),
  .logo-item:nth-child(5) {
    border-bottom: none !important;
  }

  /* Hero section -> scaling on tablets */
  .hero {
    min-height: 70vh;
  }
  .hero h1 {
    font-size: 3rem;
  }
  .hero .sub-headline {
    font-size: 1.1rem;
    padding: 0 20px;
  }

  /* Asymmetric blocks -> 1 column stack */
  .case-study-hero,
  .teaser-box,
  .partner-pitch {
    grid-template-columns: 1fr !important;
  }
  .case-study-hero > div:nth-child(2) {
    border-left: none !important;
    border-top: 1px solid var(--border-color) !important;
  }
  .grid-3-col,
  .grid-2-col {
    grid-template-columns: 1fr !important;
  }
  .grid-3-col .card,
  .grid-2-col .card {
    border-right: none !important;
    border-bottom: 1px solid var(--border-color) !important;
  }
  .grid-3-col .card:last-child,
  .grid-2-col .card:last-child {
    border-bottom: none !important;
  }
  .case-study-media img,
  .teaser-image,
  .pitch-image {
    width: 100%;
    height: 380px;
    border-right: none !important;
    border-bottom: 1px solid var(--border-color) !important;
  }
  .teaser-content,
  .case-study-text,
  .pitch-text {
    padding: 50px 24px;
  }

  .marquee-track img {
    height: 48px;
    max-width: 140px;
  }

  /* Pricing grid -> 2 columns */
  .pricing-grid,
  .partner-pricing .pricing-grid {
    grid-template-columns: repeat(2, 1fr);
  }
  .price-card {
    border-right: 1px solid var(--border-color) !important;
    border-bottom: 1px solid var(--border-color) !important;
  }
  .price-card:nth-child(2n) {
    border-right: none !important;
  }
  .price-card:nth-child(3),
  .price-card:nth-child(4) {
    border-bottom: none !important;
  }

  /* Timeline -> 1 column stack on tablets to avoid text compression */
  .timeline {
    grid-template-columns: 1fr;
  }
  .timeline-step {
    border-right: none !important;
    border-bottom: 1px solid var(--border-color) !important;
  }
  .timeline-step:last-child {
    border-bottom: none !important;
  }
}

@media (max-width: 768px) {
  .container {
    padding: 0 20px;
  }
  .header-container {
    height: 75px;
  }
  .logo-wrapper img {
    height: 40px;
  }
  header.scrolled .logo-wrapper img {
    height: 34px;
  }
  .contact-btn span {
    display: none;
  }
  .contact-btn {
    padding: 5px 8px;
  }

  /* Mobile text scale */
  .hero h1 {
    font-size: 2.2rem;
    line-height: 1.0;
    word-break: break-word;
  }
  .section-title {
    font-size: 1.8rem;
  }
  .hero-ctas {
    flex-direction: column;
    gap: 12px;
    width: 100%;
    align-items: center;
  }
  .hero-ctas .btn {
    width: fit-content;
    text-align: center;
  }

  /* Trust grid -> 1 column */
  .trust-grid {
    grid-template-columns: 1fr;
  }
  .trust-item {
    border-right: none !important;
    border-bottom: 1px solid var(--border-color) !important;
  }
  .trust-item:last-child {
    border-bottom: none !important;
  }

  .marquee-track img {
    height: 40px;
    max-width: 110px;
  }

  /* Pricing grid -> 1 column */
  .pricing-grid,
  .partner-pricing .pricing-grid {
    grid-template-columns: 1fr;
  }
  .price-card {
    border-right: none !important;
    border-bottom: 1px solid var(--border-color) !important;
  }
  .price-card p {
    min-height: auto;
    margin-bottom: 15px;
  }
  .price-card:last-child {
    border-bottom: none !important;
  }

  /* Driver profile stats -> 1 column */
  .driver-stats-grid {
    grid-template-columns: 1fr;
  }
  .stats-card {
    border-right: none !important;
    border-bottom: 1px solid var(--border-color) !important;
  }
  .stats-card:last-child {
    border-bottom: none !important;
  }



  /* Logo grid -> 2 columns */
  .logo-grid {
    grid-template-columns: repeat(2, 1fr);
  }
  .logo-item {
    border-right: 1px solid var(--border-color) !important;
    border-bottom: 1px solid var(--border-color) !important;
  }
  .logo-item:nth-child(2n) {
    border-right: none !important;
  }
  .logo-item:nth-child(4),
  .logo-item:nth-child(5) {
    border-bottom: none !important;
  }
  .logo-item:last-child {
    border-bottom: none !important;
  }

  /* Parent info & Forms */
  .parent-info-grid,
  .form-row {
    grid-template-columns: 1fr;
    gap: 24px;
  }
  .contact-form-section {
    padding: 30px 20px;
  }
  .carousel-track {
    height: 320px;
  }
  .carousel-caption h4 {
    font-size: 1.2rem;
  }
  .carousel-caption p {
    font-size: 0.8rem;
  }
}

/* Multi-step Form Progress & Styling */
.form-progress {
  position: relative;
  margin-bottom: 40px;
  background: var(--border-muted);
  height: 2px;
}

.progress-bar {
  position: absolute;
  top: 0;
  left: 0;
  height: 100%;
  background: var(--accent);
  transition: width 0.3s ease-in-out;
}

.progress-steps {
  display: flex;
  justify-content: space-between;
  position: absolute;
  top: -14px;
  left: 0;
  width: 100%;
}

.step-num {
  width: 30px;
  height: 30px;
  border-radius: 50%;
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  color: var(--text-muted);
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: var(--font-mono);
  font-size: 0.8rem;
  font-weight: 700;
  transition: var(--transition);
}

.step-num.active {
  border-color: var(--accent);
  color: var(--accent);
  background: var(--bg-secondary);
}

.step-num.completed {
  border-color: var(--border-color);
  color: var(--text-primary);
  background: rgba(234, 91, 12, 0.1);
}

.form-step {
  display: none;
}

.form-step.active {
  display: block;
}

.form-step textarea {
  width: 100%;
  background: var(--bg-secondary);
  border: 1px solid var(--border-color);
  color: var(--text-primary);
  padding: 12px 15px;
  font-family: inherit;
  font-size: 0.95rem;
  transition: var(--transition);
  resize: vertical;
  min-height: 100px;
}

.form-step textarea:focus {
  outline: none;
  border-color: var(--accent);
}

.form-step select:focus {
  outline: none;
  border-color: var(--accent);
}

.checkbox-group label a {
  transition: var(--transition);
}

.checkbox-group label a:hover {
  color: var(--accent);
}

.invalid-feedback {
  color: #ff3b30;
  font-family: var(--font-mono);
  font-size: 0.75rem;
  margin-top: 5px;
  display: none;
}

.form-group.has-error input,
.form-group.has-error textarea,
.form-group.has-error select {
  border-color: #ff3b30 !important;
}

.form-group.has-error .invalid-feedback {
  display: block;
}

/* Animations */
@keyframes slowZoom {
  from {
    transform: scale(1.02);
  }
  to {
    transform: scale(1.1);
  }
}

/* Infinite Sponsor Marquee */
.sponsor-marquee-section {
  background: rgba(255, 255, 255, 0.01);
  padding: 40px 0;
  overflow: hidden;
}

.marquee-wrapper {
  display: flex;
  overflow: hidden;
  width: 100%;
  user-select: none;
  position: relative;
}

.marquee-wrapper::before,
.marquee-wrapper::after {
  content: "";
  position: absolute;
  top: 0;
  width: 150px;
  height: 100%;
  z-index: 2;
  pointer-events: none;
}

.marquee-wrapper::before {
  left: 0;
  background: linear-gradient(to right, var(--bg-primary), transparent);
}

.marquee-wrapper::after {
  right: 0;
  background: linear-gradient(to left, var(--bg-primary), transparent);
}

.marquee-track {
  display: flex;
  gap: 80px;
  animation: scroll-marquee 25s linear infinite;
  align-items: center;
  min-width: 200%;
}

.marquee-track:hover {
  animation-play-state: paused;
}

.marquee-track img {
  height: 60px;
  max-width: 180px;
  width: auto;
  object-fit: contain;
  opacity: 0.85;
  transition: transform 0.3s ease, opacity 0.3s ease;
}

.marquee-track img:hover {
  opacity: 1;
  transform: scale(1.08);
}

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

/* --- Comparative Racing Series --- */
.series-selector-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 30px;
}

.series-card {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  padding: 40px 30px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: space-between;
  text-align: center;
  cursor: pointer;
  transition: opacity 0.4s ease, transform 0.4s ease, border-color 0.4s ease, background-color 0.4s ease;
  min-height: 420px;
}

.series-card:hover {
  transform: translateY(-5px);
  border-color: var(--accent);
}

/* Inactive state for cards */
.series-card.inactive {
  opacity: 0.35;
}

/* Active state for cards */
.series-card.active {
  opacity: 1;
  border-color: var(--accent);
  background: rgba(234, 91, 12, 0.03);
}

.series-card-logo-wrap {
  height: 100px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 25px;
  width: 100%;
}

.series-card-logo-wrap img {
  max-height: 80px;
  max-width: 100%;
  object-fit: contain;
  filter: grayscale(0);
  opacity: 1;
  transition: filter 0.3s ease, opacity 0.3s ease;
}

.series-card.inactive .series-card-logo-wrap img {
  filter: grayscale(1);
  opacity: 0.35;
}

.series-card.active .series-card-logo-wrap img {
  filter: grayscale(0);
  opacity: 1;
}

.series-card-facts {
  list-style: none;
  padding: 0;
  margin: 0 0 30px 0;
  text-align: left;
  width: 100%;
  flex-grow: 1;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.series-card-facts li {
  font-size: 0.88rem;
  line-height: 1.4;
  color: var(--text-secondary);
  position: relative;
  padding-left: 20px;
}

.series-card-facts li::before {
  content: "—";
  position: absolute;
  left: 0;
  color: var(--accent);
  font-weight: bold;
}

.series-content-block {
  display: none;
  opacity: 0;
  transform: translateY(15px);
}

.series-content-block.active {
  display: block;
  animation: seriesFadeIn 0.5s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

@keyframes seriesFadeIn {
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* Mobile responsive styles for series section */
@media (max-width: 768px) {
  .series-selector-grid {
    display: flex;
    overflow-x: auto;
    gap: 20px;
    padding: 10px 5px 25px 5px;
    scroll-snap-type: x mandatory;
    -webkit-overflow-scrolling: touch;
    scroll-padding: 20px;
  }
  
  /* Show a subtle scroll indicator or styling */
  .series-selector-grid::-webkit-scrollbar {
    height: 4px;
  }
  
  .series-selector-grid::-webkit-scrollbar-track {
    background: var(--bg-tertiary);
  }
  
  .series-selector-grid::-webkit-scrollbar-thumb {
    background: var(--border-color);
    border-radius: 2px;
  }

  .series-card {
    flex: 0 0 85%;
    scroll-snap-align: center;
    min-height: 380px;
    padding: 30px 20px;
  }
  
  .series-card.inactive {
    opacity: 0.5; /* Keep slightly more visible on mobile for visual clues */
  }

  /* Compact mobile section paddings to avoid excessive scrolling and whitespace */
  .page-section {
    padding: 60px 0 !important;
  }
  .offering-section {
    padding: 60px 0 !important;
  }
  .segmentation-section {
    padding: 60px 0 !important;
  }
  .closing-section {
    padding: 60px 0 !important;
  }
  #general-contact {
    padding: 60px 0 !important;
  }
  #racing-series {
    padding: 60px 0 !important;
  }
  .timeline-section {
    padding: 60px 0 !important;
  }
}
