/* v017: one primary navy for both website themes and every intro phase. */
:root { --pwr-navy:#152235; }
:root:not([data-theme="light"]) {
  --bg:var(--pwr-navy);
  --surface:var(--pwr-navy);
  /* One RGB step keeps the dim labels readable against the brighter navy. */
  --muted-2:#8d887e;
  --dim:#8d887e;
}
:root .pwr-intro { --bg:var(--pwr-navy); }
:root .chess-tile--ink { background:var(--pwr-navy); }

/* Approved cream reading areas and gold accents are retained. */
:root[data-theme="light"] {
  --fg:var(--pwr-navy);
  --muted:#49596b;
  --muted-2:#49596b;
  --dim:#49596b;
  --dim-2:#49596b;
  --rule:rgba(21,34,53,.20);
  --rule-2:rgba(21,34,53,.24);
  --rule-3:rgba(21,34,53,.15);
  --rule-4:rgba(21,34,53,.28);
  --card-border-color:rgba(21,34,53,.32);
  --card-border-active:rgba(21,34,53,.55);
  --card-line:rgba(21,34,53,.18);
  --card-face-hover:rgba(21,34,53,.04);
}

:root[data-theme="light"] .phead--primary .page-title {
  color:var(--pwr-navy);
}

/* A consistent navy surround connects the opening to the website navigation. */
:root[data-theme="light"] :is(.head,.foot,.pwr-intro) {
  --bg:var(--pwr-navy);
  --fg:#f0ece4;
  --muted:#d4d9df;
  --muted-2:#d4d9df;
  --dim:#d4d9df;
  --dim-2:#d4d9df;
  --gold:#e3b862;
  --gold-bright:#e3b862;
  --gold-hi:#f0d49a;
  --gold-soft:rgba(201,151,58,.6);
  --gold-ring:rgba(227,184,98,.6);
  --g1:#b8862d;
  --g2:#e3b862;
  --g3:#c2912f;
  --rule-3:rgba(227,184,98,.28);
}
:root[data-theme="light"] :is(.head,.foot) {
  background:var(--pwr-navy);
  border-color:rgba(201,151,58,.5);
}
:root[data-theme="light"] .nav a[aria-current="page"] {
  color:#f0ece4;
}
:root[data-theme="light"] .foot .links a { color:#e3b862; }
:root[data-theme="light"] .foot .links a:is(:hover,:focus-visible) { color:#f0ece4; }

/* Gold artwork is unchanged; the navy field adds contrast around the board. */
:root[data-theme="light"] .pwr-intro__skip {
  background:var(--pwr-navy);
  border-color:rgba(227,184,98,.65);
  color:#f0ece4;
  box-shadow:none;
}
:root[data-theme="light"] .pwr-intro__skip:is(:hover,:focus-visible,:active) {
  background:var(--pwr-navy);
  border-color:#e3b862;
  color:#f0ece4;
  box-shadow:none;
}

/* Navy feature panels ground each page, while long-form copy stays on cream. */
:root[data-theme="light"] :is(.strategy-king,.strategy-entry,.team .card) {
  --fg:#f0ece4;
  --muted:#d4d9df;
  --muted-2:#d4d9df;
  --dim:#d4d9df;
  --dim-2:#d4d9df;
  --gold:#e3b862;
  --gold-bright:#e3b862;
  --gold-hi:#f0d49a;
  --gold-soft:rgba(201,151,58,.6);
  --gold-ring:rgba(227,184,98,.55);
  --surface:var(--pwr-navy);
  --card-paper:var(--pwr-navy);
  --card-border-color:rgba(201,151,58,.65);
  --card-border-active:#c9973a;
  --card-line:rgba(227,184,98,.3);
  --card-face-hover:rgba(240,236,228,.04);
  --slot-tint:rgba(240,236,228,.04);
  --rule-3:rgba(240,236,228,.18);
  --rule-4:rgba(240,236,228,.22);
}

/* Expanded strategy explanations remain easy to read in the cream palette. */
:root[data-theme="light"] .strategy-entry .strategy-detail {
  --fg:var(--pwr-navy);
  --muted:#49596b;
  --muted-2:#49596b;
  --dim:#49596b;
  --dim-2:#49596b;
  --gold:#7a5c1c;
  --gold-bright:#7a5c1c;
  --gold-hi:#5e4614;
  --gold-soft:rgba(122,92,28,.6);
  --card-line:rgba(21,34,53,.24);
  background:#fdfbf7;
  color:var(--pwr-navy);
}
