/* PURO AUTO — Coming Soon
   Scene: total darkness; a car's lights wake, and the brand appears in their light. */
:root {
  --black: #000000;
  --charcoal: #252526;
  --graphite: #585859;
  --steel: #88898c;
  --mist: #aab9bf;
  --ice: #dceef2;
  --lamp: 220, 238, 242;            /* Ice as RGB, for alpha blends */
  --serif: "Cormorant Garamond", "Times New Roman", Georgia, serif;
  --sans: "Jost", "Helvetica Neue", Arial, sans-serif;
  --ease: cubic-bezier(0.22, 0.61, 0.36, 1);

  /* Choreography (seconds) */
  --t-drl: 0.5s;      /* the line grows from the centre */
  --t-main: 1.4s;     /* full brightness; light reaches the floor */
  --t-logo: 2.25s;    /* brand appears in the light */
}

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

html { -webkit-text-size-adjust: 100%; text-size-adjust: 100%; overflow-x: hidden; }

html, body { height: 100%; background: var(--black); }

body {
  color: var(--mist);
  font-family: var(--sans);
  font-weight: 300;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overflow-x: hidden;
}

/* ---------- Layout ---------- */
.page {
  position: relative;
  min-height: 100vh;
  min-height: 100svh;
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: clamp(36px, 7vh, 76px) 24px clamp(22px, 4vh, 36px);
  overflow-x: clip;
}

.hero,
.contact,
.footer { position: relative; z-index: 1; }

.hero {
  width: 100%;
  max-width: 880px;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  padding-top: clamp(4px, 3vh, 32px);
}

/* ---------- Logo ---------- */
.hero h1 { line-height: 0; font-size: 0; }

.logo {
  display: block;
  width: clamp(230px, 36vw, 440px);
  height: auto;
  max-height: 34vh;
  object-fit: contain;
  user-select: none;
  -webkit-user-drag: none;
  filter: drop-shadow(0 0 28px rgba(var(--lamp), 0.10));
}

/* ---------- Faint line beneath the logo ---------- */
.line {
  position: relative;
  width: clamp(120px, 22vw, 260px);
  height: 1px;
  margin: clamp(30px, 5.5vh, 54px) 0 clamp(26px, 4.5vh, 44px);
  background: linear-gradient(90deg, rgba(136,137,140,0), rgba(136,137,140,0.55), rgba(136,137,140,0));
  overflow: hidden;
}
.line::after {
  content: "";
  position: absolute;
  top: 0;
  left: -40%;
  width: 40%;
  height: 100%;
  background: linear-gradient(90deg, rgba(220,238,242,0), rgba(220,238,242,0.95), rgba(220,238,242,0));
  animation: line-sweep 6s var(--ease) 4s infinite;
}

/* ---------- Typography ---------- */
.headline {
  margin-top: 0;
  font-family: var(--serif);
  font-weight: 300;
  font-size: clamp(1.9rem, 4.6vw, 3.4rem);
  line-height: 1.14;
  letter-spacing: 0.02em;
  color: var(--ice);
  text-wrap: balance;
}

.subheading {
  margin-top: clamp(16px, 2.4vh, 24px);
  font-size: clamp(0.68rem, 1.15vw, 0.8rem);
  letter-spacing: 0.36em;
  text-transform: uppercase;
  color: var(--steel);
}

.supporting {
  margin-top: clamp(12px, 1.8vh, 18px);
  font-size: clamp(0.86rem, 1.2vw, 0.96rem);
  line-height: 1.7;
  letter-spacing: 0.03em;
  color: var(--graphite);
}

/* ---------- The car: only its light exists ---------- */
.scene {
  position: relative;
  z-index: 0;
  width: 100%;
  flex: 1 0 auto;
  min-height: clamp(150px, 25vh, 250px);
  pointer-events: none;
}

.car {
  position: absolute;
  left: 50%;
  top: 30%;
  transform: translateX(-50%);
  font-size: clamp(6.6px, 0.95vw, 12.5px);   /* one unit scales the whole car */
  width: min(74em, 88vw);
  height: 6em;
}

.car__breathe { position: absolute; inset: 0; }

.car > .car__breathe > span,
.floor { position: absolute; display: block; opacity: 0; }

/* One unbroken hairline of light across the full width of the car */
.bar,
.bar-mirror {
  left: 0;
  top: 1.2em;
  width: 100%;
  height: 2em;
  -webkit-mask-image: linear-gradient(to right, transparent, #000 12%, #000 88%, transparent);
  mask-image: linear-gradient(to right, transparent, #000 12%, #000 88%, transparent);
  -webkit-mask-repeat: no-repeat;
  mask-repeat: no-repeat;
  -webkit-mask-position: 50% 0;
  mask-position: 50% 0;
  -webkit-mask-size: 0% 100%;
  mask-size: 0% 100%;
}
/* The light itself: a solid white lens shape, thin at the tips (no SVG, so every browser draws it white) */
.bar__core {
  position: absolute;
  left: 0;
  right: 0;
  top: 50%;
  height: 0.36em;
  margin-top: -0.18em;
  border-radius: 50%;
  background: #ffffff;
}
.bar .bar__core {
  filter: drop-shadow(0 0 0.22em rgba(255, 255, 255, 0.95))
          drop-shadow(0 0 1.1em rgba(var(--lamp), 0.55));
}

/* Its reflection in the polished floor */
.bar-mirror {
  top: 6.2em;
  transform: scaleY(-1) scaleX(0.985);
}
.bar-mirror .bar__core {
  opacity: 0.2;
  filter: blur(0.5em);
}

/* Soft halo along the line */
.halo {
  left: 50%;
  top: 2.2em;
  width: 110%;
  height: 26em;
  margin: -13em 0 0 -55%;
  border-radius: 50%;
  background: radial-gradient(ellipse at center,
    rgba(var(--lamp), 0.16),
    rgba(var(--lamp), 0.06) 38%,
    rgba(var(--lamp), 0) 70%);
}

/* The instant it reaches full brightness */
.flash {
  left: 50%;
  top: 2.2em;
  width: 160%;
  height: 50em;
  margin: -25em 0 0 -80%;
  border-radius: 50%;
  background: radial-gradient(ellipse at center,
    rgba(var(--lamp), 0.22), rgba(var(--lamp), 0) 60%);
}

/* Light spilling onto the ground in front of the car */
.floor {
  left: 50%;
  top: 2em;
  width: min(170em, 100vw);
  height: 50em;
  transform: translateX(-50%);
  background: radial-gradient(ellipse 46% 55% at 50% 6%,
    rgba(var(--lamp), 0.15),
    rgba(var(--lamp), 0.05) 45%,
    rgba(var(--lamp), 0) 76%);
  -webkit-mask: linear-gradient(to bottom, transparent, #000 18%, #000 70%, transparent);
  mask: linear-gradient(to bottom, transparent, #000 18%, #000 70%, transparent);
}

/* ---------- Contact ---------- */
.contact {
  margin-top: clamp(8px, 2vh, 20px);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 14px;
}

.contact__label {
  font-size: 0.62rem;
  letter-spacing: 0.44em;
  text-transform: uppercase;
  color: var(--graphite);
}

.contact__email {
  position: relative;
  font-size: clamp(0.98rem, 1.4vw, 1.08rem);
  font-weight: 300;
  letter-spacing: 0.14em;
  color: var(--ice);
  text-decoration: none;
  padding: 6px 2px;
  transition: color 0.5s var(--ease);
}
.contact__email::after {
  content: "";
  position: absolute;
  left: 0; right: 0; bottom: 0;
  height: 1px;
  background: var(--mist);
  transform: scaleX(0.18);
  opacity: 0.6;
  transition: transform 0.7s var(--ease), opacity 0.7s var(--ease);
}
.contact__email:hover,
.contact__email:focus-visible { color: #fff; }
.contact__email:hover::after,
.contact__email:focus-visible::after { transform: scaleX(1); opacity: 1; }
.contact__email:focus-visible { outline: 1px solid var(--steel); outline-offset: 6px; }

/* ---------- Footer ---------- */
.footer {
  margin-top: clamp(28px, 5vh, 48px);
  font-size: 0.6rem;
  letter-spacing: 0.28em;
  text-transform: uppercase;
  color: var(--graphite);
  text-align: center;
}

/* ---------- Choreography ---------- */
.reveal {
  opacity: 0;
  transform: translate3d(0, 12px, 0);
  filter: blur(6px);
}
.is-loaded .reveal {
  animation: reveal 1.7s var(--ease) forwards;
  animation-delay: calc(var(--t-logo) + var(--d, 0) * 1s);
}
.line.reveal { transform: scaleX(0); filter: none; }
.is-loaded .line.reveal { animation-name: draw; }

.is-loaded .bar,
.is-loaded .bar-mirror { animation: grow 1.5s var(--ease) var(--t-drl) forwards; }
.is-loaded .flash { animation: flash 0.9s ease-out var(--t-main) forwards; }
.is-loaded .halo,
.is-loaded .floor { animation: ignite 2.4s var(--ease) var(--t-main) forwards; }
.is-loaded .car__breathe { animation: breathe 7s ease-in-out 4s infinite alternate; }

@keyframes grow {
  0%   { opacity: 0; -webkit-mask-size: 0% 100%; mask-size: 0% 100%; }
  8%   { opacity: 1; }
  100% { opacity: 1; -webkit-mask-size: 130% 100%; mask-size: 130% 100%; }
}
@keyframes ignite {
  0%   { opacity: 0; }
  16%  { opacity: 1; }
  100% { opacity: 0.86; }
}
@keyframes flash {
  0%   { opacity: 0; }
  14%  { opacity: 1; }
  100% { opacity: 0; }
}
@keyframes breathe {
  from { opacity: 0.93; }
  to   { opacity: 1; }
}
@keyframes reveal {
  to { opacity: 1; transform: translate3d(0, 0, 0); filter: blur(0); }
}
@keyframes draw {
  to { opacity: 1; transform: scaleX(1); }
}
@keyframes line-sweep {
  0% { left: -40%; }
  55%, 100% { left: 100%; }
}

/* No JavaScript: everything simply on */
.no-js .reveal { opacity: 1; transform: none; filter: none; }
.no-js .halo, .no-js .floor { opacity: 0.86; }
.no-js .bar, .no-js .bar-mirror { opacity: 1; -webkit-mask-size: 130% 100%; mask-size: 130% 100%; }
.no-js .flash { opacity: 0; }

/* ---------- Small screens ---------- */
@media (max-width: 560px) {
  .page { padding: 30px 20px 18px; }
  .hero { padding-top: 0; }
  .logo { width: min(66vw, 300px); max-height: 22vh; }
  .line { width: 110px; margin: 20px 0 18px; }
  .headline { font-size: 1.72rem; line-height: 1.18; }
  .subheading { margin-top: 12px; font-size: 0.62rem; letter-spacing: 0.22em; line-height: 1.8; }
  .supporting { margin-top: 8px; font-size: 0.82rem; line-height: 1.6; }
  .scene { min-height: clamp(118px, 19vh, 180px); }
  /* On a phone the light keeps its full glow: the scale no longer shrinks with the car */
  .car { top: 20%; width: 80vw; font-size: 10px; }
  .bar .bar__core { filter: drop-shadow(0 0 2px rgba(255, 255, 255, 0.95)) drop-shadow(0 0 12px rgba(var(--lamp), 0.6)); }
  .halo { height: 22em; margin-top: -11em; }
  .floor { height: 40em; }
  .contact { margin-top: 4px; gap: 10px; }
  .contact__label { font-size: 0.58rem; }
  .contact__email { font-size: 0.96rem; letter-spacing: 0.1em; }
  .footer { margin-top: 22px; font-size: 0.56rem; letter-spacing: 0.22em; }
}

@media (max-height: 640px) and (orientation: landscape) {
  .logo { max-height: 24vh; }
  .line { margin: 18px 0 16px; }
  .scene { min-height: 120px; }
}

/* ---------- Accessibility ---------- */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; }
  .reveal { opacity: 1 !important; transform: none !important; filter: none !important; }
  .halo, .floor { opacity: 0.86 !important; }
  .bar, .bar-mirror { opacity: 1 !important; -webkit-mask-size: 130% 100% !important; mask-size: 130% 100% !important; }
  .flash { opacity: 0 !important; }
}
