/* ===== Hero Home – model referință ===== */

.hero {
  --hero-navy: #0b1120;
  --hero-white: #ffffff;
  --hero-black: #0a0a0a;
  --hero-gray-light: #e5e7eb;
  --hero-gray: #9ca3af;
  --hero-gray-muted: #6b7280;
  --hero-text: var(--hero-gray-light);
  --hero-space: clamp(1.5rem, 4vw, 4rem);
  --hero-radius: 10px;

  position: relative;
  width: 100%;
  min-height: 100vh;
  min-height: 100svh;
  min-height: 100dvh;
  padding-top: var(--header-h);
  box-sizing: border-box;
  background: var(--hero-navy);
  overflow: hidden;
}

/* Camion cinematic – centru-dreapta, vizibil */
.hero__bg {
  position: absolute;
  inset: 0;
  z-index: 0;
  background-position: 55% center;
  background-size: cover;
  background-repeat: no-repeat;
}

.hero__overlay {
  position: absolute;
  inset: 0;
  z-index: 0;
  background:
    linear-gradient(90deg, rgba(11, 17, 32, 0.94) 0%, rgba(11, 17, 32, 0.7) 32%, rgba(11, 17, 32, 0.2) 55%, rgba(11, 17, 32, 0.05) 72%, transparent 100%),
    linear-gradient(180deg, rgba(11, 17, 32, 0.35) 0%, transparent 28%, rgba(11, 17, 32, 0.5) 100%);
  pointer-events: none;
}

/* Hartă – dreapta-sus, ~45% lățime, în prim-plan (model imagine 2) */
.hero__map-layer {
  position: absolute;
  top: calc(var(--header-h) + 0.5rem);
  right: clamp(0.75rem, 2.5vw, 2.25rem);
  width: min(46vw, 620px);
  max-width: 48%;
  height: min(calc(100dvh - var(--header-h) - 7.5rem), 76vh);
  z-index: 2;
  pointer-events: none;
}

.hero__map-layer::before {
  content: '';
  position: absolute;
  inset: 0 5% 12%;
  background: radial-gradient(ellipse 70% 60% at 55% 42%, rgba(59, 130, 246, 0.1) 0%, transparent 68%);
  pointer-events: none;
  z-index: 0;
}

.hero__map-layer .moldova-scene {
  pointer-events: auto;
}

.hero__inner {
  position: relative;
  z-index: 3;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  width: 100%;
  max-width: 1440px;
  min-height: calc(100dvh - var(--header-h));
  margin: 0 auto;
  padding:
    clamp(2rem, 5vh, 3.5rem) var(--hero-space)
    clamp(1.25rem, 2.5vh, 2rem);
}

.hero__row {
  display: none;
}

/* —— Conținut stânga —— */
.hero__content {
  display: flex;
  flex-direction: column;
  gap: 0;
  max-width: min(32rem, 44%);
  padding-top: clamp(0.5rem, 2vh, 1.5rem);
}

.hero__eyebrow {
  margin: 0 0 1.25rem;
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--hero-gray);
}

.hero__title {
  margin: 0;
  font-size: clamp(2rem, 3.8vw, 3.1rem);
  font-weight: 700;
  line-height: 1.15;
  letter-spacing: -0.02em;
  color: var(--hero-white);
  text-wrap: balance;
}

.hero__title-accent {
  display: block;
  color: var(--hero-gray-light);
  font-weight: 700;
}

.hero__text {
  margin: 1.5rem 0 0;
  max-width: 42ch;
  font-size: clamp(0.95rem, 1.1vw, 1.05rem);
  line-height: 1.7;
  color: var(--hero-gray);
}

.hero__actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.85rem;
  margin-top: 2rem;
}

.hero__btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  min-height: 3rem;
  padding: 0.7rem 1.5rem;
  border-radius: var(--hero-radius);
  font-size: 0.82rem;
  font-weight: 600;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  text-decoration: none;
  border: 1px solid transparent;
  transition: background 0.2s ease, border-color 0.2s ease, color 0.2s ease, transform 0.2s ease;
}

.hero__btn-icon {
  width: 1.1rem;
  height: 1.1rem;
  flex-shrink: 0;
}

.hero__btn:hover {
  transform: translateY(-1px);
}

.hero__btn--primary {
  color: var(--hero-black);
  background: var(--hero-white);
  border-color: var(--hero-white);
}

.hero__btn--primary:hover {
  color: var(--hero-black);
  background: var(--hero-gray-light);
  border-color: var(--hero-gray-light);
}

.hero__btn--ghost {
  color: var(--hero-white);
  background: transparent;
  border-color: rgba(255, 255, 255, 0.35);
}

.hero__btn--ghost:hover {
  color: var(--hero-gray-light);
  border-color: rgba(255, 255, 255, 0.55);
  background: rgba(255, 255, 255, 0.06);
}

/* —— Statistici jos + etichetă sedii dreapta —— */
.hero__stats-bar {
  display: flex;
  align-items: stretch;
  justify-content: flex-start;
  gap: 1rem;
  margin: auto 0 0;
  padding: 0;
  width: 100%;
  max-width: 52rem;
}

.hero__stats-cards {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 1rem;
  flex: 1;
  margin: 0;
  padding: 0;
}

.hero__stat {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  margin: 0;
  padding: 1.25rem 1.5rem;
  border-radius: var(--hero-radius);
  background: rgba(15, 23, 42, 0.55);
  border: 1px solid rgba(255, 255, 255, 0.08);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  transition: border-color 0.2s ease, background 0.2s ease;
}

.hero__stat:hover {
  border-color: rgba(255, 255, 255, 0.18);
  background: rgba(15, 23, 42, 0.65);
}

.hero__stat-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 2.25rem;
  height: 2.25rem;
  margin-bottom: 0.85rem;
  border-radius: 50%;
  border: 1.5px solid rgba(255, 255, 255, 0.28);
  color: var(--hero-gray-light);
  background: rgba(255, 255, 255, 0.04);
}

.hero__stat-icon svg {
  width: 1.05rem;
  height: 1.05rem;
}

.hero__stat-value {
  margin: 0 0 0.2rem;
  font-size: clamp(1.5rem, 2.2vw, 1.85rem);
  font-weight: 700;
  color: var(--hero-white);
  font-variant-numeric: tabular-nums;
  line-height: 1.1;
}

.hero__stat-label {
  margin: 0;
  font-size: 0.78rem;
  line-height: 1.4;
  color: var(--hero-gray);
}

/* —— Hartă Moldova —— */
.moldova-scene {
  position: relative;
  z-index: 1;
  width: 100%;
  height: 100%;
  max-width: none;
  margin: 0;
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  justify-content: flex-start;
}

.moldova-scene__frame {
  position: relative;
  width: 100%;
  flex: 1 1 auto;
  min-height: 0;
  display: flex;
  align-items: flex-start;
  justify-content: flex-end;
}

.moldova-scene__svg {
  display: block;
  width: 100%;
  height: 100%;
  min-height: 280px;
  overflow: visible;
}

.moldova-scene__wash {
  opacity: 0.65;
}

.moldova-scene__counties-context {
  opacity: 0.2;
}

.moldova-scene__county {
  fill: rgba(59, 130, 246, 0.05);
  stroke: rgba(96, 165, 250, 0.14);
  stroke-width: 0.6;
  vector-effect: non-scaling-stroke;
}

.moldova-scene__county--focus {
  opacity: 0.92;
  fill: rgba(59, 130, 246, 0.18);
  stroke: rgba(147, 197, 253, 0.62);
  stroke-width: 1.25;
  vector-effect: non-scaling-stroke;
}

.moldova-scene__county-name {
  font-family: inherit;
  font-size: 22px;
  font-weight: 600;
  fill: rgba(148, 163, 184, 0.32);
  letter-spacing: 0.1em;
  text-transform: uppercase;
  pointer-events: none;
}

.moldova-scene__route-base {
  fill: none;
  stroke: rgba(255, 255, 255, 0.28);
  stroke-width: 1.1;
  stroke-linecap: round;
  stroke-linejoin: round;
  vector-effect: non-scaling-stroke;
}

.moldova-scene__route-comet {
  fill: none;
  stroke: url(#moldova-route-gradient);
  stroke-width: 1.5;
  stroke-linecap: round;
  stroke-linejoin: round;
  vector-effect: non-scaling-stroke;
  stroke-dasharray: 14 110;
  stroke-dashoffset: 14;
  animation: moldovaRouteComet 5s ease-in-out infinite;
}

@keyframes moldovaRouteComet {
  0% { stroke-dashoffset: 14; opacity: 0; }
  10% { opacity: 0.8; }
  90% { opacity: 0.8; }
  100% { stroke-dashoffset: -110; opacity: 0; }
}

.moldova-scene__pin-group {
  cursor: pointer;
  outline: none;
}

.moldova-scene__leader {
  stroke: rgba(96, 165, 250, 0.25);
  stroke-width: 0.75;
  vector-effect: non-scaling-stroke;
  transition: stroke 0.2s ease;
}

.moldova-scene__pulse {
  fill: none;
  stroke: rgba(96, 165, 250, 0.5);
  stroke-width: 1;
  transform-box: fill-box;
  transform-origin: center;
  opacity: 0;
  vector-effect: non-scaling-stroke;
  animation: moldovaPinPulse 4s ease-out infinite;
}

@keyframes moldovaPinPulse {
  0% { transform: scale(0.8); opacity: 0; }
  20% { opacity: 0.5; }
  70% { opacity: 0; transform: scale(2); }
  100% { opacity: 0; transform: scale(2); }
}

.moldova-scene__pin {
  fill: rgba(59, 130, 246, 0.2);
  stroke: rgba(96, 165, 250, 0.6);
  stroke-width: 1;
}

.moldova-scene__dot {
  fill: #ffffff;
  stroke: #93c5fd;
  stroke-width: 2.25;
  filter: drop-shadow(0 0 10px rgba(255, 255, 255, 0.75)) drop-shadow(0 0 18px rgba(59, 130, 246, 0.55));
  transition: transform 0.2s ease;
}

.moldova-scene__label {
  font-family: inherit;
  font-size: 40px;
  font-weight: 600;
  fill: rgba(255, 255, 255, 0.98);
  paint-order: stroke fill;
  stroke: rgba(11, 17, 32, 0.88);
  stroke-width: 5px;
  stroke-linejoin: round;
  transition: fill 0.2s ease;
}

.moldova-scene__halo {
  fill: rgba(59, 130, 246, 0.08);
  stroke: rgba(96, 165, 250, 0.35);
  stroke-width: 0.75;
  opacity: 0;
  transition: opacity 0.2s ease;
}

.moldova-scene__pin-group:hover .moldova-scene__label,
.moldova-scene__pin-group.is-active .moldova-scene__label {
  fill: var(--hero-gray-light);
}

.moldova-scene__pin-group:hover .moldova-scene__leader,
.moldova-scene__pin-group.is-active .moldova-scene__leader {
  stroke: rgba(96, 165, 250, 0.5);
}

.moldova-scene__pin-group.is-active .moldova-scene__pin {
  fill: rgba(59, 130, 246, 0.25);
  stroke: rgba(96, 165, 250, 0.8);
}

.moldova-scene__pin-group.is-active .moldova-scene__halo {
  opacity: 1;
}

.moldova-scene__pin-group:focus-visible .moldova-scene__dot {
  stroke: #fff;
  stroke-width: 2;
}

/* Panou detalii sau etichetă sedii sub hartă */
.moldova-panel {
  position: relative;
  z-index: 4;
  width: 100%;
  margin-top: 0.35rem;
  padding: 0;
  border: none;
  background: transparent;
  text-align: center;
}

.moldova-panel.is-visible {
  position: absolute;
  right: 0;
  bottom: 2.25rem;
  width: min(16rem, 92%);
  padding: 0.75rem 0.9rem;
  border-radius: var(--hero-radius);
  background: rgba(11, 17, 32, 0.88);
  border: 1px solid rgba(96, 165, 250, 0.28);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  text-align: left;
}

.moldova-panel__hint {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.4rem;
  margin: 0;
  padding: 0.15rem 0;
  font-size: 0.65rem;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--hero-gray);
}

.moldova-panel__hint::before {
  content: '';
  display: inline-block;
  width: 0.85rem;
  height: 0.85rem;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none'%3E%3Cpath d='M12 21s-6-5.2-6-10a6 6 0 1112 0c0 4.8-6 10-6 10z' stroke='%239ca3af' stroke-width='1.5'/%3E%3Ccircle cx='12' cy='11' r='2' fill='%239ca3af'/%3E%3C/svg%3E");
  background-size: contain;
  background-repeat: no-repeat;
  flex-shrink: 0;
}

.moldova-panel__hint span {
  color: var(--hero-gray-light);
}

.moldova-panel__head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 0.75rem;
}

.moldova-panel__city {
  margin: 0;
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--hero-white);
}

.moldova-panel__role {
  margin: 0;
  font-size: 0.62rem;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--hero-gray);
  white-space: nowrap;
}

.moldova-panel__address {
  margin: 0.4rem 0 0;
  font-size: 0.76rem;
  line-height: 1.5;
  color: var(--hero-gray);
}

.moldova-panel__foot {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
  margin-top: 0.5rem;
  padding-top: 0.5rem;
  border-top: 1px solid rgba(255, 255, 255, 0.06);
}

.moldova-panel__phone {
  font-size: 0.76rem;
  color: var(--hero-white);
  text-decoration: none;
}

.moldova-panel__phone:hover {
  color: var(--hero-gray-light);
}

.moldova-panel__link {
  font-size: 0.72rem;
  font-weight: 600;
  color: var(--hero-gray-light);
  text-decoration: none;
}

.moldova-panel__link:hover {
  color: var(--hero-white);
}

/* Animații intrare */
.hero--ready .hero__eyebrow,
.hero--ready .hero__text,
.hero--ready .hero__stats-bar {
  animation: heroFadeIn 0.7s ease both;
}

.hero--ready .hero__title {
  animation: heroFadeIn 0.8s ease both;
}

.hero--ready .hero__actions {
  animation: heroFadeIn 0.75s ease both;
}

.hero--ready .hero__map-layer {
  animation: heroMapFade 1s ease 0.25s both;
}

@keyframes heroMapFade {
  from { opacity: 0; }
  to { opacity: 1; }
}

.hero--ready .hero__eyebrow { animation-delay: 0.05s; }
.hero--ready .hero__title { animation-delay: 0.12s; }
.hero--ready .hero__text { animation-delay: 0.3s; }
.hero--ready .hero__actions { animation-delay: 0.42s; }
.hero--ready .hero__stats-bar { animation-delay: 0.55s; }

@keyframes heroFadeIn {
  from { opacity: 0; transform: translateY(8px); }
  to { opacity: 1; transform: translateY(0); }
}

@media (prefers-reduced-motion: reduce) {
  .hero--ready .hero__eyebrow,
  .hero--ready .hero__title,
  .hero--ready .hero__text,
  .hero--ready .hero__actions,
  .hero--ready .hero__stats-bar,
  .hero--ready .moldova-scene,
  .moldova-scene__route-comet,
  .moldova-scene__pulse {
    animation: none !important;
    opacity: 1 !important;
    transform: none !important;
  }
}

/* —— Responsive —— */
@media (max-width: 1100px) {
  .hero {
    min-height: auto;
    display: flex;
    flex-direction: column;
  }

  .hero__inner {
    display: contents;
    min-height: auto;
  }

  .hero__content {
    order: 1;
    max-width: none;
    padding: clamp(1.5rem, 3vh, 2rem) var(--hero-space) 0;
  }

  .hero__map-layer {
    position: relative;
    top: auto;
    right: auto;
    order: 2;
    width: min(100%, 480px);
    max-width: 100%;
    height: min(48vh, 420px);
    margin: 1.25rem auto 0;
  }

  .hero__stats-bar {
    order: 3;
    flex-direction: column;
    align-items: stretch;
    margin: 0;
    padding: 1.5rem var(--hero-space) 2rem;
    max-width: none;
  }

  .hero__stats-cards {
    max-width: none;
  }

  .moldova-scene {
    align-items: center;
  }

  .moldova-scene__frame {
    justify-content: center;
    align-items: center;
  }
}

@media (max-width: 640px) {
  .hero {
    --hero-space: 1.25rem;
  }

  .hero__title {
    font-size: clamp(1.65rem, 7vw, 2.1rem);
  }

  .hero__actions {
    flex-direction: column;
    align-items: stretch;
  }

  .hero__btn {
    width: 100%;
  }

  .hero__stats-bar {
    grid-template-columns: 1fr;
    gap: 0.75rem;
  }

  .moldova-scene {
    height: auto;
    max-width: 100%;
  }

  .moldova-scene__frame {
    height: auto;
  }

  .moldova-scene__svg {
    height: auto;
    max-height: min(42vh, 280px);
    aspect-ratio: 1191 / 2155;
  }
}
