/* ---------------------------------------------------------------
   Kiko Enterprises — Queenstown Diesel Delivery
   Brand palette carried over from the Webflow build; the scale,
   surfaces and contrast-safe variants are defined here.
--------------------------------------------------------------- */

:root {
  /* Brand. --flame is the identity orange and is used for borders,
     glows and accents. It is NOT contrast-safe behind white text
     (3.33:1 on white), so anything carrying white copy uses --flame-ink
     (4.76:1) and anything set as small orange text uses --flame-text. */
  --flame:        #ff4c1a;
  --flame-ink:    #d13e15;
  --flame-deep:   #b8330f;
  --flame-text:   #c4380f;
  --flame-lift:   #ff804a;

  /* Display gradient — both stops clear 3:1 on white for large text. */
  --grad-from:    #e03100;
  --grad-to:      #f2591c;

  /* Neutrals */
  --ink:          #12100f;
  --ink-2:        #55504d;
  --ink-3:        #736c67;
  --paper:        #fff;
  --surface:      #fdf8f5;
  --surface-2:    #fbf1eb;
  --line:         #ece3dd;
  --line-strong:  #ddd0c7;

  /* Elevation — the glow belongs to the primary CTA and nothing else. */
  --glow:         0 6px 16px -6px rgba(184, 51, 15, .45), 0 0 0 1px rgba(184, 51, 15, .08);
  --glow-hover:   0 10px 24px -8px rgba(184, 51, 15, .6),  0 0 0 1px rgba(184, 51, 15, .12);
  --shadow-card:  0 1px 2px rgba(18, 16, 15, .04), 0 8px 24px -18px rgba(18, 16, 15, .28);

  --radius:       12px;
  --radius-lg:    16px;
  --radius-pill:  100px;

  /* Fluid spacing */
  --gap-xs:  .5rem;
  --gap-s:   .875rem;
  --gap-m:   1.5rem;
  --gap-l:   2.25rem;
  --gap-xl:  clamp(3rem, 7vw, 5.5rem);

  --measure:  60ch;
  --shell:    1140px;

  --font: system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto,
          Oxygen, Ubuntu, Cantarell, "Fira Sans", "Droid Sans",
          "Helvetica Neue", sans-serif;
}

*, *::before, *::after { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }

body {
  margin: 0;
  background-color: var(--paper);
  color: var(--ink);
  font-family: var(--font);
  font-size: 1rem;
  font-weight: 500;
  line-height: 1.2;
  text-transform: capitalize;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

img { max-width: 100%; display: block; }

::selection { background: var(--flame); color: #fff; }

/* Every interactive element gets the same visible, contrast-safe ring. */
a:focus-visible,
summary:focus-visible,
.skip:focus-visible {
  outline: 3px solid var(--flame-ink);
  outline-offset: 3px;
  border-radius: 4px;
}
summary:focus:not(:focus-visible) { outline: none; }

.skip {
  position: absolute;
  left: 50%;
  top: 0;
  z-index: 100;
  padding: .75rem 1.25rem;
  border-radius: 0 0 var(--radius) var(--radius);
  background: var(--flame-ink);
  color: #fff;
  font-weight: 600;
  text-decoration: none;
  transform: translate(-50%, -110%);
  transition: transform .18s ease;
}
.skip:focus { transform: translate(-50%, 0); }

/* --- Type ---------------------------------------------------- */

.h1 {
  margin: 0;
  font-size: clamp(2rem, 1.3rem + 3.1vw, 3.5rem);
  font-weight: 700;
  line-height: 1.08;
  letter-spacing: -.025em;
  text-align: center;
  text-transform: capitalize;
  text-wrap: balance;
}

.h1--hero {
  max-width: 21ch;
  font-size: clamp(2.25rem, 1.35rem + 4vw, 4.25rem);
}

.h1--narrow { max-width: 24ch; }

.h1--orange {
  background-image: linear-gradient(102deg, var(--grad-from), var(--grad-to));
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  color: var(--grad-from);
}

/* The orange clause is the second half of a two-line lockup in both
   display headings; it stays inline in the short closing heading. */
.h1--hero .h1--orange,
.h1--narrow .h1--orange { display: block; }

.body-text {
  max-width: var(--measure);
  margin: 0;
  color: var(--ink-2);
  font-size: clamp(1rem, .95rem + .25vw, 1.125rem);
  font-weight: 500;
  line-height: 1.5;
  text-align: center;
  text-transform: capitalize;
  text-wrap: pretty;
}

/* The hero sub-line is the second thing read on the page — it is sized
   as a lede, not as fine print (it was 14px in the Webflow build). */
.lede {
  max-width: 48ch;
  margin: 0;
  color: var(--ink-2);
  font-size: clamp(1.0625rem, 1rem + .4vw, 1.3125rem);
  font-weight: 500;
  line-height: 1.45;
  text-align: center;
  text-transform: capitalize;
  text-wrap: balance;
}

.text-s {
  margin: 0;
  color: var(--ink-2);
  font-size: .9375rem;
  font-weight: 500;
  line-height: 1.5;
  text-transform: capitalize;
}

.text-s--lower { text-transform: lowercase; }

.tag {
  margin: 0;
  padding: .5rem 1.125rem;
  border: 1px solid var(--line-strong);
  border-radius: var(--radius-pill);
  background: var(--paper);
  color: var(--flame-text);
  font-size: .75rem;
  font-weight: 700;
  letter-spacing: .11em;
  text-transform: uppercase;
}

.pill {
  margin: 0;
  padding: .5rem 1.125rem;
  border: 1px solid var(--line-strong);
  border-radius: var(--radius-pill);
  font-size: .8125rem;
  font-weight: 600;
}

/* --- Button -------------------------------------------------- */

.btn {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  padding: 15px 34px;
  border-radius: var(--radius);
  /* Both stops clear 4.5:1 against white label text. */
  background-image: linear-gradient(168deg, var(--flame-ink), var(--flame-deep));
  background-color: var(--flame-ink);
  color: var(--paper);
  font-size: 1rem;
  font-weight: 600;
  letter-spacing: -.005em;
  text-decoration: none;
  white-space: nowrap;
  box-shadow: var(--glow);
  transition: transform .18s ease, box-shadow .18s ease, filter .18s ease;
}

.btn--glow { box-shadow: var(--glow); }

.btn:hover {
  transform: translateY(-2px);
  box-shadow: var(--glow-hover);
  filter: saturate(1.08);
}
.btn:active { transform: translateY(0); box-shadow: var(--glow); }

.btn:focus-visible {
  outline: 3px solid var(--flame-ink);
  outline-offset: 3px;
}

.btn__arrow {
  width: 26px;
  height: 15px;
  object-fit: scale-down;
  transition: transform .18s ease;
}
.btn:hover .btn__arrow { transform: translateX(3px); }

.btn--lg { padding: 17px 40px; font-size: 1.0625rem; }

/* --- Nav ----------------------------------------------------- */

.nav {
  position: sticky;
  top: 0;
  z-index: 20;
  display: flex;
  justify-content: center;
  padding: 12px 0;
  background-color: rgba(255, 255, 255, .82);
  -webkit-backdrop-filter: saturate(180%) blur(14px);
  backdrop-filter: saturate(180%) blur(14px);
  border-bottom: 1px solid transparent;
  transition: border-color .25s ease, box-shadow .25s ease, background-color .25s ease;
}

/* Set by script.js once the page is scrolled, so the bar separates from
   the content passing underneath it instead of floating invisibly. */
.nav.is-stuck {
  border-bottom-color: var(--line);
  box-shadow: 0 1px 20px -8px rgba(18, 16, 15, .22);
}

@supports not ((backdrop-filter: blur(1px)) or (-webkit-backdrop-filter: blur(1px))) {
  .nav { background-color: var(--paper); }
}

.nav__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  width: 100%;
  max-width: var(--shell);
  padding: 0 clamp(1rem, 3vw, 2rem);
}

.nav__brand {
  display: block;
  border-radius: 6px;
  line-height: 0;
}

.nav__brand img { width: 84px; height: auto; }

.nav .btn { padding: 12px 26px; font-size: .9375rem; }

/* --- Layout -------------------------------------------------- */

.section {
  display: flex;
  flex-direction: column;
  align-items: center;
  width: 100%;
}

/* Warm band that separates the middle of the page from the two
   white CTA moments above and below it. */
.section--tint {
  background-color: var(--surface);
  border-block: 1px solid var(--line);
}

.wrap {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: var(--gap-m);
  width: 100%;
  max-width: var(--shell);
  padding: var(--gap-xl) clamp(1rem, 3vw, 2rem);
}

.wrap--med { max-width: 980px; }

.wrap--hero {
  position: relative;
  gap: clamp(1.5rem, 3vw, 2rem);
  padding-top: clamp(3.5rem, 9vw, 7rem);
  padding-bottom: clamp(3.5rem, 9vw, 7rem);
}

/* Ambient flame wash behind the hero — the only large use of the
   identity orange, and it sits behind nothing but background. */
.section--hero {
  position: relative;
  isolation: isolate;
  overflow: hidden;
}

/* Both radii stop short of the section's top edge so the wash fades out
   rather than being cut off against the nav. */
.section--hero::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  background:
    radial-gradient(72% 50% at 50% 52%, rgba(255, 76, 26, .15), transparent 72%),
    radial-gradient(44% 34% at 84% 38%, rgba(255, 128, 74, .13), transparent 74%);
  pointer-events: none;
}

.cta-group {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: var(--gap-m);
}

/* --- Trust row ----------------------------------------------- */

.trust {
  display: flex;
  align-items: center;
  gap: .75rem;
}

.trust__people {
  width: 104px;
  height: auto;
  flex: none;
}

.trust__meta {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 4px;
}

.trust__stars {
  width: 68px;
  height: auto;
  /* The source asset is a white star strip; this recolours it to the
     brand orange rather than inverting it to near-black. */
  filter: brightness(0) saturate(100%) invert(38%) sepia(72%)
          saturate(3200%) hue-rotate(357deg) brightness(92%) contrast(96%);
}

.trust .text-s {
  color: var(--ink-2);
  font-size: .875rem;
  font-weight: 600;
  line-height: 1.2;
}

/* --- Stats --------------------------------------------------- */

.stats {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: clamp(.75rem, 2vw, 1.25rem);
  width: 100%;
  max-width: 760px;
  margin-top: var(--gap-xs);
}

.stat {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: .625rem;
  padding: clamp(1.25rem, 3vw, 1.875rem) 1rem;
  border: 1px solid var(--line-strong);
  border-radius: var(--radius-lg);
  background: var(--paper);
  box-shadow: var(--shadow-card);
}

/* Eyebrow, not a second glowing pill — the CTA keeps the glow. */
.stat__label {
  margin: 0;
  color: var(--flame-text);
  font-size: .6875rem;
  font-weight: 700;
  letter-spacing: .12em;
  line-height: 1.2;
  text-align: center;
  text-transform: uppercase;
}

.stat__value {
  margin: 0;
  font-size: clamp(2.25rem, 1.5rem + 3vw, 3.25rem);
  font-weight: 700;
  letter-spacing: -.03em;
  line-height: 1;
  font-variant-numeric: tabular-nums;
}

/* --- Accordions ---------------------------------------------- */

.accordions {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: clamp(.75rem, 1.6vw, 1rem);
  width: 100%;
  align-items: start;
}

.accordion {
  border: 1px solid var(--line-strong);
  border-radius: var(--radius-lg);
  background: var(--paper);
  box-shadow: var(--shadow-card);
  transition: border-color .22s ease, box-shadow .22s ease;
}

.accordion:hover { border-color: var(--flame-lift); }

.accordion[open] {
  border-color: var(--flame);
  background: linear-gradient(180deg, var(--surface-2), var(--paper) 42%);
}

.accordion__trigger {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: clamp(1.125rem, 2.4vw, 1.5rem);
  border-radius: var(--radius-lg);
  cursor: pointer;
  list-style: none;
  -webkit-tap-highlight-color: transparent;
}

.accordion__trigger::-webkit-details-marker { display: none; }

.accordion__heading {
  flex: 1;
  margin: 0;
  color: var(--ink);
  font-size: clamp(1rem, .95rem + .3vw, 1.125rem);
  font-weight: 600;
  line-height: 1.35;
  letter-spacing: -.01em;
  text-align: left;
  text-transform: capitalize;
  text-wrap: pretty;
}

.accordion__icon {
  flex: none;
  width: 28px;
  height: 28px;
  padding: 5px;
  border: 1px solid var(--line-strong);
  border-radius: 50%;
  background: var(--surface);
  color: var(--flame-text);
  transition: transform .28s ease, background-color .22s ease,
              border-color .22s ease, color .22s ease;
}

.accordion__trigger:hover .accordion__icon {
  border-color: var(--flame);
  color: var(--flame-ink);
}

.accordion[open] .accordion__icon {
  transform: rotate(180deg);
  border-color: var(--flame);
  background: var(--flame-ink);
  color: #fff;
}

.accordion__content {
  padding: 0 clamp(1.125rem, 2.4vw, 1.5rem) clamp(1.125rem, 2.4vw, 1.5rem);
}

.accordion__content .text-s {
  max-width: 46ch;
  color: var(--ink-2);
  line-height: 1.6;
  text-align: left;
  text-wrap: pretty;
}

/* Smooth open/close where the engine supports animating to auto;
   elsewhere the panel simply snaps, as it did before. */
@supports (interpolate-size: allow-keywords) and selector(::details-content) {
  :root { interpolate-size: allow-keywords; }

  .accordion::details-content {
    height: 0;
    overflow: hidden;
    opacity: 0;
    transition: height .32s ease, opacity .28s ease, content-visibility .32s allow-discrete;
    content-visibility: hidden;
  }

  .accordion[open]::details-content {
    height: auto;
    opacity: 1;
    content-visibility: visible;
  }
}

/* --- Testimonials (hidden in the original build) -------------- */

.testimonials {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 1.25rem;
  width: 100%;
}

.testimonials img {
  width: 100%;
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
}

/* --- Footer -------------------------------------------------- */

.footer {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: clamp(2rem, 5vw, 3rem);
  width: 100%;
  padding: clamp(3rem, 7vw, 5rem) clamp(1rem, 3vw, 2rem) 0;
  border-top: 1px solid var(--line);
  background: var(--surface);
}

.footer__inner {
  display: grid;
  grid-template-columns: 1fr auto auto;
  align-items: start;
  gap: var(--gap-l) clamp(2.5rem, 7vw, 6rem);
  width: 100%;
  max-width: 960px;
}

.footer__logo { width: 104px; height: auto; }

.footer__cols {
  display: contents;
}

.footer__col {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: .75rem;
}

.footer__col > .text-s:first-child {
  color: var(--ink);
  font-size: .75rem;
  font-weight: 700;
  letter-spacing: .11em;
  text-transform: uppercase;
}
.footer__col > .text-s:first-child strong { font-weight: 700; }

.footer__link {
  color: var(--ink-2);
  text-decoration: none;
  transition: color .16s ease;
}

.footer__link:hover { color: var(--flame-text); }

.footer__copyright {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  max-width: 960px;
  padding: 1.25rem 0;
  border-top: 1px solid var(--line);
}

.footer__copyright .text-s {
  color: var(--ink-3);
  font-size: .8125rem;
  text-align: center;
}

/* --- Responsive ---------------------------------------------- */

@media screen and (max-width: 991px) {
  .footer__inner {
    grid-template-columns: auto auto;
    justify-content: center;
    justify-items: center;
    gap: var(--gap-l) clamp(2.5rem, 9vw, 4rem);
  }
  .footer__logo  { grid-column: 1 / -1; }
  .footer__col   { align-items: center; }
  .footer__link  { text-align: center; }
}

@media screen and (max-width: 767px) {
  .accordions  { grid-template-columns: 1fr; }
  .testimonials { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

@media screen and (max-width: 479px) {
  /* The gradient clip renders unevenly on small text on some mobile
     engines, so the orange clause falls back to a flat, AA-safe fill. */
  .h1--orange {
    background-image: none;
    -webkit-text-fill-color: currentColor;
    color: var(--grad-from);
  }

  .trust { gap: .625rem; }
  .trust__people { width: 92px; }

  /* Both stats stay visible — the Webflow build hid the second one,
     which left a single off-centre card. */
  .stats { gap: .625rem; }
  .stat  { padding: 1.125rem .625rem; gap: .5rem; }
  .stat__label { font-size: .625rem; letter-spacing: .08em; }
  .stat__value { font-size: clamp(1.75rem, 8vw, 2.25rem); }

  .testimonials { grid-template-columns: 1fr; }

  .footer__inner { grid-template-columns: 1fr; gap: var(--gap-m); }

  .nav__brand img { width: 68px; }
  .nav .btn { padding: 11px 20px; font-size: .875rem; }
  .btn { padding: 14px 26px; }
  .btn--lg { padding: 15px 30px; font-size: 1rem; }
}

@media (prefers-reduced-motion: reduce) {
  /* Motion is removed; colour and shadow fades are harmless and stay. */
  *, *::before, *::after {
    animation-duration: .001ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: .001ms !important;
    scroll-behavior: auto !important;
  }
  .btn:hover { transform: none; }
  .btn:hover .btn__arrow { transform: none; }
}

@media print {
  .nav, .skip, .btn__arrow { display: none; }
  .section--hero::before { display: none; }
  body { color: #000; }
  .accordion__content { display: block !important; }
}
