/*
 * site.css: the only stylesheet for giuseppespizza.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        container, sections, columns
 *   5. Components    one block per component: "=== Component: <name> ==="
 *   6. Pages         rare page-specific rules: "=== Page: <path> ==="
 *   7. Utilities     a handful of helpers
 *
 * Breakpoints (from the original Elementor kit; media queries can't use custom properties):
 *   mobile  <= 767px    tablet 768px-1024px    desktop >= 1025px
 *   The header menu collapses to the burger at <= 1024px (as the original).
 *
 * Editing: change tokens to restyle the site; add new components as new blocks;
 * add modifier classes (.button--light) instead of changing a component for one page.
 */

/* ============ 1. Tokens ============ */
:root {
  /* Colours (Elementor global colours of the original) */
  --color-red: #a61e1f;        /* primary: buttons, headings, red bands */
  --color-sage: #91a8a0;       /* secondary: hover colour, sage bands */
  --color-text: #000000;
  --color-white: #ffffff;
  --color-toggle-bg: rgb(0 0 0 / 0.05);

  /* Typography */
  --font-script: "Pacifico", cursive;           /* headings, nav, buttons */
  --font-body: "Inter", Arial, sans-serif;      /* body text, footer */
  --text-body: 20px;
  --text-heading: 42px;
  --text-heading-xl: 53px;
  --text-nav: 21px;
  --text-button: 20px;
  --text-footer-heading: 24px;

  /* Layout */
  --container: 1280px;         /* Elementor boxed width (content 1260 + 2 x 10px column padding) */
  --col-pad: 10px;             /* Elementor column padding */
  --section-pad-x: 30px;
  --header-h: 106px;           /* desktop; tablet 143px; mobile 64px (set below) */
  --radius-button: 3px;
  --radius-image: 20px;

  /* Motion (original Elementor timings) */
  --duration: 300ms;
  --duration-nav: 400ms;
  --ease: ease;
}
@media (max-width: 1024px) { :root { --header-h: 143px; } }
@media (max-width: 767px) { :root { --header-h: 64px; } }

/* ============ 2. Fonts ============ */
/* Self-hosted Google Fonts (OFL): Pacifico 400 and Inter variable (200, 400, 600 used). */
@font-face { font-family: "Pacifico"; src: url("/assets/fonts/pacifico-latin-400.woff2") format("woff2"); font-weight: 400; font-style: normal; font-display: swap; }
@font-face { font-family: "Inter"; src: url("/assets/fonts/inter-latin-variable.woff2") format("woff2"); font-weight: 100 900; 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); font-size: 16px; line-height: 1.5; color: var(--color-text); background: var(--color-white); overflow-x: clip; }
img, svg, video, iframe { max-width: 100%; }
img, video { height: auto; display: block; }
h1, h2, h3, h4 { margin: 0; font-weight: 400; }
p { margin: 0; }
a { color: inherit; text-decoration: none; transition: color var(--duration) var(--ease), background-color var(--duration) var(--ease); }
ul { list-style: none; margin: 0; padding: 0; }
a:focus-visible, button:focus-visible { outline: 2px solid var(--color-sage); outline-offset: 2px; }
[id] { scroll-margin-top: var(--header-h); }

/* ============ 4. Layout ============ */
.container { width: 100%; max-width: var(--container); margin-inline: auto; }
.col { padding: var(--col-pad); min-width: 0; }
.section-pad { padding-inline: var(--section-pad-x); }

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

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

/* === Component: site-header ===
 * Sticky white bar: empty left column, centred nav, "Order Now" right (desktop).
 * Tablet: burger centred, Order Now on its own row. Mobile: burger only.
 * The header box keeps a fixed height, so the open dropdown overlays the page (as the original's fixed header did).
 */
.site-header { position: sticky; top: 0; z-index: 50; height: var(--header-h); }
.site-header__bar { background: var(--color-white); padding-block: 20px; }
.site-header__inner { display: flex; flex-wrap: wrap; align-items: center; }
.site-header__spacer { flex: 0 0 15%; }
.site-header__nav { flex: 0 0 69.666%; padding: var(--col-pad); }
.site-header__cta { flex: 0 0 15%; padding: var(--col-pad); display: flex; justify-content: flex-end; }

.nav-toggle { display: none; align-items: center; justify-content: center; margin: 0 auto; width: 33px; height: 33px; padding: 0; border: 0; border-radius: 3px; background: var(--color-toggle-bg); color: var(--color-red); cursor: pointer; position: relative; }
.nav-toggle::after { content: ""; position: absolute; inset: -6px; } /* 44px tap target */
.nav-toggle svg { width: 22px; height: 22px; }
.nav-toggle__close { display: none; }
.nav-toggle[aria-expanded="true"] { color: var(--color-white); }
.nav-toggle[aria-expanded="true"] .nav-toggle__open { display: none; }
.nav-toggle[aria-expanded="true"] .nav-toggle__close { display: block; }

.site-nav__list { display: flex; flex-wrap: wrap; justify-content: center; }
.site-nav__list a { display: block; padding: 13px 20px; font-family: var(--font-script); font-size: var(--text-nav); line-height: 20px; color: var(--color-red); transition: color var(--duration-nav) var(--ease); }
.site-nav__list a:hover, .site-nav__list a:focus-visible, .site-nav__list a[aria-current="page"], .site-nav__list a.is-active { color: var(--color-sage); }

@media (max-width: 1024px) {
  .site-header__bar { padding-block: 8px; }
  .site-header__nav { flex-basis: 69.666%; }
  .site-header__cta { flex-basis: 100%; justify-content: center; }
  .nav-toggle { display: inline-flex; }
  .site-nav__toggle-row { display: flex; height: 43px; align-items: flex-start; justify-content: center; padding-top: 0; }
  /* Slide-down panel: grid row 0fr -> 1fr; align-items stretch so the list is clipped while it animates */
  .site-nav { display: grid; grid-template-rows: 0fr; align-items: stretch; visibility: hidden; background: var(--color-white); transition: grid-template-rows var(--duration) var(--ease), visibility var(--duration); }
  .site-nav.is-open { grid-template-rows: 1fr; visibility: visible; }
  .site-nav.is-instant { transition: none; }
  .site-nav__inner { overflow: hidden; min-height: 0; }
  .site-nav__list { display: block; }
  .site-nav__list a { padding: 10px 20px; line-height: 20px; text-align: center; }
  .site-nav__list a:hover, .site-nav__list a:focus-visible, .site-nav__list a[aria-current="page"], .site-nav__list a.is-active { color: var(--color-white); background: var(--color-red); }
}
@media (min-width: 1025px) {
  .site-nav__toggle-row { display: none; }
}
@media (max-width: 767px) {
  .site-header__bar { padding-block: 0; }
  .site-header__spacer, .site-header__cta { display: none; }
  .site-header__nav { flex-basis: 100%; }
}

/* === Component: button ===
 * Pacifico 20px, 12px 24px padding. Default: red with white text (header, app section).
 * --light: white with red text (top picks, events). Hover: sage background, white text.
 */
.button { display: inline-flex; align-items: center; justify-content: center; padding: 12px 24px; border: 0; border-radius: var(--radius-button); background: var(--color-red); color: var(--color-white); font-family: var(--font-script); font-size: var(--text-button); font-weight: 400; line-height: 20px; cursor: pointer; transition: background-color var(--duration) var(--ease), color var(--duration) var(--ease); }
.button:hover, .button:focus-visible { background: var(--color-sage); color: var(--color-white); }
.button--light { background: var(--color-white); color: var(--color-red); border-radius: 0; }
.button--square { border-radius: 0; }

/* === Component: button-group (centred row; stacks on mobile) === */
.button-group { display: flex; flex-wrap: wrap; justify-content: center; gap: 10px; }
@media (max-width: 767px) { .button-group { flex-direction: column; align-items: center; } }

/* === Component: section-heading ===
 * Pacifico 42px. --rule adds the thin white line under it (37px gap), as on the red sections.
 */
.section-heading { font-family: var(--font-script); font-size: var(--text-heading); line-height: 1; text-align: center; color: var(--color-red); }
.section-heading--white { color: var(--color-white); }
.section-heading--rule { padding-bottom: 37px; border-bottom: 1px solid var(--color-white); }

/* === Component: hero (home: full-height photo with the big logo) ===
 * Pulled 66px up under the sticky header, like the original.
 */
.hero { position: relative; z-index: 0; margin-top: -66px; display: flex; align-items: center; justify-content: center; min-height: calc(98vh + 24px); background: url("/wp-content/uploads/2023/10/header_bg.png") center / cover no-repeat; border-bottom: 24px solid var(--color-red); }
.hero .container { padding: var(--col-pad); }
.hero__logo-wrap { display: flex; justify-content: center; }
.hero__logo-wrap img { width: 22%; }
@media (max-width: 1024px) { .hero__logo-wrap img { width: 30%; } }
@media (max-width: 767px) { .hero__logo-wrap img { width: 65%; } }

/* === Component: hero-small (inner pages: photo strip + small logo + red rule) === */
.hero-small { position: relative; z-index: 0; margin-top: -2px; display: flex; align-items: center; min-height: calc(17vh + 24px); background: url("/wp-content/uploads/2023/10/header_bg.png") center / cover no-repeat; border-bottom: 24px solid var(--color-red); }
.hero-small__inner { width: 100%; max-width: 1600px; margin-inline: auto; padding: var(--col-pad); display: flex; justify-content: center; }
.hero-small__inner img { width: 8%; }
@media (max-width: 1024px) { .hero-small__inner img { width: 20%; } }
@media (max-width: 767px) { .hero-small__inner img { width: 27%; } .hero-small--gallery .hero-small__inner img { width: 30%; } }

/* === Component: about (home: photo / text / photo) === */
.about { display: flex; align-items: stretch; margin-block: 100px; }
.about__media { flex: 0 0 25%; }
.about__media--left { padding-bottom: 50px; }
.about__media--left img { max-width: 75%; border-radius: 0 var(--radius-image) var(--radius-image) 0; }
.about__media--right img { max-width: 84%; margin-left: auto; border-radius: var(--radius-image) 0 0 var(--radius-image); }
.about__body { flex: 0 0 49.333%; display: flex; flex-direction: column; justify-content: center; padding: var(--col-pad); }
.about__text { font-size: var(--text-body); text-align: center; padding-bottom: 50px; }
.about__text p { margin-bottom: 16px; }
@media (max-width: 767px) {
  .about { flex-direction: column; }
  .about__media--left img, .about__media--right img { margin-inline: auto; border-radius: var(--radius-image); }
}

/* === Component: band (plain coloured strip) === */
.band { height: 70px; }
.band--sage { background: var(--color-sage); }

/* === Component: features (three icons with Pacifico captions) === */
.features { padding-block: 35px; }
.features__grid { display: grid; grid-template-columns: repeat(3, 1fr); }
.features__item { padding: var(--col-pad); text-align: center; }
.features__item img { margin-inline: auto; }
.features__item p { padding-bottom: 46px; font-family: var(--font-script); font-size: 23px; line-height: 40px; color: var(--color-red); }
@media (max-width: 767px) { .features__grid { grid-template-columns: 1fr; } }

/* === Component: shopfront (photo overlapping a sage block with a red rule) === */
.shopfront { position: relative; }
.shopfront__band { background: var(--color-sage); height: 297px; }
.shopfront__rule { height: 23px; border-bottom: 22px solid var(--color-red); }
.shopfront__photo { position: relative; margin-top: -370px; padding: var(--col-pad); display: flex; justify-content: center; }
.shopfront__photo img { width: 763px; }
.shopfront__after { height: 27px; }
@media (max-width: 767px) { .shopfront__after { display: none; } }

/* === Component: price-list ("Our Top Picks": name left, price right, three columns) === */
.picks { background: var(--color-red); padding: 50px var(--section-pad-x); }
.picks .container { padding: var(--col-pad); }
.picks__list { display: grid; grid-template-columns: repeat(3, 1fr); margin-top: 29px; }
.picks__item { display: flex; align-items: flex-start; padding: var(--col-pad); }
.picks__name { flex: 0 0 47.994%; font-family: var(--font-script); font-size: 20px; line-height: 20px; color: var(--color-white); }
.picks__price { flex: 0 0 50.248%; font-family: var(--font-body); font-size: 20px; line-height: 20px; color: var(--color-white); text-align: right; }
.picks .button-group { margin-top: 29px; }
@media (max-width: 767px) { .picks__list { grid-template-columns: 1fr; } }

/* === Component: app-promo ("Download Our Mobile App" on a pizza photo) === */
.app-promo { background: url("/wp-content/uploads/2023/10/app_bg.png") center / cover no-repeat; padding: 20px var(--section-pad-x); }
.app-promo--home { padding: 30px; }
.app-promo__grid { display: grid; grid-template-columns: 1fr 1fr; }
.app-promo__text { display: flex; flex-direction: column; justify-content: center; align-items: center; padding: var(--col-pad); text-align: center; color: var(--color-white); }
.app-promo__title { font-family: var(--font-script); color: var(--color-white); text-align: center; }
.app-promo__title-1 { display: block; font-size: var(--text-heading); line-height: 1; }
.app-promo__title-2 { display: block; margin-top: 10px; font-size: var(--text-heading-xl); line-height: 1; }
.app-promo__lead { width: 68.71%; margin-top: 38px; margin-bottom: 16px; font-size: var(--text-body); }
.app-promo .button-group { margin-top: 0; width: 100%; }
.app-promo__media { padding: var(--col-pad); display: flex; justify-content: center; align-items: flex-start; }
.app-promo__media img { width: 245px; }
@media (max-width: 1024px) { .app-promo__lead { margin-top: 10px; } }
@media (max-width: 767px) {
  .app-promo { padding: 30px; }
  .app-promo__grid { grid-template-columns: 1fr; }
  .app-promo__lead { width: auto; max-width: 225px; }
  .app-promo .button-group { margin-top: 0; }
}

/* === Component: red-rule (20px red line closing the app section, 42px gap below) === */
.red-rule { border-top: 1px solid transparent; border-bottom: 20px solid var(--color-red); margin-bottom: 42px; }

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

/* === Component: contact-section (red "Contact Us" block; the Elementor Pro form is not rebuilt) === */
.contact-section { background: var(--color-red); padding: 80px var(--section-pad-x); }
.contact-section .container { padding: var(--col-pad); }
.contact-section__phone { margin-top: 35px; text-align: center; font-size: var(--text-body); font-weight: 600; color: var(--color-white); }
.contact-section__phone a:hover { color: var(--color-sage); }

/* === Component: red-panel (red section with a ruled heading: /events/, /bookings/) === */
.red-panel { background: var(--color-red); padding: 50px var(--section-pad-x); }
.red-panel .container { padding: var(--col-pad); }

/* === Component: event-gallery (3 / 2 / 1 columns, lightbox) === */
.event-gallery { display: grid; grid-template-columns: repeat(3, 1fr); gap: 80px; padding-top: 50px; }
.event-gallery a { display: block; }
.event-gallery img { width: 100%; aspect-ratio: 367 / 255; object-fit: cover; }
@media (max-width: 1024px) { .event-gallery { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 767px) { .event-gallery { grid-template-columns: 1fr; } }

/* === Component: lead-text (white Inter text in red panels) === */
.lead-text { color: var(--color-white); font-size: 24px; text-align: center; padding: 25px; }
.lead-text a { text-decoration: underline; }

/* === Component: photo-gallery (/gallery/: rounded square thumbnails, lightbox) === */
.photo-gallery { display: grid; grid-template-columns: repeat(5, 1fr); gap: 34px; margin-block: 70px; }
.photo-gallery a { display: flex; justify-content: center; }
.photo-gallery img { width: 100%; max-width: 150px; border-radius: 25px; }
@media (max-width: 767px) { .photo-gallery { grid-template-columns: 1fr; } }

/* === Component: booking (photo + intro text in the red panel) === */
.booking { display: grid; grid-template-columns: 1fr 1fr; }
.booking__media { padding: var(--col-pad); display: flex; justify-content: center; }
.booking__media img { width: 477px; border-radius: 10px; }
.booking__text { padding: var(--col-pad); display: flex; align-items: center; font-size: var(--text-body); color: var(--color-white); }
@media (max-width: 767px) { .booking { grid-template-columns: 1fr; } }

/* === Component: site-footer (red; Quick Links / Find Us / Opening Hours / social + credit) === */
.site-footer { background: var(--color-red); padding-block: 50px; color: var(--color-white); }
.site-footer__grid { display: grid; grid-template-columns: 25% 23.281% 26.719% 25%; }
.site-footer__col { padding: var(--col-pad); }
.site-footer__heading { font-family: var(--font-body); font-size: var(--text-footer-heading); line-height: 1; font-weight: 400; margin-bottom: 10px; }
.site-footer__list { font-size: var(--text-body); font-weight: 200; line-height: 24px; }
.site-footer__phone { margin-top: 28px; font-size: var(--text-body); font-weight: 600; line-height: 24px; }
.site-footer__social { display: inline-flex; align-items: center; justify-content: center; width: 46px; height: 46px; border-radius: 50%; background: var(--color-white); color: var(--color-red); }
.site-footer__social svg { width: 23px; height: 23px; fill: currentColor; }
.site-footer__copyright { margin-top: 15px; font-size: var(--text-body); font-weight: 200; line-height: 24px; }
.site-footer__credit { font-size: var(--text-body); font-weight: 400; line-height: 24px; }
@media (max-width: 1024px) {
  .site-footer { padding-inline: var(--section-pad-x); }
  .site-footer__col--social { text-align: center; }
  .site-footer__col--social .site-footer__copyright, .site-footer__col--social .site-footer__credit { text-align: left; }
}
@media (max-width: 767px) {
  .site-footer__grid { grid-template-columns: 1fr; text-align: center; }
  .site-footer__col--social .site-footer__copyright, .site-footer__col--social .site-footer__credit { text-align: center; }
}

/* === Component: gallery lightbox (GLightbox, styled from here; library CSS in /assets/vendor/glightbox-3.3.1/) === */
.glightbox-clean .gslide-title { font-family: var(--font-body); margin-bottom: 0; }

/* === Component: contact-email (catalogue placeholder; this site has no email address, see SITE.md) === */
.contact-email { display: grid; gap: 1rem; justify-items: center; color: var(--color-white); }

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

/* === Page: /gallery/ === */
.gallery-section { margin-block: 70px; padding-inline: var(--section-pad-x); }
.gallery-section .container { padding: var(--col-pad); }

/* === Page: /events/ and /bookings/ (red panel sits 50px below the hero) === */
.red-panel--spaced { margin-block: 50px; }
.red-panel--top { margin-top: 50px; padding-bottom: 0; }
.events__cta { margin-top: 58px; }

/* === Page: /bookings/ (white-on-white "Bookings" heading after Contact Us, kept as on the original) === */
.ghost-heading { height: 100px; padding: var(--col-pad); }
.ghost-heading .container { padding: var(--col-pad); }

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

/* ============ 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; }
  [data-reveal] { visibility: visible !important; }
}
