/* ============================================================
   The Malthouse Club — shared stylesheet
   Syston & District Conservative Club, 59 High Street, Syston
   ============================================================ */

:root {
  /* Colour: grounded in the building itself — dark oak panelling,
     brass fittings behind the bar, an amber pint held up to the light,
     the green baize of the snooker table through the back room. */
  --malt-dark:    #211a14;   /* main background, dark oak */
  --malt-panel:   #2c2318;   /* raised panel / card background */
  --malt-panel-2: #362b1d;   /* lighter panel, hover states */
  --amber:        #c37f2e;   /* primary accent — pulled pint */
  --amber-bright: #e0a147;
  --brass:        #b6975a;   /* rules, borders, secondary accent */
  --cream:        #efe6d3;   /* primary text on dark */
  --cream-dim:    #cdc0a4;   /* secondary text on dark */
  --baize:        #3c5738;   /* snooker-table green, used sparingly */
  --baize-bright: #567a50;
  --brick:        #8a3d2c;   /* old brick, used sparingly for alerts/CTA-2 */
  --paper:        #efe6d3;   /* light sections (function room, gallery) */
  --ink:          #241d16;   /* text on light sections */

  --font-display: "Zilla Slab", Georgia, serif;
  --font-body: "Public Sans", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;

  --max-width: 1120px;
  --edge: clamp(1.25rem, 4vw, 3rem);
}

*, *::before, *::after { box-sizing: border-box; }

html { scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  * { animation-duration: 0.01ms !important; transition-duration: 0.01ms !important; }
}

body {
  margin: 0;
  background: var(--malt-dark);
  color: var(--cream);
  font-family: var(--font-body);
  font-size: 1.0625rem;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

h1, h2, h3, h4 {
  font-family: var(--font-display);
  font-weight: 700;
  line-height: 1.08;
  margin: 0 0 0.5em;
  color: var(--cream);
}

h1 { font-size: clamp(2.4rem, 5.4vw, 4.4rem); letter-spacing: -0.01em; }
h2 { font-size: clamp(1.7rem, 3.4vw, 2.5rem); }
h3 { font-size: 1.3rem; }

p { margin: 0 0 1.1em; max-width: 62ch; }
p.wide { max-width: none; }

a { color: var(--amber-bright); }
a:focus-visible, button:focus-visible, input:focus-visible, textarea:focus-visible {
  outline: 3px solid var(--brass);
  outline-offset: 2px;
}

img { max-width: 100%; display: block; }

.wrap {
  max-width: var(--max-width);
  margin: 0 auto;
  padding-left: var(--edge);
  padding-right: var(--edge);
}

/* ---------- Header ---------- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 20;
  background: var(--malt-dark);
  border-bottom: 3px solid var(--brass);
}

.site-header .wrap {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1.5rem;
  padding-top: 0.9rem;
  padding-bottom: 0.9rem;
}

.brand {
  display: flex;
  align-items: center;
  gap: 0.85rem;
  text-decoration: none;
  color: var(--cream);
}

.brand-mark {
  flex: none;
  width: 48px;
  height: 48px;
  border-radius: 50%;
  border: 2px solid var(--brass);
  box-shadow: inset 0 0 0 3px var(--malt-dark), inset 0 0 0 4px var(--brass);
  display: grid;
  place-items: center;
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 0.85rem;
  letter-spacing: 0.04em;
  color: var(--brass);
}

.brand-text .brand-name {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 1.25rem;
  display: block;
}

.brand-text .brand-sub {
  display: block;
  font-size: 0.78rem;
  color: var(--cream-dim);
  margin-top: 0.1rem;
}

.site-nav ul {
  list-style: none;
  display: flex;
  gap: clamp(1rem, 3vw, 2rem);
  margin: 0;
  padding: 0;
}

.site-nav a {
  color: var(--cream);
  text-decoration: none;
  font-size: 0.98rem;
  padding-bottom: 4px;
  border-bottom: 2px solid transparent;
}

.site-nav a:hover { color: var(--amber-bright); }
.site-nav a[aria-current="page"] {
  border-bottom-color: var(--amber);
  color: var(--amber-bright);
}

.nav-toggle { display: none; }

@media (max-width: 640px) {
  .site-nav ul { gap: 1rem; font-size: 0.9rem; flex-wrap: wrap; justify-content: flex-end; }
  .brand-sub { display: none; }
}

/* ---------- Hero ---------- */
.hero {
  position: relative;
  padding: clamp(3.5rem, 9vw, 6.5rem) 0 clamp(3rem, 7vw, 5rem);
  background:
    repeating-linear-gradient(
      0deg,
      rgba(182, 151, 90, 0.05) 0px,
      rgba(182, 151, 90, 0.05) 1px,
      transparent 1px,
      transparent 34px
    ),
    linear-gradient(180deg, #251d15 0%, #211a14 70%);
  border-bottom: 1px solid var(--malt-panel-2);
  overflow: hidden;
}

.hero-eyebrow {
  color: var(--brass);
  font-size: 0.95rem;
  margin-bottom: 0.9rem;
}

.hero h1 { max-width: 14ch; }

.hero-lede {
  font-size: 1.15rem;
  color: var(--cream-dim);
  max-width: 46ch;
  margin-top: 1.1rem;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.9rem;
  margin-top: 1.8rem;
}

.status-pill {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  margin-top: 1.6rem;
  padding: 0.5rem 0.95rem;
  background: var(--malt-panel);
  border: 1px solid var(--malt-panel-2);
  border-radius: 999px;
  font-size: 0.92rem;
  color: var(--cream-dim);
}

.status-dot {
  width: 9px;
  height: 9px;
  border-radius: 50%;
  background: var(--baize-bright);
  box-shadow: 0 0 0 3px rgba(86, 122, 80, 0.25);
}

/* ---------- Buttons ---------- */
.btn {
  display: inline-block;
  font-family: var(--font-body);
  font-weight: 600;
  font-size: 0.98rem;
  padding: 0.75rem 1.4rem;
  border-radius: 4px;
  text-decoration: none;
  border: 1px solid transparent;
  cursor: pointer;
}

.btn-primary {
  background: var(--amber);
  color: #241a0f;
}
.btn-primary:hover { background: var(--amber-bright); }

.btn-outline {
  background: transparent;
  border-color: var(--brass);
  color: var(--cream);
}
.btn-outline:hover { border-color: var(--amber-bright); color: var(--amber-bright); }

/* ---------- Sections ---------- */
.section {
  padding: clamp(3rem, 7vw, 4.5rem) 0;
}

.section-dark { background: var(--malt-dark); }
.section-panel { background: var(--malt-panel); border-top: 1px solid var(--malt-panel-2); border-bottom: 1px solid var(--malt-panel-2); }
.section-paper { background: var(--paper); color: var(--ink); }
.section-paper h1, .section-paper h2, .section-paper h3 { color: var(--ink); }
.section-paper p { color: #4a4030; }
.section-paper a { color: #8a3d2c; }

.section-head {
  max-width: 60ch;
  margin-bottom: 2.2rem;
}

.section-head .kicker {
  color: var(--brass);
  font-size: 0.92rem;
  margin-bottom: 0.4rem;
}

.section-paper .kicker { color: #8a3d2c; }

/* ---------- Two column layout ---------- */
.split {
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;
  gap: clamp(2rem, 5vw, 3.5rem);
  align-items: start;
}

@media (max-width: 800px) {
  .split { grid-template-columns: 1fr; }
}

/* ---------- Opening hours board ---------- */
.hours-board {
  background: var(--malt-panel);
  border: 1px solid var(--brass);
  padding: clamp(1.5rem, 4vw, 2.25rem);
}

.hours-board h3 {
  margin-bottom: 1.1rem;
  padding-bottom: 0.7rem;
  border-bottom: 1px solid var(--malt-panel-2);
}

.hours-list { list-style: none; margin: 0; padding: 0; }

.hours-list li {
  display: flex;
  justify-content: space-between;
  gap: 1rem;
  padding: 0.55rem 0;
  border-bottom: 1px dashed rgba(182, 151, 90, 0.3);
  font-size: 1rem;
}

.hours-list li:last-child { border-bottom: none; }

.hours-list .day { color: var(--cream); }
.hours-list .time { color: var(--cream-dim); font-variant-numeric: tabular-nums; }
.hours-list li.is-today .day,
.hours-list li.is-today .time { color: var(--amber-bright); font-weight: 600; }

.hours-note {
  margin-top: 1.2rem;
  font-size: 0.92rem;
  color: var(--cream-dim);
}

/* ---------- Cards / link tiles ---------- */
.tile-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 1.5rem;
}

@media (max-width: 700px) {
  .tile-grid { grid-template-columns: 1fr; }
}

.tile {
  display: block;
  text-decoration: none;
  padding: 1.9rem;
  border: 1px solid var(--malt-panel-2);
  background: var(--malt-panel);
  color: var(--cream);
  position: relative;
}

.tile:hover { border-color: var(--brass); }

.tile.tile-amber { border-left: 4px solid var(--amber); }
.tile.tile-baize { border-left: 4px solid var(--baize-bright); }

.tile h3 { margin-bottom: 0.5rem; }
.tile p { color: var(--cream-dim); margin-bottom: 0; max-width: 40ch; }

.tile .tile-go {
  display: inline-block;
  margin-top: 1rem;
  font-size: 0.9rem;
  color: var(--amber-bright);
}

/* ---------- Info list (features / accessibility) ---------- */
.feature-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 0.7rem 1.5rem;
}

@media (max-width: 560px) {
  .feature-list { grid-template-columns: 1fr; }
}

.feature-list li {
  padding-left: 1.4rem;
  position: relative;
  color: #4a4030;
}

.feature-list li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0.55em;
  width: 8px;
  height: 8px;
  background: var(--brick);
}

/* ---------- Pricing table ---------- */
.pricing-table {
  width: 100%;
  border-collapse: collapse;
  background: var(--malt-panel);
  border: 1px solid var(--malt-panel-2);
}

.pricing-table caption {
  text-align: left;
  padding: 1rem 1.25rem 0;
  font-size: 0.88rem;
  color: var(--cream-dim);
  caption-side: bottom;
}

.pricing-table th, .pricing-table td {
  text-align: left;
  padding: 0.9rem 1.25rem;
  border-bottom: 1px solid var(--malt-panel-2);
  font-size: 0.98rem;
}

.pricing-table th {
  font-family: var(--font-display);
  font-weight: 700;
  color: var(--brass);
  border-bottom: 1px solid var(--brass);
}

.pricing-table td.price { font-variant-numeric: tabular-nums; color: var(--amber-bright); }

/* ---------- Enquiry form ---------- */
.enquiry-form {
  background: var(--malt-panel);
  border: 1px solid var(--malt-panel-2);
  padding: clamp(1.5rem, 4vw, 2.25rem);
  display: grid;
  gap: 1.1rem;
}

.enquiry-form .field { display: grid; gap: 0.4rem; }

.enquiry-form label { font-size: 0.92rem; color: var(--cream-dim); }

.enquiry-form input,
.enquiry-form select,
.enquiry-form textarea {
  font: inherit;
  padding: 0.65rem 0.8rem;
  background: var(--malt-dark);
  border: 1px solid var(--malt-panel-2);
  color: var(--cream);
  border-radius: 3px;
}

.enquiry-form .field-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1.1rem;
}

@media (max-width: 560px) {
  .enquiry-form .field-row { grid-template-columns: 1fr; }
}

.form-note {
  font-size: 0.85rem;
  color: var(--cream-dim);
  margin-top: -0.4rem;
}

/* ---------- Map ---------- */
.map-frame {
  border: 1px solid var(--malt-panel-2);
  filter: grayscale(0.25) sepia(0.15) contrast(1.02);
}

.map-frame iframe {
  width: 100%;
  height: 100%;
  border: 0;
  display: block;
}

.find-us {
  display: grid;
  grid-template-columns: 1fr 1.3fr;
  gap: clamp(1.5rem, 4vw, 3rem);
  align-items: stretch;
}

@media (max-width: 800px) {
  .find-us { grid-template-columns: 1fr; }
}

.find-us .map-frame { min-height: 320px; }

.address-block dt { color: var(--brass); font-size: 0.85rem; margin-top: 1rem; }
.address-block dt:first-child { margin-top: 0; }
.address-block dd { margin: 0.2rem 0 0; }

/* ---------- Gallery ---------- */
.gallery-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  grid-auto-rows: 220px;
  gap: 1rem;
}

@media (max-width: 900px) {
  .gallery-grid { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 560px) {
  .gallery-grid { grid-template-columns: 1fr; grid-auto-rows: 200px; }
}

.gallery-grid .span-2-col { grid-column: span 2; }
.gallery-grid .span-2-row { grid-row: span 2; }

@media (max-width: 560px) {
  .gallery-grid .span-2-col { grid-column: span 1; }
  .gallery-grid .span-2-row { grid-row: span 1; }
}

.placeholder-tile {
  position: relative;
  height: 100%;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 0.6rem;
  text-align: center;
  padding: 1rem;
  color: var(--cream-dim);
}

.placeholder-tile svg { width: 34px; height: 34px; opacity: 0.7; }
.placeholder-tile .cap { font-size: 0.85rem; max-width: 20ch; }
.placeholder-tile .tag { font-size: 0.72rem; color: var(--brass); }

/* ---------- Footer ---------- */
.site-footer {
  background: var(--malt-dark);
  border-top: 3px solid var(--brass);
  padding: 2.5rem 0 2rem;
}

.footer-grid {
  display: grid;
  grid-template-columns: 1.4fr 1fr 1fr;
  gap: 2rem;
}

@media (max-width: 700px) {
  .footer-grid { grid-template-columns: 1fr; }
}

.footer-grid h4 {
  font-size: 0.95rem;
  color: var(--brass);
  margin-bottom: 0.7rem;
  font-family: var(--font-body);
  font-weight: 600;
}

.footer-grid p, .footer-grid address { color: var(--cream-dim); font-style: normal; font-size: 0.94rem; }

.footer-grid ul { list-style: none; margin: 0; padding: 0; }
.footer-grid ul li { margin-bottom: 0.45rem; }
.footer-grid a { color: var(--cream-dim); text-decoration: none; }
.footer-grid a:hover { color: var(--amber-bright); }

.footer-base {
  max-width: var(--max-width);
  margin: 2rem auto 0;
  padding: 1.2rem var(--edge) 0;
  border-top: 1px solid var(--malt-panel-2);
  font-size: 0.85rem;
  color: var(--cream-dim);
  display: flex;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 0.6rem;
}

.socialmedialink {
  display: block; width: 40px; height: 40px;
}

.carousel { max-width: 920px; }

/* ---------- Stage: one photo at a time ---------- */
.carousel-stage {
  position: relative;
  /* Fixed height, so the page never jumps as photos load or change.
     Portrait phone shots are shown whole (object-fit: contain) on a dark mat. */
  height: clamp(340px, 68vh, 640px);
  background: rgba(0, 0, 0, 0.28);
  border: 1px solid var(--malt-panel-2);
}

.carousel-track {
  display: flex;
  height: 100%;
  margin: 0;
  padding: 0;
  list-style: none;
  overflow-x: auto;
  overscroll-behavior-x: contain;
  scroll-snap-type: x mandatory;
  scrollbar-width: none;
}
.carousel-track::-webkit-scrollbar { display: none; }

.carousel-slide {
  flex: 0 0 100%;
  height: 100%;
  scroll-snap-align: center;
  scroll-snap-stop: always;
}

.carousel-slide figure {
  height: 100%;
  margin: 0;
  display: grid;
  grid-template-rows: minmax(0, 1fr) auto;
}

.carousel-slide img {
  width: 100%;
  height: 100%;
  min-height: 0;
  object-fit: contain;
  display: block;
}

.carousel-slide figcaption {
  padding: 0.85rem 4rem 1rem;      /* side padding clears the arrow buttons */
  text-align: center;
  font-size: 1rem;
  color: var(--cream);
  background: var(--malt-panel);
  border-top: 1px solid var(--malt-panel-2);
}

.carousel-track:focus-visible { outline: 3px solid var(--brass); outline-offset: -3px; }

/* ---------- Prev / next ---------- */
.carousel-btn {
  position: absolute;
  top: calc((100% - 3.4rem) / 2);   /* centred on the photo, not the caption */
  transform: translateY(-50%);
  width: 46px;
  height: 46px;
  display: grid;
  place-items: center;
  padding: 0;
  color: var(--cream);
  background: rgba(33, 26, 20, 0.82);
  border: 2px solid var(--brass);
  border-radius: 50%;
  cursor: pointer;
}
.carousel-btn.prev { left: 0.75rem; }
.carousel-btn.next { right: 0.75rem; }
.carousel-btn svg { width: 20px; height: 20px; }
.carousel-btn:hover:not(:disabled) { color: var(--amber-bright); border-color: var(--amber-bright); }
.carousel-btn:disabled { opacity: 0.3; cursor: default; }

/* ---------- Counter + thumbnails ---------- */
.carousel-count {
  margin: 0.9rem 0 0.6rem;
  font-size: 0.92rem;
  color: var(--cream-dim);
  font-variant-numeric: tabular-nums;
}

.carousel-thumbs {
  display: flex;
  gap: 0.6rem;
  margin: 0;
  padding: 0 0 0.4rem;
  list-style: none;
  overflow-x: auto;
}

.carousel-thumbs button {
  display: block;
  width: 76px;
  height: 76px;
  padding: 0;
  border: 2px solid transparent;
  background: var(--malt-panel);
  opacity: 0.6;
  cursor: pointer;
}
.carousel-thumbs button:hover { opacity: 1; }
.carousel-thumbs button[aria-current="true"] { border-color: var(--amber); opacity: 1; }
.carousel-thumbs img { width: 100%; height: 100%; object-fit: cover; display: block; }

/* Without JS the strip still swipes/scrolls; the extras just stay hidden */
.carousel:not(.is-ready) .carousel-btn,
.carousel:not(.is-ready) .carousel-count,
.carousel:not(.is-ready) .carousel-thumbs { display: none; }

@media (max-width: 560px) {
  .carousel-stage { height: clamp(320px, 62vh, 520px); }
  .carousel-slide figcaption { padding: 0.75rem 1rem 0.9rem; font-size: 0.95rem; }
  .carousel-btn { top: auto; bottom: 4.6rem; transform: none; width: 42px; height: 42px; }
  .carousel-thumbs button { width: 64px; height: 64px; }
}


/* ---------- Utility ---------- */
.mt-0 { margin-top: 0; }
.text-center { text-align: center; }
