/* ============================================================
   LUDLOW RACECOURSE
   Editorial ivory + royal blue + coral · real photography
   Chalked bookies boards for data
   Legacy var names kept: green = royal blue, gold = coral
   ============================================================ */

:root {
  --ivory: #f5f1e7;
  --ivory-2: #efe9db;
  --paper: #fbf8f1;
  --ink: #1a231d;
  --ink-soft: #4a544c;
  --green: #273851;
  --green-deep: #1d2b40;
  --green-black: #141e2e;
  --gold: #ed7162;
  --gold-bright: #f79288;
  --gold-deep: #c14b3d; /* coral for small text on light backgrounds (contrast) */
  --chalk: #f4eedd;
  --chalk-dim: rgba(244, 238, 221, .55);
  --chalk-yellow: #ffd977;
  --board: #131710;
  --font-display: "Fraunces", Georgia, serif;
  --font-body: "Manrope", system-ui, sans-serif;
  --font-chalk: "Caveat", cursive;
}

* { margin: 0; padding: 0; box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: calc(var(--banner-h, 0px) + 90px); }
body {
  font-family: var(--font-body);
  background: var(--ivory);
  color: var(--ink);
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}
img { max-width: 100%; display: block; }
a { color: inherit; }

.wrap { width: min(1280px, 92vw); margin-inline: auto; }
.wrap-narrow { width: min(920px, 92vw); margin-inline: auto; }

/* ---------------- Header ---------------- */
.site-header {
  position: fixed; top: var(--banner-h, 0); left: 0; right: 0; z-index: 200;
  display: flex; align-items: center; justify-content: space-between;
  padding: 1rem clamp(1.2rem, 4vw, 3rem);
  transition: background .35s, box-shadow .35s, padding .35s;
}
.site-header .logo { height: 64px; width: auto; transition: height .35s; }
.site-header .logo-light { display: block; }
.site-header .logo-dark { display: none; }
.site-header.solid {
  background: rgba(245, 241, 231, .96);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  box-shadow: 0 1px 0 rgba(26,35,29,.08), 0 10px 30px rgba(26,35,29,.06);
  padding-block: .6rem;
}
.site-header.solid .logo { height: 52px; }
.site-header.solid .logo-light { display: none; }
.site-header.solid .logo-dark { display: block; }

.main-nav { display: flex; align-items: center; gap: clamp(1rem, 2.4vw, 2.2rem); }
.main-nav > a {
  text-decoration: none;
  font-size: .8rem; font-weight: 700; letter-spacing: .18em; text-transform: uppercase;
  color: #fff; opacity: .92; transition: color .25s, opacity .2s;
  padding-bottom: .3rem; border-bottom: 1px solid transparent;
}
.main-nav > a:hover { opacity: 1; border-bottom-color: currentColor; }
.site-header.solid .main-nav > a { color: var(--ink); }
.main-nav > a[aria-current="page"] { border-bottom-color: var(--gold); color: var(--gold-bright); }
.site-header.solid .main-nav > a[aria-current="page"] { color: var(--green); border-bottom-color: var(--gold); }

.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: .6rem;
  padding: .95rem 1.9rem;
  font-weight: 700; font-size: .8rem; letter-spacing: .18em; text-transform: uppercase;
  text-decoration: none; cursor: pointer; border: 0;
  transition: background .25s, color .25s, transform .25s, box-shadow .25s;
}
.btn-gold, .main-nav > a.btn-gold { background: var(--gold); color: var(--green-black); }
.btn-gold:hover { background: var(--gold-bright); transform: translateY(-2px); box-shadow: 0 10px 26px rgba(237,113,98,.4); }
/* Softer corners on every button; Book Tickets also carries a slow coral halo
   so it is the first thing a visitor notices. Still for reduced-motion users. */
.btn { border-radius: 9px; }
a[data-ticket].btn-gold {
  box-shadow: 0 0 0 0 rgba(237,113,98,.55), 0 0 18px rgba(237,113,98,.5);
  animation: ticketHalo 2.6s ease-out infinite;
}
a[data-ticket].btn-gold:hover { animation: none; box-shadow: 0 0 0 4px rgba(237,113,98,.28), 0 0 30px rgba(243,138,123,.75); }
@keyframes ticketHalo {
  0%   { box-shadow: 0 0 0 0 rgba(237,113,98,.6), 0 0 16px rgba(237,113,98,.45); }
  70%  { box-shadow: 0 0 0 13px rgba(237,113,98,0), 0 0 28px rgba(237,113,98,.7); }
  100% { box-shadow: 0 0 0 0 rgba(237,113,98,0), 0 0 16px rgba(237,113,98,.45); }
}
@media (prefers-reduced-motion: reduce) { a[data-ticket].btn-gold { animation: none; } }
/* The nav link rule above gives every header link a short bottom padding for its
   underline, which left the Book Tickets label sitting low in its button. */
.main-nav > a.btn { padding: .85rem 1.6rem; border-bottom: 0; }
.btn-line { border: 1px solid rgba(255,255,255,.55); color: #fff; background: transparent; }
.btn-line:hover { background: #fff; color: var(--ink); }
.btn-green { background: var(--green); color: var(--ivory); }
.btn-green:hover { background: var(--green-deep); transform: translateY(-2px); }
.nav-toggle { display: none; background: none; border: 0; font-size: 1.7rem; color: #fff; cursor: pointer; z-index: 210; }
.site-header.solid .nav-toggle { color: var(--ink); }

/* ---------------- Hero (video) ---------------- */
.hero {
  position: relative; min-height: 100svh;
  display: flex; flex-direction: column; justify-content: flex-end;
  color: #fff; overflow: hidden;
  background: var(--green-black);
}
.hero video, .hero .hero-fallback {
  position: absolute; inset: 0; width: 100%; height: 100%;
  object-fit: cover; object-position: center 40%;
}
.hero::after {
  content: ""; position: absolute; inset: 0;
  background:
    linear-gradient(180deg, rgba(20,30,46,.55) 0%, rgba(20,30,46,.15) 35%, rgba(20,30,46,.55) 72%, rgba(20,30,46,.92) 100%);
}
.hero-inner {
  position: relative; z-index: 2;
  padding-bottom: clamp(6rem, 12vh, 9rem);
}
.hero .kicker { color: var(--gold-bright); }
.hero h1 {
  font-family: var(--font-display); font-weight: 500;
  font-size: clamp(2.6rem, 6.4vw, 5.4rem);
  line-height: 1.04; letter-spacing: -.015em;
  max-width: 16ch; margin: 1.2rem 0 1.4rem;
  text-shadow: 0 2px 40px rgba(0,0,0,.45);
}
.hero h1 em { font-style: italic; color: var(--gold-bright); }
.hero .lede {
  max-width: 52ch; font-size: clamp(1rem, 1.3vw, 1.15rem);
  line-height: 1.7; color: rgba(255,255,255,.88);
}
.hero-cta { display: flex; flex-wrap: wrap; gap: 1rem; margin-top: 2.2rem; }

/* next raceday bar riding the hero bottom */
.next-bar {
  position: absolute; left: 0; right: 0; bottom: 0; z-index: 3;
  background: rgba(20, 30, 46, .82);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  border-top: 1px solid rgba(247,146,136,.45);
}
.next-bar-inner {
  display: flex; flex-wrap: wrap; align-items: center; gap: 1.2rem 2.5rem;
  padding: 1.1rem 0;
}
.next-bar .label {
  font-size: .68rem; font-weight: 800; letter-spacing: .3em; text-transform: uppercase;
  color: var(--gold-bright);
}
.next-bar .meeting {
  font-family: var(--font-display); font-size: clamp(1.05rem, 1.8vw, 1.35rem);
  font-style: italic; color: #fff;
}
.next-bar .cd {
  display: flex; gap: 1.3rem; margin-left: auto;
  font-variant-numeric: tabular-nums;
}
.next-bar .cd div { text-align: center; }
.next-bar .cd b {
  display: block; font-family: var(--font-display); font-weight: 500;
  font-size: clamp(1.2rem, 2vw, 1.6rem); color: var(--gold-bright); line-height: 1;
}
.next-bar .cd span {
  font-size: .58rem; letter-spacing: .26em; text-transform: uppercase;
  color: rgba(255,255,255,.55);
}
.next-bar .book { white-space: nowrap; }

/* ---------------- Raceday strip ---------------- */
.raceday-strip {
  background: var(--green-deep);
  border-bottom: 1px solid rgba(247,146,136,.35);
}
.raceday-strip-inner {
  display: flex; flex-wrap: wrap; align-items: center;
  gap: .4rem 2.2rem; padding: .8rem 0;
}
.rs-item {
  font-size: .78rem; letter-spacing: .08em; color: rgba(245,241,231,.8);
}
.rs-item b {
  font-size: .64rem; font-weight: 800; letter-spacing: .26em; text-transform: uppercase;
  color: var(--gold-bright); margin-right: .5rem;
}
.rs-stamp { margin-left: auto; color: rgba(245,241,231,.5); }

/* ---------------- Generic section bits ---------------- */
section { position: relative; }
.section-pad { padding: clamp(4.5rem, 9vw, 8.5rem) 0; }
.kicker {
  font-size: .72rem; font-weight: 800; letter-spacing: .34em; text-transform: uppercase;
  color: var(--gold-deep);
  display: inline-flex; align-items: center; gap: .9rem;
}
.kicker::before { content: ""; width: 44px; height: 1px; background: currentColor; opacity: .7; }
h2.title {
  font-family: var(--font-display); font-weight: 500;
  font-size: clamp(2rem, 4.2vw, 3.4rem); line-height: 1.1; letter-spacing: -.01em;
  margin: 1rem 0 1.1rem;
}
h2.title em { font-style: italic; color: var(--gold-deep); }
/* Keep the coral italic phrases on one line — they read as a unit */
h1 em, h2.title em { white-space: nowrap; }
@media (max-width: 600px) {
  /* long phrases that can't fit on one 92vw line at phone sizes */
  h1 em.em-wrap, h2.title em.em-wrap { white-space: normal; }
}
@media (max-width: 360px) {
  /* very narrow devices: let all heading phrases wrap rather than overflow */
  h1 em, h2.title em { white-space: normal; }
}
.sub { color: var(--ink-soft); line-height: 1.75; max-width: 62ch; font-size: 1.02rem; }

.reveal { opacity: 0; transform: translateY(30px); transition: opacity .9s ease, transform .9s cubic-bezier(.2,.7,.3,1); }
.reveal.in { opacity: 1; transform: none; }

/* ---------------- Stats rail ---------------- */
.stats-rail {
  border-block: 1px solid rgba(26,35,29,.14);
  background: var(--paper);
}
.stats-rail-inner {
  display: grid; grid-template-columns: repeat(auto-fit, minmax(min(200px, 100%), 1fr));
}
.stat {
  padding: 2.4rem 1.6rem; text-align: center;
  border-left: 1px solid rgba(26,35,29,.1);
}
.stat:first-child { border-left: 0; }
.stat b {
  display: block; font-family: var(--font-display); font-weight: 500;
  font-size: clamp(2.2rem, 3.6vw, 3.2rem); color: var(--green); line-height: 1.05;
}
.stat b sup { font-size: .45em; color: var(--gold-deep); }
.stat span {
  display: block; margin-top: .5rem;
  font-size: .7rem; font-weight: 700; letter-spacing: .24em; text-transform: uppercase;
  color: var(--ink-soft);
}

/* ---------------- Editorial split ---------------- */
.split { display: grid; gap: clamp(2rem, 5vw, 5rem); align-items: center; }
.split.two { grid-template-columns: repeat(auto-fit, minmax(min(420px, 100%), 1fr)); }
.frame { position: relative; }
.frame img { width: 100%; height: 100%; object-fit: cover; box-shadow: 0 30px 70px rgba(26,35,29,.25); }
.frame::after {
  content: ""; position: absolute; inset: 1.1rem; pointer-events: none;
  border: 1px solid rgba(255,255,255,.55);
}
.frame .caption {
  position: absolute; left: 0; bottom: -1.1rem; transform: translateY(100%);
  font-size: .72rem; letter-spacing: .2em; text-transform: uppercase; color: var(--ink-soft);
}

/* ---------------- Betting ring / chalk boards ---------------- */
.ring {
  background:
    linear-gradient(rgba(20,30,46,.88), rgba(20,30,46,.94)),
    url("assets/betting-ring.jpg") center 30%/cover no-repeat;
  color: var(--chalk);
}
.ring .kicker { color: var(--gold-bright); }
.ring h2.title { color: #fff; }
.ring h2.title em { color: var(--gold-bright); }
.ring .sub { color: rgba(244,238,221,.72); }

.boards {
  margin-top: 3.5rem;
  display: grid; gap: clamp(1.6rem, 3.5vw, 3rem);
  grid-template-columns: repeat(auto-fit, minmax(min(430px, 100%), 1fr));
  align-items: start;
}
.chalkboard {
  background:
    radial-gradient(120% 90% at 30% 10%, rgba(255,255,255,.045), transparent 60%),
    radial-gradient(100% 80% at 80% 90%, rgba(255,255,255,.03), transparent 55%),
    var(--board);
  border: 10px solid #e8e2d2;
  outline: 1px solid rgba(0,0,0,.35);
  box-shadow:
    0 2px 0 rgba(255,255,255,.15) inset,
    0 34px 70px rgba(0,0,0,.55);
  padding: clamp(1.4rem, 3vw, 2.4rem);
  position: relative;
}
.chalkboard.tilt-l { transform: rotate(-1.1deg); }
.chalkboard.tilt-r { transform: rotate(.9deg); }
.chalkboard .board-title {
  font-family: var(--font-chalk); font-weight: 700;
  font-size: clamp(1.7rem, 2.6vw, 2.2rem);
  color: var(--chalk-yellow);
  text-align: center; letter-spacing: .04em;
  border-bottom: 2px dashed rgba(244,238,221,.28);
  padding-bottom: .7rem; margin-bottom: 1.1rem;
  text-shadow: 0 0 1px rgba(255,217,119,.5);
}
.chalkboard .board-sub {
  font-family: var(--font-chalk); font-size: 1.15rem; color: var(--chalk-dim);
  text-align: center; margin: -0.6rem 0 1rem;
}
.chalk-row {
  display: flex; align-items: baseline; gap: .8rem;
  font-family: var(--font-chalk); font-weight: 600;
  font-size: clamp(1.25rem, 1.9vw, 1.55rem);
  color: var(--chalk);
  padding: .42rem 0;
  text-decoration: none;
  transition: transform .2s;
}
a.chalk-row:hover { transform: translateX(6px); }
a.chalk-row:hover .odds { color: #fff; }
.chalk-row .when { color: var(--chalk-dim); font-size: .82em; min-width: 6.2ch; }
.chalk-row .runner { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.chalk-row .dots {
  flex: 1; border-bottom: 2px dotted rgba(244,238,221,.32);
  transform: translateY(-.35em); min-width: 20px;
}
.chalk-row .odds { color: var(--chalk-yellow); white-space: nowrap; }
.chalk-row.feature .runner, .chalk-row.feature .when { color: var(--chalk-yellow); }
.chalk-row.feature .odds { color: #fff; }
.chalk-row .chip {
  font-size: .6em; letter-spacing: .08em; color: var(--green-black);
  background: var(--chalk-yellow); border-radius: 3px; padding: .06em .5em;
  transform: rotate(-2deg);
}
.chalk-note {
  margin-top: 1.1rem; padding-top: .8rem;
  border-top: 2px dashed rgba(244,238,221,.28);
  font-family: var(--font-chalk); font-size: 1.2rem; color: var(--chalk-dim);
  text-align: center;
}
.chalk-note b { color: var(--chalk-yellow); font-weight: 700; }

/* ---------------- Almanac / facts — editorial entries ---------------- */
.almanac { background: var(--ivory); }
.almanac-grid {
  margin-top: 2.4rem;
  display: grid; gap: 0 4.5rem;
  grid-template-columns: repeat(auto-fit, minmax(min(420px, 100%), 1fr));
}
.fact {
  display: flex; gap: 1.7rem; align-items: flex-start;
  padding: 2.4rem 0 2.6rem;
  border-top: 1px solid rgba(26,35,29,.16);
}
.fact-no {
  flex: 0 0 auto;
  font-family: var(--font-display); font-style: italic; font-weight: 400;
  font-size: 3.6rem; line-height: .8; margin-top: .2rem;
  color: rgba(39,56,81,.22);
  -webkit-text-stroke: 1px rgba(39,56,81,.45);
  -webkit-text-fill-color: transparent;
  font-variant-numeric: tabular-nums;
  transition: color .3s, -webkit-text-stroke-color .3s;
}
.fact:hover .fact-no {
  -webkit-text-stroke-color: var(--gold);
  color: rgba(237,113,98,.25);
}
.fact-body { display: flex; flex-direction: column; gap: .55rem; }
.fact-tag {
  font-size: .62rem; font-weight: 800; letter-spacing: .28em; text-transform: uppercase;
  color: var(--gold-deep);
}
.fact h3 {
  font-family: var(--font-display); font-weight: 500;
  font-size: clamp(1.3rem, 1.7vw, 1.55rem); line-height: 1.2; letter-spacing: -.005em;
}
.fact p { color: var(--ink-soft); line-height: 1.7; font-size: .95rem; max-width: 54ch; }
@media (max-width: 560px) {
  .fact { gap: 1.2rem; padding: 1.9rem 0 2rem; }
  .fact-no { font-size: 2.6rem; }
}

/* ---------------- Records / timing board ---------------- */
.records { background: var(--green); color: var(--ivory); }
.records .kicker { color: var(--gold-bright); }
.records h2.title { color: #fff; }
.records h2.title em { color: var(--gold-bright); }
.records .sub { color: rgba(245,241,231,.7); }
.timing-table {
  margin-top: 3rem; width: 100%;
  border-collapse: collapse;
  font-variant-numeric: tabular-nums;
}
.timing-table th {
  text-align: left; font-size: .66rem; letter-spacing: .28em; text-transform: uppercase;
  color: rgba(245,241,231,.55); font-weight: 700;
  padding: .9rem .8rem; border-bottom: 1px solid rgba(247,146,136,.4);
}
.timing-table td {
  padding: 1.05rem .8rem;
  border-bottom: 1px solid rgba(245,241,231,.12);
  font-size: .98rem;
}
.timing-table td.horse {
  font-family: var(--font-display); font-style: italic; font-size: 1.2rem; color: #fff;
}
.timing-table td.time { color: var(--gold-bright); font-weight: 700; letter-spacing: .06em; }
.timing-table td.dist, .timing-table td.year { color: rgba(245,241,231,.75); }
.timing-table tr:hover td { background: rgba(255,255,255,.04); }
.records .foot {
  margin-top: 1.2rem; font-size: .74rem; letter-spacing: .12em; text-transform: uppercase;
  color: rgba(245,241,231,.45);
}

/* ---------------- Hospitality ---------------- */
.hosp-cards {
  margin-top: 3rem;
  display: grid; gap: 1.5rem;
  grid-template-columns: repeat(auto-fit, minmax(min(300px, 100%), 1fr));
}
.hosp-card {
  background: var(--paper); border: 1px solid rgba(26,35,29,.12);
  display: flex; flex-direction: column;
  text-decoration: none;
  transition: transform .3s, box-shadow .3s;
  box-shadow: 0 14px 34px rgba(26,35,29,.07);
}
.hosp-card:hover { transform: translateY(-6px); box-shadow: 0 28px 56px rgba(26,35,29,.14); }
.hosp-card .ph { aspect-ratio: 16/10; overflow: hidden; }
.hosp-card .ph img { width: 100%; height: 100%; object-fit: cover; transition: transform .6s; }
.hosp-card:hover .ph img { transform: scale(1.05); }
.hosp-card .body { padding: 1.6rem 1.6rem 1.5rem; display: flex; flex-direction: column; gap: .6rem; flex: 1; }
.hosp-card h3 { font-family: var(--font-display); font-weight: 600; font-size: 1.3rem; }
.hosp-card p { color: var(--ink-soft); font-size: .93rem; line-height: 1.65; }
.hosp-card .price {
  margin-top: auto; padding-top: 1rem;
  font-family: var(--font-display); font-style: italic; font-size: 1.05rem; color: var(--green);
}
.hosp-card .price b { color: var(--gold-deep); font-style: normal; font-family: var(--font-body); font-weight: 800; }

/* ---------------- Heritage band ---------------- */
.heritage {
  background:
    linear-gradient(rgba(20,30,46,.72), rgba(20,30,46,.82)),
    url("assets/grandstand.jpg") center 35%/cover no-repeat;
  background-attachment: fixed;
  color: #fff; text-align: center;
}
@supports (-webkit-touch-callout: none) { .heritage { background-attachment: scroll; } }
.heritage blockquote {
  font-family: var(--font-display); font-style: italic; font-weight: 400;
  font-size: clamp(1.6rem, 3.4vw, 2.6rem); line-height: 1.35;
  max-width: 30ch; margin: 0 auto;
}
.heritage blockquote em { color: var(--gold-bright); }
.timeline {
  margin: 3.5rem auto 0; display: flex; flex-wrap: wrap; justify-content: center;
  gap: 0; max-width: 1000px;
}
.tl-item {
  flex: 1 1 150px; padding: 0 1.2rem 0; position: relative;
  border-top: 1px solid rgba(247,146,136,.5);
  padding-top: 1.4rem; margin-top: .5rem;
}
.tl-item::before {
  content: ""; position: absolute; top: -5px; left: 50%; transform: translateX(-50%);
  width: 9px; height: 9px; border-radius: 50%; background: var(--gold-bright);
}
.tl-item b {
  display: block; font-family: var(--font-display); font-weight: 500;
  font-size: 1.6rem; color: var(--gold-bright);
}
.tl-item span { font-size: .8rem; color: rgba(255,255,255,.75); line-height: 1.5; display: block; margin-top: .3rem; }

/* ---------------- Visit strip ---------------- */
.visit-grid {
  margin-top: 3rem; display: grid; gap: 1.4rem;
  grid-template-columns: repeat(auto-fit, minmax(min(290px, 100%), 1fr));
}
.visit-card {
  background: var(--paper); border: 1px solid rgba(26,35,29,.12);
  padding: 1.8rem;
}
.visit-card h3 {
  font-size: .7rem; font-weight: 800; letter-spacing: .3em; text-transform: uppercase;
  color: var(--gold-deep); margin-bottom: 1rem;
}
.visit-card p, .visit-card li { color: var(--ink-soft); line-height: 1.75; font-size: .95rem; }
.visit-card ul { list-style: none; }
.visit-card a { color: var(--green); font-weight: 700; text-decoration: none; }
.visit-card a:hover { text-decoration: underline; }
.visit-card .big { font-family: var(--font-display); font-size: 1.35rem; color: var(--ink); line-height: 1.4; }

/* ---------------- Footer ---------------- */
.site-footer { background: var(--green-black); color: rgba(245,241,231,.75); }
.footer-main {
  display: grid; gap: 2.5rem;
  grid-template-columns: repeat(auto-fit, minmax(min(240px, 100%), 1fr));
  padding: clamp(3rem, 6vw, 5rem) 0 2.5rem;
}
.site-footer .logo { height: 84px; width: auto; }
.site-footer h4 {
  font-size: .68rem; font-weight: 800; letter-spacing: .3em; text-transform: uppercase;
  color: var(--gold-bright); margin-bottom: 1.1rem;
}
.site-footer ul { list-style: none; }
.site-footer li { margin-bottom: .55rem; font-size: .92rem; line-height: 1.6; }
.site-footer a { color: rgba(245,241,231,.85); text-decoration: none; }
.site-footer a:hover { color: var(--gold-bright); }
.footer-bottom {
  border-top: 1px solid rgba(245,241,231,.14);
  padding: 1.4rem 0 2rem;
  font-size: .74rem; letter-spacing: .1em; text-transform: uppercase;
  color: rgba(245,241,231,.4);
  display: flex; flex-wrap: wrap; gap: .8rem; justify-content: space-between;
}

/* ---------------- Page hero (subpages) ---------------- */
.page-hero {
  position: relative; color: #fff;
  padding: clamp(10rem, 18vh, 13rem) 0 clamp(3.5rem, 7vw, 5.5rem);
  background: var(--green-black);
}
.page-hero .bg { position: absolute; inset: 0; }
.page-hero .bg img { width: 100%; height: 100%; object-fit: cover; }
.page-hero .bg::after {
  content: ""; position: absolute; inset: 0;
  background: linear-gradient(180deg, rgba(20,30,46,.6), rgba(20,30,46,.35) 45%, rgba(20,30,46,.85));
}
.page-hero .wrap { position: relative; z-index: 2; }
.page-hero .kicker { color: var(--gold-bright); }
.page-hero h1 {
  font-family: var(--font-display); font-weight: 500;
  font-size: clamp(2.4rem, 5.2vw, 4.4rem); line-height: 1.06; letter-spacing: -.01em;
  margin-top: 1rem; max-width: 18ch;
}
.page-hero h1 em { font-style: italic; color: var(--gold-bright); }
.page-hero p { margin-top: 1.2rem; max-width: 56ch; color: rgba(255,255,255,.85); line-height: 1.7; }

/* ---------------- Responsive ---------------- */
@media (max-width: 880px) {
  .main-nav {
    position: fixed; inset: 0; z-index: 205;
    display: none; flex-direction: column; justify-content: center; align-items: center; gap: 2.2rem;
    background: rgba(20,30,46,.97);
  }
  .main-nav.open { display: flex; }
  .main-nav > a { color: #fff !important; font-size: 1.05rem; }
  .nav-toggle { display: block; }
  /* On small screens the next-raceday bar is tall enough to cover the hero CTAs
     when absolutely positioned — let it flow after the hero content instead */
  .next-bar { position: static; }
  .hero-inner { padding-bottom: 2.4rem; }
  .next-bar .cd { margin-left: 0; }
  /* Small screens: let long fixture names wrap in full rather than being
     ellipsised out of existence when a price + chip share the row */
  .chalk-row { flex-wrap: wrap; }
  .chalk-row .runner { white-space: normal; overflow: visible; text-overflow: clip; flex: 1 1 8ch; min-width: 0; }
  .chalk-row .when { min-width: 0; flex: 0 0 auto; }
  .chalk-row .dots { flex: 1 1 12px; min-width: 12px; }
  .timing-table th:nth-child(4), .timing-table td:nth-child(4) { display: none; }
  .stat { padding: 1.6rem 1rem; }
  .heritage { background-attachment: scroll; }
}

@media (prefers-reduced-motion: reduce) {
  .reveal { opacity: 1; transform: none; transition: none; }
  html { scroll-behavior: auto; }
  .heritage { background-attachment: scroll; }
}

/* ---------------- Announcement banner (admin-controlled, site-wide) ---------------- */
.site-banner {
  position: fixed; top: 0; left: 0; right: 0; z-index: 300;
  text-align: center; padding: .65rem 1.2rem;
  font-weight: 700; font-size: .85rem; letter-spacing: .06em;
  color: #fff;
}
.site-banner--red { background: #a4232a; }
.site-banner--amber { background: #b9770e; }
.site-banner--info { background: var(--green-deep); }

/* ---------------- Fixture first/last race times ---------------- */
.chalk-row .times {
  display: block; font-size: .68em; letter-spacing: .06em;
  color: var(--chalk-dim); margin-top: .15rem;
}

/* ---------------- Hospitality menus (admin uploads) ---------------- */
.menu-group { margin-top: 2.4rem; }
.menu-group h3 {
  font-size: .7rem; font-weight: 800; letter-spacing: .3em; text-transform: uppercase;
  color: var(--gold-deep); margin-bottom: 1.1rem;
}
.menu-cards {
  display: grid; gap: 1.2rem;
  grid-template-columns: repeat(auto-fit, minmax(min(240px, 100%), 1fr));
}
.menu-card {
  background: var(--paper); border: 1px solid rgba(26,35,29,.12);
  padding: 1.4rem 1.5rem; text-decoration: none;
  display: flex; flex-direction: column; gap: .3rem;
  box-shadow: 0 14px 34px rgba(26,35,29,.07);
  transition: transform .3s, box-shadow .3s;
}
.menu-card:hover { transform: translateY(-4px); box-shadow: 0 20px 44px rgba(26,35,29,.12); }
.menu-card b { font-family: var(--font-display); font-weight: 500; font-size: 1.1rem; color: var(--ink); }
.menu-card span {
  font-size: .72rem; letter-spacing: .2em; text-transform: uppercase;
  color: var(--gold-deep);
}

/* Menus that are images are shown as the card itself, side by side */
#menusList { display: grid; gap: 2.6rem; grid-template-columns: repeat(auto-fit, minmax(min(280px, 100%), 360px)); align-items: start; }
.menu-card.has-preview { padding: 0 0 1.3rem; gap: .35rem; border-radius: 10px; overflow: hidden; }
.menu-card.has-preview .menu-preview { display: block; width: 100%; height: auto; margin-bottom: .9rem; border-bottom: 1px solid rgba(26,35,29,.1); }
.menu-card.has-preview b, .menu-card.has-preview span { padding: 0 1.3rem; }
.menu-card.has-preview:hover { transform: translateY(-6px); box-shadow: 0 26px 54px rgba(26,35,29,.18); }

/* ---------------- Venue-hire enquiry form ---------------- */
.enquiry-form { margin-top: 2rem; }
.ef-grid { display: grid; gap: 1rem; grid-template-columns: 1fr 1fr; }
@media (max-width: 640px) { .ef-grid { grid-template-columns: 1fr; } }
.ef-field { display: block; margin-bottom: 1rem; }
.ef-field span {
  display: block; font-size: .66rem; font-weight: 800;
  letter-spacing: .22em; text-transform: uppercase;
  color: var(--gold-deep); margin-bottom: .4rem;
}
.ef-field input, .ef-field select, .ef-field textarea {
  width: 100%; padding: .8rem .9rem;
  border: 1px solid rgba(26,35,29,.2); background: var(--paper);
  font: inherit; color: var(--ink);
}
.ef-field input:focus, .ef-field select:focus, .ef-field textarea:focus {
  outline: 2px solid var(--gold);
}
.ef-field textarea { resize: vertical; }
.ef-status { margin-top: 1rem; font-weight: 700; display: none; }
.ef-status.ok { display: block; color: #1c6b3a; }
.ef-status.err { display: block; color: #a4232a; }

/* ---------------- Hero video: brand-blue tint ----------------
   The footage reads grey/dun; this washes it toward the royal blue
   without flattening it. `mix-blend-mode: color` keeps the video's
   own light and shade and borrows only hue+saturation from the wash. */
.hero { isolation: isolate; }
.hero video, .hero .hero-fallback { filter: saturate(.82); }
.hero::before {
  content: ""; position: absolute; inset: 0; z-index: 1;
  background: linear-gradient(180deg, #2f5183 0%, #24406b 55%, #1a2d4d 100%);
  mix-blend-mode: color;
  opacity: .45;
  pointer-events: none;
}

/* ---------------- Hero clearance under the announcement banner ----------------
   The header is fixed below the banner, so when a banner is showing (it wraps to
   three lines on a phone) the hero text has to start that much lower or the logo
   sits on top of it. */
.hero { padding-top: calc(var(--banner-h, 0px) + 7rem); }
.page-hero { padding-top: calc(var(--banner-h, 0px) + clamp(10rem, 18vh, 13rem)); }

/* ---------------- Enquire by phone or email (venue hire) ---------------- */
.enquire-contact { display: flex; flex-wrap: wrap; gap: .9rem; margin-top: 1.8rem; }
.enquire-alt { margin-top: 1.4rem; font-size: .95rem; line-height: 1.8; color: var(--ink-soft); }
.enquire-alt a { color: var(--green); font-weight: 700; text-decoration: none; border-bottom: 1px solid rgba(39,56,81,.3); }

/* ---------------- Legal pages (privacy policy) ---------------- */
.page-hero--plain { background: linear-gradient(180deg, var(--green-black), var(--green-deep)); padding-bottom: clamp(2.6rem, 5vw, 4rem); }
.legal { max-width: 780px; }
.legal-date { font-size: .74rem; font-weight: 800; letter-spacing: .2em; text-transform: uppercase; color: var(--gold-deep); }
.legal h2 { font-family: var(--font-display); font-weight: 500; font-size: clamp(1.4rem, 2.6vw, 1.8rem); color: var(--green); margin: 2.6rem 0 .8rem; }
.legal h3 { font-size: .78rem; font-weight: 800; letter-spacing: .18em; text-transform: uppercase; color: var(--ink); margin: 1.6rem 0 .5rem; }
.legal p, .legal li { font-size: 1.02rem; line-height: 1.75; color: var(--ink-soft); }
.legal p { margin-bottom: 1rem; }
.legal ul { margin: 0 0 1.1rem 1.25rem; }
.legal li { margin-bottom: .45rem; }
.legal a { color: var(--gold-deep); font-weight: 700; }
.footer-bottom a { color: inherit; text-decoration: underline; text-underline-offset: 3px; }
.footer-bottom a:hover { color: var(--gold-bright); }

/* ---------------- Ticket shop (Future Ticketing embed on /fixtures/) ---------------- */
.ticket-shop { background: #fff; border: 1px solid rgba(26,35,29,.12); border-radius: 12px; padding: clamp(1.1rem, 3vw, 2.2rem); min-height: 260px; box-shadow: 0 18px 44px rgba(26,35,29,.08); overflow-x: auto; }
.ticket-help { margin-top: 1.6rem; font-size: .98rem; line-height: 1.7; color: var(--ink-soft); max-width: 760px; }
.ticket-help a { color: var(--gold-deep); font-weight: 700; }
