/*
 * DCC 2026 event follow-up page (/dcc-2026/).
 * Enqueued only on that page (see my_theme_enqueue_styles in functions.php),
 * and every rule is additionally scoped under body.page-dcc-2026 .entry-content
 * with element-qualified selectors (p.dm-dcc-subhead, h2, h3.dm-dcc-give-h3) so they
 * match the (0,3,2) specificity of pages.css's generic `body.page:not(.home) .entry-content p/h2/h3`
 * rules and win by source order.
 *
 * The DOUBLE MY GIFT buttons intentionally inherit the site's shared button
 * look from pages.css (body.page:not(.home) .entry-content .wp-block-button__link:
 * rust background, cream text, pill radius, gold on hover). Only spacing and
 * casing are adjusted here.
 */

/* ---------- Section containers ---------- */
body.page-dcc-2026 .entry-content .dm-dcc-hero,
body.page-dcc-2026 .entry-content .dm-dcc-video-section {
  max-width: 1100px;
  margin: 0 auto;
  text-align: center;
}

body.page-dcc-2026 .entry-content .dm-dcc-hero {
  padding: 1rem 0 2.5rem;
}

body.page-dcc-2026 .entry-content .dm-dcc-video-section {
  padding: 2rem 0 3.5rem;
}

/* ---------- Hero ---------- */
body.page-dcc-2026 .entry-content .dm-dcc-hero h1 {
  font-family: var(--garamond);
  font-weight: 400;
  font-size: clamp(2.2rem, 5vw, 3.4rem);
  line-height: 1.15;
  margin: 0 0 0.5em;
}

body.page-dcc-2026 .entry-content p.dm-dcc-subhead {
  text-wrap: balance; /* even wraps on phones; ignored by older browsers */
  color: var(--dm-color-navy);
  font-weight: 700;
  font-size: clamp(1.15rem, 2.4vw, 1.5rem);
  line-height: 1.3;
  max-width: 34em;
  margin: 0 auto 0.75em;
}

body.page-dcc-2026 .entry-content p.dm-dcc-intro,
body.page-dcc-2026 .entry-content p.dm-dcc-chapter-intro {
  text-wrap: balance; /* avoids a lone last word; ignored by older browsers */
  font-size: clamp(1rem, 1.8vw, 1.15rem);
  line-height: 1.5;
  max-width: 40em;
  margin: 0 auto 1.5em;
}

/* ---------- Video ---------- */
body.page-dcc-2026 .entry-content .dm-dcc-video-section h2 {
  font-family: var(--garamond);
  font-weight: 400;
  font-size: clamp(1.6rem, 3.5vw, 2.25rem);
  line-height: 1.2;
  margin: 0 0 1em;
  padding-bottom: 0;
  border-bottom: 0;
}

body.page-dcc-2026 .entry-content .dm-dcc-video {
  position: relative;
  aspect-ratio: 16 / 9;
  max-width: 1100px;
  margin: 0 auto 1.5rem;
  background: #000;
}

body.page-dcc-2026 .entry-content .dm-dcc-video iframe {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  border: 0;
}

@supports not (aspect-ratio: 16 / 9) {
  body.page-dcc-2026 .entry-content .dm-dcc-video {
    height: 0;
    padding-bottom: 56.25%;
  }
}

/* ---------- Chapter buttons (seek the embedded player; fall back to Vimeo links) ---------- */
/* `ol.` qualifier: pages.css's generic `.entry-content ol` (0,3,2) otherwise adds left padding. */
body.page-dcc-2026 .entry-content ol.dm-dcc-chapters {
  list-style: none;
  display: flex;
  flex-direction: column;
  align-items: stretch;
  gap: 0.75rem;
  max-width: 34rem;
  margin: 0 auto 2rem;
  padding: 0;
}

body.page-dcc-2026 .entry-content ol.dm-dcc-chapters li {
  margin: 0;
  padding: 0;
}

body.page-dcc-2026 .entry-content a.dm-dcc-chapter {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.6rem;
  width: 100%;
  min-height: 48px;
  padding: 0.7rem 1.5rem;
  border: 2px solid var(--dm-color-navy);
  border-radius: 50px;
  background: #fff;
  color: var(--dm-color-navy);
  font-family: 'Public Sans', 'Cabin', sans-serif;
  font-size: 1rem;
  font-weight: 600;
  letter-spacing: 0.02em;
  line-height: 1.3;
  text-align: center;
  text-decoration: none;
  transition: background-color 0.2s ease, color 0.2s ease;
}

/* Play glyph, drawn in the current text color so it flips with hover. */
body.page-dcc-2026 .entry-content a.dm-dcc-chapter::before {
  content: '';
  flex: 0 0 auto;
  width: 0;
  height: 0;
  border-style: solid;
  border-width: 6px 0 6px 10px;
  border-color: transparent transparent transparent currentColor;
}

body.page-dcc-2026 .entry-content a.dm-dcc-chapter:hover,
body.page-dcc-2026 .entry-content a.dm-dcc-chapter:focus-visible {
  background: var(--dm-color-navy);
  color: #fff;
  text-decoration: none;
}

body.page-dcc-2026 .entry-content a.dm-dcc-chapter:focus-visible {
  outline: 3px solid var(--dm-color-gold);
  outline-offset: 3px;
}

/* Chapter currently selected / playing (set by dcc-2026.js): navy fill, gold border. */
body.page-dcc-2026 .entry-content a.dm-dcc-chapter.is-active {
  background: var(--dm-color-navy);
  border-color: var(--dm-color-gold);
  color: #fff;
}

@media (min-width: 768px) {
  body.page-dcc-2026 .entry-content ol.dm-dcc-chapters {
    flex-direction: row;
    flex-wrap: wrap;
    justify-content: center;
    max-width: none;
  }

  body.page-dcc-2026 .entry-content ol.dm-dcc-chapters li {
    flex: 0 1 auto;
  }

  body.page-dcc-2026 .entry-content a.dm-dcc-chapter {
    width: auto;
  }
}

/* ---------- DOUBLE MY GIFT CTA ---------- */
body.page-dcc-2026 .entry-content .dm-dcc-cta-row {
  margin: 0.5rem 0 0;
}

body.page-dcc-2026 .entry-content .dm-dcc-cta .wp-block-button__link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 48px;
  text-transform: uppercase;
  letter-spacing: 0.08em;
}

/* ---------- Giving section ---------- */
/* The site header is not sticky on inner pages (parent .site-header is
   position: relative; the child only repositions it on body.home), so no
   header-height offset is needed; this is breathing room only. */
body.page-dcc-2026 .entry-content #give {
  scroll-margin-top: 24px;
}

/* #give receives focus from the DOUBLE MY GIFT script. No outline override here:
   browsers show their focus ring only for keyboard activation (:focus-visible),
   which is the behavior we want. */

body.page-dcc-2026 .entry-content .dm-dcc-give h3.dm-dcc-give-h3 {
  font-family: var(--garamond);
  font-weight: 600;
  font-size: clamp(1.25rem, 2.4vw, 1.5rem);
  line-height: 1.3;
  margin: 1.25em 0 0.75em;
}

body.page-dcc-2026 .entry-content .dm-dcc-give p.dm-dcc-ps {
  font-size: 0.95rem;
  line-height: 1.5;
}
