/* ==========================================================================
   site.css — Greenburst Lawns, built from the house shell plus the approved
   brief's ring-count archetype (runs/greenburst-lawns-salina-ks/brief.md §3).

   HARD RULE (house-tech-spec §3): no raw hex, no px/rem size literals, no
   font-name literals in this file. Tokens only. The two escape hatches are
   the house breakpoints and an explicit `@allow-literal: reason` comment.
   ========================================================================== */

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

.container {
  width: 100%;
  max-width: var(--layout-container);
  margin-inline: auto;
  padding-inline: var(--layout-gutter);
}

/* Wide composed sections (brief §3.4): Hero, The Ring Count, Contact/Footer.
   Max-width 1440px, padding-inline scales up at the two stated breakpoints. */
.container--wide {
  max-width: var(--layout-container-wide);
}

@media (min-width: 48em) {
  .container--wide { padding-inline: var(--layout-gutter-md); }
}

@media (min-width: 64em) {
  .container--wide { padding-inline: var(--layout-gutter-lg); }
}

/* Centred narrower sections (brief §3.4): Services Detail, About. */
.container--md {
  max-width: var(--layout-container-md);
}

.section {
  padding-block: var(--section-gap);
}

.measure {
  max-width: var(--layout-measure);
}

/* --- Header & navigation ---------------------------------------------------
   Progressive enhancement: with JS off the nav list is a plain, always-visible
   list of links and the toggle stays [hidden]. With JS on, narrow viewports
   collapse the list behind the toggle.                                     */

.site-header {
  position: sticky;
  inset-block-start: 0;
  z-index: var(--z-header);
  padding-block: var(--space-sm);
  border-bottom: var(--border-hairline) var(--border-style) var(--color-border);
  background-color: var(--color-bg);
}

.site-header__inner {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-sm);
}

/* Overrides the house default (--text-h3, a token this brief does not
   define — no h3-level heading exists anywhere on this site). Reuses
   --text-lead, already part of the brief's own declared scale. */
.site-header__brand {
  font-family: var(--font-display);
  font-size: var(--text-lead);
  font-weight: var(--font-weight-display);
  color: var(--color-ink);
  text-decoration: none;
  letter-spacing: var(--tracking-tight);
}

.nav-toggle {
  display: inline-flex;
  align-items: center;
  gap: var(--space-2xs);
  padding: var(--space-2xs) var(--space-xs);
  border: var(--border-hairline) var(--border-style) var(--color-border-strong);
  border-radius: var(--radius-sm);
  font-size: var(--text-small);
  font-weight: var(--font-weight-body-strong);
}

.site-nav__list {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: var(--space-sm);
  margin: 0;
  padding: 0;
  list-style: none;
}

.site-nav__link {
  display: inline-flex;
  align-items: center;
  text-decoration: none;
  font-size: var(--text-small);
  font-weight: var(--font-weight-body-strong);
  color: var(--color-ink);
}

.site-nav__link:hover,
.site-nav__link:focus-visible {
  text-decoration: underline;
  text-underline-offset: var(--space-3xs);
}

.site-nav {
  display: none;
}

[data-nav-ready] .site-nav[data-nav-open='true'] {
  display: block;
  flex-basis: 100%;
}

@media (min-width: 48em) {
  .site-nav {
    display: block;
  }

  [data-nav-ready] .nav-toggle {
    display: none;
  }
}

/* --- Buttons ----------------------------------------------------------------
   Sign-paint register (ref-010, tile-a.html's approved hero device): the
   primary CTA carries the 700 weight, uppercase, tracked-out treatment.    */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: var(--space-2xs);
  padding: var(--space-xs) var(--space-md);
  border: var(--border-hairline) var(--border-style) transparent;
  border-radius: var(--radius-sm);
  font-weight: var(--font-weight-body-strong);
  line-height: var(--leading-snug);
  text-align: center;
  text-decoration: none;
  transition: background-color var(--duration-fast) var(--ease-out),
              color var(--duration-fast) var(--ease-out);
}

.btn--primary {
  background-color: var(--color-accent);
  color: var(--color-accent-ink);
  font-weight: var(--font-weight-body-bold);
  text-transform: uppercase;
  letter-spacing: var(--tracking-wide);
}

.btn--quiet {
  border-color: var(--color-border-strong);
  color: var(--color-ink);
}

.btn--buy {
  /* preview.css supplies colour/geometry; no overrides needed here. */
}

/* --- Shared section label (eyebrow) ---------------------------------------- */

.eyebrow {
  margin: 0 0 var(--space-xs) 0;
  font-family: var(--font-body);
  font-weight: var(--font-weight-body-bold);
  font-size: var(--text-eyebrow);
  letter-spacing: var(--tracking-wide);
  text-transform: uppercase;
  color: var(--color-accent);
}

main h2 {
  margin: 0 0 var(--space-md) 0;
  color: var(--color-ink);
}

/* --- Two-stroke ring mark (brief §6 recurring ornament) --------------------
   One device, two sizes: full beside every Ring Count row, shrunk at the
   head of each Services Detail column. Static — no animation — the
   signature move lives only in the hero.                                   */

.ringmark {
  flex-shrink: 0;
  width: var(--ringmark-size);
  height: var(--ringmark-size);
  color: var(--color-ink);
}

.ringmark--sm {
  width: var(--ringmark-size-sm);
  height: var(--ringmark-size-sm);
  margin-block-end: var(--space-2xs);
}

.ringmark__inner {
  color: var(--color-accent);
}

/* ============================================================================
   HERO — living-hero signature move ("the ring settles").
   ========================================================================== */

.hero {
  position: relative;
  overflow: hidden;
  padding-block-start: var(--hero-top-pad);
  padding-block-end: var(--section-gap);
  background: radial-gradient(ellipse at 30% 20%,
    var(--color-bg-radial-light) 0%, var(--color-bg) 55%, var(--color-bg-radial-dark) 100%);
}

.hero__grid {
  display: grid;
  grid-template-areas: "head" "field" "below";
  grid-template-columns: 1fr;
  row-gap: var(--space-lg);
}

.hero__head {
  grid-area: head;
}

.hero__field {
  grid-area: field;
  position: relative;
  max-width: var(--hero-field-max-mobile);
  margin-inline: auto;
}

.hero__below {
  grid-area: below;
}

@media (min-width: 48em) {
  .hero__grid {
    grid-template-areas: "head field" "below field";
    grid-template-columns: var(--col-hero-text) 1fr;
    column-gap: var(--space-xl);
    row-gap: var(--space-md);
    align-items: center;
  }

  .hero__head,
  .hero__below {
    max-width: var(--col-hero-text);
  }

  .hero__field {
    max-width: var(--hero-field-max);
    margin-inline-start: auto;
    margin-inline-end: 0;
  }
}

.hero__kicker {
  display: flex;
  align-items: center;
  gap: var(--space-2xs);
  margin-block-end: var(--hero-gap-sm);
}

.hero__rule {
  display: inline-block;
  width: var(--space-lg);
  height: var(--border-thick);
  background-color: var(--color-accent);
}

.hero__rule-caption {
  font-family: var(--font-body);
  font-weight: var(--font-weight-body-bold);
  font-size: var(--text-small);
  letter-spacing: var(--tracking-wide);
  text-transform: uppercase;
  color: var(--color-accent);
}

.hero__eyebrow {
  margin: 0 0 var(--hero-gap-sm) 0;
  font-family: var(--font-body);
  font-weight: var(--font-weight-body-bold);
  font-size: var(--text-eyebrow);
  letter-spacing: var(--tracking-wide);
  text-transform: uppercase;
  color: var(--color-accent);
}

.hero__h1 {
  margin: 0 0 var(--hero-gap-md) 0;
  font-size: var(--text-h1);
  line-height: var(--leading-tight);
  color: var(--color-ink);
}

.hero__cta {
  margin: 0;
}

.hero__lead {
  margin: 0 0 var(--space-sm) 0;
  font-size: var(--text-lead);
  color: var(--color-ink-muted);
}

.hero__facts {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-sm) var(--space-md);
  margin: 0;
  padding: 0;
  list-style: none;
  font-size: var(--text-small);
  font-weight: var(--font-weight-body-bold);
  color: var(--color-ink);
}

.hero__facts li {
  border-block-end: var(--border-thick) var(--border-style) var(--color-accent-decorative);
  padding-block-end: var(--space-3xs);
}

.hero__field picture,
.hero__field img {
  display: block;
  width: 100%;
  height: auto;
  border-radius: var(--radius-sm);
}

/* Decorative overlays, independent of the photo's own pixels (ref-001's
   satellite-float physics, adapted — brief §1, §4). Absolutely positioned
   within the field box so they read as "near" the log/turf without needing
   to pixel-align with the generated artwork. */
.hero__rings {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
}

.hero__ring {
  fill: none;
  stroke: var(--color-ink);
  stroke-width: 2;
  opacity: 0.55;
}

.hero__ring--outer {
  stroke: var(--color-accent);
  stroke-width: 3;
  animation: hero-ring-settle var(--duration-ring-settle) var(--ease-out) 1 both;
}

@keyframes hero-ring-settle {
  0%   { opacity: 0; r: 45; }
  100% { opacity: 1; r: 60; }
}

.hero__mote {
  position: absolute;
  color: var(--color-accent-decorative);
  pointer-events: none;
}

.hero__mote circle {
  fill: currentColor;
}

.hero__mote--1 {
  inset-block-start: 62%;
  inset-inline-start: 20%;
  width: var(--space-sm);
  height: var(--space-sm);
  animation: hero-mote-float-a var(--duration-mote-1) var(--ease-in-out) infinite;
}

.hero__mote--2 {
  inset-block-start: 71%;
  inset-inline-start: 74%;
  width: var(--space-xs);
  height: var(--space-xs);
  animation: hero-mote-float-b var(--duration-mote-2) var(--ease-in-out) infinite;
}

.hero__mote--3 {
  inset-block-start: 57%;
  inset-inline-start: 54%;
  width: var(--space-xs);
  height: var(--space-xs);
  animation: hero-mote-float-c var(--duration-mote-3) var(--ease-in-out) infinite;
}

@keyframes hero-mote-float-a {
  0%, 100% { transform: translate(0, 0); }
  50%      { transform: translate(var(--mote-drift-1-x), var(--mote-drift-1-y)); }
}

@keyframes hero-mote-float-b {
  0%, 100% { transform: translate(0, 0); }
  50%      { transform: translate(var(--mote-drift-2-x), var(--mote-drift-2-y)); }
}

@keyframes hero-mote-float-c {
  0%, 100% { transform: translate(0, 0); }
  50%      { transform: translate(var(--mote-drift-3-x), var(--mote-drift-3-y)); }
}

/* Reduced motion (brief §4): the ring resolves instantly to its final state;
   the motes freeze. No exceptions (house-tech-spec §8). */
@media (prefers-reduced-motion: reduce) {
  .hero__ring--outer {
    animation: none;
    opacity: 1;
    r: 60;
  }

  .hero__mote--1,
  .hero__mote--2,
  .hero__mote--3 {
    animation: none;
  }
}

/* ============================================================================
   THE RING COUNT — substitutes for trust-strip/reviews.
   ========================================================================== */

.ringcount {
  background-color: var(--color-bg);
}

.ringcount__grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--space-lg);
}

@media (min-width: 48em) {
  .ringcount__grid {
    grid-template-columns: var(--col-ringcount-intro) 1fr;
    column-gap: var(--space-2xl);
    align-items: start;
  }
}

.ringcount__dek {
  color: var(--color-ink-muted);
}

.ringcount__list {
  margin: 0;
  padding: 0;
  list-style: none;
}

.ringcount__row {
  display: flex;
  align-items: flex-start;
  gap: var(--space-sm);
  padding-block: var(--space-md);
  border-block-start: var(--border-hairline) var(--border-style) var(--color-border);
}

.ringcount__row:first-child {
  border-block-start: var(--border-thick) var(--border-style) var(--color-ink);
}

.ringcount__label {
  margin: 0 0 var(--space-3xs) 0;
  font-family: var(--font-body);
  font-weight: var(--font-weight-body-bold);
  font-size: var(--text-body);
  color: var(--color-ink);
}

.ringcount__row-body p:last-child {
  margin: 0;
  max-width: var(--measure-row);
  color: var(--color-ink-muted);
}

/* ============================================================================
   SERVICES DETAIL — the Ring Count in full, three columns.
   ========================================================================== */

.services__standfirst {
  margin: var(--space-sm) 0 var(--space-xl) 0;
  color: var(--color-ink-muted);
}

.services__grid {
  margin: 0;
  padding: 0;
  list-style: none;
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--space-xl);
}

@media (min-width: 48em) {
  .services__grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: var(--grid-gap-services);
    align-items: start;
  }
}

.services__col {
  display: flex;
  flex-direction: column;
}

.services__col picture {
  margin-block-end: var(--space-2xs);
}

.services__col img {
  width: 100%;
  height: auto;
  aspect-ratio: 7 / 5;
  object-fit: cover;
  border-radius: var(--radius-sm);
}

.services__col-subhead {
  margin: var(--space-2xs) 0 var(--space-3xs) 0;
  font-family: var(--font-body);
  font-weight: var(--font-weight-body-bold);
  font-size: var(--text-body);
  color: var(--color-ink);
}

.services__col p:last-child {
  margin: 0;
  color: var(--color-ink-muted);
}

/* ============================================================================
   ABOUT / OUR STORY
   ========================================================================== */

.about__grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--space-lg);
}

@media (min-width: 48em) {
  .about__grid {
    grid-template-columns: var(--col-about-text) 1fr;
    gap: var(--grid-gap-about);
    align-items: center;
  }
}

.about__media img {
  width: 100%;
  height: auto;
  max-width: var(--about-image-w);
  aspect-ratio: 14 / 9;
  object-fit: cover;
  border-radius: var(--radius-sm);
}

@media (min-width: 48em) {
  .about__media img {
    margin-inline-start: auto;
  }
}

/* ============================================================================
   SERVICE AREA — deliberately thin, single centred column (PATTERNS.md P1).
   ========================================================================== */

.service-area {
  background-color: var(--color-surface);
}

.service-area__container {
  max-width: var(--measure-narrow);
  margin-inline: auto;
  color: var(--color-ink-muted);
}

.service-area__container h2 {
  color: var(--color-ink);
}

/* ============================================================================
   FAQ — single centred column (PATTERNS.md P1). No h3: question/answer pairs
   are styled body text.
   ========================================================================== */

.faq__container {
  max-width: var(--measure-wide);
  margin-inline: auto;
}

.faq__list {
  margin-block-start: var(--space-lg);
}

.faq__item {
  padding-block: var(--space-md);
  border-block-start: var(--border-hairline) var(--border-style) var(--color-border);
}

.faq__item:first-child {
  border-block-start: var(--border-thick) var(--border-style) var(--color-ink);
}

.faq__question {
  margin: 0 0 var(--space-2xs) 0;
  font-weight: var(--font-weight-body-strong);
  color: var(--color-ink);
}

.faq__answer {
  margin: 0;
  color: var(--color-ink-muted);
}

/* ============================================================================
   CONTACT — the house form. Desktop composition realises brief §3.4's
   "NAP / Hours / Form" three columns from this section's own three pieces.
   ========================================================================== */

.contact {
  background-color: var(--color-surface);
}

.contact__grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--space-lg);
}

@media (min-width: 48em) {
  .contact__grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
    column-gap: var(--grid-gap-contact);
    row-gap: var(--space-lg);
    align-items: start;
  }

  .contact__intro,
  .contact__hours,
  .form {
    max-width: var(--col-contact);
  }
}

.contact__hours {
  margin: 0;
  font-size: var(--text-small);
  color: var(--color-ink-muted);
}

/* --- Form -----------------------------------------------------------------
   One form per site (spec §6). POSTs to the endpoint constant in main.js;
   works as a plain HTML POST with JS off.                                  */

.form {
  display: grid;
  gap: var(--space-md);
  max-width: var(--layout-measure);
}

.field {
  display: grid;
  gap: var(--space-3xs);
}

.field__label {
  font-size: var(--text-small);
  font-weight: var(--font-weight-body-strong);
  color: var(--color-ink);
}

.field__control {
  width: 100%;
  min-height: var(--layout-tap-min);
  padding: var(--space-2xs) var(--space-xs);
  background-color: var(--color-bg);
  color: var(--color-ink);
  border: var(--border-hairline) var(--border-style) var(--color-border-strong);
  border-radius: var(--radius-sm);
}

textarea.field__control {
  min-height: var(--space-3xl);
  resize: vertical;
}

.field__hint {
  font-size: var(--text-small);
  color: var(--color-ink-muted);
}

.form__trap {
  position: absolute;
  /* @allow-literal: off-canvas parking position, not a design value */
  left: -9999px;
  opacity: 0;
  pointer-events: none;
}

.form__status {
  font-size: var(--text-small);
  color: var(--color-ink-muted);
}

.form__status[data-state='error'] {
  color: var(--color-ink);
  font-weight: var(--font-weight-body-strong);
}

/* --- Footer -----------------------------------------------------------------
   Desktop composition (brief §3.4): NAP / Hours / Rights, three columns,
   same gap figure as the Contact section above.                           */

.site-footer {
  padding-block: var(--space-xl);
  border-top: var(--border-hairline) var(--border-style) var(--color-border);
  font-size: var(--text-small);
  background-color: var(--color-surface);
}

.site-footer a {
  text-underline-offset: var(--space-3xs);
}

.site-footer__nap {
  font-style: normal;
}

.site-footer__grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--space-md);
}

@media (min-width: 48em) {
  .site-footer__grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
    column-gap: var(--grid-gap-contact);
    align-items: start;
  }
}
