/* Higginshaw Hall Bookings: club colours and fonts (matching the main website) */
@font-face { font-family: 'Inter'; font-style: normal; font-weight: 400 700; font-display: swap; src: url(/fonts/inter-latin.woff2) format('woff2'); }
@font-face { font-family: 'Oswald'; font-style: normal; font-weight: 500 600; font-display: swap; src: url(/fonts/oswald-latin.woff2) format('woff2'); }

:root {
  --brand: #14213d;
  --brand-2: #1f3a6e;
  --accent: #f2a900;
  --ink: #1d1f23;
  --muted: #5b6270;
  --line: #e2e5ea;
  --bg-alt: #f4f5f7;
  --ok: #1d7a46;
  --err: #b42318;
  --radius: 10px;
  --head: "Oswald", "Arial Narrow", Arial, sans-serif;
  --body: "Inter", system-ui, -apple-system, "Segoe UI", Roboto, Arial, sans-serif;
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; font-family: var(--body); color: var(--ink); background: #fff; line-height: 1.55; font-size: 16px; }
img { max-width: 100%; height: auto; display: block; }
a { color: var(--brand-2); }
p, li { overflow-wrap: anywhere; }
h1, h2, h3 { font-family: var(--head); color: var(--brand); text-transform: uppercase; line-height: 1.15; letter-spacing: .01em; }
h1 { font-size: clamp(1.6rem, 5vw, 2.2rem); margin: .2em 0 .5em; }
h2 { font-size: 1.3rem; margin: 1.6em 0 .6em; }
h3 { font-size: 1.1rem; margin: 1.2em 0 .4em; }

.wrap { width: 100%; max-width: 1080px; margin: 0 auto; padding: 0 16px; }
.main { padding-top: 20px; padding-bottom: 48px; min-height: 60vh; }

/* Header */
.top { background: #fff; border-bottom: 1px solid var(--line); position: sticky; top: 0; z-index: 20; }
.top-inner { display: flex; align-items: center; justify-content: space-between; gap: 12px; min-height: 64px; flex-wrap: wrap; }
.brand { display: flex; align-items: center; gap: 10px; text-decoration: none; color: var(--brand); }
.brand span { font-family: var(--head); font-size: 1.05rem; text-transform: uppercase; line-height: 1.05; }
.nav { display: flex; align-items: center; gap: 4px; flex-wrap: wrap; }
.nav a, .linklike { padding: 8px 10px; border-radius: 6px; text-decoration: none; color: var(--ink); font-weight: 600; font-size: .95rem; white-space: nowrap; }
.nav a:hover, .linklike:hover { background: var(--bg-alt); color: var(--brand); }
.linklike { background: none; border: 0; cursor: pointer; font: inherit; font-weight: 600; font-size: .95rem; }
form.inline { display: inline; margin: 0; }

/* Footer */
.foot { background: var(--brand); color: #dfe4ee; padding: 24px 0; font-size: .9rem; }
.foot a { color: #fff; }

/* Buttons */
.btn { display: inline-block; padding: 12px 22px; min-height: 44px; border-radius: 999px; background: var(--accent); color: var(--brand); font-weight: 700; text-decoration: none; border: 0; cursor: pointer; font-size: 1rem; font-family: inherit; text-align: center; }
.btn:hover { filter: brightness(1.06); }
.btn-navy { background: var(--brand); color: #fff; }
.btn-ghost { background: transparent; color: var(--brand); box-shadow: inset 0 0 0 2px var(--brand); }
.btn-danger { background: var(--err); color: #fff; }
.btn-small { padding: 8px 14px; min-height: 36px; font-size: .9rem; white-space: nowrap; }
.btn-row { display: flex; flex-wrap: wrap; gap: 10px; margin: 16px 0; }
button:disabled { opacity: .6; cursor: wait; }

/* Forms */
.form { max-width: 520px; }
.form label { display: block; font-weight: 600; margin: 14px 0 4px; }
.form .hint { font-weight: 400; color: var(--muted); font-size: .9rem; }
input[type=text], input[type=email], input[type=tel], input[type=password], input[type=number], input[type=date], select, textarea {
  width: 100%; padding: 11px 12px; border: 1px solid #c9ced6; border-radius: 8px; font: inherit; background: #fff; color: var(--ink);
}
input:focus, select:focus, textarea:focus { outline: 3px solid rgba(242,169,0,.45); border-color: var(--accent); }
textarea { min-height: 96px; resize: vertical; }
.row2 { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
@media (max-width: 480px) { .row2 { grid-template-columns: 1fr; } }
.check { display: flex; gap: 8px; align-items: center; font-weight: 600; margin-top: 14px; }
.hp { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }
.cf-turnstile { margin: 16px 0 4px; min-height: 65px; }
.note { font-size: .85rem; color: var(--muted); }

/* Messages */
.msg { padding: 12px 14px; border-radius: 8px; margin: 12px 0; font-weight: 600; }
.msg-ok { background: #e7f6ec; color: var(--ok); border: 1px solid #b7e3c6; }
.msg-err { background: #fdecea; color: var(--err); border: 1px solid #f5c2bc; }
.msg-info { background: #fff6dc; color: #7a5300; border: 1px solid #f3dc9a; }

/* Cards and lists */
.card { border: 1px solid var(--line); border-radius: var(--radius); padding: 16px; margin: 12px 0; background: #fff; }
.card h3 { margin-top: 0; }
.when { background: var(--bg-alt); border-left: 4px solid var(--accent); border-radius: 4px; padding: 10px 14px; margin: 10px 0; font-weight: 600; color: var(--brand); }
.when li { margin: 2px 0; }
.pill { display: inline-block; padding: 2px 10px; border-radius: 999px; font-size: .8rem; font-weight: 700; text-transform: uppercase; letter-spacing: .02em; }
.pill-pending { background: #fff6dc; color: #7a5300; }
.pill-accepted { background: #e7f6ec; color: var(--ok); }
.pill-declined, .pill-cancelled { background: #f1f2f4; color: var(--muted); }
.kv { width: 100%; border-collapse: collapse; }
.kv td { padding: 6px 8px 6px 0; vertical-align: top; border-bottom: 1px solid var(--line); }
.kv td:first-child { color: var(--muted); width: 38%; }
.muted { color: var(--muted); }

/* Week calendar */
.pick-date { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; margin: 12px 0 4px; }
.pick-date label { font-weight: 600; }
.pick-date input { width: auto; }
.week-nav { display: flex; align-items: center; justify-content: space-between; gap: 8px; margin: 18px 0 8px; }
.week-title { margin: 0; font-size: 1.05rem; text-align: center; }
.legend { list-style: none; display: flex; flex-wrap: wrap; gap: 6px 16px; padding: 0; margin: 0 0 10px; font-size: .85rem; color: var(--muted); }
.legend li { display: flex; align-items: center; gap: 6px; }
.swatch { display: inline-block; width: 16px; height: 16px; border-radius: 4px; border: 1px solid var(--line); }
.grid-scroll { overflow-x: auto; -webkit-overflow-scrolling: touch; border: 1px solid var(--line); border-radius: var(--radius); }
.grid { border-collapse: separate; border-spacing: 2px; width: 100%; min-width: 340px; table-layout: fixed; font-size: .8rem; }
.grid th { font-weight: 600; color: var(--brand); padding: 4px 2px; text-align: center; position: sticky; top: 0; background: #fff; }
.grid th.t { width: 44px; text-align: right; padding-right: 6px; color: var(--muted); font-weight: 500; position: static; }
.grid tbody th.t { vertical-align: top; font-size: .75rem; }
.grid td { height: 26px; border-radius: 4px; padding: 0; }
.grid td a { display: block; width: 100%; height: 100%; min-height: 26px; }
.cell-free { background: #d6f2df; }
.cell-free:hover, .cell-free a:focus { background: #9fdcb3; outline: none; }
.cell-unavailable { background: #f4d6a6; }
.cell-unavailable a { color: var(--brand); font-size: .7rem; line-height: 1.1; padding: 2px; overflow: hidden; text-decoration: none; white-space: nowrap; text-overflow: ellipsis; }
.cell-closed { background: repeating-linear-gradient(45deg, #eceef1, #eceef1 4px, #f6f7f9 4px, #f6f7f9 8px); }
.cell-past { background: #f1f2f4; }
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.slots { list-style: none; padding: 0; }
@media (min-width: 720px) { .grid { font-size: .85rem; } .grid td, .grid td a { height: 30px; min-height: 30px; } }
.slot-row { border-top: 1px solid var(--line); padding: 10px 0; }
.slot-row:first-child { border-top: 0; }
.slot-row .btn-row { margin: 8px 0 0; }
details summary { cursor: pointer; font-weight: 600; }
.hours { border-collapse: collapse; margin: 8px 0; }
.hours th { text-align: left; padding: 6px 10px 6px 0; font-weight: 600; }
.hours td { padding: 4px 6px 4px 0; }
.hours select { width: auto; }
.hours .check { margin: 0; font-weight: 500; }
.form.wide { max-width: 720px; }
.feed-url code { display: block; padding: 10px 12px; background: var(--bg-alt); border-radius: 8px; overflow-wrap: anywhere; font-size: .85rem; }
@media (max-width: 520px) { .hours, .hours tbody, .hours tr { display: block; } .hours tr { padding: 8px 0; border-bottom: 1px solid var(--line); } .hours th, .hours td { display: inline-block; } .hours th { display: block; } }
