/* ========================================================================== */
/* 0. VARIABLES Y CONFIGURACIÓN GLOBAL                                       */
/* ========================================================================== */
:root {
  --c-navy-deep: #081622;
  --c-navy: #0C2438;
  --c-navy-light: #13334c;
  
  --c-card-surface: rgba(17, 43, 66, 0.88);
  --c-card-border: rgba(216, 137, 79, 0.18);
  --c-card-border-hover: rgba(216, 137, 79, 0.45);

  --c-terracotta: #D8894F;
  --c-terracotta-soft: rgba(216, 137, 79, 0.85);
  --c-terracotta-dim: rgba(216, 137, 79, 0.12);
  --c-terracotta-glow: rgba(216, 137, 79, 0.25);

  --c-sand: #F7F5F0;
  --c-sand-muted: rgba(247, 245, 240, 0.72);
  --c-sand-faint: rgba(247, 245, 240, 0.08);

  --f-head: 'Playfair Display', Georgia, serif;
  --f-body: 'Plus Jakarta Sans', sans-serif;
  --transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);

  /* Alturas de referencia para cálculo dinámico */
  --topbar-height: 60px;
  --navbar-height: 52px;
}

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  height: 100%;
}

body {
  font-family: var(--f-body);
  background-color: var(--c-navy);
  color: var(--c-sand);
  line-height: 1.6;
  overflow-x: hidden;
  min-height: 100%;
}

a {
  text-decoration: none;
  color: inherit;
  transition: var(--transition);
}

img {
  max-width: 100%;
  display: block;
}

.svg-icon {
  width: 18px;
  height: 18px;
  display: inline-block;
  vertical-align: middle;
}

/* ========================================================================== */
/* 1. TOP BAR                                                                 */
/* ========================================================================== */
.top-bar {
  position: relative;
  z-index: 100;
  background: rgba(12, 36, 56, 0.171);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid rgba(247, 245, 240, 0.08);
  width: 100%;
}

.top-bar-inner {
  max-width: 1280px;
  margin: 0 auto;
  padding: 0.8rem 1.5rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1.5rem;
}

.top-brand {
  display: flex;
  align-items: center;
  gap: 0.85rem;
}

.brand-logo-img {
  height: 40px;
  width: auto;
  object-fit: contain;
}

.brand-titles {
  display: flex;
  flex-direction: column;
}

.brand-name {
  font-family: var(--f-head);
  font-size: 1.35rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  color: var(--c-sand);
  line-height: 1.1;
}

.brand-subtitle {
  font-size: 0.68rem;
  text-transform: uppercase;
  letter-spacing: 0.22em;
  color: var(--c-terracotta-soft);
  font-weight: 600;
}

.top-actions {
  display: flex;
  align-items: center;
  gap: 1.25rem;
}

.top-email {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.85rem;
  color: var(--c-sand-muted);
  padding: 0.45rem 0.9rem;
  border-radius: 999px;
  background: var(--c-sand-faint);
  border: 1px solid rgba(247, 245, 240, 0.12);
}

.top-email:hover {
  border-color: var(--c-terracotta-soft);
  color: var(--c-sand);
  background: var(--c-terracotta-dim);
}

.top-socials {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.social-circle {
  width: 35px;
  height: 35px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--c-sand-faint);
  border: 1px solid rgba(247, 245, 240, 0.14);
  color: var(--c-sand-muted);
}

.social-circle:hover {
  background: var(--c-terracotta-soft);
  border-color: var(--c-terracotta-soft);
  color: var(--c-navy-deep);
  transform: translateY(-2px);
}

.btn-whatsapp {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  background: rgba(37, 211, 102, 0.9);
  color: #FFFFFF;
  font-weight: 600;
  font-size: 0.85rem;
  padding: 0.48rem 1.1rem;
  border-radius: 999px;
  box-shadow: 0 4px 14px rgba(37, 211, 102, 0.2);
}

.btn-whatsapp:hover {
  background: #25D366;
  color: #FFFFFF;
  transform: translateY(-2px);
  box-shadow: 0 6px 18px rgba(37, 211, 102, 0.35);
}

.wa-svg {
  width: 17px;
  height: 17px;
}

/* ========================================================================== */
/* 2. BARRA DE NAVEGACIÓN Y MENÚ MÓVIL                                        */
/* ========================================================================== */
.main-navbar {
  position: sticky;
  top: 0;
  z-index: 95;
  background: rgba(8, 22, 34, 0.94);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border-bottom: 1px solid rgba(216, 137, 79, 0.2);
}

.nav-inner {
  max-width: 1280px;
  margin: 0 auto;
  padding: 0 1.5rem;
}

.mobile-nav-header {
  display: none;
  justify-content: space-between;
  align-items: center;
  padding: 0.85rem 0;
}

.mobile-menu-label {
  font-size: 0.85rem;
  text-transform: uppercase;
  letter-spacing: 0.15em;
  color: var(--c-terracotta-soft);
  font-weight: 600;
}

.nav-toggle {
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  width: 26px;
  height: 19px;
  background: transparent;
  border: none;
  cursor: pointer;
  padding: 0;
}

.nav-toggle span {
  width: 100%;
  height: 2px;
  background-color: var(--c-sand);
  border-radius: 2px;
  transition: var(--transition);
}

.nav-toggle.active span:nth-child(1) {
  transform: translateY(8.5px) rotate(45deg);
}

.nav-toggle.active span:nth-child(2) {
  opacity: 0;
}

.nav-toggle.active span:nth-child(3) {
  transform: translateY(-8.5px) rotate(-45deg);
}

.nav-links {
  display: flex;
  list-style: none;
  align-items: center;
  gap: 0.5rem;
}

.nav-item {
  display: flex;
  align-items: center;
  gap: 0.35rem;
  padding: 1rem 1rem;
  font-size: 0.88rem;
  font-weight: 600;
  color: var(--c-sand-muted);
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.nav-item:hover,
.nav-item.active {
  color: var(--c-terracotta);
}

.dropdown-arrow {
  width: 13px;
  height: 13px;
  transition: transform 0.3s ease;
  stroke: currentColor;
}

.nav-dropdown {
  position: relative;
}

.nav-dropdown:hover .dropdown-arrow {
  transform: rotate(180deg);
}

.dropdown-menu {
  position: absolute;
  top: 100%;
  left: 0;
  min-width: 320px;
  background: rgba(10, 26, 40, 0.98);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border: 1px solid rgba(216, 137, 79, 0.25);
  border-radius: 0 0 8px 8px;
  list-style: none;
  padding: 0.6rem 0;
  opacity: 0;
  visibility: hidden;
  transform: translateY(8px);
  transition: var(--transition);
  box-shadow: 0 16px 36px rgba(0, 0, 0, 0.5);
}

.nav-dropdown:hover .dropdown-menu {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}

.dropdown-menu li a {
  display: block;
  padding: 0.65rem 1.3rem;
  font-size: 0.84rem;
  color: var(--c-sand-muted);
  border-left: 2px solid transparent;
}

.dropdown-menu li a:hover {
  background: var(--c-terracotta-dim);
  color: var(--c-sand);
  border-left-color: var(--c-terracotta);
  padding-left: 1.55rem;
}

/* ========================================================================== */
/* 3. HERO BANNER PANTALLA COMPLETA (Ajuste 100% viewport)                    */
/* ========================================================================== */
.hero-banner {
  position: relative;
  width: 100%;
  /* Ocupa la altura total de pantalla restante sin dejar espacios */
  min-height: calc(100vh - var(--topbar-height) - var(--navbar-height));
  min-height: calc(100dvh - var(--topbar-height) - var(--navbar-height));
  background-image: url('../img/Machupicchu--banner.png');
  background-position: center center;
  background-size: cover;
  background-repeat: no-repeat;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 3rem 1.5rem;
  background-position-y: -40px;
}

.hero-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(
    180deg,
    rgba(12, 36, 56, 0.62) 0%,
    rgba(12, 36, 56, 0.45) 50%,
    rgba(12, 36, 56, 0.95) 100%
  );
  z-index: 1;
}

.hero-content {
  position: relative;
  z-index: 2;
  max-width: 860px;
  margin: 0 auto;
}

.hero-content h2 {
  font-family: var(--f-head);
  font-size: clamp(2.1rem, 4.5vw, 3.4rem);
  font-weight: 700;
  color: var(--c-sand);
  line-height: 1.2;
  margin-bottom: 1.4rem;
  text-shadow: 0 2px 14px rgba(0, 0, 0, 0.7);
}

.hero-content p {
  font-size: clamp(1rem, 1.8vw, 1.15rem);
  color: rgba(247, 245, 240, 0.95);
  margin-bottom: 2.2rem;
  line-height: 1.7;
  text-shadow: 0 1px 8px rgba(0, 0, 0, 0.7);
}

.hero-content strong {
  color: var(--c-terracotta);
  font-weight: 600;
}

.hero-buttons {
  display: flex;
  gap: 1.25rem;
  justify-content: center;
  flex-wrap: wrap;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0.85rem 1.8rem;
  border-radius: 999px;
  font-weight: 600;
  font-size: 0.88rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  cursor: pointer;
  transition: var(--transition);
}

.btn-primary {
  background: var(--c-terracotta-soft);
  color: var(--c-navy-deep);
  border: 1px solid var(--c-terracotta-soft);
}

.btn-primary:hover {
  background: var(--c-sand);
  border-color: var(--c-sand);
  color: var(--c-navy-deep);
  transform: translateY(-3px);
  box-shadow: 0 8px 24px var(--c-terracotta-glow);
}

.btn-secondary {
  background: rgba(12, 36, 56, 0.45);
  color: var(--c-sand);
  border: 1px solid rgba(247, 245, 240, 0.35);
  backdrop-filter: blur(8px);
}

.btn-secondary:hover {
  background: var(--c-sand);
  color: var(--c-navy-deep);
  transform: translateY(-3px);
  box-shadow: 0 8px 20px rgba(247, 245, 240, 0.2);
}

/* ========================================================================== */
/* 4 & 5. SECCIONES Y TARJETAS CONTRASTADAS                                   */
/* ========================================================================== */
.section-container {
  max-width: 1280px;
  margin: 0 auto;
  padding: 5.5rem 1.5rem;
}

.bg-alt {
  background: rgba(6, 17, 27, 0.65);
  max-width: 100%;
}

.bg-alt .cards-grid {
  max-width: 1280px;
  margin: 0 auto;
}

.section-header {
  text-align: center;
  margin-bottom: 3.5rem;
}

.section-tag {
  font-size: 0.78rem;
  text-transform: uppercase;
  letter-spacing: 0.22em;
  color: var(--c-terracotta-soft);
  font-weight: 700;
}

.section-title {
  font-family: var(--f-head);
  font-size: clamp(1.9rem, 3.2vw, 2.6rem);
  color: var(--c-sand);
  margin: 0.4rem 0 0.8rem;
}

.title-underline {
  width: 50px;
  height: 2px;
  background: var(--c-terracotta-soft);
  margin: 0 auto;
  border-radius: 2px;
}

.cards-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
  gap: 2rem;
}

.tour-card {
  background: var(--c-card-surface);
  border: 1px solid var(--c-card-border);
  border-radius: 12px;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  transition: transform 0.35s ease, box-shadow 0.35s ease, border-color 0.35s ease;
  backdrop-filter: blur(8px);
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.28);
}

.tour-card:hover {
  transform: translateY(-8px);
  box-shadow: 0 18px 36px -8px rgba(0, 0, 0, 0.55);
  border-color: var(--c-card-border-hover);
}

.card-image-box {
  width: 100%;
  height: 215px;
  overflow: hidden;
  position: relative;
}

.card-image-box img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.6s ease;
}

.tour-card:hover .card-image-box img {
  transform: scale(1.06);
}

.card-content {
  padding: 1.5rem;
  display: flex;
  flex-direction: column;
  flex-grow: 1;
}

.card-title {
  font-family: var(--f-head);
  font-size: 1.2rem;
  font-weight: 700;
  color: var(--c-sand);
  margin-bottom: 0.75rem;
  line-height: 1.35;
  min-height: 2.8rem;
}

.card-description {
  font-size: 0.86rem;
  color: var(--c-sand-muted);
  line-height: 1.55;
  margin-bottom: 1.25rem;
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
  text-overflow: ellipsis;
}

.card-price-box {
  margin-top: auto;
  padding: 0.85rem 0;
  border-top: 1px solid rgba(247, 245, 240, 0.09);
  margin-bottom: 1.2rem;
  display: flex;
  align-items: baseline;
  gap: 0.45rem;
}

.price-prefix,
.price-suffix {
  font-size: 0.76rem;
  color: rgba(247, 245, 240, 0.6);
  text-transform: uppercase;
}

.price-value {
  font-size: 1.35rem;
  font-weight: 700;
  color: var(--c-terracotta);
}

.card-actions {
  display: grid;
  grid-template-columns: 1fr 1.2fr;
  gap: 0.65rem;
}

.btn-card-contact {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0.6rem 0.8rem;
  font-size: 0.8rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  border-radius: 6px;
  border: 1px solid rgba(247, 245, 240, 0.2);
  color: var(--c-sand);
  background: rgba(247, 245, 240, 0.04);
}

.btn-card-contact:hover {
  background: rgba(247, 245, 240, 0.12);
  border-color: var(--c-sand);
}

.btn-card-book {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0.6rem 0.8rem;
  font-size: 0.8rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  border-radius: 6px;
  border: 1px solid var(--c-terracotta-soft);
  color: var(--c-navy-deep);
  background: var(--c-terracotta-soft);
}

.btn-card-book:hover {
  background: var(--c-sand);
  border-color: var(--c-sand);
  color: var(--c-navy-deep);
}

/* ========================================================================== */
/* 6. FOOTER                                                                  */
/* ========================================================================== */
.main-footer {
  background: #06131e;
  border-top: 1px solid rgba(216, 137, 79, 0.2);
  padding-top: 4.5rem;
  color: var(--c-sand);
}

.footer-inner {
  max-width: 1280px;
  margin: 0 auto;
  padding: 0 1.5rem 3.5rem;
  display: grid;
  grid-template-columns: 1.3fr 1fr 1fr 1fr;
  gap: 2.5rem;
}

.brand-col .footer-logo {
  display: inline-flex;
  align-items: center;
  gap: 0.75rem;
  margin-bottom: 1.1rem;
}

.footer-logo-img {
  height: 38px;
  width: auto;
  object-fit: contain;
}

.footer-brand-name {
  font-family: var(--f-head);
  font-size: 1.35rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  color: var(--c-sand);
}

.footer-tagline {
  font-size: 0.85rem;
  color: var(--c-sand-muted);
  line-height: 1.6;
  margin-bottom: 1.5rem;
}

.footer-social-icons {
  display: flex;
  gap: 0.6rem;
}

.footer-social-icons a {
  width: 34px;
  height: 34px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--c-sand-faint);
  border: 1px solid rgba(247, 245, 240, 0.12);
  color: var(--c-sand-muted);
}

.footer-social-icons a:hover {
  background: var(--c-terracotta-soft);
  border-color: var(--c-terracotta-soft);
  color: var(--c-navy-deep);
}

.footer-heading {
  font-family: var(--f-head);
  font-size: 1.1rem;
  color: var(--c-sand);
  margin-bottom: 1.25rem;
  position: relative;
  padding-bottom: 0.5rem;
}

.footer-heading::after {
  content: '';
  position: absolute;
  left: 0;
  bottom: 0;
  width: 30px;
  height: 2px;
  background: var(--c-terracotta-soft);
}

.footer-link-list {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 0.55rem;
}

.footer-link-list a {
  font-size: 0.84rem;
  color: var(--c-sand-muted);
}

.footer-link-list a:hover {
  color: var(--c-terracotta);
  padding-left: 0.35rem;
}

.footer-contact-info {
  margin-top: 1.25rem;
  font-size: 0.83rem;
  color: var(--c-sand-muted);
  line-height: 1.8;
}

.footer-bottom {
  border-top: 1px solid rgba(247, 245, 240, 0.07);
  padding: 1.5rem 1.5rem;
  text-align: center;
  font-size: 0.8rem;
  color: rgba(247, 245, 240, 0.45);
}

/* ========================================================================== */
/* 7. RESPONSIVIDAD TOTAL (Tablets y Celulares)                               */
/* ========================================================================== */
@media (max-width: 992px) {
  :root {
    --navbar-height: 48px;
  }

  .mobile-nav-header {
    display: flex;
  }

  .nav-links {
    display: none;
    flex-direction: column;
    align-items: flex-start;
    gap: 0;
    width: 100%;
    padding: 0.5rem 0 1.2rem;
    border-top: 1px solid rgba(247, 245, 240, 0.08);
  }

  .nav-links.open {
    display: flex;
  }

  .nav-links > li {
    width: 100%;
  }

  .nav-item {
    width: 100%;
    padding: 0.85rem 0.5rem;
    justify-content: space-between;
    border-bottom: 1px solid rgba(247, 245, 240, 0.05);
  }

  .nav-dropdown .dropdown-menu {
    position: static;
    visibility: visible;
    opacity: 1;
    transform: none;
    box-shadow: none;
    border: none;
    background: rgba(6, 18, 28, 0.6);
    border-left: 2px solid var(--c-terracotta-soft);
    margin-left: 0.75rem;
    display: none;
    padding: 0.3rem 0;
  }

  .nav-dropdown.active .dropdown-menu {
    display: block;
  }

  .dropdown-menu li a {
    padding: 0.55rem 1rem;
    font-size: 0.82rem;
  }

  .footer-inner {
    grid-template-columns: 1fr 1fr;
    gap: 2rem;
  }
}

@media (max-width: 768px) {
  .top-actions .top-email {
    display: none;
  }

  .cards-grid {
    grid-template-columns: 1fr;
  }

  .footer-inner {
    grid-template-columns: 1fr;
    gap: 2.2rem;
  }
}

@media (max-width: 480px) {
  :root {
    --topbar-height: 110px;
    --navbar-height: 48px;
  }

  .top-bar-inner {
    flex-direction: column;
    gap: 0.75rem;
    text-align: center;
  }

  .top-brand {
    justify-content: center;
  }

  .top-actions {
    width: 100%;
    justify-content: center;
  }

  .hero-buttons {
    flex-direction: column;
    width: 100%;
  }

  .hero-buttons .btn {
    width: 100%;
  }

  .card-actions {
    grid-template-columns: 1fr;
  }
}