/* ──────────────────────────── 01 / HERO ─────────────────────────── */

.hero {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  padding-top: 0;
  padding-bottom: 0;
}

.hero-watermark {
  position: absolute;
  top: 50%;
  left: 50%;
  width: 40vw;
  height: 40vw;
  transform: translate(-50%, -50%);
  color: var(--cream);
  opacity: 0.08;
  pointer-events: none;
}

.hero-particles {
  position: absolute;
  inset: 0;
  pointer-events: none;
}

.hero-particle {
  position: absolute;
  width: 2px;
  height: 2px;
  border-radius: 50%;
  background: var(--cream);
}

.hero-content {
  position: relative;
  z-index: 2;
  text-align: center;
}

.hero-title {
  font-size: clamp(64px, 13vw, 180px);
  letter-spacing: 0.06em;
}

.hero-title .letter {
  display: inline-block;
  white-space: pre;
}

.hero-tagline {
  margin-top: 16px;
  font-size: 17px;
  color: var(--cream);
}

.hero-rule {
  width: 120px;
  height: 1px;
  margin: 48px auto 0;
  background: var(--brand);
  transform-origin: center;
}

.hero-scroll-cue {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 14px;
  margin-top: 56px;
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 0.2em;
  color: var(--muted);
}

.hero-chevron {
  width: 18px;
  height: 18px;
  animation: cue-pulse 1.5s ease-in-out infinite;
}

@keyframes cue-pulse {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(8px); }
}

/* ─────────────────────────── 02 / THE CAR ───────────────────────── */

.car-hero {
  width: 80%;
  margin: 64px auto 0;
}

.car-hero img {
  width: 100%;
  height: auto;
  background: var(--surface);
}

.car-cols {
  display: grid;
  grid-template-columns: 55% 40%;
  gap: 5%;
  margin-top: 16vh;
}

.car-heading {
  font-size: clamp(36px, 4vw, 56px);
  margin-bottom: 32px;
}

.car-copy p + p {
  margin-top: 24px;
}

.car-stats {
  display: flex;
  flex-direction: column;
  transform: translateY(80px);
}

.stat-card {
  padding: 36px 0;
}

.stat-card + .stat-card {
  border-top: 1px solid rgba(255, 251, 237, 0.12);
}

.stat-card .stat-number {
  font-size: clamp(64px, 7vw, 120px);
}

.stat-card .stat-label {
  margin-top: 8px;
}

/* ───────────────────────── 03 / ENGINEERING ─────────────────────── */

.engineering {
  padding-left: 0;
  padding-right: 0;
}

.gallery-pin {
  position: relative;
  height: 100vh;
  display: flex;
  flex-direction: column;
  justify-content: center;
  overflow: hidden;
}

.gallery-pin .section-label {
  position: absolute;
  top: 10vh;
  left: var(--gutter);
}

.gallery-track {
  display: flex;
  gap: 4vw;
  width: max-content;
  padding: 0 var(--gutter);
  will-change: transform;
}

.gallery-card {
  position: relative;
  width: 70vw;
  height: 60vh;
  flex-shrink: 0;
  overflow: hidden;
  background: var(--surface);
}

.card-media {
  position: absolute;
  inset: 0;
  overflow: hidden;
}

.card-media img {
  width: 120%;
  max-width: none;
  height: 100%;
  object-fit: cover;
}

.card-caption {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 2;
  padding: 80px 40px 36px;
  background: linear-gradient(to top, rgba(10, 10, 10, 0.85), rgba(10, 10, 10, 0));
}

.card-caption h2 {
  font-size: clamp(28px, 3vw, 44px);
}

.card-caption p {
  max-width: 52ch;
  margin-top: 10px;
  font-size: 15px;
  color: var(--cream);
}

.gallery-progress {
  position: absolute;
  left: var(--gutter);
  right: var(--gutter);
  bottom: 8vh;
  height: 2px;
  background: rgba(107, 107, 107, 0.25);
}

.gallery-progress-fill {
  width: 100%;
  height: 100%;
  background: var(--brand);
  transform: scaleX(0);
  transform-origin: left;
}

/* ──────────────────────────── 04 / THE TEAM ─────────────────────── */

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

.team-card {
  position: relative;
  overflow: hidden;
  background: var(--surface);
  outline-offset: 4px;
}

.team-portrait {
  aspect-ratio: 3 / 4;
}

.team-portrait svg {
  width: 100%;
  height: 100%;
  transition: filter 400ms ease-out;
}

.monogram {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 110px;
  letter-spacing: 0.05em;
  fill: rgba(201, 168, 124, 0.16);
  text-anchor: middle;
  dominant-baseline: central;
}

.team-overlay {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  padding: 28px;
  background: rgba(10, 10, 10, 0.7);
  transform: translateY(100%);
  transition: transform 400ms ease-out;
}

.team-card:hover .team-overlay,
.team-card:focus-within .team-overlay,
.team-card:focus .team-overlay {
  transform: translateY(0);
}

.team-card:hover .team-portrait svg,
.team-card:focus .team-portrait svg {
  filter: saturate(0.6);
}

.team-name {
  font-size: 20px;
}

.team-role {
  margin-top: 4px;
  font-size: 14px;
  font-weight: 500;
  color: var(--brand-light);
}

.team-desc {
  margin-top: 10px;
  font-size: 14px;
  color: var(--muted);
}

/* Touch devices: no hover — show details statically below the portrait. */
@media (hover: none) {
  .team-overlay {
    position: static;
    transform: none;
    background: none;
    padding: 20px 4px 24px;
  }
}

/* ────────────────────────── 05 / PERFORMANCE ────────────────────── */

.perf-split {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: var(--gutter);
  align-items: center;
  min-height: 100vh;
  margin-top: 32px;
}

.perf-stats {
  display: flex;
  flex-direction: column;
  gap: 72px;
}

.perf-number {
  display: block;
  font-size: clamp(72px, 7vw, 96px);
  color: var(--brand-light);
}

.perf-stat .stat-label {
  margin-top: 6px;
}

.timeline {
  position: relative;
  padding: 40px 0;
}

.timeline::before {
  content: '';
  position: absolute;
  top: 0;
  bottom: 0;
  left: 50%;
  width: 1px;
  background: rgba(107, 107, 107, 0.5);
}

.timeline-item {
  position: relative;
  width: 50%;
  padding-bottom: 56px;
}

.timeline-item:last-child {
  padding-bottom: 0;
}

.timeline-node {
  position: absolute;
  top: 6px;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--brand);
}

.timeline-item:nth-child(odd) {
  padding-right: 40px;
  text-align: right;
}

.timeline-item:nth-child(odd) .timeline-node {
  right: -4px;
}

.timeline-item:nth-child(even) {
  margin-left: 50%;
  padding-left: 40px;
}

.timeline-item:nth-child(even) .timeline-node {
  left: -4px;
}

.timeline-body time {
  display: block;
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 0.16em;
  color: var(--muted);
}

.timeline-body p {
  margin-top: 4px;
  font-weight: 500;
  color: var(--cream);
}

/* ─────────────────────────── 06 / PARTNERS ──────────────────────── */

.partners {
  text-align: center;
}

.partners-intro {
  margin-top: 16px;
  color: var(--cream);
}

.logo-row {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  align-items: center;
  gap: 48px 80px;
  margin: 96px 0;
}

.partner-logo {
  width: clamp(150px, 15vw, 220px);
  height: auto;
  color: var(--white);
  transition: color 300ms ease-out;
}

.logo-row li:hover .partner-logo {
  color: var(--brand-light);
}

.logo-text {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 30px;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  text-anchor: middle;
  fill: currentColor;
}

.partners-cta p {
  color: var(--cream);
}

.partners-cta .btn-ghost {
  margin-top: 28px;
}

/* ──────────────────────── 07 / FOOTER / CONTACT ─────────────────── */

.contact {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  overflow: hidden;
}

.footer-watermark {
  position: absolute;
  top: 50%;
  left: 50%;
  width: 20vw;
  height: 20vw;
  transform: translate(-50%, -50%);
  color: var(--cream);
  opacity: 0.06;
  pointer-events: none;
}

.footer-content {
  position: relative;
  z-index: 2;
  text-align: center;
}

.footer-title {
  font-size: 48px;
}

.footer-rule {
  width: 60px;
  height: 1px;
  margin: 28px auto;
  background: var(--brand);
}

.footer-email {
  font-size: 17px;
  color: var(--cream);
  background-image: linear-gradient(currentColor, currentColor);
  background-repeat: no-repeat;
  background-position: left bottom;
  background-size: 0% 1px;
  padding-bottom: 3px;
  transition: background-size 300ms ease-out;
}

.footer-email:hover,
.footer-email:focus-visible {
  background-size: 100% 1px;
}

.footer-social {
  display: flex;
  justify-content: center;
  gap: 32px;
  margin-top: 36px;
}

.footer-social a {
  color: var(--muted);
  transition: color 300ms ease-out;
}

.footer-social a:hover,
.footer-social a:focus-visible {
  color: var(--brand-light);
}

.footer-icon {
  width: 20px;
  height: 20px;
}

.footer-meta {
  position: absolute;
  left: var(--gutter);
  right: var(--gutter);
  bottom: 28px;
  display: flex;
  justify-content: space-between;
  gap: 16px;
  font-size: 12px;
  color: var(--muted);
}

/* Reduced motion: no pinning, so the gallery must read as a vertical
   stack at every width or the off-screen cards become unreachable. */
.reduced-motion .engineering,
html:not(.js) .engineering {
  padding-left: var(--gutter);
  padding-right: var(--gutter);
}

.reduced-motion .gallery-pin,
html:not(.js) .gallery-pin {
  height: auto;
  overflow: visible;
  display: block;
}

.reduced-motion .gallery-pin .section-label,
html:not(.js) .gallery-pin .section-label {
  position: static;
  margin-bottom: 40px;
}

.reduced-motion .gallery-track,
html:not(.js) .gallery-track {
  flex-direction: column;
  gap: 28px;
  width: auto;
  padding: 0;
  will-change: auto;
}

.reduced-motion .gallery-card,
html:not(.js) .gallery-card {
  width: 100%;
  height: auto;
  aspect-ratio: 16 / 9;
}

.reduced-motion .card-media img,
html:not(.js) .card-media img {
  width: 100%;
}

.reduced-motion .gallery-progress,
html:not(.js) .gallery-progress {
  display: none;
}

/* ──────────────────────── Responsive: tablet ────────────────────── */

@media (max-width: 1199px) {
  .car-cols {
    grid-template-columns: 1fr;
    gap: 0;
  }

  .car-stats {
    transform: none;
    margin-top: 64px;
  }

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

  .perf-split {
    grid-template-columns: 1fr;
    gap: 96px;
    min-height: 0;
  }

  .gallery-card {
    width: 80vw;
  }
}

/* ──────────────────────── Responsive: mobile ────────────────────── */

@media (max-width: 767px) {
  .car-hero {
    width: 100%;
  }

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

  .pull-quote {
    padding: 80px 0;
  }

  /* Gallery becomes a vertical stack — no pinning on mobile. */
  .engineering {
    padding-left: var(--gutter);
    padding-right: var(--gutter);
  }

  .gallery-pin {
    height: auto;
    overflow: visible;
    display: block;
  }

  .gallery-pin .section-label {
    position: static;
    margin-bottom: 40px;
  }

  .gallery-track {
    flex-direction: column;
    gap: 28px;
    width: auto;
    padding: 0;
    will-change: auto;
  }

  .gallery-card {
    width: 100%;
    height: auto;
    aspect-ratio: 4 / 3;
  }

  .card-media img {
    width: 100%;
  }

  .card-caption {
    padding: 60px 20px 24px;
  }

  .gallery-progress {
    display: none;
  }

  /* Timeline collapses to a single left rail. */
  .timeline::before {
    left: 4px;
  }

  .timeline-item:nth-child(odd),
  .timeline-item:nth-child(even) {
    width: 100%;
    margin-left: 0;
    padding-left: 32px;
    padding-right: 0;
    text-align: left;
  }

  .timeline-item:nth-child(odd) .timeline-node,
  .timeline-item:nth-child(even) .timeline-node {
    left: 0;
    right: auto;
  }

  .logo-row {
    gap: 40px;
    margin: 72px 0;
  }

  .footer-meta {
    flex-direction: column;
    align-items: center;
    text-align: center;
    gap: 6px;
  }
}
