/* =========================================================
   Jardines Perpetuos — Página pública
   Estructura: tokens · base · componentes · secciones · responsive
   ========================================================= */

/* ---------- Tokens ---------- */
:root {
  /* Morado tomado directamente del logo oficial (LOGO-JP.png): #4B2464 */
  --jp-purple: #4B2464;
  --jp-purple-dark: #331645;
  --jp-purple-deep: #2A0F3B;
  --jp-purple-mid: #6B3F87;
  --jp-purple-light: #F2ECF5;
  --jp-purple-tint: #E6DBEC;

  --jp-ivory: #FAF8F4;
  --jp-ivory-2: #F6F2EE;
  --jp-white: #FFFFFF;
  --jp-text: #1F1A24;
  --jp-muted: #5E5764;
  --jp-border: #E8E2EA;

  /* Festival */
  --jp-marigold: #F4A21E;
  --jp-marigold-deep: #E4651A;
  --jp-gold: #FFD27A;
  --jp-cream: #FFF3DA;

  --font-serif: "Cormorant Garamond", "Cormorant", Georgia, serif;
  --font-sans: "Inter", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;

  /* Contenedor de contenido: fondos y hero van a todo el ancho; el contenido, máx. 1240px */
  --container-max: 1240px;
  --gutter: clamp(20px, 3.4vw, 49px);
  --radius: 10px;
  --ease: cubic-bezier(.22, .61, .36, 1);
  --header-h: 92px;
}

/* ---------- Base ---------- */
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; scroll-padding-top: var(--header-h); }
body {
  margin: 0;
  font-family: var(--font-sans);
  font-size: 16px;
  line-height: 1.55;
  color: var(--jp-text);
  background: var(--jp-white);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}
img, picture, svg { display: block; max-width: 100%; }
img { height: auto; }
a { color: inherit; }
ul { margin: 0; padding: 0; list-style: none; }
p, h1, h2, h3, figure, blockquote { margin: 0; }
address { font-style: normal; }

.sprite { position: absolute; width: 0; height: 0; overflow: hidden; }
.icon {
  width: 1em; height: 1em; flex: none;
  fill: none; stroke: currentColor; stroke-width: 1.5;
  stroke-linecap: round; stroke-linejoin: round;
}

.wrap { width: min(100% - 2 * var(--gutter), var(--container-max)); margin-inline: auto; }

:focus-visible { outline: 2px solid var(--jp-purple); outline-offset: 3px; border-radius: 4px; }
.skip-link {
  position: absolute; left: 16px; top: -60px; z-index: 100;
  background: var(--jp-purple); color: #fff; padding: 10px 16px; border-radius: 8px;
  text-decoration: none; font-weight: 600; transition: top .2s;
}
.skip-link:focus { top: 12px; }

/* ---------- Botones ---------- */
.btn {
  display: inline-flex; align-items: center; gap: .6em;
  font: 500 15px/1 var(--font-sans);
  letter-spacing: .01em;
  text-decoration: none; white-space: nowrap;
  border-radius: 999px; padding: 15px 26px;
  border: 1px solid transparent;
  transition: background-color .3s var(--ease), color .3s var(--ease), border-color .3s var(--ease), box-shadow .3s var(--ease), transform .3s var(--ease);
}
.btn .icon { font-size: 17px; }
.btn .icon--arrow { transition: transform .35s var(--ease); }
.btn:hover .icon--arrow { transform: translateX(4px); }

.btn--emergency {
  background: var(--jp-purple); color: #fff;
  padding: 14px 26px 14px 22px;
  box-shadow: 0 6px 18px -8px rgba(75, 36, 100, .55);
}
.btn--emergency .icon { font-size: 18px; }
.btn--emergency:hover { background: var(--jp-purple-dark); box-shadow: 0 10px 24px -10px rgba(75, 36, 100, .7); }

.btn--ghost {
  color: #fff; border-color: rgba(255, 255, 255, .85);
  background: rgba(42, 15, 59, .38);
  backdrop-filter: blur(4px); -webkit-backdrop-filter: blur(4px);
}
.btn--ghost:hover { background: #fff; color: var(--jp-purple); border-color: #fff; }

.btn--marigold {
  background: linear-gradient(180deg, #FFB73A, var(--jp-marigold-deep));
  color: var(--jp-purple-deep); font-weight: 700;
  box-shadow: 0 10px 24px -12px rgba(228, 101, 26, .9);
}
.btn--marigold:hover { background: linear-gradient(180deg, #FFC75C, #EE7424); }

.link-caps {
  display: inline-flex; align-items: center; gap: 10px;
  font: 600 12px/1 var(--font-sans); letter-spacing: .12em; text-transform: uppercase;
  color: var(--jp-purple); text-decoration: none; white-space: nowrap;
}
.link-caps .icon { font-size: 15px; transition: transform .35s var(--ease); }
.link-caps:hover .icon { transform: translateX(4px); }

.circle-arrow {
  display: inline-grid; place-items: center;
  width: 34px; height: 34px; border-radius: 50%;
  border: 1px solid var(--jp-purple); color: var(--jp-purple);
  transition: background-color .3s var(--ease), color .3s var(--ease);
}
.circle-arrow .icon { font-size: 15px; transition: transform .35s var(--ease); }

/* =========================================================
   HEADER
   ========================================================= */
.site-header {
  position: sticky; top: 0; z-index: 50;
  background: rgba(255, 255, 255, .97);
  transition: box-shadow .3s var(--ease);
}
.site-header.is-scrolled { box-shadow: 0 1px 0 var(--jp-border), 0 8px 24px -18px rgba(31, 26, 36, .35); }
.site-header__inner {
  height: var(--header-h);
  display: flex; align-items: center; gap: 24px;
}
/* Marca del encabezado: la versión reducida del logotipo en SVG (isotipo y
   nombre). El pie usa el logotipo completo, que es otra imagen. */
.brand { flex: none; display: block; padding: 4px 0; }
.brand img { height: 68px; width: auto; }

.main-nav { flex: 1; display: flex; justify-content: center; }
.main-nav ul { display: flex; gap: clamp(20px, 2.6vw, 37.4px); }
.main-nav a:not(.btn) {
  position: relative; display: block; padding: 8px 0;
  font-size: 14.5px; font-weight: 500; color: var(--jp-text); text-decoration: none;
  transition: color .25s var(--ease);
}
.main-nav a:not(.btn)::after {
  content: ""; position: absolute; left: 0; right: 0; bottom: 2px; height: 1px;
  background: var(--jp-purple); transform: scaleX(0); transform-origin: left;
  transition: transform .35s var(--ease);
}
.main-nav a:not(.btn):hover { color: var(--jp-purple); }
.main-nav a:not(.btn):hover::after,
.main-nav a[aria-current="page"]::after { transform: scaleX(1); }
.main-nav a[aria-current="page"] { color: var(--jp-purple); font-weight: 600; }
.main-nav__emergency { display: none; }

.header-emergency { flex: none; }
.header-emergency__short { display: none; }
.header-call, .nav-toggle { display: none; }

/* =========================================================
   HERO
   ========================================================= */
.hero {
  position: relative; isolation: isolate;
  height: clamp(520px, 41vw, 720px);
  color: #fff; overflow: hidden;
  background: #3f5a2c;
}
.hero__media, .hero__media img {
  position: absolute; inset: 0; width: 100%; height: 100%;
}
.hero__media img { object-fit: cover; object-position: 50% 18%; z-index: -2; }
/* Degradado sutil: solo lo necesario para la legibilidad del texto */
.hero::before {
  content: ""; position: absolute; inset: 0; z-index: -1;
  background:
    linear-gradient(90deg, rgba(20, 12, 26, .55) 0%, rgba(20, 12, 26, .28) 30%, rgba(20, 12, 26, 0) 55%),
    linear-gradient(0deg, rgba(20, 12, 26, .42) 0%, rgba(20, 12, 26, 0) 42%),
    linear-gradient(270deg, rgba(20, 12, 26, .32) 0%, rgba(20, 12, 26, 0) 22%);
}
.hero__inner {
  position: relative; height: 100%;
  display: flex; align-items: flex-end; justify-content: space-between; gap: 32px;
  padding-bottom: clamp(40px, 4.6vw, 66.2px);
}
.hero__title {
  font-family: var(--font-serif); font-weight: 500;
  font-size: clamp(48px, 5.4vw, 77.8px); line-height: .96; letter-spacing: -.01em;
  text-shadow: 0 2px 24px rgba(0, 0, 0, .25);
}
.hero__lead {
  margin: 18px 0 30px;
  font-size: clamp(17px, 1.45vw, 20.9px); line-height: 1.45; font-weight: 400;
  text-shadow: 0 1px 12px rgba(0, 0, 0, .35);
}
.hero__words {
  text-align: right; padding-bottom: 6px;
  font: 500 clamp(13px, 1.1vw, 15.8px)/2.05 var(--font-sans);
  letter-spacing: .16em; text-transform: uppercase;
  text-shadow: 0 1px 10px rgba(0, 0, 0, .4);
}
.hero__words::after {
  content: ""; display: block; width: 76px; height: 1px; margin: 14px 0 0 auto;
  background: rgba(255, 255, 255, .8);
}

/* =========================================================
   ACCESOS
   ========================================================= */
.access { background: var(--jp-ivory); border-bottom: 1px solid var(--jp-border); }
.access__grid { display: grid; grid-template-columns: repeat(4, 1fr); }
.access__item {
  position: relative;
  display: flex; flex-direction: column; align-items: center; text-align: center;
  padding: 34px 20px 36px; text-decoration: none; color: var(--jp-text);
  transition: background-color .35s var(--ease);
}
.access__item + .access__item::before {
  content: ""; position: absolute; left: 0; top: 22px; bottom: 22px; width: 1px; background: var(--jp-border);
}
.access__icon {
  display: grid; place-items: center;
  width: 80px; height: 80px; border-radius: 50%;
  background: var(--jp-purple-light); color: var(--jp-purple);
  margin-bottom: 20px;
  transition: background-color .35s var(--ease), transform .35s var(--ease);
}
.access__icon .icon { font-size: 34px; stroke-width: 1.35; }
.access__title {
  font-size: 15px; font-weight: 600; letter-spacing: .06em; text-transform: uppercase;
  margin-bottom: 8px;
}
.access__text { font-size: 15px; line-height: 1.5; color: var(--jp-muted); margin-bottom: 22px; }
.access__item:hover { background: rgba(255, 255, 255, .7); }
.access__item:hover .access__icon { background: var(--jp-purple-tint); transform: translateY(-2px); }
.access__item:hover .circle-arrow { background: var(--jp-purple); color: #fff; }
.access__item:hover .circle-arrow .icon { transform: translateX(2px); }

/* =========================================================
   INSTALACIONES
   ========================================================= */
.facilities { padding: clamp(48px, 4.6vw, 66.2px) 0 clamp(52px, 5vw, 72px); }
.section-head {
  display: flex; align-items: flex-end; justify-content: space-between; gap: 20px;
  margin-bottom: 28px;
}
.section-title {
  font-family: var(--font-serif); font-weight: 500;
  font-size: clamp(36px, 3.4vw, 49px); line-height: 1.05; letter-spacing: -.005em;
  color: var(--jp-text);
}
.section-head .link-caps { margin-bottom: 10px; }

.facilities__scroller { width: min(100% - 2 * var(--gutter), var(--container-max)); margin-inline: auto; }
.facilities__grid { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: clamp(14px, 1.5vw, 21.6px); }
.photo-card figure { display: block; }
.photo-card__img {
  aspect-ratio: 3 / 2; overflow: hidden; border-radius: var(--radius);
  background: var(--jp-ivory-2);
}
.photo-card__img picture { display: block; height: 100%; }
.photo-card__img img {
  width: 100%; height: 100%; object-fit: cover;
  transition: transform .9s var(--ease), filter .6s var(--ease);
}
.photo-card:hover .photo-card__img img { transform: scale(1.035); }
.photo-card figcaption {
  margin-top: 12px; font-size: 15px; font-weight: 500; color: var(--jp-text);
}

/* =========================================================
   FESTIVAL DE DÍA DE MUERTOS
   ========================================================= */
.fest {
  position: relative; isolation: isolate; overflow: hidden;
  color: #fff;
  background:
    radial-gradient(60% 80% at 12% 90%, rgba(196, 58, 128, .45) 0%, rgba(196, 58, 128, 0) 60%),
    radial-gradient(50% 60% at 45% 10%, rgba(120, 60, 170, .45) 0%, rgba(120, 60, 170, 0) 70%),
    linear-gradient(115deg, #2E0F42 0%, #4B2464 48%, #3A1553 100%);
  display: grid;
  grid-template-columns: var(--gutter) auto minmax(0, 1fr) 44%;
  grid-template-rows: clamp(44px, 4vw, 57.6px) auto auto auto auto clamp(44px, 4vw, 57.6px);
  grid-template-areas:
    ".  .      .     photo"
    ".  head   meta  photo"
    ".  place  place photo"
    ".  acts   acts  photo"
    ".  cta    cta   photo"
    ".  .      .     photo";
  column-gap: 32px;
}
/* papel picado sutil en el borde superior */
.fest::before {
  content: ""; position: absolute; left: 0; right: 0; top: 0; height: 10px; z-index: 3;
  background:
    radial-gradient(circle at 10px 0, transparent 7px, var(--jp-marigold) 7.5px) 0 0 / 20px 10px repeat-x;
  opacity: .9;
}
.fest::after {
  content: ""; position: absolute; inset: 0 44% 0 0; z-index: 0; pointer-events: none;
  background: url("../images/fest-altar-1000.webp") 30% 60% / cover no-repeat;
  opacity: .13; mix-blend-mode: luminosity;
  -webkit-mask-image: linear-gradient(90deg, #000 30%, transparent 100%);
          mask-image: linear-gradient(90deg, #000 30%, transparent 100%);
}
.fest > * { position: relative; z-index: 1; }

.fest__head { grid-area: head; align-self: end; }
.fest__logo {
  width: 118px; height: auto; margin-bottom: 22px;
  /* versión monocroma blanca del logo oficial (como en el cartel) */
  filter: brightness(0) invert(1); opacity: .95;
}
.fest__edition {
  font: 700 clamp(15px, 1.35vw, 19.4px)/1 var(--font-sans);
  letter-spacing: .22em; text-transform: uppercase; color: var(--jp-gold);
}
.fest__title {
  font-family: var(--font-serif); font-weight: 600;
  font-size: clamp(54px, 6.4vw, 92.2px); line-height: .92; letter-spacing: -.01em;
  margin-top: 8px;
  color: var(--jp-cream);
  background: linear-gradient(180deg, #FFF8E6 0%, #FFE3A3 100%);
  -webkit-background-clip: text; background-clip: text; -webkit-text-fill-color: transparent;
  text-shadow: none;
  filter: drop-shadow(0 3px 0 rgba(160, 30, 110, .55));
}
.fest__tagline {
  margin-top: 14px;
  font-family: var(--font-serif); font-style: italic; font-weight: 500;
  font-size: clamp(22px, 2vw, 28.8px); color: #fff;
}
.fest__tagline::after {
  content: ""; display: block; width: 120px; height: 1px; margin-top: 14px;
  background: linear-gradient(90deg, var(--jp-gold), transparent);
}

.fest__meta { grid-area: meta; align-self: end; justify-self: start; position: relative; z-index: 3; padding-top: 30px; margin-left: clamp(8px, 2vw, 28.8px); margin-bottom: 8px; }
.fest__date {
  display: grid; justify-items: center; text-align: center;
  width: 150px; padding: 14px 12px 12px;
  border-radius: 14px;
  background: linear-gradient(180deg, #FFD27A 0%, var(--jp-marigold) 100%);
  color: var(--jp-purple-deep);
  box-shadow: 0 0 0 3px rgba(255, 210, 122, .35), 0 18px 34px -18px rgba(0, 0, 0, .6);
}
.fest__date-day, .fest__date-month { font: 800 14px/1.1 var(--font-sans); letter-spacing: .12em; text-transform: uppercase; }
.fest__date-num { font: 700 76px/.95 var(--font-sans); letter-spacing: -.04em; margin: 2px 0 0; }
.fest__date-month { font-size: 18px; letter-spacing: .08em; }
.fest__date-time {
  margin-top: 10px; padding: 5px 12px; border-radius: 999px;
  background: var(--jp-purple-deep); color: var(--jp-gold);
  font: 700 14px/1 var(--font-sans); letter-spacing: .04em;
}
.fest__free {
  position: absolute; top: -18px; left: calc(100% - 30px);
  transform: rotate(-9deg);
  padding: 12px 18px; border-radius: 999px;
  background: var(--jp-marigold-deep); color: #fff;
  font: 800 15px/1 var(--font-sans); letter-spacing: .06em; text-transform: uppercase; white-space: nowrap;
  box-shadow: 0 10px 24px -10px rgba(0, 0, 0, .55);
}

.fest__place {
  grid-area: place; margin-top: 30px;
  display: flex; align-items: flex-start; gap: 10px;
  font-size: 15px; line-height: 1.45; color: rgba(255, 255, 255, .92);
  letter-spacing: .02em;
}
.fest__place .icon { font-size: 22px; color: var(--jp-marigold); margin-top: 1px; }
.fest__place strong { font-weight: 600; text-transform: uppercase; letter-spacing: .06em; font-size: 14px; }

.fest__acts {
  grid-area: acts; margin-top: 30px;
  display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 12px;
  max-width: 640px;
}
.fest__acts li {
  display: flex; flex-direction: column; align-items: center; text-align: center; gap: 10px;
  font: 700 12.5px/1.25 var(--font-sans); letter-spacing: .06em; text-transform: uppercase;
}
.fest__acts .icon { font-size: 38px; color: var(--jp-gold); stroke-width: 1.3; }

.fest__cta { grid-area: cta; margin-top: 34px; }

.fest__photo { grid-area: photo; position: relative; margin: 0; min-height: 560px; }
.fest__photo picture, .fest__photo img { position: absolute; inset: 0; width: 100%; height: 100%; }
.fest__photo img {
  object-fit: cover; object-position: 72% 45%;
  -webkit-mask-image: linear-gradient(90deg, transparent 0%, #000 22%);
          mask-image: linear-gradient(90deg, transparent 0%, #000 22%);
}
.fest__script {
  position: absolute; right: clamp(20px, 3vw, 43.2px); bottom: clamp(22px, 2.6vw, 37.4px);
  font-family: var(--font-serif); font-style: italic; font-weight: 500;
  font-size: clamp(26px, 2.4vw, 34.6px); color: #fff;
  text-shadow: 0 2px 14px rgba(0, 0, 0, .7);
}

/* Decoración floral */
.fest__deco { position: absolute; inset: 0; z-index: 0; pointer-events: none; grid-area: auto; }
.mg { position: absolute; filter: drop-shadow(0 6px 10px rgba(0, 0, 0, .3)); }
.mg--1 { width: 190px; height: 190px; left: -66px; bottom: -62px; }
.mg--2 { width: 116px; height: 116px; left: 78px; bottom: -44px; }
.mg--3 { width: 82px; height: 82px; left: -24px; bottom: 118px; }
.mg--4 { width: 84px; height: 84px; left: 150px; bottom: -30px; }
.lf { position: absolute; width: 70px; height: 35px; }
.lf--1 { left: 44px; bottom: 112px; transform: rotate(-38deg); }
.lf--2 { left: 214px; bottom: 30px; transform: rotate(-14deg); width: 56px; }

/* Fotografías del Festival */
.fest-photos {
  background: linear-gradient(180deg, #2A0F3B 0%, #230C31 100%);
  padding: 22px 0 34px;
}
.fest-photos__grid {
  display: grid; grid-template-columns: 1.5fr 1fr 1fr .62fr; gap: 14px;
  height: clamp(200px, 17vw, 244.8px);
}
.fest-photos__item, .fest-photos__poster {
  position: relative; overflow: hidden; border-radius: var(--radius); margin: 0; min-height: 0;
}
.fest-photos__item picture, .fest-photos__item img,
.fest-photos__poster picture, .fest-photos__poster img { width: 100%; height: 100%; }
.fest-photos__item img, .fest-photos__poster img { object-fit: cover; transition: transform .9s var(--ease); }
.fest-photos__item:hover img, .fest-photos__poster:hover img { transform: scale(1.035); }
.fest-photos__item figcaption {
  position: absolute; left: 0; right: 0; bottom: 0; padding: 30px 16px 12px;
  background: linear-gradient(0deg, rgba(20, 8, 28, .75), transparent);
  font-size: 13px; font-weight: 500; letter-spacing: .02em; color: #fff;
}
.fest-photos__poster { display: block; text-decoration: none; color: #fff; }
.fest-photos__poster img { object-position: 50% 0; }
.fest-photos__poster-label {
  position: absolute; left: 0; right: 0; bottom: 0; padding: 30px 12px 12px;
  display: flex; align-items: center; gap: 8px;
  background: linear-gradient(0deg, rgba(20, 8, 28, .85), transparent);
  font: 600 12px/1.2 var(--font-sans); letter-spacing: .08em; text-transform: uppercase;
}
.fest-photos__poster-label .icon { transition: transform .35s var(--ease); }
.fest-photos__poster:hover .fest-photos__poster-label .icon { transform: translateX(3px); }

/* =========================================================
   CIERRE EMOCIONAL
   ========================================================= */
.closing {
  position: relative; overflow: hidden; isolation: isolate;
  background: linear-gradient(180deg, #F7F1F4 0%, var(--jp-ivory) 38%, #fff 100%);
  padding: clamp(56px, 6vw, 86.4px) 0;
}
.closing__inner {
  display: grid; grid-template-columns: minmax(0, 1.1fr) minmax(0, 1fr); align-items: center; gap: 48px;
}
.closing__quote p {
  font-family: var(--font-serif); font-style: italic; font-weight: 500;
  font-size: clamp(28px, 2.6vw, 37.4px); line-height: 1.25; color: var(--jp-text);
  padding-left: clamp(0px, 4vw, 57.6px);
}
.pillars { display: flex; justify-content: flex-end; gap: clamp(20px, 3vw, 43.2px); }
.pillars li {
  display: flex; align-items: center; gap: 14px;
  font: 500 12.5px/1.2 var(--font-sans); letter-spacing: .14em; text-transform: uppercase; color: var(--jp-text);
  white-space: nowrap;
}
.pillars__icon {
  display: grid; place-items: center; width: 60px; height: 60px; border-radius: 50%;
  background: #fff; border: 1px solid var(--jp-border); color: var(--jp-purple);
}
.pillars__icon .icon { font-size: 28px; stroke-width: 1.3; }

/* =========================================================
   FOOTER
   ========================================================= */
.site-footer { background: #fff; border-top: 1px solid var(--jp-border); }
.site-footer__grid {
  display: grid; grid-template-columns: 1.35fr .8fr 1.2fr .7fr; gap: 40px;
  padding-top: clamp(44px, 4.4vw, 63.4px); padding-bottom: clamp(40px, 4vw, 56px);
}
.site-footer__brand img { width: 220px; height: auto; }
.site-footer__title { font: 600 15px/1.2 var(--font-sans); color: var(--jp-text); margin-bottom: 16px; }
.site-footer__list li { margin-bottom: 7px; }
.site-footer__list a {
  font-size: 14.5px; color: var(--jp-muted); text-decoration: none;
  transition: color .25s var(--ease);
}
.site-footer__list a:hover { color: var(--jp-purple); }
.site-footer__list--icons li { display: flex; gap: 12px; align-items: flex-start; margin-bottom: 12px; }
.site-footer__list--icons .icon { font-size: 18px; color: var(--jp-purple); margin-top: 2px; }
.site-footer__list--icons a { line-height: 1.5; }
.social { display: flex; gap: 12px; }
.social a {
  display: grid; place-items: center; width: 42px; height: 42px; border-radius: 50%;
  background: var(--jp-purple-light); color: var(--jp-purple);
  transition: background-color .3s var(--ease), color .3s var(--ease), transform .3s var(--ease);
}
.social .icon { font-size: 20px; }
.social .icon .fill, .icon .fill { fill: currentColor; stroke: none; }
.social a:hover { background: var(--jp-purple); color: #fff; transform: translateY(-2px); }

.site-footer__bar { background: var(--jp-purple-light); }
.site-footer__bar-inner {
  display: flex; justify-content: space-between; align-items: center; gap: 16px;
  padding-top: 18px; padding-bottom: 18px;
  font-size: 13px; color: var(--jp-muted);
}
.site-footer__motto { font-family: var(--font-serif); font-style: italic; font-size: 19px; color: var(--jp-purple); font-weight: 500; }

/* =========================================================
   APARICIÓN SUAVE (solo con JS y sin reduced-motion)
   ========================================================= */
@media (prefers-reduced-motion: no-preference) {
  .js [data-reveal] { opacity: 0; transform: translateY(14px); transition: opacity .8s var(--ease), transform .8s var(--ease); }
  .js [data-reveal].is-visible { opacity: 1; transform: none; }
  .js .access__grid [data-reveal]:nth-child(2), .js .facilities__grid [data-reveal]:nth-child(2) { transition-delay: .06s; }
  .js .access__grid [data-reveal]:nth-child(3), .js .facilities__grid [data-reveal]:nth-child(3) { transition-delay: .12s; }
  .js .access__grid [data-reveal]:nth-child(4), .js .facilities__grid [data-reveal]:nth-child(4) { transition-delay: .18s; }
  .js .facilities__grid [data-reveal]:nth-child(5) { transition-delay: .24s; }
}
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { transition-duration: .01ms !important; animation-duration: .01ms !important; }
}

/* =========================================================
   RESPONSIVE
   ========================================================= */

/* Laptop */
@media (max-width: 1279px) {
  .main-nav ul { gap: 14px; }
  .main-nav a:not(.btn) { font-size: 14px; white-space: nowrap; }
  .header-emergency { padding: 12px 18px 12px 16px; font-size: 14px; }
  .header-emergency__long { display: none; }
  .header-emergency__short { display: inline; }
  .brand img { height: 62px; }
  .fest { column-gap: 24px; }
  .fest__acts { gap: 8px; }
  .fest__acts li { font-size: 11.5px; }
  .pillars { gap: 20px; }
  .pillars__icon { width: 52px; height: 52px; }
}

/* Tablet: menú hamburguesa */
@media (max-width: 1023px) {
  :root { --header-h: 76px; }
  .brand img { height: 56px; }
  .site-header__inner { gap: 12px; }
  .header-emergency { margin-left: auto; }
  .nav-toggle {
    display: grid; place-items: center; width: 46px; height: 46px; flex: none;
    border: 1px solid var(--jp-border); border-radius: 50%; background: #fff; color: var(--jp-text);
    cursor: pointer; transition: border-color .25s var(--ease);
  }
  .nav-toggle .icon { font-size: 22px; }
  .nav-toggle .icon--close { display: none; }
  .nav-toggle[aria-expanded="true"] .icon--open { display: none; }
  .nav-toggle[aria-expanded="true"] .icon--close { display: block; }
  .nav-toggle:hover { border-color: var(--jp-purple); }

  .main-nav {
    position: fixed; left: 0; right: 0; top: var(--header-h); bottom: 0; z-index: 49;
    display: flex; flex-direction: column; justify-content: flex-start; gap: 28px;
    padding: 18px var(--gutter) 40px;
    background: #fff; border-top: 1px solid var(--jp-border);
    overflow-y: auto;
    opacity: 0; visibility: hidden; transform: translateY(-8px);
    transition: opacity .3s var(--ease), transform .3s var(--ease), visibility 0s linear .3s;
  }
  .main-nav.is-open { opacity: 1; visibility: visible; transform: none; transition-delay: 0s; }
  .main-nav ul { flex-direction: column; gap: 0; }
  .main-nav li { border-bottom: 1px solid var(--jp-border); }
  .main-nav a:not(.btn) { padding: 16px 0; font-family: var(--font-serif); font-size: 28px; font-weight: 500; white-space: normal; }
  .main-nav a:not(.btn)::after { display: none; }
  .main-nav a[aria-current="page"] { font-weight: 600; }
  .main-nav__emergency { display: inline-flex; align-self: flex-start; }
  body.nav-open { overflow: hidden; } /* bloquea scroll del fondo mientras el menú está abierto */

  .hero { height: clamp(520px, 72vw, 640px); }
  .hero__media img { object-position: 58% 50%; }

  .fest {
    grid-template-columns: var(--gutter) minmax(0, 1fr) auto var(--gutter);
    grid-template-rows: auto;
    grid-template-areas:
      ".     .     .     ."
      ".     head  meta  ."
      "photo photo photo photo"
      ".     acts  acts  ."
      ".     place place ."
      ".     cta   cta   ."
      ".     .     .     .";
    grid-template-rows: 48px auto auto auto auto auto 48px;
  }
  .fest__photo { min-height: 0; aspect-ratio: 16 / 10; margin-top: 36px; }
  .fest__photo img { -webkit-mask-image: none; mask-image: none; object-position: 78% 45%; }
  .fest__photo::before {
    content: ""; position: absolute; inset: 0; z-index: 1;
    background: linear-gradient(180deg, #4B2464 0%, rgba(75, 36, 100, 0) 18%, rgba(0,0,0,0) 70%, rgba(20, 8, 28, .45) 100%);
  }
  .fest__script { z-index: 2; }
  .fest__free { left: auto; right: -12px; top: -24px; }
  .fest__acts { max-width: none; margin-top: 34px; }
  .fest__place { margin-top: 30px; }
  .mg--1 { bottom: auto; top: 58%; }
  .mg--2, .lf { display: none; }

  .closing__inner { grid-template-columns: 1fr; gap: 36px; }
  .closing__quote p { padding-left: 0; }
  .pillars { justify-content: flex-start; }

  .site-footer__grid { grid-template-columns: 1fr 1fr 1fr; }
  .site-footer__brand { grid-column: 1 / -1; }
}

/* Galería como carrusel horizontal (tablet y mobile) */
@media (max-width: 899px) {
  .facilities__scroller {
    width: 100%; padding-inline: var(--gutter);
    overflow-x: auto; overscroll-behavior-x: contain;
    scroll-snap-type: x mandatory; scroll-padding-inline: var(--gutter);
    scrollbar-width: none;
    padding-bottom: 4px;
  }
  .facilities__scroller::-webkit-scrollbar { display: none; }
  .facilities__grid {
    grid-template-columns: none; grid-auto-flow: column; grid-auto-columns: min(74vw, 340px);
    gap: 14px; width: max-content;
  }
  .photo-card { scroll-snap-align: start; }

  .access__grid { grid-template-columns: repeat(2, 1fr); width: 100%; }
  .access__item { padding: 28px 16px 30px; border-bottom: 1px solid var(--jp-border); }
  .access__item:nth-child(n+3) { border-bottom: 0; }
  .access__item + .access__item::before { display: none; }
  .access__item:nth-child(even) { border-left: 1px solid var(--jp-border); }

  .fest-photos__grid {
    height: auto;
    grid-template-columns: 1fr 1fr;
    grid-template-areas: "wide wide" "a b" "poster poster";
  }
  .fest-photos__item--wide { grid-area: wide; aspect-ratio: 16 / 10; }
  .fest-photos__item:not(.fest-photos__item--wide) { aspect-ratio: 1 / 1; }
  .fest-photos__poster { grid-area: poster; aspect-ratio: 16 / 9; }
  .fest-photos__poster img { object-position: 50% 0; }
}

/* Mobile */
@media (max-width: 639px) {
  :root { --header-h: 68px; --gutter: 18px; }
  .brand img { height: 48px; }
  .header-emergency { display: none; }
  .header-call {
    display: grid; place-items: center; margin-left: auto;
    width: 44px; height: 44px; border-radius: 50%;
    background: var(--jp-purple); color: #fff; text-decoration: none;
    box-shadow: 0 6px 16px -8px rgba(75, 36, 100, .6);
  }
  .header-call .icon { font-size: 20px; }
  .nav-toggle { width: 44px; height: 44px; }

  .hero { height: min(640px, calc(100svh - var(--header-h) - 40px)); min-height: 540px; }
  .hero__media img { object-position: 62% 50%; }
  .hero::before {
    background:
      linear-gradient(0deg, rgba(20, 12, 26, .72) 0%, rgba(20, 12, 26, .35) 45%, rgba(20, 12, 26, 0) 70%),
      linear-gradient(180deg, rgba(20, 12, 26, .25) 0%, rgba(20, 12, 26, 0) 22%);
  }
  .hero__inner { flex-direction: column; align-items: flex-start; justify-content: flex-end; gap: 0; }
  .hero__words {
    order: -1; display: flex; flex-wrap: wrap; gap: 4px 0; text-align: left;
    font-size: 10.5px; letter-spacing: .2em; line-height: 1.4; margin-bottom: 18px; padding: 0;
  }
  .hero__words li + li::before { content: "·"; margin: 0 .55em; opacity: .8; }
  .hero__words::after { display: none; }
  .hero__title { font-size: clamp(46px, 13vw, 56px); }
  .hero__lead { font-size: 16.5px; margin: 14px 0 24px; }
  .hero .btn { padding: 14px 20px; font-size: 14.5px; }

  .access__icon { width: 64px; height: 64px; margin-bottom: 14px; }
  .access__icon .icon { font-size: 28px; }
  .access__title { font-size: 13px; letter-spacing: .05em; }
  .access__text { font-size: 13.5px; margin-bottom: 16px; }

  .section-head { flex-direction: column; align-items: flex-start; gap: 10px; margin-bottom: 22px; }
  .section-head .link-caps { margin-bottom: 0; }

  .fest {
    grid-template-columns: var(--gutter) minmax(0, 1fr) var(--gutter);
    grid-template-areas:
      ".     .     ."
      ".     head  ."
      ".     meta  ."
      "photo photo photo"
      ".     acts  ."
      ".     place ."
      ".     cta   ."
      ".     .     .";
    grid-template-rows: 40px auto auto auto auto auto auto 44px;
    column-gap: 0;
  }
  .fest__logo { width: 96px; margin-bottom: 18px; }
  .fest__edition { font-size: 14px; letter-spacing: .2em; }
  .fest__title { font-size: clamp(50px, 14.5vw, 62px); }
  .fest__tagline { font-size: 23px; }
  .fest__meta { padding-top: 26px; margin-left: 0; display: flex; flex-wrap: wrap; align-items: center; gap: 14px 16px; }
  .fest__date {
    width: auto; grid-auto-flow: column; align-items: center; gap: 12px; padding: 12px 16px;
  }
  .fest__date-num { font-size: 54px; margin: 0; }
  .fest__date-day, .fest__date-month { display: block; }
  .fest__date-time { margin-top: 0; }
  .fest__date { grid-template-columns: auto auto; grid-template-rows: auto auto; grid-auto-flow: row; justify-items: start; text-align: left; column-gap: 12px; row-gap: 4px; }
  .fest__date-num { grid-row: 1 / 3; }
  .fest__date-day { grid-column: 2; align-self: end; }
  .fest__date-month { grid-column: 2; align-self: start; font-size: 16px; }
  .fest__date-time { grid-column: 1 / -1; justify-self: stretch; text-align: center; margin-top: 8px; padding: 7px 10px; }
  .fest__free { position: static; transform: rotate(-6deg); font-size: 14px; padding: 12px 16px; }
  .fest__photo { margin-top: 30px; aspect-ratio: 4 / 3.4; }
  .fest__photo img { object-position: 80% 40%; }
  .fest__acts { grid-template-columns: repeat(3, minmax(0, 1fr)); row-gap: 24px; column-gap: 8px; }
  .fest__acts .icon { font-size: 34px; }
  .fest__acts li { font-size: 11px; }
  .fest__cta .btn { width: 100%; justify-content: center; }
  .mg--1 { width: 110px; height: 110px; left: -46px; top: 30%; }
  .mg--3 { display: none; }
  .mg--4 { display: none; }

  .fest-photos { padding: 18px 0 28px; }
  .fest-photos__grid { gap: 10px; }

  .closing { padding: 56px 0 60px; }
  .closing__quote p { font-size: 29px; }
  .pillars { flex-direction: column; gap: 14px; }
  .pillars__icon { width: 50px; height: 50px; }
  .pillars__icon .icon { font-size: 24px; }

  .site-footer__grid { grid-template-columns: 1fr 1fr; gap: 34px 20px; }
  .site-footer__brand img { width: 180px; }
  .site-footer__col--contact { grid-column: 1 / -1; order: 3; }
  .site-footer__bar-inner { flex-direction: column; align-items: flex-start; gap: 4px; }
}

/* =========================================================
   ANCHOS (referencia: danieliweb, marco de 1440px)
   Fondos, hero y bandas de color: a todo el ancho del viewport.
   Contenido en desktop: margen del 4.5 % por lado, con tope en el
   ancho que tendría dentro de un marco de 1440px (1440 × .91 ≈ 1310px).
   ========================================================= */
:root { --frame: 1440px; }
@media (min-width: 1024px) {
  .page { --gutter: 4.5%; --container-max: calc(var(--frame) * .91); }
  .site-header__inner { width: min(91%, calc(var(--frame) * .91)); }
}

/* =========================================================
   FESTIVAL · DESKTOP: fondo a todo el ancho, contenido (info + foto) en 1240px
   ========================================================= */
@media (min-width: 1024px) {
  .fest {
    --fest-side: max(var(--gutter), (100% - var(--container-max)) / 2);
    --fest-photo: .44;
    column-gap: 0;
    grid-template-columns:
      var(--fest-side)
      auto
      minmax(0, 1fr)
      calc((100% - 2 * var(--fest-side)) * var(--fest-photo))
      var(--fest-side);
    grid-template-areas:
      ".  .      .     photo ."
      ".  head   meta  photo ."
      ".  place  place photo ."
      ".  acts   acts  photo ."
      ".  cta    cta   photo ."
      ".  .      .     photo .";
  }
}
@media (min-width: 1024px) and (max-width: 1279px) {
  .fest { --fest-photo: .40; }
}
