/* Homepage hero illustration: a top-down parking and storage site.
   Flat and neutral per the interface standard: shared roles only, green for the
   booked status only, no gradient, glow or outline around the picture. */

.hero-site-scene {
  min-width: 0;
  width: 100%;
  margin: 0;
}

.hero-site-scene__stage {
  position: relative;
  overflow: hidden;
  border-radius: var(--radius-card);
}

.hero-site-scene__art {
  display: block;
  width: 100%;
  height: auto;
}

.hero-site-scene__ground {
  fill: var(--surface-subtle);
}

.hero-site-scene__fence {
  fill: none;
  stroke: var(--border-control);
  stroke-width: 2;
  stroke-linecap: round;
  stroke-dasharray: 2 7;
}

.hero-site-scene__paint {
  fill: none;
  stroke: var(--border-control);
  stroke-width: 3;
  stroke-linecap: round;
}

.hero-site-scene__paint--lane {
  stroke-dasharray: 18 16;
  opacity: 0.5;
}

.hero-site-scene__code {
  fill: var(--text-caption);
  font-family: inherit;
  font-size: var(--font-size-caption);
  font-weight: 500;
  text-anchor: middle;
}

.hero-site-scene__car {
  fill: var(--border-control);
}

.hero-site-scene__car--arriving {
  fill: var(--text-primary);
}

.hero-site-scene__glass {
  fill: var(--surface-subtle);
}

.hero-site-scene__unit {
  fill: var(--surface-muted);
}

.hero-site-scene__unit--booked {
  fill: var(--state-success-bg);
  stroke: var(--state-success);
  stroke-width: 2;
}

.hero-site-scene__slat {
  fill: none;
  stroke: var(--border-control);
  stroke-width: 2;
  stroke-linecap: round;
  opacity: 0.45;
}

.hero-site-scene__lock-body {
  fill: var(--state-success);
}

.hero-site-scene__lock-shackle {
  fill: none;
  stroke: var(--state-success);
  stroke-width: 3;
  stroke-linecap: round;
}

.hero-site-scene__stall-pick {
  fill: var(--public-tint);
  stroke: var(--public-tint-icon);
  stroke-width: 2;
  opacity: 0;
}

.hero-site-scene__stall-booked {
  fill: var(--state-success-bg);
  stroke: var(--state-success);
  stroke-width: 2;
}

.hero-site-scene__stall-open {
  fill: none;
  stroke: var(--border-control);
  stroke-width: 2;
  stroke-dasharray: 6 6;
  opacity: 0;
}

.hero-site-scene__gate {
  fill: var(--text-primary);
  transform-box: fill-box;
  transform-origin: 0% 50%;
}

.hero-site-scene__post {
  fill: var(--border-control);
}

/* Status pill floating over the picture, beside stall A03. */
.hero-site-scene__status {
  position: absolute;
  top: 44%;
  left: 29%;
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  margin: 0;
  padding: 0.375rem 0.75rem;
  border: 1px solid var(--border-ui);
  border-radius: var(--radius-chip);
  background: var(--surface-raised);
  box-shadow: var(--shadow-floating);
  color: var(--text-primary);
  font-size: var(--font-size-sm);
  font-weight: 500;
  line-height: 1.45;
  white-space: nowrap;
}

.hero-site-scene__status-dot {
  width: 0.5rem;
  height: 0.5rem;
  border-radius: var(--radius-chip);
  background: var(--state-success);
}

.hero-site-scene__status-booked {
  display: none;
}

.hero-site-scene__caption {
  margin-top: 0.75rem;
  color: var(--text-caption);
  font-size: var(--font-size-sm);
  line-height: 1.45;
}

/* Resting state above: parked, paid and S4 locked. heroSiteScene.js plays the
   picture once in time with the steps beside it by setting data-scene-step,
   then removes it so the picture rests again. Under five seconds in total, so
   it needs no pause control. Reduced motion never sets a step. */
.hero-site-scene[data-scene-step] .hero-site-scene__arrival {
  transform: translateY(460px);
}

.hero-site-scene[data-scene-step="1"] :is(.hero-site-scene__stall-booked, .hero-site-scene__status),
.hero-site-scene[data-scene-step]:not([data-scene-step="4"]) .hero-site-scene__locked {
  opacity: 0;
}

.hero-site-scene[data-scene-step="1"] .hero-site-scene__stall-pick {
  opacity: 1;
}

.hero-site-scene[data-scene-step="2"] .hero-site-scene__status-booked {
  display: inline;
}

.hero-site-scene[data-scene-step="2"] .hero-site-scene__status-paid {
  display: none;
}

@keyframes hero-site-scene-arrive {
  0%,
  10% {
    transform: translateY(460px);
    animation-timing-function: var(--motion-ease);
  }

  70%,
  100% {
    transform: translateY(0);
  }
}

@keyframes hero-site-scene-gate {
  0% {
    transform: rotate(0deg);
  }

  12%,
  60% {
    transform: rotate(-82deg);
  }

  80%,
  100% {
    transform: rotate(0deg);
  }
}

@keyframes hero-site-scene-lock {
  0%,
  72% {
    opacity: 0;
  }

  88%,
  100% {
    opacity: 1;
  }
}

@media (prefers-reduced-motion: no-preference) {
  :is(.hero-site-scene__stall-pick, .hero-site-scene__stall-booked, .hero-site-scene__status) {
    transition: opacity 0.3s var(--motion-ease);
  }

  .hero-site-scene[data-scene-step="4"] .hero-site-scene__arrival {
    animation: hero-site-scene-arrive 1.5s linear both;
  }

  .hero-site-scene[data-scene-step="4"] .hero-site-scene__gate {
    animation: hero-site-scene-gate 1.5s var(--motion-ease) both;
  }

  .hero-site-scene[data-scene-step="4"] .hero-site-scene__locked {
    animation: hero-site-scene-lock 1.5s var(--motion-ease) both;
  }
}
