/* ============================================
   CORPORATE HERO — Engineering Grid Background
   ============================================ */

.gpw-hero {
  position: relative;
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  padding-top: var(--header-height);
  background: #0a1628;
}

/* Engineering grid layer */
.gpw-hero__grid {
  position: absolute;
  top: 0; left: 0;
  width: 100%; height: 100%;
  z-index: 0;
  /* Minor grid */
  background-image:
    linear-gradient(rgba(35, 85, 90, 0.07) 1px, transparent 1px),
    linear-gradient(90deg, rgba(35, 85, 90, 0.07) 1px, transparent 1px),
    /* Major grid */
    linear-gradient(rgba(35, 85, 90, 0.15) 1px, transparent 1px),
    linear-gradient(90deg, rgba(35, 85, 90, 0.15) 1px, transparent 1px);
  background-size:
    40px 40px,
    40px 40px,
    200px 200px,
    200px 200px;
}

/* Glow spots at intersections */
.gpw-hero__glow {
  position: absolute;
  top: 0; left: 0;
  width: 100%; height: 100%;
  z-index: 0;
  pointer-events: none;
}

.gpw-hero__glow-dot {
  position: absolute;
  width: 6px;
  height: 6px;
  border-radius: 50%;
  animation: glowPulse 4s ease-in-out infinite;
}

.gpw-hero__glow-dot::after {
  content: '';
  position: absolute;
  top: 50%; left: 50%;
  transform: translate(-50%, -50%);
  width: 40px;
  height: 40px;
  border-radius: 50%;
  animation: glowSpread 4s ease-in-out infinite;
}

.gpw-hero__glow-dot--teal {
  background: var(--teal);
}
.gpw-hero__glow-dot--teal::after {
  background: radial-gradient(circle, rgba(35, 85, 90, 0.3) 0%, transparent 70%);
}

.gpw-hero__glow-dot--coral {
  background: var(--coral);
}
.gpw-hero__glow-dot--coral::after {
  background: radial-gradient(circle, rgba(237, 131, 94, 0.2) 0%, transparent 70%);
}

.gpw-hero__glow-dot--lime {
  background: var(--lime);
}
.gpw-hero__glow-dot--lime::after {
  background: radial-gradient(circle, rgba(173, 207, 145, 0.2) 0%, transparent 70%);
}

@keyframes glowPulse {
  0%, 100% { opacity: 0.3; transform: scale(1); }
  50% { opacity: 0.8; transform: scale(1.3); }
}

@keyframes glowSpread {
  0%, 100% { opacity: 0.4; transform: translate(-50%, -50%) scale(1); }
  50% { opacity: 0.8; transform: translate(-50%, -50%) scale(1.5); }
}

/* Stagger animation delays for each dot */
.gpw-hero__glow-dot:nth-child(1) { animation-delay: 0s; }
.gpw-hero__glow-dot:nth-child(1)::after { animation-delay: 0s; }
.gpw-hero__glow-dot:nth-child(2) { animation-delay: 0.7s; }
.gpw-hero__glow-dot:nth-child(2)::after { animation-delay: 0.7s; }
.gpw-hero__glow-dot:nth-child(3) { animation-delay: 1.4s; }
.gpw-hero__glow-dot:nth-child(3)::after { animation-delay: 1.4s; }
.gpw-hero__glow-dot:nth-child(4) { animation-delay: 2.1s; }
.gpw-hero__glow-dot:nth-child(4)::after { animation-delay: 2.1s; }
.gpw-hero__glow-dot:nth-child(5) { animation-delay: 2.8s; }
.gpw-hero__glow-dot:nth-child(5)::after { animation-delay: 2.8s; }
.gpw-hero__glow-dot:nth-child(6) { animation-delay: 0.4s; }
.gpw-hero__glow-dot:nth-child(6)::after { animation-delay: 0.4s; }
.gpw-hero__glow-dot:nth-child(7) { animation-delay: 1.8s; }
.gpw-hero__glow-dot:nth-child(7)::after { animation-delay: 1.8s; }
.gpw-hero__glow-dot:nth-child(8) { animation-delay: 3.2s; }
.gpw-hero__glow-dot:nth-child(8)::after { animation-delay: 3.2s; }

/* Gradient overlay for depth + vignette */
.gpw-hero__overlay {
  position: absolute;
  top: 0; left: 0;
  width: 100%; height: 100%;
  background:
    radial-gradient(ellipse 60% 50% at 25% 75%, rgba(35, 85, 90, 0.12) 0%, transparent 70%),
    radial-gradient(ellipse 40% 40% at 75% 25%, rgba(237, 131, 94, 0.06) 0%, transparent 60%),
    radial-gradient(ellipse 100% 100% at 50% 50%, transparent 40%, rgba(10, 22, 40, 0.6) 100%);
  z-index: 1;
}

/* Content */
.gpw-hero__inner {
  position: relative;
  z-index: 2;
  text-align: center;
  max-width: 860px;
  margin: 0 auto;
  padding: var(--space-4xl) var(--space-xl);
}

.gpw-hero__tagline {
  font-family: var(--font-accent);
  font-size: var(--text-xs);
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.2em;
  color: var(--lime);
  margin-bottom: var(--space-lg);
  display: flex;
  align-items: center;
  justify-content: center;
  gap: var(--space-sm);
}

.gpw-hero__tagline::before,
.gpw-hero__tagline::after {
  content: '';
  width: 32px;
  height: 1px;
  background: var(--lime);
}

.gpw-hero h1 {
  font-size: clamp(2.2rem, 1.4rem + 3vw, 3.6rem);
  font-weight: 900;
  color: var(--white);
  line-height: 1.12;
  margin-bottom: var(--space-xl);
}

.gpw-hero__sub {
  font-size: var(--text-xl);
  color: rgba(255,255,255,0.75);
  line-height: 1.7;
  max-width: 640px;
  margin: 0 auto var(--space-2xl);
}

.gpw-hero .btn-group {
  justify-content: center;
  margin-bottom: var(--space-3xl);
}

/* Division cards — floating below text */
.gpw-hero__divisions {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: var(--space-lg);
  max-width: 620px;
  margin: 0 auto;
}

.gpw-hero__div-card {
  padding: var(--space-xl);
  background: rgba(255,255,255,0.06);
  border: 1px solid rgba(255,255,255,0.1);
  border-radius: var(--radius-lg);
  backdrop-filter: blur(12px);
  transition: all 0.3s ease;
  text-align: left;
}

.gpw-hero__div-card:hover {
  background: rgba(255,255,255,0.1);
  border-color: rgba(255,255,255,0.2);
  transform: translateY(-4px);
}

.gpw-hero__div-num {
  font-family: var(--font-accent);
  font-size: 10px;
  text-transform: uppercase;
  letter-spacing: 0.2em;
  margin-bottom: var(--space-xs);
}

.gpw-hero__div-card:first-child .gpw-hero__div-num { color: var(--lime); }
.gpw-hero__div-card:last-child .gpw-hero__div-num { color: var(--coral); }

.gpw-hero__div-title {
  font-size: var(--text-base);
  font-weight: 700;
  color: var(--white);
  margin-bottom: 4px;
}

.gpw-hero__div-desc {
  font-size: var(--text-sm);
  color: rgba(255,255,255,0.5);
  line-height: 1.5;
}

/* Scroll indicator */
.gpw-hero__scroll {
  position: absolute;
  bottom: var(--space-2xl);
  left: 50%;
  transform: translateX(-50%);
  z-index: 2;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: var(--space-xs);
  color: rgba(255,255,255,0.35);
  font-size: 10px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.15em;
  animation: heroScroll 2s ease-in-out infinite;
}

.gpw-hero__scroll svg {
  width: 20px;
  height: 20px;
}

@keyframes heroScroll {
  0%, 100% { opacity: 0.35; transform: translateX(-50%) translateY(0); }
  50% { opacity: 0.7; transform: translateX(-50%) translateY(6px); }
}

/* --- Responsive --- */
@media (max-width: 600px) {
  .gpw-hero__divisions {
    grid-template-columns: 1fr;
    max-width: 340px;
  }

  .gpw-hero__inner {
    padding: var(--space-2xl) var(--space-lg);
  }
}
/* ── Interactive Nearshore Map ── */
.nearshore-map {
  position: relative;
  width: 100%;
  aspect-ratio: 1.2 / 1;
  border-radius: var(--radius-lg);
  overflow: hidden;
  background: #0a1628;
}
.nearshore-map__dots {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  opacity: 0.7;
}
.nearshore-map__overlay {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
}
.nearshore-map__label {
  font-family: 'Lato', sans-serif;
  font-size: 1.4px;
  font-weight: 700;
  fill: var(--white);
  text-anchor: middle;
  pointer-events: none;
  opacity: 0;
  animation: mapLabelLoop 12s ease-in-out infinite;
}
.nearshore-map__label--origin {
  fill: var(--coral);
  font-size: 1.8px;
}
.nearshore-map__path {
  stroke-dasharray: 1000;
  stroke-dashoffset: 1000;
  animation: mapDrawLoop 12s ease-in-out infinite;
}
.nearshore-map__dot-travel {
  opacity: 0;
  animation: mapDotLoop 12s ease-in-out infinite;
}
.nearshore-map__legend {
  display: flex;
  justify-content: center;
  gap: var(--space-xl);
  margin-top: var(--space-md);
  font-size: var(--text-xs);
  color: var(--mid-gray);
}
.nearshore-map__legend span {
  display: flex;
  align-items: center;
  gap: var(--space-xs);
}
.nearshore-map__legend-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  display: inline-block;
}
.nearshore-map__legend-dot--origin { background: var(--coral); }
.nearshore-map__legend-dot--dest { background: var(--lime); }

/* Map loop: 12s total — draw (0-33%), hold (33-60%), fade out (60-70%), pause (70-100%) */
@keyframes mapDrawLoop {
  0%   { stroke-dashoffset: 1000; opacity: 0; }
  5%   { opacity: 1; }
  33%  { stroke-dashoffset: 0; opacity: 1; }
  60%  { stroke-dashoffset: 0; opacity: 1; }
  70%  { opacity: 0; }
  100% { stroke-dashoffset: 1000; opacity: 0; }
}
@keyframes mapLabelLoop {
  0%   { opacity: 0; }
  25%  { opacity: 0; }
  33%  { opacity: 1; }
  60%  { opacity: 1; }
  70%  { opacity: 0; }
  100% { opacity: 0; }
}
@keyframes mapDotLoop {
  0%   { opacity: 0; offset-distance: 0%; }
  5%   { opacity: 1; }
  33%  { opacity: 1; offset-distance: 100%; }
  60%  { opacity: 0; offset-distance: 100%; }
  100% { opacity: 0; offset-distance: 0%; }
}
