/* =========================
   CONTAINER
========================= */
.container {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 1.5rem;
}

/* =========================
   SECTIONS
========================= */
.section {
  padding: var(--section-padding) 0;
  scroll-margin-top: 96px;
}

.section h2 {
  text-align: center;
}

.section .split-text {
  text-align: center;
}

.section .split-text ul,
.section .split-text ol {
  text-align: left;
  margin-left: auto;
  margin-right: auto;
}

.section-center {
  text-align: center;
}

.section-center .split-text {
  text-align: center;
}

.section-center ul,
.section-center ol {
  text-align: left;
  margin-left: auto;
  margin-right: auto;
}

.section-light {
  background: linear-gradient(180deg, #f5f7fa 0%, #ffffff 100%);
}

.section-dark {
  background:
    linear-gradient(180deg, rgba(10, 25, 47, 0.9), rgba(10, 25, 47, 0.9)),
    url("../img/content/hero-bg.jpg") center / cover no-repeat;
  color: var(--color-white);
  position: relative;
  overflow: hidden;
}

.section-dark h2,
.section-dark p {
  color: var(--color-white);
}

#contacto::before {
  content: "";
  position: absolute;
  inset: 0;
  box-shadow:
    inset 0 120px 160px rgba(10, 25, 47, 0.35),
    inset 0 -120px 160px rgba(128, 0, 32, 0.25);
  pointer-events: none;
}

#contacto .container {
  position: relative;
  z-index: 1;
  text-align: center;
}

#contacto p {
  text-align: center;
  margin-left: auto;
  margin-right: auto;
}

/* =========================
   HEADER
========================= */
.site-header {
  position: sticky;
  top: 0;
  background: transparent;
  border-bottom: 1px solid transparent;
  box-shadow: none;
  z-index: 1000;
  transition: background var(--transition-base), box-shadow var(--transition-base), border-color var(--transition-base);
}

.site-header.is-scrolled {
  background: rgba(128, 0, 32, 0.12);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid rgba(128, 0, 32, 0.2);
  box-shadow: 0 8px 24px rgba(10, 25, 47, 0.12);
}

.site-header.is-scrolled .main-nav a:not(.btn) {
  color: var(--color-primary);
  text-shadow: none;
}

.site-header.is-scrolled .main-nav a:not(.btn):hover {
  background-color: rgba(128, 0, 32, 0.18);
  transform: translateY(-1px);
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 72px;
  gap: 1.5rem;
}

.logo {
  display: inline-flex;
  align-items: center;
  gap: 0.6rem;
}

.logo img {
  height: 40px;
  max-height: 44px;
  width: auto;
  display: block;
}

.main-nav {
  display: flex;
  align-items: center;
  gap: 1.2rem;
}

.main-nav a:not(.btn) {
  font-family: var(--font-heading);
  font-weight: 600;
  color: var(--text-primary);
  padding: 0.4rem 0.6rem;
  border-radius: 999px;
}

.main-nav a:not(.btn):hover {
  background-color: rgba(128, 0, 32, 0.12);
  transform: translateY(-1px);
}

.nav-toggle {
  display: none;
  width: 44px;
  height: 44px;
  border: 1px solid rgba(10, 25, 47, 0.12);
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.6);
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 5px;
  padding: 0;
}

.nav-toggle span {
  display: block;
  width: 20px;
  height: 2px;
  background: var(--color-primary);
  border-radius: 999px;
  transition: transform 0.2s ease, opacity 0.2s ease;
}

/* =========================
   HERO
========================= */
.hero {
  margin-top: -80px;
  padding: calc(5.25rem + 80px) 0 4.5rem;
  min-height: calc(100vh + 80px);
  min-height: calc(100svh + 80px);
  position: relative;
  overflow: hidden;
  display: flex;
  align-items: center;
}

/* Dark-to-transparent wash using brand navy to keep text legible while showing the photo */
.hero::before {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(90deg, rgba(10, 25, 47, 0.78) 0%, rgba(10, 25, 47, 0.5) 42%, rgba(10, 25, 47, 0.22) 70%, rgba(10, 25, 47, 0) 100%);
  z-index: 1;
}

/* Background image sits behind content for easier swapping */
.hero-media {
  position: absolute;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  user-select: none;
}

.hero-media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  filter: saturate(0.92) contrast(0.95);
}

.hero-content {
  position: relative;
  z-index: 2;
  max-width: 700px;
}

/* Clean editorial block: no glass, just strong typographic contrast */
.hero-text {
  padding: 0;
  background: transparent;
  border: none;
  box-shadow: none;
  backdrop-filter: none;
}

.hero h1 {
  color: #f8fafc;
  font-size: clamp(2.1rem, 3.6vw, 3.1rem);
  line-height: 1.15;
}

.hero-micro {
  margin-top: 0.6rem;
  font-size: 0.95rem;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: rgba(248, 250, 252, 0.72);
}

.hero-subtitle {
  font-size: 1.02rem;
  margin-top: 1rem;
  max-width: 620px;
  color: rgba(248, 250, 252, 0.86);
}

.hero-cta {
  display: flex;
  flex-wrap: wrap;
  gap: 0.7rem;
  margin-top: 1.4rem;
}

/* =========================
   SPLIT LAYOUTS
========================= */
.split {
  display: grid;
  grid-template-columns: minmax(0, 1.1fr) minmax(0, 0.9fr);
  gap: 3.5rem;
  align-items: center;
}

.split.reverse > .split-text {
  order: 2;
}

.split.reverse > .split-media {
  order: 1;
}

.split-media img {
  width: 100%;
  border-radius: 22px;
  box-shadow: 0 18px 40px rgba(10, 25, 47, 0.12);
  border: 1px solid rgba(10, 25, 47, 0.08);
  background: var(--color-gray-light);
  object-fit: cover;
}

.section-dark .split-media img {
  border-color: rgba(255, 255, 255, 0.2);
  box-shadow: 0 22px 50px rgba(0, 0, 0, 0.35);
}

/* =========================
   FOOTER
========================= */
.site-footer {
  background-color: var(--color-primary);
  background-image: none;
  color: var(--color-white);
  padding: 4rem 0 2rem;
  position: relative;
  overflow: hidden;
}

.site-footer * {
  background-image: none !important;
}

.site-footer::before,
.site-footer::after {
  content: none !important;
}

.footer-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 2.5rem;
  align-items: start;
}

.footer-brand p {
  color: rgba(255, 255, 255, 0.7);
}

.footer-logo {
  height: 40px;
  width: auto;
  margin-bottom: 0.8rem;
  display: block;
}

.footer-contact ul,
.footer-social ul {
  list-style: none;
  padding: 0;
  margin: 0;
}

.footer-contact li,
.footer-social li {
  display: flex;
  align-items: center;
  gap: 0.7rem;
  margin-bottom: 0.8rem;
}

.footer-icon {
  width: 38px;
  height: 38px;
  border-radius: 10px;
  background: rgba(128, 0, 32, 0.18);
  color: var(--color-accent);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex: 0 0 38px;
  transition: transform 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
}

.footer-icon svg {
  width: 18px;
  height: 18px;
}

.footer-contact li:hover .footer-icon,
.footer-social li:hover .footer-icon {
  transform: translateY(-2px);
  background: rgba(128, 0, 32, 0.3);
  box-shadow: 0 10px 18px rgba(10, 25, 47, 0.2);
}

.footer-contact a,
.footer-social a {
  color: var(--color-white);
  transition: var(--transition-base);
}

.footer-contact a:hover,
.footer-social a:hover {
  opacity: 0.8;
}

@media (max-width: 980px) {
  .logo img {
    height: 34px;
  }

  .header-inner {
    height: auto;
    padding: 0.75rem 0;
    flex-wrap: wrap;
  }

  .hero {
    margin-top: -104px;
    padding: calc(4.25rem + 104px) 0 3.5rem;
    min-height: calc(100svh + 104px);
  }

  .hero-text {
    padding: 0;
  }

  .split {
    grid-template-columns: 1fr;
  }

  .split.reverse > .split-text,
  .split.reverse > .split-media {
    order: initial;
  }

  .main-nav {
    display: none;
    flex-direction: column;
    align-items: stretch;
    gap: 0.6rem;
    width: 100%;
    margin-top: 0.8rem;
    padding: 0.6rem 0.8rem 0.9rem;
    border-radius: 16px;
    background: rgba(255, 255, 255, 0.98);
    border: 1px solid rgba(10, 25, 47, 0.1);
    box-shadow: 0 18px 36px rgba(10, 25, 47, 0.12);
    backdrop-filter: blur(10px);
  }

  .site-header.nav-open .main-nav {
    display: flex;
  }

  .nav-toggle {
    display: inline-flex;
  }

  .site-header.nav-open .nav-toggle span:nth-child(1) {
    transform: translateY(7px) rotate(45deg);
  }

  .site-header.nav-open .nav-toggle span:nth-child(2) {
    opacity: 0;
  }

  .site-header.nav-open .nav-toggle span:nth-child(3) {
    transform: translateY(-7px) rotate(-45deg);
  }

  .footer-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 768px) {
  .section {
    padding: 3.5rem 0;
  }

  .hero {
    min-height: auto;
  }

  .hero-cta {
    justify-content: center;
  }
}

@media (max-width: 600px) {
  .main-nav {
    gap: 0.4rem;
  }

  .main-nav a:not(.btn) {
    padding: 0.35rem 0.5rem;
  }
}
