/* ============================================================
   GeoVillages — landing.css
   Hero, secciones de la landing y galería de exploración.
   Depende de los tokens y componentes de base.css.
   ============================================================ */

/* ---------- Utilidades de sección ---------- */
.section { padding: 88px 0; }
.section-alt {
  background:
    radial-gradient(900px 420px at 50% 0%, rgba(139, 92, 246, .07), transparent 70%),
    var(--surface);
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
}
.section-head { text-align: center; max-width: 680px; margin: 0 auto 48px; }
.section-head p { color: var(--muted); font-size: 16.5px; margin-bottom: 0; }
.section-title {
  font-size: clamp(26px, 4.2vw, 42px);
  letter-spacing: -0.01em;
  margin-bottom: 14px;
}
.section-tag {
  display: inline-block;
  padding: 5px 14px;
  border-radius: 999px;
  font: 600 12px var(--font-body);
  letter-spacing: .1em;
  text-transform: uppercase;
  color: var(--brand-strong);
  background: rgba(139, 92, 246, .12);
  border: 1px solid rgba(139, 92, 246, .28);
  margin-bottom: 16px;
}

/* ---------- Reveal on scroll (solo si hay JS) ---------- */
.gv-js .reveal {
  opacity: 0;
  transform: translateY(26px);
  transition: opacity .65s ease, transform .65s ease;
}
.gv-js .reveal.is-visible { opacity: 1; transform: none; }
.gv-js .reveal.d1 { transition-delay: .08s; }
.gv-js .reveal.d2 { transition-delay: .16s; }
.gv-js .reveal.d3 { transition-delay: .24s; }

/* ---------- Ajustes de flashes con nav transparente ---------- */
.landing .gv-flashes { position: relative; z-index: 60; }
.landing .gv-flashes:not(:empty) { padding-top: 84px; }

/* ============================================================
   HERO
   ============================================================ */
.hero {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  min-height: 96vh;
  min-height: 96svh;
  padding: 150px 0 110px;
}
.hero-inner {
  position: relative;
  z-index: 5;
  text-align: center;
  max-width: 900px;
}
.hero-badge {
  font-size: 13px;
  padding: 7px 16px;
  margin-bottom: 28px;
}
.hero-title {
  font-size: clamp(44px, 9vw, 96px);
  font-weight: 700;
  letter-spacing: -0.025em;
  line-height: 1.02;
  margin: 0 0 24px;
}
.hero-sub {
  font-size: clamp(16px, 2.3vw, 20px);
  color: var(--muted);
  max-width: 640px;
  margin: 0 auto 38px;
  line-height: 1.65;
}
.hero-ctas {
  display: flex;
  gap: 14px;
  justify-content: center;
  flex-wrap: wrap;
}

/* --- Fondo del hero --- */
.hero-bg {
  position: absolute;
  inset: 0;
  z-index: 0;
  overflow: hidden;
  pointer-events: none;
}
.hero-fade {
  position: absolute;
  left: 0; right: 0; bottom: 0;
  height: 190px;
  background: linear-gradient(to bottom, transparent, var(--ink));
  z-index: 3;
}

/* Cuadrícula retro synthwave (suelo en perspectiva) */
.hero-grid {
  position: absolute;
  left: -25%;
  right: -25%;
  bottom: -14%;
  height: 58%;
  background-image:
    linear-gradient(rgba(139, 92, 246, .17) 1px, transparent 1px),
    linear-gradient(90deg, rgba(139, 92, 246, .17) 1px, transparent 1px);
  background-size: 46px 46px;
  transform: perspective(520px) rotateX(60deg);
  transform-origin: 50% 0;
  -webkit-mask-image: linear-gradient(to bottom, transparent 0, #000 28%, rgba(0, 0, 0, .3) 100%);
  mask-image: linear-gradient(to bottom, transparent 0, #000 28%, rgba(0, 0, 0, .3) 100%);
}

/* Blobs de gradiente: el wrapper recibe el parallax (JS),
   el interior lleva la deriva lenta (CSS). */
.blob-wrap { position: absolute; z-index: 1; will-change: transform; }
/* Blobs pastel muy suaves sobre fondo blanco */
.blob { border-radius: 50%; filter: blur(90px); opacity: .3; }
.bw-1 { top: -190px; left: -170px; }
.bw-2 { top: 6%; right: -230px; }
.bw-3 { bottom: -260px; left: 26%; }
.blob-1 {
  width: 580px; height: 580px;
  background: radial-gradient(circle at 35% 35%, var(--brand), transparent 70%);
  animation: blob-a 26s ease-in-out infinite alternate;
}
.blob-2 {
  width: 640px; height: 640px;
  background: radial-gradient(circle at 60% 40%, var(--pink), transparent 70%);
  opacity: .26;
  animation: blob-b 32s ease-in-out infinite alternate;
}
.blob-3 {
  width: 540px; height: 540px;
  background: radial-gradient(circle at 50% 50%, #22d3ee, transparent 70%);
  opacity: .22;
  animation: blob-c 24s ease-in-out infinite alternate;
}
@keyframes blob-a { to { transform: translate(70px, 55px) scale(1.14); } }
@keyframes blob-b { to { transform: translate(-65px, 70px) scale(1.1); } }
@keyframes blob-c { to { transform: translate(55px, -60px) scale(1.18); } }

/* Emojis flotantes decorativos */
.float-wrap { position: absolute; z-index: 2; will-change: transform; }
.float-el {
  display: block;
  font-size: 36px;
  animation: floaty 7s ease-in-out infinite;
  filter: drop-shadow(0 8px 20px rgba(139, 92, 246, .45));
}
@keyframes floaty {
  50% { transform: translateY(-18px) rotate(6deg); }
}
.fw-1 { top: 25%; left: 7%; }
.fw-2 { top: 16%; right: 11%; }
.fw-3 { bottom: 32%; left: 13%; }
.fw-4 { top: 42%; right: 6%; }
.fw-5 { bottom: 13%; right: 8%; }
.fw-6 { top: 60%; left: 3%; }
.fw-1 .float-el { animation-delay: -1s; }
.fw-2 .float-el { animation-delay: -3s; font-size: 30px; animation-duration: 6s; }
.fw-3 .float-el { animation-delay: -2s; font-size: 32px; animation-duration: 8s; }
.fw-4 .float-el { animation-delay: -4.5s; font-size: 30px; }
.fw-5 .float-el { animation-delay: -5.5s; animation-duration: 9s; }
.fw-6 .float-el { animation-delay: -2.8s; font-size: 28px; animation-duration: 7.5s; }

/* ============================================================
   CINTA MARQUEE RETRO
   ============================================================ */
.marquee-strip {
  overflow: hidden;
  border-top: 1px solid rgba(139, 92, 246, .35);
  border-bottom: 1px solid rgba(139, 92, 246, .35);
  background: rgba(139, 92, 246, .08);
  padding: 11px 0;
}
.marquee-track {
  display: flex;
  width: max-content;
  animation: marquee 30s linear infinite;
}
.marquee-track span {
  white-space: nowrap;
  padding-right: 28px;
  font: 700 14px 'Courier New', monospace;
  letter-spacing: .06em;
  color: var(--brand-strong);
}
@keyframes marquee { to { transform: translateX(-50%); } }

/* ============================================================
   MUESTRA / INGREDIENTES
   ============================================================ */
.ingredients {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 14px;
}
.ingredient {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 13px 22px;
  border-radius: 999px;
  background: var(--card);
  border: 1px solid var(--line);
  box-shadow: var(--shadow-card);
  font: 600 15px var(--font-display);
  color: var(--text);
  transition: transform .18s ease, border-color .18s ease, box-shadow .18s ease;
}
.ingredient:hover {
  transform: translateY(-3px);
  border-color: rgba(139, 92, 246, .5);
  box-shadow: var(--shadow-pop);
}

/* ============================================================
   FEATURES
   ============================================================ */
.features-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
}
.feature-card {
  padding: 28px 26px;
  position: relative;
  overflow: hidden;
  transition: transform .2s ease, border-color .2s ease, box-shadow .2s ease;
}
.feature-card::before {
  content: '';
  position: absolute;
  top: 0; left: 0; right: 0;
  height: 3px;
  background: var(--grad-brand);
  opacity: 0;
  transition: opacity .2s ease;
}
.feature-card:hover {
  transform: translateY(-5px);
  border-color: rgba(139, 92, 246, .55);
  box-shadow: var(--shadow-pop);
}
.feature-card:hover::before { opacity: 1; }
.feature-emoji {
  display: block;
  font-size: 40px;
  line-height: 1;
  margin-bottom: 16px;
}
.feature-card h3 { font-size: 19px; margin-bottom: 8px; }
.feature-card p { color: var(--muted); font-size: 14.5px; margin: 0; }

/* ============================================================
   CÓMO FUNCIONA
   ============================================================ */
.steps {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 22px;
}
.step { padding: 32px 26px; text-align: center; }
.step-num {
  width: 54px; height: 54px;
  margin: 0 auto 18px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  background: var(--grad-brand);
  color: #fff;
  font: 700 22px var(--font-display);
  box-shadow: 0 8px 22px rgba(236, 72, 153, .35);
}
.step h3 { font-size: 19px; margin-bottom: 8px; }
.step p { color: var(--muted); font-size: 14.5px; margin: 0; }

/* ============================================================
   TARJETAS DE SITIOS (showcase + explore)
   ============================================================ */
.sites-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 20px;
}
a.site-card {
  display: block;
  padding: 22px;
  color: var(--text);
  text-decoration: none !important;
  transition: transform .18s ease, border-color .18s ease, box-shadow .18s ease;
}
a.site-card:hover {
  transform: translateY(-4px);
  border-color: rgba(139, 92, 246, .6);
  box-shadow: var(--shadow-pop);
}
.site-card-top {
  display: flex;
  align-items: center;
  gap: 14px;
  min-width: 0;
}
.site-emoji {
  flex: 0 0 auto;
  width: 54px; height: 54px;
  display: grid;
  place-items: center;
  font-size: 28px;
  border-radius: var(--radius-sm);
  background: rgba(139, 92, 246, .12);
  border: 1px solid rgba(139, 92, 246, .3);
}
.site-id { min-width: 0; }
.site-title {
  font: 600 17px var(--font-display);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.site-author {
  color: var(--cyan);
  font-size: 13.5px;
  font-weight: 600;
  margin-top: 3px;
}
.site-meta {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  margin-top: 16px;
  padding-top: 13px;
  border-top: 1px solid var(--line);
  color: var(--muted);
  font-size: 13px;
}
.showcase-more { text-align: center; margin-top: 34px; }

/* ============================================================
   BARRIOS
   ============================================================ */
.barrios-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 16px;
}
a.barrio-card {
  display: flex;
  flex-direction: column;
  gap: 8px;
  padding: 24px 20px;
  color: var(--text);
  text-decoration: none !important;
  transition: transform .18s ease, border-color .18s ease, box-shadow .18s ease;
}
a.barrio-card:hover {
  transform: translateY(-4px);
  border-color: rgba(34, 211, 238, .55);
  box-shadow: var(--shadow-pop);
}
.barrio-emoji { font-size: 34px; line-height: 1; }
.barrio-name { font-family: var(--font-display); font-size: 17px; }
.barrio-desc {
  color: var(--muted);
  font-size: 13.5px;
  line-height: 1.45;
  flex: 1;
}

/* ============================================================
   CTA FINAL
   ============================================================ */
.section-cta { padding-bottom: 30px; }
.cta-final {
  position: relative;
  overflow: hidden;
  text-align: center;
  padding: 76px 28px;
  border-radius: 26px;
  border: 1px solid rgba(139, 92, 246, .4);
  background:
    radial-gradient(620px 320px at 15% 0%, rgba(139, 92, 246, .28), transparent 65%),
    radial-gradient(620px 320px at 85% 100%, rgba(236, 72, 153, .22), transparent 65%),
    var(--card);
  box-shadow: var(--shadow-card);
}
.cta-final h2 {
  font-size: clamp(28px, 4.6vw, 46px);
  letter-spacing: -0.015em;
  margin-bottom: 14px;
}
.cta-final p {
  color: var(--muted);
  font-size: 17px;
  max-width: 560px;
  margin: 0 auto 32px;
}
.cta-note { margin-top: 18px; font-size: 13.5px; }

/* ============================================================
   ESTADO VACÍO (showcase + explore)
   ============================================================ */
.empty-state {
  text-align: center;
  padding: 70px 26px;
  max-width: 640px;
  margin: 0 auto;
}
.empty-emoji { font-size: 60px; line-height: 1; margin-bottom: 16px; }
.empty-state h3 { font-size: 22px; }
.empty-state p { max-width: 460px; margin: 0 auto 26px; }
.empty-actions {
  display: flex;
  gap: 12px;
  justify-content: center;
  flex-wrap: wrap;
}

/* ============================================================
   EXPLORE
   ============================================================ */
.explore-head { padding-top: 56px; }
.explore-title {
  font-size: clamp(30px, 5.5vw, 48px);
  letter-spacing: -0.02em;
  margin-bottom: 10px;
}
.explore-sub { font-size: 16.5px; max-width: 620px; }
.chips {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin: 26px 0 8px;
}
.chip {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  padding: 9px 16px;
  border-radius: 999px;
  background: var(--card);
  border: 1px solid var(--line);
  color: var(--muted);
  font: 600 13.5px var(--font-body);
  text-decoration: none !important;
  transition: transform .15s ease, border-color .15s ease, color .15s ease, box-shadow .15s ease;
}
.chip:hover {
  color: var(--text);
  border-color: var(--brand);
  transform: translateY(-1px);
}
.chip-active {
  background: var(--grad-brand);
  color: #fff;
  border-color: transparent;
  box-shadow: 0 6px 18px rgba(139, 92, 246, .4);
}
.chip-active:hover { color: #fff; border-color: transparent; }
.explore-main { padding-top: 26px; padding-bottom: 30px; }
.results-info {
  color: var(--muted);
  font-size: 14.5px;
  margin-bottom: 22px;
}

/* ============================================================
   RESPONSIVE
   ============================================================ */
@media (max-width: 980px) {
  .features-grid { grid-template-columns: repeat(2, 1fr); }
  .barrios-grid { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 760px) {
  .section { padding: 62px 0; }
  .section-head { margin-bottom: 36px; }
  .hero { padding: 130px 0 90px; min-height: 88vh; min-height: 88svh; }
  .steps { grid-template-columns: 1fr; }
  .fw-3, .fw-6 { display: none; }
  .blob { filter: blur(70px); }
}
@media (max-width: 560px) {
  .features-grid { grid-template-columns: 1fr; }
  .barrios-grid { grid-template-columns: 1fr; }
  .sites-grid { grid-template-columns: 1fr; }
  .hero-ctas .btn { width: 100%; max-width: 320px; }
  .float-el { font-size: 26px !important; }
  .fw-5 { display: none; }
  .cta-final { padding: 56px 20px; }
  .empty-state { padding: 54px 18px; }
}
@media (max-width: 400px) {
  .hero-title { font-size: 40px; }
  .hero-badge { font-size: 12px; }
  .chip { padding: 8px 13px; font-size: 13px; }
  .ingredient { padding: 11px 18px; font-size: 14px; }
}

/* ============================================================
   MOVIMIENTO REDUCIDO
   ============================================================ */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .blob,
  .float-el,
  .marquee-track { animation: none !important; }
  .gv-js .reveal {
    opacity: 1 !important;
    transform: none !important;
    transition: none !important;
  }
  .feature-card:hover,
  a.site-card:hover,
  a.barrio-card:hover,
  .chip:hover { transform: none; }
}
