/*
 * NGChess club website template (docs/ADR-003-club-websites.md).
 * One standardized, themeable layout for every club — clubs choose one of three approved themes;
 * there is no per-club CSS. Each theme's tokens were chosen for WCAG 2.2 AA contrast
 * (body text >= 7:1, muted text >= 4.5:1, buttons >= 4.5:1).
 */

:root,
[data-theme="midnight"] {
    --c-bg: #0B1220;
    --c-surface: #121C2F;
    --c-surface-2: #182640;
    --c-text: #E8ECF3;
    --c-muted: #A9B4C8;
    --c-border: #283754;
    --c-accent: #1ED3C6;
    --c-accent-ink: #062321;
    --c-link: #5EEAD4;
    --c-header: #0B1220;
    --c-hero-from: #0B1220;
    --c-hero-to: #12304A;
    --c-hero-text: #F4F7FB;
    --c-focus: #FFC24B;
    --c-ok-bg: #0F3B2E; --c-ok-text: #B7F5D8;
    --c-warn-bg: #3D2E0B; --c-warn-text: #FFE3A3;
    --c-bad-bg: #431A1F; --c-bad-text: #FFC7CE;
    --c-note-bg: #1D2A45; --c-note-border: #3A5C9A;
    color-scheme: dark;
}

[data-theme="ivory"] {
    --c-bg: #FBF8F2;
    --c-surface: #FFFFFF;
    --c-surface-2: #F3EEE4;
    --c-text: #1B2330;
    --c-muted: #525B68;
    --c-border: #E2DACB;
    --c-accent: #0B6E69;
    --c-accent-ink: #FFFFFF;
    --c-link: #0B6E69;
    --c-header: #FFFFFF;
    --c-hero-from: #F3EEE4;
    --c-hero-to: #E4F1EE;
    --c-hero-text: #1B2330;
    --c-focus: #B45309;
    --c-ok-bg: #DDF3E8; --c-ok-text: #0F5132;
    --c-warn-bg: #FDF0D5; --c-warn-text: #7A4A00;
    --c-bad-bg: #FBE0E3; --c-bad-text: #8A1C2B;
    --c-note-bg: #EAF2FF; --c-note-border: #6C8FD0;
    color-scheme: light;
}

[data-theme="classic"] {
    --c-bg: #F5F7FB;
    --c-surface: #FFFFFF;
    --c-surface-2: #EAF0F8;
    --c-text: #0B1A33;
    --c-muted: #4A5568;
    --c-border: #D5DDEA;
    --c-accent: #0B3D91;
    --c-accent-ink: #FFFFFF;
    --c-link: #0B3D91;
    --c-header: #FFFFFF;
    --c-hero-from: #0B3D91;
    --c-hero-to: #0B1A33;
    --c-hero-text: #FFFFFF;
    --c-focus: #C2410C;
    --c-ok-bg: #DDF3E8; --c-ok-text: #0F5132;
    --c-warn-bg: #FDF0D5; --c-warn-text: #7A4A00;
    --c-bad-bg: #FBE0E3; --c-bad-text: #8A1C2B;
    --c-note-bg: #FFF6E0; --c-note-border: #D29B2A;
    color-scheme: light;
}

*, *::before, *::after { box-sizing: border-box; }
/* Author display rules (grid/flex) must never defeat the hidden attribute. */
[hidden] { display: none !important; }
html { scroll-behavior: smooth; scroll-padding-top: 84px; -webkit-text-size-adjust: 100%; }
body.club-site {
    margin: 0;
    background: var(--c-bg);
    color: var(--c-text);
    font: 16px/1.6 system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
}
img { max-width: 100%; height: auto; }
h1, h2, h3 { line-height: 1.2; margin: 0 0 .5rem; letter-spacing: -0.01em; }
h1 { font-size: clamp(2rem, 4.5vw, 3rem); font-weight: 800; }
h2 { font-size: clamp(1.45rem, 3vw, 1.9rem); font-weight: 800; }
h3 { font-size: 1.12rem; font-weight: 700; }
p { margin: 0 0 1rem; }
a { color: var(--c-link); text-underline-offset: 3px; }
:focus-visible { outline: 3px solid var(--c-focus); outline-offset: 2px; border-radius: 4px; }
.visually-hidden { position: absolute !important; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.cs-wrap { max-width: 1120px; margin: 0 auto; padding-inline: max(20px, env(safe-area-inset-left)) max(20px, env(safe-area-inset-right)); }
@media (max-width: 380px) { .cs-wrap { padding-inline: max(16px, env(safe-area-inset-left)) max(16px, env(safe-area-inset-right)); } }
.cs-muted { color: var(--c-muted); }

/* First focusable element on every club page; visually hidden until it receives keyboard focus. */
.skip-link { position: fixed; left: 12px; top: 12px; z-index: 100; background: var(--c-surface); color: var(--c-text); padding: 10px 14px; border-radius: 8px; border: 2px solid var(--c-focus); font-weight: 700; }
.skip-link:not(:focus) { width: 1px; height: 1px; padding: 0; border: 0; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

/* ---------- demo bar (only on /demo): owner-conversion UI, deliberately unlike the club's own header ---------- */
.cs-demo-bar { background: #1B1F24; color: #EEF1F4; font-size: .9rem; }
.cs-demo-bar-inner { display: flex; flex-wrap: wrap; align-items: center; gap: 6px 16px; padding-block: 6px; }
.cs-demo-label { margin: 0; flex: 1 1 280px; }
.cs-demo-label strong { color: #FFFFFF; }
.cs-demo-actions { display: flex; flex-wrap: wrap; align-items: center; gap: 6px 8px; }
.cs-chip-btn { display: inline-flex; align-items: center; min-height: 44px; padding: 6px 14px; border-radius: 999px; border: 1px solid #5A636E; background: transparent; color: #EEF1F4; font: inherit; font-weight: 600; text-decoration: none; cursor: pointer; white-space: nowrap; }
.cs-chip-btn:hover { background: #2A3038; }
.cs-chip-btn--primary { background: #1ED3C6; color: #062321; border-color: #1ED3C6; }
.cs-chip-btn--primary:hover { background: #3BE0D4; }
.cs-chip-link { display: inline-flex; align-items: center; min-height: 44px; padding: 0 6px; border: 0; background: none; color: #C9D1DB; font: inherit; font-size: .85rem; text-decoration: underline; text-underline-offset: 3px; cursor: pointer; }
.cs-chip-link:hover { color: #FFFFFF; }
.cs-demo-bar :focus-visible { outline-color: #FFC24B; }
@media (max-width: 640px) {
    .cs-demo-bar { font-size: .84rem; }
    .cs-demo-bar-inner { gap: 4px 8px; padding-block: 6px; }
    .cs-demo-label { flex-basis: 100%; }
    .cs-demo-extra { display: none; }
    .cs-demo-actions { width: 100%; }
    .cs-chip-btn { padding: 4px 12px; font-size: .84rem; }
}

/* ---------- header ---------- */
.cs-header { position: sticky; top: 0; z-index: 40; background: var(--c-header); border-bottom: 1px solid var(--c-border); }
.cs-header-inner { position: relative; display: flex; align-items: center; gap: 16px; min-height: 72px; }
.cs-identity { display: flex; align-items: center; gap: 12px; min-height: 44px; min-width: 0; color: var(--c-text); text-decoration: none; }
.cs-logo { width: 46px; height: 46px; border-radius: 12px; object-fit: contain; background: #FFFFFF; border: 1px solid var(--c-border); flex-shrink: 0; }
.cs-monogram { display: grid; place-items: center; width: 46px; height: 46px; border-radius: 12px; background: var(--c-accent); color: var(--c-accent-ink); font-weight: 800; letter-spacing: .02em; flex-shrink: 0; }
.cs-identity-text { display: flex; flex-direction: column; min-width: 0; }
.cs-identity-name { font-weight: 800; font-size: 1.05rem; line-height: 1.2; overflow: hidden; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; }
.cs-identity-sub { font-size: .82rem; color: var(--c-muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.cs-nav { margin-left: auto; display: flex; align-items: center; gap: 2px; }
.cs-nav a:not(.cs-btn) { display: inline-flex; align-items: center; min-height: 44px; padding: 8px 11px; border-radius: 8px; color: var(--c-text); font-weight: 600; font-size: .95rem; text-decoration: none; }
.cs-nav a:not(.cs-btn):hover { background: var(--c-surface-2); }
.cs-nav a[aria-current="page"]:not(.cs-btn) { color: var(--c-link); box-shadow: inset 0 -3px 0 var(--c-accent); border-radius: 8px 8px 0 0; }
.cs-nav .cs-btn { margin-left: 8px; }
.cs-menu-btn { display: none; margin-left: auto; align-items: center; gap: 8px; min-height: 44px; min-width: 44px; padding: 8px 12px; border: 1px solid var(--c-border); border-radius: 10px; background: var(--c-surface); color: var(--c-text); font: inherit; font-weight: 700; cursor: pointer; }
.cs-menu-btn svg { width: 20px; height: 20px; }

@media (max-width: 920px) {
    .cs-menu-btn { display: inline-flex; }
    .cs-nav { display: none; position: absolute; top: 100%; left: -20px; right: -20px; flex-direction: column; align-items: stretch; gap: 0; padding: 8px 20px 18px; background: var(--c-header); border-bottom: 1px solid var(--c-border); box-shadow: 0 16px 32px rgba(0, 0, 0, .18); }
    .cs-nav.is-open { display: flex; }
    .cs-nav a:not(.cs-btn) { padding: 12px 8px; border-bottom: 1px solid var(--c-border); border-radius: 0; }
    .cs-nav a[aria-current="page"]:not(.cs-btn) { box-shadow: inset 4px 0 0 var(--c-accent); padding-left: 14px; }
    .cs-nav .cs-btn { margin: 14px 0 0; }
}

/* ---------- buttons, badges ---------- */
.cs-btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 44px; padding: 10px 18px; border-radius: 10px; border: 2px solid transparent; font: inherit; font-weight: 700; line-height: 1.2; text-decoration: none; cursor: pointer; }
.cs-btn-primary { background: var(--c-accent); color: var(--c-accent-ink); }
.cs-btn-primary:hover { filter: brightness(1.07); }
.cs-btn-secondary { background: transparent; color: var(--c-text); border-color: var(--c-border); }
.cs-btn-secondary:hover { background: var(--c-surface-2); }
.cs-hero .cs-btn-secondary { color: var(--c-hero-text); border-color: color-mix(in srgb, var(--c-hero-text) 45%, transparent); }
/* The hero's primary button must stand out from the hero background in every theme. */
.cs-hero .cs-btn-primary { background: var(--c-hero-cta-bg, var(--c-accent)); color: var(--c-hero-cta-ink, var(--c-accent-ink)); }
[data-theme="classic"] { --c-hero-cta-bg: #FFFFFF; --c-hero-cta-ink: #0B3D91; }
.cs-hero--image { --c-hero-cta-bg: #FFFFFF; --c-hero-cta-ink: #0B1A33; }
.cs-btn[disabled], .cs-btn[aria-disabled="true"] { opacity: .6; cursor: not-allowed; }

.cs-badge { display: inline-flex; align-items: center; gap: 6px; padding: 2px 10px; border-radius: 999px; font-size: .78rem; font-weight: 700; letter-spacing: .02em; background: var(--c-surface-2); color: var(--c-text); border: 1px solid var(--c-border); }
.cs-badge--ok { background: var(--c-ok-bg); color: var(--c-ok-text); border-color: transparent; }
.cs-badge--warn { background: var(--c-warn-bg); color: var(--c-warn-text); border-color: transparent; }
.cs-badge--bad { background: var(--c-bad-bg); color: var(--c-bad-text); border-color: transparent; }
.cs-chip { display: inline-block; padding: 4px 12px; border-radius: 999px; font-size: .85rem; font-weight: 600; background: color-mix(in srgb, var(--c-hero-text) 12%, transparent); border: 1px solid color-mix(in srgb, var(--c-hero-text) 25%, transparent); }

/* ---------- hero ---------- */
.cs-hero { position: relative; overflow: hidden; background: linear-gradient(135deg, var(--c-hero-from), var(--c-hero-to)); color: var(--c-hero-text); }
.cs-hero-media { position: absolute; inset: 0; }
.cs-hero-media img { width: 100%; height: 100%; object-fit: cover; }
.cs-hero-media::after { content: ""; position: absolute; inset: 0; background: linear-gradient(90deg, rgba(5, 10, 20, .86) 0%, rgba(5, 10, 20, .62) 55%, rgba(5, 10, 20, .30) 100%); }
.cs-hero--image { color: #FFFFFF; }
.cs-hero--image .cs-btn-secondary { color: #FFFFFF; border-color: rgba(255, 255, 255, .6); }
.cs-hero-inner { position: relative; padding-block: clamp(24px, 4.5vw, 52px); max-width: 760px; }
.cs-hero h1 { font-size: clamp(1.9rem, 4vw, 2.6rem); margin-bottom: .35rem; }
.cs-eyebrow { font-size: .78rem; font-weight: 800; letter-spacing: .14em; text-transform: uppercase; margin-bottom: .5rem; opacity: .9; }
.cs-lede { font-size: clamp(1.02rem, 1.8vw, 1.18rem); max-width: 40em; opacity: .95; margin-bottom: .75rem; }
.cs-cta-row { display: flex; flex-wrap: wrap; align-items: center; gap: 12px; margin-top: 1.25rem; }
.cs-chips { display: flex; flex-wrap: wrap; gap: 8px; margin: .25rem 0 0; padding: 0; list-style: none; }
.cs-hero-link { display: inline-flex; align-items: center; min-height: 44px; padding: 0 6px; color: var(--c-hero-text); font-weight: 700; text-underline-offset: 4px; }
.cs-hero--image .cs-hero-link { color: #FFFFFF; }

/* ---------- sections, cards ---------- */
.cs-section { padding-block: clamp(32px, 5vw, 56px); }
.cs-section--alt { background: var(--c-surface); border-block: 1px solid var(--c-border); }
.cs-section-head { display: flex; flex-wrap: wrap; align-items: end; justify-content: space-between; gap: 8px 24px; margin-bottom: 24px; }
.cs-section-head p { margin: 0; color: var(--c-muted); max-width: 42em; }
.cs-page-head { padding-block: 40px 8px; }
.cs-breadcrumbs ol { display: flex; flex-wrap: wrap; gap: 6px; padding: 0; margin: 0 0 12px; list-style: none; font-size: .9rem; color: var(--c-muted); }
.cs-breadcrumbs li + li::before { content: "/"; margin-right: 6px; color: var(--c-muted); }
.cs-breadcrumbs a { color: var(--c-muted); }
.cs-grid { display: grid; gap: 16px; grid-template-columns: repeat(auto-fill, minmax(min(100%, 300px), 1fr)); }
.cs-card { display: flex; flex-direction: column; gap: 10px; background: var(--c-surface); border: 1px solid var(--c-border); border-radius: 14px; padding: 20px; }
.cs-section--alt .cs-card { background: var(--c-bg); }
.cs-card-title { margin: 0; }
.cs-card-title a { display: inline-block; padding-block: 6px; color: var(--c-text); text-decoration: none; }
.cs-section-head > a { display: inline-flex; align-items: center; min-height: 44px; }
.cs-card-title a:hover { text-decoration: underline; }
.cs-card-meta { margin: 0; color: var(--c-muted); font-size: .92rem; font-weight: 600; }
.cs-card p { margin: 0; }
.cs-card-actions { display: flex; flex-wrap: wrap; gap: 10px; margin-top: auto; padding-top: 6px; }
.cs-facts { display: grid; gap: 6px; margin: 0; }
.cs-facts div { display: grid; grid-template-columns: 76px 1fr; gap: 10px; }
.cs-facts dt { font-size: .78rem; font-weight: 800; letter-spacing: .06em; text-transform: uppercase; color: var(--c-muted); padding-top: 3px; }
.cs-facts dd { margin: 0; }
.cs-facts--wide div { grid-template-columns: 150px 1fr; }
.cs-availability { display: flex; flex-wrap: wrap; align-items: center; gap: 6px 10px; margin: 0; font-weight: 700; }
.cs-card-actions--stack { flex-direction: column; align-items: stretch; }
/* A state with no action (e.g. "Registration closed", "Cancelled"): readable text, not a disabled-looking button. */
.cs-cta-status { display: inline-flex; align-items: center; min-height: 44px; margin: 0; font-weight: 700; color: var(--c-muted); }
.cs-next-step { font-weight: 600; }
.cs-contact-card { flex-direction: row; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 16px; }
.cs-two-col { display: grid; gap: 32px; grid-template-columns: minmax(0, 1.6fr) minmax(0, 1fr); align-items: start; }
.cs-aside { position: sticky; top: 96px; }
/* minmax(0, 1fr), not 1fr: a grid item keeps min-width:auto, so a wide field pushed the column past the screen. */
@media (max-width: 860px) { .cs-two-col { grid-template-columns: minmax(0, 1fr); } .cs-aside { position: static; } }
.cs-prose p { max-width: 68ch; }
.cs-list { padding-left: 1.2rem; }
.cs-list li { margin-bottom: .35rem; }

.cs-feature { display: grid; gap: 20px; grid-template-columns: 110px 1fr; align-items: start; background: var(--c-surface); border: 1px solid var(--c-border); border-radius: 16px; padding: 22px; }
.cs-datebox { text-align: center; border-radius: 12px; background: var(--c-accent); color: var(--c-accent-ink); padding: 12px 8px; font-weight: 800; }
.cs-datebox span { display: block; }
.cs-datebox .m { font-size: .8rem; letter-spacing: .12em; text-transform: uppercase; }
.cs-datebox .d { font-size: 2rem; line-height: 1; margin: 2px 0; }
.cs-datebox .w { font-size: .8rem; }
@media (max-width: 520px) { .cs-feature { grid-template-columns: 1fr; } .cs-datebox { display: flex; gap: 8px; justify-content: center; align-items: baseline; } .cs-datebox .d { font-size: 1.4rem; } }

/* ---------- schedule ---------- */
.cs-filters { display: flex; flex-wrap: wrap; align-items: end; gap: 12px; margin-bottom: 20px; }
.cs-field { display: grid; gap: 4px; }
.cs-field label, .cs-legend { font-size: .85rem; font-weight: 700; }
.cs-select, .cs-input, .cs-textarea { width: 100%; min-height: 44px; padding: 10px 12px; border-radius: 10px; border: 1px solid var(--c-border); background: var(--c-surface); color: var(--c-text); font: inherit; }
.cs-textarea { min-height: 120px; resize: vertical; }
.cs-select:focus-visible, .cs-input:focus-visible, .cs-textarea:focus-visible { border-color: var(--c-focus); }
.cs-tz { font-size: .9rem; color: var(--c-muted); margin: 0 0 16px; }
.cs-days { list-style: none; padding: 0; margin: 0; display: grid; gap: 18px; }
.cs-day h3 { font-size: 1rem; margin: 0 0 8px; color: var(--c-muted); text-transform: uppercase; letter-spacing: .08em; }
.cs-slots { list-style: none; padding: 0; margin: 0; border: 1px solid var(--c-border); border-radius: 14px; overflow: hidden; background: var(--c-surface); }
.cs-slot { display: grid; grid-template-columns: 150px minmax(0, 1fr) auto; gap: 6px 16px; align-items: center; padding: 14px 18px; border-top: 1px solid var(--c-border); }
.cs-slot:first-child { border-top: 0; }
.cs-slot-time { font-weight: 700; font-variant-numeric: tabular-nums; }
.cs-slot-title { font-weight: 700; }
.cs-slot-title a { color: var(--c-text); }
.cs-slot-meta { display: block; color: var(--c-muted); font-size: .9rem; }
.cs-slot--cancelled .cs-slot-title, .cs-slot--cancelled .cs-slot-time { text-decoration: line-through; text-decoration-thickness: 2px; }
.cs-slot--moved .cs-slot-time { text-decoration: line-through; }
@media (max-width: 640px) { .cs-slot { grid-template-columns: 1fr; } }
.cs-empty { border: 1px dashed var(--c-border); border-radius: 14px; padding: 28px; text-align: center; color: var(--c-muted); }
.cs-empty strong { display: block; color: var(--c-text); margin-bottom: 4px; }

/* ---------- coaches, news ---------- */
.cs-coach { flex-direction: row; align-items: flex-start; gap: 16px; }
.cs-coach-photo { width: 72px; height: 72px; border-radius: 50%; object-fit: cover; flex-shrink: 0; background: var(--c-surface-2); }
.cs-coach-mono { display: grid; place-items: center; width: 72px; height: 72px; border-radius: 50%; flex-shrink: 0; background: var(--c-surface-2); color: var(--c-link); font-weight: 800; font-size: 1.3rem; }
.cs-verified { font-size: .85rem; }
.cs-post-image { border-radius: 14px; width: 100%; aspect-ratio: 16 / 9; object-fit: cover; }

/* ---------- forms ---------- */
.cs-form { display: grid; gap: 16px; max-width: 640px; }
.cs-form fieldset { border: 1px solid var(--c-border); border-radius: 14px; padding: 16px 18px; margin: 0; display: grid; gap: 14px; }
.cs-form legend { font-weight: 800; padding: 0 6px; }
.cs-row-2 { display: grid; gap: 14px; grid-template-columns: 1fr 1fr; }
@media (max-width: 560px) { .cs-row-2 { grid-template-columns: 1fr; } }
.cs-hint { font-size: .85rem; color: var(--c-muted); margin: 0; }
.cs-error { font-size: .88rem; font-weight: 700; color: var(--c-bad-text); background: var(--c-bad-bg); border-radius: 8px; padding: 4px 10px; margin: 0; }
.cs-error::before { content: "⚠ "; }
.cs-input[aria-invalid="true"], .cs-select[aria-invalid="true"], .cs-textarea[aria-invalid="true"] { border: 2px solid var(--c-bad-text); }
.cs-check { display: grid; grid-template-columns: 24px 1fr; gap: 10px; align-items: start; }
.cs-check input { width: 24px; height: 24px; margin: 1px 0 0; accent-color: var(--c-accent); }
.cs-radio-row { display: flex; flex-wrap: wrap; gap: 10px 20px; }
.cs-radio-row label { display: inline-flex; align-items: center; gap: 8px; min-height: 44px; }
.cs-radio-row input { width: 20px; height: 20px; accent-color: var(--c-accent); }
.cs-hp { position: absolute; left: -10000px; width: 1px; height: 1px; overflow: hidden; }
.cs-alert { border-radius: 14px; padding: 16px 18px; border: 1px solid var(--c-border); }
.cs-alert--ok { background: var(--c-ok-bg); color: var(--c-ok-text); border-color: transparent; }
.cs-alert--bad { background: var(--c-bad-bg); color: var(--c-bad-text); border-color: transparent; }
.cs-alert h2, .cs-alert h3 { color: inherit; }
.cs-alert ul { margin: .5rem 0 0; padding-left: 1.2rem; }
.cs-privacy { font-size: .88rem; color: var(--c-muted); background: var(--c-surface-2); border-radius: 12px; padding: 12px 14px; }
.cs-submit-row { align-items: center; }
.cs-demo-note { margin: 0; font-size: .9rem; font-weight: 700; color: var(--c-muted); }
/* Fictional contact details on the demo: shown as labelled sample data, never as mailto:/tel: links. */
.cs-sample { display: inline-flex; flex-wrap: wrap; align-items: center; gap: 4px 8px; min-height: 40px; }
.cs-sample-tag { font-size: .72rem; font-weight: 800; letter-spacing: .06em; text-transform: uppercase; color: var(--c-muted); border: 1px solid var(--c-border); border-radius: 999px; padding: 0 8px; }

/* ---------- owner tips (demo explanation layer) ---------- */
.cs-owner-note { display: none; margin: 0 0 18px; padding: 12px 14px; border-radius: 12px; background: var(--c-note-bg); border: 1px dashed var(--c-note-border); color: var(--c-text); font-size: .92rem; }
.cs-owner-note strong { display: block; margin-bottom: 2px; }
body.show-owner-notes .cs-owner-note { display: block; }
.cs-customize { display: grid; gap: 16px; grid-template-columns: repeat(auto-fit, minmax(min(100%, 240px), 1fr)); }
/* Owner zone: what an owner can change, set apart from member-facing content by tone and a dashed frame. */
.cs-owner-zone { background: var(--c-note-bg); border-block: 2px dashed var(--c-note-border); }
.cs-owner-zone .cs-card { background: var(--c-surface); }
.cs-owner-zone-label { margin: 0 0 6px; font-size: .78rem; font-weight: 800; letter-spacing: .14em; text-transform: uppercase; color: var(--c-text); }

/* ---------- footer ---------- */
.cs-footer { margin-top: 40px; background: var(--c-surface); border-top: 1px solid var(--c-border); padding-block: 36px 28px; font-size: .95rem; }
.cs-footer-grid { display: grid; gap: 28px; grid-template-columns: 1.3fr 1fr 1fr; }
@media (max-width: 760px) { .cs-footer-grid { grid-template-columns: 1fr; } }
.cs-footer h2 { font-size: 1rem; }
.cs-footer ul { list-style: none; padding: 0; margin: 0; display: grid; gap: 2px; }
.cs-footer ul a { display: inline-flex; align-items: center; min-height: 44px; }
.cs-powered a { display: inline-flex; align-items: center; gap: 10px; min-height: 44px; color: var(--c-text); text-decoration: none; }
.cs-powered .ng-logo { width: 117px; height: 30px; }
/* NGChess attribution logo (fragments/brand-logo.html carries its own fills; this adds forced-colors support). */
.ng-logo { display: block; flex-shrink: 0; }
@media (forced-colors: active) {
    .ng-logo .lg-body, .ng-logo .lg-accent, .ng-logo .lg-word-a, .ng-logo .lg-word-b { fill: CanvasText; }
    .ng-logo .lg-accent-stroke { stroke: CanvasText; }
}
.cs-fine { font-size: .85rem; color: var(--c-muted); margin-top: 10px; }
/* Links inside running text must not rely on colour alone (WCAG 1.4.1). */
.cs-fine a, .cs-privacy a, .cs-prose a { text-decoration: underline; text-decoration-thickness: 1px; }

@media (prefers-reduced-motion: reduce) {
    html { scroll-behavior: auto; }
    *, *::before, *::after { transition: none !important; animation: none !important; }
}

@media (forced-colors: active) {
    .cs-btn, .cs-chip-btn, .cs-menu-btn, .cs-badge { border: 1px solid ButtonText; }
    .cs-nav a[aria-current="page"] { outline: 2px solid CanvasText; }
    .cs-hero-media::after { display: none; }
    .cs-owner-note { border: 2px dashed CanvasText; }
}

@media print {
    .cs-header, .cs-demo-bar, .cs-footer, .cs-cta-row, .cs-filters { display: none !important; }
    body.club-site { background: #FFFFFF; color: #000000; }
}
