/* Track hero visual v2 */
.track-hero {
  position: relative;
  width: 100%;
  min-height: 560px;
  overflow: hidden;
  color: #fff;
  background:
    linear-gradient(90deg, rgba(0,0,0,.88) 0%, rgba(0,0,0,.74) 32%, rgba(0,0,0,.48) 62%, rgba(0,0,0,.68) 100%),
    radial-gradient(circle at 70% 45%, rgba(50,50,50,.14), rgba(0,0,0,.58)),
    #071018;
  background-size: cover;
  background-position: center center;
  border-radius: 0;
}

.track-hero-overlay {
  position: absolute;
  inset: 0;
  background:
    linear-gradient(90deg, rgba(0,0,0,.90) 0%, rgba(0,0,0,.82) 28%, rgba(0,0,0,.45) 58%, rgba(0,0,0,.58) 100%);
  pointer-events: none;
}

.track-hero-inner {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: minmax(220px, 300px) minmax(0, 1fr);
  gap: 10px;
  align-items: stretch;
  min-height: 560px;
  padding: 34px 34px 24px 38px;
  box-sizing: border-box;
}

.track-hero-left {
  display: flex;
  flex-direction: column;
  justify-content: flex-start;
  gap: 30px;
  padding-top: 8px;
}

.track-hero-right {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  min-width: 0;
  overflow: hidden;
}

.track-hero-title-row {
  display: flex;
  align-items: center;
  gap: 16px;
  flex-wrap: wrap;
}

.track-hero-title {
  margin: 0;
  font-family: Arial, sans-serif;
  font-size: clamp(34px, 3.4vw, 52px);
  line-height: 1;
  font-weight: 800;
  letter-spacing: -1.2px;
  color: #ffffff;
}

.track-hero-flag {
  font-size: clamp(34px, 3.2vw, 44px);
  line-height: 1;
  display: inline-flex;
  align-items: center;
}

.track-hero-direction {
  margin-top: 10px;
  font-family: Arial, sans-serif;
  font-size: clamp(30px, 2.5vw, 42px);
  line-height: 1.05;
  font-style: italic;
  font-weight: 300;
  color: rgba(255,255,255,.92);
}

.track-hero-info-block {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.track-hero-label {
  font-family: Arial, sans-serif;
  font-size: clamp(26px, 2.6vw, 46px);
  line-height: 1.05;
  font-weight: 800;
  color: #fff;
}

.track-hero-value {
  font-family: Arial, sans-serif;
  font-size: clamp(28px, 2.4vw, 44px);
  line-height: 1.05;
  font-style: italic;
  font-weight: 300;
  color: rgba(255,255,255,.96);
}

.track-hero-reveal {
  opacity: 0;
  transform: translateY(14px);
  transition:
    opacity 320ms ease-out,
    transform 320ms ease-out;
}

.track-hero-reveal.is-visible {
  opacity: 1;
  transform: translateY(0);
}

.track-scene {
  width: 100%;
  height: 100%;
  min-height: 480px;
  display: flex;
  align-items: center;
  justify-content: center;
  perspective: 1600px;
  --track-tilt: 30deg;
  overflow: hidden;
}

.track-stage {
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  transform-origin: 50% 50%;
  transform-style: preserve-3d;
  transition: transform 1050ms cubic-bezier(.22,1,.36,1);
  will-change: transform;
}

.track-scene.is-tilted .track-stage {
  transform: rotateX(var(--track-tilt)) scale(0.86);
}

.track-stage svg {
  display: block;
  width: 100%;
  height: 100%;
  max-width: 100%;
  max-height: calc(100% - 20px);
  overflow: visible;
}

.track-draw-overlay {
  fill: none;
  stroke: #ffffff;
  stroke-linecap: round;
  stroke-linejoin: round;
  filter: drop-shadow(0 0 12px rgba(255,255,255,.92));
  pointer-events: none;
}

.track-sector-segment {
  fill: none;
  pointer-events: none;
  filter: drop-shadow(0 0 10px rgba(255,255,255,.16));
}

.track-sector-glow {
  fill: none;
  pointer-events: none;
  filter: blur(4px);
}

.track-sector-title-box {
  fill: rgba(10, 15, 26, 0.78);
  stroke-width: 2;
  filter: drop-shadow(0 8px 18px rgba(0,0,0,.35));
}

.track-sector-title-main {
  font-family: Arial, sans-serif;
  font-size: 18px;
  font-weight: 700;
  text-anchor: middle;
  dominant-baseline: middle;
  paint-order: stroke fill;
  stroke: rgba(0,0,0,.55);
  stroke-width: 4px;
  letter-spacing: .4px;
  pointer-events: none;
}

.track-sector-title-sub {
  font-family: Arial, sans-serif;
  font-size: 12px;
  font-weight: 500;
  text-anchor: middle;
  dominant-baseline: middle;
  paint-order: stroke fill;
  stroke: rgba(0,0,0,.45);
  stroke-width: 3px;
  letter-spacing: .2px;
  pointer-events: none;
}

@media (max-width: 900px) {
  .track-hero-inner {
    grid-template-columns: 1fr;
    gap: 12px;
    padding: 28px 22px 22px 22px;
  }

  .track-hero-left {
    gap: 20px;
  }

  .track-hero-right {
    min-height: 360px;
  }

  .track-scene {
    min-height: 340px;
  }
}


.track-finish-overlay-group {
  pointer-events: none;
}

.track-finish-overlay-outer,
.track-finish-overlay-inner {
  pointer-events: none;
}


.track-finish-overlay-group {
  pointer-events: none;
}

.track-finish-overlay-outer {
  pointer-events: none;
  filter: drop-shadow(0 0 3px rgba(0,0,0,.28));
}

.track-finish-overlay-inner {
  pointer-events: none;
}

.track-sector-flag-pole {
  stroke: rgba(255,255,255,.96);
  stroke-width: 2.2;
  stroke-linecap: round;
  filter: drop-shadow(0 3px 6px rgba(0,0,0,.35));
}

.track-sector-flag-shape {
  stroke: rgba(255,255,255,.92);
  stroke-width: 1.5;
  stroke-linejoin: round;
  filter: drop-shadow(0 6px 10px rgba(0,0,0,.30));
}

.track-sector-flag-text {
  fill: #ffffff;
  font-family: Arial, sans-serif;
  font-size: 10px;
  font-weight: 700;
  text-anchor: middle;
  dominant-baseline: middle;
  paint-order: stroke fill;
  stroke: rgba(0,0,0,.26);
  stroke-width: 2px;
  pointer-events: none;
}


.track-sector-segment,
.track-sector-glow {
  stroke-linecap: butt;
  stroke-linejoin: miter;
}

.track-sector-glow {
  filter: blur(2.6px);
}

.track-sector-flag-pole-shadow {
  stroke: rgba(0,0,0,.30);
  stroke-width: 3.2;
  stroke-linecap: round;
}

.track-sector-flag-shadow {
  fill: rgba(0,0,0,.22);
}

.track-sector-flag-back {
  opacity: 0.48;
  filter: brightness(.72);
}

.track-sector-flag-pole {
  stroke: rgba(255,255,255,.96);
  stroke-width: 2.2;
  stroke-linecap: round;
  filter: drop-shadow(0 3px 6px rgba(0,0,0,.35));
}

.track-sector-flag-shape {
  stroke: rgba(255,255,255,.92);
  stroke-width: 1.5;
  stroke-linejoin: round;
  filter: drop-shadow(0 6px 10px rgba(0,0,0,.30));
}


.track-draw-overlay {
  stroke-linecap: butt;
  stroke-linejoin: miter;
}


.track-sector-flag-base-shadow {
  fill: rgba(0,0,0,.32);
  filter: blur(1.2px);
}

.track-sector-flag-foot {
  fill: rgba(210,210,210,.95);
  stroke: rgba(90,90,90,.35);
  stroke-width: 0.7;
}

.track-sector-flag-pole-shadow {
  stroke: rgba(0,0,0,.28);
  stroke-width: 3.6;
  stroke-linecap: round;
}

.track-sector-flag-pole {
  stroke: rgba(250,250,250,.98);
  stroke-width: 2.4;
  stroke-linecap: round;
  filter: drop-shadow(0 2px 4px rgba(0,0,0,.30));
}

.track-sector-flag-shadow {
  fill: rgba(0,0,0,.20);
  filter: blur(1.2px);
}

.track-sector-flag-back {
  opacity: 0.52;
  filter: brightness(.62) saturate(.95);
}

.track-sector-flag-side {
  opacity: 0.72;
  filter: brightness(.78);
}

.track-sector-flag-shape {
  stroke: rgba(255,255,255,.92);
  stroke-width: 1.4;
  stroke-linejoin: round;
  filter: drop-shadow(0 4px 8px rgba(0,0,0,.22));
}

.track-sector-flag-text {
  fill: #ffffff;
  font-family: Arial, sans-serif;
  font-size: 10px;
  font-weight: 700;
  text-anchor: middle;
  dominant-baseline: middle;
  paint-order: stroke fill;
  stroke: rgba(0,0,0,.32);
  stroke-width: 2px;
  pointer-events: none;
}


.track-sector-marker {
  pointer-events: none;
}

.track-sector-marker-body {
  pointer-events: none;
  transform-box: fill-box;
  transform-origin: center bottom;
}


.track-hero-label {
  font-size: clamp(24px, 2.2vw, 40px);
}

.track-hero-value {
  font-size: clamp(24px, 2vw, 40px);
}

.track-hero-direction {
  font-size: clamp(26px, 2.2vw, 38px);
}


.track-hero-inner {
  grid-template-columns: minmax(210px, 280px) minmax(0, 1fr);
  grid-template-rows: auto 1fr;
  padding: 26px 28px 18px 34px;
}

.track-hero-header {
  grid-column: 1 / -1;
  grid-row: 1;
  min-width: 0;
  margin-bottom: 4px;
}

.track-hero-left {
  grid-column: 1;
  grid-row: 2;
  padding-top: 0;
  gap: 22px;
  min-width: 0;
}

.track-hero-right {
  grid-column: 2;
  grid-row: 2;
}

.track-hero-title-row--single {
  flex-wrap: nowrap;
  white-space: nowrap;
  overflow: hidden;
}

.track-hero-title {
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  width: 100%;
  font-size: clamp(34px, 4.1vw, 62px);
  color: #ffffff;
}

.track-hero-flagline {
  display: flex;
  align-items: center;
  min-height: 44px;
}

.track-hero-direction {
  margin-top: 4px;
  font-size: clamp(24px, 2.1vw, 36px);
}

.track-hero-label {
  font-size: clamp(22px, 2vw, 38px);
}

.track-hero-value {
  font-size: clamp(22px, 1.9vw, 38px);
}

.track-scene {
  min-height: 0;
  padding: 8px 0 4px 0;
  perspective: 1500px;
  perspective-origin: 50% 50%;
  overflow: hidden;
}

.track-stage {
  width: 100%;
  height: 100%;
  padding: 8px 8px 10px 8px;
  box-sizing: border-box;
  display: flex;
  align-items: center;
  justify-content: center;
}

.track-scene.is-tilted .track-stage {
  transform-origin: 50% 58%;
  transform: translateY(-28px) rotateX(var(--track-tilt)) scale(1.02);
}

.track-stage svg {
  width: auto;
  height: 100%;
  max-width: 100%;
  max-height: 100%;
  margin: 0 auto;
  display: block;
}

@media (max-width: 900px) {
  .track-hero-inner {
    grid-template-columns: 1fr;
    grid-template-rows: auto auto 1fr;
  }

  .track-hero-header {
    grid-column: 1;
    grid-row: 1;
  }

  .track-hero-left {
    grid-column: 1;
    grid-row: 2;
  }

  .track-hero-right {
    grid-column: 1;
    grid-row: 3;
  }

  .track-hero-title {
    font-size: clamp(30px, 7vw, 46px);
  }
}


.track-hero-title-row--single {
  align-items: center;
  gap: 16px;
}

.track-hero-title-row--single .track-hero-flag,
.track-hero-title-row--single .track-hero-country-flag,
.track-hero-title-row--single img.track-hero-country-flag {
  flex: 0 0 auto;
}

.track-hero-title-row--single .track-hero-title {
  flex: 1 1 auto;
}

.track-hero-flagline {
  display: none;
}


.track-hero-mapActionWrap{
  position:absolute;
  top:18px;
  right:18px;
  z-index:5;
  display:flex;
  justify-content:flex-end;
}

.track-hero-mapAction{
  display:inline-flex;
  align-items:center;
  justify-content:center;
  min-height:40px;
  padding:0 16px;
  border-radius:999px;
  text-decoration:none;
  font-family:Arial, sans-serif;
  font-size:14px;
  font-weight:700;
  color:#ffffff;
  background:rgba(18,30,46,.82);
  border:1px solid rgba(255,255,255,.16);
  box-shadow:0 10px 24px rgba(0,0,0,.24);
  backdrop-filter:blur(6px);
}

.track-hero-mapAction:hover{
  color:#ffffff;
  text-decoration:none;
  background:rgba(29,50,74,.92);
  border-color:rgba(255,255,255,.24);
}

@media (max-width: 900px){
  .track-hero-mapActionWrap{
    top:12px;
    right:12px;
  }

  .track-hero-mapAction{
    min-height:36px;
    padding:0 14px;
    font-size:13px;
  }
}


.track-hero-header {
  margin-bottom: 8px;
  padding-top: 2px;
}

.track-hero-title-row--single {
  align-items: flex-start;
}

.track-hero-title {
  line-height: 1.08;
  padding-bottom: 0.08em;
}

.track-hero-mapActionWrap{
  position: static;
  top: auto;
  right: auto;
  z-index: auto;
  display: flex;
  justify-content: flex-start;
  margin-top: 4px;
}

.track-hero-mapAction{
  min-height: 38px;
}


/* v24 fixes: show country flag next to title, keep button under sectors */
.track-hero-title-row--single {
  align-items: center;
  gap: 14px;
  flex-wrap: nowrap;
  white-space: nowrap;
  overflow: hidden;
}

.track-hero-title-row--single .track-hero-flag {
  display: inline-flex;
  align-items: center;
  flex: 0 0 auto;
  line-height: 1;
}

.track-hero-title-row--single .track-hero-flag .track-hero-country-flag,
.track-hero-title-row--single .track-hero-country-flag,
.track-hero-title-row--single img.track-hero-country-flag {
  width: 42px;
  height: 42px;
  object-fit: contain;
  display: inline-block;
}

.track-hero-flagline {
  display: none !important;
}

.track-hero-mapActionWrap {
  position: static !important;
  top: auto !important;
  right: auto !important;
  z-index: auto !important;
  display: flex !important;
  justify-content: flex-start !important;
  margin-top: 4px;
}

.track-hero-mapAction {
  min-height: 38px;
}

.track-hero-title {
  line-height: 1.08;
  padding-bottom: 0.08em;
}
