/* Shared Kmeggie+ palette and grouped footer. */
:root {
  --navy: #041f3b;
  --navy-2: #0a4470;
  --red: #a80f2e;
  --red-dark: #650a20;
  --ink: #0a1e31;
  --muted: #2c4254;
  --line: #9cb3c5;
  --paper: #fff;
  --cream: #fff;
  --pale: #e5eff6;
}

html, body.content-site, body.qc-page { background: #fff; }

body.qc-page {
  --ink: #041f3b;
  --paper: #fff;
  --accent: #a80f2e;
  --muted: #2c4254;
  --line: #9cb3c5;
}

.lab-header { border-bottom-color: var(--line); }
.utility-bar { background: #041f3b; }
.primary-nav .pilot-nav, .button.primary { background: var(--red); border-color: var(--red); color: #fff; }
.primary-nav .pilot-nav:hover, .button.primary:hover { background: var(--red-dark); }
.page-home .hero-bleed { background: #041f3b; }
.page-home .hero-bleed::before {
  background: linear-gradient(90deg, rgba(5, 27, 53, .97) 0%, rgba(5, 27, 53, .88) 45%, rgba(5, 27, 53, .38) 80%, rgba(5, 27, 53, .16) 100%);
}

body.qc-page .input-panel, body.qc-page .dropzone { background: #fff; }
body.qc-page .input-panel { border-top-color: var(--navy); }

.lab-footer, body.qc-page .lab-footer {
  display: block;
  margin: 0;
  background: #061e39;
  color: #edf4fb;
  border: 0;
  border-top: 6px solid #a80f2e;
  padding: 66px 0 25px;
  font: 15px/1.55 Arial, Helvetica, sans-serif;
}

.lab-footer .footer-grid {
  display: grid;
  grid-template-columns: minmax(235px, 1.3fr) repeat(4, minmax(0, 1fr));
  gap: 32px;
  align-items: start;
}

.lab-footer .footer-brand .wordmark { color: #fff; }
.lab-footer .footer-brand .wordmark > span { color: #ffcf6f; }
.lab-footer .footer-brand p {
  color: #dce7f1;
  font: 17px/1.55 Georgia, "Times New Roman", serif;
  max-width: 260px;
  margin: 20px 0 10px;
}
.lab-footer .footer-brand address { color: #b9ccdc; font-style: normal; font-size: 14px; }

.lab-footer .footer-group {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 11px;
  min-width: 0;
  border: 0;
}
.lab-footer .footer-group strong {
  color: #fff;
  font: 700 14px/1.4 Arial, Helvetica, sans-serif;
  letter-spacing: .09em;
  text-transform: uppercase;
  margin: 3px 0 9px;
}
.lab-footer .footer-group a, body.qc-page .lab-footer .footer-group a {
  color: #d9e5ef;
  font: 15px/1.4 Arial, Helvetica, sans-serif;
  text-decoration: none;
  padding: 0;
  border: 0;
  overflow-wrap: anywhere;
  white-space: normal;
}
.lab-footer .footer-group a:hover, .lab-footer .footer-group a:focus-visible {
  color: #ffcf6f;
  text-decoration: underline;
  text-underline-offset: 4px;
}
.lab-footer a:focus-visible { outline-color: #ffcf6f; }

.lab-footer .footer-base {
  border-top: 1px solid #506882;
  color: #cbd9e6;
  margin-top: 48px;
  padding-top: 20px;
  display: flex;
  flex-wrap: wrap;
  gap: 12px 30px;
  justify-content: space-between;
  font-size: 13px;
}
.lab-footer .footer-base a, body.qc-page .lab-footer .footer-base a {
  color: #ffd176;
  font-weight: 700;
  text-decoration: none;
}
.lab-footer .footer-base a:hover { text-decoration: underline; text-underline-offset: 4px; }
.lab-footer .footer-home-links {
  color: #d5e3ee;
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
  font-size: 13px;
  margin: 18px auto 0;
}
.lab-footer .footer-home-links a { color: #ffd176; text-decoration: none; }
.lab-footer .footer-home-links a:hover { text-decoration: underline; text-underline-offset: 4px; }

@media (max-width: 1080px) {
  .lab-footer .footer-grid { grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 28px; }
  .lab-footer .footer-brand { grid-column: 1 / -1; border-bottom: 1px solid #506882; padding-bottom: 24px; }
}
@media (max-width: 700px) {
  .lab-footer .footer-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 29px 18px; }
  .lab-footer .footer-brand, .lab-footer .footer-group:last-child { grid-column: 1 / -1; }
  .lab-footer .footer-base { flex-direction: column; gap: 7px; }
  .page-home .hero-bleed::before { background: rgba(5, 27, 53, .88); }
}
@media (max-width: 380px) {
  .lab-footer .footer-grid { grid-template-columns: 1fr; }
  .lab-footer .footer-brand, .lab-footer .footer-group:last-child { grid-column: 1; }
}
