/* Layout concept: an institutional advisory site. Quiet navy-and-paper pages built on a 12-col container,
   with one deep "settlement" band carrying the layered architecture diagram, where the logo green marks the T+0 layer. */
:root {
  --paper: #f4f6f8;
  --surface: #ffffff;
  --ink: #0d2035;
  --ink-2: #485a70;
  --ink-3: #73849a;
  --line: #d9e0e8;
  --deep: #0d2035;
  --deep-2: #142a44;
  --deep-line: #27415f;
  --on-deep: #e8eef5;
  --on-deep-2: #98abc1;
  --accent: #30a16d;
  --accent-bright: #3fb67f;
  --accent-soft: #e1f2e9;
  --accent-ink: #1e7a50;
  --coin: #e4b44e;
  --bank: #7d9cc8;
  --digital: #a99be6;
  --chain: #9aa7bb;

  --f-display: "Source Serif 4", "Iowan Old Style", Georgia, serif;
  --f-body: "IBM Plex Sans", "Helvetica Neue", Arial, sans-serif;
  --f-mono: "IBM Plex Mono", ui-monospace, "SF Mono", Menlo, monospace;

  --s-xs: 0.8125rem;
  --s-sm: 0.9375rem;
  --s-md: 1.0625rem;
  --s-lg: 1.375rem;
  --s-xl: clamp(1.75rem, 1.2rem + 2vw, 2.5rem);
  --s-2xl: clamp(2.4rem, 1.4rem + 4vw, 4.25rem);

  --wrap: 1200px;
  --radius: 6px;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --paper: #0a1524;
    --surface: #102035;
    --ink: #e8edf4;
    --ink-2: #a3b1c4;
    --ink-3: #7d8ca2;
    --line: #213651;
    --deep: #0c1c30;
    --deep-2: #132840;
    --deep-line: #29425f;
    --on-deep: #e8eef5;
    --on-deep-2: #98abc1;
    --accent: #3fb67f;
    --accent-bright: #4cc68c;
    --accent-soft: #11291f;
    --accent-ink: #5ed39b;
    color-scheme: dark;
  }
}
:root[data-theme="dark"] {
  --paper: #0a1524;
  --surface: #102035;
  --ink: #e8edf4;
  --ink-2: #a3b1c4;
  --ink-3: #7d8ca2;
  --line: #213651;
  --deep: #0c1c30;
  --deep-2: #132840;
  --deep-line: #29425f;
  --on-deep: #e8eef5;
  --on-deep-2: #98abc1;
  --accent: #3fb67f;
  --accent-bright: #4cc68c;
  --accent-soft: #11291f;
  --accent-ink: #5ed39b;
  color-scheme: dark;
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--f-body);
  font-size: var(--s-md);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}
img { max-width: 100%; }
a { color: inherit; }
h1, h2, h3 { font-family: var(--f-display); font-weight: 500; line-height: 1.12; text-wrap: balance; margin: 0; letter-spacing: -0.01em; }
p { margin: 0; }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; border-radius: 2px; }

.wrap {
  max-width: var(--wrap);
  margin-inline: auto;
  padding-left: max(24px, env(safe-area-inset-left, 0px));
  padding-right: max(24px, env(safe-area-inset-right, 0px));
}
@media (max-width: 480px) {
  .wrap { padding-left: max(16px, env(safe-area-inset-left, 0px)); padding-right: max(16px, env(safe-area-inset-right, 0px)); }
}

.eyebrow {
  font-family: var(--f-mono);
  font-size: var(--s-xs);
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--accent-ink);
}
.lede { font-size: var(--s-lg); line-height: 1.5; color: var(--ink-2); max-width: 40ch; }
.muted { color: var(--ink-2); }

/* Buttons */
.btn {
  display: inline-flex; align-items: center; gap: 0.5em;
  font: 500 var(--s-sm)/1 var(--f-body);
  padding: 0.95em 1.4em;
  border-radius: 2px;
  text-decoration: none;
  border: 1px solid transparent;
  cursor: pointer;
  transition: background-color .2s, color .2s, border-color .2s;
}
.btn-primary { background: var(--ink); color: var(--paper); }
.btn-primary:hover { background: var(--accent); color: #fff; }
.btn-ghost { border-color: var(--line); color: var(--ink); background: transparent; }
.btn-ghost:hover { border-color: var(--ink); }
.btn .arr { transition: transform .2s; }
.btn:hover .arr { transform: translateX(3px); }

/* Header */
.site-header {
  position: sticky; top: env(safe-area-inset-top, 0px); z-index: 50;
  background: color-mix(in srgb, var(--paper) 88%, transparent);
  backdrop-filter: saturate(1.4) blur(10px);
  -webkit-backdrop-filter: saturate(1.4) blur(10px);
  border-bottom: 1px solid var(--line);
}
.nav { display: flex; align-items: center; justify-content: space-between; gap: 24px; height: 68px; }
.logo { display: inline-flex; align-items: center; gap: 10px; text-decoration: none; color: var(--ink); }
.logo-svg { width: 46px; height: auto; flex: none; }
.logo-mark { font-family: var(--f-mono); font-weight: 600; font-size: 1.35rem; letter-spacing: -0.02em; color: var(--ink); }
.logo-sub { font-size: var(--s-xs); color: var(--ink-3); letter-spacing: 0.02em; }
.nav-links { display: flex; align-items: center; gap: 32px; list-style: none; margin: 0; padding: 0; }
.nav-links a { text-decoration: none; font-size: var(--s-sm); color: var(--ink-2); }
.nav-links a:hover, .nav-links a[aria-current="page"] { color: var(--ink); }
.nav-links a[aria-current="page"] { box-shadow: inset 0 -2px 0 var(--accent); padding-bottom: 4px; }
.nav-links .btn { padding: 0.75em 1.1em; color: var(--paper); }
.nav-links .btn:hover { color: #fff; }
.nav-toggle { display: none; background: none; border: 1px solid var(--line); color: var(--ink); border-radius: 2px; padding: 8px 12px; font: 500 var(--s-xs) var(--f-mono); letter-spacing: .06em; cursor: pointer; }
@media (max-width: 820px) {
  .logo-sub { display: none; }
  .nav-toggle { display: inline-block; }
  .nav-links {
    position: absolute; left: 0; right: 0; top: 68px;
    flex-direction: column; align-items: stretch; gap: 0;
    background: var(--surface); border-bottom: 1px solid var(--line);
    padding: 8px max(16px, env(safe-area-inset-right, 0px)) 16px max(16px, env(safe-area-inset-left, 0px));
    display: none;
  }
  .nav-links.open { display: flex; }
  .nav-links li a { display: block; padding: 12px 0; }
  .nav-links a[aria-current="page"] { box-shadow: none; color: var(--accent-ink); }
  .nav-links .btn { justify-content: center; margin-top: 8px; }
}

/* Sections */
.section { padding-block: clamp(64px, 8vw, 112px); }
.section + .section { border-top: 1px solid var(--line); }
.section-head { display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 6fr); gap: 32px 64px; align-items: end; margin-bottom: 48px; }
.section-head h2 { font-size: var(--s-xl); margin-top: 12px; }
.section-head p { color: var(--ink-2); max-width: 56ch; }
@media (max-width: 820px) { .section-head { grid-template-columns: 1fr; } }

/* Hero */
.hero { padding-block: clamp(56px, 7vw, 96px) clamp(48px, 6vw, 72px); }
.hero-grid { display: grid; grid-template-columns: minmax(0, 7fr) minmax(0, 5fr); gap: 48px 72px; align-items: end; }
.hero h1 { font-size: var(--s-2xl); margin-top: 18px; font-weight: 400; }
.hero h1 em { font-style: italic; color: var(--accent-ink); }
.hero .lede { margin-top: 24px; }
.hero-cta { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 36px; }
@media (max-width: 900px) { .hero-grid { grid-template-columns: 1fr; } }

/* Settlement clock: T+2 -> T+1 -> T+0 */
.clock { border-top: 1px solid var(--ink); }
.clock-row { display: grid; grid-template-columns: 72px minmax(0, 1fr); gap: 16px; padding: 16px 0; border-bottom: 1px solid var(--line); align-items: baseline; }
.clock-row .t { font-family: var(--f-mono); font-size: 1.5rem; font-weight: 500; color: var(--ink-3); font-variant-numeric: tabular-nums; }
.clock-row .d { font-size: var(--s-sm); color: var(--ink-2); }
.clock-row .d strong { display: block; color: var(--ink); font-weight: 500; }
.clock-row.now .t { color: var(--accent); }
.clock-cap { font-family: var(--f-mono); font-size: var(--s-xs); color: var(--ink-3); margin-top: 12px; letter-spacing: .04em; }

/* ============ Architecture band ============ */
.arch-band { background: var(--deep); color: var(--on-deep); padding-block: clamp(64px, 8vw, 104px); position: relative; overflow: hidden; }
.arch-band::before {
  content: ""; position: absolute; inset: 0; pointer-events: none; opacity: .5;
  background-image:
    linear-gradient(to right, color-mix(in srgb, var(--deep-line) 45%, transparent) 1px, transparent 1px),
    linear-gradient(to bottom, color-mix(in srgb, var(--deep-line) 45%, transparent) 1px, transparent 1px);
  background-size: 48px 48px;
  mask-image: radial-gradient(ellipse at 30% 50%, #000 25%, transparent 70%);
  -webkit-mask-image: radial-gradient(ellipse at 30% 50%, #000 25%, transparent 70%);
}
.arch-band .wrap { position: relative; }
.arch-band .eyebrow { color: var(--accent-bright); }
.arch-intro { display: grid; grid-template-columns: minmax(0, 6fr) minmax(0, 5fr); gap: 24px 64px; align-items: end; margin-bottom: 32px; }
.arch-intro h2 { font-size: var(--s-xl); margin-top: 12px; color: var(--on-deep); }
.arch-intro p { color: var(--on-deep-2); max-width: 52ch; }
@media (max-width: 900px) { .arch-intro { grid-template-columns: 1fr; } }

.iso-scroll { overflow-x: auto; -webkit-overflow-scrolling: touch; }
.iso { display: block; width: 100%; height: auto; min-width: 760px; }
.scroll-hint { display: none; font-family: var(--f-mono); font-size: var(--s-xs); color: var(--on-deep-2); margin-bottom: 8px; }
@media (max-width: 800px) { .scroll-hint { display: block; } }

/* Slabs */
.iso-layer { transition: opacity .3s; }
.iso.focus .iso-layer:not(.hot) { opacity: .28; }
.f-top { fill: color-mix(in srgb, var(--lc) 20%, var(--deep-2)); stroke: var(--lc); stroke-width: 1.3; stroke-linejoin: round; }
.f-left { fill: color-mix(in srgb, var(--lc) 42%, var(--deep)); }
.f-right { fill: color-mix(in srgb, var(--lc) 26%, var(--deep)); }
.f-grid { stroke: var(--lc); stroke-opacity: .16; stroke-width: 1; }
.iso-layer[data-layer="t0"] .f-top { fill: color-mix(in srgb, var(--lc) 30%, var(--deep-2)); stroke-width: 1.8; }
.iso-layer[data-layer="t0"] .f-left { fill: color-mix(in srgb, var(--lc) 62%, var(--deep)); }
.iso-layer[data-layer="t0"] .f-right { fill: color-mix(in srgb, var(--lc) 44%, var(--deep)); }

.cube .c-t { fill: color-mix(in srgb, var(--lc) 55%, var(--deep-2)); stroke: var(--lc); stroke-width: .8; }
.cube .c-l { fill: color-mix(in srgb, var(--lc) 38%, var(--deep)); stroke: var(--lc); stroke-opacity: .5; stroke-width: .6; }
.cube .c-r { fill: color-mix(in srgb, var(--lc) 22%, var(--deep)); stroke: var(--lc); stroke-opacity: .5; stroke-width: .6; }
.blk-glow { fill: var(--accent-bright); }
.chain-link { stroke: var(--lc); stroke-width: 2; stroke-dasharray: 2 3; }
.stk-side { fill: color-mix(in srgb, var(--lc) 40%, var(--deep)); stroke: var(--lc); stroke-width: .8; }
.stk-top { fill: color-mix(in srgb, var(--lc) 70%, var(--deep-2)); stroke: var(--lc); stroke-width: .8; }
.t0-link { stroke: var(--accent-bright); stroke-width: 1.2; stroke-dasharray: 3 4; opacity: .8; }
.t0-ring { fill: none; stroke: var(--accent-bright); stroke-width: 1.2; }
.t0-logo .ring { fill: none; stroke: var(--on-deep); }
.t0-logo .line, .t0-logo .dot { fill: var(--accent-bright); }

/* Callouts */
.co-lead { stroke: var(--lc); stroke-width: 1; stroke-dasharray: 2 4; }
.co-end, .co-dot { fill: var(--lc); }
.co-bar { fill: var(--lc); }
.co-name { font: 500 23px var(--f-display); fill: var(--on-deep); }
.iso-layer[data-layer="t0"] .co-name { fill: var(--accent-bright); }
.co-tag { font: 500 11px var(--f-mono); letter-spacing: .08em; fill: var(--on-deep-2); }
.co-item { font: 400 13.5px var(--f-body); fill: var(--on-deep); }

/* Flows */
.pipe-bed { stroke-width: 8; stroke-linecap: round; opacity: .18; }
.pipe { stroke-width: 1.4; stroke-dasharray: 4 5; animation: flow 1s linear infinite; }
.pipe-bed.cash, .pipe.cash { stroke: var(--coin); }
.pipe-bed.asset, .pipe.asset { stroke: var(--digital); }
.pipe.asset { animation-direction: reverse; }
.pipe-bed.chainp, .pipe.chainp { stroke: var(--on-deep); }
@keyframes flow { to { stroke-dashoffset: -18; } }
.port { fill: var(--deep); stroke: var(--on-deep-2); stroke-width: 1; }
.coin { fill: var(--coin); stroke: #7f5a14; stroke-width: 1.5; }
.coin-t { font: 700 12px var(--f-mono); fill: #2a1d05; }
.token { fill: var(--digital); stroke: color-mix(in srgb, var(--digital) 50%, #fff); stroke-width: 1.2; }
.token-in { fill: var(--deep); opacity: .55; }
.settle { fill: var(--on-deep); }
.fl-h { font: 600 11px var(--f-mono); letter-spacing: .08em; fill: var(--coin); }
.fl-h.a { fill: var(--digital); }
.fl-s { font: 400 11px var(--f-mono); fill: var(--on-deep-2); }

.arch-foot { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 12px 32px; margin-top: 20px; font-family: var(--f-mono); font-size: var(--s-xs); color: var(--on-deep-2); }
.legend { display: flex; flex-wrap: wrap; gap: 8px 22px; align-items: center; }
.legend span { display: inline-flex; align-items: center; gap: 8px; }
.legend i { width: 12px; height: 12px; display: inline-block; background: var(--c); }
.legend i.round { border-radius: 50%; }
.legend i.dia { transform: rotate(45deg) scale(.85); }

@media (prefers-reduced-motion: reduce) { .pipe { animation: none; } }

/* Stats */
.stats { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); border-top: 1px solid var(--ink); }
.stat { padding: 28px 28px 28px 0; border-right: 1px solid var(--line); }
.stat + .stat { padding-left: 28px; }
.stat:last-child { border-right: 0; }
.stat .v { font-family: var(--f-display); font-size: clamp(2.4rem, 1.6rem + 2.6vw, 3.6rem); line-height: 1; font-variant-numeric: tabular-nums; letter-spacing: -0.02em; }
.stat .v small { font-size: .5em; color: var(--ink-3); margin-left: 4px; }
.stat .l { margin-top: 14px; color: var(--ink-2); font-size: var(--s-sm); max-width: 32ch; }
.sources { margin-top: 24px; font-size: var(--s-xs); color: var(--ink-3); max-width: 90ch; }
.sources a { color: var(--ink-2); }
@media (max-width: 760px) {
  .stats { grid-template-columns: 1fr; }
  .stat, .stat + .stat { padding: 24px 0; border-right: 0; border-bottom: 1px solid var(--line); }
}

/* Generic grids */
.grid-3 { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 0; border-top: 1px solid var(--line); }
.cell { padding: 28px 28px 8px 0; min-width: 0; }
.cell + .cell { padding-left: 28px; border-left: 1px solid var(--line); }
.cell h3 { font-size: var(--s-lg); margin-bottom: 10px; }
.cell p { color: var(--ink-2); font-size: var(--s-sm); }
.cell .k { font-family: var(--f-mono); font-size: var(--s-xs); color: var(--accent-ink); letter-spacing: .06em; text-transform: uppercase; display: block; margin-bottom: 14px; }
@media (max-width: 860px) {
  .grid-3 { grid-template-columns: 1fr; }
  .cell, .cell + .cell { padding: 24px 0; border-left: 0; border-bottom: 1px solid var(--line); }
}

/* Engagement path (a real sequence) */
.path { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 0; counter-reset: step; }
.step { position: relative; padding: 28px 24px 0 0; border-top: 2px solid var(--line); min-width: 0; }
.step::before { content: ""; position: absolute; top: -6px; left: 0; width: 10px; height: 10px; border-radius: 50%; background: var(--paper); border: 2px solid var(--accent); }
.step:last-child { border-top-color: var(--accent); }
.step .k { font-family: var(--f-mono); font-size: var(--s-xs); color: var(--ink-3); letter-spacing: .06em; }
.step h3 { font-size: 1.25rem; margin: 8px 0 10px; }
.step p { color: var(--ink-2); font-size: var(--s-sm); }
@media (max-width: 860px) {
  .path { grid-template-columns: 1fr; gap: 28px; border-left: 2px solid var(--line); padding-left: 24px; }
  .step { border-top: 0; padding: 0; }
  .step::before { left: -31px; top: 6px; }
}

/* CTA band */
.cta-band { background: var(--surface); border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); padding-block: clamp(56px, 7vw, 88px); }
.cta-inner { display: flex; flex-wrap: wrap; align-items: end; justify-content: space-between; gap: 28px; }
.cta-inner h2 { font-size: var(--s-xl); max-width: 22ch; }
.cta-inner p { color: var(--ink-2); margin-top: 12px; max-width: 52ch; }

/* Page hero (inner pages) */
.page-hero { padding-block: clamp(56px, 7vw, 96px) clamp(40px, 5vw, 64px); border-bottom: 1px solid var(--line); }
.page-hero h1 { font-size: clamp(2.2rem, 1.4rem + 3vw, 3.4rem); font-weight: 400; margin-top: 14px; max-width: 20ch; }
.page-hero .lede { margin-top: 20px; max-width: 52ch; }

/* Services list (services page) */
.svc-rows { border-top: 1px solid var(--ink); }
.svc-row { display: grid; grid-template-columns: 64px minmax(0, 4fr) minmax(0, 5fr) minmax(0, 3fr); gap: 16px 32px; padding: 32px 0; border-bottom: 1px solid var(--line); scroll-margin-top: 90px; }
.svc-row .n { font-family: var(--f-mono); color: var(--accent-ink); font-size: var(--s-sm); padding-top: 4px; }
.svc-row h3 { font-size: 1.5rem; }
.svc-row p { color: var(--ink-2); font-size: var(--s-sm); }
.svc-row ul { margin: 12px 0 0; padding-left: 18px; color: var(--ink-2); font-size: var(--s-sm); }
.svc-row ul li + li { margin-top: 4px; }
.svc-row .out { font-family: var(--f-mono); font-size: var(--s-xs); color: var(--ink-3); letter-spacing: .02em; line-height: 1.7; }
.svc-row .out b { display: block; color: var(--ink); font-weight: 500; letter-spacing: .06em; text-transform: uppercase; margin-bottom: 6px; }
@media (max-width: 900px) {
  .svc-row { grid-template-columns: 48px minmax(0, 1fr); }
  .svc-row > :nth-child(3), .svc-row > :nth-child(4) { grid-column: 2; }
}

/* Two-column prose */
.split { display: grid; grid-template-columns: minmax(0, 4fr) minmax(0, 7fr); gap: 32px 72px; }
.split h2 { font-size: var(--s-xl); }
.prose p + p { margin-top: 1em; }
.prose p { color: var(--ink-2); max-width: 64ch; }
.prose strong { color: var(--ink); font-weight: 500; }
@media (max-width: 860px) { .split { grid-template-columns: 1fr; } }

/* People */
.people { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 24px; }
.person { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 28px; display: grid; grid-template-columns: 64px minmax(0, 1fr); gap: 20px; }
.avatar { width: 64px; height: 64px; border-radius: 50%; display: grid; place-items: center; background: var(--deep); color: var(--accent-bright); font-family: var(--f-display); font-size: 1.4rem; }
.person h3 { font-size: 1.35rem; }
.person .role { font-family: var(--f-mono); font-size: var(--s-xs); color: var(--accent-ink); letter-spacing: .04em; margin: 4px 0 12px; }
.person p { color: var(--ink-2); font-size: var(--s-sm); }
@media (max-width: 760px) { .people { grid-template-columns: 1fr; } }

/* Contact */
.contact-grid { display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); gap: 40px 72px; }
.form { display: grid; gap: 18px; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: clamp(20px, 3vw, 36px); }
.form .row { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 18px; }
.field { display: grid; gap: 6px; min-width: 0; }
.field label { font-size: var(--s-xs); font-family: var(--f-mono); letter-spacing: .05em; text-transform: uppercase; color: var(--ink-2); }
.field input, .field select, .field textarea {
  font: inherit; font-size: var(--s-sm); color: var(--ink); background: var(--paper);
  border: 1px solid var(--line); border-radius: 3px; padding: 12px 14px; width: 100%;
}
.field textarea { min-height: 140px; resize: vertical; }
.field input:focus, .field select:focus, .field textarea:focus { outline: none; border-color: var(--accent); box-shadow: 0 0 0 3px color-mix(in srgb, var(--accent) 20%, transparent); }
.form-note { font-size: var(--s-xs); color: var(--ink-3); }
.form-status { font-size: var(--s-sm); color: var(--accent-ink); }
.contact-facts { display: grid; gap: 24px; align-content: start; }
.fact .k { font-family: var(--f-mono); font-size: var(--s-xs); letter-spacing: .06em; text-transform: uppercase; color: var(--ink-3); }
.fact .v { margin-top: 4px; font-size: var(--s-md); }
@media (max-width: 860px) { .contact-grid { grid-template-columns: 1fr; } .form .row { grid-template-columns: 1fr; } }

/* Footer */
.site-footer { padding-block: 48px 40px; font-size: var(--s-sm); color: var(--ink-2); }
.foot-grid { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 24px 48px; }
.foot-grid nav { display: flex; flex-wrap: wrap; gap: 8px 28px; }
.foot-grid nav a { text-decoration: none; }
.foot-grid nav a:hover { color: var(--ink); }
.foot-legal { margin-top: 32px; padding-top: 20px; border-top: 1px solid var(--line); font-size: var(--s-xs); color: var(--ink-3); display: flex; flex-wrap: wrap; justify-content: space-between; gap: 8px 24px; }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { transition-duration: 0s !important; }
}
