/* ============================================
   MainStreet AI — site stylesheet
   Palette: light gray + white / navy / goldenrod + sage
   ============================================ */
:root {
  --paper: #d9dfe6;
  --card: #ffffff;
  --ink: #17293b;
  --navy: #213a52;
  --navy-2: #2c4a63;
  --amber: #e0a94a;
  --amber-deep: #c0851f;
  --gold: #e0a94a;
  --gold-deep: #c0851f;
  --sage: #7e9b6b;
  --sage-deep: #5c7a48;
  --terra: #c4513e;
  --muted: #586069;
  --line: #cdd4dc;
  --display: "Fraunces", Georgia, serif;
  --sans: "Work Sans", "Segoe UI", sans-serif;
}

* { margin: 0; padding: 0; box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  font-family: var(--sans); font-weight: 400;
  color: var(--ink); background: var(--paper); line-height: 1.7;
}
img { max-width: 100%; display: block; }
a { color: var(--sage-deep); text-decoration: none; }
a:hover { color: var(--gold-deep); }

h1, h2, h3, .brand-text, .footer-brand { font-family: var(--display); font-weight: 600; line-height: 1.12; }
h1 { font-size: clamp(2.2rem, 5.5vw, 3.6rem); letter-spacing: -0.01em; }
h2 { font-size: clamp(1.6rem, 3.5vw, 2.3rem); }
h3 { font-size: 1.2rem; }
h1 em, h2 em { font-style: italic; color: var(--gold-deep); }

/* ---------- header ---------- */
.site-header {
  position: sticky; top: 0; z-index: 100;
  display: flex; align-items: center; justify-content: space-between;
  gap: 1rem; padding: 0.85rem 5vw;
  background: rgba(249, 250, 252, 0.9);
  border-bottom: 1px solid var(--line);
  backdrop-filter: blur(8px);
}
.brand { display: flex; align-items: center; gap: 0.55rem; color: var(--ink); }
.brand-mark {
  width: 0.85rem; height: 0.85rem; border-radius: 2px;
  background: var(--amber); transform: rotate(45deg);
}
.brand-logo { height: 2.5rem; width: auto; display: block; }
@media (max-width: 640px) { .brand-logo { height: 2.1rem; } }
.brand-text { font-size: 1.3rem; }
.brand-text em { font-style: italic; color: var(--terra); }

.site-nav { display: flex; align-items: center; gap: 1.4rem; }
.site-nav > a {
  font-size: 0.92rem; font-weight: 500; color: var(--ink);
  letter-spacing: 0.02em;
}
.site-nav > a:hover, .site-nav > a.active { color: var(--amber-deep); }
.nav-cta {
  background: var(--navy); color: var(--paper) !important;
  padding: 0.5rem 1.15rem; border-radius: 0.4rem;
}
.nav-cta:hover { background: var(--navy-2); }

.nav-toggle { display: none; background: none; border: 0; cursor: pointer; }
.nav-toggle span {
  display: block; width: 24px; height: 2px; margin: 5px 0;
  background: var(--ink); transition: 0.2s;
}

/* ---------- hero ---------- */
.hero {
  padding: clamp(4rem, 11vw, 7.5rem) 5vw clamp(3rem, 8vw, 5.5rem);
  max-width: 62rem;
}
.hero .eyebrow {
  color: var(--sage-deep); text-transform: uppercase;
  letter-spacing: 0.18em; font-size: 0.78rem; font-weight: 600;
  margin-bottom: 1rem;
}
.hero p.lede {
  font-size: 1.15rem; max-width: 46rem; margin: 1.4rem 0 2rem;
  color: var(--muted);
}
.hero-compact { padding-bottom: 1.5rem; }

/* ---------- buttons ---------- */
.btn {
  display: inline-block; padding: 0.8rem 1.7rem; border-radius: 0.45rem;
  font-family: var(--sans); font-size: 0.95rem; font-weight: 600;
  transition: 0.18s; cursor: pointer; border: 2px solid transparent;
}
.btn-primary { background: var(--amber); color: var(--ink); }
.btn-primary:hover { background: var(--amber-deep); color: var(--ink); }
.btn-dark { background: var(--navy); color: var(--paper); }
.btn-dark:hover { background: var(--navy-2); color: #fff; }
.btn-outline { border-color: var(--navy); color: var(--navy); background: transparent; }
.btn-outline:hover { background: var(--navy); color: var(--paper); }

/* ---------- sections ---------- */
.section { padding: clamp(3rem, 7vw, 5rem) 5vw; }
.section-alt { background: #ffffff; }
.section-dark { background: var(--navy); color: #e8e4dc; }
.section-dark h2, .section-dark h3 { color: #fff; }
.section .eyebrow {
  color: var(--sage-deep); text-transform: uppercase;
  letter-spacing: 0.18em; font-size: 0.75rem; font-weight: 600;
  margin-bottom: 0.5rem;
}
.section-dark .eyebrow { color: var(--amber); }
.section h2 { margin-bottom: 1rem; }
.section p + p { margin-top: 1rem; }
.narrow { max-width: 62rem; margin-inline: auto; }
.center { text-align: center; }
.section ul { margin: 1rem 0 1rem 1.3rem; }
.section li { margin: 0.4rem 0; }

.two-col {
  display: grid; gap: 3rem;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  align-items: start; max-width: 68rem; margin-inline: auto;
}

/* ---------- cards ---------- */
.cards {
  display: grid; gap: 1.4rem; margin-top: 2.2rem;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  max-width: 72rem; margin-inline: auto;
}
.card {
  background: var(--card); border: 1px solid var(--line);
  border-radius: 0.6rem; padding: 1.8rem;
  display: flex; flex-direction: column; gap: 0.7rem;
  box-shadow: 0 1px 2px rgba(28, 36, 49, 0.05);
}
.card h3 { color: var(--navy); }
.card .card-icon { font-size: 1.5rem; }
.card p { font-size: 0.96rem; color: var(--muted); flex: 1; }
.card .card-price {
  font-family: var(--display); font-size: 1.05rem; color: var(--amber-deep);
}
.section-dark .card { background: var(--navy-2); border-color: #3a5872; }
.section-dark .card p { color: #c3ccd8; }

/* ---------- service detail rows ---------- */
.svc {
  display: grid; gap: 2.5rem; align-items: start;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  max-width: 68rem; margin-inline: auto;
  padding: clamp(2.2rem, 5vw, 3.5rem) 0;
  border-bottom: 1px solid var(--line);
}
.svc:last-of-type { border-bottom: 0; }
.svc h2 { font-size: 1.7rem; }
.svc .svc-meta { font-size: 0.95rem; color: var(--amber-deep); font-weight: 600; margin-top: 0.4rem; }
.svc ul { color: var(--muted); }

/* ---------- pricing ---------- */
.pricing-grid {
  display: grid; gap: 1.6rem; margin-top: 2.2rem;
  grid-template-columns: repeat(auto-fit, minmax(290px, 1fr));
  max-width: 72rem; margin-inline: auto;
}
.price-card {
  background: var(--card); border: 1px solid var(--line); border-radius: 0.7rem;
  padding: 2.1rem 1.9rem; display: flex; flex-direction: column;
}
.price-card.featured { border: 2px solid var(--amber); position: relative; }
.price-card.featured::before {
  content: "Most popular"; position: absolute; top: -0.8rem; left: 1.5rem;
  background: var(--amber); color: var(--ink); font-size: 0.72rem; font-weight: 600;
  letter-spacing: 0.08em; text-transform: uppercase;
  padding: 0.2rem 0.7rem; border-radius: 1rem;
}
.price-card .tier-name { font-family: var(--display); font-size: 1.35rem; color: var(--navy); }
.price-card .tier-tag { color: var(--muted); font-size: 0.92rem; margin: 0.2rem 0 1rem; }
.price-card .price {
  font-family: var(--display); font-size: 2rem; color: var(--ink); margin-bottom: 0.2rem;
}
.price-card .price small { font-size: 0.95rem; color: var(--muted); font-family: var(--sans); }
.price-card ul { flex: 1; margin: 1rem 0 1.4rem 1.2rem; color: var(--muted); font-size: 0.95rem; }
.price-note {
  max-width: 62rem; margin: 2rem auto 0; font-size: 0.9rem; color: var(--muted);
}

/* ---------- steps ---------- */
.steps { counter-reset: step; max-width: 62rem; margin: 2rem auto 0; display: grid; gap: 1.4rem; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); }
.step {
  counter-increment: step; background: var(--card);
  border: 1px solid var(--line); border-radius: 0.6rem; padding: 1.6rem;
}
.step::before {
  content: counter(step, decimal-leading-zero);
  font-family: var(--display); font-size: 2rem; color: var(--sage-deep);
  display: block; margin-bottom: 0.4rem;
}
.step h3 { margin-bottom: 0.4rem; }
.step p { font-size: 0.95rem; color: var(--muted); }

/* ---------- case study ---------- */
.case {
  background: var(--navy); color: #e8e4dc; border-radius: 0.9rem;
  padding: clamp(2rem, 5vw, 3.2rem); max-width: 68rem; margin-inline: auto;
}
.case h2 { color: #fff; }
.case .eyebrow { color: var(--amber); }
.case ul { color: #c3ccd8; }
.case .case-footnote { font-size: 0.85rem; color: #8d99a8; margin-top: 1.2rem; }

/* ---------- forms ---------- */
.form-card {
  background: var(--card); border: 1px solid var(--line); border-radius: 0.7rem;
  padding: 2rem; max-width: 34rem;
}
.form-row { margin-bottom: 1rem; }
.form-row label {
  display: block; font-size: 0.8rem; letter-spacing: 0.06em; font-weight: 600;
  text-transform: uppercase; margin-bottom: 0.3rem; color: var(--muted);
}
.form-row input, .form-row textarea, .form-row select {
  width: 100%; padding: 0.7rem 0.85rem; border-radius: 0.4rem;
  border: 1px solid var(--line); background: var(--card);
  font-family: var(--sans); font-size: 0.97rem; color: var(--ink);
}
.form-row input:focus, .form-row textarea:focus, .form-row select:focus {
  outline: 2px solid var(--amber); outline-offset: 1px;
}
.form-status { margin-top: 1rem; font-size: 0.9rem; display: none; }
.form-status.ok { display: block; color: #22803c; }
.form-status.err { display: block; color: #b3261e; }
.hp-field { position: absolute; left: -5000px; }

/* ---------- CTA band ---------- */
.cta-band {
  padding: clamp(2.6rem, 7vw, 4.2rem) 5vw; text-align: center;
  background: linear-gradient(105deg, var(--navy), var(--navy-2) 75%);
  color: #e8e4dc;
}
.cta-band h2 { color: #fff; margin-bottom: 0.6rem; }
.cta-band p { max-width: 56ch; margin: 0 auto 1.6rem; }

/* ---------- footer ---------- */
.site-footer { background: var(--ink); color: #c3ccd8; padding: 3rem 5vw 1.5rem; }
.footer-grid {
  display: grid; gap: 2rem;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  max-width: 68rem; margin-inline: auto;
}
.footer-brand { font-size: 1.3rem; color: #fff; margin-bottom: 0.4rem; }
.footer-brand em { font-style: italic; color: var(--terra); }
.site-footer h3 { color: #fff; font-size: 1rem; margin-bottom: 0.5rem; }
.site-footer a { color: #e8e4dc; }
.site-footer a:hover { color: var(--gold-deep); }
.footer-note { font-size: 0.82rem; color: #8d99a8; margin-top: 0.8rem; }
.footer-legal { text-align: center; margin-top: 2.5rem; font-size: 0.8rem; color: #6d7885; }

/* ---------- responsive ---------- */
@media (max-width: 820px) {
  .nav-toggle { display: block; }
  .site-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 5vw 1rem;
  }
  .site-nav.open { display: flex; }
  .site-nav > a { padding: 0.6rem 0; width: 100%; }
  .nav-cta { text-align: center; margin-top: 0.4rem; }
}
