/* Andrew's Tree Service — mobile-first, no framework. */

:root {
  --forest: #143028;
  --forest-2: #1c4034;
  --ink: #1a2420;
  --muted: #31443c;
  --cream: #f4efe6;
  --paper: #fffcf7;
  --line: #ddd4c6;
  --gold: #8a5e12;
  --gold-bg: #f3d48a;
  --moss: #e7f0e8;
  --danger: #8c1d1d;
  --shadow: 0 16px 40px rgba(20, 48, 40, 0.12);
  --serif: "Iowan Old Style", "Palatino Linotype", Palatino, Georgia, "Liberation Serif", serif;
  --sans: system-ui, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  --max: 1120px;
  --header: 4.5rem;
}

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

html { scroll-behavior: smooth; scroll-padding-bottom: 5.5rem; }

body {
  margin: 0;
  color: var(--ink);
  background: var(--cream);
  font-family: var(--sans);
  font-size: 1.125rem;
  line-height: 1.6;
  padding-bottom: 5.5rem;
}

img { max-width: 100%; height: auto; }

a { color: #145c38; }

a:hover { color: #0d3d25; }

h1, h2, h3, h4 {
  font-family: var(--serif);
  line-height: 1.15;
  font-weight: 700;
  letter-spacing: -0.02em;
  margin: 0 0 0.6rem;
}

h1 { font-size: clamp(2.2rem, 5vw, 3.7rem); }
h2 { font-size: clamp(1.7rem, 3vw, 2.45rem); }
h3 { font-size: 1.35rem; }

p { margin: 0 0 1rem; }

.skip {
  position: absolute;
  left: 1rem;
  top: -4rem;
  background: var(--gold-bg);
  color: var(--ink);
  padding: 0.6rem 1rem;
  z-index: 80;
  border-radius: 8px;
}

.skip:focus { top: 0.75rem; }

.wrap {
  width: min(var(--max), calc(100% - 2rem));
  margin-inline: auto;
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

:focus-visible {
  outline: 3px solid var(--gold);
  outline-offset: 3px;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 40;
  background: var(--forest);
  color: var(--cream);
}

.header-inner {
  width: min(var(--max), calc(100% - 1.25rem));
  margin-inline: auto;
  min-height: var(--header);
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.75rem;
}

.brand {
  display: flex;
  align-items: center;
  gap: 0.7rem;
  color: var(--cream);
  text-decoration: none;
  margin-right: auto;
  order: 1;
}

.brand-mark {
  width: 24px;
  height: 24px;
  display: block;
  flex: none;
  fill: currentColor;
}

.brand-name {
  font-family: var(--serif);
  font-weight: 700;
  line-height: 1;
  font-size: 0.98rem;
  letter-spacing: -0.02em;
  white-space: nowrap;
}

.nav-toggle { order: 2; }
.header-call { order: 3; }

.nav-toggle,
.header-call {
  min-height: 48px;
  min-width: 48px;
  border-radius: 999px;
  border: 2px solid rgba(244, 239, 230, 0.45);
  background: transparent;
  color: var(--cream);
  font: inherit;
  font-weight: 700;
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0 0.9rem;
}

.header-call { display: none; }

.site-nav {
  display: none;
  list-style: none;
  margin: 0;
  padding: 0.35rem 0 0.85rem;
  flex: 1 0 100%;
  order: 4;
}

.site-nav.is-open { display: flex; flex-direction: column; }

.site-nav a {
  color: var(--cream);
  text-decoration: none;
  font-weight: 650;
  display: flex;
  align-items: center;
  min-height: 48px;
  padding: 0.2rem 0;
  border-bottom: 1px solid rgba(244, 239, 230, 0.12);
}

.site-nav a[aria-current="page"] { color: var(--gold-bg); }

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.45rem;
  min-height: 48px;
  padding: 0.75rem 1.15rem;
  border-radius: 999px;
  border: 2px solid transparent;
  font: inherit;
  font-weight: 750;
  text-decoration: none;
  cursor: pointer;
  text-align: center;
}

.btn-call { background: var(--forest); color: var(--cream); }
.btn-call:hover { background: var(--forest-2); color: white; }
.btn-quote { background: var(--gold-bg); color: var(--ink); }
.btn-quote:hover { background: #e7c56e; color: var(--ink); }
.btn-ghost {
  background: transparent;
  color: var(--forest);
  border-color: var(--forest);
}
.btn-ghost:hover { background: var(--forest); color: var(--cream); }

.hero {
  display: grid;
  background: var(--paper);
}

.hero-media {
  min-height: 280px;
  background: #244036;
}

.hero-media img {
  width: 100%;
  height: 240px;
  object-fit: cover;
  object-position: center 46%;
  display: block;
}

.hero-copy {
  padding: 1.75rem 1.25rem 2.25rem;
}

.eyebrow {
  margin: 0 0 0.75rem;
  font-size: 0.82rem;
  font-weight: 750;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--gold);
}

.lede { font-size: 1.2rem; max-width: 40rem; }

.actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  margin: 1.25rem 0 0.5rem;
}

.actions .btn { flex: 1 1 12rem; }

.rating {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.55rem 0.8rem;
  margin: 1rem 0 0;
  font-weight: 700;
}

.stars { color: var(--gold); letter-spacing: 0.08em; font-size: 1.15rem; }

.rating a { font-weight: 750; }

.trust {
  background: var(--forest);
  color: var(--cream);
}

.trust ul {
  list-style: none;
  margin: 0;
  padding: 0.4rem 0;
  display: grid;
}

.trust li {
  margin: 0;
  padding: 0.85rem 0;
  border-bottom: 1px solid rgba(244, 239, 230, 0.14);
  font-weight: 700;
}

.trust li:last-child { border-bottom: 0; }

.trust span {
  display: block;
  font-weight: 500;
  color: #d7e4db;
  font-size: 0.98rem;
}

section { padding: 3.25rem 0; }

.section-head { max-width: 42rem; margin-bottom: 1.5rem; }

.cards {
  display: grid;
  gap: 0.9rem;
}

.card {
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
  background: var(--paper);
  border: 1px solid var(--line);
  border-top: 4px solid #2f6b45;
  border-radius: 14px;
  padding: 1.15rem 1.15rem 1.05rem;
  color: inherit;
  text-decoration: none;
  min-height: 100%;
  box-shadow: 0 1px 0 rgba(20, 48, 40, 0.04);
}

.card:hover { border-top-color: var(--gold); color: inherit; }

.card p { color: var(--muted); margin: 0; flex: 1; }

.more {
  margin-top: 0.8rem;
  font-weight: 750;
  color: #145c38;
}

.gallery {
  display: grid;
  gap: 0.75rem;
  grid-template-columns: 1fr;
}

.shot {
  position: relative;
  display: block;
  width: 100%;
  padding: 0;
  border: 0;
  border-radius: 14px;
  overflow: hidden;
  background: #d9d1c4;
  cursor: zoom-in;
  aspect-ratio: 4 / 3;
}

.shot img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.split {
  display: grid;
  gap: 1.25rem;
  align-items: center;
}

.split img {
  width: 100%;
  border-radius: 16px;
  display: block;
  object-fit: cover;
  max-height: 520px;
}

.panel {
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: 16px;
  padding: 1.25rem;
}

blockquote {
  margin: 0;
  font-family: var(--serif);
  font-size: 1.35rem;
  line-height: 1.4;
}

blockquote p { margin: 0; }

cite {
  display: block;
  margin-top: 0.9rem;
  font-style: normal;
  font-family: var(--sans);
  font-size: 1rem;
  font-weight: 700;
}

.towns {
  display: grid;
  gap: 0.75rem;
}

.towns a {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  min-height: 56px;
  padding: 0.8rem 1rem;
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: 12px;
  text-decoration: none;
  color: var(--ink);
  font-weight: 750;
}

.towns a:hover { border-color: #2f6b45; color: var(--ink); }

.towns a span { color: var(--muted); font-weight: 600; }

.form-card {
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: 18px;
  padding: 1.25rem;
  box-shadow: var(--shadow);
}

form { display: grid; gap: 0.9rem; }
.form-grid { display: grid; gap: 0.9rem; }

label { display: grid; gap: 0.35rem; font-weight: 750; }

input, select, textarea {
  width: 100%;
  min-height: 48px;
  padding: 0.7rem 0.8rem;
  border: 1.5px solid #c9bfb0;
  border-radius: 10px;
  background: white;
  color: var(--ink);
  font: inherit;
}

textarea { min-height: 8.5rem; resize: vertical; }
input, select, textarea, .btn { scroll-margin-bottom: 5.75rem; }

.hint { font-weight: 500; color: var(--muted); font-size: 0.95rem; }

.hp {
  position: absolute;
  left: -9999px;
  height: 0;
  overflow: hidden;
}

.form-status {
  min-height: 1.5rem;
  margin: 0;
  font-weight: 700;
}

.form-status.is-error { color: var(--danger); }
.form-status.is-ok { color: #145c38; }

.crumbs {
  font-size: 0.95rem;
  margin: 0 0 0.25rem;
  padding-top: 1.15rem;
  color: var(--muted);
}

.crumbs a { color: var(--muted); }

.prose { max-width: 42rem; }

.prose ul, .check-list { padding-left: 1.15rem; }
.prose li, .check-list li { margin: 0.35rem 0; }

.page-hero { padding: 1.25rem 0 0.5rem; }
.page-hero .prose { margin-inline: auto; }

.page-photo {
  width: 100%;
  border-radius: 16px;
  object-fit: cover;
  max-height: 460px;
}

.related {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin-top: 0.5rem;
}

.related a {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  padding: 0.35rem 0.8rem;
  border-radius: 999px;
  background: var(--moss);
  text-decoration: none;
  color: var(--forest);
  font-weight: 700;
}

.site-footer {
  background: var(--forest);
  color: #e7efe9;
  padding: 2.5rem 0 2rem;
}

.site-footer a { color: var(--gold-bg); }

.footer-grid {
  display: grid;
  gap: 1.5rem;
}

.site-footer h2 {
  font-family: var(--sans);
  font-size: 0.82rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--gold-bg);
}

.site-footer h2.footer-brand {
  display: flex;
  align-items: center;
  gap: 0.55rem;
  margin: 0 0 0.75rem;
  font-family: var(--serif);
  font-size: 1.3rem;
  font-weight: 700;
  letter-spacing: -0.02em;
  text-transform: none;
  color: var(--cream);
  line-height: 1.1;
}

.site-footer ul { list-style: none; margin: 0; padding: 0; }
.site-footer li { margin: 0.25rem 0; }

.nap-phone {
  font-size: 1.45rem;
  font-family: var(--serif);
  font-weight: 700;
}

.nap-phone a { color: white; text-decoration: none; }

.legal {
  margin-top: 1.5rem;
  padding-top: 1rem;
  border-top: 1px solid rgba(244, 239, 230, 0.15);
  color: #c9d6ce;
  font-size: 0.95rem;
}

.sticky-call {
  position: fixed;
  left: 0.75rem;
  right: 0.75rem;
  bottom: 0.75rem;
  z-index: 35;
  min-height: 52px;
  border-radius: 999px;
  background: var(--gold-bg);
  color: var(--ink);
  text-decoration: none;
  font-weight: 800;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 10px 24px rgba(20, 48, 40, 0.25);
  transition: transform 0.2s ease;
}
.sticky-call.is-away { transform: translateY(160%); }

.sticky-call:hover { color: var(--ink); background: #e7c56e; }

#lightbox {
  position: relative;
  border: 0;
  padding: 0;
  background: transparent;
  max-width: min(1040px, 96vw);
  width: 100%;
}

#lightbox::backdrop { background: rgba(10, 22, 18, 0.88); }

#lightbox img {
  width: 100%;
  height: auto;
  border-radius: 12px;
  display: block;
}

#lightbox form { margin: 0; }

.lightbox-close {
  position: absolute;
  top: 0.5rem;
  right: 0.5rem;
}

.note {
  background: var(--moss);
  border-radius: 12px;
  padding: 0.9rem 1rem;
}

@media (min-width: 700px) {
  .trust ul { grid-template-columns: 1fr 1fr; }
  .trust li { border-bottom: 0; padding: 1.1rem 1rem 1.1rem 0; }
  .cards { grid-template-columns: 1fr 1fr; }
  .towns { grid-template-columns: 1fr 1fr; }
  .footer-grid { grid-template-columns: 1.3fr 1fr 1fr; }
  .form-grid { grid-template-columns: 1fr 1fr; }
  .form-grid .full { grid-column: 1 / -1; }
}

@media (min-width: 960px) {
  body { padding-bottom: 0; }
  .sticky-call { display: none; }
  .nav-toggle { display: none; }
  .header-call { display: inline-flex; }
  .header-inner { gap: 1rem; }
  .site-nav {
    display: flex;
    flex-direction: row;
    align-items: center;
    gap: 1.1rem;
    flex: 0 1 auto;
    margin: 0 0 0 auto;
    padding: 0;
  }
  .brand { margin-right: 0; }
  .brand-name { font-size: 1.2rem; }
  .brand-mark { width: 28px; height: 28px; }
  .site-nav a {
    border: 0;
    min-height: 48px;
    padding: 0;
  }
  .hero {
    grid-template-columns: 1.15fr 0.85fr;
    min-height: 640px;
    align-items: stretch;
  }
  .hero-media img {
    height: 100%;
    min-height: 640px;
  }
  .hero-copy {
    display: flex;
    flex-direction: column;
    justify-content: center;
    padding: 3rem 3rem 3rem 2.5rem;
  }
  .trust ul { grid-template-columns: repeat(4, 1fr); }
  .cards { grid-template-columns: 1fr 1fr 1fr; }
  .site-nav { order: 2; }
  .header-call { order: 3; }
  .gallery {
    grid-template-columns: 1.4fr 1fr 1fr;
    grid-auto-rows: 220px;
  }
  .gallery .shot { aspect-ratio: auto; height: 100%; }
  .gallery .shot:first-child { grid-row: span 2; }
  .split { grid-template-columns: 1.05fr 0.95fr; gap: 2rem; }
  .towns { grid-template-columns: 1fr 1fr 1fr; }
  .form-card { padding: 1.75rem; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  * { transition: none !important; }
}
