/* =========================================================
   Spatial Hero V2.1 — Controls
   Desktop side arrows (geometric) + bottom index rail
========================================================= */

/* —— Desktop side arrows —— */
.sv-spatial-hero__arrow {
  position: absolute;
  top: 28%;
  z-index: 14;
  display: none;
  align-items: center;
  justify-content: center;
  width: 48px;
  height: 48px;
  padding: 0;
  border: 1px solid rgba(30, 40, 46, 0.28);
  background: rgba(243, 241, 235, 0.72);
  backdrop-filter: blur(10px);
  cursor: pointer;
  color: var(--sv-ink);
  transition: background 240ms, border-color 240ms, transform 240ms;
  clip-path: polygon(
    0 0,
    calc(100% - 8px) 0,
    100% 8px,
    100% 100%,
    8px 100%,
    0 calc(100% - 8px)
  );
}

@media (hover: hover) and (pointer: fine) {
  .sv-spatial-hero__arrow {
    display: grid;
    place-items: center;
  }
}

.sv-spatial-hero__arrow--prev {
  left: clamp(8px, 2.5vw, 28px);
}

.sv-spatial-hero__arrow--next {
  right: clamp(8px, 2.5vw, 28px);
}

/* Geometric chevron built from lines */
.sv-spatial-hero__arrow-geo {
  position: relative;
  display: block;
  width: 14px;
  height: 14px;
}

.sv-spatial-hero__arrow--prev .sv-spatial-hero__arrow-geo::before {
  content: "";
  position: absolute;
  top: 50%;
  left: 4px;
  width: 8px;
  height: 1px;
  background: currentColor;
  transform: translateY(-50%) rotate(-45deg);
  transform-origin: left center;
}

.sv-spatial-hero__arrow--prev .sv-spatial-hero__arrow-geo::after {
  content: "";
  position: absolute;
  top: 50%;
  left: 4px;
  width: 8px;
  height: 1px;
  background: currentColor;
  transform: translateY(-50%) rotate(45deg);
  transform-origin: left center;
}

.sv-spatial-hero__arrow--next .sv-spatial-hero__arrow-geo::before {
  content: "";
  position: absolute;
  top: 50%;
  right: 4px;
  width: 8px;
  height: 1px;
  background: currentColor;
  transform: translateY(-50%) rotate(45deg);
  transform-origin: right center;
}

.sv-spatial-hero__arrow--next .sv-spatial-hero__arrow-geo::after {
  content: "";
  position: absolute;
  top: 50%;
  right: 4px;
  width: 8px;
  height: 1px;
  background: currentColor;
  transform: translateY(-50%) rotate(-45deg);
  transform-origin: right center;
}

@media (hover: hover) {
  .sv-spatial-hero__arrow:hover {
    background: rgba(30, 40, 46, 0.08);
    border-color: rgba(30, 40, 46, 0.55);
  }
  .sv-spatial-hero__arrow--prev:hover {
    transform: translateX(-2px);
  }
  .sv-spatial-hero__arrow--next:hover {
    transform: translateX(2px);
  }
}

/* —— Bottom index rail —— */
.sv-spatial-hero__navigation {
  position: relative;
  z-index: 12;
  display: flex;
  align-items: stretch;
  justify-content: center;
  gap: clamp(8px, 1.8vw, 24px);
  width: min(calc(100% - 32px), 680px);
  margin: 14px auto 0;
  padding: 10px 0 20px;
}

.sv-spatial-hero__nav-button {
  position: relative;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  min-height: 40px;
  padding: 4px 2px 12px;
  border: 0;
  background: transparent;
  color: var(--sv-muted);
  cursor: pointer;
  text-align: left;
  transition: color 220ms ease;
}

.sv-spatial-hero__nav-button:hover {
  color: var(--sv-ink);
}

.sv-spatial-hero__nav-index {
  font-size: 9px;
  letter-spacing: 0.14em;
  font-variant-numeric: tabular-nums;
}

.sv-spatial-hero__nav-label {
  font-size: 12px;
  letter-spacing: 0.02em;
  white-space: nowrap;
}

.sv-spatial-hero__nav-marker {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  height: 1px;
  background: var(--sv-ink);
  transform: scaleX(0);
  transform-origin: left center;
  transition: transform 340ms var(--sv-ease);
}

.sv-spatial-hero__nav-button[aria-pressed="true"] {
  color: var(--sv-ink);
}

.sv-spatial-hero__nav-button[aria-pressed="true"] .sv-spatial-hero__nav-marker {
  transform: scaleX(1);
}

.sv-spatial-hero__nav-divider {
  display: block;
  width: 1px;
  min-height: 18px;
  margin: auto 0;
  background: var(--sv-line);
  align-self: center;
}

.sv-spatial-hero__nav-button:focus-visible,
.sv-spatial-hero__arrow:focus-visible,
.sv-spatial-entry__select:focus-visible,
.sv-spatial-entry__cta:focus-visible {
  outline: 2px solid #506c80;
  outline-offset: 3px;
}

@media (max-width: 767px) {
  .sv-spatial-hero__arrow {
    display: none !important;
  }

  .sv-spatial-hero__navigation {
    gap: 4px;
    width: calc(100% - 20px);
    margin-top: 8px;
    padding: 6px 0 16px;
  }

  .sv-spatial-hero__nav-button {
    flex: 1;
    justify-content: center;
    min-width: 0;
    padding: 4px 0 10px;
  }

  .sv-spatial-hero__nav-label {
    font-size: clamp(9px, 2.5vw, 11px);
    white-space: normal;
    line-height: 1.25;
    text-align: center;
  }
}
