/* ==========================================================================
   KAC Expedite – site styles
   ========================================================================== */

@font-face {
  font-family: "Inter";
  font-style: normal;
  font-weight: 400 800;
  font-display: swap;
  src: url("assets/fonts/inter-latin-var.woff2") format("woff2");
}

:root {
  --navy: #071f42;
  --navy-700: #0c2b58;
  --navy-600: #143a70;
  --red: #c90917;
  --red-700: #a50712;
  --white: #ffffff;
  --gray-50: #f5f7fa;
  --gray-100: #eceff4;
  --gray-200: #dfe4eb;
  --gray-400: #8a94a3;
  --text: #263244;
  --text-muted: #556172;

  --font: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  --radius: 8px;
  --radius-lg: 12px;
  --shadow-sm: 0 1px 2px rgba(7, 31, 66, 0.06);
  --shadow: 0 1px 3px rgba(7, 31, 66, 0.06), 0 8px 24px rgba(7, 31, 66, 0.06);
  --header-h: 76px;
  --container: 1180px;
  --gutter: 24px;
}

/* ---------- Base ---------- */
*,
*::before,
*::after { box-sizing: border-box; }

html {
  -webkit-text-size-adjust: 100%;
  scroll-behavior: smooth;
  scroll-padding-top: var(--header-h);
}

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

body {
  margin: 0;
  background: var(--white);
  color: var(--text);
  font-family: var(--font);
  font-size: 1.0625rem;
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

img, svg, picture { display: block; max-width: 100%; }
img { height: auto; }

h1, h2, h3, h4 {
  margin: 0 0 0.5em;
  color: var(--navy);
  font-weight: 700;
  line-height: 1.15;
  letter-spacing: -0.02em;
}

p { margin: 0 0 1em; }
p:last-child { margin-bottom: 0; }

a { color: var(--navy-600); text-underline-offset: 3px; }
a:hover { color: var(--red); }

:focus-visible {
  outline: 3px solid var(--red);
  outline-offset: 3px;
  border-radius: 2px;
}

.container {
  width: 100%;
  max-width: calc(var(--container) + var(--gutter) * 2);
  margin: 0 auto;
  padding: 0 var(--gutter);
}

.visually-hidden {
  position: absolute !important;
  width: 1px; height: 1px;
  padding: 0; margin: -1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
  border: 0;
}

.skip-link {
  position: absolute;
  top: -100px;
  left: 16px;
  z-index: 200;
  padding: 10px 16px;
  background: var(--white);
  color: var(--navy);
  font-weight: 600;
  border-radius: var(--radius);
  box-shadow: var(--shadow);
}
.skip-link:focus { top: 12px; }

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 48px;
  padding: 12px 24px;
  border: 2px solid transparent;
  border-radius: var(--radius);
  font: inherit;
  font-size: 1rem;
  font-weight: 600;
  line-height: 1.2;
  text-decoration: none;
  cursor: pointer;
  transition: background-color 0.15s ease, border-color 0.15s ease, color 0.15s ease;
}

.btn-primary { background: var(--red); color: var(--white); }
.btn-primary:hover { background: var(--red-700); color: var(--white); }

.btn-outline-light { border-color: rgba(255, 255, 255, 0.7); color: var(--white); }
.btn-outline-light:hover { background: var(--white); border-color: var(--white); color: var(--navy); }

.btn-sm { min-height: 42px; padding: 9px 18px; font-size: 0.9375rem; }

.btn[disabled] { opacity: 0.65; cursor: progress; }

/* ---------- Header ---------- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: var(--navy);
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  height: var(--header-h);
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  color: var(--white);
  text-decoration: none;
}
.brand:hover { color: var(--white); }
.brand img { width: 54px; height: 56px; }
.brand-name {
  font-size: 1.125rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  white-space: nowrap;
}

.site-nav { display: flex; align-items: center; gap: 32px; }

.nav-list {
  display: flex;
  align-items: center;
  gap: 4px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.nav-list a {
  position: relative;
  display: block;
  padding: 10px 14px;
  color: rgba(255, 255, 255, 0.82);
  font-size: 0.9688rem;
  font-weight: 500;
  text-decoration: none;
  border-radius: 6px;
}
.nav-list a:hover { color: var(--white); }
.nav-list a.is-active { color: var(--white); }
.nav-list a.is-active::after {
  content: "";
  position: absolute;
  left: 14px; right: 14px; bottom: 4px;
  height: 2px;
  background: var(--red);
}

.nav-toggle {
  display: none;
  align-items: center;
  justify-content: center;
  width: 46px;
  height: 46px;
  padding: 0;
  background: transparent;
  border: 1px solid rgba(255, 255, 255, 0.25);
  border-radius: var(--radius);
  color: var(--white);
  cursor: pointer;
}
.nav-toggle svg { width: 22px; height: 22px; }
.nav-toggle .icon-close { display: none; }
.nav-toggle[aria-expanded="true"] .icon-open { display: none; }
.nav-toggle[aria-expanded="true"] .icon-close { display: block; }

@media (max-width: 900px) {
  :root { --header-h: 68px; }
  .brand img { width: 46px; height: 48px; }
  .brand-name { font-size: 1rem; }
  .nav-toggle { display: inline-flex; }

  .site-nav {
    position: absolute;
    top: 100%;
    left: 0; right: 0;
    display: none;
    flex-direction: column;
    align-items: stretch;
    gap: 16px;
    padding: 12px var(--gutter) 24px;
    background: var(--navy);
    border-top: 1px solid rgba(255, 255, 255, 0.08);
    box-shadow: 0 16px 24px rgba(0, 0, 0, 0.2);
  }
  .site-nav.is-open { display: flex; }
  .nav-list { flex-direction: column; align-items: stretch; gap: 0; }
  .nav-list a { padding: 14px 4px; font-size: 1.0625rem; border-bottom: 1px solid rgba(255, 255, 255, 0.08); border-radius: 0; }
  .nav-list a.is-active::after { display: none; }
  .site-nav .btn { width: 100%; }
}

/* ---------- Hero ---------- */
.hero {
  position: relative;
  isolation: isolate;
  display: flex;
  flex-direction: column;
  justify-content: center;
  min-height: min(82vh, 760px);
  background: var(--navy);
  color: var(--white);
  overflow: hidden;
}

.hero-media,
.hero-media img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
}
.hero-media { z-index: -2; }
.hero-media img { object-fit: cover; object-position: 62% 55%; }

.hero::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  background: linear-gradient(90deg, rgba(7, 31, 66, 0.95) 0%, rgba(7, 31, 66, 0.88) 34%, rgba(7, 31, 66, 0.45) 62%, rgba(7, 31, 66, 0.12) 100%);
}

.hero-content { padding-top: 96px; padding-bottom: 96px; }
.hero-text { max-width: 600px; }

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 20px;
  font-size: 0.8125rem;
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}
.eyebrow::before {
  content: "";
  width: 32px;
  height: 3px;
  background: var(--red);
}
.hero .eyebrow { color: rgba(255, 255, 255, 0.85); }

.hero h1 {
  margin-bottom: 20px;
  color: var(--white);
  font-size: clamp(2.5rem, 5.6vw, 4.25rem);
  font-weight: 800;
  line-height: 1.04;
  letter-spacing: -0.03em;
}

.hero-sub {
  max-width: 520px;
  margin-bottom: 36px;
  color: rgba(255, 255, 255, 0.88);
  font-size: clamp(1.0625rem, 1.6vw, 1.25rem);
  line-height: 1.6;
}

.hero-actions { display: flex; flex-wrap: wrap; gap: 14px; }

.hero-facts {
  background: rgba(7, 31, 66, 0.92);
  border-top: 1px solid rgba(255, 255, 255, 0.12);
}
.hero-facts ul {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 40px;
  margin: 0;
  padding: 18px 0;
  list-style: none;
  color: rgba(255, 255, 255, 0.85);
  font-size: 0.9375rem;
}
.hero-facts strong { color: var(--white); font-weight: 600; }
.hero-facts a { color: var(--white); text-decoration: none; }
.hero-facts a:hover { text-decoration: underline; color: var(--white); }

@media (max-width: 760px) {
  .hero { min-height: 0; }
  .hero::before { background: linear-gradient(180deg, rgba(7, 31, 66, 0.86) 0%, rgba(7, 31, 66, 0.78) 60%, rgba(7, 31, 66, 0.9) 100%); }
  .hero-media img { object-position: 64% 50%; }
  .hero-content { padding-top: 72px; padding-bottom: 72px; }
  .hero-actions .btn { flex: 1 1 200px; }
  .hero-facts ul { flex-direction: column; gap: 6px; }
}

/* ---------- Sections ---------- */
.section { padding: 104px 0; }
.section-alt { background: var(--gray-50); }

.section-head { max-width: 680px; margin-bottom: 56px; }
.section-head .eyebrow { color: var(--red); }
.section h2 { font-size: clamp(2rem, 3.6vw, 2.75rem); }
.lead { color: var(--text-muted); font-size: 1.1875rem; }

@media (max-width: 760px) {
  .section { padding: 72px 0; }
  .section-head { margin-bottom: 40px; }
}

/* ---------- About ---------- */
.about-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.25fr) minmax(0, 1fr);
  gap: 72px;
  align-items: start;
}
.about-grid .section-head { margin-bottom: 28px; }
.about-copy p { font-size: 1.125rem; }

.fact-card {
  padding: 32px;
  background: var(--gray-50);
  border: 1px solid var(--gray-200);
  border-top: 4px solid var(--red);
  border-radius: var(--radius-lg);
}
.fact-card h3 { margin-bottom: 20px; font-size: 1.125rem; }
.fact-list { margin: 0; }
.fact-list div {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  padding: 14px 0;
  border-bottom: 1px solid var(--gray-200);
}
.fact-list div:last-child { border-bottom: 0; padding-bottom: 0; }
.fact-list dt { color: var(--text-muted); font-size: 0.9375rem; }
.fact-list dd { margin: 0; color: var(--navy); font-weight: 600; text-align: right; }

@media (max-width: 900px) {
  .about-grid { grid-template-columns: 1fr; gap: 40px; }
}

/* ---------- Services ---------- */
.service-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 24px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.service-card {
  height: 100%;
  padding: 36px 32px;
  background: var(--white);
  border: 1px solid var(--gray-200);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-sm);
}

.service-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 56px;
  height: 56px;
  margin-bottom: 24px;
  color: var(--red);
  background: rgba(201, 9, 23, 0.07);
  border-radius: 10px;
}
.service-icon svg { width: 28px; height: 28px; }

.service-card h3 { margin-bottom: 12px; font-size: 1.25rem; }
.service-card p { color: var(--text-muted); }

@media (max-width: 960px) {
  .service-grid { grid-template-columns: 1fr; max-width: 640px; }
}

/* ---------- Contact ---------- */
.contact-grid {
  display: grid;
  grid-template-columns: minmax(0, 0.9fr) minmax(0, 1.1fr);
  gap: 64px;
  align-items: start;
}

.contact-list { margin: 0; padding: 0; list-style: none; }
.contact-list li {
  display: grid;
  grid-template-columns: 44px 1fr;
  gap: 16px;
  padding: 18px 0;
  border-bottom: 1px solid var(--gray-200);
}
.contact-list li:first-child { padding-top: 0; }
.contact-list li:last-child { border-bottom: 0; }

.contact-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
  color: var(--navy);
  background: var(--gray-50);
  border: 1px solid var(--gray-200);
  border-radius: 10px;
}
.contact-icon svg { width: 20px; height: 20px; }

.contact-label {
  display: block;
  color: var(--text-muted);
  font-size: 0.8125rem;
  font-weight: 600;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}
.contact-value { color: var(--navy); font-weight: 600; font-style: normal; }
a.contact-value { text-decoration: none; }
a.contact-value:hover { color: var(--red); text-decoration: underline; }

/* ---------- Form ---------- */
.form-card {
  padding: 40px;
  background: var(--white);
  border: 1px solid var(--gray-200);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow);
}
.form-card h3 { margin-bottom: 6px; font-size: 1.375rem; }
.form-intro { margin-bottom: 28px; color: var(--text-muted); font-size: 0.9688rem; }

.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; }
.field { margin-bottom: 20px; }

.field label,
.consent-legend {
  display: block;
  margin-bottom: 8px;
  color: var(--navy);
  font-size: 0.9375rem;
  font-weight: 600;
}
.field .req { color: var(--red); }
.field .opt { color: var(--text-muted); font-weight: 400; }

.field input,
.field textarea {
  display: block;
  width: 100%;
  min-height: 50px;
  padding: 12px 14px;
  background: var(--white);
  border: 1px solid #c9d1dc;
  border-radius: var(--radius);
  color: var(--text);
  font: inherit;
  font-size: 1rem;
  transition: border-color 0.15s ease, box-shadow 0.15s ease;
}
.field textarea { min-height: 140px; resize: vertical; }
.field input:hover,
.field textarea:hover { border-color: var(--gray-400); }
.field input:focus,
.field textarea:focus {
  outline: none;
  border-color: var(--navy-600);
  box-shadow: 0 0 0 3px rgba(20, 58, 112, 0.18);
}
.field input[aria-invalid="true"],
.field textarea[aria-invalid="true"] { border-color: var(--red); }

.field-hint { margin-top: 6px; color: var(--text-muted); font-size: 0.8125rem; }
.field-error { margin-top: 6px; color: var(--red); font-size: 0.875rem; font-weight: 500; }
.field-error:empty { display: none; }

.hp-field { position: absolute; left: -10000px; width: 1px; height: 1px; overflow: hidden; }

.consent-box {
  margin: 4px 0 24px;
  padding: 20px;
  background: var(--gray-50);
  border: 1px solid var(--gray-200);
  border-radius: var(--radius);
}
.consent-box legend { float: left; width: 100%; padding: 0; }
.consent-box legend + * { clear: both; }
.consent-note { margin-bottom: 14px; color: var(--text-muted); font-size: 0.875rem; }

.checkbox {
  display: grid;
  grid-template-columns: 22px 1fr;
  gap: 12px;
  align-items: start;
  cursor: pointer;
}
.checkbox input {
  width: 20px;
  height: 20px;
  margin: 2px 0 0;
  accent-color: var(--navy);
  cursor: pointer;
}
.checkbox span { color: var(--text); font-size: 0.875rem; line-height: 1.6; }

.form-privacy { margin: 0 0 20px; color: var(--text-muted); font-size: 0.8125rem; }

.form-status {
  margin-top: 20px;
  padding: 14px 16px;
  border-radius: var(--radius);
  font-size: 0.9375rem;
  font-weight: 500;
}
.form-status:empty { display: none; }
.form-status.is-success { background: #e8f5ec; border: 1px solid #a8d5b5; color: #155d2b; }
.form-status.is-error { background: #fdecee; border: 1px solid #f2b8bd; color: #8c0a14; }

fieldset { margin: 0; padding: 0; border: 0; min-width: 0; }
fieldset.consent-box { padding: 20px; border: 1px solid var(--gray-200); }

@media (max-width: 960px) {
  .contact-grid { grid-template-columns: 1fr; gap: 48px; }
}
@media (max-width: 560px) {
  .form-card { padding: 28px 20px; }
  .form-row { grid-template-columns: 1fr; gap: 0; }
  .form-card .btn { width: 100%; }
}

/* ---------- Footer ---------- */
.site-footer {
  background: var(--navy);
  color: rgba(255, 255, 255, 0.78);
  font-size: 0.9375rem;
}
.footer-main {
  display: grid;
  grid-template-columns: 1.4fr 1fr 1fr 1.4fr;
  gap: 48px;
  padding-top: 72px;
  padding-bottom: 56px;
}
.footer-brand .brand { margin-bottom: 18px; }
.footer-brand .brand img { width: 62px; height: 64px; }
.footer-tagline { color: rgba(255, 255, 255, 0.78); }

.footer-title {
  margin-bottom: 16px;
  color: var(--white);
  font-size: 0.8125rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.footer-links { margin: 0; padding: 0; list-style: none; }
.footer-links li + li { margin-top: 10px; }
.site-footer a { color: rgba(255, 255, 255, 0.85); text-decoration: none; }
.site-footer a:hover { color: var(--white); text-decoration: underline; }
.site-footer address { font-style: normal; }
.footer-contact li + li { margin-top: 10px; }

.footer-bottom { border-top: 1px solid rgba(255, 255, 255, 0.1); }
.footer-bottom .container {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 8px 24px;
  padding-top: 22px;
  padding-bottom: 22px;
  color: rgba(255, 255, 255, 0.6);
  font-size: 0.875rem;
}
.footer-bottom p { margin: 0; }

@media (max-width: 960px) {
  .footer-main { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 560px) {
  .footer-main { grid-template-columns: 1fr; gap: 36px; padding-top: 56px; }
}

/* ---------- Legal pages ---------- */
.page-hero {
  padding: 72px 0 56px;
  background: var(--navy);
  color: rgba(255, 255, 255, 0.82);
}
.page-hero .eyebrow { color: rgba(255, 255, 255, 0.82); }
.page-hero h1 { margin-bottom: 12px; color: var(--white); font-size: clamp(2.25rem, 4.4vw, 3.25rem); }
.page-hero p { margin: 0; }

.legal { padding: 64px 0 96px; }
.legal-body { max-width: 820px; }
.legal-body h2 {
  margin: 48px 0 16px;
  padding-top: 8px;
  font-size: 1.5rem;
}
.legal-body h2:first-child { margin-top: 0; }
.legal-body h3 { margin: 28px 0 10px; font-size: 1.125rem; }
.legal-body ul { margin: 0 0 1em; padding-left: 1.25em; }
.legal-body li { margin-bottom: 6px; }

.legal-toc {
  margin-bottom: 48px;
  padding: 24px 28px;
  background: var(--gray-50);
  border: 1px solid var(--gray-200);
  border-radius: var(--radius-lg);
}
.legal-toc h2 { margin: 0 0 12px; font-size: 1rem; }
.legal-toc ol { margin: 0; padding-left: 1.25em; columns: 2; column-gap: 40px; }
.legal-toc li { margin-bottom: 6px; break-inside: avoid; }

.callout {
  margin: 0 0 1.25em;
  padding: 20px 24px;
  background: var(--gray-50);
  border-left: 4px solid var(--red);
  border-radius: 0 var(--radius) var(--radius) 0;
  color: var(--navy);
  font-weight: 600;
}
.callout p { margin-bottom: 0.75em; }

.legal-contact { margin: 0 0 1em; padding: 0; list-style: none; }
.legal-contact li { margin-bottom: 4px; }

@media (max-width: 640px) {
  .legal-toc ol { columns: 1; }
}
