:root {
  --navy: #0f2a44;
  --navy-deep: #0a1e31;
  --ink: #1b2430;
  --muted: #5b6673;
  --line: #dde3ea;
  --bg: #ffffff;
  --bg-alt: #f4f7fa;
  --accent: #e8702a;
  --accent-dark: #c95a1a;
  --radius: 10px;
  --max: 1080px;
  --font: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

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

a { color: var(--navy); }

h1, h2, h3 { line-height: 1.2; margin: 0 0 0.5em; }
h1 { font-size: clamp(1.9rem, 4.2vw, 2.9rem); font-weight: 750; letter-spacing: -0.01em; }
h2 { font-size: clamp(1.5rem, 3vw, 2rem); font-weight: 700; }
h3 { font-size: 1.15rem; font-weight: 650; }
p { margin: 0 0 1em; }
ul, ol { margin: 0 0 1em; padding-left: 1.2em; }
li { margin-bottom: 0.4em; }

.container {
  width: 100%;
  max-width: var(--max);
  margin: 0 auto;
  padding: 0 16px;
}
.container.narrow { max-width: 680px; }

/* ---------- header ---------- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 10;
  background: rgba(255, 255, 255, 0.92);
  backdrop-filter: blur(8px);
  border-bottom: 1px solid var(--line);
}
.nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  min-height: 64px;
}
.brand {
  font-weight: 800;
  font-size: 1.3rem;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  text-decoration: none;
  color: var(--navy);
}
.brand span { color: var(--accent); }
.nav nav { display: flex; align-items: center; gap: 20px; flex-wrap: wrap; }
.nav nav a { text-decoration: none; font-weight: 500; color: var(--ink); font-size: 0.95rem; }
.nav nav a:hover { color: var(--navy); }
.nav-cta {
  padding: 8px 14px;
  border-radius: 999px;
  background: var(--navy);
  color: #fff !important;
}
@media (max-width: 640px) {
  .nav nav a:not(.nav-cta) { display: none; }
}

/* ---------- hero ---------- */
.hero {
  background: linear-gradient(180deg, var(--navy-deep) 0%, var(--navy) 100%);
  color: #fff;
  padding: 72px 0 80px;
}
.hero h1 { color: #fff; max-width: 820px; }
.hero .lede {
  font-size: 1.2rem;
  max-width: 680px;
  color: rgba(255, 255, 255, 0.85);
  margin-bottom: 1.8em;
}
.hero-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 320px;
  gap: 48px;
  align-items: center;
}
.counter-card {
  display: flex;
  flex-direction: column;
  gap: 6px;
  background: #fff;
  color: var(--ink);
  border-radius: 14px;
  padding: 28px 28px 24px;
  box-shadow: 0 18px 48px rgba(0, 0, 0, 0.35);
  border-top: 6px solid var(--accent);
}
.counter-eyebrow {
  font-size: 0.78rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--accent);
  font-weight: 700;
}
.counter-num {
  font-size: 3.6rem;
  font-weight: 800;
  line-height: 1;
  color: var(--navy);
  letter-spacing: -0.03em;
  display: flex;
  align-items: baseline;
  gap: 10px;
}
.counter-num small {
  font-size: 1.1rem;
  font-weight: 600;
  color: var(--muted);
  letter-spacing: 0;
}
.counter-label {
  font-size: 1.25rem;
  font-weight: 700;
  color: var(--navy);
}
.counter-sub {
  font-size: 0.95rem;
  color: var(--muted);
  margin-bottom: 12px;
}
.counter-card .button { text-align: center; }
@media (max-width: 860px) {
  .hero-grid { grid-template-columns: 1fr; gap: 36px; }
  .counter-card { max-width: 420px; }
}
.hero-actions { display: flex; gap: 12px; flex-wrap: wrap; }

/* ---------- buttons ---------- */
.button {
  display: inline-block;
  padding: 13px 22px;
  border-radius: 8px;
  font-weight: 600;
  text-decoration: none;
  border: 2px solid transparent;
  cursor: pointer;
  font-size: 1rem;
  font-family: inherit;
  line-height: 1.2;
}
.button.primary { background: var(--accent); color: #fff; border-color: var(--accent); }
.button.primary:hover { background: var(--accent-dark); border-color: var(--accent-dark); }
.button.ghost { background: transparent; color: #fff; border-color: rgba(255, 255, 255, 0.5); }
.button.ghost:hover { border-color: #fff; }
.button.full { display: block; text-align: center; margin-top: auto; }
.button.outline { background: transparent; color: var(--navy); border-color: var(--navy); }
.button.outline:hover { background: var(--navy); color: #fff; }
.offer .topup { margin-top: auto; margin-bottom: 16px; }
.offer .topup + .button.full { margin-top: 0; }

/* ---------- sections ---------- */
.section { padding: 72px 0; }
.section.alt { background: var(--bg-alt); }
.section-intro { color: var(--muted); font-size: 1.08rem; margin-bottom: 2em; }
.subhead { margin-top: 56px; }

.grid { display: grid; gap: 20px; }
.grid.two { grid-template-columns: repeat(2, 1fr); }
.grid.three { grid-template-columns: repeat(3, 1fr); }
.grid.offers { grid-template-columns: repeat(3, 1fr); align-items: stretch; }
.grid.offers.two-up { grid-template-columns: repeat(2, 1fr); max-width: 860px; }
@media (max-width: 860px) {
  .grid.three, .grid.offers, .grid.offers.two-up { grid-template-columns: 1fr; }
}
@media (max-width: 640px) {
  .grid.two { grid-template-columns: 1fr; }
  .section { padding: 56px 0; }
  .hero { padding: 56px 0 64px; }
}

.card {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 24px;
}
.card p:last-child, .card ul:last-child { margin-bottom: 0; }

/* ---------- offers ---------- */
.offer { display: flex; flex-direction: column; }
.offer ul { font-size: 0.97rem; margin-bottom: 1.4em; }
.offer.featured { border-color: var(--navy); box-shadow: 0 8px 28px rgba(15, 42, 68, 0.12); }
.offer-step {
  font-size: 0.78rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--accent);
  font-weight: 700;
  margin-bottom: 0.4em;
}
.price {
  font-size: 1.35rem;
  font-weight: 750;
  color: var(--navy);
  margin-bottom: 1em;
  line-height: 1.3;
}
.price-note {
  display: block;
  font-size: 0.9rem;
  font-weight: 500;
  color: var(--muted);
}
.topup {
  margin-top: auto;
  padding: 14px 16px;
  background: var(--bg-alt);
  border-radius: 8px;
  font-size: 0.95rem;
}
.topup strong {
  display: block;
  color: var(--navy);
  margin-bottom: 4px;
}

/* ---------- checklist & steps ---------- */
.checklist h3 { margin-bottom: 0.25em; }
.checklist p { color: var(--muted); margin: 0; }
.checklist > div {
  padding: 18px 20px;
  border-left: 3px solid var(--accent);
  background: var(--bg-alt);
  border-radius: 0 8px 8px 0;
}
.steps { counter-reset: step; list-style: none; padding: 0; }
.steps li {
  position: relative;
  padding-left: 48px;
  margin-bottom: 1.1em;
}
.steps li::before {
  counter-increment: step;
  content: counter(step);
  position: absolute;
  left: 0;
  top: 0;
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background: var(--navy);
  color: #fff;
  font-weight: 700;
  display: grid;
  place-items: center;
  font-size: 0.9rem;
}

/* ---------- findings ---------- */
.finding-tag {
  font-size: 0.78rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--accent);
  font-weight: 700;
  margin-bottom: 0.5em;
}

/* ---------- about ---------- */
.proof-strip {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 16px;
  margin-bottom: 40px;
}
.proof-strip > div {
  background: var(--navy);
  color: #fff;
  border-radius: var(--radius);
  padding: 20px 22px;
}
.proof-strip strong { display: block; font-size: 1.5rem; margin-bottom: 4px; }
.proof-strip span { color: rgba(255, 255, 255, 0.8); font-size: 0.95rem; }
@media (max-width: 720px) { .proof-strip { grid-template-columns: 1fr; } }
.prose { max-width: none; }

/* ---------- form ---------- */
form { margin-top: 8px; }
.field { margin-bottom: 18px; }
.field label { display: block; font-weight: 600; margin-bottom: 6px; }
.optional { font-weight: 400; color: var(--muted); font-size: 0.92rem; }
input[type="text"], input[type="email"], input[type="url"], textarea {
  width: 100%;
  padding: 12px 14px;
  font: inherit;
  border: 1px solid #c5ccd4;
  border-radius: 8px;
  background: #fff;
}
input:focus, textarea:focus { outline: 2px solid var(--accent); outline-offset: 1px; border-color: var(--accent); }
.hidden-field { position: absolute; left: -9999px; }

/* ---------- footer ---------- */
.site-footer {
  background: var(--navy-deep);
  color: rgba(255, 255, 255, 0.85);
  padding: 36px 0;
  font-size: 0.95rem;
}
.site-footer a { color: #fff; }
.site-footer strong { text-transform: uppercase; letter-spacing: 0.04em; }
.site-footer .small { color: rgba(255, 255, 255, 0.6); margin: 0; }

/* ===================== design spike: motion, icons, report ===================== */

/* hero: faint dot grid plus two slowly drifting glows */
.hero { position: relative; overflow: hidden; }
.hero::before {
  content: "";
  position: absolute; inset: 0;
  background-image: radial-gradient(rgba(255, 255, 255, 0.07) 1px, transparent 1px);
  background-size: 26px 26px;
  pointer-events: none;
}
.hero::after {
  content: "";
  position: absolute; inset: -40%;
  background:
    radial-gradient(40% 40% at 30% 40%, rgba(232, 112, 42, 0.22), transparent 70%),
    radial-gradient(35% 35% at 75% 65%, rgba(90, 160, 255, 0.18), transparent 70%);
  animation: drift 24s ease-in-out infinite alternate;
  pointer-events: none;
}
.hero .container { position: relative; z-index: 1; }
@keyframes drift {
  from { transform: translate3d(-4%, -3%, 0) rotate(0deg); }
  to   { transform: translate3d(4%, 3%, 0) rotate(6deg); }
}

@keyframes lift {
  from { opacity: 0; transform: translateY(14px); }
  to   { opacity: 1; transform: translateY(0); }
}

/* sections fade up as they enter the viewport */
.js .reveal { opacity: 0; transform: translateY(32px); transition: opacity 0.8s ease, transform 0.8s cubic-bezier(0.2, 0.7, 0.2, 1); }
.js .reveal.is-visible { opacity: 1; transform: none; }
/* cards and checklist items stagger in after their section */
.js .reveal .card, .js .reveal .checklist > div, .js .reveal .proof-strip > div {
  opacity: 0; transform: translateY(24px);
  transition: opacity 0.6s ease, transform 0.6s cubic-bezier(0.2, 0.7, 0.2, 1);
}
.js .reveal.is-visible .card, .js .reveal.is-visible .checklist > div, .js .reveal.is-visible .proof-strip > div { opacity: 1; transform: none; }
.js .reveal.is-visible > .container > .grid > :nth-child(1), .js .reveal.is-visible .proof-strip > :nth-child(1) { transition-delay: 0.15s; }
.js .reveal.is-visible > .container > .grid > :nth-child(2), .js .reveal.is-visible .proof-strip > :nth-child(2) { transition-delay: 0.27s; }
.js .reveal.is-visible > .container > .grid > :nth-child(3), .js .reveal.is-visible .proof-strip > :nth-child(3) { transition-delay: 0.39s; }
.js .reveal.is-visible > .container > .grid > :nth-child(4) { transition-delay: 0.51s; }
.js .reveal.is-visible > .container > .grid > :nth-child(5) { transition-delay: 0.63s; }
.js .reveal.is-visible > .container > .grid > :nth-child(6) { transition-delay: 0.75s; }
.js .reveal.is-visible > .container > .grid > :nth-child(7) { transition-delay: 0.87s; }
.js .reveal.is-visible > .container > .grid > :nth-child(8) { transition-delay: 0.99s; }

/* cards lift slightly on hover */
.card { transition: transform 0.2s ease, box-shadow 0.2s ease; }
.card:hover { transform: translateY(-3px); box-shadow: 0 10px 28px rgba(15, 42, 68, 0.10); }

/* checklist icons */
.checklist > div { position: relative; padding-left: 64px; }
.checklist .icon {
  position: absolute; left: 18px; top: 20px;
  width: 28px; height: 28px;
  fill: none; stroke: var(--accent); stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round;
}

/* how it runs + sample report side by side */
.runs-grid { display: grid; grid-template-columns: minmax(0, 1fr) 380px; gap: 48px; align-items: start; margin-top: 56px; }
.runs-grid .subhead { margin-top: 0; }
@media (max-width: 900px) { .runs-grid { grid-template-columns: 1fr; } }

.report {
  margin: 0;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 6px;
  padding: 22px 24px 20px;
  box-shadow: 0 14px 40px rgba(15, 42, 68, 0.14);
  font-size: 0.92rem;
  transform: rotate(-1.2deg);
  position: relative;
}
.report::before {
  content: ""; position: absolute; left: 0; top: 0; bottom: 0; width: 6px;
  background: var(--navy); border-radius: 6px 0 0 6px;
}
.report-head { display: flex; justify-content: space-between; font-size: 0.72rem; text-transform: uppercase; letter-spacing: 0.08em; color: var(--muted); margin-bottom: 14px; }
.report-title { font-weight: 750; font-size: 1.15rem; color: var(--navy); line-height: 1.2; }
.report-sub { color: var(--muted); margin-bottom: 14px; }
.lights { list-style: none; padding: 0; margin: 0 0 14px; border-top: 1px solid var(--line); }
.lights li { display: flex; align-items: center; gap: 10px; padding: 7px 0; border-bottom: 1px solid var(--line); }
.lights li span { flex: 1; }
.lights li em { font-style: normal; font-size: 0.78rem; color: var(--muted); }
.lights i { width: 12px; height: 12px; border-radius: 50%; flex: none; }
.lights .red { background: #d9342b; box-shadow: 0 0 0 3px rgba(217, 52, 43, 0.15); }
.lights .amber { background: #e8a52a; box-shadow: 0 0 0 3px rgba(232, 165, 42, 0.15); }
.lights .green { background: #2f9e5b; box-shadow: 0 0 0 3px rgba(47, 158, 91, 0.15); }
.report-fix { background: var(--bg-alt); border-radius: 6px; padding: 12px 14px; }
.report-fix strong { display: block; font-size: 0.78rem; text-transform: uppercase; letter-spacing: 0.08em; color: var(--accent); margin-bottom: 6px; }
.report-fix ol { margin: 0; padding-left: 1.2em; }
.report-fix li { margin-bottom: 4px; }

/* respect reduced motion everywhere */
@media (prefers-reduced-motion: reduce) {
  .hero::after { animation: none; }
  .js .reveal, .js .reveal .card, .js .reveal .checklist > div, .js .reveal .proof-strip > div { opacity: 1; transform: none; transition: none; }
  .card { transition: none; }
  .report { transform: none; }
}

/* about: portrait beside the text */
.about-grid { display: grid; grid-template-columns: 260px minmax(0, 1fr); gap: 40px; align-items: start; }
.portrait { margin: 0; }
.portrait img {
  display: block; width: 100%; height: auto;
  border-radius: 16px;
  box-shadow: 0 14px 36px rgba(15, 42, 68, 0.18);
}
.portrait figcaption { margin-top: 12px; font-weight: 700; color: var(--navy); }
.portrait figcaption span { display: block; font-weight: 500; color: var(--muted); font-size: 0.92rem; }
@media (max-width: 760px) {
  .about-grid { grid-template-columns: 1fr; gap: 24px; }
  .portrait { max-width: 220px; }
}

/* ===================== fractional CTO redesign ===================== */
.eyebrow {
  font-size: 0.8rem; text-transform: uppercase; letter-spacing: 0.1em;
  color: var(--accent); font-weight: 700; margin-bottom: 1.2em;
}
.checklist.compact > div { padding: 14px 18px; }
.checklist.compact h3 { font-size: 1.02rem; }
.checklist.compact p { font-size: 0.95rem; }
.grid.logos { grid-template-columns: repeat(3, 1fr); }
@media (max-width: 860px) { .grid.logos { grid-template-columns: 1fr; } }
.logo-card {
  border: 1px solid var(--line); border-radius: var(--radius); padding: 20px 22px; background: #fff;
}
.logo-card h3 { margin-bottom: 2px; }
.logo-meta { font-size: 0.8rem; text-transform: uppercase; letter-spacing: 0.06em; color: var(--muted); margin-bottom: 10px; }
.logo-card p:last-child { margin: 0; font-size: 0.95rem; color: var(--ink); }
.testimonial {
  margin: 48px 0 0; padding: 28px 32px;
  background: var(--navy); color: #fff; border-radius: var(--radius);
  border-left: 6px solid var(--accent);
}
.testimonial p { font-size: 1.25rem; line-height: 1.5; margin-bottom: 0.8em; }
.testimonial footer { color: rgba(255,255,255,0.8); font-size: 0.95rem; }
.testimonial footer strong { color: #fff; }
select {
  width: 100%; padding: 12px 14px; font: inherit; border: 1px solid #c5ccd4; border-radius: 8px; background: #fff;
}
select:focus { outline: 2px solid var(--accent); outline-offset: 1px; border-color: var(--accent); }
.js .reveal .logo-card { opacity: 0; transform: translateY(24px); transition: opacity 0.6s ease, transform 0.6s cubic-bezier(0.2, 0.7, 0.2, 1); }
.js .reveal.is-visible .logo-card { opacity: 1; transform: none; }
@media (prefers-reduced-motion: reduce) { .js .reveal .logo-card { opacity: 1; transform: none; transition: none; } }

/* ===================== short, conversation-led version ===================== */
.starts { list-style: none; padding: 0; margin: 4px 0 18px; counter-reset: s; }
.starts li { position: relative; padding-left: 36px; margin-bottom: 12px; font-size: 0.95rem; color: var(--muted); line-height: 1.45; }
.starts li strong { color: var(--navy); }
.starts li::before {
  counter-increment: s; content: counter(s);
  position: absolute; left: 0; top: 1px; width: 24px; height: 24px; border-radius: 50%;
  background: var(--accent); color: #fff; font-size: 0.8rem; font-weight: 700; display: grid; place-items: center;
}
.counter-card .button { text-align: center; }

.areas { list-style: none; padding: 0; margin: 0 0 28px; display: grid; grid-template-columns: repeat(2, 1fr); gap: 14px 32px; }
.areas li { padding: 16px 18px 16px 22px; border-left: 3px solid var(--accent); background: var(--bg-alt); border-radius: 0 8px 8px 0; }
.areas strong { display: block; color: var(--navy); margin-bottom: 2px; }
.areas span { color: var(--muted); font-size: 0.95rem; }
@media (max-width: 760px) { .areas { grid-template-columns: 1fr; } }
.not-listed { font-size: 1.08rem; color: var(--ink); margin: 0; }
.section-outro { color: var(--muted); margin: 28px 0 0; }

.record { list-style: none; padding: 0; margin: 0 0 40px; border-top: 1px solid var(--line); }
.record li { display: grid; grid-template-columns: 300px 1fr; gap: 24px; padding: 14px 0; border-bottom: 1px solid var(--line); }
.record strong { color: var(--navy); }
.record span { color: var(--muted); }
@media (max-width: 760px) { .record li { grid-template-columns: 1fr; gap: 2px; } }
.js .reveal .areas li, .js .reveal .record li { opacity: 0; transform: translateY(16px); transition: opacity 0.5s ease, transform 0.5s cubic-bezier(0.2, 0.7, 0.2, 1); }
.js .reveal.is-visible .areas li, .js .reveal.is-visible .record li { opacity: 1; transform: none; }
.js .reveal.is-visible .areas li:nth-child(n+2), .js .reveal.is-visible .record li:nth-child(n+2) { transition-delay: 0.08s; }
.js .reveal.is-visible .areas li:nth-child(n+4), .js .reveal.is-visible .record li:nth-child(n+4) { transition-delay: 0.16s; }
.js .reveal.is-visible .areas li:nth-child(n+6), .js .reveal.is-visible .record li:nth-child(n+6) { transition-delay: 0.24s; }
@media (prefers-reduced-motion: reduce) { .js .reveal .areas li, .js .reveal .record li { opacity: 1; transform: none; transition: none; } }

/* how we work: choices */
.choices { display: grid; grid-template-columns: repeat(2, 1fr); gap: 16px; }
@media (max-width: 860px) { .choices { grid-template-columns: 1fr; } }
.choice {
  display: grid; grid-template-columns: 28px 1fr; gap: 14px; align-items: start;
  padding: 20px 22px; background: #fff; border: 2px solid var(--line); border-radius: var(--radius);
  text-decoration: none; color: var(--ink);
  transition: border-color 0.2s ease, transform 0.2s ease, box-shadow 0.2s ease;
}
.choice:hover { border-color: var(--navy); transform: translateY(-2px); box-shadow: 0 10px 28px rgba(15, 42, 68, 0.10); }
.choice.is-chosen { border-color: var(--accent); box-shadow: 0 0 0 3px rgba(232, 112, 42, 0.18); }
.choice-mark {
  width: 24px; height: 24px; border-radius: 50%; border: 2px solid #b9c2cc; margin-top: 2px;
  display: grid; place-items: center; transition: border-color 0.2s ease;
}
.choice-mark::after { content: ""; width: 12px; height: 12px; border-radius: 50%; background: var(--accent); transform: scale(0); transition: transform 0.2s ease; }
.choice:hover .choice-mark { border-color: var(--navy); }
.choice.is-chosen .choice-mark { border-color: var(--accent); }
.choice.is-chosen .choice-mark::after { transform: scale(1); }
.choice-body strong { display: block; color: var(--navy); font-size: 1.08rem; margin-bottom: 4px; }
.choice-body > span { color: var(--muted); font-size: 0.95rem; line-height: 1.5; }
.choice-cta { grid-column: 2; margin-top: 10px; font-weight: 600; color: var(--accent); font-size: 0.92rem; }
.choice-cta::after { content: " \2192"; }
.chosen { background: #fff; border-left: 4px solid var(--accent); padding: 10px 14px; border-radius: 0 8px 8px 0; margin-bottom: 20px; color: var(--ink); }
.js .reveal .choice { opacity: 0; transform: translateY(16px); transition: opacity 0.5s ease, transform 0.5s cubic-bezier(0.2, 0.7, 0.2, 1), border-color 0.2s ease, box-shadow 0.2s ease; }
.js .reveal.is-visible .choice { opacity: 1; transform: none; }
.js .reveal.is-visible .choice:nth-child(2) { transition-delay: 0.08s; }
.js .reveal.is-visible .choice:nth-child(3) { transition-delay: 0.16s; }
.js .reveal.is-visible .choice:nth-child(4) { transition-delay: 0.24s; }
.js .reveal.is-visible .choice:hover { transform: translateY(-2px); }
@media (prefers-reduced-motion: reduce) { .js .reveal .choice { opacity: 1; transform: none; transition: none; } .choice:hover { transform: none; } }

/* contact dialog */
.what-cta { margin: 28px 0 0; }
.contact-dialog { border: 0; padding: 0; background: transparent; max-width: min(640px, calc(100vw - 32px)); width: 100%; }
.contact-dialog::backdrop { background: transparent; }
.contact-dialog:not([open]) { display: none; }
.contact-dialog:target { display: block; position: fixed; inset: 0; margin: auto; height: max-content; z-index: 1000; } /* no-JS fallback */
/* the backdrop is a real element so it works, and closes the dialog, with or without JavaScript */
.dialog-backdrop { position: fixed; inset: 0; background: rgba(10, 30, 49, 0.72); backdrop-filter: blur(3px); z-index: 0; }
.dialog-inner { position: relative; z-index: 1; background: #fff; border-radius: 14px; padding: 36px 36px 32px; box-shadow: 0 30px 80px rgba(0,0,0,0.4); max-height: calc(100vh - 32px); overflow: auto; }
@media (max-width: 640px) { .dialog-inner { padding: 28px 20px 24px; } }
.dialog-inner h2 { padding-right: 36px; }
.dialog-inner .section-intro { margin-bottom: 1.4em; }
.dialog-close {
  position: absolute; top: 14px; right: 14px; width: 40px; height: 40px; border-radius: 50%;
  border: 0; background: var(--bg-alt); color: var(--muted); font-size: 1.6rem; line-height: 1; cursor: pointer;
  display: grid; place-items: center; text-decoration: none;
}
.dialog-close:hover { background: var(--line); color: var(--ink); }
.form-error { margin-top: 14px; color: #b3261e; }
body:has(dialog[open]), body:has(dialog:target) { overflow: hidden; }
@media (prefers-reduced-motion: no-preference) {
  .contact-dialog[open] .dialog-inner { animation: lift 0.3s ease-out both; }
}

/* thanks page: hero fills the space between header and footer */
.thanks-page { min-height: 100vh; display: flex; flex-direction: column; }
.thanks-page main { flex: 1; display: flex; }
.thanks-hero { flex: 1; display: flex; align-items: center; }
.thanks-hero h1 { margin-bottom: 0.4em; }
