/* =====================================================
   Dominion Shield Group — Design System
   Palette: Navy / Gold / White / Light Gray
   Type: Space Grotesk (headings) + Inter (body)
   ===================================================== */

:root {
  /* Color tokens */
  --navy-950: #081120;
  --navy-900: #0A1628;
  --navy-800: #10203A;
  --navy-700: #1A2F4F;
  --navy-100: #E8EDF4;
  --gold-500: #C9A227;
  --gold-400: #D9B64A;
  --gold-600: #A8861C;
  --white: #FFFFFF;
  --gray-050: #F7F8FA;
  --gray-100: #EEF1F4;
  --gray-200: #DDE2E8;
  --gray-400: #9AA5B1;
  --gray-500: #66707C;
  --gray-700: #3C4550;
  --ink: #131A22;

  /* Type */
  --font-display: "Space Grotesk", "Segoe UI", sans-serif;
  --font-body: "Inter", "Helvetica Neue", Arial, sans-serif;

  /* Scale */
  --text-xs: 0.75rem;
  --text-sm: 0.875rem;
  --text-base: 1rem;
  --text-lg: 1.125rem;
  --text-xl: 1.375rem;
  --text-2xl: 1.75rem;
  --text-3xl: 2.25rem;
  --text-4xl: 3rem;
  --text-5xl: 3.75rem;

  /* Layout */
  --container: 1200px;
  --container-narrow: 820px;
  --section-pad: 7.5rem;
  --radius: 2px;

  --shadow-card: 0 1px 2px rgba(8, 17, 32, 0.06), 0 8px 24px rgba(8, 17, 32, 0.07);
  --transition: 180ms cubic-bezier(0.4, 0, 0.2, 1);
}

/* ---------- Reset ---------- */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body {
  font-family: var(--font-body);
  font-size: var(--text-base);
  line-height: 1.65;
  color: var(--ink);
  background: var(--white);
  -webkit-font-smoothing: antialiased;
}
img, svg, video { display: block; max-width: 100%; }
a { color: inherit; text-decoration: none; }
ul[role="list"] { list-style: none; }
button { font: inherit; cursor: pointer; }

/* Accessibility */
.skip-link {
  position: absolute; left: -999px; top: 0;
  background: var(--gold-500); color: var(--navy-900);
  padding: 0.75rem 1.25rem; z-index: 200; font-weight: 600;
}
.skip-link:focus { left: 0; }
:focus-visible { outline: 2px solid var(--gold-500); outline-offset: 3px; }
.visually-hidden {
  position: absolute; width: 1px; height: 1px; overflow: hidden;
  clip: rect(0 0 0 0); white-space: nowrap;
}
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation: none !important; transition: none !important; }
  .reveal { opacity: 1 !important; transform: none !important; }
}

/* ---------- Typography ---------- */
h1, h2, h3, h4 {
  font-family: var(--font-display);
  font-weight: 600;
  line-height: 1.15;
  letter-spacing: -0.015em;
  color: var(--navy-900);
}
h1 { font-size: clamp(2.4rem, 5vw, var(--text-5xl)); }
h2 { font-size: clamp(1.9rem, 3.5vw, var(--text-4xl)); }
h3 { font-size: var(--text-xl); }
h4 { font-size: var(--text-lg); }
p { max-width: 68ch; }
.lead { font-size: var(--text-lg); color: var(--gray-700); }

/* Eyebrow with the gold keyline — DSG's signature device */
.eyebrow {
  display: inline-flex; align-items: center; gap: 0.75rem;
  font-family: var(--font-display);
  font-size: var(--text-sm);
  font-weight: 500;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--gold-600);
  margin-bottom: 1.25rem;
}
.eyebrow::before {
  content: ""; width: 2.25rem; height: 2px; background: var(--gold-500);
}
.on-dark .eyebrow { color: var(--gold-400); }

/* ---------- Layout ---------- */
.container { max-width: var(--container); margin-inline: auto; padding-inline: 1.5rem; }
.container-narrow { max-width: var(--container-narrow); margin-inline: auto; padding-inline: 1.5rem; }
.section { padding-block: var(--section-pad); }
.section-tight { padding-block: 5rem; }
.section-gray { background: var(--gray-050); }
.section-navy { background: var(--navy-900); color: var(--navy-100); }
.section-navy h2, .section-navy h3 { color: var(--white); }
.section-navy p { color: var(--navy-100); }
.section-head { max-width: 720px; margin-bottom: 3.5rem; }
.grid { display: grid; gap: 2rem; }
.grid-2 { grid-template-columns: repeat(2, 1fr); }
.grid-3 { grid-template-columns: repeat(3, 1fr); }
.grid-4 { grid-template-columns: repeat(4, 1fr); }
@media (max-width: 960px) {
  .grid-3, .grid-4 { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 640px) {
  :root { --section-pad: 4.5rem; }
  .grid-2, .grid-3, .grid-4 { grid-template-columns: 1fr; }
}

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex; align-items: center; gap: 0.6rem;
  font-family: var(--font-display); font-weight: 500;
  font-size: var(--text-sm); letter-spacing: 0.06em; text-transform: uppercase;
  padding: 0.95rem 1.9rem; border: 1px solid transparent; border-radius: var(--radius);
  transition: background var(--transition), color var(--transition), border-color var(--transition);
}
.btn-gold { background: var(--gold-500); color: var(--navy-950); }
.btn-gold:hover { background: var(--gold-400); }
.btn-outline { border-color: var(--gray-200); color: var(--navy-900); background: transparent; }
.btn-outline:hover { border-color: var(--navy-900); }
.on-dark .btn-outline, .section-navy .btn-outline, .btn-outline.on-dark { border-color: rgba(255,255,255,0.35); color: var(--white); }
.on-dark .btn-outline:hover, .section-navy .btn-outline:hover, .btn-outline.on-dark:hover { border-color: var(--gold-400); color: var(--gold-400); }
.btn-link {
  font-family: var(--font-display); font-weight: 500; font-size: var(--text-sm);
  letter-spacing: 0.06em; text-transform: uppercase; color: var(--navy-900);
  border-bottom: 2px solid var(--gold-500); padding-bottom: 0.2rem;
}
.btn-link:hover { color: var(--gold-600); }

/* ---------- Header ---------- */
.site-header {
  position: sticky; top: 0; z-index: 100;
  background: rgba(10, 22, 40, 0.96);
  backdrop-filter: blur(8px);
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}
.header-inner {
  display: flex; align-items: center; justify-content: space-between;
  min-height: 76px; padding-block: 0.6rem; max-width: var(--container); margin-inline: auto; padding-inline: 1.5rem;
}
.brand { display: flex; align-items: center; gap: 1.1rem; color: var(--white); }
.brand-mark { width: 95px; height: 105px; flex: none; }
.brand-name {
  font-family: var(--font-display); font-weight: 600; font-size: 1.55rem;
  letter-spacing: 0.02em; line-height: 1.1;
}
.brand-name span { display: block; font-size: 0.8rem; font-weight: 500; letter-spacing: 0.22em; color: var(--gold-400); text-transform: uppercase; margin-top: 0.3rem; }
@media (max-width: 560px) {
  .brand-mark { width: 66px; height: 73px; }
  .brand-name { font-size: 1.15rem; }
  .brand-name span { font-size: 0.62rem; letter-spacing: 0.16em; }
}
.nav { display: flex; align-items: center; gap: 2rem; }
.nav a {
  font-family: var(--font-display); font-size: var(--text-sm); font-weight: 500;
  color: var(--navy-100); letter-spacing: 0.04em; padding-block: 0.5rem;
  border-bottom: 2px solid transparent; transition: color var(--transition);
}
.nav a:hover, .nav a[aria-current="page"] { color: var(--gold-400); border-bottom-color: var(--gold-500); }
.nav .btn { padding: 0.65rem 1.3rem; }
.nav-toggle { display: none; background: none; border: 0; color: var(--white); width: 44px; height: 44px; }
.nav-toggle svg { margin: auto; }

/* Dropdown (Capabilities) */
.nav-item { position: relative; }
.nav-dropdown {
  position: absolute; top: calc(100% + 0.75rem); left: 50%; transform: translateX(-50%);
  min-width: 260px; background: var(--white); border-radius: var(--radius);
  box-shadow: var(--shadow-card); border-top: 3px solid var(--gold-500);
  padding: 0.5rem 0; display: none;
}
.nav-item:hover .nav-dropdown, .nav-item:focus-within .nav-dropdown { display: block; }
.nav-dropdown a {
  display: block; padding: 0.7rem 1.4rem; color: var(--navy-900);
  border-bottom: 0; font-weight: 500;
}
.nav-dropdown a:hover { background: var(--gray-050); color: var(--gold-600); }

@media (max-width: 960px) {
  .nav-toggle { display: block; }
  .nav {
    position: fixed; top: var(--header-h, 132px); right: 0; bottom: 0; left: 0; background: var(--navy-950);
    flex-direction: column; align-items: flex-start; gap: 0;
    padding: 1.5rem; display: none; overflow-y: auto;
  }
  .nav.open { display: flex; }
  .nav > a, .nav-item { width: 100%; }
  .nav a { display: block; padding: 0.9rem 0; font-size: var(--text-lg); border-bottom: 1px solid rgba(255,255,255,0.07); }
  .nav-dropdown { position: static; transform: none; display: block; background: transparent; box-shadow: none; border-top: 0; padding-left: 1rem; }
  .nav-dropdown a { color: var(--gray-400); font-size: var(--text-base); }
  .nav .btn { margin-top: 1.25rem; }
}

/* ---------- Hero ---------- */
.hero {
  position: relative; background: var(--navy-950); color: var(--white);
  padding-block: 9rem 8rem; overflow: hidden;
}
.hero::before {
  content: ""; position: absolute; inset: 0;
  background-image:
    linear-gradient(rgba(201,162,39,0.05) 1px, transparent 1px),
    linear-gradient(90deg, rgba(201,162,39,0.05) 1px, transparent 1px);
  background-size: 72px 72px;
  mask-image: radial-gradient(ellipse 90% 80% at 30% 20%, black 30%, transparent 75%);
}
.hero::after {
  content: ""; position: absolute; inset: 0;
  background: radial-gradient(ellipse 60% 70% at 80% 100%, rgba(26,47,79,0.9), transparent 65%);
}
.hero-inner {
  position: relative; z-index: 1; max-width: var(--container); margin-inline: auto; padding-inline: 1.5rem;
  display: grid; grid-template-columns: 1.15fr 1fr; gap: 3.5rem; align-items: center;
}
.hero-copy { min-width: 0; }
.hero-media {
  position: relative; align-self: stretch; min-height: 380px; border-radius: var(--radius);
  overflow: hidden; border: 1px solid rgba(201,162,39,0.35);
}
.hero-media img { width: 100%; height: 100%; object-fit: cover; display: block; }
.hero-media::after {
  content: ""; position: absolute; inset: 0;
  background: linear-gradient(155deg, rgba(8,17,32,0.55), rgba(8,17,32,0.15) 55%, rgba(201,162,39,0.12));
}
.hero-media::before {
  content: ""; position: absolute; inset: 0; z-index: 2; pointer-events: none;
  border: 1px solid rgba(201,162,39,0.5); box-shadow: inset 0 0 0 1px rgba(8,17,32,0.4);
}
@media (max-width: 900px) {
  .hero-inner { grid-template-columns: 1fr; gap: 2.5rem; }
  .hero-media { min-height: 240px; order: 2; }
  .hero-copy { order: 1; }
}
.hero h1 { color: var(--white); max-width: 15ch; }
.hero .lead { color: var(--navy-100); max-width: 52ch; margin-top: 1.5rem; }
.hero-actions { display: flex; flex-wrap: wrap; gap: 1rem; margin-top: 2.75rem; }
.hero-kicker {
  display: inline-flex; align-items: center; gap: 0.75rem;
  font-family: var(--font-display); font-size: var(--text-sm); font-weight: 500;
  letter-spacing: 0.2em; text-transform: uppercase; color: var(--gold-400);
  margin-bottom: 1.75rem;
}
.hero-kicker::before { content: ""; width: 2.25rem; height: 2px; background: var(--gold-500); }

/* Page hero (interior pages) */
.page-hero {
  background: var(--navy-900); color: var(--white);
  padding-block: 6rem 4.5rem; border-bottom: 3px solid var(--gold-500);
}
.page-hero h1 { color: var(--white); }
.page-hero .lead { color: var(--navy-100); margin-top: 1rem; }
.breadcrumbs { font-size: var(--text-sm); color: var(--gray-400); margin-bottom: 1.5rem; }
.breadcrumbs a:hover { color: var(--gold-400); }
.breadcrumbs [aria-current] { color: var(--navy-100); }

/* ---------- Cards ---------- */
.card {
  background: var(--white); border: 1px solid var(--gray-200);
  border-radius: var(--radius); padding: 2.25rem;
  transition: border-color var(--transition), box-shadow var(--transition), transform var(--transition);
}
.card:hover { border-color: var(--gold-500); box-shadow: var(--shadow-card); transform: translateY(-3px); }
.card h3 { margin-bottom: 0.75rem; }
.card p { font-size: var(--text-sm); color: var(--gray-700); }
.card .btn-link { margin-top: 1.5rem; display: inline-block; }
.card-icon {
  width: 46px; height: 46px; margin-bottom: 1.5rem;
  color: var(--gold-600);
}
.card-list { margin-top: 1.25rem; display: grid; gap: 0.5rem; font-size: var(--text-sm); color: var(--gray-700); }
.card-list li { display: flex; gap: 0.6rem; align-items: baseline; list-style: none; }
.card-list li::before { content: ""; flex: none; width: 6px; height: 6px; background: var(--gold-500); transform: translateY(-2px); }

/* Dark stat band */
.stat-band { display: grid; grid-template-columns: repeat(4, 1fr); gap: 2rem; }
.stat-band .stat h3 { font-size: var(--text-3xl); color: var(--gold-400); }
.stat-band .stat p { font-size: var(--text-sm); letter-spacing: 0.08em; text-transform: uppercase; margin-top: 0.4rem; }
@media (max-width: 800px) { .stat-band { grid-template-columns: repeat(2, 1fr); } }

/* Value list (About) */
.value-row { display: flex; gap: 1.5rem; padding: 1.75rem 0; border-bottom: 1px solid var(--gray-200); }
.value-row:first-child { border-top: 1px solid var(--gray-200); }
.value-num { font-family: var(--font-display); color: var(--gold-600); font-weight: 500; min-width: 2.5rem; }
.value-row h3 { margin-bottom: 0.35rem; font-size: var(--text-lg); }

/* News cards */
.news-card { display: flex; flex-direction: column; overflow: hidden; padding: 0; }
.news-media { aspect-ratio: 16/9; background: linear-gradient(135deg, var(--navy-800), var(--navy-950)); position: relative; }
.news-media::after {
  content: "Image via War.gov"; position: absolute; inset: auto 0 0 0;
  font-size: 0.7rem; color: var(--gray-400); padding: 0.4rem 0.8rem;
  background: rgba(8,17,32,0.65);
}
.news-body { padding: 1.75rem; display: flex; flex-direction: column; flex: 1; }
.news-date { font-size: var(--text-xs); letter-spacing: 0.1em; text-transform: uppercase; color: var(--gray-500); margin-bottom: 0.6rem; }
.news-body h3 { font-size: var(--text-lg); margin-bottom: 0.6rem; }
.news-body p { flex: 1; }
.news-attrib { font-size: var(--text-xs); color: var(--gray-500); margin-top: 2rem; }

/* ---------- Forms ---------- */
.form { display: grid; gap: 1.4rem; }
.form-row { display: grid; gap: 1.4rem; grid-template-columns: 1fr 1fr; }
@media (max-width: 640px) { .form-row { grid-template-columns: 1fr; } }
.field label { display: block; font-weight: 500; font-size: var(--text-sm); margin-bottom: 0.45rem; color: var(--navy-900); }
.field .req { color: var(--gold-600); }
.field input, .field select, .field textarea {
  width: 100%; padding: 0.85rem 1rem; font: inherit;
  border: 1px solid var(--gray-200); border-radius: var(--radius); background: var(--white);
  transition: border-color var(--transition);
}
.field input:focus, .field select:focus, .field textarea:focus {
  outline: none; border-color: var(--gold-500); box-shadow: 0 0 0 3px rgba(201,162,39,0.18);
}
.field textarea { min-height: 140px; resize: vertical; }
.field-error { display: none; font-size: var(--text-sm); color: #B4231F; margin-top: 0.4rem; }
.field.invalid input, .field.invalid select, .field.invalid textarea { border-color: #B4231F; }
.field.invalid .field-error { display: block; }
.form-note { font-size: var(--text-xs); color: var(--gray-500); }
.hp-field { position: absolute; left: -9999px; opacity: 0; height: 0; overflow: hidden; }
.form-success {
  display: none; background: var(--gray-050); border-left: 3px solid var(--gold-500);
  padding: 1.25rem 1.5rem; font-weight: 500;
}

/* Tabs on contact page */
.form-tabs { display: flex; flex-wrap: wrap; gap: 0.5rem; margin-bottom: 2.5rem; }
.form-tab {
  border: 1px solid var(--gray-200); background: var(--white); border-radius: var(--radius);
  padding: 0.7rem 1.3rem; font-family: var(--font-display); font-weight: 500; font-size: var(--text-sm);
}
.form-tab[aria-selected="true"] { background: var(--navy-900); color: var(--white); border-color: var(--navy-900); }
.form-panel[hidden] { display: none; }

/* ---------- CTA band ---------- */
.cta-band {
  background: var(--navy-900); border-top: 3px solid var(--gold-500);
  color: var(--white); text-align: left;
}
.cta-band .container { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 2rem; }
.cta-band h2 { color: var(--white); max-width: 22ch; }
.cta-band p { color: var(--navy-100); margin-top: 0.75rem; }

/* ---------- Footer ---------- */
.site-footer { background: var(--navy-950); color: var(--gray-400); font-size: var(--text-sm); }
.footer-main {
  display: grid; grid-template-columns: 2fr 1fr 1fr 1.2fr; gap: 3rem;
  padding-block: 4.5rem 3rem; border-bottom: 1px solid rgba(255,255,255,0.08);
}
.footer-main h4 {
  color: var(--white); font-size: var(--text-sm); letter-spacing: 0.12em;
  text-transform: uppercase; margin-bottom: 1.25rem;
}
.footer-main ul { display: grid; gap: 0.65rem; }
.footer-main a:hover { color: var(--gold-400); }
.footer-brand p { margin-top: 1.25rem; max-width: 34ch; }
.footer-legal {
  display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between;
  gap: 1rem; padding-block: 1.75rem; font-size: var(--text-xs);
}
.footer-legal ul { display: flex; flex-wrap: wrap; gap: 1.5rem; }
.footer-legal a:hover { color: var(--gold-400); }
@media (max-width: 900px) { .footer-main { grid-template-columns: 1fr 1fr; } }
@media (max-width: 560px) { .footer-main { grid-template-columns: 1fr; } }

/* ---------- Reveal on scroll (subtle) ---------- */
.reveal { opacity: 0; transform: translateY(18px); transition: opacity 500ms ease, transform 500ms ease; }
.reveal.in { opacity: 1; transform: none; }

/* ---------- Misc ---------- */
.two-col { display: grid; grid-template-columns: 1fr 1fr; gap: 4rem; align-items: start; }
@media (max-width: 900px) { .two-col { grid-template-columns: 1fr; } }
.checklist { display: grid; gap: 0.85rem; }
.checklist li { display: flex; gap: 0.85rem; list-style: none; align-items: baseline; }
.checklist li::before {
  content: "✓"; color: var(--gold-600); font-weight: 700; flex: none;
}
.notice {
  background: var(--gray-050); border-left: 3px solid var(--gold-500);
  padding: 1.5rem 1.75rem; font-size: var(--text-sm); color: var(--gray-700);
}
.prose h2 { margin: 2.75rem 0 1rem; font-size: var(--text-2xl); }
.prose h3 { margin: 2rem 0 0.75rem; }
.prose p, .prose ul, .prose ol { margin-bottom: 1rem; color: var(--gray-700); }
.prose ul, .prose ol { padding-left: 1.4rem; }
.prose li { margin-bottom: 0.4rem; }
.updated { font-size: var(--text-sm); color: var(--gray-500); margin-bottom: 2.5rem; }

/* 404 */
.err-page { text-align: center; padding-block: 10rem; }
.err-code { font-family: var(--font-display); font-size: 6rem; font-weight: 600; color: var(--gray-200); line-height: 1; }
.err-page h1 { margin-top: 1rem; }
.err-page .hero-actions { justify-content: center; }

/* Cookie banner */
.cookie-banner {
  position: fixed; inset: auto 1rem 1rem 1rem; z-index: 150;
  background: var(--navy-950); color: var(--navy-100);
  border: 1px solid rgba(255,255,255,0.12); border-radius: var(--radius);
  padding: 1.5rem; max-width: 560px; margin-left: auto;
  box-shadow: 0 16px 48px rgba(0,0,0,0.4); display: none;
}
.cookie-banner.show { display: block; }
.cookie-banner p { font-size: var(--text-sm); }
.cookie-actions { display: flex; gap: 0.75rem; margin-top: 1.25rem; flex-wrap: wrap; }
