/* Shared page chrome for every responsiveppc.com page: header, footer, and the
   lead form dialog. Built on the tokens in /styles.css. */

html { scroll-behavior: smooth; }
.site-page { font-size: 16px; line-height: 1.6; overflow-x: hidden; }
.site-page [hidden] { display: none !important; }

/* — header — */
.site-header {
  position: sticky; top: 0; z-index: 20;
  background: color-mix(in srgb, var(--color-bg) 92%, transparent);
  backdrop-filter: blur(8px);
}
.site-nav { max-width: 1200px; margin: 0 auto; display: flex; align-items: center; gap: 28px; padding: 16px clamp(16px, 5vw, 56px); }
.site-brand {
  display: flex; align-items: center; gap: 10px; margin-right: auto;
  font-family: var(--font-heading); font-size: 20px; color: var(--color-text); text-decoration: none;
}
.site-brand-mark { width: 30px; height: 30px; border-radius: 50%; background: var(--color-accent); display: grid; place-items: center; }
.site-brand-mark span { width: 12px; height: 12px; border-radius: 50%; background: var(--color-bg); }
.site-nav-links { display: flex; gap: 26px; font-size: 15px; font-weight: 600; }
.site-nav-links a { color: var(--color-text); text-decoration: none; }
.site-nav-links a:hover, .site-nav-links a[aria-current="page"] { color: var(--color-accent-700); }
.site-nav-cta { white-space: nowrap; font-size: 14px; padding: 10px 18px; }
@media (max-width: 899px) { .site-nav-links { display: none; } }
@media (max-width: 420px) {
  .site-nav { gap: 12px; }
  .site-brand { font-size: 18px; gap: 8px; }
  .site-nav-cta { padding: 9px 14px; }
}
@media (max-width: 359px) {
  .site-brand { font-size: 16px; }
  .site-brand-mark { width: 26px; height: 26px; }
  .site-nav-cta { font-size: 13px; padding: 8px 12px; }
}

/* — footer — */
.site-footer {
  max-width: 1200px; margin: 0 auto; padding: 28px clamp(16px, 5vw, 56px) 40px;
  display: flex; flex-wrap: wrap; gap: 12px 24px; justify-content: space-between;
  font-size: 14px; color: var(--color-neutral-700);
}
.site-footer-brand { font-family: var(--font-heading); color: var(--color-text); }

/* — lead form (native <dialog>) — */
.lead {
  width: min(560px, calc(100% - 24px)); max-height: calc(100% - 24px); margin: clamp(12px, 4vh, 48px) auto auto;
  padding: 0; border: 0; border-radius: 32px; background: var(--color-bg); color: var(--color-text);
  box-shadow: var(--shadow-lg); overflow-y: auto;
}
.lead::backdrop { background: color-mix(in srgb, var(--color-neutral-900) 55%, transparent); }
.lead-inner { position: relative; padding: clamp(22px, 4vw, 36px); }
.lead-close {
  position: absolute; top: 16px; right: 16px; width: 40px; height: 40px; border-radius: 50%; border: 0;
  background: var(--color-surface); cursor: pointer; display: grid; place-items: center; color: var(--color-text);
}
.lead-close:hover { background: var(--color-neutral-300); }
.lead-who { display: flex; align-items: center; gap: 12px; margin-bottom: 14px; padding-right: 44px; font-size: 14px; color: var(--color-neutral-700); }
.lead-avatar {
  width: 44px; height: 44px; border-radius: 50%; flex: none; background: var(--color-accent-200);
  display: grid; place-items: center; font-family: var(--font-heading); font-size: 20px; color: var(--color-accent-800);
}
.lead h3 { font-size: 26px; margin: 0 0 20px; padding-right: 44px; }
.lead form { display: flex; flex-direction: column; gap: 18px; }
.lead fieldset { border: 0; margin: 0; padding: 0; min-width: 0; }
.lead legend, .lead .field > label { display: block; font-size: 14px; font-weight: 700; color: var(--color-text); margin-bottom: 8px; padding: 0; }
.lead .opt { font-weight: 400; color: var(--color-neutral-700); }
.lead-pills { display: flex; flex-wrap: wrap; gap: 8px; }
.lead-pill { position: relative; }
.lead-pill input { position: absolute; opacity: 0; width: 1px; height: 1px; }
.lead-pill span {
  display: inline-block; border-radius: 999px; padding: 10px 16px; font: 600 14px var(--font-body); cursor: pointer;
  border: 1.5px solid var(--color-neutral-300); background: var(--color-neutral-100); color: var(--color-text);
}
.lead-pill span:hover { border-color: var(--color-accent); }
.lead-pill input:checked + span { background: var(--color-accent); border-color: var(--color-accent); color: var(--color-bg); }
.lead-pill input:focus-visible + span { outline: 2px solid var(--color-accent); outline-offset: 2px; }
.lead .input { min-height: 46px; font-size: 15px; }
.lead select.input { appearance: auto; }
.lead textarea.input { border-radius: 20px; padding: 12px 14px; min-height: 96px; }
.lead-row { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(200px, 100%), 1fr)); gap: 18px; }
.lead-submit { font-size: 17px; padding: 16px 24px; }
.lead-err { color: var(--color-danger); font-size: 14px; font-weight: 600; margin: 0; }
.lead-err:empty { display: none; }
.lead-hp { position: absolute; left: -9999px; }
.lead-step { padding: 12px 0; display: flex; flex-direction: column; gap: 14px; }
.lead-step h3 { font-size: 28px; margin: 0; }
.lead-step p { font-size: 16px; color: var(--color-neutral-800); margin: 0; }
.lead-done-icon { width: 56px; height: 56px; border-radius: 50%; background: var(--color-accent-2-200); color: var(--color-accent-2-800); display: grid; place-items: center; }
.lead-actions { display: flex; flex-wrap: wrap; gap: 10px; }
.lead-actions .btn { font-size: 15px; padding: 12px 20px; }

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