/* ============================================================
   DriverHQ — Legal pages (Privacy Policy & Terms) stylesheet
   Matches the main site brand system (navy / blue / mint,
   Manrope + DM Sans). Standalone; no build step required.
   ============================================================ */
@import "https://fonts.googleapis.com/css2?family=DM+Sans:wght@400;500;600;700&family=Manrope:wght@400;500;600;700;800&display=swap";

:root {
  --navy: #0b2235;
  --navy-2: #102d44;
  --blue: #1064e8;
  --blue-dark: #0c55c8;
  --blue-light: #e8f1ff;
  --mint: #56d9b7;
  --ink: #102334;
  --muted: #657685;
  --line: #dfe7ed;
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  min-width: 320px;
  margin: 0;
  color: var(--ink);
  background: #fff;
  font-family: "DM Sans", sans-serif;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizelegibility;
  line-height: 1.65;
}

a { color: var(--blue); text-decoration: none; }
a:hover { text-decoration: underline; }

/* ---------- Top navigation ---------- */
.legal-nav {
  position: sticky;
  top: 0;
  z-index: 20;
  background: rgba(255, 255, 255, 0.86);
  backdrop-filter: saturate(160%) blur(12px);
  border-bottom: 1px solid var(--line);
}
.legal-nav-inner {
  max-width: 1000px;
  height: 72px;
  margin: 0 auto;
  padding: 0 24px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.brand {
  color: var(--navy);
  letter-spacing: -1px;
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font: 800 21px/1 Manrope, sans-serif;
}
.brand > span:last-child > span { color: var(--blue); }
.brand-mark {
  background: var(--blue);
  border-radius: 8px;
  display: inline-flex;
  align-items: end;
  gap: 2px;
  width: 27px;
  height: 27px;
  padding: 6px;
  transform: skew(-4deg);
}
.brand-mark span { background: #fff; border-radius: 2px; width: 4px; }
.brand-mark span:first-child { height: 8px; }
.brand-mark span:nth-child(2) { height: 14px; }
.brand-mark span:nth-child(3) { height: 11px; }

.back-home {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  color: #445663;
  font-size: 14px;
  font-weight: 600;
}
.back-home:hover { color: var(--blue); text-decoration: none; }
.back-home svg { width: 16px; height: 16px; }

/* ---------- Hero / header band ---------- */
.legal-hero {
  position: relative;
  overflow: hidden;
  background: linear-gradient(128deg, #f9fcff 18%, #fff 58%, #f4f9ff 100%);
  border-bottom: 1px solid var(--line);
}
.legal-hero::after {
  content: "";
  position: absolute;
  top: -140px;
  right: -120px;
  width: 460px;
  height: 460px;
  border-radius: 50%;
  background: radial-gradient(circle, #4eb1ff2e, #67d5bd0d 50%, transparent 70%);
  pointer-events: none;
}
.legal-hero-inner {
  position: relative;
  max-width: 1000px;
  margin: 0 auto;
  padding: 70px 24px 54px;
}
.eyebrow {
  color: var(--blue);
  text-transform: uppercase;
  letter-spacing: 1.8px;
  display: inline-flex;
  align-items: center;
  gap: 7px;
  font-size: 11px;
  font-weight: 800;
}
.eyebrow svg { width: 14px; height: 14px; }
.legal-hero h1 {
  color: var(--navy);
  font-family: Manrope, sans-serif;
  font-weight: 700;
  letter-spacing: -2.4px;
  font-size: clamp(34px, 4.6vw, 52px);
  line-height: 1.08;
  margin: 16px 0 12px;
}
.legal-hero p.lede {
  color: #5f7180;
  max-width: 640px;
  font-size: 17px;
  margin: 0;
}
.updated-pill {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  margin-top: 22px;
  padding: 7px 14px;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 999px;
  color: #4a5c6a;
  font-size: 12px;
  font-weight: 600;
}
.updated-pill svg { width: 14px; height: 14px; color: var(--blue); }

/* ---------- Body layout ---------- */
.legal-body {
  max-width: 1000px;
  margin: 0 auto;
  padding: 56px 24px 80px;
  display: grid;
  grid-template-columns: 236px 1fr;
  gap: 54px;
  align-items: start;
}

/* Sticky table of contents */
.legal-toc {
  position: sticky;
  top: 96px;
}
.legal-toc strong {
  display: block;
  color: #9fb1be;
  text-transform: uppercase;
  letter-spacing: 1px;
  font-size: 10px;
  margin-bottom: 12px;
}
.legal-toc a {
  display: block;
  color: #5b6b77;
  font-size: 13px;
  font-weight: 600;
  padding: 7px 0 7px 14px;
  border-left: 2px solid var(--line);
  line-height: 1.35;
}
.legal-toc a:hover {
  color: var(--blue);
  border-left-color: var(--blue);
  text-decoration: none;
}

/* Prose */
.legal-content { min-width: 0; }
.legal-content section { scroll-margin-top: 92px; margin-bottom: 42px; }
.legal-content h2 {
  color: var(--navy);
  font-family: Manrope, sans-serif;
  font-weight: 700;
  letter-spacing: -0.8px;
  font-size: 24px;
  margin: 0 0 8px;
  display: flex;
  align-items: center;
  gap: 12px;
}
.legal-content h2 .num {
  flex: none;
  display: grid;
  place-items: center;
  width: 30px;
  height: 30px;
  border-radius: 8px;
  background: var(--blue-light);
  color: var(--blue);
  font: 800 13px Manrope, sans-serif;
}
.legal-content h3 {
  color: var(--navy-2);
  font-family: Manrope, sans-serif;
  font-weight: 700;
  font-size: 16px;
  margin: 22px 0 6px;
}
.legal-content p { color: #46586a; font-size: 15px; margin: 0 0 14px; }
.legal-content ul { margin: 0 0 16px; padding-left: 0; list-style: none; }
.legal-content ul li {
  position: relative;
  color: #46586a;
  font-size: 15px;
  padding: 4px 0 4px 26px;
  line-height: 1.6;
}
.legal-content ul li::before {
  content: "";
  position: absolute;
  left: 3px;
  top: 12px;
  width: 7px;
  height: 7px;
  border-radius: 2px;
  background: var(--mint);
  transform: rotate(45deg);
}
.legal-content strong { color: var(--navy-2); font-weight: 700; }

/* Callout / highlight box */
.callout {
  background: #f3f8fc;
  border: 1px solid #e1ebf3;
  border-left: 4px solid var(--blue);
  border-radius: 10px;
  padding: 16px 18px;
  margin: 0 0 18px;
}
.callout p { margin: 0; color: #3f5568; font-size: 14px; }
.callout strong { color: var(--navy); }

/* Contact card */
.contact-card {
  background: var(--navy);
  border-radius: 16px;
  padding: 30px 32px;
  color: #cdd9e2;
  margin-top: 10px;
}
.contact-card h3 { color: #fff; margin: 0 0 8px; font-size: 18px; }
.contact-card p { color: #9db0bd; margin: 0 0 14px; font-size: 14px; }
.contact-card a { color: #6fb2ff; font-weight: 600; }

/* ---------- Footer ---------- */
.legal-footer {
  color: #587386;
  background: #091e2e;
  padding: 34px max(24px, 50vw - 500px);
}
.legal-footer-inner {
  max-width: 1000px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  font-size: 12px;
}
.legal-footer .brand { color: #fff; font-size: 18px; }
.legal-footer nav { display: flex; gap: 20px; }
.legal-footer nav a { color: #8097a7; }
.legal-footer nav a:hover { color: #fff; text-decoration: none; }

@media (max-width: 820px) {
  .legal-body { grid-template-columns: 1fr; gap: 28px; }
  .legal-toc {
    position: static;
    display: flex;
    flex-wrap: wrap;
    gap: 6px 14px;
    padding-bottom: 18px;
    border-bottom: 1px solid var(--line);
  }
  .legal-toc strong { width: 100%; }
  .legal-toc a { border-left: 0; padding: 4px 0; }
  .legal-footer-inner { flex-direction: column; align-items: flex-start; }
}
