/* ============================================================
   Chiaro site chrome — the ONE header + footer for chiarohq.com.

   Every marketing page links this file and carries the markup from
   scripts/site_chrome.py. Do not copy these rules into a page's inline
   <style>: scripts/apply_site_chrome.py strips chrome rules out of the
   pages it stamps, so a local copy is both redundant and a drift source.

   Two nav variants:
     nav                  light, sticky  (default — every page)
     nav.nav--hero        dark, absolute (landing only, over the video hero)

   Layout relies on .wrap (max-width:1200px; padding:0 32px), which every
   page already defines identically. Colours fall back to literals so this
   sheet still renders correctly on a page with no :root block.
   ============================================================ */

/* ---------- nav: light sticky (default) ---------- */
nav {
  position: sticky;
  top: 0;
  z-index: 20;
  padding: 16px 0;
  background: rgba(246, 242, 233, 0.88);
  backdrop-filter: saturate(160%) blur(14px);
  -webkit-backdrop-filter: saturate(160%) blur(14px);
  border-bottom: 1px solid rgba(17, 17, 17, 0.06);
}
nav .nav-inner {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 32px;
  display: flex;
  flex-direction: row;
  align-items: center;
  justify-content: space-between;
}
nav .brand {
  display: block;
  flex-shrink: 0;
  line-height: 0;
}
nav .brand img {
  height: 30px;
  width: auto;
  display: block;
}
nav .brand .brand-hero { display: none; }
nav .nav-links {
  display: flex;
  flex-direction: row;
  align-items: center;
  gap: 6px;
}
nav .nav-links a.nav-link {
  font-family: var(--sans, 'Geist', -apple-system, sans-serif);
  font-size: 14px;
  line-height: 1.4;
  letter-spacing: normal;
  font-weight: 400;
  color: rgba(17, 17, 17, 0.72);
  text-decoration: none;
  padding: 8px 14px;
  border-radius: 8px;
  transition: color .15s, background .15s;
}
nav .nav-links a.nav-link:hover { color: #111; background: rgba(17, 17, 17, 0.05); }
nav .nav-links a.nav-link[aria-current="page"] { color: #111; background: rgba(17, 17, 17, 0.05); }

/* The nav CTA is fully specified here so it renders identically on pages
   whose local .btn--brand differs (the hub sheet omits the shadow). */
nav .nav-links .btn {
  display: inline-flex;
  align-items: center;
  line-height: 1.4;
  letter-spacing: normal;
  gap: 8px;
  margin-left: 10px;
  padding: 10px 20px;
  border-radius: 100px;
  font-family: var(--sans, 'Geist', -apple-system, sans-serif);
  font-size: 14px;
  font-weight: 500;
  text-decoration: none;
  cursor: pointer;
  background: var(--claude, #166534);
  border: 1px solid var(--claude, #166534);
  color: #fff;
  box-shadow: 0 8px 30px rgba(22, 101, 52, 0.35);
  transition: background .15s, box-shadow .2s ease, transform .15s;
}
nav .nav-links .btn:hover {
  background: #14532D;
  border-color: #14532D;
  transform: translateY(-1px);
}

/* ---------- nav: dark hero variant (landing) ---------- */
nav.nav--hero {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  z-index: 6;
  padding: 22px 0;
  background: transparent;
  backdrop-filter: none;
  -webkit-backdrop-filter: none;
  border-bottom: none;
}
nav.nav--hero .brand .brand-light { display: none; }
nav.nav--hero .brand .brand-hero { display: block; }
nav.nav--hero .nav-links a.nav-link { color: rgba(255, 255, 255, 0.78); }
nav.nav--hero .nav-links a.nav-link:hover,
nav.nav--hero .nav-links a.nav-link[aria-current="page"] {
  color: #fff;
  background: rgba(255, 255, 255, 0.08);
}
nav.nav--hero .nav-toggle span { background: #fff; }
nav.nav--hero .nav-toggle:hover { background: rgba(255, 255, 255, 0.08); }

/* ---------- mobile: hamburger + drawer ---------- */
nav .nav-toggle {
  display: none;
  position: relative;
  width: 40px;
  height: 40px;
  padding: 0;
  border: none;
  background: transparent;
  cursor: pointer;
  border-radius: 10px;
  transition: background .15s;
}
nav .nav-toggle:hover { background: rgba(17, 17, 17, 0.04); }
nav .nav-toggle span {
  position: absolute;
  left: 10px;
  width: 20px;
  height: 1.75px;
  background: var(--ink, #111);
  border-radius: 2px;
  transition: transform .24s ease, opacity .18s ease, top .24s ease;
}
nav .nav-toggle span:nth-child(1) { top: 14px; }
nav .nav-toggle span:nth-child(2) { top: 19px; }
nav .nav-toggle span:nth-child(3) { top: 24px; }
nav .nav-toggle[aria-expanded="true"] span:nth-child(1) { top: 19px; transform: rotate(45deg); }
nav .nav-toggle[aria-expanded="true"] span:nth-child(2) { opacity: 0; }
nav .nav-toggle[aria-expanded="true"] span:nth-child(3) { top: 19px; transform: rotate(-45deg); }

nav .nav-drawer {
  display: none;
  overflow: hidden;
  max-height: 0;
  transition: max-height .28s cubic-bezier(.22, .61, .36, 1);
  border-top: 1px solid rgba(232, 230, 224, 0.6);
  background: rgba(250, 250, 248, 0.98);
  backdrop-filter: saturate(180%) blur(20px);
  -webkit-backdrop-filter: saturate(180%) blur(20px);
}
nav .nav-drawer.open { max-height: 520px; }
nav .nav-drawer-inner {
  max-width: 1200px;
  margin: 0 auto;
  padding: 12px 32px 20px;
  display: flex;
  flex-direction: column;
}
nav .drawer-link {
  font-family: var(--sans, 'Geist', -apple-system, sans-serif);
  font-size: 16px;
  line-height: 1.6;
  letter-spacing: normal;
  font-weight: 500;
  color: var(--ink, #111);
  text-decoration: none;
  padding: 16px 8px;
  border-bottom: 1px solid var(--line, #E5DDD0);
  transition: color .15s;
}
nav .drawer-link:hover { color: var(--claude, #166534); }
nav .drawer-cta {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  line-height: 1.4;
  letter-spacing: normal;
  gap: 8px;
  margin-top: 20px;
  padding: 14px 24px;
  border-radius: 100px;
  background: var(--claude, #166534);
  color: #fff;
  text-decoration: none;
  font-family: var(--sans, 'Geist', -apple-system, sans-serif);
  font-size: 14.5px;
  font-weight: 500;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.10), 0 1px 2px rgba(0, 0, 0, 0.04);
  transition: background .15s, box-shadow .2s ease;
}
nav .drawer-cta:hover {
  background: #14532D;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.14), 0 6px 18px rgba(22, 101, 52, 0.28);
}
nav .nav-drawer .drawer-cta,
nav .nav-drawer .drawer-cta:hover { color: #fff; }

/* The drawer is opaque, so on the landing it needs the light nav treatment
   the moment it opens — otherwise dark-variant links sit on a cream panel. */
nav.nav--hero .nav-drawer .drawer-link { color: var(--ink, #111); }

@media (max-width: 860px) {
  nav .nav-links { display: none; }
  nav .nav-toggle { display: inline-flex; }
  nav .nav-drawer { display: block; }
}
@media (max-width: 640px) {
  nav .nav-inner { padding: 0 20px; }
  nav .nav-drawer-inner { padding: 12px 20px 20px; }
}

/* ---------- footer (dark, every page) ---------- */
.site-footer {
  background: var(--ink, #111);
  color: rgba(255, 255, 255, 0.85);
  padding-top: 72px;
  /* Pinned so a page's own body typography cannot change footer metrics —
     dpa.html sets line-height 1.65 and shifted the chrome by 5px. */
  font-family: var(--sans, 'Geist', -apple-system, sans-serif);
  font-size: 14px;
  line-height: 1.5;
  letter-spacing: normal;
}
.site-footer .wrap { max-width: 1200px; margin: 0 auto; padding: 0 32px; }
.site-footer a { text-decoration: none; }
.site-footer .footer-main {
  display: grid;
  grid-template-columns: minmax(0, 1.4fr) auto;
  gap: 80px;
  padding-bottom: 54px;
  align-items: start;
}
.site-footer .footer-brand-row {
  display: flex;
  align-items: center;
  gap: 11px;
  margin-bottom: 24px;
  flex-wrap: wrap;
}
.site-footer .footer-brand { display: block; line-height: 0; }
.site-footer .footer-brand img { height: 30px; width: auto; display: block; }
.site-footer .footer-ya-pill {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 12px;
  font-weight: 500;
  color: rgba(255, 255, 255, 0.62);
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.15);
  padding: 6px 12px;
  border-radius: 100px;
  transition: color .15s, border-color .15s;
}
.site-footer .footer-ya-pill:hover { color: #fff; border-color: rgba(255, 255, 255, 0.32); }
.site-footer .footer-ya-pill svg { width: 10px; height: 10px; opacity: .7; }
.site-footer .footer-entity {
  font-size: 13px;
  line-height: 1.75;
  color: rgba(255, 255, 255, 0.5);
  max-width: 60ch;
  margin: 0;
}
.site-footer .footer-creds { margin-top: 26px; display: flex; align-items: center; gap: 14px; }
.site-footer .footer-seal { width: 62px; height: 62px; flex-shrink: 0; display: block; }
.site-footer .footer-seal img { width: 100%; height: 100%; object-fit: contain; }
.site-footer .footer-reg { display: flex; flex-direction: column; gap: 2px; }
.site-footer .footer-reg-num { font-size: 13px; line-height: 1.5; color: rgba(255, 255, 255, 0.55); }
.site-footer .footer-reg-lab {
  font-size: 13px;
  line-height: 1.5;
  color: rgba(255, 255, 255, 0.55);
  display: inline-flex;
  align-items: center;
  gap: 6px;
  transition: color .15s;
}
.site-footer .footer-reg-lab:hover { color: #fff; }
.site-footer .footer-reg-lab svg {
  width: 9px;
  height: 9px;
  flex-shrink: 0;
  opacity: .62;
  transition: opacity .15s, transform .18s ease;
}
.site-footer .footer-reg-lab:hover svg { opacity: 1; transform: translate(1px, -1px); }
.site-footer .footer-right {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 36px;
}
.site-footer .footer-cols { display: flex; gap: 46px; flex-wrap: wrap; justify-content: flex-end; }
.site-footer .footer-col h4 {
  font-size: 12px;
  font-weight: 600;
  letter-spacing: .04em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.4);
  margin: 0 0 15px;
}
.site-footer .footer-col ul {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 11px;
}
.site-footer .footer-col a { font-size: 14px; line-height: 1.4; color: rgba(255, 255, 255, 0.68); transition: color .15s; }
.site-footer .footer-col a:hover { color: #fff; }
.site-footer .footer-socials { display: flex; gap: 10px; }
.site-footer .footer-socials a {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 38px;
  height: 38px;
  border-radius: 10px;
  border: 1px solid rgba(255, 255, 255, 0.12);
  color: rgba(255, 255, 255, 0.5);
  transition: color .15s, border-color .15s, background .15s, transform .15s;
}
.site-footer .footer-socials a:hover {
  color: #fff;
  border-color: rgba(255, 255, 255, 0.3);
  background: rgba(255, 255, 255, 0.05);
  transform: translateY(-1px);
}
.site-footer .footer-socials svg { width: 15px; height: 15px; }
.site-footer .footer-bottom {
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  padding: 24px 0;
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 13px;
  color: rgba(255, 255, 255, 0.45);
  gap: 18px;
  flex-wrap: wrap;
}
.site-footer .footer-bottom a { color: rgba(255, 255, 255, 0.45); }
.site-footer .footer-bottom a:hover { color: #fff; }
.site-footer .footer-bottom .fb-links { display: flex; gap: 22px; }

@media (max-width: 860px) {
  .site-footer .footer-main { grid-template-columns: 1fr; gap: 48px; }
  .site-footer .footer-right { align-items: flex-start; }
  .site-footer .footer-cols { justify-content: flex-start; gap: 38px; }
}
@media (max-width: 640px) {
  .site-footer .wrap { padding: 0 20px; }
}
