/* ---------- Preloader ---------- */
.preloader {
  position: fixed;
  inset: 0;
  z-index: 300;
  background: var(--noche);
  display: grid;
  place-items: center;
  transition: opacity 0.6s var(--ease-marca), visibility 0.6s;
}
.preloader.is-hidden {
  opacity: 0;
  visibility: hidden;
}
.preloader__inner {
  text-align: center;
}
.preloader__mark {
  font-family: var(--fuente-display);
  font-size: clamp(3rem, 9vw, 6rem);
  color: var(--hueso);
  line-height: 1;
}
.preloader__mark em {
  color: var(--ambar);
}
.preloader__bar {
  width: min(60vw, 260px);
  height: 2px;
  margin: 1.4rem auto 0.7rem;
  background: var(--borde);
  overflow: hidden;
}
.preloader__bar span {
  display: block;
  height: 100%;
  width: 0%;
  background: var(--ambar);
}
.preloader__count {
  font-family: var(--fuente-meta);
  font-size: 0.8rem;
  letter-spacing: 0.2em;
  color: var(--texto-suave);
}
.no-js .preloader {
  display: none;
}

/* ---------- Draft ribbon ---------- */
.draft-ribbon {
  background: repeating-linear-gradient(45deg, #6b4a05, #6b4a05 12px, #7d5706 12px, #7d5706 24px);
  color: #ffe6b0;
  font-family: var(--fuente-meta);
  font-size: 0.74rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  text-align: center;
  padding: 0.45rem 1rem;
  position: relative;
  z-index: 60;
}

/* ---------- Nav ---------- */
.nav {
  position: sticky;
  top: 0;
  z-index: 50;
  backdrop-filter: blur(14px);
  background: rgba(11, 31, 58, 0.72);
  border-bottom: 1px solid var(--borde-2);
}
.nav__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: 0.85rem 0;
}
.brand {
  display: flex;
  align-items: center;
  gap: 0.7rem;
}
.brand img {
  width: 42px;
  height: 42px;
}
.brand__name {
  display: block;
  font-family: var(--fuente-display);
  font-size: 1.05rem;
  line-height: 1.1;
}
.brand__tag {
  display: block;
  font-family: var(--fuente-meta);
  font-size: 0.66rem;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--texto-tenue);
}
.nav__links {
  display: flex;
  gap: 1.6rem;
  font-size: 0.92rem;
}
.nav__links a {
  color: var(--texto-suave);
  transition: color 0.25s;
  position: relative;
}
.nav__links a:hover,
.nav__links a[aria-current="page"] {
  color: var(--hueso);
}
.nav__cta {
  display: flex;
  align-items: center;
  gap: 0.7rem;
}
.nav__toggle {
  display: none;
  background: none;
  border: 1px solid var(--borde);
  color: var(--texto);
  border-radius: 10px;
  padding: 0.5rem 0.7rem;
  cursor: pointer;
}

.nav__mobile {
  position: fixed;
  inset: 0;
  z-index: 90;
  background: var(--noche-2);
  clip-path: inset(0 0 100% 0);
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 0.4rem;
  padding: 2rem;
  visibility: hidden;
}
.nav__mobile.is-open {
  visibility: visible;
}
.nav__mobile a {
  font-family: var(--fuente-display);
  font-size: clamp(1.9rem, 9vw, 3rem);
  padding: 0.35rem 0;
  border-bottom: 1px solid var(--borde-2);
}
.nav__mobile .cerrar {
  position: absolute;
  top: 1.4rem;
  right: 1.6rem;
  font-size: 1.6rem;
  background: none;
  border: none;
  color: var(--texto);
  cursor: pointer;
}

/* ---------- Hero ---------- */
.hero {
  position: relative;
  min-height: 100svh;
  display: flex;
  align-items: center;
  padding: 6rem 0 4rem;
  overflow: hidden;
}
.hero__grid {
  display: grid;
  grid-template-columns: 1.05fr 0.95fr;
  gap: clamp(1.5rem, 5vw, 4rem);
  align-items: center;
}
.hero__title {
  font-size: clamp(2.6rem, 7vw, 5.2rem);
  line-height: 0.98;
}
.hero__lead {
  font-size: 1.12rem;
  color: var(--texto-suave);
  max-width: 46ch;
}
.hero__actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.9rem;
  margin: 1.6rem 0 0;
}
.hero__photo {
  position: relative;
  justify-self: center;
  width: min(100%, 460px);
  aspect-ratio: 4 / 5;
  border-radius: 200px 200px var(--radio-lg) var(--radio-lg);
  overflow: hidden;
  background: linear-gradient(160deg, var(--noche-3), var(--noche-2));
  border: 1px solid var(--borde);
  box-shadow: var(--sombra);
}
.hero__photo img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center top;
}
.hero__glow {
  position: absolute;
  width: 60vw;
  height: 60vw;
  max-width: 620px;
  max-height: 620px;
  right: -8%;
  top: 8%;
  background: radial-gradient(circle, rgba(245, 165, 36, 0.32), transparent 62%);
  filter: blur(30px);
  z-index: 0;
  pointer-events: none;
}
.hero__scroll {
  position: absolute;
  bottom: 1.6rem;
  left: 50%;
  transform: translateX(-50%);
  font-family: var(--fuente-meta);
  font-size: 0.7rem;
  letter-spacing: 0.28em;
  text-transform: uppercase;
  color: var(--texto-tenue);
  display: flex;
  align-items: center;
  gap: 0.6rem;
}
.hero__scroll::after {
  content: "";
  width: 1px;
  height: 34px;
  background: linear-gradient(var(--ambar), transparent);
}

/* ---------- Chapters ---------- */
.chapter {
  position: relative;
  padding: clamp(4rem, 10vw, 8rem) 0;
}
.chapter__inner {
  display: grid;
  grid-template-columns: 0.9fr 1.1fr;
  gap: clamp(1.5rem, 5vw, 4rem);
  align-items: center;
}
.chapter--rev .chapter__inner {
  grid-template-columns: 1.1fr 0.9fr;
}
.chapter__media {
  border-radius: var(--radio-lg);
  overflow: hidden;
  border: 1px solid var(--borde);
  background: var(--noche-2);
  aspect-ratio: 4 / 5;
  position: relative;
}
.chapter__media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.chapter__body p {
  color: var(--texto-suave);
  font-size: 1.05rem;
}
.chapter__datos {
  display: flex;
  flex-wrap: wrap;
  gap: 1.4rem;
  margin-top: 1.6rem;
}
.chapter__dato {
  border-left: 2px solid var(--ambar);
  padding-left: 0.8rem;
}
.chapter__dato b {
  display: block;
  font-family: var(--fuente-display);
  font-size: 1.1rem;
}
.chapter__dato span {
  font-family: var(--fuente-meta);
  font-size: 0.7rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--texto-tenue);
}

/* ---------- Propuestas ---------- */
.axes {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.2rem;
}
.eje {
  background: var(--superficie);
  border: 1px solid var(--borde);
  border-radius: var(--radio);
  padding: 1.7rem;
  transition: transform 0.4s var(--ease-marca), background 0.3s, border-color 0.3s;
  position: relative;
  overflow: hidden;
}
.eje:hover {
  transform: translateY(-6px);
  background: var(--superficie-2);
  border-color: rgba(245, 165, 36, 0.4);
}
.eje__n {
  font-family: var(--fuente-meta);
  font-size: 0.8rem;
  color: var(--ambar);
  letter-spacing: 0.2em;
}
.eje__icon {
  width: 46px;
  height: 46px;
  margin: 0.9rem 0 0.4rem;
  color: var(--ambar);
}
.eje h3 {
  font-size: 1.35rem;
  margin-bottom: 0.4rem;
}
.eje p {
  color: var(--texto-suave);
  font-size: 0.95rem;
  margin: 0;
}

/* ---------- Ruleta 3D ---------- */
.wheel-wrap {
  position: relative;
  height: 60vh;
  min-height: 420px;
  display: grid;
  place-items: center;
  perspective: 1400px;
  margin-top: 2rem;
}
.wheel {
  position: relative;
  width: 300px;
  height: 300px;
  transform-style: preserve-3d;
}
.wheel__slot {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  text-align: center;
  padding: 1.4rem;
  border-radius: var(--radio-lg);
  background: linear-gradient(150deg, var(--noche-3), var(--noche-2));
  border: 1px solid var(--borde);
  backface-visibility: hidden;
}
.wheel__slot b {
  font-family: var(--fuente-display);
  font-size: 1.6rem;
}
.wheel__slot span {
  display: block;
  font-family: var(--fuente-meta);
  font-size: 0.72rem;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--ambar);
  margin-bottom: 0.5rem;
}

/* ---------- Territorio ---------- */
.territorio__grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.2rem;
  margin-top: 2rem;
}
.pilar {
  padding: 1.5rem;
  border-radius: var(--radio);
  border: 1px solid var(--borde);
  background: linear-gradient(160deg, rgba(31, 111, 84, 0.16), transparent);
}
.pilar h3 {
  font-size: 1.2rem;
}
.pilar p {
  color: var(--texto-suave);
  font-size: 0.92rem;
  margin: 0;
}

/* ---------- Mosaico redes ---------- */
.mosaico {
  columns: 3;
  column-gap: 1.1rem;
}
.post {
  break-inside: avoid;
  margin-bottom: 1.1rem;
  border-radius: var(--radio);
  overflow: hidden;
  border: 1px solid var(--borde);
  background: var(--superficie);
  display: block;
  transition: transform 0.4s var(--ease-marca), border-color 0.3s;
}
.post:hover {
  transform: translateY(-4px);
  border-color: rgba(245, 165, 36, 0.4);
}
.post__media {
  aspect-ratio: 1 / 1;
  background: linear-gradient(150deg, var(--noche-3), var(--noche-2));
  display: grid;
  place-items: center;
  position: relative;
}
.post__media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.post__red {
  position: absolute;
  top: 0.7rem;
  left: 0.7rem;
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  font-family: var(--fuente-meta);
  font-size: 0.64rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  background: rgba(8, 24, 49, 0.72);
  border: 1px solid var(--borde);
  padding: 0.28rem 0.6rem;
  border-radius: 999px;
}
.post__red svg {
  width: 13px;
  height: 13px;
}
.post__body {
  padding: 1rem 1.1rem 1.2rem;
}
.post__body h3 {
  font-size: 1.05rem;
  margin-bottom: 0.35rem;
}
.post__body p {
  color: var(--texto-suave);
  font-size: 0.86rem;
  margin: 0 0 0.6rem;
}
.post__fecha {
  font-family: var(--fuente-meta);
  font-size: 0.68rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--texto-tenue);
}
.mosaico__placeholder {
  display: grid;
  place-items: center;
  text-align: center;
  height: 100%;
  padding: 1rem;
}
.mosaico__placeholder span {
  font-family: var(--fuente-meta);
  font-size: 0.7rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--texto-tenue);
}
.redes-cta {
  display: flex;
  flex-wrap: wrap;
  gap: 0.8rem;
  justify-content: center;
  margin-top: 2.2rem;
}

/* ---------- Sumate ---------- */
.form {
  max-width: 640px;
}
.form__grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1rem;
}
.field {
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
  margin-bottom: 1rem;
}
.field--full {
  grid-column: 1 / -1;
}
.field label {
  font-family: var(--fuente-meta);
  font-size: 0.72rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--texto-suave);
}
.field input,
.field select,
.field textarea {
  background: var(--superficie);
  border: 1px solid var(--borde);
  border-radius: 12px;
  padding: 0.85rem 1rem;
  color: var(--texto);
  font-family: inherit;
  font-size: 1rem;
}
.field.check {
  flex-direction: row;
  align-items: flex-start;
  gap: 0.7rem;
  font-size: 0.88rem;
  color: var(--texto-suave);
}
.field.check input {
  width: auto;
  margin-top: 0.2rem;
}
.form__error {
  color: #ff9b8a;
  font-size: 0.86rem;
  margin: -0.5rem 0 0.8rem;
  min-height: 1em;
}
.form__ok {
  color: var(--sabana-2);
  font-weight: 600;
}

/* ---------- CTA final ---------- */
.cta-final {
  text-align: center;
  padding: clamp(4rem, 9vw, 7rem) 0;
}
.cta-final h2 {
  font-size: clamp(2.1rem, 5vw, 3.6rem);
}

/* ---------- Footer ---------- */
.footer {
  border-top: 1px solid var(--borde-2);
  padding: 3.5rem 0 2.5rem;
  position: relative;
  z-index: 1;
}
.footer__grid {
  display: grid;
  grid-template-columns: 1.4fr 1fr 1fr;
  gap: 2rem;
  margin-bottom: 2rem;
}
.footer h4 {
  font-size: 1rem;
  margin-bottom: 0.8rem;
}
.footer a {
  color: var(--texto-suave);
  font-size: 0.92rem;
  transition: color 0.2s;
}
.footer a:hover {
  color: var(--hueso);
}
.footer__nota {
  border-top: 1px solid var(--borde-2);
  padding-top: 1.5rem;
  font-size: 0.78rem;
  color: var(--texto-tenue);
  max-width: 80ch;
}

/* ---------- Admin ---------- */
.admin-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.9rem;
}
.admin-table th,
.admin-table td {
  text-align: left;
  padding: 0.6rem 0.8rem;
  border-bottom: 1px solid var(--borde-2);
}
.admin-table th {
  font-family: var(--fuente-meta);
  font-size: 0.7rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--texto-suave);
}

/* ---------- Cookie banner ---------- */
.cookie-banner {
  position: fixed;
  left: 1rem;
  right: 1rem;
  bottom: 1rem;
  z-index: 120;
  max-width: 760px;
  margin-inline: auto;
  background: rgba(8, 24, 49, 0.96);
  border: 1px solid var(--borde);
  border-radius: var(--radio);
  padding: 1.1rem 1.3rem;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 1rem;
  box-shadow: var(--sombra);
  transform: translateY(140%);
  transition: transform 0.6s var(--ease-marca);
}
.cookie-banner.is-visible {
  transform: translateY(0);
}
.cookie-banner p {
  margin: 0;
  flex: 1 1 320px;
  font-size: 0.86rem;
  color: var(--texto-suave);
}
.cookie-banner a {
  color: var(--ambar);
  text-decoration: underline;
}

/* ---------- Plan de trabajo ---------- */
.plan {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1.2rem;
}
.plan-bloque {
  position: relative;
  background: var(--superficie);
  border: 1px solid var(--borde);
  border-radius: var(--radio);
  padding: 1.8rem 1.8rem 1.6rem;
  min-height: 230px;
}
.plan-bloque__n {
  font-family: var(--fuente-display);
  font-size: 2.4rem;
  color: rgba(245, 165, 36, 0.35);
  line-height: 1;
  display: block;
  margin-bottom: 0.4rem;
}
.plan-bloque h2 {
  font-size: 1.4rem;
  margin-bottom: 0.5rem;
}
.plan-bloque p {
  color: var(--texto-suave);
  font-size: 0.95rem;
}
.plan-bloque__puntos {
  list-style: none;
  margin: 0.6rem 0 0;
  padding: 0;
}
.plan-bloque__puntos li {
  position: relative;
  padding-left: 1.3rem;
  color: var(--texto-suave);
  font-size: 0.9rem;
  margin-bottom: 0.4rem;
}
.plan-bloque__puntos li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0.6em;
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--ambar);
}

/* ---------- Comunidad (cifras de redes) ---------- */
.comunidad {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 2.2rem;
  padding: 1.4rem 0 2rem;
  border-bottom: 1px solid var(--borde-2);
  margin-bottom: 2.2rem;
}
.comunidad__item b {
  font-family: var(--fuente-display);
  font-size: clamp(1.7rem, 3.4vw, 2.4rem);
  color: var(--hueso);
  display: block;
  line-height: 1;
}
.comunidad__item span {
  font-family: var(--fuente-meta);
  font-size: 0.7rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--ambar);
}
.comunidad__nota {
  font-family: var(--fuente-meta);
  font-size: 0.68rem;
  letter-spacing: 0.1em;
  color: var(--texto-tenue);
  margin-left: auto;
}

/* ---------- Facebook en vivo ---------- */
.fb-live {
  margin-top: 2.5rem;
  border-top: 1px solid var(--borde-2);
  padding-top: 2.5rem;
  display: grid;
  grid-template-columns: 0.9fr 1.1fr;
  gap: 2rem;
  align-items: start;
}
.fb-live__intro h3 {
  font-size: 1.6rem;
}
.fb-live__intro p {
  color: var(--texto-suave);
}
.fb-embed {
  min-height: 320px;
  border-radius: var(--radio);
  border: 1px dashed var(--borde);
  display: grid;
  place-items: center;
  background: var(--superficie);
}
.fb-embed iframe {
  width: 100%;
  border-radius: var(--radio);
}

@media (max-width: 980px) {
  .plan,
  .fb-live {
    grid-template-columns: 1fr;
  }
}

/* ---------- Responsive ---------- */
@media (max-width: 980px) {
  .hero__grid,
  .chapter__inner,
  .chapter--rev .chapter__inner {
    grid-template-columns: 1fr;
  }
  .hero__photo,
  .chapter__media {
    width: min(100%, 400px);
  }
  .axes,
  .territorio__grid {
    grid-template-columns: 1fr 1fr;
  }
  .mosaico {
    columns: 2;
  }
  .footer__grid {
    grid-template-columns: 1fr 1fr;
  }
}

@media (max-width: 720px) {
  .nav__links,
  .nav__cta .btn {
    display: none;
  }
  .nav__toggle {
    display: inline-block;
  }
  .axes,
  .territorio__grid,
  .form__grid,
  .footer__grid {
    grid-template-columns: 1fr;
  }
  .mosaico {
    columns: 1;
  }
  .chapter--rev .chapter__media {
    order: -1;
  }
}
