/* ===========================================================
   SIERRA LANDSCAPE CONSTRUCTION — Stylesheet
   Theme: "Site survey" — olive/sage + sun-baked stone, clay accent
   Type: Fraunces (display) / Work Sans (body)
   =========================================================== */

:root {
  /* Color tokens */
  --olive: #3C4F2E;        /* primary olive green - dark surfaces, headings */
  --sage: #5B7349;         /* secondary olive - mid-tone surface/accent */
  --sage-light: #738F5C;   /* hover state for sage */
  --stone: #E8E5DC;        /* soft neutral, used sparingly for subtle fills */
  --limestone: #FFFFFF;    /* clean white - primary light surface */
  --ink: #1A1A18;          /* near-black - primary text, dark surfaces */
  --muted: #B9C2AC;        /* muted sage-grey - secondary text on dark */
  --muted-ink: #5A5D55;    /* secondary text on light */
  --line: #E3E3E0;         /* hairline border on light */
  --line-dark: #33402A;    /* hairline border on dark */
  --clay: #1A1A18;         /* CTA accent now near-black, replacing terracotta */
  --clay-dark: #000000;    /* hover state for CTAs */

  /* Type */
  --font-display: 'Fraunces', serif;
  --font-body: 'Work Sans', sans-serif;

  /* Layout */
  --container: 1180px;
  --radius: 12px;
}

/* ---------- Reset ---------- */
* { margin: 0; padding: 0; box-sizing: border-box; }

html {
  scroll-behavior: smooth;
  width: 100%;
}

body {
  width: 100%;
  min-height: 100vh;
  font-family: var(--font-body);
  color: var(--ink);
  background: var(--limestone);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

img, svg, video, picture { max-width: 100%; height: auto; display: block; }

a { color: inherit; text-decoration: none; }

ul, ol { list-style: none; }

h1, h2, h3, h4 {
  font-family: var(--font-display);
  line-height: 1.15;
  letter-spacing: -0.01em;
  font-weight: 600;
}

button { font-family: inherit; cursor: pointer; border: none; background: none; }

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

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.001ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.001ms !important;
    scroll-behavior: auto !important;
  }
}

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  font-weight: 600;
  font-size: 0.95rem;
  padding: 0.75rem 1.4rem;
  border-radius: 999px;
  transition: transform 0.15s ease, background 0.15s ease, color 0.15s ease;
  white-space: nowrap;
}
.btn-primary {
  background: var(--clay);
  color: var(--limestone);
}
.btn-primary:hover {
  background: var(--clay-dark);
  transform: translateY(-1px);
}
.btn-ghost {
  border: 2px solid var(--olive);
  color: var(--olive);
}
.btn-ghost:hover { background: var(--olive); color: var(--limestone); }

.btn-ghost-light {
  border: 2px solid var(--limestone);
  color: var(--limestone);
}
.btn-ghost-light:hover { background: var(--limestone); color: var(--olive); }

.btn-lg { padding: 1rem 1.9rem; font-size: 1rem; }
.btn-block { width: 100%; }

/* ---------- Eyebrow ---------- */
.eyebrow {
  display: inline-flex;
  align-items: center;
  font-family: var(--font-body);
  font-size: 0.8rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  font-weight: 600;
  color: var(--muted);
  margin-bottom: 1rem;
}
.eyebrow-dark { color: var(--sage); }

/* ---------- Header ---------- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(246, 241, 231, 0.92);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--line);
}
.header-inner {
  max-width: var(--container);
  margin: 0 auto;
  padding: 0.9rem 1.5rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1.5rem;
}
.logo {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  color: var(--ink);
}
.logo-mark-img { height: 40px; width: auto; display: block; }
.logo-text {
  font-family: var(--font-display);
  font-size: 0.8rem;
  letter-spacing: 0.04em;
  line-height: 1.3;
  color: var(--muted-ink);
}
.logo-text strong { color: var(--olive); font-weight: 700; display: block; font-size: 0.78rem; letter-spacing: 0.02em; }
.logo-subtitle {
  font-size: 0.68rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  color: var(--sage);
  text-transform: uppercase;
}

.main-nav {
  display: flex;
  align-items: center;
  gap: 2rem;
}
.main-nav a {
  color: var(--ink);
  font-size: 0.92rem;
  font-weight: 500;
  padding: 0.3rem 0;
}
.main-nav a:hover { color: var(--clay); }

.header-actions {
  display: flex;
  align-items: center;
  gap: 1.2rem;
}
.header-phone {
  font-weight: 600;
  font-size: 0.92rem;
  white-space: nowrap;
  color: var(--olive);
}
.header-phone:hover { color: var(--clay); }

.nav-toggle {
  display: none;
  flex-direction: column;
  justify-content: center;
  gap: 5px;
  width: 28px;
  height: 22px;
}
.nav-toggle span {
  display: block;
  height: 2px;
  background: var(--ink);
  border-radius: 2px;
  transition: transform 0.25s ease, opacity 0.25s ease;
}
.nav-toggle.is-open span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.nav-toggle.is-open span:nth-child(2) { opacity: 0; }
.nav-toggle.is-open span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

/* ---------- Hero ---------- */
.hero {
  background: var(--limestone);
  position: relative;
  overflow: hidden;
}
.hero-grid {
  max-width: var(--container);
  margin: 0 auto;
  padding: 4.5rem 1.5rem 4rem;
  display: grid;
  grid-template-columns: 1.05fr 0.95fr;
  gap: 3rem;
  align-items: center;
}
.hero-copy h1 {
  font-size: clamp(2.3rem, 4.4vw, 3.6rem);
  margin-bottom: 1.2rem;
  color: var(--olive);
}
.hero-copy .accent { color: var(--clay); font-style: italic; }
.hero-sub {
  font-size: 1.08rem;
  color: var(--muted-ink);
  max-width: 40ch;
  margin-bottom: 1.8rem;
}
.hero-actions { display: flex; gap: 1rem; flex-wrap: wrap; margin-bottom: 2rem; }

.trust-row {
  display: flex;
  gap: 1.6rem;
  flex-wrap: wrap;
  font-size: 0.88rem;
  font-weight: 600;
  color: var(--sage);
}
.trust-row li { display: flex; align-items: center; gap: 0.5rem; }
.trust-row li::before {
  content: '';
  width: 6px; height: 6px;
  border-radius: 50%;
  background: var(--clay);
}

.hero-media img {
  border-radius: var(--radius);
  height: 460px;
  object-fit: cover;
  width: 100%;
}

.contour-divider {
  display: block;
  width: 100%;
  height: 40px;
  color: var(--sage);
  opacity: 0.5;
}

/* ---------- Stats strip ---------- */
.stats-strip {
  background: var(--olive);
  color: var(--limestone);
}
.stats-inner {
  max-width: var(--container);
  margin: 0 auto;
  padding: 2.2rem 1.5rem;
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1.5rem;
  text-align: center;
}
.stat { display: flex; flex-direction: column; gap: 0.3rem; }
.stat-num {
  font-family: var(--font-display);
  font-size: 1.9rem;
  font-weight: 700;
  color: var(--stone);
}
.stat-label {
  font-size: 0.82rem;
  color: var(--muted);
  letter-spacing: 0.02em;
}

/* ---------- Section shells ---------- */
.section-inner {
  max-width: var(--container);
  margin: 0 auto;
  padding: 5.5rem 1.5rem;
}
.section-inner h2 {
  font-size: clamp(1.8rem, 3vw, 2.4rem);
  max-width: 24ch;
  margin-bottom: 1rem;
  color: var(--olive);
}
.section-sub {
  color: var(--muted-ink);
  max-width: 58ch;
  font-size: 1.02rem;
  margin-bottom: 2.8rem;
}

/* ---------- Services ---------- */
.services { background: var(--limestone); }
.services-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.5rem;
}
.service-card {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 1.8rem;
  transition: transform 0.18s ease, box-shadow 0.18s ease, border-color 0.18s ease;
}
.service-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 12px 28px rgba(47, 58, 42, 0.1);
  border-color: var(--sage);
}
.service-num {
  display: inline-block;
  font-family: var(--font-display);
  font-size: 0.85rem;
  font-weight: 700;
  color: var(--stone);
  margin-bottom: 0.8rem;
}
.service-card h3 {
  font-size: 1.15rem;
  margin-bottom: 0.5rem;
  color: var(--ink);
}
.service-card p {
  color: var(--muted-ink);
  font-size: 0.94rem;
}

/* ---------- About ---------- */
.about { background: #fff; }
.about-grid {
  max-width: var(--container);
  margin: 0 auto;
  padding: 5.5rem 1.5rem;
  display: grid;
  grid-template-columns: 0.85fr 1.15fr;
  gap: 3.5rem;
  align-items: center;
}
.about-media img {
  border-radius: var(--radius);
  height: 520px;
  object-fit: cover;
}
.about-copy h2 { margin-bottom: 1rem; max-width: 20ch; }
.about-copy > p { color: var(--muted-ink); margin-bottom: 1.8rem; max-width: 54ch; }

.checklist { display: flex; flex-direction: column; gap: 0.9rem; margin-bottom: 2rem; }
.checklist li {
  display: flex;
  align-items: flex-start;
  gap: 0.8rem;
  font-weight: 600;
  font-size: 0.95rem;
  color: var(--ink);
}
.checklist li::before {
  content: '✓';
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 20px; height: 20px;
  border-radius: 50%;
  background: var(--sage);
  color: var(--limestone);
  font-size: 0.7rem;
  flex-shrink: 0;
  margin-top: 0.15rem;
}

/* ---------- Work / Portfolio slider ---------- */
.work {
  background: var(--limestone);
  padding: 5.5rem 0;
  overflow: hidden; /* contain the marquee track within the section */
}
.work-header {
  max-width: var(--container);
  margin: 0 auto;
  padding: 0 1.5rem;
  margin-bottom: 2.8rem;
}
.work-header h2 { max-width: 24ch; }

.portfolio-slider {
  width: 100%;
  overflow: hidden;
  -webkit-mask-image: linear-gradient(90deg, transparent 0, #000 6%, #000 94%, transparent 100%);
  mask-image: linear-gradient(90deg, transparent 0, #000 6%, #000 94%, transparent 100%);
}
.portfolio-track {
  display: flex;
  gap: 1.5rem;
  width: max-content;
  animation: portfolio-scroll 32s linear infinite;
}
.portfolio-slider:hover .portfolio-track {
  animation-play-state: paused;
}
.portfolio-item {
  position: relative;
  flex: 0 0 auto;
  width: 320px;
  height: 230px;
  border-radius: var(--radius);
  overflow: hidden;
  border: 1px solid var(--line);
  background: #fff;
}
.portfolio-item img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.portfolio-item figcaption {
  position: absolute;
  left: 0; right: 0; bottom: 0;
  padding: 0.9rem 1.1rem;
  background: linear-gradient(to top, rgba(27, 31, 23, 0.85), transparent);
  color: var(--limestone);
  font-size: 0.92rem;
  font-weight: 600;
}

/* Track contains the image set twice back-to-back; animate exactly half its
   width so the loop point is invisible. */
@keyframes portfolio-scroll {
  from { transform: translateX(0); }
  to   { transform: translateX(-50%); }
}

@media (prefers-reduced-motion: reduce) {
  .portfolio-track { animation: none; }
  .portfolio-slider { overflow-x: auto; }
}

/* ---------- Reviews ---------- */
.reviews { background: var(--olive); color: var(--limestone); }
.reviews .eyebrow { color: var(--stone); }
.reviews h2 { color: var(--limestone); max-width: 20ch; }
.reviews-note { color: var(--muted); font-style: italic; font-size: 0.88rem; }
.reviews-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.5rem;
}
.review-card {
  background: var(--sage);
  border: 1px solid var(--line-dark);
  border-radius: var(--radius);
  padding: 1.8rem;
  display: flex;
  flex-direction: column;
  gap: 1.2rem;
}
.stars { color: var(--stone); letter-spacing: 0.1em; }
.review-card p {
  font-size: 0.97rem;
  color: var(--limestone);
  opacity: 0.95;
}
.review-card footer {
  display: flex;
  flex-direction: column;
  gap: 0.15rem;
  font-size: 0.85rem;
}
.review-card footer strong { color: var(--stone); }
.review-card footer span { color: var(--muted); }

/* ---------- CTA band ---------- */
.cta-band {
  background: var(--clay);
  color: var(--limestone);
}
.cta-inner {
  max-width: 760px;
  margin: 0 auto;
  padding: 4.5rem 1.5rem;
  text-align: center;
}
.cta-inner h2 { font-size: clamp(1.7rem, 3vw, 2.2rem); margin-bottom: 0.8rem; color: var(--limestone); }
.cta-inner p { font-size: 1.05rem; margin-bottom: 2rem; opacity: 0.92; }
.cta-inner .hero-actions { justify-content: center; }
.cta-band .btn-primary { background: var(--olive); color: var(--limestone); }
.cta-band .btn-primary:hover { background: var(--ink); }

/* ---------- Contact ---------- */
.contact { background: #fff; }
.contact-grid {
  max-width: var(--container);
  margin: 0 auto;
  padding: 5.5rem 1.5rem;
  display: grid;
  grid-template-columns: 0.9fr 1.1fr;
  gap: 3.5rem;
}
.contact-info h2 { margin-bottom: 1rem; max-width: 20ch; }
.contact-details {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 1.6rem;
  margin-top: 2rem;
}
.contact-details dt {
  font-family: var(--font-display);
  font-size: 0.75rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--sage);
  margin-bottom: 0.3rem;
}
.contact-details dd { font-weight: 600; font-size: 0.97rem; color: var(--ink); }
.contact-details a:hover { color: var(--clay); }

.contact-form {
  background: var(--limestone);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 2rem;
  display: flex;
  flex-direction: column;
  gap: 1.3rem;
}
.form-row { display: flex; flex-direction: column; gap: 0.5rem; }
.form-row label {
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--ink);
}
.form-row input,
.form-row select,
.form-row textarea {
  font-family: inherit;
  font-size: 0.95rem;
  padding: 0.75rem 0.9rem;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: #fff;
  color: var(--ink);
}
.form-row input:focus,
.form-row select:focus,
.form-row textarea:focus {
  border-color: var(--clay);
  outline: none;
  box-shadow: 0 0 0 3px rgba(91, 115, 73, 0.18);
}
.form-row textarea { resize: vertical; }

/* ---------- Footer ---------- */
.site-footer { background: var(--ink); color: var(--limestone); }
.footer-inner {
  max-width: var(--container);
  margin: 0 auto;
  padding: 4rem 1.5rem 2.5rem;
  display: grid;
  grid-template-columns: 1.6fr 1fr 1fr 1fr;
  gap: 2.5rem;
}
.footer-brand .logo-text { font-size: 0.85rem; color: var(--limestone); }
.footer-brand .logo-text strong { color: var(--stone); }
.footer-brand p {
  margin-top: 1rem;
  color: var(--muted);
  font-size: 0.9rem;
  max-width: 32ch;
}
.footer-col { display: flex; flex-direction: column; gap: 0.7rem; }
.footer-col h4 {
  font-size: 0.78rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--stone);
  margin-bottom: 0.4rem;
  font-family: var(--font-body);
  font-weight: 700;
}
.footer-col a, .footer-col span {
  color: var(--muted);
  font-size: 0.92rem;
}
.footer-col a:hover { color: var(--limestone); }

.footer-bottom {
  border-top: 1px solid var(--line-dark);
  max-width: var(--container);
  margin: 0 auto;
  padding: 1.4rem 1.5rem;
  display: flex;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 0.5rem;
  font-size: 0.82rem;
  color: var(--muted);
}

/* ===========================================================
   RESPONSIVE
   =========================================================== */

@media (max-width: 1024px) {
  .hero-grid { grid-template-columns: 1fr; }
  .hero-media { order: -1; }
  .hero-media img { height: 340px; }
  .about-grid { grid-template-columns: 1fr; }
  .about-media img { height: 360px; }
  .about-media { order: -1; }
  .contact-grid { grid-template-columns: 1fr; }
  .footer-inner { grid-template-columns: 1fr 1fr; }
}

@media (max-width: 860px) {
  .main-nav { display: none; }
  .nav-toggle { display: flex; }
  .header-phone { display: none; }
  .logo-subtitle { display: none; }

  .main-nav.is-open {
    display: flex;
    flex-direction: column;
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: var(--limestone);
    border-bottom: 1px solid var(--line);
    padding: 1.2rem 1.5rem;
    gap: 1rem;
  }

  .services-grid { grid-template-columns: repeat(2, 1fr); }
  .portfolio-item { width: 260px; height: 190px; }
  .reviews-grid { grid-template-columns: 1fr; }
  .stats-inner { grid-template-columns: repeat(2, 1fr); }
}

@media (max-width: 600px) {
  .header-inner { padding: 0.8rem 1.2rem; }
  .hero-grid { padding: 3rem 1.2rem 3rem; }
  .section-inner, .about-grid, .contact-grid { padding: 3.5rem 1.2rem; }
  .hero-copy h1 { font-size: 2rem; }
  .hero-actions, .cta-inner .hero-actions { flex-direction: column; align-items: stretch; }
  .hero-actions .btn, .cta-inner .btn { width: 100%; }
  .trust-row { gap: 1rem 1.4rem; }
  .services-grid { grid-template-columns: 1fr; }
  .portfolio-item { width: 220px; height: 160px; }
  .portfolio-track { animation-duration: 22s; }
  .work { padding: 3.5rem 0; }
  .work-header { padding: 0 1.2rem; margin-bottom: 2rem; }
  .contact-details { grid-template-columns: 1fr; }
  .footer-inner { grid-template-columns: 1fr; gap: 2rem; padding: 3rem 1.2rem 2rem; }
  .footer-bottom { flex-direction: column; text-align: center; }
  .stats-inner { grid-template-columns: 1fr 1fr; gap: 1.2rem 1rem; }
  .stat-num { font-size: 1.5rem; }
}

/* ===========================================================
   PORTFOLIO PAGE (portfolio.html)
   =========================================================== */

.portfolio-hero {
  background: var(--olive);
  color: var(--limestone);
  padding: 4.5rem 0 3.5rem;
}
.portfolio-hero-inner {
  max-width: var(--container);
  margin: 0 auto;
  padding: 0 1.5rem;
}
.portfolio-hero .eyebrow { color: var(--stone); }
.portfolio-hero h1 {
  font-size: clamp(2.1rem, 4vw, 3rem);
  color: var(--limestone);
  max-width: 26ch;
  margin-bottom: 1rem;
}
.portfolio-hero .hero-sub {
  color: var(--muted);
  max-width: 48ch;
  margin-bottom: 1.8rem;
}

/* ---------- Filter pills ---------- */
.portfolio-filters {
  background: var(--limestone);
  border-bottom: 1px solid var(--line);
  position: sticky;
  top: 73px; /* sits just under the sticky site header */
  z-index: 50;
}
.filters-inner {
  display: flex;
  flex-wrap: wrap;
  gap: 0.7rem;
  padding: 1.2rem 1.5rem;
}
.filter-pill {
  font-family: var(--font-body);
  font-size: 0.88rem;
  font-weight: 600;
  padding: 0.55rem 1.1rem;
  border-radius: 999px;
  border: 1px solid var(--line);
  background: #fff;
  color: var(--muted-ink);
  cursor: pointer;
  transition: background 0.15s ease, color 0.15s ease, border-color 0.15s ease;
  white-space: nowrap;
}
.filter-pill:hover { border-color: var(--sage); color: var(--olive); }
.filter-pill.is-active {
  background: var(--ink);
  border-color: var(--ink);
  color: var(--limestone);
}

/* ---------- Portfolio grid ---------- */
.portfolio-grid-section { background: var(--limestone); }
.portfolio-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1.5rem;
}
.portfolio-grid-item {
  border-radius: var(--radius);
  overflow: hidden;
  background: #fff;
  border: 1px solid var(--line);
}
.img-placeholder {
  height: 220px;
  background: repeating-linear-gradient(
    45deg,
    var(--stone) 0,
    var(--stone) 12px,
    #fff 12px,
    #fff 24px
  );
  display: flex;
  align-items: center;
  justify-content: center;
}
.img-placeholder span {
  background: rgba(255, 255, 255, 0.9);
  color: var(--muted-ink);
  font-size: 0.78rem;
  font-weight: 600;
  letter-spacing: 0.03em;
  padding: 0.4rem 0.8rem;
  border-radius: 999px;
}
.portfolio-grid-item figcaption {
  padding: 0.9rem 1.1rem;
  font-size: 0.92rem;
  font-weight: 600;
  color: var(--ink);
}

@media (max-width: 1024px) {
  .portfolio-grid { grid-template-columns: repeat(3, 1fr); }
}

@media (max-width: 860px) {
  .portfolio-filters { top: 0; } /* header collapses its phone/nav row on mobile */
  .portfolio-grid { grid-template-columns: repeat(2, 1fr); }
}

@media (max-width: 600px) {
  .portfolio-hero { padding: 3rem 0 2.5rem; }
  .portfolio-hero-inner { padding: 0 1.2rem; }
  .filters-inner { padding: 1rem 1.2rem; }
  .portfolio-grid { grid-template-columns: 1fr 1fr; gap: 1rem; }
  .img-placeholder { height: 150px; }
}
