/* Qirelon Asthavar — Canada — main theme
   Palette: Steel Blue + Stone (muted financial)
   primary #47607a · primary-dark #2a3a49 · accent #a98f6a
*/

:root {
  --bg: #16202a;
  --bg-2: #1c2733;
  --bg-3: #233040;
  --ink: #eef2f7;
  --ink-2: #c8d2dd;
  --muted: #94a2b3;
  --line: rgba(255, 255, 255, .10);
  --line-strong: rgba(255, 255, 255, .18);
  --primary: #47607a;
  --primary-light: #5d7993;
  --primary-dark: #2a3a49;
  --accent: #a98f6a;
  --accent-2: #c7b08a;
  --accent-soft: rgba(169, 143, 106, .18);
  --paper: #f1ece2;
  --paper-2: #e7e0d2;
  --paper-ink: #1e2832;
  --green: #6c8f78;
  --red: #b46a6a;
  --radius: 12px;
  --radius-lg: 20px;
  --font: Inter, system-ui, -apple-system, "Segoe UI", Roboto, Arial, sans-serif;
  --mono: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  font-family: var(--font);
  color: var(--ink);
  background: var(--bg);
  line-height: 1.55;
  overflow-x: hidden;
  background:
    radial-gradient(circle at 18% 4%, rgba(71, 96, 122, .35), transparent 28%),
    radial-gradient(circle at 82% 12%, rgba(169, 143, 106, .14), transparent 26%),
    linear-gradient(180deg, #16202a, #1a2532 50%, #16202a);
  background-attachment: fixed;
}

a { color: inherit; text-decoration: none; }
button, input, select, textarea { font: inherit; }
img { max-width: 100%; height: auto; display: block; }
.wrap { width: min(1180px, calc(100% - 32px)); margin: 0 auto; }

/* ===== Top navigation ===== */
.topbar {
  position: sticky;
  top: 0;
  z-index: 30;
  border-bottom: 1px solid var(--line);
  background: rgba(22, 32, 42, .88);
  backdrop-filter: blur(16px);
}
.topbar__inner {
  min-height: 70px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
}
.brand {
  display: inline-flex;
  align-items: center;
  gap: 11px;
  font-weight: 900;
  color: var(--ink);
}
.brand__mark {
  width: 40px;
  height: 40px;
  display: grid;
  place-items: center;
  border-radius: 11px;
  background: linear-gradient(135deg, var(--accent), var(--accent-2));
  color: var(--primary-dark);
  box-shadow: 0 0 26px rgba(169, 143, 106, .25);
  font-size: 20px;
  font-weight: 900;
}
.brand__name { font-size: 17px; letter-spacing: -.01em; }
.nav {
  display: flex;
  gap: 22px;
  align-items: center;
  color: var(--ink-2);
  font-size: 14px;
  font-weight: 700;
}
.nav a {
  position: relative;
  padding: 6px 0;
  transition: color .18s ease;
}
.nav a:hover { color: var(--ink); }
.nav a.is-active { color: var(--accent); }
.nav a.is-active:after {
  content: "";
  position: absolute;
  left: 0; right: 0; bottom: -2px;
  height: 2px;
  background: var(--accent);
}
.nav__cta {
  min-height: 42px;
  display: inline-flex;
  align-items: center;
  padding: 0 18px;
  border-radius: 999px;
  background: linear-gradient(135deg, var(--accent), var(--accent-2));
  color: var(--primary-dark) !important;
  font-weight: 800;
  box-shadow: 0 8px 24px rgba(169, 143, 106, .18);
  transition: transform .18s ease, box-shadow .18s ease;
}
.nav__cta:hover { transform: translateY(-1px); box-shadow: 0 12px 30px rgba(169, 143, 106, .25); }

/* Hamburger toggle (mobile only) */
.nav-toggle {
  display: none;
  width: 44px;
  height: 44px;
  align-items: center;
  justify-content: center;
  flex-direction: column;
  gap: 5px;
  background: transparent;
  border: 1px solid var(--line-strong);
  border-radius: 10px;
  cursor: pointer;
  padding: 0;
  flex-shrink: 0;
}
.nav-toggle:hover { border-color: var(--accent); }
.nav-toggle__bar {
  display: block;
  width: 20px;
  height: 2px;
  background: var(--ink);
  border-radius: 2px;
  transition: transform .22s ease, opacity .22s ease;
  transform-origin: center;
}
.nav-toggle[aria-expanded="true"] .nav-toggle__bar:nth-child(1) {
  transform: translateY(7px) rotate(45deg);
}
.nav-toggle[aria-expanded="true"] .nav-toggle__bar:nth-child(2) { opacity: 0; }
.nav-toggle[aria-expanded="true"] .nav-toggle__bar:nth-child(3) {
  transform: translateY(-7px) rotate(-45deg);
}

/* ===== Generic ===== */
main { min-height: 72vh; }
.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  color: var(--accent);
  font-size: 12px;
  font-weight: 800;
  letter-spacing: .14em;
  text-transform: uppercase;
}
.eyebrow:before {
  content: "";
  width: 34px;
  height: 1px;
  background: currentColor;
}
.btn {
  min-height: 48px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0 20px;
  border-radius: 999px;
  font-weight: 800;
  border: 1px solid transparent;
  cursor: pointer;
  transition: transform .18s ease, box-shadow .18s ease, background .18s ease;
}
.btn--primary {
  background: linear-gradient(135deg, var(--accent), var(--accent-2));
  color: var(--primary-dark);
  box-shadow: 0 10px 28px rgba(169, 143, 106, .22);
}
.btn--primary:hover { transform: translateY(-1px); box-shadow: 0 14px 34px rgba(169, 143, 106, .3); }
.btn--ghost {
  color: var(--ink);
  border-color: var(--line-strong);
  background: rgba(255, 255, 255, .04);
}
.btn--ghost:hover { background: rgba(255, 255, 255, .08); }

/* ===== Hero ===== */
.field-hero { position: relative; padding: 56px 0 80px; overflow: hidden; }
.field-bg {
  position: absolute;
  inset: 0;
  opacity: .35;
  background-image:
    linear-gradient(rgba(255, 255, 255, .05) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, .05) 1px, transparent 1px);
  background-size: 56px 56px;
  mask-image: linear-gradient(to bottom, black, transparent 86%);
}
.field-grid {
  position: relative;
  display: grid;
  grid-template-columns: minmax(0, 1fr) 420px;
  gap: 36px;
  align-items: start;
}
.hero-copy { padding-top: 28px; }
.query-brand {
  display: inline-flex;
  align-items: center;
  gap: 11px;
  margin-bottom: 18px;
  color: var(--ink);
  font-size: 18px;
  font-weight: 900;
}
.query-brand__mark {
  width: 36px;
  height: 36px;
  display: grid;
  place-items: center;
  border-radius: 10px;
  background: linear-gradient(135deg, var(--accent), var(--accent-2));
  color: var(--primary-dark);
  box-shadow: 0 0 26px rgba(169, 143, 106, .25);
  font-weight: 900;
}
.hero-copy h1 {
  margin: 18px 0 0;
  font-size: clamp(40px, 5.8vw, 68px);
  line-height: 1;
  letter-spacing: -.02em;
  font-weight: 900;
}
.hero-copy p.lede {
  max-width: 600px;
  margin: 22px 0 0;
  color: var(--ink-2);
  font-size: 19px;
  line-height: 1.55;
}
.brief-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 30px;
}
.hero-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 24px;
  margin-top: 36px;
  padding-top: 28px;
  border-top: 1px solid var(--line);
}
.hero-meta div { min-width: 0; }
.hero-meta span {
  display: block;
  color: var(--muted);
  font-size: 12px;
  letter-spacing: .12em;
  text-transform: uppercase;
  font-weight: 800;
}
.hero-meta b {
  display: block;
  margin-top: 4px;
  font-size: 18px;
  color: var(--ink);
}

/* ===== Lead card ===== */
.hero-form {
  grid-column: 2;
  grid-row: 1;
  position: sticky;
  top: 92px;
}
.lead-card {
  padding: 22px;
  border: 1px solid rgba(169, 143, 106, .28);
  border-radius: 22px;
  background: var(--paper);
  color: var(--paper-ink);
  box-shadow: 0 28px 90px rgba(0, 0, 0, .35);
}
.lead-card__head { margin-bottom: 18px; }
.lead-card__head span.kicker {
  display: inline-flex;
  margin-bottom: 10px;
  color: var(--primary-dark);
  font-size: 12px;
  font-weight: 900;
  letter-spacing: .14em;
  text-transform: uppercase;
}
.lead-card__head h2 {
  margin: 0;
  font-size: 28px;
  line-height: 1.1;
  color: var(--paper-ink);
  letter-spacing: -.01em;
}
.lead-card__head p {
  margin: 10px 0 0;
  color: #5a6470;
  font-size: 15px;
}
.contact-form { display: grid; gap: 14px; }
.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.form-label {
  display: block;
  margin-bottom: 7px;
  color: #5a6470;
  font-size: 12px;
  font-weight: 800;
  letter-spacing: .04em;
}
.rf-form-input {
  width: 100%;
  height: 46px;
  padding: 0 12px;
  border: 1px solid rgba(30, 40, 50, .15);
  border-radius: 10px;
  background: #fff;
  color: var(--paper-ink);
  outline: none;
  font-weight: 600;
  transition: border-color .15s ease, box-shadow .15s ease;
}
.rf-form-input:focus {
  border-color: var(--primary);
  box-shadow: 0 0 0 3px rgba(71, 96, 122, .18);
}
.form-field.has-error .rf-form-input {
  border-color: var(--red);
  box-shadow: 0 0 0 3px rgba(180, 106, 106, .2);
}
.iti, .iti-wrap { width: 100%; }
.err {
  display: none;
  margin-top: 6px;
  color: var(--red);
  font-size: 12px;
  font-weight: 700;
}
.form-field.has-error .err:not(.hide),
.form-field.has-error .error-msg { display: block; }
.hide, .waiting_block.hidden { display: none !important; }
.form-submit {
  min-height: 50px;
  border: 0;
  border-radius: 10px;
  background: linear-gradient(135deg, var(--accent), var(--accent-2));
  color: var(--primary-dark);
  font-weight: 900;
  cursor: pointer;
  letter-spacing: .01em;
  transition: transform .15s ease, box-shadow .15s ease;
}
.form-submit:hover { transform: translateY(-1px); box-shadow: 0 12px 28px rgba(169, 143, 106, .25); }
.form-note { margin: 0; color: #5a6470; font-size: 12px; }
.form-note a { color: var(--paper-ink); text-decoration: underline; text-underline-offset: 3px; font-weight: 800; }
.dot-spinner { display: flex; gap: 5px; }
.dot { width: 7px; height: 7px; border-radius: 50%; background: var(--paper-ink); animation: t54Pulse .9s infinite alternate; }
.dot:nth-child(2) { animation-delay: .15s; }
.dot:nth-child(3) { animation-delay: .3s; }
@keyframes t54Pulse {
  from { opacity: .3; transform: translateY(0); }
  to { opacity: 1; transform: translateY(-3px); }
}

/* ===== Signal strip ===== */
.signal-strip {
  overflow: hidden;
  border-block: 1px solid var(--line);
  background: var(--paper);
  color: var(--paper-ink);
  font-weight: 800;
}
.strip-track {
  display: flex;
  width: max-content;
  animation: t54Ticker 32s linear infinite;
}
.strip-track span {
  padding: 14px 30px;
  white-space: nowrap;
  font-size: 13px;
  letter-spacing: .02em;
}
.strip-track span b { color: var(--primary-dark); }
.strip-track span em { color: var(--primary); font-style: normal; }
@keyframes t54Ticker {
  from { transform: translateX(0); }
  to { transform: translateX(-50%); }
}

/* ===== Market field section ===== */
.market-field { padding: 86px 0 78px; }
.market-field-grid {
  display: grid;
  grid-template-columns: .56fr 1fr;
  gap: 28px;
  align-items: start;
}
.market-field-copy { position: sticky; top: 92px; }
.market-field-copy h2 {
  margin: 18px 0 0;
  font-size: clamp(32px, 4.6vw, 56px);
  line-height: 1.02;
  letter-spacing: -.015em;
}
.market-field-copy p {
  max-width: 520px;
  margin: 20px 0 0;
  color: var(--ink-2);
  font-size: 17px;
}
.field-visual {
  border: 1px solid var(--line-strong);
  border-radius: 22px;
  background: rgba(255, 255, 255, .04);
  box-shadow: 0 28px 90px rgba(0, 0, 0, .28);
  overflow: hidden;
}
.field-top {
  min-height: 52px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 18px;
  border-bottom: 1px solid var(--line);
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
  letter-spacing: .08em;
  text-transform: uppercase;
}
.field-top b {
  color: var(--accent);
  font-size: 22px;
  letter-spacing: 0;
  font-family: var(--mono);
}
.field-body {
  display: grid;
  grid-template-columns: 118px 1fr;
}
.asset-rail {
  display: grid;
  align-content: start;
  gap: 8px;
  padding: 16px;
  border-right: 1px solid var(--line);
  background: rgba(0, 0, 0, .14);
}
.asset-rail button {
  min-height: 42px;
  border: 1px solid transparent;
  border-radius: 12px;
  background: transparent;
  color: var(--muted);
  font-weight: 800;
  cursor: pointer;
  transition: color .15s ease, background .15s ease;
}
.asset-rail button:hover { color: var(--ink); }
.asset-rail button.is-active {
  color: var(--primary-dark);
  background: var(--accent);
}
.map-canvas {
  position: relative;
  min-height: 360px;
  overflow: hidden;
  background: linear-gradient(135deg, rgba(71, 96, 122, .15), rgba(169, 143, 106, .08));
}
.map-canvas:before {
  content: "";
  position: absolute;
  inset: 0;
  background-image: radial-gradient(circle, rgba(255, 255, 255, .12) 1px, transparent 1px);
  background-size: 24px 24px;
  opacity: .35;
}
.map-canvas svg {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
}
.node {
  position: absolute;
  display: inline-flex;
  align-items: center;
  gap: 7px;
  padding: 8px 11px;
  border: 1px solid var(--line-strong);
  border-radius: 999px;
  background: rgba(22, 32, 42, .82);
  color: var(--ink);
  font-size: 12px;
  font-weight: 800;
  letter-spacing: .02em;
}
.node i {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--accent);
  box-shadow: 0 0 16px var(--accent);
}
.n1 { left: 10%; top: 64%; }
.n2 { left: 37%; top: 38%; }
.n3 { right: 18%; top: 24%; }
.n4 { right: 8%; bottom: 20%; }
.field-readout {
  grid-column: 1 / -1;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1px;
  background: var(--line);
}
.field-readout div {
  padding: 16px;
  background: rgba(22, 32, 42, .96);
}
.field-readout span {
  display: block;
  color: var(--muted);
  font-size: 11px;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: .1em;
}
.field-readout b {
  display: block;
  margin-top: 6px;
  font-size: 17px;
  color: var(--ink);
}
.field-metrics {
  grid-column: 2;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 10px;
  margin-top: 12px;
}
.field-metrics article {
  min-height: 116px;
  padding: 18px;
  border: 1px solid var(--line);
  border-radius: 18px;
  background: rgba(255, 255, 255, .04);
}
.field-metrics span {
  color: var(--muted);
  font-size: 11px;
  font-weight: 800;
  letter-spacing: .1em;
  text-transform: uppercase;
}
.field-metrics b {
  display: block;
  margin-top: 10px;
  font-size: 18px;
  line-height: 1.25;
  color: var(--ink);
}

/* ===== Tools hub ===== */
.tools-hub {
  padding: 84px 0;
  background: var(--paper);
  color: var(--paper-ink);
}
.tools-hub .eyebrow { color: var(--primary-dark); }
.tools-layout {
  display: grid;
  grid-template-columns: .56fr 1fr;
  gap: 34px;
  align-items: start;
}
.tools-head { position: sticky; top: 92px; }
.tools-head h2 {
  margin: 18px 0 0;
  font-size: clamp(32px, 4.6vw, 56px);
  line-height: 1.02;
  letter-spacing: -.015em;
  color: var(--paper-ink);
}
.tools-head p {
  max-width: 540px;
  margin: 20px 0 0;
  color: #5a6470;
  font-size: 17px;
}
.tools-console {
  border: 1px solid rgba(30, 40, 50, .12);
  border-radius: 22px;
  background: rgba(255, 255, 255, .76);
  box-shadow: 0 28px 90px rgba(30, 40, 50, .14);
  overflow: hidden;
}
.tools-tabs {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1px;
  background: rgba(30, 40, 50, .12);
}
.tools-tabs button {
  min-height: 58px;
  border: 0;
  background: #fff;
  color: #5a6470;
  font-weight: 800;
  cursor: pointer;
  transition: color .15s ease, background .15s ease;
}
.tools-tabs button:hover { color: var(--primary-dark); }
.tools-tabs button.is-active {
  background: var(--primary-dark);
  color: var(--accent);
}
.tools-content {
  display: grid;
  grid-template-columns: 1fr;
  align-items: stretch;
  padding: 20px;
}
.tools-copy {
  display: grid;
  grid-template-rows: auto auto minmax(72px, auto) minmax(116px, auto) auto;
  align-content: center;
  min-height: 390px;
  padding: 30px;
  border-radius: 18px;
  background: var(--primary-dark);
  color: #fff;
}
.tools-copy span {
  color: var(--accent);
  font-size: 12px;
  font-weight: 800;
  letter-spacing: .12em;
  text-transform: uppercase;
}
.tools-copy h3 {
  margin: 12px 0 0;
  font-size: clamp(28px, 3.6vw, 44px);
  line-height: 1.02;
  letter-spacing: -.015em;
}
.tools-copy p {
  margin: 16px 0 0;
  color: var(--ink-2);
  font-size: 16px;
}
.tools-copy ul {
  display: grid;
  gap: 8px;
  margin: 20px 0 0;
  padding: 0;
  list-style: none;
}
.tools-copy li {
  display: flex;
  align-items: center;
  gap: 9px;
  color: #dbe2eb;
  font-weight: 700;
}
.tools-copy li:before {
  content: "";
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--accent);
  box-shadow: 0 0 12px rgba(169, 143, 106, .5);
}
.tools-copy a {
  min-height: 44px;
  display: inline-flex;
  align-items: center;
  justify-self: start;
  margin-top: 24px;
  padding: 0 17px;
  border-radius: 999px;
  background: linear-gradient(135deg, var(--accent), var(--accent-2));
  color: var(--primary-dark);
  font-weight: 800;
}

/* ===== Briefing / layer grid ===== */
.briefing { padding: 80px 0; }
.briefing-grid {
  display: grid;
  grid-template-columns: .62fr 1fr;
  gap: 36px;
}
.briefing h2,
.proof-wall h2,
.allocator h2 {
  margin: 18px 0 0;
  font-size: clamp(32px, 4.6vw, 56px);
  line-height: 1.02;
  letter-spacing: -.015em;
}
.layer-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
}
.layer-grid article,
.proof-layout article {
  min-height: 190px;
  padding: 22px;
  border: 1px solid var(--line);
  border-radius: 18px;
  background: rgba(255, 255, 255, .04);
  transition: transform .2s ease, border-color .2s ease;
}
.layer-grid article:hover,
.proof-layout article:hover {
  transform: translateY(-3px);
  border-color: rgba(169, 143, 106, .42);
}
.layer-grid span {
  color: var(--accent);
  font-family: var(--mono);
  font-weight: 800;
}
.layer-grid b,
.proof-layout b {
  display: block;
  margin-top: 12px;
  font-size: 20px;
  letter-spacing: -.005em;
}
.layer-grid p,
.proof-layout p {
  margin: 12px 0 0;
  color: var(--ink-2);
  font-size: 15px;
}

/* ===== Allocator ===== */
.allocator {
  padding: 82px 0;
  color: var(--paper-ink);
  background: linear-gradient(135deg, var(--paper) 0%, var(--paper-2) 100%);
}
.allocator .eyebrow { color: var(--primary-dark); }
.allocator-copy p { color: #5a6470; font-size: 17px; max-width: 540px; }
.allocator-grid {
  display: grid;
  grid-template-columns: 1fr .82fr;
  gap: 42px;
  align-items: center;
}
.allocator-card {
  display: grid;
  grid-template-columns: .86fr 1fr;
  gap: 18px;
  padding: 20px;
  border: 1px solid rgba(30, 40, 50, .12);
  border-radius: 22px;
  background: rgba(255, 255, 255, .76);
  box-shadow: 0 28px 90px rgba(30, 40, 50, .16);
}
.allocation-output {
  container-type: inline-size;
  display: grid;
  grid-template-rows: auto minmax(72px, auto) auto;
  align-content: center;
  min-height: 260px;
  padding: 24px;
  border-radius: 18px;
  color: var(--ink);
  background: var(--primary-dark);
}
.allocation-output span,
.allocation-output small { color: #a5b5c2; }
.allocation-output small {
  display: block;
  min-height: 18px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.allocation-output strong {
  display: flex;
  align-items: center;
  width: 100%;
  min-height: 72px;
  margin: 8px 0;
  color: var(--accent);
  font-size: clamp(28px, 15cqw, 54px);
  line-height: 1;
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
  overflow: hidden;
}
.allocation-controls { display: grid; align-content: center; gap: 16px; }
.allocation-controls label {
  display: grid;
  gap: 9px;
  color: var(--paper-ink);
  font-weight: 800;
}
.allocation-controls label span {
  display: flex;
  justify-content: space-between;
  gap: 14px;
}
.allocation-controls output {
  color: var(--primary-dark);
  font-family: var(--mono);
}
.allocation-controls input {
  width: 100%;
  accent-color: var(--primary);
}
.allocation-controls select {
  height: 46px;
  border: 1px solid rgba(30, 40, 50, .18);
  border-radius: 12px;
  background: #fff;
  color: var(--paper-ink);
  font-weight: 800;
  padding: 0 12px;
}

/* ===== Proof wall ===== */
.proof-wall { padding: 80px 0; }
.proof-layout {
  display: grid;
  grid-template-columns: 1.2fr repeat(3, 1fr);
  gap: 12px;
}
.proof-lead { min-height: 260px; }

/* ===== Author panel ===== */
.author-panel {
  padding: 78px 0;
  background: var(--paper);
  color: var(--paper-ink);
}
.author-panel .eyebrow { color: var(--primary-dark); }
.author-card {
  display: grid;
  grid-template-columns: 220px minmax(0, 1fr);
  gap: 28px;
  align-items: center;
  padding: 24px;
  border: 1px solid rgba(30, 40, 50, .12);
  border-radius: 24px;
  background: rgba(255, 255, 255, .8);
  box-shadow: 0 28px 90px rgba(30, 40, 50, .14);
}
.author-card__avatar {
  width: 100%;
  aspect-ratio: 1;
  display: grid;
  place-items: center;
  border-radius: 22px;
  overflow: hidden;
  background: linear-gradient(135deg, var(--accent), var(--accent-2));
  color: var(--primary-dark);
  font-size: 48px;
  font-weight: 900;
}
.author-card h2 {
  margin: 16px 0 0;
  font-size: clamp(28px, 4.2vw, 48px);
  line-height: 1.04;
  letter-spacing: -.015em;
}
.author-card__name {
  display: inline-flex;
  margin-top: 16px;
  color: var(--primary-dark);
  font-size: 22px;
  font-weight: 900;
  text-decoration: underline;
  text-underline-offset: 4px;
}
.author-card__role {
  margin: 6px 0 0;
  color: var(--primary-dark);
  font-weight: 800;
}
.author-card p:not(.author-card__role) {
  max-width: 720px;
  margin: 14px 0 0;
  color: #5a6470;
  font-size: 16px;
}
.author-card__link {
  min-height: 44px;
  display: inline-flex;
  align-items: center;
  margin-top: 20px;
  padding: 0 17px;
  border-radius: 999px;
  background: var(--primary-dark);
  color: var(--accent);
  font-weight: 800;
}

/* ===== FAQ ===== */
.seo-faq { padding: 82px 0; }
.seo-faq__head { max-width: 840px; margin-bottom: 26px; }
.seo-faq__head h2 {
  margin: 18px 0 0;
  font-size: clamp(32px, 4.6vw, 56px);
  line-height: 1.02;
  letter-spacing: -.015em;
}
.seo-faq__head p {
  margin: 18px 0 0;
  color: var(--ink-2);
  font-size: 17px;
}
.seo-faq__grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
}
.seo-faq__item {
  border: 1px solid var(--line);
  border-radius: 18px;
  background: rgba(255, 255, 255, .04);
  overflow: hidden;
  transition: border-color .18s ease;
}
.seo-faq__item:hover { border-color: rgba(169, 143, 106, .35); }
.seo-faq__item summary {
  min-height: 68px;
  display: flex;
  align-items: center;
  padding: 18px 20px;
  color: var(--ink);
  font-size: 17px;
  font-weight: 800;
  cursor: pointer;
  list-style: none;
}
.seo-faq__item summary::-webkit-details-marker { display: none; }
.seo-faq__item summary:after {
  content: "+";
  margin-left: auto;
  color: var(--accent);
  font-size: 22px;
  font-weight: 700;
  transition: transform .2s ease;
}
.seo-faq__item[open] summary:after { transform: rotate(45deg); }
.seo-faq__item p {
  margin: 0;
  padding: 0 20px 20px;
  color: var(--ink-2);
  line-height: 1.7;
  font-size: 15px;
}

/* ===== SEO content block ===== */
.seo-content {
  padding: 80px 0;
  background: rgba(255, 255, 255, .02);
  border-block: 1px solid var(--line);
}
.seo-content .wrap { max-width: 880px; }
.seo-content h2 {
  margin: 0 0 18px;
  font-size: clamp(28px, 3.6vw, 42px);
  line-height: 1.08;
  letter-spacing: -.015em;
}
.seo-content h3 {
  margin: 36px 0 12px;
  font-size: 22px;
  line-height: 1.2;
  color: var(--accent-2);
}
.seo-content p {
  margin: 14px 0 0;
  color: var(--ink-2);
  font-size: 16px;
  line-height: 1.75;
}
.seo-content ul {
  margin: 14px 0 0;
  padding-left: 22px;
  color: var(--ink-2);
}
.seo-content ul li {
  margin: 8px 0;
  line-height: 1.65;
}
.seo-content strong { color: var(--ink); }

/* ===== Floating brief ===== */
.floating-brief {
  position: fixed;
  left: 18px;
  bottom: 18px;
  z-index: 25;
  width: min(340px, calc(100vw - 36px));
  padding: 10px;
  border: 1px solid rgba(169, 143, 106, .3);
  border-radius: 18px;
  background: rgba(22, 32, 42, .88);
  box-shadow: 0 20px 60px rgba(0, 0, 0, .34);
  backdrop-filter: blur(18px);
  opacity: 0;
  transform: translateY(18px);
  pointer-events: none;
  transition: opacity .24s ease, transform .24s ease;
}
.floating-brief.is-visible {
  opacity: 1;
  transform: translateY(0);
  pointer-events: auto;
}
.floating-brief a {
  display: flex;
  min-height: 48px;
  align-items: center;
  justify-content: center;
  padding: 0 18px;
  border-radius: 999px;
  color: var(--primary-dark);
  background: linear-gradient(135deg, var(--accent), var(--accent-2));
  font-weight: 800;
  text-align: center;
}

/* ===== Footer ===== */
.site-footer {
  padding: 56px 0 36px;
  border-top: 1px solid var(--line);
  color: var(--ink-2);
  font-size: 14px;
  background: #11181f;
}
.site-footer__top {
  display: grid;
  grid-template-columns: 1.4fr repeat(3, 1fr);
  gap: 36px;
  margin-bottom: 36px;
}
.site-footer__col h4 {
  margin: 0 0 14px;
  color: var(--accent);
  font-size: 12px;
  letter-spacing: .14em;
  text-transform: uppercase;
  font-weight: 800;
}
.site-footer__col ul {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 10px;
}
.site-footer__col a {
  color: var(--ink-2);
  transition: color .15s ease;
}
.site-footer__col a:hover { color: var(--ink); }
.site-footer__brand {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 14px;
}
.site-footer__brand .brand__mark {
  width: 38px;
  height: 38px;
}
.site-footer__about {
  max-width: 320px;
  line-height: 1.65;
  color: var(--muted);
  font-size: 14px;
}
.site-footer__inner {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
  justify-content: space-between;
  padding-top: 24px;
  border-top: 1px solid var(--line);
  color: var(--muted);
  font-size: 13px;
}
.site-footer__inner a {
  text-decoration: underline;
  text-underline-offset: 3px;
}
.site-footer__disclaimer {
  margin-top: 18px;
  padding: 18px;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: rgba(255, 255, 255, .03);
  color: var(--muted);
  font-size: 13px;
  line-height: 1.7;
}

/* ===== Lang switch ===== */
.lang-switch { position: fixed; top: 16px; right: 16px; z-index: 45; }
.lang-switch details { position: relative; }
.lang-switch summary {
  min-height: 40px;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 0 14px;
  border: 1px solid var(--line-strong);
  border-radius: 999px;
  background: rgba(22, 32, 42, .84);
  color: var(--ink);
  box-shadow: 0 18px 50px rgba(0, 0, 0, .26);
  backdrop-filter: blur(16px);
  cursor: pointer;
  font-size: 12px;
  font-weight: 800;
  list-style: none;
}
.lang-switch summary::-webkit-details-marker { display: none; }
.lang-switch summary:after {
  content: "";
  width: 6px;
  height: 6px;
  border-right: 2px solid currentColor;
  border-bottom: 2px solid currentColor;
  transform: rotate(45deg) translateY(-2px);
  opacity: .7;
}
.lang-switch .fi {
  width: 18px;
  height: 13px;
  flex: 0 0 auto;
  border-radius: 2px;
}
.lang-switch__list {
  position: absolute;
  top: calc(100% + 8px);
  right: 0;
  width: 230px;
  padding: 8px;
  border: 1px solid var(--line-strong);
  border-radius: 16px;
  background: rgba(22, 32, 42, .94);
  box-shadow: 0 22px 70px rgba(0, 0, 0, .36);
  backdrop-filter: blur(18px);
}
.lang-switch__list a {
  display: flex;
  align-items: center;
  gap: 9px;
  min-height: 38px;
  padding: 0 10px;
  border-radius: 10px;
  color: var(--ink-2);
  font-size: 13px;
  font-weight: 800;
}
.lang-switch__list a:hover,
.lang-switch__list a.is-active {
  color: var(--ink);
  background: rgba(255, 255, 255, .06);
}
@media (max-width: 760px) {
  .lang-switch { display: none; }
}

/* ===== Sub-page header (for tech pages) ===== */
.page-head {
  padding: 80px 0 40px;
  text-align: left;
}
.page-head h1 {
  margin: 16px 0 0;
  font-size: clamp(36px, 5.4vw, 64px);
  line-height: 1;
  letter-spacing: -.02em;
  font-weight: 900;
  max-width: 900px;
}
.page-head p.lede {
  max-width: 720px;
  margin: 22px 0 0;
  color: var(--ink-2);
  font-size: 18px;
}

.text-page {
  padding: 30px 0 90px;
}
.text-page .wrap { max-width: 880px; }
.text-page h2 {
  margin: 40px 0 12px;
  font-size: 26px;
  line-height: 1.18;
  letter-spacing: -.01em;
}
.text-page h3 {
  margin: 28px 0 10px;
  font-size: 19px;
  color: var(--accent-2);
}
.text-page p {
  margin: 12px 0 0;
  color: var(--ink-2);
  line-height: 1.75;
  font-size: 16px;
}
.text-page ul,
.text-page ol {
  margin: 12px 0 0;
  padding-left: 22px;
  color: var(--ink-2);
  line-height: 1.75;
}
.text-page ul li,
.text-page ol li { margin: 6px 0; }
.text-page strong { color: var(--ink); }
.text-page a { color: var(--accent-2); text-decoration: underline; text-underline-offset: 3px; }

/* Reveal animation — progressive enhancement (only hide when JS confirmed) */
.has-js .reveal-item {
  opacity: 0;
  transform: translateY(22px);
  transition: opacity .52s ease, transform .52s ease;
}
.has-js .reveal-item.is-inview { opacity: 1; transform: translateY(0); }
.has-js .reveal-item:nth-child(2) { transition-delay: .06s; }
.has-js .reveal-item:nth-child(3) { transition-delay: .12s; }
.has-js .reveal-item:nth-child(4) { transition-delay: .18s; }

@media (prefers-reduced-motion: reduce) {
  .strip-track { animation: none; }
  .has-js .reveal-item,
  .floating-brief { transition: none; transform: none; opacity: 1; }
}

/* ===== Responsive ===== */
@media (max-width: 1080px) {
  .field-grid,
  .market-field-grid,
  .tools-layout,
  .briefing-grid,
  .allocator-grid,
  .proof-layout {
    grid-template-columns: 1fr;
  }
  .field-visual,
  .hero-form,
  .field-metrics { grid-column: auto; grid-row: auto; }
  .hero-form,
  .market-field-copy,
  .tools-head { position: static; }
  .seo-faq__grid { grid-template-columns: 1fr; }
  .author-card { grid-template-columns: 1fr; }
  .author-card__avatar { max-width: 220px; }
  .site-footer__top { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 760px) {
  /* backdrop-filter on .topbar creates a containing block for position:fixed
     descendants in Chromium — drop it on mobile so the nav panel covers the viewport */
  .topbar { backdrop-filter: none; -webkit-backdrop-filter: none; background: rgba(22, 32, 42, .96); }
  .nav-toggle { display: inline-flex; }
  .nav {
    position: fixed;
    left: 0;
    right: 0;
    top: 70px;
    bottom: 0;
    background: rgba(22, 32, 42, .98);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    flex-direction: column;
    align-items: stretch;
    padding: 22px 22px 40px;
    gap: 0;
    transform: translateY(-12px);
    transition: transform .26s ease, opacity .26s ease, visibility .26s ease;
    opacity: 0;
    visibility: hidden;
    border-top: 1px solid var(--line);
    overflow-y: auto;
    overscroll-behavior: contain;
  }
  .nav.is-open {
    transform: translateY(0);
    opacity: 1;
    visibility: visible;
  }
  .nav a {
    padding: 18px 4px;
    border-bottom: 1px solid var(--line);
    font-size: 16px;
    color: var(--ink);
  }
  .nav a.is-active { color: var(--accent); }
  .nav a.is-active:after { display: none; }
  .nav__cta {
    margin-top: 18px;
    min-height: 48px;
    justify-content: center;
    text-align: center;
    border-bottom: 0 !important;
    padding: 0 22px;
  }
  body.nav-locked { overflow: hidden; }

  .brand__name { max-width: 52vw; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
  .field-body,
  .field-readout,
  .field-metrics,
  .tools-tabs,
  .layer-grid,
  .allocator-card { grid-template-columns: 1fr; }
  .asset-rail {
    grid-template-columns: repeat(2, 1fr);
    border-right: 0;
    border-bottom: 1px solid var(--line);
  }
  .form-row { grid-template-columns: 1fr; }
  .hero-copy { padding-top: 16px; }
  .hero-copy h1 { font-size: clamp(36px, 11vw, 56px); }
  .tools-copy { min-height: 360px; padding: 24px; }
  .floating-brief { display: none; }
  .site-footer__top { grid-template-columns: 1fr; }
  .hero-meta { grid-template-columns: 1fr 1fr; }
  .author-card__avatar { max-width: 120px; font-size: 38px; border-radius: 18px; }
  .query-brand { display: none; }
  .page-head h1 { font-size: clamp(30px, 8vw, 44px); }
  .text-page { padding: 40px 0; }
  .text-page h2 { font-size: clamp(22px, 5.5vw, 28px); margin-top: 28px; }
  .text-page h3 { font-size: clamp(18px, 4.5vw, 22px); }
  .text-page p, .text-page li { font-size: 15px; }
}
@media (max-width: 480px) {
  .topbar__inner { gap: 10px; min-height: 64px; }
  .nav { top: 64px; }
  .brand__name { max-width: 42vw; font-size: 15px; }
  .brand__mark { width: 36px; height: 36px; font-size: 18px; }
  .nav-toggle { width: 42px; height: 42px; }
  .lead-card { padding: 18px; }
  .lead-card__head h2 { font-size: 22px; }
  .wrap { width: calc(100% - 24px); }
  .hero-meta { grid-template-columns: 1fr; gap: 12px; }
  .hero-meta > div { padding: 12px 14px; }
  .seo-faq__item summary { font-size: 15px; padding: 14px 16px; }
  .form-submit { width: 100%; }
}
