/* ============================================
   XGEOSPACE - Layout Styles
   ============================================ */

/* ========== Navigation (NASA/SpaceX Style with Dropdowns) ========== */
.navbar {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 80px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 6rem;
  z-index: 2000;
  background: transparent;
  transition: all 0.4s ease;
  border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}

/* Navbar Scrolled State */
.navbar.scrolled {
  background: rgba(0, 0, 0, 0.95);
  height: 70px;
  backdrop-filter: blur(20px);
  border-bottom-color: rgba(255, 255, 255, 0.1);
}

/* Hero Section */
.hero {
  height: 100vh;
  width: 100%;
  position: relative;
  display: flex;
  align-items: center;
  padding: 0 6rem;
  overflow: hidden;
  background: #000;
}

/* Logo Styles */
.nav-logo {
  display: flex;
  align-items: center;
  gap: 1.2rem;
  z-index: 1001;
  text-decoration: none;
}

.nav-logo img {
  height: 50px;
  width: 50px;
  object-fit: cover;
  border-radius: 50%;
  transition: all 0.5s cubic-bezier(0.175, 0.885, 0.32, 1.275);
  border: 1px solid rgba(255, 255, 255, 0.2);
}

.nav-logo:hover img {
  transform: rotate(360deg) scale(1.1);
  border-color: #fc3d21;
}

.brand-info {
  display: flex;
  flex-direction: column;
  line-height: 1.2;
}

.brand-name {
  font-family: "Orbitron", sans-serif;
  font-size: 1.4rem;
  font-weight: 800;
  color: white;
  letter-spacing: 2px;
  text-transform: uppercase;
}

.brand-tagline {
  font-family: 'JetBrains Mono', monospace;
  font-size: 0.6rem;
  color: #aaa;
  letter-spacing: 1px;
  text-transform: uppercase;
}

.nav-menu {
  display: flex;
  gap: 2.5rem;
  height: 100%;
  align-items: center;
}

/* Link Style */
.nav-item {
  height: 100%;
  display: flex;
  align-items: center;
}

.nav-link {
  color: rgba(255, 255, 255, 0.8);
  font-family: "Inter", sans-serif;
  font-weight: 600;
  font-size: 0.85rem;
  text-transform: uppercase;
  letter-spacing: 1px;
  cursor: pointer;
  padding: 8px 12px;
  display: flex;
  align-items: center;
  gap: 8px;
  transition: all 0.3s ease;
  text-decoration: none;
}

.nav-link:hover, .nav-item:hover .nav-link {
  color: white;
}

.nav-link i {
  font-size: 12px;
  transition: transform 0.3s ease;
}

.nav-item:hover .nav-link i {
  transform: rotate(180deg);
  color: #fc3d21;
}

/* Mega-Menu Container */
.dropdown-menu {
  position: absolute;
  top: 80px;
  left: 0;
  right: 0;
  width: 100vw;
  background: rgba(8, 8, 8, 0.95); /* Deep dark background */
  backdrop-filter: blur(25px);
  -webkit-backdrop-filter: blur(25px);
  border-bottom: 1px solid rgba(255, 255, 255, 0.05);
  border-top: 2px solid #fc3d21; /* Red brand top border */
  box-shadow: 0 15px 35px rgba(0, 0, 0, 0.8); /* Dark shadow */
  padding: 40px 15%;
  opacity: 0;
  visibility: hidden;
  transform: translateY(10px);
  transition: all 0.3s ease;
  z-index: 5000;
  display: flex;
  justify-content: flex-start; /* Left aligned */
  gap: 80px;
  box-sizing: border-box;
}

.navbar.scrolled .dropdown-menu {
  top: 70px;
}

.nav-item:hover .dropdown-menu {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}

/* Column styles */
.mega-column {
  display: flex;
  flex-direction: column;
  gap: 20px; /* More spacing between items */
  border-right: none; /* No vertical borders */
  padding-right: 0;
  min-width: 280px;
  max-width: 350px;
}

.mega-column:last-child {
  border-right: none;
  padding-right: 0;
}

.mega-title {
  font-family: "Inter", sans-serif; /* Clean sans-serif */
  font-size: 0.82rem;
  color: #fc3d21; /* Red brand color */
  font-weight: 700;
  letter-spacing: 0.8px;
  text-transform: uppercase;
  margin-bottom: 12px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08); /* Subtle grey line */
  padding-bottom: 12px;
  text-shadow: none;
  margin-left: 0;
}

.mega-item {
  text-decoration: none;
  display: flex;
  flex-direction: column;
  gap: 2px; /* Tighter gap */
  transition: all 0.2s ease;
  padding: 8px 0; /* Slight padding */
  border-radius: 0;
  border: none;
  background: transparent;
}

.mega-item:hover {
  background: transparent;
  border-color: transparent;
  transform: none; /* No sliding animation */
}

.mega-item-title {
  color: #ffffff; /* White text */
  font-weight: 600;
  font-size: 0.9375rem; /* 15px */
  font-family: "Inter", sans-serif;
  letter-spacing: -0.2px;
  transition: color 0.2s;
}

.mega-item-desc {
  color: rgba(255, 255, 255, 0.6); /* Light corporate grey desc */
  font-size: 0.85rem;
  line-height: 1.45;
  font-family: "Inter", sans-serif;
  font-weight: 400;
}

.mega-item:hover .mega-item-title {
  color: #fc3d21; /* Red brand hover */
}

/* Highlights */
.nav-link-highlight {
  border: 1px solid #fc3d21 !important;
  border-radius: 6px;
  padding: 10px 20px !important;
  color: #fc3d21 !important;
  font-weight: 800 !important;
  display: flex;
  align-items: center;
}

.nav-link-highlight:hover {
  background: #fc3d21;
  color: white !important;
}

/* Mobile Toggle */
.nav-toggle {
  display: none;
  flex-direction: column;
  gap: 5px;
  background: none;
  border: 1px solid rgba(255, 255, 255, 0.15);
  cursor: pointer;
  z-index: 2100;
  position: relative;
  padding: 10px;
  pointer-events: all;
  border-radius: 4px;
}

.nav-toggle span {
  width: 22px;
  height: 2px;
  background: white;
  display: block;
  border-radius: 2px;
  transition: transform 0.35s ease, opacity 0.35s ease;
  transform-origin: center;
}

/* Hamburger to X morph */
.nav-toggle.active span:nth-child(1) {
  transform: translateY(7px) rotate(45deg);
}
.nav-toggle.active span:nth-child(2) {
  opacity: 0;
  transform: scaleX(0);
}
.nav-toggle.active span:nth-child(3) {
  transform: translateY(-7px) rotate(-45deg);
}

/* ========== Hero Section (Slider Style) ========== */
.hero {
  height: 100vh;
  width: 100%;
  position: relative;
  display: flex;
  align-items: center;
  padding: 0 4rem;
  overflow: hidden;
  background: #000;
}

.hero-slider {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: 0;
}

/* Cada Slide Individual */
.hero-slide {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-size: cover;
  background-position: center;
  opacity: 0;
  transform: scale(1);
  transition:
    opacity 1.5s ease-in-out,
    transform 8s linear;
}

/* Estado Activo (Visible) */
.hero-slide.active {
  opacity: 1;
  transform: scale(1.1);
}

/* Controles del Slider */
.slider-controls {
  position: absolute;
  bottom: 40px;
  right: 4rem;
  display: flex;
  gap: 1rem;
  z-index: 10;
  pointer-events: none;
}

.slider-arrow {
  width: 60px;
  height: 60px;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.1);
  color: white;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  pointer-events: all;
  transition: all 0.4s cubic-bezier(0.165, 0.84, 0.44, 1);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  outline: none;
  padding: 0;
}

.slider-arrow i {
  width: 24px;
  height: 24px;
  transition: transform 0.3s ease;
}

.slider-arrow:hover {
  background: #fc3d21;
  border-color: #fc3d21;
  box-shadow: 0 0 25px rgba(252, 61, 33, 0.4);
}

.slider-arrow:hover i {
  transform: scale(1.2);
}

.slider-arrow:active {
  transform: scale(0.9);
}

@media (max-width: 768px) {
  .slider-controls {
    right: 20px;
    bottom: 20px;
    gap: 0.5rem;
  }
  .slider-arrow {
    width: 45px;
    height: 45px;
  }
}

/* Overlay Oscuro */
.hero-overlay {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: linear-gradient(
    to right,
    rgba(0, 0, 0, 0.8) 0%,
    rgba(0, 0, 0, 0.4) 50%,
    rgba(0, 0, 0, 0.1) 100%
  );
  z-index: 1;
}

.hero-content {
  position: relative;
  z-index: 2;
  max-width: 900px;
  margin-top: 80px;
}

.hero-title {
  font-size: clamp(3rem, 7vw, 6rem);
  font-weight: 900;
  line-height: 1;
  margin-bottom: 1.5rem;
  text-transform: uppercase;
}

.hero-subtitle {
  font-size: 1.3rem;
  color: #ccc;
  max-width: 600px;
  margin-bottom: 2.5rem;
  font-weight: 300;
}

/* ========== Footer ========== */
.footer {
  background: #000000;
  color: #cccccc;
  padding: 60px 0 30px;
  font-family: "Inter", sans-serif;
  font-size: 0.95rem;
  border-top: 1px solid #222;
}

.footer-top {
  display: flex;
  flex-wrap: wrap;
  gap: 40px;
  margin-bottom: 50px;
  justify-content: space-between;
}

.footer-brand-section {
  flex: 2;
  min-width: 300px;
  max-width: 400px;
}

.footer-logo-img {
  width: 60px;
  margin-bottom: 15px;
  display: block;
}

.footer-brand-title {
  font-size: 1.5rem;
  font-weight: 700;
  color: white;
  line-height: 1.2;
  margin-bottom: 15px;
  font-family: "Inter", sans-serif;
}

.footer-mission-text {
  line-height: 1.6;
  margin-bottom: 20px;
  color: #aaa;
}

.footer-links-section {
  flex: 3;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
  gap: 20px;
  min-width: 300px;
}

.footer-link-col {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.footer-link-item {
  color: white;
  text-decoration: none;
  font-weight: 500;
  transition: color 0.2s;
}

.footer-link-item:hover {
  color: #fc3d21;
}

.footer-social-section {
  flex: 1;
  min-width: 200px;
}

.footer-social-icons {
  display: flex;
  gap: 10px;
  margin-bottom: 20px;
}

.footer-social-icon {
  width: 54px;
  height: 84px;
  background: rgba(25, 25, 25, 0.9);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 50% / 30%; /* Creates the vertical ovoid shape */
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
  text-decoration: none;
  position: relative;
  overflow: hidden;
}

.footer-social-icon:hover {
  transform: translateY(-8px) scale(1.05);
  border-color: rgba(255, 255, 255, 0.4);
  background: rgba(40, 40, 40, 1);
  box-shadow: 0 15px 30px rgba(0, 0, 0, 0.5);
}

/* Individual Icon Colors (as seen in the reference image) */
.footer-social-icon[aria-label="Facebook"] { color: #1877f2; }
.footer-social-icon[aria-label="Instagram"] { color: #fe2c55; }
.footer-social-icon[aria-label="LinkedIn"] { color: #0077b5; }
.footer-social-icon[aria-label="TikTok"] { color: #ff0050; }
.footer-social-icon[aria-label="WhatsApp"] { color: #25d366; }
.footer-social-icon[aria-label="Email"] { color: #fc3d21; }

.footer-social-icon svg {
  width: 24px;
  height: 24px;
  transition: transform 0.3s ease;
}

.footer-social-icon:hover svg {
  transform: scale(1.2);
}

.footer-social-icon[aria-label="Facebook"] svg,
.footer-social-icon[aria-label="LinkedIn"] svg {
  /* Some icons in the image are filled circles/squares */
  filter: drop-shadow(0 0 2px rgba(255, 255, 255, 0.1));
}

/* Individual Brand Colors on Hover with Glow */
.footer-social-icon[aria-label="Facebook"]:hover {
  background: #1877f2;
  box-shadow: 0 0 25px rgba(24, 119, 242, 0.6);
}

.footer-social-icon[aria-label="LinkedIn"]:hover {
  background: #0077b5;
  box-shadow: 0 0 25px rgba(0, 119, 181, 0.6), 0 0 10px rgba(255, 255, 255, 0.3);
}

.footer-social-icon[aria-label="X"]:hover {
  background: #000;
  box-shadow: 0 0 25px rgba(255, 255, 255, 0.3), 0 0 10px rgba(255, 255, 255, 0.1);
}

.footer-social-icon[aria-label="TikTok"]:hover {
  background: #000;
  box-shadow: 0 0 20px rgba(255, 0, 80, 0.7), 0 0 20px rgba(37, 244, 238, 0.7);
}

.footer-social-icon[aria-label="WhatsApp"]:hover {
  background: #25d366;
  box-shadow: 0 0 25px rgba(37, 211, 102, 0.6), 0 0 10px rgba(255, 255, 255, 0.3);
}

.footer-social-icon[aria-label="Email"]:hover {
  background: #fc3d21;
  box-shadow: 0 0 25px rgba(252, 61, 33, 0.6), 0 0 10px rgba(255, 255, 255, 0.3);
}

.footer-social-icon[aria-label="Instagram"]:hover {
  background: linear-gradient(45deg, #f09433, #e6683c, #dc2743, #cc2366, #bc1888);
  box-shadow: 0 0 25px rgba(220, 39, 67, 0.6), 0 0 10px rgba(255, 255, 255, 0.3);
  border-color: transparent;
}

/* Support Section Styles (Placeholder if needed) */
.footer-link-col .footer-title-nexus {
  font-family: "Orbitron", sans-serif;
  letter-spacing: 2px;
}

.footer-legal-bar {
  border-top: 1px solid #333;
  padding-top: 25px;
  display: flex;
  flex-wrap: wrap;
  gap: 20px;
  font-size: 0.85rem;
  margin-bottom: 25px;
}

.footer-legal-link {
  color: #ccc;
  text-decoration: none;
  transition: color 0.2s;
}

.footer-legal-link:hover {
  color: white;
}

@media (max-width: 1200px) {
  .navbar {
    padding: 0 4rem;
  }
  .dropdown-menu {
    padding: 40px 8%;
    gap: 40px;
  }
}

@media (max-width: 1024px) {
  .navbar {
    padding: 0 2rem;
  }
  .nav-menu {
    gap: 1.5rem;
  }
  .dropdown-menu {
    padding: 30px 5%;
    gap: 30px;
  }
  .mega-column {
    min-width: 200px;
  }
}

@media (max-width: 768px) {
  .navbar {
    padding: 0 20px;
    height: 70px;
    background: rgba(0, 0, 0, 0.95);
  }

  .nav-logo img {
    height: 40px;
    width: 40px;
  }

  .brand-name {
    font-size: 1.1rem;
  }

  .nav-menu {
    position: fixed;
    top: 70px; /* Fixed height for navbar */
    left: 0;
    width: 100%;
    height: calc(100vh - 70px);
    background: #000;
    flex-direction: column;
    justify-content: flex-start;
    padding: 2rem 1.5rem;
    transform: translateX(100%);
    transition: transform 0.4s cubic-bezier(0.165, 0.84, 0.44, 1);
    z-index: 1999;
    overflow-y: auto;
    gap: 1rem;
  }

  .nav-menu.active {
    transform: translateX(0);
  }

  .nav-item {
    width: 100%;
    height: auto;
    flex-direction: column;
    align-items: flex-start;
  }

  .nav-link {
    width: 100%;
    padding: 15px 0;
    font-size: 1.1rem;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
    justify-content: space-between;
  }

  .dropdown-menu {
    position: static;
    width: 100%;
    height: 0;
    padding: 0;
    opacity: 0;
    visibility: hidden;
    display: none; /* Hide on mobile by default */
    transform: none;
    background: transparent;
    border: none;
    box-shadow: none;
    flex-direction: column;
    gap: 20px;
    transition: none;
  }

  .nav-item:hover .dropdown-menu {
    height: auto;
    opacity: 1;
    visibility: visible;
    display: flex;
    padding: 10px 0 20px 20px;
  }

  .mega-column {
    min-width: 100%;
    max-width: 100%;
    gap: 10px;
  }

  .mega-title {
    font-size: 0.75rem;
    margin-bottom: 8px;
    padding-bottom: 8px;
  }

  .mega-item-desc {
    display: none; /* Hide descriptions on mobile to save space */
  }

  .nav-toggle {
    display: flex;
  }

  .hero-title {
    font-size: clamp(2.5rem, 10vw, 4rem) !important;
  }

  .hero {
    padding: 0 20px;
    text-align: center;
    justify-content: center;
  }

  .hero-content {
    margin-top: 40px;
    padding: 0;
  }

  .footer-top {
    flex-direction: column;
    gap: 30px;
  }

  .footer-brand-section, .footer-links-section, .footer-social-section {
    flex: 1;
    max-width: 100%;
  }
  
  .footer-links-section {
    grid-template-columns: 1fr 1fr;
  }
}

@media (max-width: 480px) {
  .hero-title {
    font-size: 2.2rem !important;
  }
  
  .footer-links-section {
    grid-template-columns: 1fr;
  }
}

/* Service Slider Custom Buttons */
.svc-slider-btn {
  width: 65px;
  height: 45px;
  background: rgba(255, 255, 255, 0.02);
  border: 1px solid rgba(255, 255, 255, 0.1);
  color: white;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  position: relative;
  overflow: hidden;
  transition: all 0.4s cubic-bezier(0.165, 0.84, 0.44, 1);
  clip-path: polygon(10% 0, 100% 0, 90% 100%, 0 100%);
}

.svc-slider-btn:hover {
  background: rgba(255, 255, 255, 0.08);
  border-color: rgba(255, 255, 255, 0.3);
  box-shadow: 0 0 20px rgba(255, 255, 255, 0.1);
  transform: translateY(-2px);
}

.svc-slider-btn i {
  width: 20px;
  height: 20px;
  z-index: 2;
}

.btn-scan-line {
  position: absolute;
  top: 0;
  left: -100%;
  width: 100%;
  height: 100%;
  background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.1), transparent);
  transition: left 0.5s;
}

.svc-slider-btn:hover .btn-scan-line {
  left: 100%;
  transition: left 0.8s ease-in-out;
}

@media (max-width: 768px) {
  .svc-card-premium {
    flex: 0 0 280px !important;
  }
}

@media (max-width: 480px) {
  .svc-card-premium {
    flex: 0 0 85vw !important;
  }
}