/* ==========================================================================
   JCP Certification Service — homepage
   Palette: white + federal blue
   Type: Libre Franklin (display) · Public Sans (body) · IBM Plex Mono (labels)
   ========================================================================== */

:root {
  --white: #ffffff;
  --paper: #f7fafd;
  --sky: #edf3fb;
  --line: #d7e2f0;
  --line-soft: #e6edf7;
  --ink: #10233f;
  --ink-soft: #43567a;
  --blue: #1550c8;
  --blue-deep: #0c2e6e;
  --blue-hover: #0f3fa3;
  --stamp: #1550c8;

  --font-display: "Libre Franklin", "Public Sans", system-ui, sans-serif;
  --font-body: "Public Sans", system-ui, -apple-system, sans-serif;
  --font-mono: "IBM Plex Mono", ui-monospace, "SF Mono", monospace;

  --radius: 10px;
  --wrap: 1140px;
  --shadow-card: 0 1px 2px rgba(16, 35, 63, .05), 0 10px 30px -12px rgba(12, 46, 110, .14);
}

* { box-sizing: border-box; margin: 0; padding: 0; }

html { scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation: none !important; transition: none !important; }
}

body {
  font-family: var(--font-body);
  font-size: 1.0625rem;
  line-height: 1.65;
  color: var(--ink);
  background: var(--white);
  -webkit-font-smoothing: antialiased;
}

.sr-only {
  position: absolute; width: 1px; height: 1px;
  clip: rect(0 0 0 0); overflow: hidden; white-space: nowrap;
}

.wrap { max-width: var(--wrap); margin: 0 auto; padding: 0 24px; }
.wrap-narrow { max-width: 860px; }

img { max-width: 100%; display: block; }

/* ---------- Typography ---------- */

h1, h2, h3 { font-family: var(--font-display); color: var(--blue-deep); }

h1 {
  font-size: clamp(2.1rem, 4.6vw, 3.4rem);
  font-weight: 800;
  line-height: 1.06;
  letter-spacing: -0.022em;
  margin-bottom: 20px;
  text-wrap: balance;
}

h2 {
  font-size: clamp(1.6rem, 3vw, 2.2rem);
  font-weight: 800;
  line-height: 1.14;
  letter-spacing: -0.015em;
  margin-bottom: 14px;
  text-wrap: balance;
}

h3 { font-size: 1.125rem; font-weight: 700; line-height: 1.3; margin-bottom: 8px; }

p + p { margin-top: 14px; }

.eyebrow {
  font-family: var(--font-mono);
  font-size: .78rem;
  font-weight: 500;
  letter-spacing: .1em;
  text-transform: uppercase;
  color: var(--ink-soft);
  margin-bottom: 14px;
  display: flex;
  align-items: center;
  gap: 10px;
}

.eyebrow-ref {
  color: var(--blue);
  border: 1px solid var(--line);
  border-radius: 4px;
  padding: 3px 8px;
  background: var(--paper);
}

.lede, .section-lede {
  font-size: 1.15rem;
  color: var(--ink-soft);
  max-width: 620px;
}
.section-lede { margin-bottom: 40px; }
.section-foot { margin-top: 28px; }

a { color: var(--blue); text-decoration: none; }
a:hover { text-decoration: underline; }

:focus-visible {
  outline: 3px solid var(--blue);
  outline-offset: 2px;
  border-radius: 3px;
}

/* ---------- Buttons ---------- */

.btn {
  display: inline-block;
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 1rem;
  padding: 14px 26px;
  border-radius: var(--radius);
  border: 2px solid transparent;
  cursor: pointer;
  transition: background-color .15s ease, color .15s ease, border-color .15s ease, transform .15s ease;
}
.btn:hover { text-decoration: none; transform: translateY(-1px); }
.btn-sm { padding: 10px 18px; font-size: .92rem; }

.btn-solid { background: var(--blue); color: #fff; }
.btn-solid:hover { background: var(--blue-hover); }

.btn-ghost { border-color: var(--line); color: var(--blue-deep); background: var(--white); }
.btn-ghost:hover { border-color: var(--blue); color: var(--blue); }

.btn-invert { background: #fff; color: var(--blue-deep); }
.btn-invert:hover { background: var(--sky); }

.btn-invert-ghost { border-color: rgba(255,255,255,.45); color: #fff; }
.btn-invert-ghost:hover { border-color: #fff; }

.text-link { font-weight: 600; }

/* ---------- Header ---------- */

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(255, 255, 255, .92);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--line-soft);
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  min-height: 74px;
}

.brand { display: flex; align-items: center; gap: 12px; color: inherit; }
.brand:hover { text-decoration: none; }

.brand-mark {
  font-family: var(--font-display);
  font-weight: 900;
  font-size: .95rem;
  letter-spacing: .02em;
  color: #fff;
  background: linear-gradient(160deg, var(--blue) 0%, var(--blue-deep) 100%);
  border-radius: 8px;
  padding: 10px 11px;
  line-height: 1;
}

.brand-text { display: flex; flex-direction: column; line-height: 1.25; }
.brand-text strong { font-family: var(--font-display); font-size: 1rem; color: var(--blue-deep); }
.brand-text span { font-size: .74rem; color: var(--ink-soft); letter-spacing: .02em; }

.nav-list {
  display: flex;
  align-items: center;
  gap: 26px;
  list-style: none;
}
.nav-list > li > a:not(.btn) {
  font-weight: 600;
  font-size: .96rem;
  color: var(--ink);
}
.nav-list > li > a:not(.btn):hover,
.nav-list > li > a[aria-current="page"] {
  color: var(--blue);
  text-decoration: none;
}
.nav-list > li > a[aria-current="page"] { font-weight: 700; }

.nav-phone a {
  font-family: var(--font-mono);
  font-size: .88rem !important;
  color: var(--blue) !important;
}

.nav-toggle { display: none; }

/* ---------- Hero ---------- */

.hero {
  background:
    radial-gradient(900px 420px at 85% -10%, rgba(21, 80, 200, .07), transparent 65%),
    linear-gradient(180deg, var(--paper) 0%, var(--white) 78%);
  border-bottom: 1px solid var(--line-soft);
  overflow: hidden;
}

.hero-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.15fr) minmax(0, .85fr);
  gap: 48px;
  align-items: center;
  padding-top: 76px;
  padding-bottom: 84px;
}

.hero-copy .lede strong { color: var(--ink); }

.hero-actions { display: flex; flex-wrap: wrap; gap: 14px; margin-top: 30px; }

.hero-stats {
  display: flex;
  flex-wrap: wrap;
  gap: 0;
  margin-top: 44px;
  border-top: 1px solid var(--line);
  padding-top: 22px;
}
.hero-stats > div {
  padding-right: 34px;
  margin-right: 34px;
  border-right: 1px solid var(--line);
}
.hero-stats > div:last-child { border-right: 0; margin-right: 0; padding-right: 0; }
.hero-stats dt {
  font-family: var(--font-display);
  font-weight: 800;
  font-size: 1.7rem;
  color: var(--blue);
  letter-spacing: -0.01em;
}
.hero-stats dd { font-size: .86rem; color: var(--ink-soft); max-width: 150px; }

.hero-visual { position: relative; justify-self: center; }

.dossier {
  position: relative;
  width: min(360px, 86vw);
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: 12px;
  box-shadow: var(--shadow-card);
  transform: rotate(-1.6deg);
  z-index: 2;
}

.dossier-shadow-card {
  position: absolute;
  inset: 18px -16px -16px 18px;
  background: var(--sky);
  border: 1px solid var(--line);
  border-radius: 12px;
  transform: rotate(2deg);
  z-index: 1;
}

.dossier-head {
  padding: 18px 22px 14px;
  border-bottom: 2px solid var(--blue-deep);
}
.dossier-form {
  display: block;
  font-family: var(--font-mono);
  font-weight: 600;
  font-size: .8rem;
  letter-spacing: .14em;
  color: var(--blue);
}
.dossier-title {
  display: block;
  font-family: var(--font-display);
  font-weight: 700;
  font-size: .98rem;
  color: var(--blue-deep);
  margin-top: 4px;
  line-height: 1.3;
}

.dossier-body { padding: 12px 22px 22px; }

.dossier-row {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  font-family: var(--font-mono);
  font-size: .8rem;
  padding: 9px 0;
  border-bottom: 1px dashed var(--line);
}
.dossier-row:last-child { border-bottom: 0; }
.dossier-row span { color: var(--ink-soft); }
.dossier-row b { color: var(--blue-deep); font-weight: 600; }

.dossier-stamp {
  position: absolute;
  right: -18px;
  bottom: -20px;
  width: 108px;
  height: 108px;
  display: grid;
  place-items: center;
  text-align: center;
  font-family: var(--font-display);
  font-weight: 900;
  font-size: .92rem;
  line-height: 1.15;
  letter-spacing: .06em;
  color: var(--stamp);
  border: 3px solid var(--stamp);
  border-radius: 50%;
  background: rgba(255, 255, 255, .88);
  transform: rotate(9deg);
  box-shadow: var(--shadow-card);
}
.dossier-stamp::after {
  content: "";
  position: absolute;
  inset: 6px;
  border: 1px solid var(--stamp);
  border-radius: 50%;
  opacity: .55;
}

/* ---------- Sections ---------- */

.section { padding: 88px 0; }
.section-tint {
  background: linear-gradient(180deg, var(--paper) 0%, var(--sky) 100%);
  border-top: 1px solid var(--line-soft);
  border-bottom: 1px solid var(--line-soft);
}

.split {
  display: grid;
  grid-template-columns: minmax(0, 1.05fr) minmax(0, .95fr);
  gap: 56px;
  align-items: start;
}

/* ---------- Panels & lists ---------- */

.check-panel, .dev-panel {
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 30px 32px;
  box-shadow: var(--shadow-card);
}
.check-panel { border-top: 4px solid var(--blue); }

.check-list, .x-list { list-style: none; margin-top: 10px; }
.check-list li, .x-list li {
  position: relative;
  padding: 7px 0 7px 32px;
}
.check-list li::before {
  content: "✓";
  position: absolute;
  left: 0;
  top: 6px;
  width: 21px; height: 21px;
  display: grid; place-items: center;
  font-size: .72rem;
  font-weight: 700;
  color: var(--blue);
  background: var(--sky);
  border: 1px solid var(--line);
  border-radius: 50%;
}
.x-list li::before {
  content: "✕";
  position: absolute;
  left: 0;
  top: 6px;
  width: 21px; height: 21px;
  display: grid; place-items: center;
  font-size: .68rem;
  font-weight: 700;
  color: var(--ink-soft);
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: 50%;
}

/* ---------- Cards ---------- */

.card-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 22px;
}

.card {
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 28px;
  box-shadow: var(--shadow-card);
  transition: transform .18s ease, border-color .18s ease;
}
.card:hover { transform: translateY(-3px); border-color: var(--blue); }
.card p { font-size: .96rem; color: var(--ink-soft); }

.card-cta {
  background: linear-gradient(165deg, var(--blue) 0%, var(--blue-deep) 100%);
  border-color: var(--blue-deep);
  display: flex;
  flex-direction: column;
  gap: 6px;
}
.card-cta h3 { color: #fff; }
.card-cta p { color: rgba(255, 255, 255, .82); flex-grow: 1; }
.card-cta .btn { align-self: flex-start; background: #fff; color: var(--blue-deep); }
.card-cta .btn:hover { background: var(--sky); }

.steps {
  list-style: none;
  counter-reset: step;
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 22px;
}

.steps li {
  counter-increment: step;
  position: relative;
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 26px 26px 26px 26px;
  box-shadow: var(--shadow-card);
}
.steps li::before {
  content: "0" counter(step);
  display: inline-block;
  font-family: var(--font-mono);
  font-weight: 600;
  font-size: .82rem;
  letter-spacing: .08em;
  color: var(--blue);
  background: var(--sky);
  border: 1px solid var(--line);
  border-radius: 5px;
  padding: 4px 9px;
  margin-bottom: 14px;
}
.steps p { font-size: .95rem; color: var(--ink-soft); }

.req-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 22px;
}
.req-col {
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 28px;
  box-shadow: var(--shadow-card);
}
.req-col h3 { padding-bottom: 12px; border-bottom: 1px solid var(--line-soft); margin-bottom: 8px; }
.req-col li { font-size: .95rem; }
.req-warn { border-top: 4px solid var(--blue-deep); }

.dev-panel { border-left: 4px solid var(--blue); }
.dev-tag {
  font-family: var(--font-mono);
  font-size: .74rem;
  letter-spacing: .12em;
  text-transform: uppercase;
  color: var(--blue);
  margin-bottom: 10px;
}
.dev-panel .text-link { display: inline-block; margin-top: 14px; }

.faq { display: grid; gap: 12px; }

.faq details {
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: var(--shadow-card);
  overflow: hidden;
}
.faq summary {
  list-style: none;
  cursor: pointer;
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 1.02rem;
  color: var(--blue-deep);
  padding: 18px 52px 18px 24px;
  position: relative;
}
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after {
  content: "+";
  position: absolute;
  right: 20px;
  top: 50%;
  transform: translateY(-50%);
  font-family: var(--font-mono);
  font-size: 1.15rem;
  color: var(--blue);
  transition: transform .18s ease;
}
.faq details[open] summary::after { content: "–"; }
.faq details p { padding: 0 24px 20px; color: var(--ink-soft); }
.faq summary:hover { color: var(--blue); }

.contact-details { margin-top: 26px; display: grid; gap: 12px; }
.contact-details p { display: grid; gap: 2px; }
.contact-details span {
  font-family: var(--font-mono);
  font-size: .72rem;
  letter-spacing: .12em;
  text-transform: uppercase;
  color: var(--ink-soft);
}
.contact-details a { font-weight: 600; font-size: 1.05rem; }

.contact-form {
  background: var(--white);
  border: 1px solid var(--line);
  border-top: 4px solid var(--blue);
  border-radius: var(--radius);
  padding: 32px;
  box-shadow: var(--shadow-card);
}
.contact-form h3 { margin-bottom: 18px; }

.form-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
  margin-bottom: 20px;
}
.form-full { grid-column: 1 / -1; }

.contact-form label {
  display: grid;
  gap: 6px;
  font-size: .88rem;
  font-weight: 600;
  color: var(--ink);
}
.contact-form input,
.contact-form textarea {
  font-family: var(--font-body);
  font-size: 1rem;
  color: var(--ink);
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 11px 13px;
  transition: border-color .15s ease, background-color .15s ease;
}
.contact-form input:focus,
.contact-form textarea:focus {
  outline: none;
  border-color: var(--blue);
  background: var(--white);
  box-shadow: 0 0 0 3px rgba(21, 80, 200, .12);
}
.contact-form textarea { resize: vertical; }

.form-note { margin-top: 14px; font-size: .88rem; color: var(--ink-soft); }

.cta-band {
  background: linear-gradient(160deg, var(--blue) 0%, var(--blue-deep) 90%);
  color: #fff;
  padding: 84px 0;
  text-align: center;
}
.cta-band h2 { color: #fff; }
.cta-band p {
  color: rgba(255, 255, 255, .85);
  max-width: 560px;
  margin: 0 auto;
}
.cta-band .hero-actions { justify-content: center; }

.site-footer {
  background: var(--white);
  border-top: 1px solid var(--line-soft);
  padding: 56px 0 0;
}

.footer-grid {
  display: grid;
  grid-template-columns: 1.4fr 1fr 1fr;
  gap: 40px;
  padding-bottom: 44px;
}

.site-footer h3 {
  font-size: .82rem;
  font-family: var(--font-mono);
  font-weight: 600;
  letter-spacing: .12em;
  text-transform: uppercase;
  color: var(--ink-soft);
  margin-bottom: 14px;
}
.site-footer ul { list-style: none; display: grid; gap: 9px; }
.site-footer li { font-size: .95rem; color: var(--ink-soft); }
.site-footer li a { color: var(--ink); font-weight: 500; }
.site-footer li a:hover { color: var(--blue); }

.footer-note {
  margin-top: 18px;
  font-size: .84rem;
  color: var(--ink-soft);
  max-width: 340px;
}

.footer-bottom {
  border-top: 1px solid var(--line-soft);
  padding-top: 20px;
  padding-bottom: 20px;
}
.footer-bottom p { font-size: .85rem; color: var(--ink-soft); }

.reveal {
  opacity: 0;
  transform: translateY(14px);
  transition: opacity .5s ease, transform .5s ease;
}
.reveal.is-visible { opacity: 1; transform: none; }
@media (prefers-reduced-motion: reduce) {
  .reveal { opacity: 1; transform: none; }
}

@media (max-width: 960px) {
  .hero-grid { grid-template-columns: 1fr; gap: 56px; padding-top: 52px; padding-bottom: 64px; }
  .hero-visual { justify-self: start; margin-left: 6px; }
  .split { grid-template-columns: 1fr; gap: 36px; }
  .card-grid, .steps, .req-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .footer-grid { grid-template-columns: 1fr 1fr; }
}

@media (max-width: 720px) {
  .section { padding: 64px 0; }
  .card-grid, .steps, .req-grid { grid-template-columns: 1fr; }
  .form-grid { grid-template-columns: 1fr; }
  .footer-grid { grid-template-columns: 1fr; }
  .hero-stats > div { padding-right: 22px; margin-right: 22px; }

  .nav-toggle {
    display: grid;
    place-items: center;
    width: 44px; height: 44px;
    background: var(--white);
    border: 1px solid var(--line);
    border-radius: 8px;
    cursor: pointer;
  }
  .nav-toggle-bar,
  .nav-toggle-bar::before,
  .nav-toggle-bar::after {
    content: "";
    display: block;
    width: 18px; height: 2px;
    background: var(--blue-deep);
    position: relative;
    transition: transform .2s ease;
  }
  .nav-toggle-bar::before { position: absolute; top: -6px; }
  .nav-toggle-bar::after { position: absolute; top: 6px; }
  .nav-toggle[aria-expanded="true"] .nav-toggle-bar { background: transparent; }
  .nav-toggle[aria-expanded="true"] .nav-toggle-bar::before { top: 0; transform: rotate(45deg); }
  .nav-toggle[aria-expanded="true"] .nav-toggle-bar::after { top: 0; transform: rotate(-45deg); }

  .nav-list {
    display: none;
    position: absolute;
    top: 74px;
    left: 0;
    right: 0;
    flex-direction: column;
    align-items: stretch;
    gap: 0;
    background: var(--white);
    border-bottom: 1px solid var(--line);
    box-shadow: var(--shadow-card);
    padding: 8px 24px 20px;
  }
  .nav-list.open,
  .nav-list.is-open { display: flex; }
  .nav-list > li { padding: 10px 0; }
  .nav-list .btn { display: block; text-align: center; margin-top: 8px; }
}
