/* ============================================================
   global-presence.css — CorosDev interactive hero globe
   Lives inside the hero's right column, replacing the static map.
   Scoped to .gp-* / #gp-* selectors only — does not touch global rules.
   ============================================================ */

/* Perfectly circular, softly-fading ambient glow behind the globe.
   Sized/blurred so it never shows a straight edge — replaces the old
   rectangular box-shadow-style glow that made the globe look "boxed". */
.gp-ambient-glow {
  position: absolute;
  inset: 6%;
  border-radius: 50%;
  background: radial-gradient(circle at 50% 50%, rgba(31, 127, 255, 0.35), rgba(31, 127, 255, 0.1) 45%, transparent 72%);
  filter: blur(40px);
  pointer-events: none;
  z-index: 0;
}

.gp-globe-wrap {
  position: relative;
  width: 100%;
  height: 100%;
  overflow: visible;
}

/* Intentionally oversized relative to its visual "stage" (112% with a
   matching negative inset) so the render surface has safe margin — the
   planet and its atmosphere shell are never trimmed right at the frame
   edge, even mid-zoom. Ancestors stay overflow:visible so this excess
   canvas area is never hard-clipped. */
.gp-globe-canvas {
  position: absolute;
  inset: -6%;
  width: 112%;
  height: 112%;
  overflow: visible;
}

.gp-globe-canvas canvas {
  outline: none;
  background: transparent;
}

.gp-fallback-note {
  position: absolute;
  left: 50%;
  bottom: 3.25rem;
  transform: translateX(-50%);
  font-size: 0.66rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  text-align: center;
  color: rgba(255, 255, 255, 0.5);
  background: rgba(7, 11, 26, 0.75);
  padding: 0.45rem 0.9rem;
  border-radius: 1rem;
  border: 1px solid rgba(255, 255, 255, 0.08);
  white-space: normal;
  width: max-content;
  max-width: 82%;
  z-index: 15;
}

/* ── Markers: restrained glow, no neon ── */
.gp-marker {
  position: relative;
  width: 16px;
  height: 16px;
  border: none;
  background: transparent;
  padding: 0;
  cursor: pointer;
  transform: translate(-50%, -50%);
}

.gp-marker-dot {
  position: absolute;
  inset: 5px;
  border-radius: 999px;
  background: #7DBBFF;
  box-shadow: 0 0 6px 1px rgba(31, 127, 255, 0.55);
  transition: background 0.35s ease, box-shadow 0.35s ease, transform 0.35s ease, opacity 0.35s ease;
}

.gp-marker-pulse {
  position: absolute;
  inset: 0;
  border-radius: 999px;
  border: 1.25px solid rgba(125, 187, 255, 0.5);
  animation: gp-pulse 2.8s ease-out infinite;
  transition: opacity 0.35s ease;
}

@keyframes gp-pulse {
  0% { transform: scale(0.5); opacity: 0.75; }
  100% { transform: scale(1.5); opacity: 0; }
}

.gp-marker.is-selected .gp-marker-dot {
  background: #ffffff;
  box-shadow: 0 0 10px 2px rgba(255, 255, 255, 0.65), 0 0 18px 4px rgba(31, 127, 255, 0.45);
  transform: scale(1.25);
}

.gp-marker.is-selected .gp-marker-pulse {
  border-color: rgba(255, 255, 255, 0.7);
  animation-duration: 1.9s;
}

.gp-marker.is-dimmed { opacity: 0.32; }
.gp-marker.is-dimmed .gp-marker-pulse { animation-play-state: paused; opacity: 0; }

/* ── Subtle overhead label (reuses existing hero_map copy) ── */
.gp-hero-label {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  text-align: center;
  z-index: 12;
  pointer-events: none;
}

/* ── Location chips: floating on desktop, inline scroll row on mobile ── */
.gp-selector {
  display: flex;
  min-width: 0;
  max-width: 100%;
  gap: 0.5rem;
  overflow-x: auto;
  padding: 0.25rem 0.1rem;
  margin-top: 1rem;
  scrollbar-width: none;
  justify-content: center;
}

.gp-selector::-webkit-scrollbar { display: none; }

.gp-selector-btn {
  flex: 0 0 auto;
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  padding: 0.5rem 0.85rem;
  border-radius: 999px;
  border: 1px solid rgba(255, 255, 255, 0.14);
  background: rgba(7, 11, 26, 0.55);
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
  color: rgba(255, 255, 255, 0.65);
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  white-space: nowrap;
  cursor: pointer;
  transition: border-color 0.25s, color 0.25s, background 0.25s;
  min-height: 40px;
}

.gp-selector-btn:hover {
  border-color: rgba(31, 127, 255, 0.5);
  color: #7DBBFF;
}

.gp-selector-btn:focus-visible {
  outline: 2px solid #1F7FFF;
  outline-offset: 2px;
}

.gp-selector-btn[aria-pressed="true"] {
  border-color: #1F7FFF;
  background: rgba(31, 127, 255, 0.18);
  color: #ffffff;
}

.gp-selector-flag {
  font-size: 0.95rem;
  line-height: 1;
}

@media (min-width: 768px) {
  .gp-selector {
    position: absolute;
    left: 50%;
    bottom: 2%;
    transform: translateX(-50%);
    margin-top: 0;
    z-index: 20;
  }
}

/* ── Floating office card ── */
.gp-card {
  position: relative;
  margin-top: 1rem;
  width: 100%;
  background: rgba(11, 18, 38, 0.72);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 1.25rem;
  box-shadow: 0 20px 50px rgba(0, 0, 0, 0.4);
  overflow: hidden;
  opacity: 0;
  transform: translateY(14px) scale(0.98);
  transition: opacity 0.55s cubic-bezier(0.16, 1, 0.3, 1), transform 0.55s cubic-bezier(0.16, 1, 0.3, 1);
}

.gp-card.gp-card--visible {
  opacity: 1;
  transform: translateY(0) scale(1);
}

.gp-card[hidden] { display: none; }

@media (min-width: 768px) {
  .gp-card {
    position: absolute;
    top: 13%;
    right: 0;
    margin-top: 0;
    width: min(280px, 74%);
    z-index: 25;
  }
}

.gp-card-close {
  position: absolute;
  top: 0.7rem;
  right: 0.7rem;
  width: 30px;
  height: 30px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  border: 1px solid rgba(255, 255, 255, 0.2);
  background: rgba(7, 11, 26, 0.55);
  backdrop-filter: blur(4px);
  color: rgba(255, 255, 255, 0.8);
  cursor: pointer;
  transition: color 0.2s, border-color 0.2s;
  z-index: 2;
}

.gp-card-close:hover { color: #7DBBFF; border-color: rgba(31, 127, 255, 0.5); }
.gp-card-close:focus-visible { outline: 2px solid #1F7FFF; outline-offset: 2px; }

.gp-card-banner {
  position: relative;
  width: 100%;
  aspect-ratio: 16 / 8;
  overflow: hidden;
  background: #0B1226;
}

.gp-card-banner img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
  display: block;
}

/* If the banner photo fails to load, hide the broken-image icon and let
   the .gp-card-banner dark background (#0B1226) show through instead. */
.gp-card-banner img.gp-card-banner-img--error {
  display: none;
}

.gp-card-banner-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(7, 11, 26, 0.05) 0%, rgba(7, 11, 26, 0.55) 65%, rgba(11, 18, 38, 0.95) 100%);
}

.gp-card-flag-badge {
  position: absolute;
  left: 0.9rem;
  bottom: -0.55rem;
  font-size: 1.15rem;
  line-height: 1;
  width: 34px;
  height: 34px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  background: rgba(11, 18, 38, 0.9);
  border: 1px solid rgba(255, 255, 255, 0.15);
  box-shadow: 0 6px 16px rgba(0, 0, 0, 0.4);
}

.gp-card-body {
  padding: 1.25rem 1.1rem 1.1rem;
}

.gp-card-type {
  font-size: 0.62rem;
  font-weight: 700;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: #7DBBFF;
  opacity: 0.9;
  margin-bottom: 0.3rem;
}

.gp-card-title {
  font-size: 1.05rem;
  font-weight: 800;
  color: #ffffff;
  line-height: 1.3;
  margin-bottom: 0.25rem;
}

.gp-card-info {
  display: flex;
  flex-direction: column;
  gap: 0.55rem;
  margin-top: 0.7rem;
}

.gp-card-info-row {
  display: flex;
  align-items: flex-start;
  gap: 0.5rem;
  font-size: 0.76rem;
  line-height: 1.5;
  color: rgba(255, 255, 255, 0.72);
}

.gp-card-info-icon {
  flex-shrink: 0;
  width: 15px;
  height: 15px;
  margin-top: 0.15rem;
  color: #7DBBFF;
  opacity: 0.85;
}

/* ── Mobile adjustments ── */
@media (max-width: 767px) {
  #hero-globe-stage { max-width: 380px; }
}

/* ── Reduced motion ── */
@media (prefers-reduced-motion: reduce) {
  .gp-marker-pulse { animation: none; }
  .gp-card { transition: opacity 0.2s linear; transform: none !important; }
  .gp-selector-btn { transition: none; }
}
