:root {
    color-scheme: light;
    /* Shared venue theme; the document supplies its validated color tokens. */
    --brand-primary: #155542;
    --brand-on-primary: #ffffff;
    --brand-hover: #124b3a;
    --brand-ink: #155542;
    --brand-tint: #f1f5f4;
    --brand-soft: #e3ebe8;
    --brand-border: #bdd0ca;
    --brand-focus: #155542;
    --ink: #202624;
    --muted: #58615e;
    --paper: var(--brand-tint);
    --line: var(--brand-border);
    font-family: system-ui, -apple-system, "Segoe UI", sans-serif;
    line-height: 1.5;
    color: var(--ink);
    background: var(--paper);
}

* { box-sizing: border-box; }
body { margin: 0; }
h1, h2, h3, p { margin: 0; }
h1 { font-size: clamp(2rem, 5vw, 3.15rem); line-height: 1.07; letter-spacing: -.055em; }
h2 { font-size: 1.25rem; letter-spacing: -.025em; }
h3 { font-size: 1.1rem; }
a { color: var(--brand-ink); }
a:hover { text-decoration: underline; }
:focus-visible { outline: 3px solid var(--brand-focus); outline-offset: 3px; }

.site-header { background: #fff; border-top: 3px solid var(--brand-primary); border-bottom: 1px solid var(--line); }
.header-inner { max-width: 1192px; margin: auto; padding: .85rem 1.25rem; display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: .75rem; }
.brand { display: inline-flex; align-items: center; gap: .55rem; font-weight: 800; color: var(--ink); text-decoration: none; white-space: nowrap; }
.brand-mark { width: 28px; height: 28px; background: url("favicon.svg") center / cover; }
nav, .actions { display: flex; flex-wrap: wrap; align-items: center; gap: .55rem; }
nav a, nav .quiet { padding: .4rem .55rem; font-size: .875rem; color: var(--muted); text-decoration: none; font-weight: 650; }
nav a:hover, nav [aria-current="page"] { color: var(--brand-ink); background: var(--brand-soft); border-radius: .45rem; }

.page { max-width: 1192px; margin: auto; padding: 2rem 1.25rem 4rem; }
.narrow { max-width: 550px; }
.page-heading { margin-bottom: 1.25rem; }
.venue-name { font-size: .85rem; font-weight: 700; letter-spacing: .025em; margin-bottom: .3rem; }
.booking-banner { display: flex; align-items: flex-end; justify-content: space-between; gap: 1rem; padding: clamp(1.3rem, 5vw, 3rem); border-radius: 1.15rem; background: var(--brand-primary); color: var(--brand-on-primary); }
.booking-banner h1 + p { color: inherit; margin-top: .55rem; }
.booking-banner .venue-name { color: inherit; }
.pay-label { white-space: nowrap; color: var(--brand-ink); background: var(--brand-soft); font-weight: 750; padding: .4rem .75rem; font-size: .82rem; border-radius: 99px; }
.panel { background: #fff; border: 1px solid var(--line); border-radius: .85rem; padding: clamp(1rem, 3vw, 1.4rem); }
.filters { display: flex; flex-wrap: wrap; align-items: end; gap: .7rem; margin: 1rem 0; }
.filters > label { min-width: 10rem; }
label { display: grid; gap: .3rem; font-size: .85rem; font-weight: 650; }
input, select, button, .button { font: inherit; }
input:not([type="checkbox"]), select { min-width: 0; width: 100%; padding: .52rem .65rem; min-height: 2.6rem; color: var(--ink); background: #fff; border: 1px solid #aeb7b3; border-radius: .5rem; }
button, .button { display: inline-flex; align-items: center; justify-content: center; min-height: 2.6rem; border: 1px solid var(--brand-ink); border-radius: .5rem; padding: .5rem .8rem; background: var(--brand-primary); color: var(--brand-on-primary); text-decoration: none; cursor: pointer; font-weight: 700; white-space: nowrap; }
button:hover, .button:hover { background: var(--brand-hover); color: var(--brand-on-primary); text-decoration: none; }
.secondary { background: var(--brand-tint); border-color: var(--line); color: var(--brand-ink); }
.secondary:hover, .quiet:hover { background: var(--brand-soft); color: var(--brand-ink); }
.quiet { background: transparent; color: var(--brand-ink); }
.small { min-height: 2rem; padding: .25rem .45rem; font-size: .78rem; }
.section-heading { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: .4rem .9rem; }
.section-heading p, .muted { color: var(--muted); font-size: .875rem; }
.section-heading .price { font-size: 1.35rem; color: var(--brand-ink); }
.court-card { margin-top: .65rem; }
.slots { margin-top: .7rem; display: flex; flex-wrap: wrap; gap: .45rem; }
.slot { display: inline-flex; align-items: center; justify-content: center; min-width: 5.35rem; min-height: 2.6rem; padding: .4rem .55rem; border: 1px solid var(--brand-border); text-decoration: none; border-radius: .5rem; font-size: .86rem; font-weight: 690; background: var(--brand-tint); }
.slot:hover, .slot.selected { color: var(--brand-on-primary); background: var(--brand-primary); text-decoration: none; border-color: var(--brand-ink); }
.form-row { display: flex; flex-wrap: wrap; align-items: end; gap: .65rem; }
.form-row > label { flex: 1 1 9rem; }
.form-stack { display: grid; gap: .75rem; }
.form-stack > button { justify-self: start; }
.checkout { margin-bottom: 1.15rem; border-color: var(--brand-border); }
.checkout form, .login form { margin-top: .8rem; }
.contact { margin-top: .9rem; font-size: .9rem; }
.empty { margin-top: .6rem; color: var(--muted); }
.notice { padding: .7rem .9rem; border-radius: .55rem; background: var(--brand-soft); margin: 0 0 .8rem; }
.notice ul { margin: 0; padding-left: 1.15rem; }
.error { background: #fce8e4; color: #852d25; }
.success { background: #e0f4e4; color: #165133; }
.confirmation h1 { margin-top: .55rem; }
.receipt { margin: 1.1rem 0; }
.receipt > div { padding: .55rem 0; border-top: 1px solid var(--line); display: flex; flex-wrap: wrap; justify-content: space-between; gap: .3rem .7rem; }
.receipt dt { color: var(--muted); }
.receipt dd { margin: 0; font-weight: 680; }
.ref { font-family: ui-monospace, monospace; overflow-wrap: anywhere; }

.calendar-filters { align-items: center; }
.calendar-date { display: flex; gap: .25rem .65rem; flex-wrap: wrap; margin-left: auto; align-items: baseline; }
.calendar-date span { color: var(--muted); font-size: .82rem; }
.calendar-filters input { width: auto; }
.court-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 17rem), 1fr)); gap: .75rem; align-items: start; }
.court-column > .muted { margin-top: .45rem; }
.calendar-entry { margin-top: .65rem; padding: .65rem; display: grid; gap: .22rem; border-radius: .55rem; border: 1px solid var(--line); border-left: 4px solid #489775; background: #f6faf6; }
.calendar-entry time { color: var(--brand-ink); font-weight: 700; font-size: .83rem; }
.blocked-entry { border-left-color: #a28749; background: #fbf8ef; }
.status-chip { display: inline-block; justify-self: start; padding: .15rem .45rem; font-size: .75rem; font-weight: 680; border-radius: .35rem; background: #e7ebe6; color: #435047; }
.paid { background: #ddf2e3; color: #175639; }
.unpaid { background: #f5eccb; color: #674a16; }
.calendar-slots { margin-top: .75rem; }
summary { cursor: pointer; color: var(--brand-ink); font-weight: 700; }
.settings-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 30rem), 1fr)); gap: .8rem; align-items: start; }
.settings-grid .panel > h2 { margin-bottom: .55rem; }
.settings-row { border-top: 1px solid var(--line); margin-top: .55rem; padding-top: .55rem; }
.settings-grid summary + form { margin-top: .65rem; }
.hours-row { display: flex; align-items: end; flex-wrap: wrap; gap: .55rem; margin: 0; min-width: 0; border: 1px solid var(--line); border-radius: .5rem; padding: .45rem .65rem .65rem; }
.hours-row legend { font-size: .84rem; font-weight: 700; padding: 0 .2rem; }
.hours-row > label:not(.checkbox) { flex: 1 1 5rem; }
.checkbox { display: flex; align-items: center; min-height: 2.6rem; }
.checkbox input { accent-color: var(--brand-ink); }
.visually-hidden { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }

@media (max-width: 540px) {
    .page { padding-top: 1.15rem; }
    .booking-banner { flex-wrap: wrap; }
    .filters > label { min-width: 0; flex: 1 1 8rem; }
    .calendar-date { margin-left: 0; flex-basis: 100%; }
}

.venue-banner {
    position: relative;
    overflow: hidden;
    isolation: isolate;
    background: var(--brand-primary);
    border-top: 4px solid var(--brand-primary);
}
.venue-cover { position: absolute; inset: 0; z-index: -2; width: 100%; height: 100%; object-fit: cover; }
.venue-banner:has(.venue-cover) { color: #fff; }
.venue-banner:has(.venue-cover)::after { content: ""; position: absolute; inset: 0; z-index: -1; background: rgb(0 0 0 / .66); }
.venue-banner .venue-name { display: flex; align-items: center; gap: .6rem; }
.venue-logo { width: 2.65rem; height: 2.65rem; padding: .18rem; background: #fff; border-radius: .45rem; object-fit: contain; }
.venue-links { margin-top: .45rem; }
.booking-policy { margin: .65rem 0; padding: .65rem; background: var(--brand-tint); border-radius: .45rem; font-size: .875rem; }
.booking-policy p { white-space: pre-wrap; overflow-wrap: anywhere; }
.slot:has(small) { flex-direction: column; }
.slot small { font-size: .72rem; }
.setup-nav { margin-bottom: .85rem; }
textarea { width: 100%; padding: .5rem .65rem; border: 1px solid #aeb7b3; border-radius: .5rem; font: inherit; resize: vertical; }
.media-preview { max-width: 7rem; max-height: 4rem; object-fit: contain; }
.share-qr svg { display: block; max-width: 100%; height: auto; margin: .5rem 0; }
[hidden] { display: none !important; }

.payment-qr { display: block; width: min(100%, 20rem); height: auto; margin: .75rem auto; }
.payment-instructions { margin: .8rem 0; }

.payment-hold { display: flex; flex-wrap: wrap; align-items: baseline; justify-content: space-between; column-gap: 1rem; margin: .7rem 0 .45rem; padding: .65rem .85rem; background: var(--brand-soft); color: var(--brand-ink); border-radius: .55rem; }
.hold-countdown { font-size: 1.55rem; line-height: 1.15; font-variant-numeric: tabular-nums; }

.booking-icon { display: inline-block; flex: 0 0 18px; vertical-align: -.18em; pointer-events: none; }
.booking-icon-label, .booking-notice { display: flex; align-items: center; gap: .42rem; }
.booking-page .actions > .button, .booking-button, .booking-page .venue-links a { gap: .42rem; }
.booking-page .venue-links a { display: inline-flex; align-items: center; }
.compact-venue-banner { padding: .8rem 1rem; gap: .4rem .75rem; }
.compact-venue-banner h1, .compact-payment h1 { font-size: clamp(1.45rem, 4vw, 2rem); }
.compact-venue-banner .venue-name { margin-bottom: .25rem; }
.compact-venue-banner .venue-logo { width: 1.7rem; height: 1.7rem; }
.compact-venue-banner h1 + p { margin-top: .22rem; font-size: .85rem; }
.booking-filters { padding: .65rem .8rem; margin: .65rem 0; }
.booking-filters > label { flex: 1 1 9rem; min-width: 0; }
.booking-filters .booking-icon { color: var(--brand-ink); }
.compact-court-card { padding: .7rem .8rem; margin-top: .5rem; }
.booking-slots { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 5rem), 1fr)); gap: .35rem; margin-top: .45rem; }
.booking-slots .slot { min-width: 0; min-height: 44px; padding: .32rem .25rem; white-space: nowrap; }
.booking-details { margin: .7rem 0 0; padding: .75rem; background: var(--brand-tint); border: 1px solid var(--brand-border); border-radius: .6rem; scroll-margin: .75rem; }
.booking-details .form-row, .booking-details .notice { margin-top: .45rem; }
.booking-details .notice { margin-bottom: 0; }
.compact-policy { font-size: .86rem; }
.compact-policy summary { display: inline-flex; align-items: center; gap: .25rem; list-style: none; }
.compact-policy summary::-webkit-details-marker { display: none; }
.compact-policy[open] summary .booking-icon { transform: rotate(180deg); }
.compact-policy p { margin-top: .3rem; white-space: pre-wrap; overflow-wrap: anywhere; }
.booking-details .compact-policy { flex: 1 1 100%; }
.booking-button { min-height: 44px; }
.booking-button:disabled { opacity: .65; cursor: wait; }
[data-booking-results][aria-busy="true"] { opacity: .65; }
.compact-payment { padding: .85rem 1rem; }
.compact-payment h1 { margin: 0; }
.compact-payment .price { font-size: 1.4rem; }
.payment-qr-block { display: grid; justify-items: center; gap: .15rem; margin: .35rem 0 .55rem; }
.payment-qr-block .payment-qr { width: min(100%, 13rem); margin: 0; }
.payment-qr-block .button { gap: .35rem; }
.payment-steps { margin: .5rem 0; padding-left: 1.22rem; font-size: .86rem; }
.payment-steps li + li { margin-top: .2rem; }
.payment-steps span { display: block; color: var(--muted); }
.payment-reference { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; column-gap: .5rem; padding: .35rem .55rem; margin: .55rem 0; background: var(--brand-tint); border-radius: .45rem; }
.payment-reference .ref { display: block; font-size: .85rem; }
.copy-reference { width: 44px; height: 44px; }
.copy-reference.reference-copied { color: var(--brand-ink); background: #ddf2e3; }
.payment-actions > .button { min-height: 44px; }
.payment-booking-summary { color: var(--muted); font-size: .84rem; margin: .55rem 0 .2rem; }
@media (max-width: 540px) {
    .booking-page { padding-inline: .85rem; }
    .booking-filters > label { flex-basis: 0; }
    .booking-details .booking-button, .payment-actions > .button { flex: 1 1 auto; }
}
.copy-feedback:empty { display: none; }

.survey-panel { margin-top: .75rem; padding: 1rem; display: grid; gap: .7rem; }
.survey-panel h2 { font-size: 1.5rem; }
.survey-step { font-weight: 700; }
.survey-back { font-size: .9rem; font-weight: 700; padding: .35rem .5rem; }
.survey-progress { display: grid; grid-template-columns: repeat(6, 1fr); gap: .3rem; list-style: none; margin: 0; padding: 0; }
.survey-progress li { height: .32rem; background: var(--line); border-radius: 99px; }
.survey-progress li.complete { background: var(--brand-ink); }
.survey-summary { padding: .45rem .65rem; background: var(--brand-tint); border-radius: .5rem; color: var(--muted); font-size: .85rem; font-weight: 650; }
.survey-form > button { justify-self: stretch; }
.survey-choices { display: grid; gap: .45rem; }
.survey-choice { display: flex; align-items: center; justify-content: space-between; gap: .65rem; padding: .75rem; min-height: 48px; border: 1px solid var(--brand-border); border-radius: .55rem; color: var(--ink); background: var(--brand-tint); text-decoration: none; }
.survey-choice:hover { border-color: var(--brand-ink); text-decoration: none; background: var(--brand-soft); }
.survey-choice:has(> .booking-icon) { justify-content: flex-start; }
.survey-choice small { display: block; color: var(--muted); font-size: .75rem; }
.survey-price { color: var(--brand-ink); white-space: nowrap; }
.survey-times { grid-template-columns: repeat(auto-fit, minmax(min(100%, 6.5rem), 1fr)); margin-top: 0; }
.survey-times .slot { min-height: 3rem; }
.survey-empty { margin: 0; }
.survey-panel .booking-details { margin: 0; }
.survey-panel .booking-details .form-row > label { flex-basis: 100%; }
.survey-panel .booking-details .booking-button { width: 100%; white-space: normal; }

/* Open Play */
.booking-types { display:grid; gap:.5rem; margin: .9rem 0; }
.booking-types .survey-choice { justify-content:flex-start; gap:.75rem; text-decoration:none; }
.booking-types .survey-choice span { display:grid; gap:.2rem; }
.booking-types .survey-choice[aria-current="page"] { border-color:var(--brand-ink); background:var(--brand-soft); }
.open-play-progress { grid-template-columns:repeat(4,minmax(0,1fr)); }
.open-play-card { border:1px solid var(--line); border-radius:.75rem; padding:.9rem; display:grid; gap:.45rem; margin:.45rem 0; }
.open-play-capacity { width:100%; height:.65rem; accent-color:var(--brand-ink); display:block; }
.open-play-create,.open-play-admin-list { margin:1rem 0; }
.open-play-form-grid { display:grid; grid-template-columns:repeat(auto-fit,minmax(min(100%,12rem),1fr)); gap:.75rem; }
.open-play-list-row { display:grid; grid-template-columns:minmax(0,2fr) repeat(3,minmax(0,1fr)) auto; gap:.8rem; align-items:center; border-bottom:1px solid var(--line); padding:.85rem 0; }
.session-name { font-weight:650; }
.open-play-stats { display:grid; grid-template-columns:repeat(auto-fit,minmax(7rem,1fr)); gap:.75rem; margin-bottom:1rem; }
.open-play-stats div { display:grid; gap:.2rem; }
.open-play-stats small { color:#637269; }
.open-play-stats strong { font-size:1.4rem; }
.open-play-table-wrap { overflow-x:auto; }
.open-play-table { width:100%; border-collapse:collapse; text-align:left; font-size:.9rem; }
.open-play-table th,.open-play-table td { border-bottom:1px solid var(--line); padding:.7rem .5rem; vertical-align:top; }
.open-play-table td small { display:block; overflow-wrap:anywhere; }
.open-play-table td details { margin-bottom:.5rem; }
.open-play-table td:last-child { min-width:13rem; }
.open-play-entry { border-color:#5275b7; background:#f0f4ff; }
[data-occurrences][hidden] { display:none; }
@media(max-width:640px){.open-play-list-row{grid-template-columns:repeat(2,minmax(0,1fr));}.open-play-list-row>div:first-child{grid-column:1/-1;}}

/* Compact staff calendar */
.calendar-page { max-width: none; padding:1.25rem clamp(.7rem,2vw,1.5rem) 2rem; }
.calendar-heading { margin-bottom:.7rem; }
.calendar-heading h1 { font-size:1.5rem; margin:.2rem 0; }
.calendar-heading .button { gap:.35rem; }
.calendar-toolbar { display:flex; flex-wrap:wrap; align-items:center; justify-content:space-between; gap:.6rem; padding:.65rem; margin-bottom:.7rem; }
.calendar-toolbar .actions { gap:.35rem; }
.calendar-toolbar input { width:auto; min-width:0; }
.calendar-toolbar .calendar-date { margin-left:auto; align-items:center; }
.calendar-toolbar button,.calendar-toolbar .button { min-height:2.2rem; padding:.3rem .65rem; }
.calendar-icon-button { padding:.35rem; min-width:2.2rem; min-height:2.2rem; }
.calendar-icon-button .booking-icon { flex:0 0 18px; }
.calendar-region { min-width:0; }
.compact-calendar-scroll { overflow:auto; max-height:min(72vh, 850px); border:1px solid var(--line); border-radius:.65rem; background:#fff; scrollbar-gutter:stable; }
.compact-calendar-grid { --slot-height:32px; --header-height:52px; display:grid; position:relative; isolation:isolate; grid-template-columns:72px repeat(var(--court-count),minmax(124px,1fr)); grid-template-rows:var(--header-height) repeat(var(--slot-count),var(--slot-height)); min-width:calc(72px + var(--court-count)*124px); }
.calendar-corner,.calendar-column-header,.calendar-time-label,.calendar-cell { background:#fff; border-bottom:1px solid var(--line); border-right:1px solid var(--line); }
.calendar-corner,.calendar-column-header { position:sticky; top:0; z-index:5; background:var(--brand-tint); }
.calendar-corner { grid-column:1; grid-row:1; left:0; z-index:7; display:flex; align-items:center; padding:.45rem; font-size:.78rem; font-weight:700; }
.calendar-column-header { display:flex; flex-direction:column; justify-content:center; align-items:center; min-width:0; padding:.3rem; text-align:center; overflow:hidden; }
.calendar-column-header strong { font-size:.88rem; max-width:100%; overflow:hidden; text-overflow:ellipsis; white-space:nowrap; }
.calendar-column-header small { font-size:.72rem; color:var(--muted); }
.calendar-time-label { position:sticky; left:0; z-index:4; padding:.3rem .4rem; font-size:.72rem; color:var(--muted); white-space:nowrap; }
.calendar-cell { background:linear-gradient(#fff,#fff); }
.calendar-free-slot { display:flex; align-items:center; justify-content:center; z-index:1; color:#728478; text-decoration:none; border:1px solid transparent; }
.calendar-free-slot span { opacity:.35; font-size:1.15rem; }
.calendar-free-slot:hover,.calendar-free-slot:focus-visible { background:var(--brand-soft); color:var(--brand-ink); border-color:var(--brand-ink); text-decoration:none; }
.calendar-free-slot:hover span,.calendar-free-slot:focus-visible span { opacity:1; }
.calendar-event { z-index:2; display:flex; flex-direction:column; justify-content:flex-start; gap:.12rem; min-width:0; overflow:hidden; margin:2px; border-left:3px solid var(--event-border); background:var(--event-bg); color:var(--event-text); border-radius:4px; padding:.3rem .4rem; text-decoration:none; font-size:.72rem; line-height:1.15; }
.calendar-event:hover { filter:brightness(.97); text-decoration:none; color:var(--event-text); }
.calendar-event-title { font-size:.8rem; font-weight:700; overflow:hidden; text-overflow:ellipsis; white-space:nowrap; }
.calendar-event-time,.calendar-event-status { white-space:nowrap; overflow:hidden; text-overflow:ellipsis; }
.calendar-event--short { flex-direction:row; align-items:center; gap:.3rem; padding:.2rem; }
.calendar-event--short .calendar-event-time { display:none; }
.calendar-event--short .calendar-event-status { margin-left:auto; font-size:.65rem; }
.calendar-event--paid { --event-border:#287c51; --event-bg:#dcece3; --event-text:#164d32; }
.calendar-event--pending { --event-border:#d79a22; --event-bg:#fff0cc; --event-text:#704a0a; }
.calendar-event--unpaid { --event-border:#b66e44; --event-bg:#f6e4d6; --event-text:#754624; }
.calendar-event--open-play { --event-border:#5275b7; --event-bg:#dce7fa; --event-text:#284c89; }
.calendar-event--blocked { --event-border:#9ca3af; --event-bg:#e4e5e8; --event-text:#565d65; }
.calendar-event--open-play { align-items:center; justify-content:center; text-align:center; }
.calendar-event--open-play .calendar-event-title { max-width:100%; }
.calendar-now-line { position:absolute; left:72px; right:0; top:calc(var(--header-height) + var(--now-offset)*var(--slot-height)); height:2px; background:#d35454; z-index:3; pointer-events:none; }
.calendar-closed { grid-row:2; grid-column:2/-1; margin:.5rem; color:var(--muted); }
.calendar-legend { display:flex; flex-wrap:wrap; gap:.45rem 1rem; font-size:.75rem; color:var(--muted); padding:.7rem .15rem; }
.calendar-legend span { display:flex; gap:.35rem; align-items:center; }
.calendar-legend-dot { display:inline-block; width:10px; height:10px; border-radius:2px; background:var(--event-border); }
.calendar-history { border:1px solid var(--line); border-radius:.5rem; padding:.6rem; background:#fff; }
.calendar-history-row { display:grid; grid-template-columns:minmax(0,1fr) 1fr auto; gap:.5rem; font-size:.8rem; padding:.5rem .15rem; border-top:1px solid var(--line); color:inherit; }
.calendar-history-row span { color:var(--muted); }
.calendar-dialog { border:1px solid var(--line); border-radius:.85rem; padding:0; width:min(520px,calc(100vw - 2rem)); max-height:calc(100dvh - 2rem); box-shadow:0 15px 60px #152a2033; color:inherit; background:#fff; }
.calendar-dialog::backdrop { background:rgba(24,38,30,.48); }
.calendar-dialog-header { position:sticky; top:0; z-index:2; display:flex; justify-content:space-between; align-items:center; padding:.55rem 1rem; border-bottom:1px solid var(--line); background:white; }
.calendar-dialog-body { padding:1rem; }
.calendar-dialog-body h2 { margin:0 0 .8rem; font-size:1.25rem; }
.calendar-dialog-body h3 { margin:.8rem 0 .4rem; font-size:1rem; }
.calendar-dialog-body h2:focus { outline:none; }
.calendar-create-choices .survey-choice { display:flex; justify-content:flex-start; align-items:center; gap:.65rem; }
.calendar-create-choices .survey-choice span { flex:1; display:grid; gap:.2rem; }
.calendar-modal-back { display:inline-flex; align-items:center; gap:.25rem; margin-bottom:.5rem; font-size:.82rem; }
.calendar-form-grid { display:grid; grid-template-columns:repeat(2,minmax(0,1fr)); gap:.65rem; }
.calendar-court-picker { border:1px solid var(--line); border-radius:.4rem; display:flex; flex-wrap:wrap; gap:.5rem; padding:.5rem; }
.calendar-court-picker legend { font-size:.85rem; font-weight:600; }
.calendar-modal-form > button { justify-self:stretch; }
[data-calendar-occurrences][hidden],[data-calendar-errors][hidden],.calendar-toast[hidden],.calendar-verify[hidden] { display:none!important; }
.calendar-record-title { display:grid; gap:.25rem; padding:.65rem 0; }
.calendar-record-title strong { font-size:1.15rem; }
.calendar-detail-list { margin:.6rem 0; border-block:1px solid var(--line); padding:.4rem 0; }
.calendar-detail-list div { display:flex; justify-content:space-between; gap:1rem; padding:.35rem 0; font-size:.87rem; }
.calendar-detail-list dt { color:var(--muted); }
.calendar-detail-list dd { margin:0; font-weight:600; text-align:right; overflow-wrap:anywhere; }
.calendar-payment-summary { display:flex; align-items:center; justify-content:space-between; gap:.5rem; margin:.75rem 0; }
.calendar-payment-summary div { display:grid; gap:.25rem; }
.calendar-payment-summary div:last-child { justify-items:end; }
.calendar-payment-summary strong { font-size:1.35rem; }
.calendar-payment-summary small { color:var(--muted); }
.calendar-modal-actions { gap:.35rem; margin:.5rem 0; }
.calendar-modal-actions .button { gap:.3rem; font-size:.82rem; }
.calendar-verify,.calendar-danger { padding:.65rem 0; border-top:1px solid var(--line); margin-top:.5rem; }
.calendar-verify summary,.calendar-danger summary { cursor:pointer; font-size:.88rem; font-weight:600; }
.calendar-danger summary { color:#a13e35; }
.calendar-verify form,.calendar-danger form { margin-top:.6rem; }
.calendar-session-stats { display:grid; grid-template-columns:repeat(2,1fr); gap:.5rem; margin:.5rem 0; }
.calendar-session-stats div { display:grid; gap:.2rem; padding:.5rem .6rem; background:var(--brand-tint); border-radius:.4rem; }
.calendar-session-stats small { color:var(--muted); font-size:.75rem; }
.calendar-session-stats strong { font-size:1.1rem; }
.calendar-player-list { margin:.4rem 0 .8rem; }
.calendar-player { display:flex; flex-wrap:wrap; align-items:center; justify-content:space-between; gap:.5rem; padding:.5rem 0; border-bottom:1px solid var(--line); font-size:.82rem; }
.calendar-player strong { flex:1; }
.calendar-skeleton { display:grid; gap:.65rem; }
.calendar-skeleton span { display:block; background:var(--brand-soft); height:2.3rem; border-radius:.35rem; }
.calendar-skeleton span:first-child { width:55%; }
.calendar-toast { border:1px solid #afc9b3; background:#edf7ef; padding:.5rem .7rem; border-radius:.4rem; margin-bottom:.5rem; }
.calendar-toast.error { background:#fff1ef; border-color:#e0b2ac; }
.calendar-event:focus-visible,.calendar-free-slot:focus-visible,.calendar-dialog button:focus-visible { outline:2px solid var(--brand-focus); outline-offset:1px; }
@media(max-width:640px) {
    .calendar-page { padding:.75rem .5rem 1.5rem; }
    .calendar-toolbar { padding:.45rem; }
    .calendar-toolbar .calendar-date { margin-left:0; flex:1 1 100%; }
    .compact-calendar-scroll { max-height:65dvh; }
    .compact-calendar-grid { --slot-height:34px; grid-template-columns:63px repeat(var(--court-count),minmax(115px,1fr)); min-width:calc(63px + var(--court-count)*115px); }
    .calendar-now-line { left:63px; }
    .calendar-dialog { margin:auto 0 0; width:100%; max-width:none; max-height:90dvh; border-radius:.85rem .85rem 0 0; }
    .calendar-dialog-body { padding:.85rem .85rem max(.85rem,env(safe-area-inset-bottom)); }
    .calendar-history-row { grid-template-columns:1fr auto; }
    .calendar-history-row span:first-of-type { grid-row:2; }
}

/* Venue website configuration and booking type chooser */
.website-settings-grid { display:grid; grid-template-columns:minmax(0,1.4fr) minmax(0,1fr); align-items:start; gap:1rem; }
.website-settings-grid textarea { width:100%; resize:vertical; font:inherit; border:1px solid #aeb7b3; border-radius:.5rem; padding:.6rem; color:var(--ink); }
.website-facility-grid { display:grid; grid-template-columns:repeat(2,minmax(0,1fr)); gap:.65rem; }
.website-gallery-preview { width:100%; max-height:180px; object-fit:cover; border-radius:.5rem; }
.booking-back { font-size:.84rem; color:var(--muted); margin:.75rem 0; }
.booking-type-menu .survey-choice { gap:.75rem; padding:1rem; }
.booking-type-menu .survey-choice span { flex:1; }
.booking-type-menu h2 { margin-bottom:.25rem; }
@media(max-width:720px){.website-settings-grid{grid-template-columns:minmax(0,1fr)}}

/* Brand accents on survey controls, rates and shared navigation. */
.booking-type-menu .booking-icon,.survey-panel h2 .booking-icon,.survey-choice > .booking-icon { color:var(--brand-ink); }
.survey-progress li.complete { background:var(--brand-ink); }
.booking-details,.open-play-card { border-color:var(--brand-border); }
.survey-step,.compact-payment .price { color:var(--brand-ink); }
.quiet { border-color:transparent; }
.secondary:hover,.quiet:hover { color:var(--brand-ink); }

/* Multi-venue workspace and platform admin */
.workspace-strip { padding-block:.4rem; border-top:1px solid var(--line); justify-content:flex-start; gap:.65rem; }
.workspace-strip > a { margin-left:auto; font-size:.84rem; }
.tenant-venue-list { display:grid; gap:.65rem; }
.tenant-venue-card { display:grid; grid-template-columns:12px minmax(0,1fr) auto; align-items:center; gap:.85rem; }
.tenant-color { height:100%; min-height:36px; border-radius:5px; }
.tenant-venue-card .button { gap:.3rem; }
.tenant-stats { display:grid; grid-template-columns:repeat(4,minmax(0,1fr)); gap:.65rem; margin-bottom:1rem; }
.tenant-stats > div { display:grid; gap:.35rem; }
.tenant-stats strong { font-size:1.4rem; }
.tenant-panel { margin-top:1rem; }
.tenant-table-scroll { overflow:auto; margin-top:.6rem; }
.tenant-table { border-collapse:collapse; width:100%; font-size:.85rem; }
.tenant-table th,.tenant-table td { padding:.65rem; text-align:left; vertical-align:top; border-bottom:1px solid var(--line); }
.tenant-table th { position:sticky; top:0; background:var(--brand-tint); white-space:nowrap; }
.tenant-table td { overflow-wrap:anywhere; }
.tenant-table td details { min-width:185px; }
.tenant-table td details form { margin-top:.5rem; }
.tenant-form-grid { display:grid; grid-template-columns:repeat(2,minmax(0,1fr)); gap:.75rem; }
.tenant-pagination { margin-top:.65rem; }
@media(max-width:640px){.tenant-stats{grid-template-columns:repeat(2,minmax(0,1fr))}.tenant-venue-card{grid-template-columns:10px minmax(0,1fr)}.tenant-venue-card .actions{grid-column:2}.tenant-form-grid{grid-template-columns:1fr}}
