/*
 * Design refresh (approved by George, 2026-12-04).
 * Loaded after style.css on the home page only for now. Other pages get it as
 * they are refreshed; once every page uses it, fold it into style.css.
 *
 * Palette = the six app / web portal colours, plus three close variations
 * marked "variation" (needed for readable text and hover states).
 */

:root {
  /* App + portal palette */
  --sb-cream: #eff5ea;        /* Light cream */
  --sb-green-pale: #d6ecdb;   /* Very light green */
  --sb-grey: #82897e;         /* Grey */
  --sb-green-light: #89d48d;  /* Light green */
  --sb-green: #4caf53;        /* Green */
  --sb-green-dark: #017020;   /* Dark green */

  /* Close variations */
  --sb-green-deep: #01591a;   /* variation: darker dark green, hover + gradient end */
  --sb-ink: #2b2f29;          /* variation: grey taken near-black, headings + body */
  --sb-ink-muted: #5c6358;    /* variation: darker grey, readable secondary text */

  --sb-font-display: Sora, Manrope, system-ui, sans-serif;
  --sb-font-body: Manrope, system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  --sb-radius: 16px;          /* matches the app's button radius */
}

/* ---------- Base type ---------- */
body {
  font-family: var(--sb-font-body);
  color: var(--sb-ink);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

h1, h2, h3,
main h1, main h2 {
  font-family: var(--sb-font-display);
  letter-spacing: -0.025em;
  color: inherit;
}

main h2 {
  font-size: clamp(1.6rem, 1.2rem + 1.6vw, 2.25rem);
  line-height: 1.15;
  font-weight: 700;
}

main section p {
  font-size: 1.0625rem;
}

a:focus, button:focus { outline-color: var(--sb-green-dark); }

/* ---------- Header ---------- */
.logo-text {
  font-family: var(--sb-font-display);
  font-weight: 700;
  letter-spacing: -0.02em;
  color: var(--sb-ink);
}

nav a {
  font-weight: 600;
  font-size: 0.95rem;
  color: var(--sb-ink);
}

nav a:hover { color: var(--sb-green-dark); }
nav a.active { color: var(--sb-green-dark); }

/* ---------- Green bands: hero + alternate sections ---------- */
.greenBackground {
  background: linear-gradient(135deg, var(--sb-green-dark) 0%, var(--sb-green) 100%);
}

/* Alternate feature sections use the light cream instead of a second loud green */
.wrapper.greenBackground:not(:first-of-type) {
  background: var(--sb-cream);
}

.wrapper.greenBackground:not(:first-of-type) section {
  color: var(--sb-ink);
}

/* The sections with inline colour #333 move to the new ink colour */
main section[style] { color: var(--sb-ink) !important; }

main section p { color: var(--sb-ink-muted); }
.hero p, .hero .user-count { color: #fff; }

/* More breathing room between feature sections */
.equipment-types,
.weather-loading,
.record-exporting,
.chemical-brews,
.product-registry {
  padding-top: clamp(2.5rem, 1rem + 4vw, 4.5rem);
  padding-bottom: clamp(2.5rem, 1rem + 4vw, 4.5rem);
}

/* ---------- Hero ---------- */
.hero-text h1 {
  font-size: clamp(2.25rem, 1.6rem + 2.4vw, 3.25rem);
  line-height: 1.08;
  letter-spacing: -0.03em;
  color: #fff;
}

.hero-text h1 .highlight-text { color: var(--sb-green-light); }

.hero-text > p { font-size: 1.125rem; opacity: 0.95; }

.app-rating {
  background: rgba(255, 255, 255, 0.14);
  border-color: rgba(255, 255, 255, 0.28);
  box-shadow: none;
}

.rating-text { font-weight: 600; }

.features {
  width: fit-content;
  max-width: 100%;
  background: rgba(1, 89, 26, 0.28);
  border-color: rgba(255, 255, 255, 0.16);
  border-radius: var(--sb-radius);
  padding: 1.25rem 1.6rem 1.25rem 1.4rem;
}

.features li { font-weight: 500; font-size: 1rem; }

.hero-images img,
main section img {
  filter: drop-shadow(0 18px 30px rgba(1, 39, 10, 0.22));
}

/* ---------- FAQ ---------- */
.faq-section {
  padding-top: clamp(2.5rem, 1rem + 4vw, 4.5rem);
  padding-bottom: clamp(2.5rem, 1rem + 4vw, 4.5rem);
}

.faq-section h2 { color: var(--sb-ink); }

.faq-container { gap: 0.75rem; }

.faq-item {
  background: var(--sb-cream);
  border: 1px solid var(--sb-green-pale);
  border-radius: var(--sb-radius);
  box-shadow: none;
}

.faq-item:hover { box-shadow: none; border-color: var(--sb-green-light); }

.faq-question {
  font-family: var(--sb-font-body);
  font-weight: 700;
  color: var(--sb-ink);
}

.faq-question:hover,
.faq-question:focus { background-color: var(--sb-green-pale); }
.faq-question:focus { outline-color: var(--sb-green-dark); }

.faq-toggle { color: var(--sb-green-dark); font-weight: 600; }

.faq-answer { background-color: #fff; }
.faq-answer p { color: var(--sb-ink-muted); }

/* ---------- Footer ---------- */
hr { border: 0; border-top: 1px solid var(--sb-green-pale); }

footer nav a { color: var(--sb-ink); font-weight: 600; }
footer nav a:hover { color: var(--sb-green-dark); }
.footer-columns .footer-col-title { color: #5d665b; }
.copyright { color: var(--sb-ink-muted); }

/* ---------- Testimonials ---------- */
.testimonials-section h2 { color: var(--sb-ink); }
.testimonial { border-radius: var(--sb-radius); border-color: var(--sb-green-pale); box-shadow: none; background: var(--sb-cream); }
.testimonial-message { color: var(--sb-ink); }
.author-name { color: var(--sb-ink); }
.author-details { color: var(--sb-ink-muted); }

/* Taller line height would let the hidden skip link peek out */
.skip-link { top: -60px; }

/* ---------- Mobile: screenshots before the feature list ---------- */
@media (max-width: 768px) {
  /* Let the hero text's children join the hero's flex column so they can be reordered */
  .hero-text { display: contents; }
  .hero-images { order: 1; max-width: 90%; margin: 0.5rem auto 1.5rem; }
  .features { order: 2; width: 100%; margin-top: 0; }
}

/* =====================================================================
 * Home page additions (preview only)
 * ===================================================================== */

/* ---------- OS-aware download buttons ---------- */
.smart-dl { display: flex; flex-wrap: wrap; gap: 0.75rem; align-items: center; margin: 1.75rem 0 2.25rem; }
.smart-dl--center { justify-content: center; margin: 0; }
.smart-dl__store img { display: block; height: 52px; width: auto; }
.smart-dl__qr { display: none; align-items: center; gap: 0.6rem; margin-left: 0.5rem; padding-left: 1.1rem; border-left: 1px solid rgba(255, 255, 255, 0.3); color: rgba(255, 255, 255, 0.9); font-size: 0.85rem; font-weight: 600; line-height: 1.3; }
.smart-dl__qr img { width: 64px; height: 64px; background: #fff; border-radius: 8px; padding: 4px; }
/* Phones: only the store for this device (unless --both) */
[data-os="ios"] .smart-dl:not(.smart-dl--both) .smart-dl__android,
[data-os="android"] .smart-dl:not(.smart-dl--both) .smart-dl__ios { display: none; }
/* Desktop: both badges plus a scannable QR */
[data-os="desktop"] .smart-dl__qr { display: inline-flex; }

/* Outline button (used for secondary actions like the sample report) */
.sb-btn-outline {
  display: inline-flex; align-items: center; gap: 0.5rem; min-height: 50px; padding: 0 1.4rem;
  border-radius: var(--sb-radius); border: 2px solid var(--sb-green-dark); color: var(--sb-green-dark);
  font-weight: 700; background: transparent; transition: background 0.15s ease;
}
.sb-btn-outline:hover { background: var(--sb-green-pale); }

/* ---------- Stats strip ---------- */
.stats-band { background: var(--sb-cream); padding-top: 0; padding-bottom: 0; }
.stats-strip { max-width: 1000px; margin: 0 auto; display: grid; grid-template-columns: repeat(4, 1fr); gap: 1rem; padding: 1.75rem 2rem; text-align: center; }
.stats-strip b { display: block; font: 700 clamp(1.5rem, 1.1rem + 1.5vw, 2rem)/1.1 var(--sb-font-display); color: var(--sb-green-dark); letter-spacing: -0.02em; }
.stats-strip span { font-size: 0.9rem; color: var(--sb-ink-muted); font-weight: 600; }
.stats-strip .tbd { color: var(--sb-grey); }
@media (max-width: 768px) { .stats-strip { grid-template-columns: repeat(2, 1fr); padding: 1.25rem 0; row-gap: 1.25rem; } }

/* ---------- Reviews (replaces the moving carousel) ---------- */
.reviews-section { max-width: 1000px; margin: 0 auto; padding: clamp(2.5rem, 1rem + 4vw, 4.5rem) 2rem; text-align: center; }
.reviews-section h2 { margin-bottom: 2rem; color: var(--sb-ink); }
.review { margin: 0; background: #fff; border: 1px solid var(--sb-green-pale); border-radius: var(--sb-radius); padding: 1.4rem 1.4rem 1.2rem; display: flex; flex-direction: column; justify-content: space-between; gap: 1rem; }
.review blockquote { margin: 0; font-size: 1.02rem; line-height: 1.55; color: var(--sb-ink); }
.review blockquote::before { content: "“"; display: block; font: 700 2.4rem/0.8 var(--sb-font-display); color: var(--sb-green); margin-bottom: 0.35rem; }
.review figcaption b { display: block; color: var(--sb-ink); }
.review figcaption span { font-size: 0.88rem; color: var(--sb-ink-muted); }
/* One row of 3 (1 on phones); the arrow pages to the next set, dots show which set */
.reviews-carousel { position: relative; padding-right: 3.25rem; text-align: left; }
.reviews-track { display: grid; grid-auto-flow: column; grid-auto-columns: calc((100% - 2rem) / 3); column-gap: 1rem; overflow-x: auto; scroll-snap-type: x mandatory; scrollbar-width: none; overscroll-behavior-x: contain; }
.reviews-track::-webkit-scrollbar { display: none; }
.reviews-track .review { scroll-snap-align: start; }
.reviews-next { position: absolute; right: 0; top: calc(50% - 1.6rem); width: 2.5rem; height: 2.5rem; border-radius: 50%; border: 1.5px solid var(--sb-green-pale); background: #fff; color: var(--sb-green-dark); display: grid; place-items: center; cursor: pointer; transition: background 0.15s, border-color 0.15s; }
.reviews-next:hover { background: var(--sb-cream); border-color: var(--sb-green-light); }
.reviews-next:focus-visible { outline: 2px solid var(--sb-green-dark); outline-offset: 2px; }
.reviews-dots { display: flex; justify-content: center; gap: 0.4rem; margin-top: 1rem; }
.reviews-dots span { width: 6px; height: 6px; border-radius: 50%; background: var(--sb-green-pale); transition: background 0.2s, width 0.2s; }
.reviews-dots span.is-active { background: var(--sb-green-dark); width: 16px; border-radius: 3px; }
.reviews-carousel.is-single { padding-right: 0; }
.reviews-carousel.is-single .reviews-next, .reviews-carousel.is-single .reviews-dots { display: none; }
@media (max-width: 768px) {
  .reviews-section { padding-left: 1rem; padding-right: 1rem; }
  .reviews-track { grid-auto-columns: 100%; }
  .reviews-carousel { padding-right: 2.9rem; }
  .reviews-next { width: 2.25rem; height: 2.25rem; }
}
.trusted-by { margin-top: 2.5rem; }
.trusted-by p { font-size: 0.8rem; font-weight: 700; text-transform: uppercase; letter-spacing: 0.08em; color: #5d665b; margin-bottom: 1rem; }
.trusted-by__logos { display: flex; flex-wrap: wrap; justify-content: center; gap: 1rem 2.5rem; }
.logo-slot { width: 120px; height: 44px; border-radius: 10px; border: 1.5px dashed var(--sb-grey); display: grid; place-items: center; color: var(--sb-grey); font-size: 0.8rem; font-weight: 600; }

/* ---------- Screenshot placeholders ---------- */
.phone-placeholder { aspect-ratio: 1036 / 2143; min-height: 0; border-radius: 36px; border-color: var(--sb-green); color: var(--sb-green-dark); background: rgba(214, 236, 219, 0.5); }

.section-link { margin-top: 1rem; }
.section-link a { color: var(--sb-green-dark); font-weight: 700; text-decoration: underline; text-underline-offset: 3px; }

/* ---------- Who it's for ---------- */
.audience-section { max-width: 1000px; margin: 0 auto; padding: clamp(2.5rem, 1rem + 4vw, 4.5rem) 2rem; }
.audience-section h2 { color: var(--sb-ink); margin-bottom: 1.5rem; }
.audience-list { list-style: none; padding: 0; margin: 0; border-top: 1px solid var(--sb-green-pale); }
.audience-list li { border-bottom: 1px solid var(--sb-green-pale); }
.audience-list a { display: grid; grid-template-columns: minmax(200px, 0.9fr) 1.6fr auto; gap: 1rem; align-items: center; padding: 1.1rem 0.25rem; color: var(--sb-ink); }
.audience-list a::after { content: "→"; color: var(--sb-green-dark); font-weight: 700; transition: transform 0.15s ease; }
.audience-list a:hover::after { transform: translateX(4px); }
.audience-list b { font: 700 1.1rem var(--sb-font-display); letter-spacing: -0.01em; }
.audience-list span { color: var(--sb-ink-muted); }
@media (max-width: 768px) {
  .audience-section { padding-left: 0; padding-right: 0; }
  .audience-list a { grid-template-columns: 1fr auto; row-gap: 0.15rem; }
  .audience-list span { grid-column: 1; grid-row: 2; font-size: 0.95rem; }
  .audience-list a::after { grid-column: 2; grid-row: 1 / span 2; }
}

/* ---------- PDF section ---------- */
.pdf-section { max-width: 1000px; margin: 0 auto; display: flex; gap: 2.5rem; align-items: center; padding: clamp(2.5rem, 1rem + 4vw, 4.5rem) 2rem; }
.pdf-text { flex: 0 0 40%; }
.pdf-image { flex: 1; }
.pdf-image img { width: 100%; height: auto; }
.pdf-versions { display: flex; flex-wrap: wrap; gap: 0.5rem; margin-top: 1rem; }
.pdf-versions span { padding: 0.3rem 0.8rem; border-radius: 999px; background: var(--sb-green-pale); color: var(--sb-green-dark); font-size: 0.85rem; font-weight: 700; }
@media (max-width: 768px) { .pdf-section { flex-direction: column; padding-left: 0; padding-right: 0; } }

/* ---------- Pricing band ---------- */
.pricing-band { max-width: 1000px; margin: clamp(2rem, 1rem + 3vw, 3.5rem) auto 0; display: flex; gap: 2rem; align-items: center; justify-content: space-between; padding: 2rem 2.25rem; border-radius: var(--sb-radius); background: var(--sb-green-pale); }
.pricing-band h2 { font-size: clamp(1.4rem, 1.1rem + 1vw, 1.75rem); color: var(--sb-ink); margin-bottom: 0.5rem; }
.pricing-band p { color: var(--sb-ink-muted); max-width: 56ch; }
.pricing-band__btn { flex-shrink: 0; display: inline-flex; align-items: center; min-height: 52px; padding: 0 1.5rem; border-radius: var(--sb-radius); background: var(--sb-green-dark); color: #fff; font-weight: 700; }
.pricing-band__btn:hover { background: var(--sb-green-deep); }
@media (max-width: 768px) { .pricing-band { flex-direction: column; align-items: flex-start; padding: 1.5rem; } }

/* Sections that style.css colours white but sit on white backgrounds */
.equipment-types, .record-exporting, .product-registry { color: var(--sb-ink); }

/* Secondary CTA under a section (e.g. sample report) */
.section-cta { margin-top: 1.5rem; }

/* Footer: four link columns on desktop */
@media (min-width: 769px) {
  .footer-columns nav { grid-template-columns: repeat(4, minmax(120px, 1fr)); width: min(780px, 100%); }
}

/* Trusted-by logos: greyscale files, kept small and calm */
.trusted-by__logos { align-items: center; }
.trusted-by__logos img { height: 44px; width: auto; max-width: 150px; object-fit: contain; opacity: 0.8; }
@media (max-width: 768px) { .trusted-by__logos { gap: 1.25rem 2rem; } .trusted-by__logos img { height: 36px; max-width: 120px; } }

/* Stats: 4 columns on desktop; a slow, continuous one-line ticker on phones */
.stats-track { display: contents; }
.stats-dup { display: none; }
@media (max-width: 768px) {
  .stats-strip { display: block; overflow: hidden; padding: 1.25rem 0; -webkit-mask-image: linear-gradient(90deg, transparent, #000 8%, #000 92%, transparent); mask-image: linear-gradient(90deg, transparent, #000 8%, #000 92%, transparent); }
  .stats-track { display: flex; width: max-content; animation: sb-stats-ticker 28s linear infinite; }
  .stats-track > div { flex: 0 0 auto; padding: 0 1.75rem; white-space: nowrap; }
  .stats-dup { display: block; }
  @media (prefers-reduced-motion: reduce) {
    .stats-strip { overflow-x: auto; }
    .stats-track { animation: none; }
    .stats-dup { display: none; }
  }
}
@keyframes sb-stats-ticker { from { transform: translateX(0); } to { transform: translateX(-50%); } }

/* Logos stay on one line on phones */
@media (max-width: 768px) {
  .trusted-by__logos { flex-wrap: nowrap; gap: 0 1.1rem; padding: 0 0.5rem; }
  .trusted-by__logos img { height: auto; max-height: 34px; max-width: 22%; min-width: 0; flex: 0 1 auto; }
}

/* Hero phones sit a little closer together */
.hero-images .back { left: 32%; }
@media (max-width: 768px) {
  .hero-images .back { left: 33%; }
  /* Centre the download badges on phones */
  .smart-dl { justify-content: center; align-self: center; width: 100%; }
}

/* Larger trusted-by logos */
.trusted-by__logos img { height: 64px; max-width: 210px; }
@media (max-width: 768px) {
  .trusted-by__logos { gap: 0 0.9rem; }
  .trusted-by__logos img { height: auto; max-height: 52px; max-width: 24%; }
}

/* Phones: both store badges sit side by side and shrink together to fit */
@media (max-width: 768px) {
  .smart-dl, main .aud-midcta .smart-dl { flex-wrap: nowrap; gap: 0.6rem; width: 100%; }
  .smart-dl__store { min-width: 0; }
  .smart-dl__ios { flex: 0 1 160px; }
  .smart-dl__android { flex: 0 1 176px; }
  .smart-dl__store img, main .smart-dl__store img { width: 100%; height: auto; }
}
@media (max-width: 480px) {
  .home-cta { padding: 1.5rem 0.75rem !important; }
  .home-cta__box { padding: 2.5rem 1.25rem !important; }
}

.logo-image { width: auto; }
