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

/* ============ 1. Tokens ============ */
:root {
  /* Colours (from the original's computed styles; the original uses several near-identical greens, kept exactly) */
  --color-bg: #161616;            /* page background */
  --color-green: #34fb1c;         /* header pill, header band, menu text */
  --color-green-footer: #34fc1c;  /* footer background, app section top border */
  --color-green-strip: #3cfc1c;   /* partner logo strip borders, about buttons */
  --color-green-icon: #33f91b;    /* footer social icons */
  --color-white: #ffffff;         /* display headings */
  --color-text-light: #fafafa;    /* body copy */
  --color-black: #000000;         /* header text/buttons, footer text and dividers */
  --color-dark: #1f1c1c;          /* footer heading, social icon circles */
  --color-button-text: #171717;   /* about buttons */
  --color-nav-active: #777777;    /* header menu hover / current section */
  --color-dropdown-hover: #424242;/* mobile menu hover / current section */

  /* Typography */
  --font-display: "Anton", sans-serif;   /* headings, menu, buttons */
  --font-body: "Poppins", sans-serif;    /* paragraphs */
  --font-footer: "Roboto", sans-serif;   /* footer details (600) */
  --text-display: 64px;                  /* section headings */
  --text-hero: 200px;                    /* hero heading (126px tablet, 63px mobile) */
  --text-copy: 20px;
  --leading-copy: 38px;
  --tracking-copy: 1px;

  /* Spacing and shape */
  --section-space: 120px;
  --gutter: 30px;
  --col-pad: 10px;                       /* Elementor column padding */
  --container: 1280px;
  --container-footer: 1140px;
  --radius-pill: 41px;
  --radius-button: 19px;

  /* Header */
  --header-h: 186px;                     /* sticky header height (anchor offset) */

  /* Motion (match the original's timings) */
  --duration: 300ms;
  --ease: ease;
}

/* ============ 2. Fonts ============ */
/* Self-hosted Google Fonts (OFL), latin subset. */
@font-face { font-family: "Anton"; src: url("/assets/fonts/anton-400-latin.woff2") format("woff2"); font-weight: 400; font-style: normal; font-display: swap; }
@font-face { font-family: "Poppins"; src: url("/assets/fonts/poppins-400-latin.woff2") format("woff2"); font-weight: 400; font-style: normal; font-display: swap; }
@font-face { font-family: "Roboto"; src: url("/assets/fonts/roboto-600-latin.woff2") format("woff2"); font-weight: 600; 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-light); background: var(--color-bg); overflow-x: clip; }
img, svg, video, iframe { max-width: 100%; }
img, video { height: auto; display: block; }
h1, h2, h3 { margin: 0; font-weight: 400; line-height: 1; }
p { margin: 0; }
ul { margin: 0; padding: 0; list-style: none; }
a { color: inherit; }
a:focus-visible, button:focus-visible { outline: 2px solid var(--color-white); outline-offset: 2px; }
[id] { scroll-margin-top: var(--header-h); }

/* ============ 4. Layout ============ */
.section-space { margin-block: var(--section-space); }

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

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

/* === Component: svg-sprite (icon symbols in the header partial) === */
.svg-sprite { position: absolute; width: 0; height: 0; overflow: hidden; }

/* === Component: site-header ===
 * Outer band (padding 25px 30px) whose green background fades in with scroll
 * (--header-alpha, set by site.js from data-header-fade-range); inside it the rounded green
 * pill holds menu | logo | buttons. Sticky at ≥768px only (as the original). */
.site-header { position: sticky; top: 0; z-index: 50; padding: 25px var(--gutter); background: rgb(52 251 28 / var(--header-alpha, 0)); }
.site-header__pill { display: grid; grid-template-columns: 45.084% 9.73% 1fr; align-items: center; margin: var(--col-pad); padding-inline: max(0px, (100% - 2 * var(--col-pad) - var(--container)) / 2); background: var(--color-green); border-radius: var(--radius-pill); }
.site-header__menu, .site-header__logo, .site-header__buttons { padding: var(--col-pad); min-width: 0; }
.site-header__logo { display: flex; justify-content: center; }
.site-header__logo img { width: 97px; max-width: none; }
.site-header__buttons { display: flex; justify-content: flex-end; align-items: center; gap: 34px; }

/* === Component: outline-button (header Download / Order Now) === */
.outline-button { display: inline-flex; align-items: center; padding: 12px 24px; border: 3px solid var(--color-black); border-radius: var(--radius-button); font-family: var(--font-display); font-size: 20px; line-height: 20px; color: var(--color-black); text-decoration: none; white-space: nowrap; }

/* === Component: site-nav (desktop row; burger + dropdown at ≤1024px) === */
.site-nav__list { display: flex; flex-wrap: wrap; }
.site-nav__list a { display: flex; padding: 13px 20px; font-family: var(--font-display); font-size: 20px; line-height: 20px; color: var(--color-black); text-decoration: none; transition: color var(--duration) var(--ease); }
.site-nav__list a:hover, .site-nav__list a:focus-visible, .site-nav__list a.is-active { color: var(--color-nav-active); }
.nav-toggle { display: none; align-items: center; justify-content: center; margin: 0 auto; width: 48px; height: 48px; padding: 8px; border: 0; border-radius: 3px; background: var(--color-black); color: var(--color-green); cursor: pointer; }
.nav-toggle svg { width: 32px; height: 32px; }
.nav-toggle__close { display: none; }
.nav-toggle[aria-expanded="true"] .nav-toggle__open { display: none; }
.nav-toggle[aria-expanded="true"] .nav-toggle__close { display: block; }

@media (max-width: 1024px) {
  :root { --header-h: calc(70px + min(97px, 0.14 * (100vw - 80px) - 20px)); }
  .site-header__pill { grid-template-columns: 40% 14% 1fr; }
  .site-header__logo img { width: 100%; max-width: 97px; }
  .site-header__buttons { gap: 12px; }
  .nav-toggle { display: flex; }
  /* The dropdown is absolutely positioned at its static place (just under the burger) and
   * stretched to the header's full width, like Elementor's "stretch" dropdown. */
  .site-nav { position: absolute; left: 0; right: 0; margin-top: 10px; display: grid; grid-template-rows: 0fr; visibility: hidden; 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; background: var(--color-bg); }
  .site-nav__list a { padding: 10px 20px; color: var(--color-green); }
  .site-nav__list a:hover, .site-nav__list a:focus-visible { color: var(--color-green); background: var(--color-dropdown-hover); }
  .site-nav__list a.is-active:not(:hover):not(:focus-visible) { color: var(--color-green); } /* the original's dropdown shows no current-section highlight */
}
@media (max-width: 767px) {
  :root { --header-h: 0px; }
  .site-header { position: relative; padding: 0; }
  .site-header__pill { display: block; margin: 0; padding: 30px; border-radius: 0; }
  .site-header__menu { padding: 0; }
  .site-header__logo img { width: 97px; }
  .site-header__buttons { display: none; }
}

/* === Component: display-heading (Anton section headings) === */
.display-heading { font-family: var(--font-display); font-size: var(--text-display); line-height: 1; color: var(--color-white); }

/* === Component: copy (Poppins body text) === */
.copy { font-family: var(--font-body); font-size: var(--text-copy); line-height: var(--leading-copy); letter-spacing: var(--tracking-copy); color: var(--color-text-light); }
.copy p { margin-block: 20px; }

/* === Component: gradient-button (About: ORDER NOW / VIEW MENU) === */
.button-group { display: flex; flex-wrap: wrap; gap: 47px; }
.gradient-button { display: inline-flex; padding: 20px; border-radius: 3px; background: linear-gradient(to right, var(--color-green), var(--color-bg)); font-family: var(--font-display); font-size: 23px; line-height: 23px; color: var(--color-button-text); text-decoration: none; }

/* === Component: hero (#home) === */
.hero { padding: 0 var(--gutter); background: url("/wp-content/uploads/2023/07/herobg.png") right bottom / 73% auto no-repeat; }
.hero__inner { display: flex; align-items: center; max-width: 1440px; min-height: 100vh; margin-inline: auto; }
.hero__content { width: 69.766%; padding: var(--col-pad); }
.hero__title { font-family: var(--font-display); font-size: var(--text-hero); line-height: 1; color: var(--color-white); }
.hero__underline { width: 41%; margin-top: 20px; }
@media (max-width: 1024px) {
  .hero__inner { min-height: 71vh; }
  .hero__title { font-size: 126px; }
}
@media (max-width: 767px) {
  /* Original: the content column and the empty second column share the spare height equally. */
  .hero__inner { flex-direction: column; align-items: stretch; }
  .hero__inner::after { content: ""; flex: 1 0 20px; }
  .hero__content { flex: 1 0 auto; display: flex; flex-direction: column; justify-content: center; width: 100%; }
  .hero__title { font-size: 63px; }
}

/* === Component: logo-strip (partner logos between green borders) === */
.logo-strip { display: grid; grid-template-columns: repeat(4, 1fr); align-items: center; padding: 20px var(--gutter); border-block: 4px solid var(--color-green-strip); }
.logo-strip__item { display: flex; justify-content: center; padding: var(--col-pad); }
@media (max-width: 767px) {
  .logo-strip { grid-template-columns: 1fr; }
  .logo-strip__item--andrews img { width: 50%; }
  .logo-strip__item--tuffins img { width: calc(291px * 0.4); }
  .logo-strip__item--mcdonalds img { width: 31%; }
}

/* === Component: about (text column + photo column) === */
.about { display: grid; grid-template-columns: 16.874% 35.229% 47.561%; padding-left: var(--gutter); }
.about__text { grid-column: 2; display: flex; flex-direction: column; justify-content: center; padding: 30px; }
.about__text .copy { margin-block: 20px; }
.about__photo { min-height: 600px; background: url("/wp-content/uploads/2023/07/Rectangle-3.png") right center no-repeat; }
@media (max-width: 1024px) {
  .about { grid-template-columns: 1fr 1fr; }
  .about__text { grid-column: 1; }
  .about__photo { background-size: contain; }
}
@media (max-width: 767px) {
  .about { grid-template-columns: 1fr; }
  .about__text { padding: 15px; }
}

/* === Component: food-grid ("What Do You Fancy?" three images) === */
.food { padding: 0 var(--gutter); }
.food__inner { max-width: var(--container); margin-inline: auto; padding: var(--col-pad); }
.food__title { text-align: center; margin-bottom: 90px; }
.food-grid { display: grid; grid-template-columns: repeat(3, 1fr); }
.food-grid__item { display: flex; justify-content: center; padding: var(--col-pad); }
@media (max-width: 767px) {
  .food-grid { grid-template-columns: 1fr; }
  .food-grid__item img { width: 100%; }
}

/* === Component: app-promo (#download: phones either side of the app pitch) === */
.app-promo { display: grid; grid-template-columns: repeat(3, 1fr); align-items: start; margin-bottom: var(--section-space); padding-top: var(--section-space); border-top: 2px solid var(--color-green-footer); }
.app-promo__phone { display: flex; padding: var(--col-pad); }
.app-promo__phone--right { justify-content: flex-end; }
.app-promo__body { display: flex; flex-direction: column; align-items: center; padding: var(--col-pad); text-align: center; }
.app-promo__body .display-heading { margin-bottom: 10px; }
.app-promo__icon { display: block; width: 50px; height: 50px; margin-bottom: 4px; color: var(--color-white); }
.app-promo__icon svg { display: block; width: 50px; height: 50px; fill: currentColor; }
.app-promo__badges { display: inline-block; }
@media (max-width: 1024px) {
  .app-promo { align-items: center; }
}
@media (max-width: 767px) {
  .app-promo { grid-template-columns: 1fr; }
  .app-promo__phone--left img { display: none; } /* the empty column keeps its 20px padding, as the original */
}

/* === Component: site-footer (green; FOLLOW US, social icons, phone/email row, copyright row; the rows are H2s as on the original) === */
.site-footer { padding: var(--section-space) var(--gutter); background: var(--color-green-footer); color: var(--color-black); }
.site-footer__inner { max-width: var(--container-footer); margin-inline: auto; padding: var(--col-pad); }
.site-footer__heading { margin-bottom: 10px; color: var(--color-dark); text-align: center; }
.site-footer__row { display: grid; grid-template-columns: 1fr 1fr; margin-top: 15px; padding-top: 15px; border-top: 3.1px solid var(--color-black); }
.site-footer__detail { padding: var(--col-pad); font-family: var(--font-footer); font-size: 24px; font-weight: 600; line-height: 1; }
.site-footer__detail:last-child { text-align: end; }
.site-footer__row a { text-decoration: none; }
.site-footer__row a:hover { text-decoration: underline; }
@media (max-width: 767px) {
  .site-footer__row { grid-template-columns: 1fr; }
  .site-footer__detail, .site-footer__detail:last-child { font-size: 21px; text-align: center; }
}

/* === Component: social-icons (dark circles, green icons; NOT links on the original: decision d4) === */
.social-icons { display: flex; justify-content: center; flex-wrap: wrap; gap: 45px; --icon-size: 57px; }
.social-icon { display: inline-flex; align-items: center; justify-content: center; width: calc(var(--icon-size) * 2); height: calc(var(--icon-size) * 2); border-radius: 50%; background: var(--color-dark); color: var(--color-green-icon); }
.social-icon svg { width: var(--icon-size); height: var(--icon-size); fill: currentColor; }
@media (max-width: 1024px) { .social-icons { --icon-size: 32px; } }
@media (max-width: 767px) { .social-icons { --icon-size: 27px; } }

/* === Component: not-found (404 page) === */
.not-found { padding: var(--section-space) var(--gutter); text-align: center; }
.not-found .copy { max-width: 640px; margin: 30px auto; }
.not-found__links { display: flex; flex-wrap: wrap; justify-content: center; gap: 20px 47px; }

/* === Component: contact-email (kept for a future form; the original has none) === */
.contact-email { display: grid; gap: 16px; justify-items: center; text-align: center; }
.contact-email__address { font-weight: 600; word-break: break-word; }

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

/* ============ 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; }
}
