/**
 * Sitting Out — public routes light appearance v3.
 * Route-owned overrides for inherited dark-only v2/v128 backgrounds.
 * Editorial art, gameplay mockups and photo heroes stay cinematic dark;
 * body sections, interactive cards and ordinary copy use semantic light ink.
 * This does not affect dark mode, the homepage, or the authenticated UI.
 */
:root[data-so-theme="light"] :is(
  .so-page--about,.so-page--community,.so-page--how-it-works,
  .so-page--partners,.so-page--terms,.so-page--privacy-policy,
  .so-page--cookie-policy,.so-page--accessibility,
  .so-page--community-guidelines,.so-events-v3,.so-event-v2,
  .so-publication,.so-story,.so-club-v3,.so-how-v5,.so-partners-v6
) {background:var(--so-bg);color:var(--so-text)}

:root[data-so-theme="light"] :is(
  .so-about-why,.so-editorial-media-story,
  .so-club-v3-story,.so-club-v3-do,.so-club-v3-learned,.so-club-v3-today,
  .so-partners-v6-routes,.so-events-v3-intro,.so-events-v3-list,
  .so-events-v3-flow,.so-events-v3-bottom,
  .so-event-v2-main,.so-story-content,.so-page--about .so-section,
  .so-page--community .so-section,.so-page--how-it-works .so-section,
  .so-page--partners .so-section
) {background:var(--so-bg);color:var(--so-text)}

:root[data-so-theme="light"] :is(
  .so-partners-v6-principles,.so-club-v3-do,.so-club-v3-today,
  .so-events-v3-flow,.so-event-v2-main
) {background:var(--so-bg-alt)}

/* Do not convert photographed/cinematic heroes or their legible white type. */
:root[data-so-theme="light"] :is(
  .so-events-v3-hero,.so-event-v2-hero,.so-club-v3-hero,
  .so-editorial-hero--about,.so-partners-v6-hero,
  .so-partners-v6-closing,.so-how-v5-hero,.so-about-close,
  .so-editorial-cta
) {color:#f5f7fa}
:root[data-so-theme="light"] :is(
  .so-events-v3-hero,.so-event-v2-hero,.so-club-v3-hero,
  .so-editorial-hero--about,.so-partners-v6-hero,
  .so-partners-v6-closing,.so-how-v5-hero,.so-about-close,
  .so-editorial-cta
) :is(h1,h2,h3) {color:#f5f7fa}
:root[data-so-theme="light"] :is(
  .so-events-v3-hero,.so-event-v2-hero,.so-club-v3-hero,
  .so-editorial-hero--about,.so-partners-v6-hero,
  .so-partners-v6-closing,.so-how-v5-hero,.so-about-close,
  .so-editorial-cta
) p:not(.so-eyebrow) {color:#e2ebf1}

/* Club: all story and community information (not the artwork labels). */
:root[data-so-theme="light"] .so-club-v3 :is(
  .so-club-v3-story,.so-club-v3-do,.so-club-v3-learned,.so-club-v3-today
) :is(h2,h3,strong,b) {color:var(--so-text)}
:root[data-so-theme="light"] .so-club-v3 :is(
  .so-club-v3-story,.so-club-v3-do,.so-club-v3-learned,.so-club-v3-today
) p:not(.so-eyebrow) {color:var(--so-text-soft)}
:root[data-so-theme="light"] .so-club-v3-grid article {
  background:var(--so-surface);border-color:var(--so-stroke);color:var(--so-text);
}
:root[data-so-theme="light"] .so-club-v3-grid article+article,
:root[data-so-theme="light"] .so-club-v3-grid article:nth-child(3),
:root[data-so-theme="light"] .so-club-v3-grid article:nth-child(4),
:root[data-so-theme="light"] .so-club-v3-lessons p {
  border-color:var(--so-stroke);
}
:root[data-so-theme="light"] .so-club-v3-grid p,
:root[data-so-theme="light"] .so-club-v3-today__copy p {color:var(--so-text-soft)}
:root[data-so-theme="light"] .so-club-v3-today__copy .so-link {color:var(--so-link-ink)}

/* About: cards are light reading surfaces, imagery remains unchanged. */
:root[data-so-theme="light"] .so-about-why__cards article {
  background:var(--so-surface);color:var(--so-text);
  border-color:var(--so-stroke);box-shadow:var(--so-shadow-card);
}
:root[data-so-theme="light"] .so-about-why__cards h3,
:root[data-so-theme="light"] .so-editorial-media-story :is(h2,h3) {color:var(--so-text)}
:root[data-so-theme="light"] .so-about-why__cards p,
:root[data-so-theme="light"] .so-about-why__heading>p:last-child,
:root[data-so-theme="light"] .so-editorial-media-story p {color:var(--so-text-soft)}

/* Partners: avoid dark blocks in otherwise white public-facing sections. */
:root[data-so-theme="light"] .so-partners-v6-route-grid article {
  background:var(--so-surface);color:var(--so-text);
  border-color:var(--so-stroke);box-shadow:var(--so-shadow-card);
}
:root[data-so-theme="light"] .so-partners-v6-routes :is(h2,h3,strong),
:root[data-so-theme="light"] .so-partners-v6-principles :is(h2,h3,strong) {
  color:var(--so-text);
}
:root[data-so-theme="light"] .so-partners-v6-route-grid p,
:root[data-so-theme="light"] .so-partners-v6-heading>p {
  color:var(--so-text-soft);
}

/* Events archive: real published cards and the four-step explanation. */
:root[data-so-theme="light"] .so-events-v3 :is(
  .so-events-v3-intro,.so-events-v3-list,.so-events-v3-flow,.so-events-v3-bottom
) :is(h2,h3,strong) {color:var(--so-text)}
:root[data-so-theme="light"] .so-events-v3 :is(
  .so-events-v3-intro,.so-events-v3-list,.so-events-v3-flow,.so-events-v3-bottom
) p:not(.so-eyebrow) {color:var(--so-text-soft)}
:root[data-so-theme="light"] .so-events-v3-list .so-event-card,
:root[data-so-theme="light"] .so-events-v3-flow__steps {
  background:var(--so-surface);border-color:var(--so-stroke);
  color:var(--so-text);box-shadow:var(--so-shadow-card);
}
:root[data-so-theme="light"] .so-events-v3-flow__steps li+li {
  border-color:var(--so-stroke);
}
:root[data-so-theme="light"] .so-events-v3-flow__steps p {
  color:var(--so-text-soft);
}

/* Event detail: readable schedule/requirements and booking panel.
   Form/button state continues to come from the real event integration. */
:root[data-so-theme="light"] .so-event-v2-main :is(h2,h3,h4,strong,b) {
  color:var(--so-text);
}
:root[data-so-theme="light"] .so-event-v2-main :is(p,li,small) {
  color:var(--so-text-soft);
}
:root[data-so-theme="light"] .so-event-v2-action,
:root[data-so-theme="light"] .so-event-v2-journey__grid article,
:root[data-so-theme="light"] .so-event-v2-intro-strip {
  background:var(--so-surface);color:var(--so-text);
  border-color:var(--so-stroke);box-shadow:var(--so-shadow-card);
}
:root[data-so-theme="light"] .so-event-v2-action__facts>div,
:root[data-so-theme="light"] .so-event-v2-requirements span {
  background:var(--so-bg-alt);border-color:var(--so-stroke);
  color:var(--so-text);
}
:root[data-so-theme="light"] .so-event-v2-action__facts span,
:root[data-so-theme="light"] .so-event-v2-action__note,
:root[data-so-theme="light"] .so-event-v2-journey__grid p {
  color:var(--so-text-soft);
}
:root[data-so-theme="light"] .so-event-v2-action__discord-fallbacks a {
  color:var(--so-link-ink);
}

/* How it works: light background with purpose-built dark in-game previews.
   Keep game UI previews untouched for contrast; only the surrounding
   explainer shell/cards change to bright readable surfaces. */
:root[data-so-theme="light"] .so-how-v5-infographic>.so-shell,
:root[data-so-theme="light"] .so-how-v5-close__inner {
  background:var(--so-surface);border-color:var(--so-stroke);
  color:var(--so-text);box-shadow:var(--so-shadow-card);
}
:root[data-so-theme="light"] .so-how-v5-infographic__head>p,
:root[data-so-theme="light"] .so-how-v5-close__lead p {
  color:var(--so-text-soft);
}
:root[data-so-theme="light"] .so-how-v5-card {
  background:var(--so-bg-alt);border-color:var(--so-stroke);
  color:var(--so-text);
}
:root[data-so-theme="light"] .so-how-v5-card__title h3,
:root[data-so-theme="light"] .so-how-v5-close :is(h2,h3,strong) {
  color:var(--so-text);
}
:root[data-so-theme="light"] .so-how-v5-card>p,
:root[data-so-theme="light"] .so-how-v5-pillars small {color:var(--so-text-soft)}
/* Dark gameplay mockups inside light cards deliberately preserve white ink. */
:root[data-so-theme="light"] .so-how-v5-card :is(
  .so-how-v5-game-panel,.so-how-v5-people-panel,
  .so-how-v5-group-panel,.so-how-v5-session-panel
) {color:#f5f7fa}
:root[data-so-theme="light"] .so-how-v5-card :is(
  .so-how-v5-game-panel,.so-how-v5-people-panel,
  .so-how-v5-group-panel,.so-how-v5-session-panel
) :is(h3,strong,b) {color:#f5f7fa}

/* Legal, privacy and generic public pages: no dark-only generic hero blocks. */
:root[data-so-theme="light"] :is(
  .so-page--terms,.so-page--privacy-policy,
  .so-page--cookie-policy,.so-page--accessibility,
  .so-page--community-guidelines
) :is(.so-story-hero,.so-story-content) {background:var(--so-bg);color:var(--so-text)}
:root[data-so-theme="light"] :is(
  .so-page--terms,.so-page--privacy-policy,
  .so-page--cookie-policy,.so-page--accessibility,
  .so-page--community-guidelines
) :is(h1,h2,h3,h4) {color:var(--so-text)}
:root[data-so-theme="light"] :is(
  .so-page--terms,.so-page--privacy-policy,
  .so-page--cookie-policy,.so-page--accessibility,
  .so-page--community-guidelines
) :is(p,li,small) {color:var(--so-text-soft)}
:root[data-so-theme="light"] .so-page-hero {background:var(--so-bg-alt);color:var(--so-text)}
:root[data-so-theme="light"] .so-page-hero :is(h1,h2) {color:var(--so-text)}
:root[data-so-theme="light"] .so-page .so-prose a {color:var(--so-link-ink)}

/* Generic WordPress pages, fallback posts/search and the public 404. */
:root[data-so-theme="light"] :is(
  .so-lost,.so-lost__visual,.so-page .so-section,
  main:not(.so-home-v4):not(.so-event-v2) .so-post-list
) {background:var(--so-bg);color:var(--so-text)}
:root[data-so-theme="light"] .so-lost :is(h1,h2,h3),
:root[data-so-theme="light"] .so-page .so-prose :is(h1,h2,h3,h4) {
  color:var(--so-text);
}
:root[data-so-theme="light"] .so-lost p:not(.so-eyebrow),
:root[data-so-theme="light"] .so-page .so-prose :is(p,li) {
  color:var(--so-text-soft);
}
:root[data-so-theme="light"] .so-post-list .so-card,
:root[data-so-theme="light"] .so-post-list .so-empty {
  background:var(--so-surface);border-color:var(--so-stroke);
  color:var(--so-text);box-shadow:var(--so-shadow-card);
}
:root[data-so-theme="light"] .so-post-list .so-card :is(h2,h3,a) {
  color:var(--so-text);
}

/* Keep focus visibility and user-entered data readable in white form surfaces. */
:root[data-so-theme="light"] :is(
  .so-event-v2-main,.so-page--partners,.so-page--about,
  .so-page--community,.so-page--how-it-works
) :is(input,select,textarea):not([type="checkbox"]):not([type="radio"]) {
  color:var(--so-text);border-color:var(--so-stroke);
}
@media(prefers-reduced-motion:reduce) {
  :root[data-so-theme="light"] .so-events-v3-list .so-event-card {
    transition:none;
  }
}

/* Editorial magazine photographic headings stay white even in light mode.
   Legacy global light H1 styles otherwise paint the first words dark on art. */
:root[data-so-theme="light"] .so-magazine .so-magazine__hero .so-magazine__hero-copy h1,
:root[data-so-theme="light"] .so-publication .so-publication-hero h1 {
  color:#f8fbfd;
  text-shadow:0 2px 15px rgba(0,0,0,.5);
}
:root[data-so-theme="light"] .so-magazine .so-magazine__hero .so-magazine__hero-copy h1 .so-magazine__accent,
:root[data-so-theme="light"] .so-publication .so-publication-hero h1 span {
  color:#00e5ff;
}
:root[data-so-theme="light"] .so-magazine__hero .so-magazine__standfirst,
:root[data-so-theme="light"] .so-magazine__hero .so-magazine__byline {
  color:#e7f2f7;
}

/* Dark-mode magazine reading and sharing rail: no white share squares.
   Scope to story UI: buttons remain full-sized with accessible focus outline. */
:root[data-so-theme="dark"] .so-magazine__shares-inner :is(a,button,.so-magazine__share-preview) {
  background:#142632;
  color:#e6f2f8;
  border-color:#385669;
  box-shadow:none;
}
:root[data-so-theme="dark"] .so-magazine__shares-inner :is(a,button):hover {
  background:#194052;
  color:#83f0f5;
  border-color:#3bcfdd;
}
:root[data-so-theme="dark"] .so-magazine__shares-inner>span:first-child {
  color:#b6cad6;
}
:root[data-so-theme="dark"] .so-magazine__shares-inner :is(a,button):focus-visible {
  outline:3px solid #00e5ff;
  outline-offset:3px;
}
