/*
  CAMCO Earthworks — main stylesheet
  Colors come from colors.css (linked separately, do not duplicate values here).
*/

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  font-family: var(--font-body);
  color: var(--color-text);
  background: var(--color-bg);
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
}
img { max-width: 100%; display: block; }
a { color: inherit; }
h1, h2, h3, h4 {
  font-family: var(--font-heading);
  font-weight: 700;
  line-height: 1.15;
  margin: 0 0 0.5em;
}
p { margin: 0 0 1em; }
p:last-child { margin-bottom: 0; }
ul { margin: 0; padding: 0; }
button { font-family: inherit; }

.container {
  width: 100%;
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 24px;
}

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

/* ---------- Section backgrounds ---------- */
.section { padding: 88px 0; }
.section--tight { padding: 56px 0; }
.section--dark { background: var(--color-text); color: var(--color-bg); }
.section--light { background: var(--color-bg); color: var(--color-text); }
.section--card-on-dark { background: var(--color-secondary); }
.section--muted { background: #f2f1ef; }
.section-header { text-align: center; max-width: 720px; margin: 0 auto 48px; }
.section-header p { color: inherit; opacity: .8; }
.kicker {
  display: block; color: var(--color-primary); font-weight: 700;
  text-transform: uppercase; letter-spacing: 0.08em; font-size: 0.85rem;
  margin-bottom: 12px; font-family: var(--font-heading);
}

/* ---------- Zigzag section dividers ---------- */
.divider { position: relative; height: 54px; overflow: hidden; }
.divider svg { position: absolute; top: 0; left: 0; width: 100%; height: 100%; display: block; }
@media (max-width: 640px) { .divider { height: 32px; } }

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 10px;
  font-family: var(--font-heading); font-weight: 600; font-size: 1rem;
  padding: 15px 28px; border-radius: 8px; text-decoration: none;
  border: 2px solid transparent; cursor: pointer; transition: transform .12s ease, opacity .12s ease;
  line-height: 1;
}
.btn:hover { transform: translateY(-1px); }
.btn:active { transform: translateY(0); }
.btn svg { width: 18px; height: 18px; flex-shrink: 0; }
.btn-primary { background: var(--color-primary); color: #fff; }
.btn-primary:hover { opacity: .92; }
.btn-outline-dark { background: transparent; color: var(--color-text); border-color: var(--color-text); }
.btn-outline-light { background: transparent; color: #fff; border-color: #fff; }
.btn-outline-light:hover { background: rgba(255,255,255,0.08); }
.btn-outline-dark:hover { background: rgba(0,0,0,0.06); }
.btn-block { width: 100%; }
.cta-row { display: flex; flex-wrap: wrap; gap: 16px; }

/* ---------- Header / nav ---------- */
.site-header {
  background: var(--color-text); border-bottom: 3px solid var(--color-primary);
  position: sticky; top: 0; z-index: 100;
}
.nav-wrap {
  display: flex; align-items: center; justify-content: space-between;
  padding: 14px 24px; max-width: 1200px; margin: 0 auto; gap: 24px;
}
.logo-link { display: flex; align-items: center; flex-shrink: 0; }
.logo-link img { height: 42px; width: auto; }
.main-nav { display: flex; align-items: center; gap: 4px; flex: 1; }
.main-nav ul { list-style: none; display: flex; align-items: center; gap: 4px; margin: 0 0 0 auto; }
.main-nav > ul > li { position: relative; }
.nav-link {
  display: flex; align-items: center; gap: 6px; color: #fff; text-decoration: none;
  font-family: var(--font-heading); font-weight: 500; font-size: 0.98rem;
  padding: 10px 14px; border-radius: 6px; white-space: nowrap;
}
.nav-link:hover, .nav-link:focus-visible { background: rgba(255,255,255,0.08); }
.nav-link .chev { width: 12px; height: 12px; transition: transform .15s ease; }
.has-dropdown[aria-expanded="true"] .chev { transform: rotate(180deg); }

.dropdown-panel {
  position: absolute; top: calc(100% + 6px); left: 50%; transform: translateX(-50%);
  background: #fff; color: var(--color-text); border-radius: 12px;
  box-shadow: 0 16px 40px rgba(0,0,0,0.25); min-width: 220px; padding: 10px;
  display: none; z-index: 200;
}
.has-dropdown[aria-expanded="true"] + .dropdown-panel,
.dropdown-panel.is-open { display: block; }
.dropdown-panel a {
  display: block; padding: 10px 14px; border-radius: 8px; text-decoration: none;
  font-size: 0.95rem; font-weight: 500;
}
.dropdown-panel a:hover, .dropdown-panel a:focus-visible { background: var(--color-accent); }
.dropdown-panel a.all-link { color: var(--color-primary); font-weight: 700; border-bottom: 1px solid #eee; border-radius: 8px 8px 0 0; margin-bottom: 4px; padding-bottom: 12px; }

.header-actions { display: flex; align-items: center; gap: 10px; flex-shrink: 0; }
.header-actions .btn { padding: 12px 20px; font-size: 0.95rem; }
.phone-btn-header { display: inline-flex; }

.nav-toggle {
  display: none; background: none; border: none; color: #fff; padding: 8px; cursor: pointer;
}
.nav-toggle svg { width: 28px; height: 28px; }

@media (max-width: 900px) {
  .main-nav { display: none; }
  .header-actions .btn-outline-light.phone-btn-header span.phone-text { display: none; }
  .nav-toggle { display: inline-flex; }
  .main-nav.is-open {
    display: block; position: absolute; top: 100%; left: 0; right: 0; background: var(--color-text);
    border-top: 1px solid rgba(255,255,255,0.12); max-height: calc(100vh - 72px); overflow-y: auto;
  }
  .main-nav.is-open ul { flex-direction: column; align-items: stretch; margin: 0; padding: 12px; gap: 2px; }
  .main-nav.is-open .nav-link { padding: 14px; }
  .dropdown-panel { position: static; transform: none; box-shadow: none; background: rgba(255,255,255,0.06); margin-top: 4px; }
  .dropdown-panel a { color: #fff; }
  .dropdown-panel a:hover { background: rgba(255,255,255,0.12); }
  .dropdown-panel a.all-link { border-bottom-color: rgba(255,255,255,0.2); }
}
@media (max-width: 560px) {
  .header-actions .btn { padding: 10px 12px; font-size: 0.88rem; }
  .header-actions .btn svg { width: 16px; height: 16px; }
  .logo-link img { height: 32px; }
}

/* ---------- Hero ---------- */
.hero { padding: 72px 0 64px; }
.hero .container { display: grid; grid-template-columns: 1.1fr 1fr; gap: 48px; align-items: center; }
.hero-copy h1 { font-size: clamp(1.9rem, 3.2vw, 2.75rem); color: #fff; }
.hero-copy p { color: rgba(255,255,255,0.82); font-size: 1.08rem; max-width: 46ch; }
.hero-image img { border-radius: 20px; width: 100%; aspect-ratio: 4 / 3; object-fit: cover; }
.page-hero { padding: 64px 0 56px; text-align: center; }
.page-hero h1 { color: #fff; font-size: clamp(1.8rem, 3vw, 2.5rem); }
.page-hero p { color: rgba(255,255,255,0.82); max-width: 60ch; margin: 0 auto; }
.page-hero.with-split .container { display: grid; grid-template-columns: 1.1fr 1fr; gap: 48px; align-items: center; text-align: left; }
.page-hero.with-split p { margin: 0 0 1em; }

@media (max-width: 860px) {
  .hero .container, .page-hero.with-split .container { grid-template-columns: 1fr; text-align: center; }
  .hero-copy p, .page-hero.with-split p { margin-left: auto; margin-right: auto; }
  .hero-image { order: -1; }
  .cta-row { justify-content: center; }
}

/* ---------- Card grids ---------- */
.grid-3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 28px; }
.grid-4 { display: grid; grid-template-columns: repeat(2, 1fr); gap: 24px; }
@media (max-width: 860px) { .grid-3 { grid-template-columns: 1fr; } .grid-4 { grid-template-columns: 1fr; } }

.feature-card {
  background: var(--color-secondary); border-radius: 14px; padding: 32px 26px; color: #fff; text-align: center;
}
.feature-card .icon-box {
  width: 52px; height: 52px; background: var(--color-primary); border-radius: 10px;
  display: flex; align-items: center; justify-content: center; margin: 0 auto 18px;
}
.feature-card .icon-box svg { width: 26px; height: 26px; color: #fff; }
.feature-card h3 { font-size: 1.15rem; color: #fff; }
.feature-card p { color: rgba(255,255,255,0.78); font-size: 0.96rem; }

.service-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 24px; }
@media (max-width: 860px) { .service-grid { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 560px) { .service-grid { grid-template-columns: 1fr; } }

.service-card { text-decoration: none; color: var(--color-text); border-radius: 12px; overflow: hidden; background: var(--color-bg); box-shadow: 0 1px 0 rgba(0,0,0,0.05); }
.service-card img { width: 100%; aspect-ratio: 4/3; object-fit: cover; }
.service-card-label {
  display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 16px 18px;
}
.service-card-label h3 { font-size: 1.05rem; margin: 0; }
.arrow-box {
  width: 34px; height: 34px; background: var(--color-primary); border-radius: 7px; flex-shrink: 0;
  display: flex; align-items: center; justify-content: center; transition: transform .15s ease;
}
.arrow-box svg { width: 18px; height: 18px; color: #fff; }
.service-card:hover .arrow-box { transform: translateX(3px); }
.service-card p.card-blurb { padding: 0 18px 18px; margin: -8px 0 0; font-size: 0.92rem; color: #555; }

/* Process steps */
.steps { display: grid; grid-template-columns: repeat(3, 1fr); gap: 28px; }
@media (max-width: 860px) { .steps { grid-template-columns: 1fr; } }
.step-card { background: var(--color-secondary); color: #fff; border-radius: 14px; padding: 34px 26px; text-align: center; }
.step-number {
  width: 42px; height: 42px; border-radius: 50%; background: var(--color-primary); color: #fff;
  display: flex; align-items: center; justify-content: center; font-family: var(--font-heading);
  font-weight: 700; margin: 0 auto 16px; font-size: 1.1rem;
}
.step-card h3 { color: #fff; font-size: 1.1rem; }
.step-card p { color: rgba(255,255,255,0.78); font-size: 0.95rem; }
.steps-cta { text-align: center; margin-top: 40px; }
.steps-cta p { font-weight: 600; margin-bottom: 18px; }
.steps-cta .cta-row { justify-content: center; }

/* Area pills */
.area-pills { display: flex; flex-wrap: wrap; gap: 12px; justify-content: center; }
.area-pill {
  display: inline-flex; align-items: center; gap: 8px; background: var(--color-secondary); color: #fff;
  padding: 10px 18px; border-radius: 999px; text-decoration: none; font-size: 0.94rem; font-weight: 500;
}
.area-pill:hover { background: #3a3a3a; }
.area-pill svg { width: 15px; height: 15px; color: var(--color-primary); flex-shrink: 0; }
.view-all-link {
  display: block; text-align: center; margin-top: 24px; color: var(--color-primary); font-weight: 600; text-decoration: none;
}
.view-all-link:hover { text-decoration: underline; }

/* Area cards (all-areas grid) */
.area-card-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 24px; }
@media (max-width: 860px) { .area-card-grid { grid-template-columns: 1fr; } }
.area-card { background: var(--color-secondary); border-radius: 14px; padding: 28px; color: #fff; }
.area-card .area-card-head { display: flex; align-items: center; gap: 12px; margin-bottom: 12px; }
.area-card .pin-box {
  width: 40px; height: 40px; background: var(--color-text); border-radius: 8px; flex-shrink: 0;
  display: flex; align-items: center; justify-content: center;
}
.area-card .pin-box svg { width: 20px; height: 20px; color: var(--color-primary); }
.area-card h3 { color: #fff; font-size: 1.1rem; margin: 0; }
.area-card .county { color: rgba(255,255,255,0.55); font-size: 0.85rem; }
.area-card p.desc { color: rgba(255,255,255,0.8); font-size: 0.94rem; margin: 10px 0 16px; }
.area-card a { color: var(--color-primary); font-weight: 600; text-decoration: none; display: inline-flex; align-items: center; gap: 6px; }
.area-card a:hover { text-decoration: underline; }
.area-card a svg { width: 14px; height: 14px; }

/* ---------- CTA band with background image ---------- */
.cta-band {
  position: relative; background-size: cover; background-position: center; padding: 96px 0;
  text-align: center; color: #fff;
}
.cta-band::before { content: ""; position: absolute; inset: 0; background: rgba(20,15,10,0.62); }
.cta-band .container { position: relative; z-index: 1; }
.cta-band h2 { color: #fff; font-size: clamp(1.6rem, 3vw, 2.2rem); }
.cta-band p { color: rgba(255,255,255,0.88); max-width: 60ch; margin: 0 auto 28px; }
.cta-band .cta-row { justify-content: center; }

/* ---------- Two column content ---------- */
.split { display: grid; grid-template-columns: 1fr 1fr; gap: 48px; align-items: center; }
@media (max-width: 860px) { .split { grid-template-columns: 1fr; } }
.split img { border-radius: 16px; width: 100%; aspect-ratio: 4/3; object-fit: cover; }
.split h2 { font-size: clamp(1.4rem, 2.4vw, 1.9rem); }

/* ---------- Footer ---------- */
.site-footer { background: var(--color-text); color: rgba(255,255,255,0.85); padding: 64px 0 0; }
.footer-grid { display: grid; grid-template-columns: 1.4fr 1fr 1fr; gap: 40px; padding-bottom: 48px; }
@media (max-width: 760px) { .footer-grid { grid-template-columns: 1fr; gap: 32px; } }
.footer-col img { height: 40px; margin-bottom: 16px; }
.footer-col address { font-style: normal; margin-bottom: 14px; line-height: 1.5; }
.footer-phone { color: var(--color-primary); font-weight: 700; font-size: 1.2rem; text-decoration: none; display: inline-block; margin-bottom: 6px; }
.footer-hours { color: rgba(255,255,255,0.55); font-size: 0.9rem; margin-bottom: 14px; }
.footer-social { display: flex; gap: 10px; }
.footer-social a {
  width: 36px; height: 36px; border-radius: 8px; background: rgba(255,255,255,0.08);
  display: flex; align-items: center; justify-content: center; text-decoration: none;
}
.footer-social a:hover { background: rgba(255,255,255,0.18); }
.footer-social svg { width: 18px; height: 18px; color: #fff; }
.footer-col h4 { color: #fff; font-size: 0.95rem; text-transform: uppercase; letter-spacing: 0.05em; margin-bottom: 16px; }
.footer-col ul { list-style: none; display: flex; flex-direction: column; gap: 10px; }
.footer-col a { color: rgba(255,255,255,0.75); text-decoration: none; font-size: 0.95rem; }
.footer-col a:hover { color: #fff; text-decoration: underline; }
.footer-bottom {
  border-top: 1px dashed rgba(255,255,255,0.2); padding: 22px 0; display: flex; flex-wrap: wrap;
  align-items: center; justify-content: space-between; gap: 12px; font-size: 0.88rem; color: rgba(255,255,255,0.55);
}
.footer-bottom a { color: rgba(255,255,255,0.85); text-decoration: none; font-weight: 600; }
.footer-bottom a:hover { text-decoration: underline; }

/* ---------- Contact page ---------- */
.contact-logo-band { background: var(--color-text); padding: 56px 0; text-align: center; }
.contact-logo-band img { max-width: 480px; width: 80%; margin: 0 auto; }
.contact-grid { display: grid; grid-template-columns: 0.9fr 1.1fr; gap: 48px; align-items: start; }
@media (max-width: 860px) { .contact-grid { grid-template-columns: 1fr; } }
.contact-info-list { display: flex; flex-direction: column; gap: 16px; margin-bottom: 24px; }
.contact-info-row { display: flex; align-items: flex-start; gap: 12px; font-size: 1.02rem; }
.contact-info-row svg { width: 20px; height: 20px; color: var(--color-primary); margin-top: 2px; flex-shrink: 0; }
.contact-info-row a { text-decoration: underline; }
.trust-list { list-style: none; display: flex; flex-direction: column; gap: 10px; padding-top: 20px; border-top: 1px solid #ddd; margin-top: 8px; }
.trust-list li { display: flex; align-items: center; gap: 10px; font-weight: 600; }
.trust-list svg { width: 18px; height: 18px; color: #1a8a3f; flex-shrink: 0; }
.contact-socials { display: flex; gap: 10px; margin-top: 20px; }
.contact-socials a {
  width: 40px; height: 40px; border-radius: 8px; background: var(--color-text);
  display: flex; align-items: center; justify-content: center; text-decoration: none;
}
.contact-socials svg { width: 19px; height: 19px; color: #fff; }

.estimate-form {
  background: #fdf1ea; border: 2px solid var(--color-primary); border-radius: 16px; padding: 36px;
}
.estimate-form h2 { text-align: center; margin-bottom: 24px; }
.form-field { margin-bottom: 20px; }
.form-field label { display: block; font-weight: 700; margin-bottom: 8px; font-size: 0.95rem; }
.form-field .req { color: var(--color-primary); }
.form-field input[type="text"], .form-field input[type="tel"], .form-field input[type="email"], .form-field textarea {
  width: 100%; border: 1px solid #cfcac3; border-radius: 8px; padding: 13px 14px; font-size: 1rem;
  font-family: var(--font-body); background: #fff;
}
.form-field textarea { min-height: 110px; resize: vertical; }
.checkbox-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 10px; }
@media (max-width: 480px) { .checkbox-grid { grid-template-columns: 1fr; } }
.checkbox-item { display: flex; align-items: center; gap: 10px; font-size: 0.98rem; }
.checkbox-item input { width: 18px; height: 18px; accent-color: var(--color-primary); }

/* ---------- Utility ---------- */
.text-center { text-align: center; }
.mt-0 { margin-top: 0; }
