/* ==========================================================================
   KINGSmen Estate — Design System
   Direction: "Private Ledger" — architectural, hairline, flush-left.
   No pills, no rounded cards, no drop shadows. Sharp edges, thin rules,
   index numerals, inverted hover states. Dark ground throughout.
   Palette: near-black / charcoal / warm ivory / stone / muted green / BEIGE accent.
   ========================================================================== */

:root {
  /* Core neutrals */
  --ink: #0a0a09;
  --charcoal: #15140f;
  --charcoal-2: #1c1b16;
  --line: #34322a;
  --line-soft: #26251f;
  --stone: #8f897c;
  --stone-light: #bdb6a8;
  --ivory: #f2ede3;
  --ivory-2: #e8e1d2;
  --white: #ffffff;

  /* Accent — beige (replaces gold/champagne) */
  --beige: #c9bfa9;
  --beige-light: #e0d6c2;
  --beige-deep: #a89877;

  /* Secondary accent, used sparingly */
  --green: #2f4a3d;

  /* Semantic */
  --bg: var(--ink);
  --bg-alt: var(--charcoal);
  --surface: var(--charcoal-2);
  --text: var(--ivory);
  --text-muted: var(--stone-light);
  --border: var(--line);
  --accent: var(--beige);
  --accent-strong: var(--beige-light);
  --focus: #9aa88f;

  /* Type */
  --font-serif: "Cormorant Garamond", Georgia, "Times New Roman", serif;
  --font-sans: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  --font-mono: "IBM Plex Mono", ui-monospace, SFMono-Regular, Menlo, monospace;

  /* Spacing scale */
  --space-1: 0.5rem;
  --space-2: 1rem;
  --space-3: 1.5rem;
  --space-4: 2rem;
  --space-5: 3rem;
  --space-6: 4.5rem;
  --space-7: 7rem;

  --container: 1200px;
}

/* Light-section override (ivory bands use dark text) */
.on-ivory {
  --bg: var(--ivory);
  --text: var(--ink);
  --text-muted: #5c574d;
  --border: #d8cfb9;
  color: var(--text);
  background: var(--bg);
}

/* ---------- Reset ---------- */
* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: var(--font-sans);
  font-size: 16px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}
img { max-width: 100%; display: block; }
a { color: inherit; text-decoration: none; }
ul { list-style: none; margin: 0; padding: 0; }
button { font-family: inherit; }
input, select, textarea { font-family: inherit; font-size: 1rem; }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: 0.01ms !important; animation-iteration-count: 1 !important; transition-duration: 0.01ms !important; scroll-behavior: auto !important; }
}

:focus-visible {
  outline: 2px solid var(--focus);
  outline-offset: 2px;
}

.skip-link {
  position: absolute;
  left: -999px;
  top: 0;
  background: var(--beige);
  color: var(--ink);
  padding: 0.75rem 1.25rem;
  z-index: 1000;
  font-weight: 600;
}
.skip-link:focus {
  left: var(--space-2);
  top: var(--space-2);
}

/* ---------- Layout ---------- */
.container {
  max-width: var(--container);
  margin: 0 auto;
  padding: 0 var(--space-3);
}
.section {
  padding: var(--space-7) 0;
  border-bottom: 1px solid var(--border);
}
.section:last-child { border-bottom: none; }
@media (max-width: 640px) {
  .section { padding: var(--space-6) 0; }
}

/* Flush-left dossier header: big outline index number + heading, no centering */
.dossier-head {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: var(--space-4);
  align-items: end;
  max-width: 900px;
  margin: 0 0 var(--space-5);
  padding-bottom: var(--space-3);
  border-bottom: 1px solid var(--border);
}
.dossier-num {
  font-family: var(--font-serif);
  font-size: clamp(2.6rem, 6vw, 4.2rem);
  line-height: 1;
  font-weight: 500;
  color: transparent;
  -webkit-text-stroke: 1px var(--stone);
  text-stroke: 1px var(--stone);
}
.on-ivory .dossier-num { -webkit-text-stroke: 1px var(--stone); }
.eyebrow {
  display: block;
  font-family: var(--font-mono);
  font-size: 0.72rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--accent);
  font-weight: 500;
  margin-bottom: 0.5rem;
}

h1, h2, h3, h4 {
  font-family: var(--font-serif);
  font-weight: 600;
  line-height: 1.15;
  margin: 0 0 var(--space-2);
  letter-spacing: 0.005em;
}
h1 { font-size: clamp(2.3rem, 5vw, 3.8rem); }
h2 { font-size: clamp(1.8rem, 3.4vw, 2.6rem); margin-bottom: 0; }
h3 { font-size: clamp(1.2rem, 1.8vw, 1.45rem); }
p { margin: 0 0 var(--space-2); color: var(--text-muted); }
p.lead {
  font-size: 1.15rem;
  color: var(--text);
  max-width: 62ch;
}

.grid {
  display: grid;
  gap: var(--space-4);
}
.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: 900px) {
  .grid-3, .grid-4 { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 640px) {
  .grid-2, .grid-3, .grid-4 { grid-template-columns: 1fr; }
}

/* ---------- Buttons (rectangular, no fill by default) ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.6rem;
  padding: 1rem 1.6rem;
  font-weight: 600;
  font-size: 0.92rem;
  letter-spacing: 0.03em;
  text-transform: uppercase;
  border: 1px solid var(--stone);
  border-radius: 0;
  cursor: pointer;
  background: transparent;
  color: var(--text);
  transition: background 0.2s ease, color 0.2s ease, border-color 0.2s ease;
  min-height: 52px;
  line-height: 1.2;
}
.btn::after { content: "→"; font-family: var(--font-sans); }
.btn:hover { border-color: var(--accent); color: var(--accent-strong); }
.btn-primary {
  background: var(--beige);
  border-color: var(--beige);
  color: var(--ink);
}
.btn-primary:hover { background: transparent; color: var(--accent); border-color: var(--accent); }
.btn-secondary { background: transparent; }
.on-ivory .btn { border-color: #b3a98e; color: var(--text); }
.on-ivory .btn-primary { background: var(--ink); border-color: var(--ink); color: var(--ivory); }
.on-ivory .btn-primary:hover { background: transparent; color: var(--ink); }
.btn-block { width: 100%; }
.btn-lg { padding: 1.2rem 2rem; font-size: 0.95rem; }

/* ---------- Header ---------- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 500;
  background: rgba(10, 10, 9, 0.94);
  border-bottom: 1px solid var(--border);
}
.site-header .container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 80px;
}
.brand {
  display: flex;
  align-items: center;
  gap: 0.7rem;
  font-family: var(--font-sans);
  font-size: 0.95rem;
  font-weight: 600;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}
.brand img { height: 30px; width: auto; }
.brand-mark-fallback {
  height: 30px;
  width: 30px;
  border: 1px solid var(--accent);
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: var(--font-serif);
  font-weight: 700;
  color: var(--accent);
  font-size: 1rem;
}
.main-nav ul {
  display: flex;
  align-items: center;
}
.main-nav li { position: relative; }
.main-nav li + li::before {
  content: "";
  position: absolute;
  left: -1px;
  top: 50%;
  transform: translateY(-50%);
  width: 1px;
  height: 14px;
  background: var(--border);
}
.main-nav a {
  display: inline-block;
  padding: 0 1.1rem;
  white-space: nowrap;
  font-size: 0.85rem;
  font-weight: 500;
  letter-spacing: 0.03em;
  text-transform: uppercase;
  color: var(--text-muted);
  transition: color 0.2s ease;
}
.main-nav a:hover, .main-nav a[aria-current="page"] { color: var(--accent); }
.header-cta { display: flex; align-items: center; gap: var(--space-3); }
.nav-toggle {
  display: none;
  background: none;
  border: 1px solid var(--border);
  color: var(--text);
  padding: 0.6rem 0.8rem;
}
@media (max-width: 1180px) {
  .main-nav { display: none; }
  .nav-toggle { display: inline-flex; }
  .header-cta .btn-primary { padding: 0.7rem 1rem; font-size: 0.78rem; min-height: 44px; }
}
.mobile-nav {
  display: none;
  position: fixed;
  inset: 80px 0 0 0;
  background: var(--ink);
  z-index: 490;
  padding: var(--space-4) var(--space-3);
  overflow-y: auto;
}
.mobile-nav.open { display: block; }
.mobile-nav ul { display: flex; flex-direction: column; }
.mobile-nav li { border-bottom: 1px solid var(--border); }
.mobile-nav a { display: block; padding: 1.1rem 0; font-size: 1.2rem; font-family: var(--font-serif); }
.mobile-nav .btn { margin-top: var(--space-3); }

/* Mobile sticky CTA */
.sticky-cta {
  position: fixed;
  bottom: 0; left: 0; right: 0;
  z-index: 400;
  background: var(--ink);
  border-top: 1px solid var(--border);
  padding: 0.75rem var(--space-3);
  display: none;
}
@media (max-width: 640px) {
  .sticky-cta { display: block; }
  body { padding-bottom: 76px; }
}

/* ---------- Hero (full-bleed, no boxed image) ---------- */
.hero {
  padding: var(--space-6) 0 0;
  border-bottom: 1px solid var(--border);
}
.hero .container { max-width: 880px; }
.hero-copy { text-align: left; }
.hero-copy .btn-row { display: flex; gap: var(--space-2); flex-wrap: wrap; margin: var(--space-3) 0 var(--space-2); }
.microcopy { font-size: 0.85rem; color: var(--text-muted); margin-top: var(--space-1); }

.hero-elevation {
  border-top: 1px solid var(--border);
  margin-top: var(--space-5);
  background: var(--bg-alt);
}
.hero-elevation svg { display: block; width: 100%; height: auto; }
.hero-elevation figcaption {
  max-width: var(--container);
  margin: 0 auto;
  padding: 0.6rem var(--space-3) 1rem;
  font-family: var(--font-mono);
  font-size: 0.72rem;
  letter-spacing: 0.03em;
  color: var(--stone);
}

/* ---------- Ledger strip (trust bar) ---------- */
.ledger-strip {
  border-bottom: 1px solid var(--border);
  background: var(--bg-alt);
}
.ledger-strip .container {
  display: flex;
  flex-wrap: wrap;
}
.ledger-strip span {
  flex: 1 1 auto;
  padding: 1rem var(--space-3);
  border-left: 1px solid var(--border);
  font-family: var(--font-mono);
  font-size: 0.74rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--text-muted);
  text-align: center;
}
.ledger-strip span:first-child { border-left: none; }
@media (max-width: 780px) {
  .ledger-strip span { flex: 1 1 50%; border-left: none; border-top: 1px solid var(--border); }
}

/* ---------- Ledger list (replaces icon-cards) ---------- */
.ledger {
  border-top: 1px solid var(--border);
}
.ledger-row {
  display: grid;
  grid-template-columns: 90px 1fr;
  gap: var(--space-3);
  padding: var(--space-3) 0;
  border-bottom: 1px solid var(--border);
  transition: background 0.2s ease, color 0.2s ease;
}
.ledger-row:hover { background: rgba(201, 191, 169, 0.06); }
.on-ivory .ledger-row:hover { background: rgba(10,10,9,0.04); }
.ledger-row .row-num {
  font-family: var(--font-mono);
  font-size: 0.85rem;
  color: var(--accent);
  padding-top: 0.2rem;
}
.ledger-row h3 { margin-bottom: 0.3rem; }
.ledger-row p { margin: 0; }
@media (max-width: 560px) {
  .ledger-row { grid-template-columns: 1fr; gap: 0.3rem; }
}

/* ---------- Vertical timeline (replaces step cards) ---------- */
.timeline {
  position: relative;
  padding-left: 3.2rem;
  max-width: 640px;
}
.timeline::before {
  content: "";
  position: absolute;
  left: 0.95rem;
  top: 0.4rem;
  bottom: 0.4rem;
  width: 1px;
  background: var(--border);
}
.timeline-step {
  position: relative;
  padding-bottom: var(--space-5);
}
.timeline-step:last-child { padding-bottom: 0; }
.timeline-step::before {
  content: attr(data-step);
  position: absolute;
  left: -3.2rem;
  top: -0.15rem;
  width: 1.9rem;
  height: 1.9rem;
  border: 1px solid var(--accent);
  background: var(--bg);
  color: var(--accent);
  font-family: var(--font-mono);
  font-size: 0.78rem;
  display: flex;
  align-items: center;
  justify-content: center;
}

/* ---------- Split comparison panel ---------- */
.split-compare {
  display: grid;
  grid-template-columns: 1fr 1px 1fr;
  border: 1px solid var(--border);
}
.split-compare .col { padding: var(--space-4); }
.split-compare .divider { background: var(--border); }
.split-compare .col-head {
  font-family: var(--font-mono);
  font-size: 0.72rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--text-muted);
  margin-bottom: var(--space-3);
  padding-bottom: var(--space-2);
  border-bottom: 1px solid var(--border);
}
.split-compare .col-us .col-head { color: var(--accent); }
.split-compare ul { display: flex; flex-direction: column; }
.split-compare li {
  padding: 0.85rem 0;
  border-bottom: 1px solid var(--border-soft, var(--line-soft));
  font-size: 0.95rem;
}
.split-compare .col-us li { color: var(--text); font-weight: 500; }
.split-compare li:last-child { border-bottom: none; }
@media (max-width: 780px) {
  .split-compare { grid-template-columns: 1fr; }
  .split-compare .divider { display: none; }
  .split-compare .col { border-bottom: 1px solid var(--border); }
  .split-compare .col:last-child { border-bottom: none; }
}
.disclaimer {
  font-size: 0.88rem;
  color: var(--text-muted);
  border-left: 2px solid var(--accent);
  padding-left: var(--space-2);
  margin-top: var(--space-3);
}

/* ---------- FAQ / ledger accordion ---------- */
.accordion-item { border-bottom: 1px solid var(--border); }
.accordion-item:first-child { border-top: 1px solid var(--border); }
.accordion-trigger {
  width: 100%;
  text-align: left;
  background: none;
  border: none;
  color: var(--text);
  padding: 1.2rem 0;
  font-size: 1rem;
  font-weight: 500;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-2);
  cursor: pointer;
  font-family: var(--font-serif);
  font-size: 1.15rem;
}
.accordion-trigger .plus {
  position: relative;
  width: 16px; height: 16px;
  flex-shrink: 0;
}
.accordion-trigger .plus::before, .accordion-trigger .plus::after {
  content: "";
  position: absolute;
  background: var(--accent);
}
.accordion-trigger .plus::before { top: 50%; left: 0; width: 100%; height: 1px; transform: translateY(-50%); }
.accordion-trigger .plus::after { left: 50%; top: 0; height: 100%; width: 1px; transform: translateX(-50%); transition: transform 0.2s ease, opacity 0.2s ease; }
.accordion-trigger[aria-expanded="true"] .plus::after { transform: translateX(-50%) rotate(90deg); opacity: 0; }
.accordion-panel {
  overflow: hidden;
  max-height: 0;
  transition: max-height 0.25s ease;
}
.accordion-panel[data-open="true"] { max-height: 800px; }
.accordion-panel-inner { padding: 0 0 1.25rem; color: var(--text-muted); max-width: 68ch; }

/* ---------- Forms ---------- */
.form-shell {
  border: 1px solid var(--border);
  padding: var(--space-4);
}
fieldset { border: none; padding: 0; margin: 0 0 var(--space-4); }
legend {
  font-family: var(--font-serif);
  font-size: 1.3rem;
  margin-bottom: var(--space-2);
  padding: 0;
}
.field { margin-bottom: var(--space-3); }
.field label {
  display: block;
  font-size: 0.85rem;
  font-weight: 600;
  letter-spacing: 0.03em;
  text-transform: uppercase;
  margin-bottom: 0.5rem;
  color: var(--text-muted);
}
.field .hint { font-size: 0.82rem; color: var(--text-muted); margin-top: 0.3rem; }
.field input[type="text"],
.field input[type="tel"],
.field input[type="email"],
.field input[type="number"],
.field select,
.field textarea {
  width: 100%;
  padding: 0.9rem 1rem;
  min-height: 52px;
  border-radius: 0;
  border: 1px solid var(--stone);
  background: var(--ink);
  color: var(--text);
}
.field textarea { min-height: 120px; resize: vertical; }
.field input:focus, .field select:focus, .field textarea:focus {
  border-color: var(--accent);
}
.choice-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
  gap: 0;
  border: 1px solid var(--stone);
  border-bottom: none;
}
.choice {
  border-bottom: 1px solid var(--stone);
  border-left: 1px solid var(--stone);
  padding: 0.8rem 1rem;
  display: flex;
  align-items: center;
  gap: 0.6rem;
  cursor: pointer;
  min-height: 48px;
  margin-left: -1px;
}
.choice:first-child { border-left: none; margin-left: 0; }
.choice input { width: 16px; height: 16px; flex-shrink: 0; accent-color: var(--beige); }
.choice:has(input:checked) { background: rgba(201,191,169,0.1); color: var(--accent-strong); }
.file-drop {
  border: 1px dashed var(--stone);
  padding: var(--space-4);
  text-align: center;
  color: var(--text-muted);
}
.progress-steps {
  display: flex;
  gap: 0;
  margin-bottom: var(--space-4);
  font-family: var(--font-mono);
  font-size: 0.72rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--text-muted);
  border-top: 1px solid var(--border);
}
.progress-steps li { flex: 1; text-align: center; padding: 0.8rem 0 0; border-top: 1px solid var(--border); margin-top: -1px; }
.progress-steps li.active { color: var(--accent); border-color: var(--accent); font-weight: 600; }
.error-text { color: #c98a76; font-size: 0.85rem; margin-top: 0.3rem; display: none; }
.field.invalid input, .field.invalid select { border-color: #c98a76; }
.field.invalid .error-text { display: block; }

/* ---------- Testimonials ---------- */
.testimonial {
  border: 1px dashed var(--stone);
  padding: var(--space-4);
  color: var(--text-muted);
  font-style: italic;
  position: relative;
}
.testimonial .badge {
  position: absolute; top: -10px; right: 12px;
  background: var(--ink); border: 1px solid var(--accent); color: var(--accent);
  font-family: var(--font-mono);
  font-size: 0.62rem; letter-spacing: 0.06em; text-transform: uppercase;
  padding: 0.2rem 0.5rem; font-style: normal;
}

/* ---------- Footer (minimal, hairline) ---------- */
.site-footer {
  padding: var(--space-5) 0 var(--space-3);
  font-size: 0.88rem;
}
.footer-top {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  flex-wrap: wrap;
  gap: var(--space-4);
  padding-bottom: var(--space-4);
  border-bottom: 1px solid var(--border);
  margin-bottom: var(--space-3);
}
.footer-nav {
  display: flex;
  flex-wrap: wrap;
  gap: 0;
}
.footer-nav a {
  padding: 0 var(--space-2);
  border-left: 1px solid var(--border);
  color: var(--text-muted);
  font-size: 0.85rem;
  letter-spacing: 0.02em;
  text-transform: uppercase;
}
.footer-nav a:first-child { border-left: none; padding-left: 0; }
.footer-nav a:hover { color: var(--accent); }
.footer-meta { color: var(--text-muted); font-size: 0.85rem; }
.footer-meta a { color: var(--text-muted); }
.footer-meta a:hover { color: var(--accent); }
.footer-bottom {
  display: flex;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: var(--space-2);
  color: var(--stone);
  font-size: 0.78rem;
  font-family: var(--font-mono);
}

/* ---------- Final CTA ---------- */
.final-cta {
  text-align: left;
  padding: var(--space-7) 0;
}
.final-cta .container { max-width: 780px; }
.final-cta .btn-row { display: flex; gap: var(--space-2); flex-wrap: wrap; margin-top: var(--space-3); }

/* ---------- Utilities ---------- */
.text-center { text-align: center; }
.two-col {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: var(--space-5);
  align-items: start;
}
@media (max-width: 860px) {
  .two-col { grid-template-columns: 1fr; }
}

.page-hero {
  padding: var(--space-6) 0 var(--space-5);
  border-bottom: 1px solid var(--border);
}
.page-hero .container { max-width: 780px; }

.thankyou-check {
  width: 56px; height: 56px;
  border: 1px solid var(--accent); color: var(--accent);
  display: flex; align-items: center; justify-content: center;
  font-size: 1.6rem; margin: 0 auto var(--space-3);
}

/* Company info block used in About */
.info-block {
  border: 1px solid var(--border);
  padding: var(--space-4);
}
.info-block p:last-child { margin-bottom: 0; }
