/* ==========================================================================
   Fiesta de Navidad (pages/xmas/index.html)
   Lives inside the shared shell (sidenav, topbar, contact, footer). Reuses
   .page-title-head and the tokens in custom.css :root (--brand-red,
   --charcoal-deep, --radius-card, --shadow-soft). Brand red stays the single
   accent; the festive part is the night-sky hero with the falling snow that
   the old template had (same three snow sprites, pages/xmas/images/s1-s3.png)
   and the "Feliz Navidad" script.
   ========================================================================== */

.xm-wrap {
  max-width: 980px;
  margin: 0 auto;
}

/* ── Hero: night sky + snow ─────────────────────────────────────────────── */
.xm-hero {
  position: relative;
  overflow: hidden;
  isolation: isolate;
  border-radius: var(--radius-card, 14px);
  background:
    radial-gradient(120% 90% at 85% 0%, rgba(237, 85, 101, 0.38) 0%, rgba(237, 85, 101, 0) 55%),
    radial-gradient(90% 70% at 0% 100%, rgba(237, 85, 101, 0.18) 0%, rgba(237, 85, 101, 0) 60%),
    linear-gradient(165deg, #2f4050 0%, #1b2530 70%, #141c24 100%);
  color: #fff;
  text-align: center;
  padding: clamp(2.25rem, 6vw, 4rem) 1.25rem clamp(2rem, 5vw, 3rem);
  margin-bottom: 2rem;
  box-shadow: var(--shadow-soft, 0 10px 28px rgba(35, 48, 60, 0.14));
}

/* The old page's snow: three sprite layers drifting at different speeds. */
.xm-snow {
  position: absolute;
  inset: 0;
  z-index: -1;
  background-image:
    url(../../pages/xmas/images/s1.png),
    url(../../pages/xmas/images/s2.png),
    url(../../pages/xmas/images/s3.png);
  animation: xm-snow 14s linear infinite;
  opacity: 0.9;
  pointer-events: none;
}
@keyframes xm-snow {
  0%   { background-position: 0 0, 0 0, 0 0; }
  50%  { background-position: 500px 500px, 100px 200px, -100px 150px; }
  100% { background-position: 500px 1000px, 200px 400px, -100px 300px; }
}
/* Faint enso, same gesture as .page-hero, in white */
.xm-hero::after {
  content: "";
  position: absolute;
  z-index: -1;
  width: 360px;
  height: 360px;
  right: -120px;
  top: -160px;
  border: 2px solid rgba(255, 255, 255, 0.12);
  border-left-color: transparent;
  border-radius: 50%;
  transform: rotate(-30deg);
  pointer-events: none;
}

.xm-hero-logo {
  width: clamp(64px, 9vw, 88px);
  height: auto;
  margin-bottom: 0.75rem;
}
.xm-script {
  font-family: "Great Vibes", cursive;
  font-weight: 400;
  font-size: clamp(2.6rem, 6vw + 0.5rem, 4.4rem);
  line-height: 1.05;
  margin: 0;
  color: #fff;
  text-shadow: 0 2px 18px rgba(0, 0, 0, 0.35);
}
.xm-flake-rule {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.75rem;
  margin: 0.6rem auto 0.9rem;
  color: rgba(255, 255, 255, 0.85);
  font-size: 0.95rem;
}
.xm-flake-rule::before,
.xm-flake-rule::after {
  content: "";
  width: 56px;
  height: 1px;
  background: rgba(255, 255, 255, 0.45);
}
.xm-hero h1 {
  font-family: "Anton", "Arial Narrow", Impact, sans-serif;
  font-weight: 400;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  font-size: clamp(1.5rem, 2.4vw + 0.8rem, 2.4rem);
  margin: 0;
  color: #fff;
}
.xm-when {
  margin: 0.55rem 0 0;
  font-size: clamp(0.95rem, 1vw + 0.7rem, 1.1rem);
  color: rgba(255, 255, 255, 0.86);
}
.xm-when .fa { color: var(--brand-red, #ed5565); margin: 0 0.3rem 0 0.9rem; }
.xm-when .fa:first-child { margin-left: 0; }

/* Countdown: four glass tiles */
.xm-count {
  display: inline-grid;
  grid-template-columns: repeat(4, minmax(64px, 88px));
  gap: 0.6rem;
  margin: 1.6rem auto 0;
  padding: 0;
  list-style: none;
}
.xm-count li {
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.16);
  border-radius: 12px;
  padding: 0.65rem 0.25rem 0.55rem;
  backdrop-filter: blur(2px);
}
.xm-count b {
  display: block;
  font-family: "Anton", "Arial Narrow", Impact, sans-serif;
  font-weight: 400;
  font-size: clamp(1.6rem, 3vw + 0.6rem, 2.3rem);
  line-height: 1.1;
  font-variant-numeric: tabular-nums;
}
.xm-count span {
  display: block;
  font-size: 0.78rem;
  letter-spacing: 0.04em;
  color: rgba(255, 255, 255, 0.75);
}
@media (max-width: 380px) {
  .xm-count { grid-template-columns: repeat(4, 1fr); gap: 0.4rem; width: 100%; }
}
.xm-cta {
  margin-top: 1.6rem;
}
.xm-cta .btn { padding: 0.6rem 1.4rem; font-weight: 600; }
.xm-cta .btn .fa { margin-right: 0.35rem; }
.xm-started {
  margin: 1.4rem 0 0;
  font-size: 1.05rem;
  color: #fff;
}

/* ── Section headings: the site's indoor voice (as in Tu primera clase) ── */
.xm-h2 {
  font-size: clamp(1.2rem, 1vw + 0.9rem, 1.45rem);
  font-weight: 600;
  color: var(--charcoal-deep, #23303c);
  margin: 0 0 1rem;
}
.xm-h2::before {
  content: "";
  display: block;
  width: 36px;
  height: 3px;
  border-radius: 2px;
  background: var(--brand-red, #ed5565);
  margin-bottom: 0.7rem;
}
.xm-section { margin-bottom: 2.5rem; }
.xm-lede {
  max-width: 65ch;
  font-size: 0.98rem;
  line-height: 1.7;
  color: #4d5862;
}

/* ── Horario: a real sequence, so an ordered list with the time as marker ─ */
.xm-plan {
  list-style: none;
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1rem;
  padding: 0;
  margin: 0;
}
.xm-plan li {
  background: #fff;
  border: 1px solid #e7eaee;
  border-radius: var(--radius-card, 14px);
  padding: 1.1rem 1rem 1rem;
}
.xm-time {
  display: block;
  font-family: "Anton", "Arial Narrow", Impact, sans-serif;
  font-size: 1.6rem;
  line-height: 1;
  color: var(--brand-red, #ed5565);
  margin-bottom: 0.5rem;
}
.xm-time small { font-family: "Open Sans", sans-serif; font-size: 0.8rem; margin-left: 0.15rem; }
.xm-plan strong {
  display: block;
  font-size: 1rem;
  font-weight: 600;
  color: var(--charcoal-deep, #23303c);
  margin-bottom: 0.3rem;
}
.xm-plan li > span:last-child {
  display: block;
  font-size: 0.92rem;
  line-height: 1.55;
  color: #4d5862;
}
@media (max-width: 991.98px) {
  .xm-plan { grid-template-columns: 1fr; gap: 0; }
  .xm-plan li {
    display: grid;
    grid-template-columns: 6.5rem 1fr;
    column-gap: 0.75rem;
    border: 0;
    border-radius: 0;
    background: transparent;
    border-top: 1px solid #e7eaee;
    padding: 0.9rem 0;
  }
  .xm-plan li:last-child { border-bottom: 1px solid #e7eaee; }
  .xm-time { grid-row: span 2; margin: 0.1rem 0 0; }
}

/* ── Potluck: two quiet cards ───────────────────────────────────────────── */
.xm-pair {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1.25rem;
}
@media (max-width: 767.98px) {
  .xm-pair { grid-template-columns: 1fr; }
}
.xm-card {
  background: #fff;
  border: 1px solid #e7eaee;
  border-radius: var(--radius-card, 14px);
  padding: 1.5rem 1.5rem 1.25rem;
  box-shadow: 0 1px 4px rgba(130, 143, 163, 0.15);
}
.xm-card .xm-h2 { font-size: 1.15rem; }
.xm-list {
  list-style: none;
  padding: 0;
  margin: 0;
}
.xm-list li {
  display: flex;
  gap: 0.75rem;
  align-items: flex-start;
  padding: 0.45rem 0;
  font-size: 0.95rem;
  line-height: 1.55;
}
.xm-list li + li { border-top: 1px solid #f0f2f5; }
.xm-ico {
  flex: 0 0 1.1rem;
  margin-top: 0.22rem;
  text-align: center;
  color: var(--brand-red, #ed5565);
}

/* ── Registro: the form sits on the page, not in a popup ───────────────── */
.xm-form-card {
  background: #fff;
  border: 1px solid #e7eaee;
  border-radius: var(--radius-card, 14px);
  padding: 0.5rem;
  box-shadow: var(--shadow-soft, 0 10px 28px rgba(35, 48, 60, 0.14));
}
.xm-form-card iframe {
  display: block;
  width: 100%;
  height: 760px;
  border: 0;
  border-radius: 10px;
  background: transparent;
}
@media (max-width: 575.98px) {
  .xm-form-card iframe { height: 860px; }
}
.xm-closed {
  background: #f5f6f8;
  border-radius: var(--radius-card, 14px);
  padding: 1.5rem;
  text-align: center;
  color: #3f4a54;
}

/* ── Mapa ───────────────────────────────────────────────────────────────── */
.xm-map {
  aspect-ratio: 16 / 9;
  border-radius: var(--radius-card, 14px);
  overflow: hidden;
  border: 1px solid #e7eaee;
  background: #f5f6f8;
}
.xm-map iframe { display: block; width: 100%; height: 100%; border: 0; }
@media (max-width: 575.98px) {
  .xm-map { aspect-ratio: 4 / 3; }
}
.xm-map-note {
  margin: 0.6rem 0 0;
  font-size: 0.92rem;
  color: #68737e;
}

@media (prefers-reduced-motion: reduce) {
  .xm-snow { animation: none; }
}
