/* Endgame Holdings — public site.
   Self-contained: no external fonts, no CDN, nothing to block or go stale. */

:root {
  --ink:        #0c0e12;   /* near-black page ground */
  --ink-2:      #12151b;   /* raised surface */
  --ink-3:      #1a1f27;   /* card / border ground */
  --line:       #262c36;
  --line-soft:  #1e242c;
  --paper:      #eef1f4;   /* primary text on dark */
  --paper-dim:  #a6b0bd;   /* secondary text */
  --paper-mute: #77828f;   /* tertiary / captions */
  --accent:     #c9a227;   /* brass */
  --accent-lit: #e3bd45;
  --accent-ink: #17140a;
  --ok:         #5ac47f;
  --warn:       #e0a04a;
  --err:        #e0645a;
  --radius:     12px;
  --radius-sm:  8px;
  --wrap:       1120px;
  --serif: "Iowan Old Style", "Palatino Linotype", Palatino, "Book Antiqua", Georgia, serif;
  --sans: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  --mono: ui-monospace, SFMono-Regular, "SF Mono", Menlo, Consolas, monospace;
}

* { box-sizing: border-box; }

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

body {
  margin: 0;
  background: var(--ink);
  color: var(--paper);
  font-family: var(--sans);
  font-size: 17px;
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
}

.wrap { max-width: var(--wrap); margin: 0 auto; padding: 0 24px; }
.narrow { max-width: 760px; }

h1, h2, h3 { font-family: var(--serif); font-weight: 600; line-height: 1.15; letter-spacing: -0.01em; margin: 0 0 0.5em; }
h1 { font-size: clamp(2.1rem, 5.2vw, 3.4rem); }
h2 { font-size: clamp(1.6rem, 3.4vw, 2.2rem); }
h3 { font-size: 1.2rem; }
p { margin: 0 0 1.1em; }
a { color: var(--accent-lit); text-decoration-color: color-mix(in srgb, var(--accent-lit) 40%, transparent); text-underline-offset: 3px; }
a:hover { color: #f2d572; }
.muted { color: var(--paper-dim); }
.small { font-size: 0.9rem; }
.tiny  { font-size: 0.8rem; }
.sr-only {
  position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px;
  overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0;
}
.skip {
  position: absolute; left: -999px; top: 0; z-index: 100;
  background: var(--accent); color: var(--accent-ink); padding: 10px 16px; border-radius: 0 0 8px 0;
}
.skip:focus { left: 0; }

/* ── Header ─────────────────────────────────────────────────────────────── */

.site-head {
  position: sticky; top: 0; z-index: 50;
  background: color-mix(in srgb, var(--ink) 88%, transparent);
  backdrop-filter: saturate(140%) blur(10px);
  border-bottom: 1px solid var(--line-soft);
}
.head-inner { display: flex; align-items: center; justify-content: space-between; gap: 20px; height: 68px; }

.wordmark { display: inline-flex; align-items: center; gap: 10px; text-decoration: none; color: var(--paper); }
.mark {
  width: 20px; height: 20px; flex: none; border-radius: 3px;
  background:
    linear-gradient(135deg, var(--accent) 0 50%, transparent 50% 100%),
    linear-gradient(315deg, var(--accent) 0 50%, var(--ink-3) 50% 100%);
  box-shadow: 0 0 0 1px color-mix(in srgb, var(--accent) 45%, transparent);
}
.wordmark-text { font-family: var(--serif); font-size: 1.12rem; letter-spacing: 0.01em; }
.wordmark-thin { color: var(--paper-dim); font-weight: 400; margin-left: 0.32em; }

.site-nav { display: flex; align-items: center; }
.nav-links { display: flex; align-items: center; gap: 26px; }
.nav-links a { color: var(--paper-dim); text-decoration: none; font-size: 0.96rem; }
.nav-links a:hover { color: var(--paper); }
.nav-links a[aria-current="page"] { color: var(--paper); }
.nav-toggle { display: none; }

@media (max-width: 800px) {
  .nav-toggle {
    display: inline-flex; align-items: center; justify-content: center;
    width: 42px; height: 42px; background: none; border: 1px solid var(--line);
    border-radius: var(--radius-sm); cursor: pointer;
  }
  .bars, .bars::before, .bars::after {
    display: block; width: 18px; height: 2px; background: var(--paper); position: relative;
  }
  .bars::before, .bars::after { content: ""; position: absolute; left: 0; }
  .bars::before { top: -6px; } .bars::after { top: 6px; }
  .nav-links {
    position: absolute; top: 68px; left: 0; right: 0;
    flex-direction: column; align-items: stretch; gap: 0;
    background: var(--ink-2); border-bottom: 1px solid var(--line);
    padding: 8px 24px 20px; display: none;
  }
  .site-nav.open .nav-links { display: flex; }
  .nav-links a { padding: 12px 0; border-bottom: 1px solid var(--line-soft); }
  .nav-links .btn { margin-top: 14px; text-align: center; }
}

/* ── Buttons ────────────────────────────────────────────────────────────── */

.btn {
  display: inline-block; padding: 12px 22px; border-radius: var(--radius-sm);
  border: 1px solid var(--line); background: var(--ink-3); color: var(--paper);
  font: inherit; font-size: 0.98rem; font-weight: 600; text-decoration: none;
  cursor: pointer; text-align: center; transition: background .15s, border-color .15s, transform .05s;
}
.btn:hover { border-color: #3a434f; color: var(--paper); }
.btn:active { transform: translateY(1px); }
.btn-accent { background: var(--accent); border-color: var(--accent); color: var(--accent-ink); }
.btn-accent:hover { background: var(--accent-lit); border-color: var(--accent-lit); color: var(--accent-ink); }
.btn-ghost { background: transparent; }
.btn-sm { padding: 8px 14px; font-size: 0.9rem; }
.btn-lg { padding: 15px 30px; font-size: 1.05rem; }
.btn:disabled { opacity: .55; cursor: default; }
.btn-row { display: flex; flex-wrap: wrap; gap: 12px; align-items: center; }

/* ── Sections ───────────────────────────────────────────────────────────── */

section { padding: 88px 0; }
section.tight { padding: 56px 0; }
section.alt { background: var(--ink-2); border-block: 1px solid var(--line-soft); }

.eyebrow {
  font-family: var(--sans); font-size: 0.78rem; font-weight: 700;
  letter-spacing: 0.14em; text-transform: uppercase; color: var(--accent);
  margin: 0 0 14px;
}
.lede { font-size: 1.16rem; color: var(--paper-dim); max-width: 62ch; }
.section-head { max-width: 68ch; margin-bottom: 40px; }

/* ── Hero ───────────────────────────────────────────────────────────────── */

.hero { padding: 104px 0 88px; position: relative; overflow: hidden; }
.hero::before {
  content: ""; position: absolute; inset: -40% 30% auto -20%; height: 640px;
  background: radial-gradient(closest-side, color-mix(in srgb, var(--accent) 13%, transparent), transparent);
  pointer-events: none;
}
.hero .wrap { position: relative; }
.hero h1 { max-width: 18ch; }
.hero .lede { font-size: 1.24rem; margin-bottom: 32px; }
.hero-meta { display: flex; flex-wrap: wrap; gap: 28px; margin-top: 56px; color: var(--paper-mute); font-size: 0.9rem; }
.hero-meta strong { display: block; color: var(--paper); font-size: 1.5rem; font-family: var(--serif); font-weight: 600; }

/* ── Cards / grids ──────────────────────────────────────────────────────── */

.grid { display: grid; gap: 20px; }
.grid-2 { grid-template-columns: repeat(2, 1fr); }
.grid-3 { grid-template-columns: repeat(3, 1fr); }
@media (max-width: 900px) { .grid-2, .grid-3 { grid-template-columns: 1fr; } }

.card {
  background: var(--ink-2); border: 1px solid var(--line); border-radius: var(--radius);
  padding: 28px;
}
.card h3 { margin-bottom: 10px; }
.card p:last-child { margin-bottom: 0; }
.card-link { display: block; text-decoration: none; color: inherit; transition: border-color .15s, background .15s; }
.card-link:hover { border-color: color-mix(in srgb, var(--accent) 55%, var(--line)); background: var(--ink-3); color: inherit; }

.service-card { display: flex; flex-direction: column; gap: 6px; }
.service-card .num {
  font-family: var(--mono); font-size: 0.78rem; color: var(--accent); letter-spacing: 0.1em;
}
.check-list { list-style: none; margin: 14px 0 0; padding: 0; }
.check-list li { position: relative; padding-left: 24px; margin-bottom: 8px; color: var(--paper-dim); }
/* A real tick, not a chevron: the box has to be taller than it is wide before
   the 45deg rotation reads as a checkmark. */
.check-list li::before {
  content: ""; position: absolute; left: 6px; top: 0.42em; width: 6px; height: 11px;
  border-right: 2px solid var(--accent); border-bottom: 2px solid var(--accent);
  transform: rotate(42deg);
}

.step-list { counter-reset: step; list-style: none; margin: 0; padding: 0; }
.step-list li { position: relative; padding-left: 54px; margin-bottom: 26px; }
.step-list li::before {
  counter-increment: step; content: counter(step, decimal-leading-zero);
  position: absolute; left: 0; top: 0; font-family: var(--mono); font-size: 0.82rem;
  color: var(--accent); border: 1px solid var(--line); border-radius: 6px;
  width: 38px; height: 30px; display: grid; place-items: center;
}
.step-list h3 { margin-bottom: 4px; }
.step-list p { color: var(--paper-dim); margin-bottom: 0; }

.tag-row { display: flex; flex-wrap: wrap; gap: 8px; margin: 0; padding: 0; list-style: none; }
.tag {
  display: inline-block; padding: 5px 11px; border: 1px solid var(--line);
  border-radius: 999px; font-size: 0.82rem; color: var(--paper-dim); background: var(--ink-3);
}
.tag.accent { border-color: color-mix(in srgb, var(--accent) 45%, transparent); color: var(--accent-lit); }

/* ── Case studies ───────────────────────────────────────────────────────── */

.work-grid { display: grid; gap: 20px; grid-template-columns: repeat(2, 1fr); }
@media (max-width: 900px) { .work-grid { grid-template-columns: 1fr; } }
.work-card { display: flex; flex-direction: column; }
.work-card .kicker { color: var(--paper-mute); font-size: 0.82rem; letter-spacing: .06em; text-transform: uppercase; margin-bottom: 12px; }
.work-card h3 { font-size: 1.35rem; }
.work-card .more { margin-top: auto; padding-top: 16px; color: var(--accent-lit); font-weight: 600; font-size: 0.94rem; }

.case-hero { padding: 72px 0 40px; border-bottom: 1px solid var(--line-soft); }
.case-facts { display: grid; grid-template-columns: repeat(3, 1fr); gap: 18px; margin-top: 34px; }
@media (max-width: 720px) { .case-facts { grid-template-columns: 1fr; } }
.fact { border-left: 2px solid var(--accent); padding-left: 14px; }
.fact .k { display: block; font-size: 0.76rem; letter-spacing: .12em; text-transform: uppercase; color: var(--paper-mute); }
.fact .val { font-family: var(--serif); font-size: 1.12rem; }

.case-body { padding: 56px 0 72px; }
.case-body h2 { margin-top: 44px; }
.case-body h2:first-child { margin-top: 0; }
.case-body p { color: var(--paper-dim); max-width: 68ch; }

.outcome-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(190px, 1fr)); gap: 18px; margin: 30px 0; }
.outcome { background: var(--ink-2); border: 1px solid var(--line); border-radius: var(--radius); padding: 22px; }
.outcome .val { font-family: var(--serif); font-size: 2rem; color: var(--accent-lit); line-height: 1; }
.outcome .lbl { display: block; margin-top: 8px; font-weight: 600; font-size: 0.95rem; }
.outcome .note { color: var(--paper-mute); font-size: 0.85rem; margin: 4px 0 0; }

.screens { display: grid; gap: 18px; grid-template-columns: repeat(2, 1fr); margin: 34px 0; }
@media (max-width: 720px) { .screens { grid-template-columns: 1fr; } }
.screen figure { margin: 0; }
.screen img {
  width: 100%; height: auto; display: block; border: 1px solid var(--line);
  border-radius: var(--radius); background: var(--ink-2);
}
.screen figcaption { color: var(--paper-mute); font-size: 0.85rem; margin-top: 8px; }

blockquote.pull {
  margin: 34px 0; padding: 24px 28px; border-left: 3px solid var(--accent);
  background: var(--ink-2); border-radius: 0 var(--radius) var(--radius) 0;
}
blockquote.pull p { font-family: var(--serif); font-size: 1.2rem; color: var(--paper); margin-bottom: 10px; }
blockquote.pull cite { color: var(--paper-mute); font-style: normal; font-size: 0.88rem; }

/* ── Bios ───────────────────────────────────────────────────────────────── */

.bio { background: var(--ink-2); border: 1px solid var(--line); border-radius: var(--radius); padding: 30px; }
.bio h3 { font-size: 1.3rem; margin-bottom: 2px; }
.bio .headline { color: var(--accent-lit); font-size: 0.95rem; margin-bottom: 16px; }
.bio p { color: var(--paper-dim); }

/* ── Forms ──────────────────────────────────────────────────────────────── */

.form-card {
  background: var(--ink-2); border: 1px solid var(--line);
  border-radius: var(--radius); padding: 32px;
}
.field { margin-bottom: 20px; }
.field > label { display: block; font-weight: 600; font-size: 0.95rem; margin-bottom: 6px; }
.field .hint { color: var(--paper-mute); font-size: 0.87rem; margin: 0 0 8px; }
input[type=text], input[type=email], input[type=tel], textarea, select {
  width: 100%; padding: 12px 14px; font: inherit; color: var(--paper);
  background: var(--ink); border: 1px solid var(--line); border-radius: var(--radius-sm);
}
input:focus, textarea:focus, select:focus {
  outline: none; border-color: var(--accent);
  box-shadow: 0 0 0 3px color-mix(in srgb, var(--accent) 22%, transparent);
}
textarea { resize: vertical; min-height: 130px; line-height: 1.6; }
.field-row { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
@media (max-width: 620px) { .field-row { grid-template-columns: 1fr; } }
.hp { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }

.notice { border-radius: var(--radius-sm); padding: 14px 16px; margin: 0 0 22px; border: 1px solid; }
.notice.err  { background: color-mix(in srgb, var(--err) 12%, transparent);  border-color: color-mix(in srgb, var(--err) 45%, transparent);  color: #ffb9b3; }
.notice.ok   { background: color-mix(in srgb, var(--ok) 12%, transparent);   border-color: color-mix(in srgb, var(--ok) 40%, transparent);   color: #b6ecca; }
.notice.warn { background: color-mix(in srgb, var(--warn) 12%, transparent); border-color: color-mix(in srgb, var(--warn) 42%, transparent); color: #f2d3a4; }

/* ── Interview ──────────────────────────────────────────────────────────── */

.progress { display: flex; align-items: center; gap: 10px; margin-bottom: 26px; }
.progress .dot { width: 9px; height: 9px; border-radius: 50%; background: var(--line); }
.progress .dot.on { background: var(--accent); }
.progress .dot.done { background: color-mix(in srgb, var(--accent) 55%, var(--ink)); }
.progress .label { color: var(--paper-mute); font-size: 0.85rem; margin-left: 4px; }

.q-block { border-top: 1px solid var(--line-soft); padding-top: 22px; margin-top: 22px; }
.q-block:first-of-type { border-top: 0; padding-top: 0; margin-top: 0; }
.q-block .q { font-family: var(--serif); font-size: 1.2rem; margin-bottom: 6px; }
.q-block .hint { color: var(--paper-mute); font-size: 0.87rem; margin-bottom: 10px; }

.resume-note { background: var(--ink-3); border: 1px dashed var(--line); border-radius: var(--radius-sm); padding: 14px 16px; }
.resume-note code { font-family: var(--mono); font-size: 0.82rem; color: var(--accent-lit); word-break: break-all; }

/* ── CTA + footer ───────────────────────────────────────────────────────── */

.cta { background: var(--ink-2); border: 1px solid var(--line); border-radius: var(--radius); padding: 48px; text-align: center; }
.cta h2 { margin-bottom: 12px; }
.cta p { color: var(--paper-dim); max-width: 54ch; margin: 0 auto 26px; }

.site-foot { border-top: 1px solid var(--line-soft); padding: 56px 0 28px; background: var(--ink-2); }
.foot-inner { display: flex; justify-content: space-between; gap: 40px; flex-wrap: wrap; }
.foot-inner > div:first-child { max-width: 42ch; }
.foot-mark { font-size: 1.05rem; margin-bottom: 8px; }
.foot-links { display: flex; flex-direction: column; gap: 10px; }
.foot-links a { color: var(--paper-dim); text-decoration: none; font-size: 0.94rem; }
.foot-links a:hover { color: var(--paper); }
.foot-legal {
  display: flex; justify-content: space-between; flex-wrap: wrap; gap: 12px;
  border-top: 1px solid var(--line-soft); margin-top: 40px; padding-top: 20px;
}
.foot-legal a { text-decoration: none; }
