/* === Section Base === */
.section {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
  overflow: hidden;
}

.section__inner {
  width: 100%;
  max-width: var(--max-width);
  margin: 0 auto;
  padding: var(--section-padding);
}

/* === Section Colors === */
.section--hero {
  background-color: var(--color-blue);
  color: var(--color-text-light);
}

.section--hero::before {
  content: '';
  position: absolute;
  inset: 0;
  background-image: linear-gradient(180deg, rgba(0, 45, 145, 0.65) 0%, rgba(0, 45, 145, 0.8) 100%),
                     url('../img/zen_2024-09-13.webp');
  background-size: cover;
  background-position: center;
  opacity: 0;
  animation: heroImageFadeIn 2s var(--ease-out) 0.3s forwards;
  z-index: 0;
}

.section--about {
  background-color: var(--color-gray);
  color: var(--color-text-dark);
}

.section--classes {
  background-color: var(--color-teal);
  color: var(--color-text-light);
}

.section--classes::before {
  content: '';
  position: absolute;
  inset: 0;
  background-image: url('../img/zen_piedras.jpg');
  background-size: cover;
  background-position: center;
  filter: grayscale(100%);
  z-index: 0;
}

.section--classes::after {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(0, 77, 77, 0.75) 0%, rgba(0, 77, 77, 0.85) 100%);
  z-index: 0;
}

.section--classes .section__inner {
  position: relative;
  z-index: 1;
}

.section--schedule {
  background-color: var(--color-gray);
  color: var(--color-text-dark);
}

.section--events {
  background-color: var(--color-sage);
  color: var(--color-text-light);
}

.section--team {
  background-color: var(--color-gray);
  color: var(--color-text-dark);
}

.section--testimonials {
  background-color: var(--color-warm);
  color: var(--color-text-light);
}

.section--packages {
  background-color: var(--color-gray);
  color: var(--color-text-dark);
}

/* === WooCommerce page sections (cart, checkout, account) === */
.section--wc-header {
  background-color: var(--color-blue);
  color: var(--color-text-light);
  min-height: 45vh;
}

.section--wc-body {
  background-color: var(--color-gray);
  color: var(--color-text-dark);
  min-height: auto;
  padding-bottom: var(--space-24);
}

.section--contact {
  background-color: var(--color-blue);
  color: var(--color-text-light);
}

/* === Section Header (reusable) === */
.section__header {
  text-align: center;
  margin-bottom: var(--space-12);
}

.section__label {
  margin-bottom: var(--space-4);
}

/* === Split Layout === */
.split {
  display: flex;
  align-items: center;
  gap: var(--space-16);
}

.split__left,
.split__right {
  flex: 1;
}

/* === Hero Specifics === */
.hero__center {
  text-align: center;
  position: relative;
  z-index: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: var(--space-6);
}

.hero__logo {
  height: clamp(80px, 12vw, 160px);
  width: auto;
}

.hero__tagline {
  color: rgba(240, 240, 240, 0.5);
}

/* === Footer === */
.footer {
  background: var(--color-black);
  color: var(--color-text-light);
  padding: var(--space-10) var(--space-8);
}

.footer__inner {
  max-width: var(--max-width);
  margin: 0 auto;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.footer__left {
  display: flex;
  align-items: center;
  gap: var(--space-4);
}

.footer__logo {
  height: 18px;
  width: auto;
  opacity: 0.6;
}

.footer__copyright {
  font-family: var(--font-body);
  font-size: var(--text-xs);
  color: rgba(240, 240, 240, 0.3);
}

.footer__right {
  display: flex;
  align-items: center;
  gap: var(--space-8);
}

.footer__links {
  display: flex;
  gap: var(--space-6);
  list-style: none;
  padding: 0;
  margin: 0;
}

.footer__links li {
  list-style: none;
  padding: 0;
  margin: 0;
}

.footer__links a {
  font-family: var(--font-body);
  font-size: var(--text-xs);
  color: rgba(240, 240, 240, 0.4);
  transition: color var(--duration-fast) var(--ease-out);
}

.footer__links a:hover {
  color: rgba(240, 240, 240, 0.8);
}

.footer__social {
  display: flex;
  gap: var(--space-4);
}

.footer__social a {
  font-family: var(--font-body);
  font-size: var(--text-xs);
  color: rgba(240, 240, 240, 0.4);
  transition: color var(--duration-fast) var(--ease-out);
}

.footer__social a:hover {
  color: rgba(240, 240, 240, 0.8);
}

/* === About Photo === */
.about__photo {
  border-radius: 8px;
  overflow: hidden;
  aspect-ratio: 4/5;
}

.about__photo-placeholder {
  width: 100%;
  height: 100%;
  background: linear-gradient(135deg, #ccc 0%, #aaa 100%);
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: var(--font-body);
  font-size: var(--text-xs);
  color: rgba(0, 0, 0, 0.25);
  letter-spacing: 0.1em;
}

.about__photo img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  filter: grayscale(100%);
}

/* === Membresías Page === */
/* ── Eventos page ── */
.section--eventos-header {
  min-height: 45vh;
  background-color: var(--color-blue);
  color: var(--color-text-light);
}

.section--eventos-body {
  background-color: var(--color-gray);
  color: var(--color-text-dark);
  min-height: auto;
}

.section--membresia-header {
  min-height: 45vh;
  background-color: var(--color-blue);
  color: var(--color-text-light);
}

.section--membresia-products {
  background-color: var(--color-gray);
  color: var(--color-text-dark);
  min-height: auto;
}

.section--general-header {
  min-height: 20vh;
  background-color: var(--color-blue);
  color: var(--color-text-light);
}

.section--general-body {
  background-color: var(--color-white);
  color: var(--color-text-dark);
  min-height: auto;
  padding-bottom: var(--space-24);
}

.membresia-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: var(--space-6);
  max-width: 960px;
  margin: 0 auto;
}

.membresia-notice {
  font-family: var(--font-body);
  font-size: var(--text-xs);
  letter-spacing: 0.1em;
  text-align: center;
  color: var(--color-text-muted);
  border: 1px solid var(--color-border-light);
  border-radius: 6px;
  padding: var(--space-4) var(--space-8);
  margin-bottom: var(--space-8);
  max-width: 480px;
  margin-left: auto;
  margin-right: auto;
}

/* ── Horarios page ── */
.section--horarios-header {
  min-height: 45vh;
  background-color: var(--color-blue);
  color: var(--color-text-light);
}

.section--horarios {
  background-color: var(--color-blue);
  color: var(--color-text-light);
  min-height: auto;
  padding: 0 0 var(--space-16);
  display: block;
  overflow-x: hidden;
}

.membresia-scroll-hint {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: var(--space-2);
  margin-top: var(--space-12);
}

.membresia-scroll-hint__line {
  width: 1px;
  height: 28px;
  background: rgba(240, 240, 240, 0.2);
}

/* ══════════════════════════════════════════════════════
   SEO Content Page (template-seo-page.php)
   ══════════════════════════════════════════════════════ */

/* ── Background variants ───────────────────────────────────── */
.section--seo-hero,
.section--seo-dark,
.section--seo-cta {
  background-color: var(--color-blue);
  color: var(--color-text-light);
}

.section--seo-light {
  background-color: var(--color-gray);
  color: var(--color-text-dark);
}

/* ── Hero ─────────────────────────────────────────────────────── */
.section--seo-hero {
  min-height: 65vh;
  align-items: flex-end;
  padding-bottom: var(--space-20);
}

/* When a hero image is set, use it as a background with a deep-blue overlay.
   The --hero-bg custom property is injected inline by template-seo-page.php.
   The ::before pseudo-element creates the colour overlay so the image and
   overlay are always in sync, regardless of CSS stacking. */
.section--seo-hero--has-image {
  background-color: transparent;
  background-image: var(--hero-bg);
  background-size: cover;
  background-position: center top;
  position: relative;
}

.section--seo-hero--has-image::before {
  content: '';
  position: absolute;
  inset: 0;
  background-color: rgba(0, 45, 145, 0.70);
  z-index: 0;
}

.section--seo-hero--has-image .section__inner,
.section--seo-hero--has-image .seo-hero__content {
  position: relative;
  z-index: 1;
}

.seo-hero__content {
  max-width: 820px;
}

.seo-hero__eyebrow {
  color: rgba(240, 240, 240, 0.5);
  margin-bottom: var(--space-4);
}

.seo-hero__title {
  color: var(--color-text-light);
  margin-bottom: var(--space-6);
}

.seo-hero__intro {
  max-width: 680px;
  color: rgba(240, 240, 240, 0.8);
  line-height: 1.9;
}

/* ── Content sections (general) ────────────────────────────────── */
.section--seo-light,
.section--seo-dark {
  min-height: auto;
}

.seo-section__title {
  text-align: left;
}

.section--seo-dark .seo-section__title {
  color: var(--color-text-light);
}

.section--seo-light .seo-section__title {
  color: var(--color-text-dark);
}

.seo-section__intro {
  max-width: 760px;
  margin-bottom: var(--space-10);
}

.seo-section__body {
  max-width: 760px;
}

/* ── Sub-sections (H3 blocks) ──────────────────────────────────── */
.seo-subsections {
  display: flex;
  flex-direction: column;
  gap: var(--space-12);
  margin-top: var(--space-8);
}

.seo-subsection {
  max-width: 760px;
  border-left: 2px solid rgba(0, 45, 145, 0.18);
  padding-left: var(--space-8);
}

.section--seo-dark .seo-subsection {
  border-left-color: rgba(240, 240, 240, 0.18);
}

.seo-subsection__title {
  font-size: clamp(var(--text-base), 2vw, var(--text-lg));
  letter-spacing: var(--tracking-heading);
  margin-bottom: var(--space-4);
  color: inherit;
}

.seo-subsection__body {
  color: inherit;
  opacity: 0.85;
}

.seo-subsection__suitable {
  font-family: var(--font-body);
  font-size: var(--text-xs);
  color: var(--color-text-muted);
  margin-top: var(--space-4);
  letter-spacing: 0.02em;
}

.section--seo-dark .seo-subsection__suitable {
  color: rgba(240, 240, 240, 0.55);
}

/* ── Content section image split (text left, image right) ─────── */
.seo-section-split {
  display: grid;
  grid-template-columns: 55fr 45fr;
  gap: var(--space-16);
  align-items: center;
}

.seo-section-split__text {
  /* inherits section text color */
}

.seo-section-split__image {
  position: relative;
}

.seo-section-split__image-wrap {
  position: relative;
  overflow: hidden;
  border-radius: 2px;
}

.seo-section-split__image-wrap img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  filter: grayscale(100%);
}

.seo-section-split__overlay {
  position: absolute;
  inset: 0;
  mix-blend-mode: multiply;
  pointer-events: none;
}

/* On mobile: single column, image stacks below text */
@media (max-width: 767px) {
  .seo-section-split {
    grid-template-columns: 1fr;
  }

  .seo-section-split__image {
    order: 2;
  }

  .seo-section-split__text {
    order: 1;
  }
}

/* ── Subsection color blocks (H3 sections rendered as full-width rows) */
.seo-subsection-block {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
}

.seo-subsection-block__content {
  max-width: 760px;
  width: 100%;
}

.seo-subsection-block__title {
  text-align: left;
  margin-bottom: var(--space-8);
}

.section--seo-dark .seo-subsection-block__title {
  color: var(--color-text-light);
}

.section--seo-light .seo-subsection-block__title {
  color: var(--color-text-dark);
}

.seo-subsection-block__body {
  color: inherit;
  opacity: 0.85;
}

/* ── Benefits ──────────────────────────────────────────────────── */
.section--seo-sage {
  background-color: var(--color-sage);
}

.section--seo-sage .section__eyebrow,
.section--seo-sage .section__title,
.section--seo-sage .seo-benefit__label {
  color: #F0F0F0;
}

.section--seo-sage .seo-benefit__desc {
  color: rgba(240, 240, 240, 0.85);
}

.section--seo-sage .seo-section__title {
  color: var(--color-text-light);
}

.seo-benefits {
  display: flex;
  flex-direction: column;
  gap: var(--space-8);
  max-width: 760px;
  margin: 0 auto 0 0;
}

.seo-benefit__label {
  font-family: var(--font-body);
  font-size: var(--text-sm);
  font-weight: 700;
  color: var(--color-blue);
  margin-bottom: var(--space-2);
  letter-spacing: 0.02em;
}

.seo-benefit__desc {
  color: var(--color-text-muted);
  max-width: 640px;
}

/* ── Benefits split (image + list two-column) ─────────────────── */
.seo-benefits-split {
  display: grid;
  grid-template-columns: 45fr 55fr;
  gap: var(--space-16);
  align-items: start;
}

.seo-benefits-split__image {
  position: relative;
}

.seo-benefits-split__image-wrap {
  position: relative;
  overflow: hidden;
  border-radius: 2px;
}

.seo-benefits-split__image-wrap img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  filter: grayscale(100%);
}

.seo-benefits-split__overlay {
  position: absolute;
  inset: 0;
  background-color: rgba(135, 155, 125, 0.60); /* sage #879B7D at 60% */
  mix-blend-mode: multiply;
  pointer-events: none;
}

.seo-benefits-split__content .seo-benefits {
  max-width: 100%;
  margin: 0;
}

/* On mobile: stack image below the list */
@media (max-width: 767px) {
  .seo-benefits-split {
    grid-template-columns: 1fr;
  }

  .seo-benefits-split__image {
    order: 2;
  }

  .seo-benefits-split__content {
    order: 1;
  }
}

/* ── Logistics ─────────────────────────────────────────────────── */
.seo-logistics__body {
  max-width: 760px;
  color: rgba(240, 240, 240, 0.85);
}

.seo-logistics__body p {
  margin-bottom: var(--space-4);
}

/* ── FAQ ───────────────────────────────────────────────────────── */
.seo-faq {
  max-width: 760px;
  margin: 0 auto 0 0;
  border-top: 1px solid var(--color-border-light);
}

.seo-faq__item {
  border-bottom: 1px solid var(--color-border-light);
}

.seo-faq__question {
  display: flex;
  justify-content: space-between;
  align-items: center;
  width: 100%;
  padding: var(--space-6) 0;
  font-family: var(--font-body);
  font-weight: 500;
  font-size: var(--text-sm);
  color: var(--color-text-dark);
  background: transparent;
  border: none;
  cursor: pointer;
  text-align: left;
  gap: var(--space-4);
  transition: color var(--duration-fast) var(--ease-out);
}

.seo-faq__question:hover {
  color: var(--color-blue);
}

.seo-faq__icon {
  font-size: var(--text-lg);
  font-weight: 300;
  flex-shrink: 0;
  transition: transform var(--duration-fast) var(--ease-out);
  color: var(--color-blue);
}

.seo-faq__question[aria-expanded="true"] .seo-faq__icon {
  transform: rotate(45deg);
}

.seo-faq__answer {
  padding-bottom: var(--space-6);
  color: var(--color-text-muted);
  line-height: 1.8;
}

/* ── CTA ───────────────────────────────────────────────────────── */
.section--seo-cta {
  min-height: 55vh;
}

.seo-cta__inner {
  text-align: center;
  max-width: 720px;
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: var(--space-6);
}

.seo-cta__headline {
  color: var(--color-text-light);
}

.seo-cta__body {
  color: rgba(240, 240, 240, 0.75);
  max-width: 580px;
  text-align: center;
}

.seo-cta__secondary {
  margin-top: var(--space-2);
}

/* ── Responsive ─────────────────────────────────────────────────── */
@media ( max-width: 768px ) {
  .section--seo-hero {
    min-height: auto;
    padding-top: calc(var(--nav-height) + var(--space-16));
    align-items: flex-start;
  }

  .seo-subsections {
    gap: var(--space-10);
  }

  .seo-subsection {
    border-left: none;
    padding-left: 0;
    border-top: 1px solid rgba(0, 45, 145, 0.12);
    padding-top: var(--space-6);
  }

  .section--seo-dark .seo-subsection {
    border-top-color: rgba(240, 240, 240, 0.12);
  }
}
