/* ==========================================================================
   SONAR RADAR & GEOSPATIAL HUD STYLES
   Specialized frame and animations for Hamza El-Sayed Hekal's Hero Photo
   ========================================================================== */

.hero-sonar-frame {
  position: relative;
  width: 380px;
  height: 480px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: center;
}

@media (max-width: 480px) {
  .hero-sonar-frame {
    width: 300px;
    height: 390px;
  }
}

/* Photo Mask & Container */
.photo-wrap {
  position: relative;
  width: 82%;
  height: 84%;
  border-radius: 20px;
  overflow: hidden;
  box-shadow: 
    0 0 35px rgba(0, 242, 254, 0.25),
    0 0 70px rgba(0, 223, 162, 0.1),
    inset 0 0 20px rgba(7, 21, 41, 0.8);
  border: 2px solid rgba(0, 242, 254, 0.4);
  z-index: 2;
  background: #071529;
}

.photo-wrap img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center 20%;
  filter: contrast(1.05) brightness(1.02) saturate(1.05);
  transition: transform 0.6s cubic-bezier(0.16, 1, 0.3, 1), filter 0.6s ease;
}

.hero-sonar-frame:hover .photo-wrap img {
  transform: scale(1.04);
}

/* Subtle Sonar Grid Overlay over Photo */
.photo-wrap::after {
  content: '';
  position: absolute;
  inset: 0;
  background: 
    radial-gradient(circle at center, transparent 40%, rgba(7, 21, 41, 0.6) 90%),
    linear-gradient(rgba(0, 242, 254, 0.03) 1px, transparent 1px),
    linear-gradient(90deg, rgba(0, 242, 254, 0.03) 1px, transparent 1px);
  background-size: 100% 100%, 20px 20px, 20px 20px;
  pointer-events: none;
}

/* Sweeping Radar Beam over Photo */
.radar-sweep-beam {
  position: absolute;
  inset: -20%;
  background: conic-gradient(
    from 0deg at 50% 50%,
    transparent 0deg,
    rgba(0, 242, 254, 0.15) 30deg,
    rgba(0, 242, 254, 0.35) 60deg,
    transparent 61deg
  );
  animation: radarSpin 8s linear infinite;
  pointer-events: none;
  z-index: 3;
  border-radius: 50%;
  mix-blend-mode: screen;
}

@keyframes radarSpin {
  from { transform: rotate(0deg); }
  to { transform: rotate(360deg); }
}

/* HUD Rotating Azimuth Ring */
.hud-azimuth-ring {
  position: absolute;
  inset: -15px;
  border-radius: 28px;
  border: 1px dashed rgba(0, 242, 254, 0.35);
  pointer-events: none;
  z-index: 4;
}

.hud-azimuth-ring::before {
  content: '';
  position: absolute;
  inset: -8px;
  border-radius: 32px;
  border: 1px stroke rgba(245, 175, 25, 0.3);
  border-top-color: #f5af19;
  border-bottom-color: #00dfa2;
  animation: counterSpin 20s linear infinite;
}

@keyframes counterSpin {
  from { transform: rotate(360deg); }
  to { transform: rotate(0deg); }
}

/* Corner Target Reticles */
.corner-target {
  position: absolute;
  width: 18px;
  height: 18px;
  border-color: #00f2fe;
  border-style: solid;
  z-index: 5;
  pointer-events: none;
}

.corner-target.top-left {
  top: 5px;
  left: 5px;
  border-width: 2px 0 0 2px;
}
.corner-target.top-right {
  top: 5px;
  right: 5px;
  border-width: 2px 2px 0 0;
}
.corner-target.bottom-left {
  bottom: 5px;
  left: 5px;
  border-width: 0 0 2px 2px;
}
.corner-target.bottom-right {
  bottom: 5px;
  right: 5px;
  border-width: 0 2px 2px 0;
}

/* Telemetry Badges Floating on Frame */
.hud-telemetry-badge {
  position: absolute;
  padding: 6px 12px;
  background: rgba(7, 21, 41, 0.85);
  backdrop-filter: blur(8px);
  border: 1px solid rgba(0, 242, 254, 0.3);
  border-radius: 30px;
  color: #00f2fe;
  font-family: 'JetBrains Mono', monospace;
  font-size: 0.72rem;
  display: flex;
  align-items: center;
  gap: 8px;
  z-index: 6;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.3);

}

.hud-telemetry-badge.badge-top {
  top: -16px;
  left: 50%;
  transform: translateX(-50%);
}

.hud-telemetry-badge.badge-bottom {
  bottom: -16px;
  left: 50%;
  transform: translateX(-50%);
  border-color: rgba(245, 175, 25, 0.5);
  color: #f5af19;
}

.hud-status-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: #00dfa2;
  box-shadow: 0 0 8px #00dfa2;
  animation: pulseDot 2s infinite;
}

@keyframes pulseDot {
  0%, 100% { opacity: 1; transform: scale(1); }
  50% { opacity: 0.4; transform: scale(0.8); }
}

/* Pulsing Echo Wave Rings */
.sonar-echo-ring {
  position: absolute;
  width: 100%;
  height: 100%;
  border-radius: 26px;
  border: 1px solid rgba(0, 242, 254, 0.4);
  animation: echoExpand 4s cubic-bezier(0.1, 0.8, 0.3, 1) infinite;
  pointer-events: none;
  z-index: 1;
}

.sonar-echo-ring:nth-child(2) {
  animation-delay: 1.3s;
}

.sonar-echo-ring:nth-child(3) {
  animation-delay: 2.6s;
}

@keyframes echoExpand {
  0% {
    transform: scale(0.9);
    opacity: 0.8;
  }
  100% {
    transform: scale(1.35);
    opacity: 0;
  }
}
