/* =========================================================
   Showpiece sections — custom sections (rebuild as HTML/custom-code
   widgets in Elementor). Styles only; behaviour is in /assets/js.
   ========================================================= */

/* ---------- 1. HERO: pinned video with scroll-driven reveal ---------- */

.hero { position: relative; height: 170vh; }
.hero-pin {
  position: sticky; top: 0; height: 100vh; min-height: 620px;
  overflow: hidden; display: flex; align-items: flex-end;
}
.hero-media {
  position: absolute; inset: 0; z-index: 0;
  transform-origin: 50% 40%;
  will-change: transform, clip-path;
}
.hero-video, .hero-poster { width: 100%; height: 100%; object-fit: cover; }
.hero-overlay {
  position: absolute; inset: 0; z-index: 1; pointer-events: none;
  background:
    radial-gradient(ellipse at 80% 20%, rgba(255,103,28,.18), transparent 55%),
    linear-gradient(180deg, rgba(12,12,14,.55) 0%, rgba(12,12,14,.25) 35%, rgba(12,12,14,.92) 100%),
    linear-gradient(90deg, rgba(12,12,14,.75) 0%, transparent 70%);
}
.hero-content {
  position: relative; z-index: 2;
  display: flex; flex-direction: column; gap: 28px;
  padding-bottom: clamp(110px, 16vh, 170px);
  will-change: transform, opacity;
}
.hero-headline { font-size: clamp(3.2rem, min(8.4vw, 13.5vh), 9rem); line-height: .86; }
.hero-line { display: block; }
.hero-line.accent { color: var(--accent); }
.hero-sub { max-width: 52ch; font-size: clamp(1.05rem, 1.4vw, 1.25rem); color: rgba(245,242,237,.85); }

/* Word masks created by hero.js from whatever text is in .hero-line */
.hero-word { display: inline-block; overflow: hidden; vertical-align: top; padding-bottom: .04em; margin-bottom: -.04em; }
.hero-word-inner { display: inline-block; transform: translateY(105%); transition: transform 1.1s var(--ease); }
.hero.is-ready .hero-word-inner { transform: none; }

.hero-fade { opacity: 0; transform: translateY(24px); transition: opacity 1s var(--ease), transform 1s var(--ease); }
.hero.is-ready .hero-fade { opacity: 1; transform: none; }

.hero-meta {
  position: absolute; z-index: 2; left: 0; right: 0; bottom: 0;
  border-top: 1px solid rgba(255,255,255,.12);
  background: rgba(12,12,14,.35);
  backdrop-filter: blur(6px); -webkit-backdrop-filter: blur(6px);
}
.hero-meta-inner { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 12px 32px; padding-block: 18px; font-size: .85rem; color: rgba(245,242,237,.8); }
.hero-meta-item { display: flex; align-items: center; gap: 10px; }
.hero-meta-item svg { width: 18px; height: 18px; color: var(--accent); flex: none; }

.hero-scroll-cue {
  display: flex; align-items: center; gap: 12px;
  font-size: .72rem; font-weight: 700; letter-spacing: .22em; text-transform: uppercase;
}
.hero-scroll-cue::after {
  content: ""; width: 1.5px; height: 30px; background: var(--accent);
  animation: cue 2s var(--ease) infinite; transform-origin: top;
}
@keyframes cue { 0% { transform: scaleY(0); } 50% { transform: scaleY(1); transform-origin: top; } 51% { transform-origin: bottom; } 100% { transform: scaleY(0); transform-origin: bottom; } }

/* Gauge arc that fills as you scroll (echoes the logo arc) */
.hero-gauge {
  position: absolute; z-index: 2; right: clamp(-160px, -6vw, -40px); top: 50%;
  width: min(62vh, 560px); aspect-ratio: 1; transform: translateY(-58%);
  pointer-events: none; opacity: .9;
}
.hero-gauge-track { fill: none; stroke: rgba(255,255,255,.12); stroke-width: 2; }
.hero-gauge-fill { fill: none; stroke: var(--accent); stroke-width: 3; stroke-linecap: round; }
.hero-gauge-ticks line { stroke: rgba(255,255,255,.35); stroke-width: 2; }

@media (max-width: 760px) {
  .hero { height: 140vh; }
  .hero-gauge { width: 90vw; right: -40vw; opacity: .5; }
  .hero-meta-item--address, .hero-scroll-cue { display: none; }
  .hero-meta { bottom: calc(70px + env(safe-area-inset-bottom, 0px)); }
  .hero-content { padding-bottom: 150px; gap: 22px; }
}

/* ---------- 2. SERVICE DIAL: interactive tachometer ---------- */

.dial { overflow: hidden; }
.dial::before {
  content: ""; position: absolute; left: 50%; top: 40%; width: 900px; height: 900px;
  transform: translate(-10%, -50%);
  background: radial-gradient(circle, rgba(255,103,28,.10), transparent 60%);
  pointer-events: none;
}
.dial-layout { display: flex; flex-wrap: wrap; gap: clamp(40px, 6vw, 100px); align-items: flex-start; position: relative; }

.dial-list { flex: 1 1 380px; list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; counter-reset: none; }
.dial-tab {
  width: 100%; text-align: left;
  display: flex; align-items: center; gap: 22px;
  padding: 16px 0; background: none; border: 0;
  border-bottom: 1px solid var(--line);
  color: rgba(245,242,237,.42);
  transition: color .4s var(--ease), padding .5s var(--ease);
}
.dial-tab-num { font-family: var(--font-display); font-weight: 700; font-size: .95rem; letter-spacing: .1em; width: 28px; flex: none; transition: color .4s; }
.dial-tab-title { font-family: var(--font-display); font-weight: 800; text-transform: uppercase; font-size: clamp(1.5rem, 2.6vw, 2.3rem); line-height: 1; flex: 1; }
.dial-tab-arrow { width: 26px; height: 26px; flex: none; opacity: 0; transform: translateX(-12px); transition: all .5s var(--ease); color: var(--accent); }
.dial-tab:hover { color: var(--text); }
.dial-tab[aria-selected="true"] { color: var(--text); padding-left: 14px; }
.dial-tab[aria-selected="true"] .dial-tab-num { color: var(--accent); }
.dial-tab[aria-selected="true"] .dial-tab-arrow { opacity: 1; transform: none; }

.dial-stage { flex: 1 1 420px; max-width: 520px; position: relative; margin-inline: auto; }
.dial-face { position: absolute; top: 0; left: 0; width: 100%; aspect-ratio: 1; z-index: 3; pointer-events: none; }
.dial-svg { position: absolute; inset: 0; width: 100%; height: 100%; z-index: 3; pointer-events: none; overflow: visible; }
.dial-track { fill: none; stroke: rgba(255,255,255,.1); stroke-width: 10; stroke-linecap: round; }
.dial-progress { fill: none; stroke: var(--accent); stroke-width: 10; stroke-linecap: round; transition: stroke-dashoffset 1s var(--ease); filter: drop-shadow(0 0 10px rgba(255,103,28,.55)); }
.dial-ticks line { stroke: rgba(255,255,255,.3); stroke-width: 2; }
.dial-ticks line.is-major { stroke: rgba(255,255,255,.7); stroke-width: 3; }
.dial-ticks line.is-lit { stroke: var(--accent); }
.dial-needle-group { transition: transform 1.1s cubic-bezier(.34, 1.45, .5, 1); transform-origin: 200px 200px; }
.dial-needle { stroke: var(--accent); stroke-width: 5; stroke-linecap: round; }
.dial-hub { fill: var(--bg); stroke: var(--accent); stroke-width: 4; }
.dial-readout {
  position: absolute; left: 50%; bottom: 3%; transform: translateX(-50%); z-index: 4;
  display: flex; align-items: baseline; gap: 6px;
  font-family: var(--font-display); font-weight: 800;
  background: var(--bg); padding: 4px 16px; border-radius: 40px; border: 1px solid var(--line);
}
.dial-readout-current { font-size: 1.8rem; color: var(--accent); line-height: 1; }
.dial-readout-total { font-size: 1rem; color: var(--muted); }

.dial-panels { position: static; }
.dial-panel { display: flex; flex-direction: column; gap: 18px; }
.dial-panel[hidden] { display: none !important; }
.dial-panel-media {
  position: absolute; top: 0; left: 0; width: 100%; aspect-ratio: 1; padding: 13%; z-index: 1; margin: 0;
}
.dial-panel-media img {
  width: 100%; height: 100%; object-fit: cover; border-radius: 50%;
  box-shadow: 0 30px 80px rgba(0,0,0,.6), inset 0 0 0 1px rgba(255,255,255,.1);
}
.dial-panel-body { display: flex; flex-direction: column; gap: 14px; padding-top: calc(100% + 22px); text-align: center; align-items: center; }
.dial-panel-title { font-size: clamp(1.8rem, 2.8vw, 2.4rem); }
.dial-panel-text { color: var(--muted); max-width: 44ch; }

.dial-panel.is-entering .dial-panel-media img { animation: dialImgIn .9s var(--ease) both; }
.dial-panel.is-entering .dial-panel-body > * { animation: dialTextIn .8s var(--ease) both; }
.dial-panel.is-entering .dial-panel-body > *:nth-child(2) { animation-delay: .08s; }
.dial-panel.is-entering .dial-panel-body > *:nth-child(3) { animation-delay: .16s; }
@keyframes dialImgIn { from { opacity: 0; transform: scale(.86) rotate(-8deg); filter: blur(6px); } to { opacity: 1; transform: none; filter: none; } }
@keyframes dialTextIn { from { opacity: 0; transform: translateY(18px); } to { opacity: 1; transform: none; } }

@media (max-width: 900px) {
  .dial-stage { order: -1; max-width: 420px; }
  .dial-tab { padding: 12px 0; }
  .dial-tab-title { font-size: 1.45rem; }
}

/* ---------- 3. ROAD: scroll-drawn journey ---------- */

.road {
  background:
    radial-gradient(ellipse at 50% 120%, rgba(143,52,19,.55), transparent 60%),
    linear-gradient(180deg, var(--bg) 0%, #1a0f0a 100%);
  overflow: hidden;
}
.road-track { position: relative; }
.road-svg { position: absolute; inset: 0; width: 100%; height: 100%; overflow: visible; pointer-events: none; z-index: 0; }
.road-path-base { fill: none; stroke: rgba(255,255,255,.08); stroke-width: 34; stroke-linecap: round; }
.road-path-lane { fill: none; stroke: rgba(255,255,255,.22); stroke-width: 2; stroke-dasharray: 14 18; }
.road-path { fill: none; stroke: var(--accent); stroke-width: 4; stroke-linecap: round; filter: drop-shadow(0 0 8px rgba(255,103,28,.7)); }

.road-car {
  position: absolute; left: 0; top: 0; z-index: 2;
  width: 54px; height: 54px; margin: -27px 0 0 -27px;
  border-radius: 50%; background: var(--accent);
  display: flex; align-items: center; justify-content: center;
  box-shadow: 0 0 0 8px rgba(255,103,28,.18), 0 0 40px rgba(255,103,28,.6);
  will-change: transform;
}
.road-car svg { width: 28px; height: 28px; color: #111; }

.road-steps { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: clamp(90px, 12vw, 160px); position: relative; z-index: 1; padding-block: 40px; }
.road-step {
  width: min(42%, 460px);
  display: flex; flex-direction: column; gap: 14px;
  opacity: .28; transform: translateY(20px);
  transition: opacity .8s var(--ease), transform .8s var(--ease);
}
.road-step:nth-child(even) { margin-left: auto; text-align: right; align-items: flex-end; }
.road-step.is-active { opacity: 1; transform: none; }
.road-step-num {
  font-family: var(--font-display); font-weight: 800; font-size: clamp(4rem, 8vw, 7rem); line-height: .8;
  color: transparent; -webkit-text-stroke: 1.5px var(--accent);
}
.road-step.is-active .road-step-num { color: var(--accent); }
.road-step-title { font-size: clamp(2rem, 3.4vw, 3rem); }
.road-step-text { color: var(--muted); max-width: 40ch; }

@media (max-width: 760px) {
  .road-step, .road-step:nth-child(even) { width: auto; margin-left: 64px; text-align: left; align-items: flex-start; }
  .road-path-base { stroke-width: 22; }
  .road-car { width: 42px; height: 42px; margin: -21px 0 0 -21px; }
  .road-car svg { width: 22px; height: 22px; }
}

@media (prefers-reduced-motion: reduce) {
  .hero-word-inner, .hero-fade { transform: none; opacity: 1; }
  .road-step { opacity: 1; transform: none; }
}
.dial-stage { scroll-margin-top: 90px; }
