/* ==========================================================================
   Sam's Alaskan Lawn Service
   Design: topographic-map editorial layout. Deep spruce + fireweed magenta
   accent, midnight-sun gold used sparingly, mountain-horizon hero.
   ========================================================================== */

:root {
  /* --- palette (light) --- */
  --paper: #eef1e8;
  --paper-raised: #e3e9d7;
  --paper-raised-2: #d9e2cc;
  --ink: #142219;
  --ink-soft: #3c4b40;
  --spruce-700: #1f4d3a;
  --spruce-900: #0f2e21;
  --glacier-500: #386f86;
  --fireweed-500: #7d2c47;
  --fireweed-600: #66223a;
  --sun-400: #d99a2b;
  --cta-500: #2f6b45;
  --cta-600: #244f34;
  --line: rgba(15, 46, 33, 0.22);
  --shadow: rgba(15, 46, 33, 0.14);

  --font-display: Georgia, "Iowan Old Style", "Palatino Linotype", "Book Antiqua", serif;
  --font-body: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;

  --content-width: 1180px;
  --radius: 3px;
}

@media (prefers-color-scheme: dark) {
  :root {
    --paper: #101d17;
    --paper-raised: #17281f;
    --paper-raised-2: #1e3327;
    --ink: #eef1e8;
    --ink-soft: #b9c4b8;
    --spruce-700: #529372;
    --spruce-900: #cfe3d6;
    --glacier-500: #7fbcd4;
    --fireweed-500: #c97a94;
    --fireweed-600: #d68fa5;
    --sun-400: #eec06a;
    --cta-500: #3fa568;
    --cta-600: #52c17e;
    --line: rgba(238, 241, 232, 0.18);
    --shadow: rgba(0, 0, 0, 0.35);
  }
}

:root[data-theme="dark"] {
  --paper: #101d17;
  --paper-raised: #17281f;
  --paper-raised-2: #1e3327;
  --ink: #eef1e8;
  --ink-soft: #b9c4b8;
  --spruce-700: #529372;
  --spruce-900: #cfe3d6;
  --glacier-500: #7fbcd4;
  --fireweed-500: #c97a94;
  --fireweed-600: #d68fa5;
  --sun-400: #eec06a;
  --cta-500: #3fa568;
  --cta-600: #52c17e;
  --line: rgba(238, 241, 232, 0.18);
  --shadow: rgba(0, 0, 0, 0.35);
}

:root[data-theme="light"] {
  --paper: #eef1e8;
  --paper-raised: #e3e9d7;
  --paper-raised-2: #d9e2cc;
  --ink: #142219;
  --ink-soft: #3c4b40;
  --spruce-700: #1f4d3a;
  --spruce-900: #0f2e21;
  --glacier-500: #386f86;
  --fireweed-500: #7d2c47;
  --fireweed-600: #66223a;
  --sun-400: #d99a2b;
  --cta-500: #2f6b45;
  --cta-600: #244f34;
  --line: rgba(15, 46, 33, 0.22);
  --shadow: rgba(15, 46, 33, 0.14);
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  * { animation-duration: 0.001ms !important; animation-iteration-count: 1 !important; transition-duration: 0.001ms !important; }
}

body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--font-body);
  font-size: 1.0625rem;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

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

a { color: var(--glacier-500); }
a:focus-visible, button:focus-visible, input:focus-visible, textarea:focus-visible, select:focus-visible {
  outline: 2px solid var(--fireweed-500);
  outline-offset: 3px;
}

h1, h2, h3, h4 {
  font-family: var(--font-display);
  color: var(--ink);
  font-weight: 700;
  text-wrap: balance;
  margin: 0;
}

p { margin: 0; color: var(--ink-soft); }

.wrap {
  max-width: var(--content-width);
  margin: 0 auto;
  padding-inline: clamp(1.25rem, 4vw, 2.5rem);
}

.label {
  font-family: var(--font-body);
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--fireweed-500);
}

.section {
  padding-block: clamp(3.5rem, 7vw, 6rem);
}

.section-head {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  max-width: 640px;
  margin-bottom: clamp(2rem, 4vw, 3rem);
}

.section-head h2 { font-size: clamp(1.75rem, 3vw, 2.25rem); }
.section-head p { font-size: 1.0625rem; }

/* --- contour divider: layered wavy lines, like topo-map contours --- */
.contour {
  width: 100%;
  height: 34px;
  display: block;
  margin: 0;
}
.contour path { fill: none; stroke: var(--line); stroke-width: 1.5; }
.contour path.mid { stroke: var(--glacier-500); opacity: 0.45; }
.contour path.near { stroke: var(--fireweed-500); opacity: 0.35; }

/* ---------------------------------- header --------------------------------- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 40;
  background: color-mix(in srgb, var(--paper) 92%, transparent);
  backdrop-filter: blur(6px);
  border-bottom: 1px solid var(--line);
}
.site-header .wrap {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1.5rem;
  padding-block: 0.85rem;
}
.brand {
  display: flex;
  align-items: center;
  gap: 0.65rem;
  text-decoration: none;
  color: var(--ink);
}
.brand-mark { width: 34px; height: 34px; flex: none; }
.brand-text {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 1.15rem;
  line-height: 1.1;
}
.brand-text small {
  display: block;
  font-family: var(--font-body);
  font-weight: 600;
  font-size: 0.65rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--fireweed-500);
  margin-top: 0.15rem;
}

.main-nav { display: flex; align-items: center; gap: 1.75rem; }
.main-nav a {
  color: var(--ink-soft);
  text-decoration: none;
  font-size: 0.95rem;
  font-weight: 600;
}
.main-nav a:hover { color: var(--spruce-700); }

.nav-cta {
  display: flex;
  align-items: center;
  gap: 1rem;
}
.phone-link {
  color: var(--ink);
  font-weight: 700;
  text-decoration: none;
  font-variant-numeric: tabular-nums;
  font-size: 0.95rem;
  white-space: nowrap;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  padding: 0.75rem 1.4rem;
  border-radius: var(--radius);
  font-weight: 700;
  font-size: 0.95rem;
  text-decoration: none;
  border: 1px solid transparent;
  cursor: pointer;
  transition: transform 0.15s ease, background 0.15s ease, box-shadow 0.15s ease;
  font-family: var(--font-body);
}
.btn:hover { transform: translateY(-1px); }
.btn-primary {
  background: var(--cta-500);
  color: #fff;
  box-shadow: 0 2px 0 var(--cta-600);
}
.btn-primary:hover { background: var(--cta-600); }
.btn-ghost {
  background: transparent;
  border-color: var(--line);
  color: var(--ink);
}
.btn-ghost:hover { border-color: var(--spruce-700); color: var(--spruce-700); }
.btn-block { width: 100%; }

.nav-toggle {
  display: none;
  background: none;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 0.4rem 0.6rem;
  color: var(--ink);
  cursor: pointer;
}

/* ----------------------------------- hero ---------------------------------- */
.hero {
  position: relative;
  overflow: hidden;
  background: #10201a;
  border-bottom: 1px solid var(--line);
}
.hero-media {
  position: absolute;
  inset: 0;
  z-index: 0;
}
.hero-photo {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center 38%;
}
.hero-scrim {
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(100deg, rgba(7, 12, 10, 0.86) 0%, rgba(7, 12, 10, 0.6) 36%, rgba(7, 12, 10, 0.18) 62%, rgba(7, 12, 10, 0) 82%),
    linear-gradient(0deg, rgba(6, 10, 9, 0.7) 0%, rgba(6, 10, 9, 0.15) 32%, rgba(6, 10, 9, 0) 55%);
}
.hero-content {
  position: relative;
  z-index: 2;
  padding-block: clamp(4rem, 10vw, 7.5rem) clamp(9rem, 22vw, 13rem);
  display: flex;
  flex-direction: column;
  gap: 1.75rem;
  max-width: 700px;
}
.hero .label { color: var(--sun-400); }
.hero h1 {
  font-size: clamp(2.4rem, 4.6vw, 4rem);
  line-height: 1.05;
  color: #f7f4ec;
}
.hero h1 em {
  font-style: normal;
  color: var(--sun-400);
}
.hero-lede { font-size: 1.15rem; max-width: 52ch; color: rgba(247, 244, 236, 0.86); }
.hero-actions { display: flex; gap: 1rem; flex-wrap: wrap; }
.hero .btn-ghost { border-color: rgba(247, 244, 236, 0.5); color: #f7f4ec; }
.hero .btn-ghost:hover { border-color: var(--sun-400); color: var(--sun-400); }
.hero-meta {
  display: flex;
  gap: 2rem;
  flex-wrap: wrap;
  margin-top: 0.5rem;
}
.hero-meta div { display: flex; flex-direction: column; gap: 0.15rem; }
.hero-meta .num {
  font-family: var(--font-display);
  font-size: 1.5rem;
  font-weight: 700;
  font-variant-numeric: tabular-nums;
  color: #f7f4ec;
}
.hero-meta .cap {
  font-size: 0.75rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: rgba(247, 244, 236, 0.68);
}

/* ------------------------------- services --------------------------------- */
.services-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(230px, 1fr));
  gap: 1.5rem;
}
.service-card {
  background: var(--paper-raised);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: clamp(1.5rem, 3vw, 2rem);
  display: flex;
  flex-direction: column;
  gap: 0.9rem;
}
.service-icon {
  width: 38px;
  height: 38px;
  color: var(--spruce-700);
}
.service-card h3 { font-size: 1.15rem; }
.service-card p { font-size: 0.95rem; }

/* ------------------------------ service areas ------------------------------ */
.areas-band { background: var(--spruce-900); color: #eef1e8; }
@media (prefers-color-scheme: dark) {
  .areas-band { background: var(--paper-raised-2); }
}
:root[data-theme="dark"] .areas-band { background: var(--paper-raised-2); }
.areas-band .section-head p,
.areas-band .label { color: color-mix(in srgb, #eef1e8 70%, transparent); }
.areas-band .section-head h2 { color: #fff; }
:root[data-theme="dark"] .areas-band .section-head h2 { color: var(--ink); }
:root[data-theme="dark"] .areas-band p,
:root[data-theme="dark"] .areas-band .label { color: var(--ink-soft); }

.areas-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.5rem;
}
.area-card {
  background: color-mix(in srgb, #0f2e21 40%, transparent);
  border: 1px solid color-mix(in srgb, #eef1e8 20%, transparent);
  border-radius: var(--radius);
  padding: 1.75rem;
  display: flex;
  flex-direction: column;
  gap: 0.9rem;
}
@media (prefers-color-scheme: dark) {
  .area-card { background: color-mix(in srgb, var(--paper) 60%, transparent); border-color: var(--line); }
}
:root[data-theme="dark"] .area-card {
  background: color-mix(in srgb, var(--paper) 60%, transparent);
  border-color: var(--line);
}
.area-card h3 { color: #fff; font-size: 1.3rem; }
:root[data-theme="dark"] .area-card h3 { color: var(--ink); }
.area-card p { color: color-mix(in srgb, #eef1e8 78%, transparent); font-size: 0.95rem; }
:root[data-theme="dark"] .area-card p { color: var(--ink-soft); }
.area-card .area-price {
  color: var(--sun-400);
  font-family: var(--font-display);
  font-size: 1.05rem;
  font-weight: 700;
}
.areas-footnote {
  font-size: 0.82rem;
  color: color-mix(in srgb, #eef1e8 70%, transparent);
}

/* ---------------------------------- about ----------------------------------- */
.about-layout {
  max-width: 720px;
}
.field-notes {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
}
.field-notes li {
  display: grid;
  grid-template-columns: 28px 1fr;
  gap: 1rem;
  padding-block: 1.1rem;
  border-top: 1px solid var(--line);
}
.field-notes li:last-child { border-bottom: 1px solid var(--line); }
.field-notes svg { color: var(--spruce-700); width: 22px; height: 22px; margin-top: 0.15rem; }
.field-notes h4 { font-size: 1.05rem; margin-bottom: 0.3rem; }
.field-notes p { font-size: 0.95rem; }

/* -------------------------------- contact ----------------------------------- */
.contact-band { background: var(--paper-raised); border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.contact-layout {
  display: grid;
  grid-template-columns: 1fr 1.1fr;
  gap: clamp(2rem, 5vw, 4rem);
}
.contact-info { display: flex; flex-direction: column; gap: 1.75rem; }
.contact-detail { display: flex; gap: 0.9rem; }
.contact-detail svg { color: var(--fireweed-500); width: 22px; height: 22px; flex: none; margin-top: 0.15rem; }
.contact-detail h4 { font-size: 1rem; margin-bottom: 0.2rem; }
.contact-detail a { text-decoration: none; font-weight: 600; color: var(--ink); }
.contact-detail p { font-size: 0.92rem; }

form.quote-form {
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: clamp(1.5rem, 3vw, 2.25rem);
  display: flex;
  flex-direction: column;
  gap: 1.1rem;
}
.hidden-field {
  position: absolute;
  left: -9999px;
  width: 1px;
  height: 1px;
  overflow: hidden;
}
.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 1rem; }
.field { display: flex; flex-direction: column; gap: 0.4rem; }
.field label {
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--ink-soft);
}
.field input, .field select, .field textarea {
  font-family: var(--font-body);
  font-size: 0.98rem;
  padding: 0.7rem 0.8rem;
  border-radius: var(--radius);
  border: 1px solid var(--line);
  background: var(--paper-raised);
  color: var(--ink);
}
.field textarea { resize: vertical; min-height: 90px; }
.field input:focus, .field select:focus, .field textarea:focus { border-color: var(--spruce-700); }
.form-note { font-size: 0.82rem; color: var(--ink-soft); }
.form-success {
  display: none;
  background: color-mix(in srgb, var(--spruce-700) 14%, transparent);
  border: 1px solid var(--spruce-700);
  color: var(--spruce-700);
  padding: 0.9rem 1rem;
  border-radius: var(--radius);
  font-size: 0.92rem;
  font-weight: 600;
}
.form-success.visible { display: block; }

/* ---------------------------------- footer ----------------------------------- */
.site-footer { padding-block: 2.5rem; }
.footer-layout {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 1.5rem;
}
.footer-areas { display: flex; gap: 1.25rem; flex-wrap: wrap; font-size: 0.9rem; color: var(--ink-soft); }
.social-link {
  display: inline-flex;
  align-items: center;
  gap: 0.55rem;
  padding: 0.5rem 0.9rem;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  color: var(--ink);
  text-decoration: none;
  font-weight: 600;
  font-size: 0.95rem;
  transition: border-color 0.15s ease, color 0.15s ease;
}
.social-link svg { width: 26px; height: 26px; flex: none; }
.social-link:hover { border-color: var(--spruce-700); color: var(--spruce-700); }
.footer-fine { font-size: 0.82rem; color: var(--ink-soft); }
.footer-fine strong { color: var(--ink); }

/* ------------------------------- reveal-on-scroll ----------------------------- */
.reveal { opacity: 0; transform: translateY(14px); transition: opacity 0.6s ease, transform 0.6s ease; }
.reveal.in { opacity: 1; transform: translateY(0); }

/* ----------------------------------- responsive -------------------------------- */
@media (max-width: 880px) {
  .main-nav {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    flex-direction: column;
    align-items: flex-start;
    gap: 0;
    background: var(--paper);
    border-bottom: 1px solid var(--line);
    padding: 0.5rem clamp(1.25rem, 4vw, 2.5rem) 1rem;
  }
  .main-nav.nav-open { display: flex; }
  .main-nav a { padding-block: 0.6rem; width: 100%; }
  .nav-toggle { display: inline-flex; }
  .services-grid, .areas-grid, .contact-layout { grid-template-columns: 1fr; }
  .form-row { grid-template-columns: 1fr; }
  .hero-content { max-width: 100%; }
}

@media (max-width: 560px) {
  .hero-meta { gap: 1.25rem; }
  .nav-cta .phone-link { display: none; }
}
