:root {
  --tonalli-gold: #facc15;
  --tonalli-dark: #0f172a;
  --tonalli-white: #ffffff;
  --tonalli-dark-gray: #1e293b;
}

/* Contenedor Navbar */
.nav-tonalli {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 1rem 2.5rem;
  background: rgba(255, 255, 255, 0.08);
  backdrop-filter: blur(15px);
  border-radius: 0 0 30px 30px;
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.2);
  position: fixed;
  width: 100%;
  top: 0;
  z-index: 1000;
  transition: background 0.3s ease, box-shadow 0.3s ease;
}

/* Al hacer scroll: sombra y transparencia */
.nav-tonalli.scrolled {
  background: transparent;
  box-shadow: 0 2px 12px rgba(0, 0, 0, 0.08);
}

/* Logo */
.logo-tonalli-img {
  height: 60px;
  width: auto;
  object-fit: contain;
  filter: drop-shadow(0 0 4px rgba(255, 255, 255, 0.35));
  transition: filter 0.3s ease;
}

.nav-tonalli.scrolled .logo-tonalli-img {
  filter: none;
}

/* Menú centrado */
.menu-tonalli {
  display: flex;
  gap: 2rem;
  position: absolute;
  left: 50%;
  transform: translateX(-50%);
  transition: all 0.3s ease;
}

.menu-tonalli a {
  color: white;
  font-weight: 500;
  position: relative;
  text-decoration: none;
  transition: color 0.3s ease;
}

.menu-tonalli a::after {
  content: '';
  position: absolute;
  width: 0%;
  height: 2px;
  left: 0;
  bottom: -6px;
  background-color: var(--tonalli-gold);
  transition: width 0.3s ease;
}

.menu-tonalli a:hover {
  color: var(--tonalli-gold);
}

.menu-tonalli a:hover::after {
  width: 100%;
}

.nav-tonalli.scrolled .menu-tonalli a {
  color: var(--tonalli-dark-gray);
}

.nav-tonalli.scrolled .menu-tonalli a:hover {
  color: var(--tonalli-gold);
}

/* Botón "Contacto" */
.btn-tonalli-cta {
  padding: 0.5rem 1.2rem;
  border-radius: 999px;
  border: 2px solid var(--tonalli-gold);
  color: var(--tonalli-gold);
  font-weight: 600;
  text-decoration: none;
  font-size: 1rem;
  letter-spacing: 0.5px;
  position: relative;
  overflow: hidden;
  background: transparent;
  transition: all 0.4s ease;
}

.btn-tonalli-cta::before {
  content: '';
  position: absolute;
  top: 0;
  left: -100%;
  width: 100%;
  height: 100%;
  background: var(--tonalli-gold);
  transition: left 0.4s ease;
  z-index: 0;
}

.btn-tonalli-cta:hover::before {
  left: 0;
}

.btn-tonalli-cta span {
  position: relative;
  z-index: 1;
  color: inherit;
  transition: color 0.4s ease;
}

.btn-tonalli-cta:hover span {
  color: var(--tonalli-dark);
}

.nav-tonalli.scrolled .btn-tonalli-cta {
  border-color: var(--tonalli-dark-gray);
  color: var(--tonalli-dark-gray);
}

.nav-tonalli.scrolled .btn-tonalli-cta:hover::before {
  background: var(--tonalli-dark-gray);
}

.nav-tonalli.scrolled .btn-tonalli-cta:hover span {
  color: white;
}

/* Hamburguesa */
.hamburger-tonalli {
  display: none;
  flex-direction: column;
  gap: 4px;
  cursor: pointer;
}

.hamburger-tonalli span {
  width: 25px;
  height: 3px;
  background: white;
  border-radius: 2px;
}

/* Responsive */
@media (max-width: 768px) {
  .menu-tonalli {
    flex-direction: column;
    position: absolute;
    top: 70px;
    left: 50%;
    transform: translateX(-50%);
    background: rgba(15, 23, 42, 0.95);
    padding: 1rem 2rem;
    border-radius: 12px;
    display: none;
  }

  .menu-tonalli.active {
    display: flex;
  }

  .hamburger-tonalli {
    display: flex;
  }

  .btn-tonalli-cta {
    display: none;
  }
}

/* ====== Transición de color al hacer scroll ====== */

/* Enlaces del menú - parte superior (fondo oscuro) */
.menu-tonalli a {
  color: white;
  font-weight: 500;
  position: relative;
  text-decoration: none;
  transition: color 0.3s ease, opacity 0.3s ease;
}

/* Al hacer scroll - sobre fondo claro */
.nav-tonalli.scrolled .menu-tonalli a {
  color: var(--tonalli-dark-gray) !important;
  opacity: 1 !important;
}

/* Hover sigue dorado */
.nav-tonalli.scrolled .menu-tonalli a:hover {
  color: var(--tonalli-gold) !important;
}

.logo-glow-wrap-navbar {
  position: relative;
  display: inline-block;
}

.logo-tonalli-img {
  height: 60px;
  transition: transform 0.3s ease;
  filter: drop-shadow(0 0 6px rgba(251, 191, 36, 0.3));
}

.logo-glow-wrap-navbar:hover .logo-tonalli-img {
  transform: scale(1.05);
  filter: drop-shadow(0 0 18px rgba(251, 191, 36, 0.7));
}

.logo-glow-navbar {
  content: "";
  position: absolute;
  top: 0;
  left: -75%;
  width: 50%;
  height: 100%;
  background: linear-gradient(120deg, transparent, rgba(251, 191, 36, 0.5), transparent);
  transform: skewX(-20deg);
  z-index: 2;
  pointer-events: none;
  opacity: 0;
}

.logo-glow-wrap-navbar:hover .logo-glow-navbar {
  animation: shine-navbar 1s ease-in-out;
  opacity: 1;
}

@keyframes shine-navbar {
  0% {
    left: -75%;
  }

  100% {
    left: 125%;
  }
}

@media (max-width: 768px) {
  .contenido-principal {
    padding-top: 90px;
  }
}

/* Mostrar solo en móvil */
.solo-movil {
  display: block;
}

@media (min-width: 769px) {
  .solo-movil {
    display: none !important;
  }
}
@media (max-width: 480px) {
  .slider-titulo-tonalli {
    font-size: 2.2rem;
    line-height: 1.3;
  }
}

.slider-titulo-tonalli {
  font-size: clamp(2rem, 5vw, 3.2rem); /* ← Esto hace que la fuente sea fluida */
  line-height: 1.2;
  font-weight: bold;
  max-width: 650px;
  transition: color 0.4s ease, text-shadow 0.4s ease;
}




.footer-tonalli {
  background: rgba(255, 255, 255, 0.6);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  color: #1e293b;
  padding: 4rem 5%;
  border-radius: 30px 30px 0 0;
  text-align: center;
  font-family: 'Poppins', sans-serif;
  font-size: 1.05rem;
  box-shadow: 0 -12px 32px rgba(0, 0, 0, 0.15);
}

.footer-top {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 2rem;
  margin-bottom: 2.5rem;
}

.footer-logo .logo-glow-wrap {
  position: relative;
  display: inline-block;
}

.footer-logo img {
  display: block;
  max-width: 160px;
  height: auto;
  transition: transform 0.3s ease;
  filter: drop-shadow(0 0 10px rgba(251, 191, 36, 0.25));
}

.footer-logo .logo-glow-wrap:hover img {
  transform: scale(1.05);
  filter: drop-shadow(0 0 20px rgba(251, 191, 36, 0.8));
}

.logo-glow {
  content: "";
  position: absolute;
  top: 0;
  left: -75%;
  width: 50%;
  height: 100%;
  background: linear-gradient(120deg, transparent, rgba(251, 191, 36, 0.5), transparent);
  transform: skewX(-20deg);
  z-index: 2;
  pointer-events: none;
  opacity: 0;
}

.logo-glow-wrap:hover .logo-glow {
  animation: shine 1s ease-in-out;
  opacity: 1;
}

@keyframes shine {
  0% {
    left: -75%;
  }

  100% {
    left: 125%;
  }
}

.footer-nav {
  display: flex;
  gap: 1.5rem;
  flex-wrap: wrap;
  justify-content: center;
}

.footer-nav a {
  color: #1e293b;
  font-weight: 600;
  text-decoration: none;
  transition: color 0.3s ease;
  font-size: 1.05rem;
  position: relative;
}

.footer-nav a::after {
  content: "";
  position: absolute;
  bottom: -4px;
  left: 0;
  width: 0;
  height: 2px;
  background-color: #fbbf24;
  transition: width 0.3s ease;
}

.footer-nav a:hover {
  color: #f59e0b;
}

.footer-nav a:hover::after {
  width: 100%;
}

.footer-socials-3d {
  display: flex;
  justify-content: center;
  margin-top: 30px;
}

.footer-socials-3d ul {
  display: flex;
  gap: 20px;
  list-style: none;
  padding: 0;
  margin: 0;
}

.footer-socials-3d li a {
  display: flex;
  align-items: center;
  justify-content: center;
  background: #fbbf24;
  color: #1e293b;
  font-size: 1.2rem;
  width: 42px;
  height: 42px;
  border-radius: 50%;
  transition: all 0.3s ease;
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.1);
}

.footer-socials-3d li a:hover {
  transform: translateY(-4px);
  background: #f59e0b;
  color: #fff;
}

.footer-bottom {
  border-top: 1px solid rgba(0, 0, 0, 0.1);
  padding-top: 1.8rem;
  font-size: 0.95rem;
  display: flex;
  flex-direction: column;
  gap: 0.6rem;
  color: #334155;
}

.footer-bottom a {
  color: #f59e0b;
  text-decoration: none;
  font-weight: 500;
}

.footer-bottom a:hover {
  text-decoration: underline;
}

@media (min-width: 768px) {
  .footer-top {
    flex-direction: row;
    justify-content: space-between;
    align-items: center;
  }

  .footer-bottom {
    flex-direction: row;
    justify-content: space-between;
    align-items: center;
  }
}

@media (max-width: 480px) {
  .footer-top {
    gap: 1.5rem;
  }

  .footer-logo img {
    max-width: 130px;
  }
}


/*LOADER*/
@import url('https://fonts.googleapis.com/css2?family=Raleway:wght@500&display=swap');

#preloader-tonalli {
  position: fixed;
  inset: 0;
  background: #fff;
  z-index: 9999;
  display: flex;
  justify-content: center;
  align-items: center;
  flex-direction: column;
  transition: opacity 0.8s ease;
  font-family: 'Raleway', sans-serif;
}

.loader-content img {
  width: 150px;
  max-width: 80%;
  animation: pop 3s ease-in-out infinite;
}

.loader-text {
  margin-top: 20px;
  font-size: 1.2rem;
  font-weight: 500;
  color: #2e6b2d;
  text-align: center;
}

@keyframes pop {

  0%,
  100% {
    transform: scale(1);
    opacity: 1;
  }

  50% {
    transform: scale(1.03);
    opacity: 0.9;
  }
}


.nav-tonalli {
  left: 0;
  right: 0;
  margin: 0;
  /* quita cualquier separación lateral accidental */
  border-radius: 0 0 30px 30px;
  width: 100vw;
  /* fuerza el ancho completo */
  box-sizing: border-box;
}