/*
 * site.css: the only stylesheet for the-barleymow.co.uk.
 *
 * Sections, in order:
 *   1. Tokens        colours, fonts, spacing, breakpoints (custom properties)
 *   2. Fonts         @font-face for self-hosted fonts
 *   3. Base          reset and element defaults
 *   4. Layout        shared section helpers
 *   5. Components    one block per component: "=== Component: <name> ==="
 *   6. Pages         page-specific rules: "=== Page: <path> ==="
 *   7. Utilities     a handful of helpers
 *
 * Breakpoints (the original's Elementor breakpoints; media queries can't use custom properties):
 *   mobile  ≤ 767px    tablet 768px–1024px    desktop ≥ 1025px
 *
 * Page variants are switched by a class on <body>: page-home, page-menu, page-unavailable.
 */

/* ============ 1. Tokens ============ */
:root {
  /* Colours (from the original's Elementor CSS) */
  --color-gold: #ddc771;                   /* icon bar, buttons */
  --color-gold-border: rgb(197 179 106 / 0.48); /* #C5B36A7A button border */
  --color-gold-tint: rgb(221 199 113 / 0.45);   /* #DDC77173 "What's on Tap?" band */
  --color-gold-wash: rgb(221 199 113 / 0.29);   /* #DDC7714A info-card band and footer */
  --color-card: #e7e4dc;                   /* rounded grey card */
  --color-icon: #525252;
  --color-ink: #000000;
  --color-text: #232323;
  --color-bg: #ffffff;

  /* Typography */
  --font-body: "Darker Grotesque", sans-serif;
  --font-serif: "Playfair Display", serif;
  --font-italic: "Inter", sans-serif;      /* only the italic "About The Barley Mow" heading */
  --font-lightbox: "Times New Roman", Times, serif; /* Elementor lightbox captions used the browser default */

  /* Layout */
  --container: 1200px;
  --radius-image: 20px;
  --radius-card: 42px;
  --widget-gap: 20px;                      /* Elementor's default space between widgets */

  /* Motion */
  --duration: 300ms;
  --ease: ease;
}

/* ============ 2. Fonts ============ */
/* Self-hosted Google Fonts (latin subset). Darker Grotesque is the variable font (300–900). */
@font-face { font-family: "Darker Grotesque"; src: url("/assets/fonts/darker-grotesque-latin-var.woff2") format("woff2"); font-weight: 300 900; font-style: normal; font-display: swap; }
@font-face { font-family: "Inter"; src: url("/assets/fonts/inter-italic-400-latin.woff2") format("woff2"); font-weight: 400; font-style: italic; font-display: swap; }
@font-face { font-family: "Playfair Display"; src: url("/assets/fonts/playfair-display-latin-700-800.woff2") format("woff2"); font-weight: 700 800; font-style: normal; font-display: swap; }

/* ============ 3. Base ============ */
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; text-size-adjust: 100%; scroll-behavior: smooth; }
body { margin: 0; font-family: var(--font-body); color: var(--color-text); background: var(--color-bg); overflow-x: hidden; }
img, svg, video, iframe { max-width: 100%; }
img, video { height: auto; display: block; }
h1, h2, h3 { margin: 0; padding: 0; line-height: 1; font-weight: inherit; }
p { margin: 1em 0; }
a { color: inherit; text-decoration: none; } /* Elementor removed underlines from content links */
a:focus-visible, button:focus-visible { outline: 2px solid var(--color-ink); outline-offset: 2px; }

/* ============ 4. Layout ============ */
/* Wheat illustration along the bottom of a section (the original's background overlay, 50% opacity). */
.wheat { position: relative; isolation: isolate; }
.wheat::before { content: ""; position: absolute; inset: 0; z-index: -1; pointer-events: none; background: url("/wp-content/uploads/2022/03/istockphoto-1296137564-170667a-1.png") bottom center repeat-x; opacity: 0.5; }
.wheat--solid::before { opacity: 1; }

/* ============ 5. Components ============ */

/* === Component: skip-link === */
.skip-link { position: absolute; left: -9999px; top: 0; z-index: 100; padding: 0.5rem 1rem; background: var(--color-bg); color: var(--color-ink); }
.skip-link:focus { left: 1rem; }

/* === Component: icon-bar (gold bar with social icons; the original's only "header") ===
 * Default (menu and unavailable pages): 20px padding, icons centred in a right-hand column.
 * Home: no padding, icons flush right (see .page-home below). */
.icon-bar { --icon-size: 25px; --icon-col: 25.284%; background: var(--color-gold); padding: 20px; }
.page-unavailable .icon-bar { --icon-col: 21.456%; }
.icon-bar__inner { max-width: var(--container); margin-inline: auto; display: flex; justify-content: flex-end; }
.icon-bar__icons { width: var(--icon-col); padding: 10px; margin: 0; list-style: none; display: flex; flex-wrap: wrap; justify-content: center; gap: 0 5px; }
.icon-bar__icon { display: inline-flex; align-items: center; justify-content: center; width: calc(var(--icon-size) * 2); height: calc(var(--icon-size) * 2); color: var(--color-icon); }
.icon-bar__icon svg { width: var(--icon-size); height: var(--icon-size); fill: currentColor; }
.page-home .icon-bar { padding: 0; }
.page-home .icon-bar__icons { width: auto; padding: 2px; justify-content: flex-end; }
.page-home .icon-bar__item--twitter { display: none; }
@media (max-width: 1024px) { .icon-bar { --icon-size: 23px; } }
@media (max-width: 767px) { .icon-bar { --icon-size: 14px; --icon-col: 50%; } .page-unavailable .icon-bar { --icon-col: 50%; } }

/* === Component: hero-banner (one composite image: pub photo + round logo) === */
.hero-banner { min-height: 73vh; background: url("/wp-content/uploads/2022/03/Group-73.png") center / 100% auto no-repeat; }
@media (max-width: 1024px) { .hero-banner { min-height: 24vh; } }
@media (max-width: 767px) { .hero-banner { min-height: 20vh; } }

/* === Component: button (gold rounded button) === */
.button-group { display: flex; flex-wrap: wrap; justify-content: center; gap: 0 25px; }
.button { display: inline-flex; align-items: center; justify-content: center; padding: 20px; border: 3px solid var(--color-gold-border); border-radius: 20px; background: var(--color-gold); color: var(--color-ink); font-family: var(--font-body); font-size: 36px; font-weight: 500; line-height: 1; letter-spacing: -1.2px; word-spacing: 0.1em; text-decoration: none; }
@media (max-width: 1024px) { .button { font-size: 12px; } }
@media (max-width: 767px) { .button { font-size: 16px; } }

/* === Component: gallery-section (photo gallery over the wheat; GLightbox) ===
 * 4 columns (10:9 tiles) on desktop, 2 square columns on tablet, 1 on mobile. */
.gallery-section { margin-block: 150px; padding: 30px 30px 0; }
.gallery-section__inner { max-width: var(--container); min-height: 579px; margin-inline: auto; display: flex; flex-direction: column; justify-content: center; align-items: center; gap: var(--widget-gap); }
.photo-gallery { width: 100%; display: grid; grid-template-columns: repeat(4, 1fr); gap: 20px; padding-bottom: 20px; }
.photo-gallery__item { display: block; overflow: hidden; border-radius: var(--radius-image); aspect-ratio: 10 / 9; }
.photo-gallery__item img { width: 100%; height: 100%; object-fit: cover; transition: transform var(--duration) var(--ease); }
.photo-gallery__item:hover img { transform: scale(1.02); }
@media (max-width: 1024px) {
  .gallery-section { margin-block: 50px; }
  .photo-gallery { grid-template-columns: repeat(2, 1fr); }
  .photo-gallery__item { aspect-ratio: 1; }
}
@media (max-width: 767px) {
  .gallery-section { padding: 0; }
  .gallery-section--hide-mobile { display: none; }
  .photo-gallery { grid-template-columns: 1fr; }
}

/* === Component: info-section ("Private Event Hire" + "Where To Find Us" + map in a rounded grey card) ===
 * Home uses Playfair Display headings (.info-card--serif); /menu/ uses Darker Grotesque. */
.info-section { padding: 50px 0; background-color: var(--color-gold-wash); }
.info-section__inner { max-width: 1000px; min-height: 75vh; margin-inline: auto; display: flex; align-items: center; }
.info-card { width: 100%; padding: 100px; border-radius: var(--radius-card); background: var(--color-card); display: flex; flex-direction: column; align-items: center; text-align: center; }
.info-card__title { font-size: 54px; font-weight: 700; color: var(--color-ink); }
.info-card__lead { display: flow-root; margin-top: var(--widget-gap); font-size: 23px; font-weight: 700; color: var(--color-ink); }
.info-card__lead p { margin: 23px 0; }
.info-card__spacer { height: var(--spacer, 0px); margin-top: var(--widget-gap); }
.info-card__subtitle { margin-top: var(--widget-gap); margin-bottom: 20px; font-size: 46px; font-weight: 800; color: var(--color-text); }
.info-card__details { display: flow-root; max-width: 700px; margin-top: var(--widget-gap); margin-bottom: 40px; font-size: 22px; font-weight: 300; line-height: 1.7; color: var(--color-text); }
.info-card__details p { margin: 22px 0; }
.info-card__details p:last-child { margin-bottom: 0; }
.info-card--serif .info-card__title, .info-card--serif .info-card__subtitle { font-family: var(--font-serif); }
.info-card .map { max-width: 800px; }
@media (max-width: 1024px) {
  .info-section { margin-top: -98px; padding: 0 50px; }
  .info-card { padding: 50px; }
}
@media (max-width: 767px) {
  .info-section { margin-top: -101px; padding: 25px 15px 15px; }
  .info-section__inner { min-height: 100vh; }
  .info-card { padding: 10px; }
  .info-card__title { padding-top: 34px; font-size: 37px; }
  .info-card__subtitle { font-size: 30px; }
  .info-card__spacer { height: var(--spacer-mobile, var(--spacer, 0px)); }
}

/* === Component: map (keyless Google Maps iframe) === */
.map { display: block; width: 100%; height: 400px; border: 0; }

/* === Component: site-footer (copyright left, OrderYOYO credit right) === */
.site-footer { padding: 30px; background-color: var(--color-gold-wash); font-size: 22px; font-weight: 300; line-height: 1.7; color: var(--color-text); }
.site-footer__inner { max-width: var(--container); margin-inline: auto; display: grid; grid-template-columns: 1fr 1fr; }
.site-footer__col { padding: 10px; }
.site-footer__copyright { margin: 22px 0; }
.site-footer__credit { text-align: end; }
.site-footer__credit a { color: var(--color-text); }
@media (max-width: 767px) {
  .site-footer { padding: 59px 0 0; }
  .site-footer__inner { max-width: 500px; grid-template-columns: 1fr; }
  .site-footer__col > * { padding: 10px; text-align: center; }
}

/* === Component: lightbox (GLightbox, styled like the original Elementor lightbox) === */
.glightbox-container .goverlay { background: rgb(0 0 0 / 0.8); }
.glightbox-clean .gslide-description { background: transparent; }
.glightbox-clean .gdesc-inner { padding: 8px 10px 0; text-align: center; }
.glightbox-clean .gslide-title { margin-bottom: 4px; font-family: var(--font-lightbox); font-size: 16px; font-weight: 700; color: #ffffff; }
.glightbox-clean .gslide-desc { font-family: var(--font-lightbox); font-size: 14px; color: #ffffff; }
.glightbox-mobile .glightbox-container .gslide-description { background: transparent; }

/* ============ 6. Pages ============ */

/* === Page: / (about, events, on tap) === */
.about { padding: 11px 10px 10px; }
.about__title { margin: 9px; text-align: center; font-family: var(--font-italic); font-size: 61px; font-style: italic; font-weight: 400; color: var(--color-ink); }
.about__grid { max-width: 1000px; margin: 29px auto 0; display: grid; grid-template-columns: 46.631% 53.35%; }
.about__col { padding: 10px; display: flex; flex-direction: column; }
.about__col--image { justify-content: center; align-items: center; }
.about__text { display: flow-root; margin-top: -29px; margin-bottom: var(--widget-gap); font-size: 26px; font-weight: 400; color: var(--color-ink); }
.about__image { width: 57%; }
@media (max-width: 1024px) {
  .about__text { margin-top: 0; font-size: 18px; }
  .about__image { width: 100%; }
}
@media (max-width: 767px) {
  .about__title { font-size: 28px; }
  .about__grid { grid-template-columns: 1fr; }
  .about__text { font-size: 14px; }
  .about__col--image { min-height: 20px; }
  .about__image { display: none; }
}

.events { margin-block: 150px; padding: 30px 30px 0; }
.events__inner { max-width: var(--container); margin-inline: auto; display: flex; flex-direction: column; align-items: center; }
.events__title { width: 100%; text-align: center; font-size: 46px; font-weight: 900; line-height: 1.25; color: var(--color-text); }
.events__intro { display: flow-root; max-width: 590px; margin-top: var(--widget-gap); margin-bottom: 0; /* original 18px collapsed into the 22px paragraph margin */ text-align: center; font-size: 22px; font-weight: 600; line-height: 1.7; color: var(--color-text); }
.events__intro p { margin: 22px 0; }
.events__grid { width: 100%; display: grid; grid-template-columns: repeat(3, 1fr); }
.event-card { padding: 15px; display: flex; flex-direction: column; align-items: center; }
.event-card__image { width: 100%; margin-bottom: 30px; }
.event-card__image img { width: 100%; margin-inline: auto; }
.event-card__title { margin-bottom: 15px; width: 100%; text-align: center; font-size: 22px; font-weight: 600; color: var(--color-text); }
.event-card__text { display: flow-root; max-width: 590px; text-align: center; font-size: 22px; font-weight: 300; line-height: 1.7; color: var(--color-text); }
.event-card__text p { margin: 22px 0; }
@media (max-width: 1024px) { .events { margin-block: 50px; } }
@media (max-width: 767px) {
  .events__title { font-size: 23px; }
  .events__intro { font-size: 14px; }
  .events__intro p { margin: 14px 0; }
  .events__grid { grid-template-columns: 1fr; }
  .event-card__image img { width: var(--image-mobile, 100%); }
  .event-card__title { font-size: var(--title-mobile, 22px); }
}

.on-tap { min-height: 74vh; background-color: var(--color-gold-tint); }
.on-tap__inner { max-width: var(--container); margin-inline: auto; padding: 60px 10px; }
.on-tap__title { margin: var(--widget-gap) 0; text-align: center; font-size: 63px; font-weight: 700; color: var(--color-ink); }
.on-tap__logos { margin: 1px 0 var(--widget-gap); padding: 0; list-style: none; display: grid; grid-template-columns: repeat(4, 1fr); gap: 29px; align-items: start; }
.on-tap__logos li { display: flex; justify-content: center; }
@media (max-width: 1024px) {
  .on-tap { min-height: 47vh; }
  .on-tap__logos { margin-block: 0 var(--widget-gap); padding: 22px 22px 22px; }
}
@media (max-width: 767px) {
  .on-tap__title { font-size: 46px; }
  .on-tap__logos { grid-template-columns: 1fr; }
}

/* === Page: /menu/ (menu cards, app download) === */
.menu-intro { padding: 10px; }
.menu-intro__spacer { height: 50px; margin-bottom: var(--widget-gap); }
.menu-intro__title { margin-bottom: var(--widget-gap); text-align: center; font-size: 70px; font-weight: 400; color: var(--color-ink); }
.menu-cards { max-width: 1600px; margin-inline: auto; display: grid; grid-template-columns: 25% 25% 24% 25.975%; }
.menu-card { padding: 10px; display: flex; flex-direction: column; gap: var(--widget-gap); }
.menu-card--center { justify-content: center; }
.menu-card__image img { width: 100%; }
.menu-card__spacer { height: var(--spacer); }
.menu-card__title { text-align: center; font-size: 46px; font-weight: 400; line-height: 1.25; color: var(--color-text); }
@media (max-width: 1024px) {
  .menu-intro__spacer, .menu-card__spacer { display: none; }
  .menu-card__title { font-size: 40px; }
}
@media (max-width: 767px) {
  .menu-intro__title { font-size: 28px; }
  .menu-cards { grid-template-columns: 1fr; }
}

.app-promo { min-height: 93vh; margin-bottom: -82px; display: flex; align-items: center; background: url("/wp-content/uploads/2022/03/istockphoto-1296137564-170667a-1.png") bottom center repeat-x; }
.app-promo__inner { width: 100%; max-width: var(--container); margin-inline: auto; display: grid; grid-template-columns: 50.088% 48.881%; align-items: center; }
.app-promo__col { padding: 15px; }
.app-promo__spacer { display: none; height: 20px; margin-bottom: var(--widget-gap); }
.app-promo__title { margin-bottom: var(--widget-gap); font-size: 46px; font-weight: 400; line-height: 1.25; color: var(--color-text); }
.app-promo__text { display: flow-root; max-width: 700px; margin-bottom: 40px; font-size: 22px; font-weight: 500; line-height: 1.7; color: var(--color-text); }
.app-promo__text p { margin: 22px 0; }
.app-promo__text p:last-child { margin-bottom: 0; }
.app-promo__badges { display: inline-block; }
.app-promo__phones img { width: 100%; }
@media (max-width: 1024px) {
  .app-promo { min-height: 63vh; margin-block: 50px; }
}
@media (max-width: 767px) {
  .app-promo { padding: 10px; }
  .app-promo__inner { grid-template-columns: 1fr; }
  .app-promo__spacer { display: block; }
  .app-promo__phones { display: none; }
}

/* === Page: /book-a-table/ and /order-online-unavailable/ (one image) === */
.unavailable { padding: 31px 10px; }
.unavailable__inner { max-width: 1140px; margin-inline: auto; }
.unavailable__inner img { margin-inline: auto; }

/* === Page: 404 === */
.error-page { padding: 80px 20px; text-align: center; }
.error-page__title { font-size: 63px; font-weight: 700; color: var(--color-ink); }
.error-page__text { margin: 30px auto; max-width: 700px; font-size: 22px; font-weight: 300; line-height: 1.7; }
@media (max-width: 767px) { .error-page__title { font-size: 46px; } }

/* ============ 7. Utilities ============ */
.visually-hidden { position: absolute !important; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

/* ============ Reduced motion ============ */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation-duration: 0.01ms !important; animation-iteration-count: 1 !important; transition-duration: 0.01ms !important; }
}
