/* Tomorrow Logistics - site styles
   Brand colours are the variables at the top. Change them here and the whole site follows.
   Note: brand green (#10B860) is too light for text on white, so text uses --green-dark;
   bright green is for buttons (with ink text), icons, lines and accents. */

:root {
  --green: #10B860;        /* brand green: buttons, icons, accents */
  --green-hover: #0DA054;  /* button hover */
  --green-dark: #087A3F;   /* green text on white (passes contrast) */
  --green-tint: #E9F8F0;   /* pale green wash for small highlights */
  --ink: #0F1419;          /* brand dark: text, header, footer */
  --white: #FFFFFF;
  --grey-50: #F6F8F9;
  --grey-100: #E8ECEF;
  --grey-300: #C5CDD2;
  --grey-600: #55616A;     /* secondary text (6.3:1 on white) */
  --on-dark: #C9D1D6;      /* secondary text on ink */
  --error: #B42318;
  --radius: 10px;
  --radius-lg: 14px;
  --max: 1120px;
  --header-h: 72px;
  --font: "Montserrat", "Montserrat Fallback", Arial, sans-serif;
}

/* Arial resized to Montserrat's proportions, so text doesn't jump when the web font loads */
@font-face {
  font-family: "Montserrat Fallback";
  src: local("Arial"), local("ArialMT"), local("Helvetica");
  ascent-override: 86.66%;
  descent-override: 22.47%;
  line-gap-override: 0%;
  size-adjust: 111.7%;
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: calc(var(--header-h) + 16px); -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  font-family: var(--font);
  font-size: 1rem;
  font-weight: 400;
  line-height: 1.65;
  color: var(--ink);
  background: var(--white);
  -webkit-font-smoothing: antialiased;
}
img, svg { max-width: 100%; display: block; }
a { color: var(--green-dark); text-underline-offset: .18em; }
a:hover { text-decoration-thickness: 2px; }

:focus-visible { outline: 3px solid var(--green); outline-offset: 3px; border-radius: 4px; }

.skip-link {
  position: absolute; left: 1rem; top: -4rem; z-index: 100;
  background: var(--green); color: var(--ink); font-weight: 500;
  padding: .6rem 1rem; border-radius: var(--radius); text-decoration: none;
}
.skip-link:focus { top: 1rem; }

.container { width: 100%; max-width: var(--max); margin: 0 auto; padding: 0 1.25rem; }

/* Type */
h1, h2, h3 { font-weight: 800; line-height: 1.15; margin: 0 0 .75rem; letter-spacing: -.015em; }
h1 { font-size: clamp(2.1rem, 6vw, 3.5rem); line-height: 1.08; }
h2 { font-size: clamp(1.6rem, 3.6vw, 2.25rem); }
h3 { font-size: 1.1rem; letter-spacing: 0; }
p { margin: 0 0 1rem; }
.lead { font-size: clamp(1.05rem, 2vw, 1.175rem); color: var(--grey-600); max-width: 38rem; }
.eyebrow {
  display: block; margin-bottom: .9rem;
  font-size: .78rem; font-weight: 500; letter-spacing: .16em; text-transform: uppercase;
  color: var(--green-dark);
}

/* Buttons and links */
.btn {
  display: inline-flex; align-items: center; justify-content: center;
  min-height: 48px; padding: .75rem 1.5rem;
  font: 500 1rem/1.2 var(--font); text-decoration: none; cursor: pointer;
  background: var(--green); color: var(--ink);
  border: 2px solid var(--green); border-radius: var(--radius);
  transition: background-color .15s, border-color .15s, transform .15s;
}
.btn:hover { background: var(--green-hover); border-color: var(--green-hover); }
.btn:active { transform: translateY(1px); }
.btn--small { min-height: 40px; padding: .5rem 1.1rem; font-size: .9rem; }
.btn--lg { min-height: 54px; padding: .85rem 2rem; font-size: 1.05rem; }
.text-link { font-weight: 500; color: var(--ink); text-decoration: underline; text-decoration-color: var(--green); text-decoration-thickness: 2px; }
.text-link:hover { color: var(--green-dark); }

/* Header */
.site-header { background: var(--ink); position: sticky; top: 0; z-index: 50; }
.header-inner { display: flex; align-items: center; justify-content: space-between; min-height: var(--header-h); gap: 1rem; }
.brand { display: block; line-height: 0; padding: 10px 0; }
.brand img { height: 48px; width: auto; }
.nav-toggle {
  display: none; min-height: 44px; background: none; border: 1px solid rgba(255,255,255,.35); color: var(--white);
  font: 500 .9rem var(--font); padding: .5rem 1rem; border-radius: var(--radius); cursor: pointer;
}
.nav-toggle:hover { border-color: var(--white); }
.site-nav ul { display: flex; align-items: center; gap: 1.75rem; list-style: none; margin: 0; padding: 0; }
.site-nav a { color: var(--white); text-decoration: none; font-size: .92rem; font-weight: 500; }
.site-nav a:not(.btn):hover { color: var(--green); }
.site-nav a.btn { color: var(--ink); }

/* Hero */
.hero {
  padding: 3.5rem 0 3.75rem;
  background: linear-gradient(160deg, #E3F6EC 0%, #F4FBF7 55%, var(--white) 100%);
}
.hero h1 { max-width: 18ch; margin-bottom: 1.25rem; }
.hero .accent {
  background: linear-gradient(var(--green), var(--green)) no-repeat 0 92% / 100% .14em;
  padding-bottom: .04em;
  -webkit-box-decoration-break: clone; box-decoration-break: clone;
}
.hero .lead { margin-bottom: 2rem; }
/* On phones the location sits on its own line, so the label is always two lines whatever the font */
@media (max-width: 599px) {
  .eyebrow--split > span { display: block; }
  .eyebrow--split .eyebrow-sep { display: none; }
}
.hero-actions { display: flex; flex-wrap: wrap; align-items: center; gap: 1rem 1.75rem; }
.hero-items {
  list-style: none; margin: 2.75rem 0 0; padding: 1.5rem 0 0; border-top: 1px solid #CFE9DB;
  display: flex; flex-wrap: wrap; gap: .6rem 1.75rem;
  font-size: .92rem; font-weight: 500; color: var(--grey-600);
}
.hero-items li { display: flex; align-items: center; gap: .6rem; }
.hero-items li::before { content: ""; width: 8px; height: 8px; border-radius: 50%; background: var(--green); flex: none; }

.hero-grid { display: grid; gap: 2.5rem; }
.hero-photo img, .photo-pair img { width: 100%; height: auto; border-radius: var(--radius-lg); background: var(--grey-100); }
.hero-photo img { aspect-ratio: 16 / 10; object-fit: cover; }

/* Sections */
.section { padding: 4rem 0; }
.section--tint { background: var(--grey-50); }
.section--green { background: linear-gradient(170deg, #EAF8F0 0%, #F5FBF8 60%, var(--white) 100%); }
.section--green-up { background: linear-gradient(350deg, #EAF8F0 0%, #F5FBF8 60%, var(--white) 100%); }
.section--green .steps li:not(:last-child)::after { background: #CFE9DB; }
.section--green-up .contact-list li { border-top-color: #CFE9DB; }
.section-head { margin-bottom: 2.25rem; max-width: 42rem; }
.section-head .lead { margin-bottom: 0; }

/* Cards */
.grid { display: grid; gap: 1rem; }
.card {
  background: var(--white); border: 1px solid var(--grey-100); border-radius: var(--radius-lg);
  padding: 1.5rem; transition: border-color .2s, box-shadow .2s;
}
.card:hover { border-color: var(--green); box-shadow: 0 6px 24px rgba(15,20,25,.06); }
.card .icon {
  width: 52px; height: 52px; padding: 11px; margin-bottom: 1.1rem;
  color: var(--green-dark); background: var(--green-tint); border-radius: 12px;
}
.card p { color: var(--grey-600); margin: 0; font-size: .95rem; }

/* Photo pair under "What we collect" */
.photo-pair { display: grid; grid-template-columns: 1fr 1fr; gap: 1rem; margin-top: 1rem; }
.photo-pair img { aspect-ratio: 16 / 10; object-fit: cover; }

/* Steps: vertical with a connecting line on mobile, a row on desktop */
.steps { list-style: none; counter-reset: step; margin: 0; padding: 0; display: grid; gap: 1.75rem; }
.steps li { counter-increment: step; position: relative; padding-left: 3.75rem; }
.steps li::before {
  content: counter(step); position: absolute; top: 0; left: 0; z-index: 1;
  width: 40px; height: 40px; border-radius: 50%;
  display: grid; place-items: center;
  background: var(--ink); color: var(--green); font-weight: 800;
}
.steps li:not(:last-child)::after {
  content: ""; position: absolute; left: 19px; top: 40px; bottom: -1.75rem; width: 2px; background: var(--grey-100);
}
.steps h3 { padding-top: .45rem; }
.steps p { color: var(--grey-600); font-size: .95rem; margin: 0; }

/* Sectors */
.sector-list { list-style: none; margin: 0; padding: 0; display: grid; gap: 0 2.5rem; }
.sector-list li { position: relative; padding: 1rem 0 1rem 2rem; border-top: 1px solid var(--grey-100); font-weight: 500; }
.sector-list li::before {
  content: ""; position: absolute; left: 0; top: 1.35rem; width: 14px; height: 2px; background: var(--green);
}

/* Compliance */
.split { display: grid; gap: 2.5rem; }
.checks { list-style: none; margin: 1.5rem 0 0; padding: 0; }
.checks li { position: relative; padding-left: 2rem; margin-bottom: .9rem; font-weight: 500; }
.checks li::before {
  content: ""; position: absolute; left: 0; top: .28em; width: 1.15rem; height: 1.15rem;
  background: var(--green-dark); border-radius: 50%;
  -webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M12 24a12 12 0 1 0 0-24 12 12 0 0 0 0 24zm-1.5-7.2-4.3-4.3 1.4-1.4 2.9 2.9 6.2-6.2 1.4 1.4z'/%3E%3C/svg%3E") center/contain no-repeat;
          mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M12 24a12 12 0 1 0 0-24 12 12 0 0 0 0 24zm-1.5-7.2-4.3-4.3 1.4-1.4 2.9 2.9 6.2-6.2 1.4 1.4z'/%3E%3C/svg%3E") center/contain no-repeat;
}
.facts { margin: 0; border: 1px solid var(--grey-100); border-radius: var(--radius-lg); background: var(--white); overflow: hidden; }
.facts div { display: grid; gap: .15rem; padding: 1.1rem 1.4rem; border-top: 1px solid var(--grey-100); }
.facts div:first-child { border-top: 0; }
.facts dt { font-size: .78rem; font-weight: 500; letter-spacing: .12em; text-transform: uppercase; color: var(--grey-600); }
.facts dd { margin: 0; font-weight: 500; overflow-wrap: anywhere; }

/* Quote / contact: on mobile the form comes straight after the heading, contact details after */
.contact-grid { display: grid; gap: 2rem; }
.contact-intro { display: contents; }
.contact-intro > .section-intro { order: 1; }
.contact-grid > .form { order: 2; }
.contact-intro > .contact-list { order: 3; margin-top: 0; }
.contact-list { list-style: none; margin: 1.75rem 0 0; padding: 0; }
.contact-list li { padding: .9rem 0; border-top: 1px solid var(--grey-100); overflow-wrap: anywhere; }
.contact-list strong { display: block; font-size: .78rem; font-weight: 500; letter-spacing: .12em; text-transform: uppercase; color: var(--grey-600); }

.form { background: var(--white); border: 1px solid var(--grey-100); border-radius: var(--radius-lg); padding: 1.5rem 1.25rem; box-shadow: 0 8px 30px rgba(15,20,25,.06); }
.form-title { font-size: 1.2rem; margin-bottom: 1.25rem; }
.field { margin-bottom: 1.1rem; }
.field-row { display: grid; gap: 0 1rem; }
label, legend { display: block; font-weight: 500; font-size: .92rem; margin-bottom: .35rem; padding: 0; }
.req { color: var(--green-dark); }
input[type="text"], input[type="email"], input[type="tel"], textarea {
  width: 100%; min-height: 48px; font: inherit; font-size: 1rem; color: var(--ink); /* 16px stops iOS zooming in */
  padding: .7rem .9rem; border: 1.5px solid var(--grey-300); border-radius: var(--radius); background: var(--white);
  transition: border-color .15s;
}
input[type="text"]:hover, input[type="email"]:hover, input[type="tel"]:hover, textarea:hover { border-color: var(--grey-600); }
textarea { min-height: 120px; resize: vertical; }
input:focus, textarea:focus { outline: 3px solid rgba(16,184,96,.35); outline-offset: 0; border-color: var(--green-dark); }
fieldset { border: 0; margin: 0 0 1.1rem; padding: 0; min-width: 0; }
.options { display: grid; gap: .5rem; }
.option {
  display: flex; align-items: center; gap: .65rem; margin: 0; min-height: 48px;
  padding: .55rem .85rem; border: 1.5px solid var(--grey-100); border-radius: var(--radius);
  font-weight: 400; cursor: pointer; transition: border-color .15s, background-color .15s;
}
.option:hover { border-color: var(--grey-300); }
.option:has(input:checked) { border-color: var(--green-dark); background: var(--green-tint); }
.consent { display: flex; align-items: flex-start; gap: .65rem; font-weight: 400; margin: 0; font-size: .9rem; color: var(--grey-600); }
.option input, .consent input { width: 1.2rem; height: 1.2rem; accent-color: var(--green-dark); flex: none; margin: 0; }
.consent input { margin-top: .2rem; }
.field--consent { margin-bottom: 1.4rem; }
.error { display: none; color: var(--error); font-size: .85rem; font-weight: 500; margin-top: .35rem; }
.has-error .error { display: block; }
.has-error input[type="text"], .has-error input[type="email"], .has-error input[type="tel"], .has-error textarea { border-color: var(--error); }
.hp { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }
.form .btn { width: 100%; }
.form-note { font-size: .85rem; color: var(--grey-600); margin: .9rem 0 0; }
.form-note:empty { display: none; }

/* Page body for privacy / thanks / 404 */
.page { padding: 3.5rem 0 5rem; min-height: 60vh; }
.page .container { max-width: 760px; }
.page h1 { margin-bottom: 1rem; }
.page h2 { font-size: 1.3rem; margin-top: 2.25rem; }
.page ul { padding-left: 1.2rem; }
.page li { margin-bottom: .4rem; }
.centered { text-align: center; }
.centered .lead { margin-left: auto; margin-right: auto; }
.page-actions { margin-top: 2rem; }

/* Footer */
.site-footer { background: var(--ink); color: var(--on-dark); padding: 3.5rem 0 2rem; font-size: .92rem; }
.footer-grid { display: grid; gap: 2rem; margin-bottom: 2.5rem; }
.footer-brand img { height: 48px; width: auto; margin-bottom: 1.25rem; }
.footer-brand p { max-width: 22rem; }
.site-footer h2 { font-size: .78rem; font-weight: 500; letter-spacing: .16em; text-transform: uppercase; color: var(--green); margin-bottom: .75rem; }
.site-footer ul { list-style: none; margin: 0; padding: 0; }
.site-footer li { margin-bottom: .5rem; overflow-wrap: anywhere; }
.site-footer a { color: var(--white); text-decoration: none; }
.site-footer a:hover { color: var(--green); text-decoration: underline; }
.footer-legal { border-top: 1px solid rgba(255,255,255,.12); padding-top: 1.5rem; font-size: .82rem; color: #9AA6AE; }
.footer-legal p { margin: 0 0 .35rem; }
.footer-legal a { color: inherit; text-decoration: underline; }

/* Mobile "Get a quote" bar */
.mobile-cta { display: none; }

/* Scroll reveal (subtle, optional) */
.js .reveal { opacity: 0; transform: translateY(12px); transition: opacity .5s ease, transform .5s ease; }
.js .reveal.is-visible { opacity: 1; transform: none; }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { transition: none !important; animation: none !important; }
  .js .reveal { opacity: 1; transform: none; }
}

/* Mobile and small tablet */
@media (max-width: 899px) {
  .mobile-cta {
    display: block; position: fixed; left: 0; right: 0; bottom: 0; z-index: 40;
    padding: .75rem 1.25rem calc(.75rem + env(safe-area-inset-bottom));
    background: rgba(255,255,255,.96); border-top: 1px solid var(--grey-100);
    box-shadow: 0 -4px 20px rgba(15,20,25,.06);
    transition: transform .25s ease;
  }
  .mobile-cta .btn { width: 100%; }
  .mobile-cta.is-hidden { transform: translateY(110%); visibility: hidden; transition: transform .25s ease, visibility 0s .25s; }
  .has-mobile-cta { padding-bottom: calc(76px + env(safe-area-inset-bottom)); }
}

/* Tablet and up */
@media (min-width: 640px) {
  .grid--4 { grid-template-columns: repeat(2, 1fr); }
  .field-row { grid-template-columns: 1fr 1fr; }
  .options { grid-template-columns: 1fr 1fr; }
  .sector-list { grid-template-columns: 1fr 1fr; }
  .form { padding: 2rem; }
}
@media (min-width: 700px) {
  .footer-grid { grid-template-columns: 2fr 1fr 1fr; }
  .hero { padding: 5rem 0 4.5rem; }
  .section { padding: 5rem 0; }
}

/* Desktop */
@media (min-width: 980px) {
  .container { padding: 0 2rem; }
  .hero { padding: 5.5rem 0 5rem; }
  .hero-grid { grid-template-columns: minmax(0, 1fr) 460px; gap: 4rem; align-items: center; }
  .hero h1 { font-size: 3.1rem; }
  .hero-photo img { aspect-ratio: 4 / 3; }
  .photo-pair { gap: 1.25rem; margin-top: 1.25rem; }
  .section { padding: 6.5rem 0; }
  .section-head { margin-bottom: 3rem; }
  .grid--4 { grid-template-columns: repeat(4, 1fr); gap: 1.25rem; }
  .card { padding: 1.75rem; }
  .steps { grid-template-columns: repeat(4, 1fr); gap: 2rem; }
  .steps li { padding: 3.75rem 0 0; }
  .steps li:not(:last-child)::after { left: 52px; right: -1.5rem; top: 19px; bottom: auto; width: auto; height: 2px; }
  .steps h3 { padding-top: 0; }
  .sector-list { grid-template-columns: repeat(3, 1fr); }
  .split { grid-template-columns: 1fr 1fr; gap: 5rem; align-items: start; }
  .contact-grid { grid-template-columns: 1fr 1.3fr; grid-template-rows: auto 1fr; gap: 0 5rem; align-items: start; }
  .contact-intro > .section-intro { grid-column: 1; grid-row: 1; }
  .contact-intro > .contact-list { grid-column: 1; grid-row: 2; margin-top: 1.75rem; }
  .contact-grid > .form { grid-column: 2; grid-row: 1 / span 2; }
}

/* Mobile navigation */
@media (max-width: 899px) {
  .js .nav-toggle { display: inline-block; }
  .js .site-nav { display: none; position: absolute; left: 0; right: 0; top: 100%; background: var(--ink); border-top: 1px solid rgba(255,255,255,.1); padding: .5rem 1.25rem 1.5rem; box-shadow: 0 12px 24px rgba(0,0,0,.25); }
  .js .site-nav.is-open { display: block; }
  .site-nav ul { flex-direction: column; align-items: stretch; gap: 0; }
  .site-nav li { border-bottom: 1px solid rgba(255,255,255,.08); }
  .site-nav a { display: block; padding: .9rem 0; font-size: 1rem; }
  .site-nav li:last-child { border: 0; padding-top: 1rem; }
  .site-nav a.btn { display: flex; text-align: center; padding: .75rem 1rem; }
  /* without JS, keep the nav wrapped under the logo */
  html:not(.js) .header-inner { flex-wrap: wrap; padding: .5rem 0 .75rem; }
  html:not(.js) .site-nav ul { flex-direction: row; flex-wrap: wrap; gap: .5rem 1.25rem; }
  html:not(.js) .site-nav li { border: 0; padding: 0; }
  html:not(.js) .site-nav a { padding: .25rem 0; }
}
@media (min-width: 900px) and (max-width: 1023px) {
  .site-nav ul { gap: 1.25rem; }
}
