/* ==========================================================================
   Dove Decking LLC — site styles
   Plain CSS, mobile-first. Colors and fonts are set once below in :root.
   Colors are sampled from the official business card (assets/business-card.png).
   ========================================================================== */

/* Self-hosted fonts (files in /fonts, SIL Open Font License — see fonts/OFL-*.txt).
   Nothing is loaded from Google Fonts or any other outside server. */
@font-face {
  font-family: "Great Vibes";
  src: url("../fonts/great-vibes-latin.woff2") format("woff2");
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "EB Garamond";
  src: url("../fonts/eb-garamond-400-latin.woff2") format("woff2");
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}

:root {
  --bg: #f8f5ee;          /* warm off-white, like the card stock */
  --bg-alt: #efeadf;      /* slightly deeper cream for alternating sections */
  --surface: #fffefb;     /* cards / form fields */
  --text: #262b22;        /* dark charcoal-green body text */
  --muted: #4d5448;       /* secondary text */
  --forest: #2f3b2a;      /* card wordmark + tagline green */
  --green: #4f5d36;       /* leaf green for small text accents (AA on cream) */
  --leaf: #7f9152;        /* lighter leaf green for decorative bullets/leaves only */
  --green-dark: #3a4a32;  /* buttons */
  --green-deep: #2a3424;  /* footer (card border tone) */
  --bark: #5a4632;
  --line: #d9d3c3;
  --radius: 14px;
  --shadow: 0 1px 2px rgba(38, 43, 34, .06), 0 8px 24px rgba(38, 43, 34, .08);
  --script: "Great Vibes", "Snell Roundhand", "Apple Chancery", "Brush Script MT", cursive;
  --serif: "EB Garamond", Garamond, Georgia, "Iowan Old Style", "Palatino Linotype", serif;
  --sans: system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  --wrap: 72rem;
}

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

html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { transition: none !important; }
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: var(--sans);
  font-size: 1.0625rem;
  line-height: 1.65;
}

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

h1, h2, h3 {
  font-family: var(--serif);
  font-weight: 400;
  line-height: 1.2;
  margin: 0 0 .6em;
  letter-spacing: -.005em;
}
h1, h2, h3 { color: var(--forest); }
h1 { font-size: clamp(2.3rem, 6vw + 1rem, 4rem); }
h2 { font-size: clamp(2rem, 3vw + 1.1rem, 2.9rem); }
h3 { font-size: clamp(1.55rem, 1.5vw + 1.1rem, 2.05rem); }
p { margin: 0 0 1em; }

a { color: var(--green-dark); text-underline-offset: .2em; }
a:hover { color: var(--text); }

:focus-visible {
  outline: 3px solid var(--green);
  outline-offset: 3px;
  border-radius: 4px;
}

/* Anchor targets land below the sticky header */
section[id], article[id] { scroll-margin-top: 6.5rem; }

.wrap {
  width: 100%;
  max-width: var(--wrap);
  margin: 0 auto;
  padding: 0 1.25rem;
}

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

/* Hidden holder for the reusable SVG icons */
.sprite { position: absolute; width: 0; height: 0; overflow: hidden; }

/* ---------- Brand type (matches the business card) ---------- */
/* Script wordmark: "Dove Decking LLC" */
.wordmark {
  font-family: var(--script);
  font-weight: 400;
  color: var(--forest);
  letter-spacing: 0;
  line-height: 1.1;
}
/* Recurring tagline: widely spaced capitals, "HELPING YOU ENJOY NATURE".
   Written in normal case in the HTML so screen readers don't spell it out. */
.tagline {
  display: block;
  font: 600 .78rem/1.5 var(--sans);
  letter-spacing: .34em;
  text-transform: uppercase;
  color: var(--forest);
}
.dove { display: block; height: auto; }

/* ---------- Skip link ---------- */
.skip-link {
  position: absolute;
  left: 1rem; top: -4rem;
  z-index: 100;
  background: var(--green-dark);
  color: #fff;
  padding: .7rem 1rem;
  border-radius: 8px;
  font-weight: 600;
  text-decoration: none;
}
.skip-link:focus { top: 1rem; color: #fff; }

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: .5em;
  min-height: 48px;
  padding: .75rem 1.4rem;
  border: 2px solid var(--green-dark);
  border-radius: 999px;
  font: 600 1rem/1.2 var(--sans);
  text-decoration: none;
  cursor: pointer;
  transition: background-color .2s, color .2s, transform .2s;
}
.btn svg { width: 1.1em; height: 1.1em; flex: none; }
.btn-primary { background: var(--green-dark); color: #fff; }
.btn-primary:hover { background: var(--green-deep); border-color: var(--green-deep); color: #fff; }
.btn-ghost { background: transparent; color: var(--green-dark); }
.btn-ghost:hover { background: var(--green-dark); color: #fff; }
.btn:active { transform: translateY(1px); }

/* ---------- Header ---------- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(247, 243, 234, .96);
  border-bottom: 1px solid var(--line);
}
@supports (backdrop-filter: blur(6px)) {
  .site-header { background: rgba(247, 243, 234, .88); backdrop-filter: blur(6px); }
}

.header-inner {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: .5rem 1rem;
  padding-top: .6rem;
  padding-bottom: .4rem;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: .45rem;
  color: var(--forest);
  text-decoration: none;
  font-size: 1.3rem;
  line-height: 1.1;
  white-space: nowrap;
}
.brand:hover { color: var(--forest); }
.brand .dove { width: 42px; flex: none; }
.brand .wordmark { padding-top: .1em; }

.call-now { white-space: nowrap; min-height: 44px; padding: .55rem .9rem; font-size: .95rem; }

/* Mobile: nav sits on its own row under the logo — no menu button needed */
.site-nav { order: 3; width: 100%; }
.site-nav ul {
  list-style: none;
  margin: 0; padding: 0;
  display: flex;
  justify-content: space-between;
  gap: .25rem;
}
.site-nav a {
  display: block;
  padding: .55rem .4rem;
  color: var(--text);
  text-decoration: none;
  font-weight: 500;
  font-size: .98rem;
  white-space: nowrap;
  border-bottom: 2px solid transparent;
}
.site-nav a:hover { color: var(--green-dark); border-bottom-color: var(--green); }

@media (min-width: 52rem) {
  .header-inner { flex-wrap: nowrap; padding-top: .8rem; padding-bottom: .8rem; }
  .brand { font-size: 1.55rem; }
  .brand .dove { width: 48px; }
  .site-nav { order: 0; width: auto; margin-left: auto; }
  .site-nav ul { gap: 1.4rem; }
  .call-now { font-size: 1rem; padding: .6rem 1.25rem; }
}
@media (min-width: 64rem) {
  .brand { font-size: 2rem; }
  .brand .dove { width: 60px; }
}

/* ---------- Sections ---------- */
.section { padding: 4.5rem 0; }
.section-alt { background: var(--bg-alt); }
@media (min-width: 52rem) { .section { padding: 6.5rem 0; } }

.section-head {
  max-width: 40rem;
  margin: 0 auto 3rem;
  text-align: center;
}
.section-head p { color: var(--muted); }

.eyebrow {
  display: block;
  margin-bottom: .5rem;
  color: var(--green);
  font: 600 .8rem/1.3 var(--sans);
  letter-spacing: .14em;
  text-transform: uppercase;
}

/* Small leaf divider (leaf shape like the bullets on the business card) */
.divider {
  display: flex;
  align-items: center;
  gap: .9rem;
  max-width: 12rem;
  margin: 0 auto 1.1rem;
  color: var(--leaf);
}
.divider::before, .divider::after {
  content: "";
  flex: 1;
  height: 1px;
  background: var(--forest);
  opacity: .35;
}
.divider svg { width: 26px; height: 26px; flex: none; }

/* ---------- Hero ---------- */
.hero { position: relative; padding: 2.5rem 0 4rem; overflow: hidden; isolation: isolate; }
.hero-grid { position: relative; z-index: 1; display: grid; gap: 2.25rem; align-items: center; }

/* Card-style lockup: dove on its branch + script name over a thin rule + spaced tagline */
.hero-lockup {
  display: grid;
  grid-template-columns: auto 1fr;
  align-items: end;
  column-gap: .25rem;
  margin: 0 0 1.5rem;
  font-weight: 400;
}
.hero-lockup .dove { width: clamp(72px, 20vw, 124px); margin-bottom: -.2rem; }
.hero-lockup .wordmark {
  display: block;
  white-space: nowrap;
  /* sized to the text column so the name stays on one line, like the card */
  font-size: clamp(1.7rem, 8.8vw, 3.6rem);
  line-height: 1.05;
  padding: 0 .1em .12em 0;
  border-bottom: 1.5px solid var(--forest);
}
.hero-lockup .tagline {
  grid-column: 1 / -1;
  margin-top: .85rem;
  font-size: clamp(.72rem, 1.4vw + .45rem, .92rem);
  letter-spacing: .32em;
}

.hero-text .lead {
  font-size: 1.15rem;
  color: var(--muted);
  max-width: 34rem;
}
.hero-actions { display: flex; flex-wrap: wrap; gap: .75rem; margin-top: 1.75rem; }

.hero-media img {
  width: 100%;
  aspect-ratio: 4 / 3;
  object-fit: cover;
  border-radius: 22px;
  box-shadow: var(--shadow);
}

/* The card's tree, tucked into the top-right corner behind the photo
   (only on wider screens, where there is room around the photo) */
.hero-tree { display: none; }

@media (min-width: 52rem) {
  .hero { padding: 5.5rem 0 6rem; }
  .hero-grid { grid-template-columns: 1fr 1.1fr; gap: 4rem; }
  .hero-media img { aspect-ratio: 5 / 4; }
  .hero-lockup .dove { width: clamp(76px, 9vw, 116px); }
  .hero-lockup .wordmark { font-size: clamp(2rem, 4.35vw, 3.2rem); }
  .hero-tree {
    display: block;
    position: absolute;
    z-index: 0;
    top: 0;
    right: 0;
    width: clamp(380px, 40vw, 640px);
    pointer-events: none;
  }
  .hero-tree img { width: 100%; height: auto; }
}

/* ---------- Services ---------- */
.services-list { display: grid; gap: 3.5rem; }

.service { display: grid; gap: 1.5rem; align-items: center; }
.service img {
  width: 100%;
  aspect-ratio: 3 / 2;
  object-fit: cover;
  border-radius: var(--radius);
  box-shadow: var(--shadow);
}
.service-num {
  display: flex;
  align-items: center;
  gap: .5rem;
  font-family: var(--serif);
  font-size: 1.1rem;
  color: var(--green);
  margin-bottom: .25rem;
}
/* leaf bullet, like the services list on the business card */
.service-num::before {
  content: "";
  width: .7em;
  height: .7em;
  border-radius: 0 80% 0 80%;
  background: var(--leaf);
  transform: rotate(-12deg);
}
.service p { color: var(--muted); max-width: 34rem; }
.service .text-link { font-weight: 600; }

@media (min-width: 52rem) {
  .services-list { gap: 5.5rem; }
  .service { grid-template-columns: 1.15fr 1fr; gap: 4rem; }
  .service:nth-child(even) .service-media { order: 2; }
}

/* ---------- Gallery ---------- */
.gallery {
  display: grid;
  grid-template-columns: 1fr;
  gap: 1.5rem;
}
@media (min-width: 36rem) { .gallery { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 60rem) { .gallery { grid-template-columns: repeat(3, 1fr); } }

.gallery-item {
  margin: 0;
  background: var(--surface);
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: var(--shadow);
}
.gallery-item img {
  width: 100%;
  aspect-ratio: 3 / 2;
  object-fit: cover;
}
.gallery-item figcaption {
  padding: .85rem 1rem 1rem;
  font-size: .95rem;
  color: var(--muted);
}

/* Before / after pair: two photos side by side, spans two columns on larger screens */
.before-after .ba-images { display: grid; grid-template-columns: 1fr 1fr; gap: 3px; background: var(--line); }
.ba-photo { position: relative; background: var(--surface); }
.ba-label {
  position: absolute;
  left: .6rem; top: .6rem;
  padding: .2rem .6rem;
  border-radius: 999px;
  background: rgba(38, 56, 42, .88);
  color: #fff;
  font-size: .8rem;
  font-weight: 600;
  letter-spacing: .04em;
}
@media (min-width: 36rem) { .before-after { grid-column: span 2; } }

.gallery-note {
  margin-top: 2rem;
  text-align: center;
  color: var(--muted);
}

/* ---------- About ---------- */
.about-grid { display: grid; gap: 2rem; align-items: center; }
.about-mark {
  justify-self: center;
  display: grid;
  place-items: center;
  width: 11rem;
  height: 11rem;
  padding: 1.1rem;
  border-radius: 50%;
  background: var(--surface);
  box-shadow: var(--shadow);
}
.about-mark .dove { width: 100%; }
.about-text p { font-size: 1.1rem; }
.signature { font-family: var(--script); font-size: 2rem; line-height: 1.2; color: var(--forest); }
@media (min-width: 52rem) {
  .about-grid { grid-template-columns: auto 1fr; gap: 4rem; max-width: 56rem; margin: 0 auto; }
  .about-mark { width: 14rem; height: 14rem; }
}

/* ---------- Contact ---------- */
.contact-grid { display: grid; gap: 2.5rem; }
@media (min-width: 30rem) { .contact-card { padding: 2rem 1.5rem; } .contact-line { gap: .9rem; padding: .9rem 1rem; } }
@media (min-width: 52rem) { .contact-grid { grid-template-columns: 1fr 1.1fr; gap: 4rem; align-items: start; } }

.contact-card {
  padding: 1.75rem 1.1rem;
  background: var(--surface);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
}
.contact-card .owner { font-family: var(--serif); font-size: 1.75rem; color: var(--forest); margin-bottom: .1rem; }
.contact-card .owner-role { color: var(--muted); margin-bottom: 1.5rem; }

.contact-lines { list-style: none; margin: 0; padding: 0; display: grid; gap: 1rem; }
.contact-line {
  display: flex;
  align-items: center;
  gap: .75rem;
  padding: .85rem .8rem;
  border: 1px solid var(--line);
  border-radius: 12px;
  color: var(--text);
  text-decoration: none;
  transition: border-color .2s, background-color .2s;
}
.contact-line:hover { border-color: var(--green); background: #f1f2ea; color: var(--text); }
.contact-line .icon {
  display: grid;
  place-items: center;
  width: 44px; height: 44px;
  flex: none;
  border-radius: 50%;
  background: var(--green-dark);
  color: #fff;
}
.contact-line .icon svg { width: 20px; height: 20px; }
.contact-line small { display: block; color: var(--muted); font-size: .85rem; }
.contact-line strong {
  display: block;
  font-size: clamp(1.05rem, 2.5vw + .55rem, 1.6rem);
  font-weight: 600;
  overflow-wrap: anywhere;
  line-height: 1.25;
}
.contact-line .email-text { font-size: clamp(1rem, 2vw + .55rem, 1.45rem); overflow-wrap: normal; }

/* Form */
.contact-form { display: grid; gap: 1.1rem; }
.field label { display: block; font-weight: 600; margin-bottom: .35rem; }
.field .optional { font-weight: 400; color: var(--muted); }
.field input, .field textarea {
  width: 100%;
  padding: .8rem .9rem;
  font: inherit;
  color: var(--text);
  background: var(--surface);
  border: 1px solid #a8a08d;
  border-radius: 10px;
}
.field textarea { min-height: 9rem; resize: vertical; }
.field input:focus-visible, .field textarea:focus-visible { outline-offset: 1px; border-color: var(--green); }
.form-note { font-size: .9rem; color: var(--muted); margin: 0; }
.hidden-field { display: none; }

/* ---------- Footer ---------- */
.site-footer {
  background: var(--green-deep);
  color: #e9efe4;
  padding: 3.5rem 0 2rem;
}
.site-footer a { color: #e9efe4; }
.site-footer a:hover { color: #fff; }
.footer-grid { display: grid; gap: 2rem; }
@media (min-width: 52rem) { .footer-grid { grid-template-columns: 1.4fr 1fr 1fr; } }

.footer-brand { display: flex; align-items: center; gap: .6rem; margin-bottom: .6rem; }
.footer-brand .dove { width: 64px; flex: none; }
.footer-brand .wordmark { font-size: 2.1rem; color: #fff; }
.site-footer .tagline { color: #d9e0cf; font-size: .72rem; }
.site-footer h2 {
  font: 600 .8rem/1.3 var(--sans);
  letter-spacing: .14em;
  text-transform: uppercase;
  color: #c9d8c4;
  margin-bottom: .9rem;
}
.footer-links { list-style: none; margin: 0; padding: 0; display: grid; gap: .45rem; }
.footer-bottom {
  margin-top: 2.5rem;
  padding-top: 1.25rem;
  border-top: 1px solid rgba(233, 239, 228, .2);
  font-size: .9rem;
  color: #c9d8c4;
}
.footer-bottom p { margin: 0; }

/* ---------- Thanks page ---------- */
.thanks {
  min-height: 70vh;
  display: grid;
  place-items: center;
  text-align: center;
  padding: 4rem 0;
}
.thanks .dove { width: 150px; margin: 0 auto 1rem; }
.thanks p { color: var(--muted); max-width: 32rem; margin-left: auto; margin-right: auto; }
.thanks .hero-actions { justify-content: center; }
