:root {
  color-scheme: dark;
  --night: #080807;
  --smoke: #111210;
  --panel: rgba(18, 19, 17, .82);
  --panel-strong: #151613;
  --gold: #e4ad4f;
  --amber: #f5c46b;
  --bronze: #825229;
  --ivory: #f2efe8;
  --muted: #aaa69d;
  --subtle: #77766e;
  --line: rgba(224, 174, 92, .21);
  --line-soft: rgba(244, 238, 221, .1);
  --green: #83c4a0;
  --red: #e79a7d;
  --page-gutter: clamp(20px, 5vw, 80px);
  font-family: 'DM Sans', 'Segoe UI', Arial, sans-serif;
  background: var(--night);
}

* { box-sizing: border-box; }
html { min-width: 0; min-height: 100%; scroll-behavior: smooth; scroll-padding-top: 92px; background: var(--night); }
body { margin: 0; min-height: 100vh; color: var(--ivory); background: var(--night); font-family: 'DM Sans', 'Segoe UI', Arial, sans-serif; -webkit-font-smoothing: antialiased; text-rendering: optimizeLegibility; }
body::before { position: fixed; z-index: -1; inset: 0; pointer-events: none; content: ''; background: radial-gradient(ellipse 45% 35% at 8% 0%, rgba(146, 83, 30, .12), transparent 75%), radial-gradient(ellipse 50% 35% at 100% 25%, rgba(124, 78, 28, .08), transparent 72%); }
a { color: inherit; text-decoration: none; }
button, input, textarea, select { color: inherit; font: inherit; }
button { cursor: pointer; }
img { max-width: 100%; }
::selection { color: #15100a; background: var(--amber); }
:focus-visible { outline: 2px solid var(--amber); outline-offset: 3px; }
.skip-link { position: fixed; z-index: 100; top: 12px; left: 12px; padding: 12px 16px; transform: translateY(-160%); background: var(--ivory); color: var(--night); }
.skip-link:focus { transform: translateY(0); }

.site-header { position: relative; z-index: 20; display: grid; grid-template-columns: minmax(150px, 1fr) auto minmax(150px, 1fr); align-items: center; gap: 22px; min-height: 76px; padding: 10px var(--page-gutter); background: transparent; }
.site-brand { display: inline-flex; align-items: center; gap: 12px; width: max-content; color: var(--ivory); font-size: 15px; font-weight: 600; letter-spacing: .13em; }
.site-brand img { display: block; width: 39px; height: 39px; object-fit: contain; }
.site-nav { display: flex; align-items: center; justify-content: center; gap: clamp(17px, 2.3vw, 34px); }
.site-nav a, .site-menu a { color: #bdb8ad; font-size: 15px; transition: color .18s ease; }
.site-nav a:hover, .site-nav a:focus-visible, .site-menu a:hover, .site-menu a:focus-visible { color: var(--amber); }
.site-nav a[aria-current="page"] { color: var(--ivory); }
.site-nav a[aria-current="page"]::after { display: block; height: 1px; margin-top: 6px; background: var(--gold); content: ''; }
.header-actions { display: flex; align-items: center; justify-content: flex-end; gap: 11px; }
.env { display: inline-flex; align-items: center; gap: 8px; width: max-content; padding: 7px 11px; border: 1px solid var(--line); border-radius: 99px; color: #dbbc80; font-family: 'DM Mono', monospace; font-size: 12px; letter-spacing: .07em; white-space: nowrap; }
.header-cta { display: inline-flex; align-items: center; justify-content: center; gap: 11px; min-height: 40px; padding: 0 15px; border: 1px solid rgba(228, 173, 79, .5); border-radius: 3px; background: rgba(11, 11, 9, .24); color: #e4c484; font-size: 13px; font-weight: 500; transition: color .2s ease, border-color .2s ease, background .2s ease; }
.header-cta:hover { border-color: var(--amber); background: rgba(228, 173, 79, .08); color: var(--ivory); }
.button-primary, .primary { display: inline-flex; align-items: center; justify-content: center; gap: 11px; min-height: 42px; padding: 0 17px; border: 1px solid rgba(245, 196, 107, .65); border-radius: 3px; background: linear-gradient(135deg, #e2aa47, #c6872e); color: #17110a; font-size: 14px; font-weight: 600; transition: filter .2s ease, transform .2s ease; }
.button-primary:hover, .primary:hover { filter: brightness(1.1); transform: translateY(-1px); }
.menu-toggle { display: none; place-content: center; gap: 6px; width: 42px; height: 42px; padding: 9px; border: 1px solid var(--line); background: rgba(8, 8, 7, .65); }
.menu-toggle span { display: block; width: 21px; height: 1px; background: var(--amber); transition: transform .2s ease, opacity .2s ease; }
.menu-toggle[aria-expanded="true"] span:first-child { transform: translateY(3.5px) rotate(45deg); }
.menu-toggle[aria-expanded="true"] span:last-child { transform: translateY(-3.5px) rotate(-45deg); }
.site-menu { position: absolute; top: calc(100% + 9px); right: var(--page-gutter); display: grid; gap: 0; width: min(360px, calc(100vw - 32px)); padding: 19px 22px 17px; border: 1px solid var(--line); background: rgba(12, 12, 10, .97); box-shadow: 0 28px 70px #000b; backdrop-filter: blur(20px); }
.site-menu[hidden] { display: none; }
.site-menu .menu-kicker { margin: 0 0 12px; color: var(--gold); font-family: 'DM Mono', monospace; font-size: 12px; letter-spacing: .14em; text-transform: uppercase; }
.site-menu a { display: flex; align-items: center; justify-content: space-between; padding: 13px 0; border-top: 1px solid var(--line-soft); font-size: 15px; }
.site-menu a span { margin-right: 13px; color: #8a7352; font-family: 'DM Mono', monospace; font-size: 12px; }
.site-menu .menu-app { margin-top: 9px; padding: 12px; border: 1px solid var(--line); color: var(--amber); }
.menu-note { margin: 13px 0 0; color: var(--subtle); font-size: 13px; line-height: 1.65; }

.page-frame { width: min(1380px, calc(100% - var(--page-gutter) - var(--page-gutter))); margin: 0 auto; }
.page-main { position: relative; z-index: 1; min-height: calc(100vh - 76px); padding: clamp(48px, 7vw, 92px) 0 90px; }
.page-intro { display: grid; grid-template-columns: minmax(0, 1.25fr) minmax(230px, .6fr); align-items: end; gap: 34px; margin: 0 0 clamp(36px, 5vw, 65px); }
.page-intro-copy { max-width: 760px; }
.eyebrow, .kicker { margin: 0 0 17px; color: var(--gold); font-family: 'DM Mono', monospace; font-size: 12px; letter-spacing: .17em; text-transform: uppercase; }
h1, h2, h3, p { overflow-wrap: anywhere; }
.page-intro h1 { max-width: 900px; margin: 0; font-size: clamp(44px, 6vw, 78px); font-weight: 500; letter-spacing: -.065em; line-height: .98; }
.page-intro h1 em, .home-title em { color: #d7bd92; font-family: 'Playfair Display', Georgia, serif; font-weight: 500; }
.page-intro p, .lead { max-width: 650px; margin: 20px 0 0; color: var(--muted); font-size: 16px; line-height: 1.8; }
.intro-aside { padding: 20px; border-left: 1px solid var(--gold); background: linear-gradient(90deg, rgba(203, 143, 57, .08), transparent); color: #c5b99f; font-size: 14px; line-height: 1.7; }
.intro-aside b { display: block; margin-bottom: 5px; color: var(--amber); font-family: 'DM Mono', monospace; font-size: 12px; letter-spacing: .12em; }
.section-heading { display: flex; align-items: end; justify-content: space-between; gap: 20px; margin: 52px 0 21px; padding-bottom: 13px; border-bottom: 1px solid var(--line); }
.section-heading h2 { margin: 0; font-size: clamp(23px, 3vw, 36px); font-weight: 500; letter-spacing: -.04em; }
.section-heading p { max-width: 500px; margin: 0; color: var(--muted); font-size: 14px; line-height: 1.7; }
.surface, .card, .tile, .stat, .instrument, .panel, .doc-block, .note, .notice { position: relative; border: 1px solid var(--line-soft); background: linear-gradient(145deg, rgba(25, 26, 23, .9), rgba(14, 15, 13, .92)); box-shadow: inset 0 1px rgba(255,255,255,.018), 0 20px 70px rgba(0,0,0,.11); }
.surface::before, .card::before, .instrument::before { position: absolute; top: -1px; left: 20px; width: 45px; height: 1px; background: linear-gradient(90deg, var(--gold), transparent); content: ''; }
.status-strip, .notice { padding: 14px 17px; border-color: var(--line); background: rgba(82, 54, 18, .16); color: #d6c9b0; font-size: 14px; line-height: 1.7; }
.status-strip strong, .notice b { color: var(--amber); font-family: 'DM Mono', monospace; font-size: 12px; letter-spacing: .08em; }
.status-dot { display: inline-block; width: 7px; height: 7px; margin-right: 8px; border-radius: 50%; background: var(--gold); box-shadow: 0 0 9px rgba(228,173,79,.45); vertical-align: 1px; }
.status-dot--off { background: #88857b; box-shadow: none; }
.status-dot--ok { background: var(--green); box-shadow: 0 0 9px rgba(131,196,160,.35); }
.metrics-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 11px; }
.metric { min-height: 106px; padding: 20px; border: 1px solid var(--line-soft); background: linear-gradient(140deg, rgba(24,25,22,.86), rgba(12,13,12,.92)); }
.metric small, .metric-label { display: block; margin-bottom: 13px; color: var(--subtle); font-family: 'DM Mono', monospace; font-size: 12px; letter-spacing: .1em; text-transform: uppercase; }
.metric strong { display: block; color: var(--ivory); font-size: 17px; font-weight: 500; letter-spacing: -.02em; }
.metric strong.is-unavailable { color: #bbb2a3; font-size: 16px; }
.buyback-summary { margin: 0; }
.buyback-summary-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 13px; }
.buyback-stat { display: flex; min-width: 0; min-height: 142px; flex-direction: column; padding: 23px 24px; border: 1px solid var(--line-soft); border-top-color: rgba(228,173,79,.34); background: linear-gradient(145deg, rgba(23,24,21,.88), rgba(11,12,10,.94)); }
.buyback-stat small { display: block; color: #a88b5c; font-family: 'DM Mono', monospace; font-size: 12px; letter-spacing: .13em; line-height: 1.5; text-transform: uppercase; }
.buyback-stat strong { display: block; margin-top: auto; padding-top: 19px; color: var(--ivory); font-size: clamp(16px, 1.45vw, 20px); font-weight: 500; letter-spacing: -.025em; line-height: 1.45; }
.buyback-stat--detail strong { font-size: clamp(14px, 1.2vw, 16px); letter-spacing: -.01em; }
.buyback-summary > .button-secondary { margin-top: 18px; }
.split-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; }
.split-panel { padding: clamp(20px, 3vw, 31px); border-top: 1px solid rgba(238, 190, 109, .55); }
.split-panel h3 { margin: 3px 0 7px; font-size: 21px; font-weight: 500; letter-spacing: -.04em; }
.split-panel > p { margin: 0 0 22px; color: var(--muted); font-size: 14px; line-height: 1.7; }
.flow-list { display: grid; gap: 8px; }
.flow-row { display: grid; grid-template-columns: minmax(0, 1fr) auto; align-items: center; gap: 15px; padding: 14px 15px; border: 1px solid var(--line-soft); background: rgba(4, 5, 4, .32); }
.flow-row span { color: #ccc6ba; font-size: 15px; }
.flow-row strong { color: var(--amber); font-family: 'DM Mono', monospace; font-size: 15px; font-weight: 500; white-space: nowrap; }
.flow-rule { display: flex; align-items: center; gap: 12px; color: #6c6252; font-family: 'DM Mono', monospace; font-size: 11px; letter-spacing: .1em; text-transform: uppercase; }
.flow-rule::before, .flow-rule::after { height: 1px; flex: 1; background: linear-gradient(90deg, transparent, var(--line)); content: ''; }
.flow-rule::after { transform: scaleX(-1); }
.protocol-note { margin-top: 14px; padding: 15px 17px; border-left: 1px solid var(--gold); background: rgba(63, 45, 20, .17); color: #bdb5a7; font-size: 13px; line-height: 1.7; }
.architecture { display: grid; max-width: 880px; gap: 12px; margin: 20px 0 26px; }
.arch-node { display: grid; grid-template-columns: 150px minmax(0, 1fr); align-items: baseline; gap: 6px 17px; padding: 17px 20px; border: 1px solid var(--line-soft); background: linear-gradient(100deg, rgba(29, 25, 18, .8), rgba(13,14,13,.85)); }
.arch-index { color: #967343; font-family: 'DM Mono', monospace; font-size: 12px; letter-spacing: .1em; }
.arch-node strong { font-size: 15px; font-weight: 500; }
.arch-node small { grid-column: 2; color: var(--muted); font-size: 14px; line-height: 1.6; }
.arch-branches { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 11px; margin-left: 40px; }
.arch-branch { min-height: 105px; padding: 17px; border: 1px solid var(--line); background: rgba(25,20,13,.5); }
.arch-branch b { display: block; margin-bottom: 7px; color: var(--amber); font-size: 15px; font-weight: 500; }
.arch-branch span { color: var(--muted); font-size: 13px; line-height: 1.6; }
.arch-connector { height: 18px; margin-left: 43px; border-left: 1px solid var(--gold); opacity: .6; }
.policy-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 11px; }
.policy { padding: 18px; border: 1px solid var(--line-soft); background: rgba(18,19,17,.76); }
.policy small { display: block; margin-bottom: 9px; color: var(--subtle); font-family: 'DM Mono', monospace; font-size: 11px; letter-spacing: .1em; text-transform: uppercase; }
.policy strong { display: block; margin-bottom: 7px; color: #e8d8b9; font-size: 16px; font-weight: 500; }
.policy p { margin: 0; color: var(--muted); font-size: 13px; line-height: 1.65; }
.two-column { display: grid; grid-template-columns: minmax(0, 1fr) minmax(280px, .62fr); align-items: start; gap: 17px; }
.tag { display: inline-flex; align-items: center; min-height: 22px; padding: 3px 8px; border: 1px solid var(--line); color: #d5b879; font-family: 'DM Mono', monospace; font-size: 11px; letter-spacing: .08em; text-transform: uppercase; }
.chip-row { display: flex; flex-wrap: wrap; gap: 7px; }
.muted { color: var(--muted); }
.mono { font-family: 'DM Mono', monospace; }
.cta-row { display: flex; flex-wrap: wrap; align-items: center; gap: 12px; margin-top: 24px; }
.button-secondary, .secondary { display: inline-flex; min-height: 40px; align-items: center; justify-content: center; padding: 0 15px; border: 1px solid var(--line); background: rgba(17,18,16,.68); color: #dfc596; font-size: 13px; }
.button-secondary:hover, .secondary:hover { border-color: var(--gold); }
.site-footer { display: grid; gap: 24px; padding: 44px var(--page-gutter) 28px; color: #a39d92; font-size: 14px; }
.footer-main { display: flex; justify-content: space-between; align-items: center; gap: 24px; padding-bottom: 24px; border-bottom: 1px solid var(--line-soft); }
.footer-identity p { margin: 6px 0 0 37px; color: #a39d92; font-size: 13px; letter-spacing: .04em; }
.site-footer .footer-brand { display: inline-flex; align-items: center; gap: 11px; color: #e3d3b5; font-size: 14px; letter-spacing: .12em; }
.site-footer .footer-brand img { width: 26px; height: 26px; object-fit: contain; }
.footer-links { display: flex; flex-wrap: wrap; gap: 26px; }
.footer-links a { color: #c9c1b4; }
.footer-links a:hover { color: var(--amber); }
.footer-bottom { display: flex; justify-content: space-between; gap: 16px; color: #8f897e; font-size: 12px; }

/* Home: centered editorial typography with restrained warm atmosphere. */
.public-home { overflow-x: clip; }
.home-hero { position: relative; display: grid; min-height: min(850px, calc(100svh - 76px)); grid-template-columns: minmax(0, 1fr); place-items: center; overflow: hidden; padding: 7vh var(--page-gutter); isolation: isolate; }
.home-hero::before { position: absolute; z-index: -1; inset: 0; background: radial-gradient(ellipse 64% 48% at 50% 18%, rgba(183, 100, 35, .16), transparent 74%), radial-gradient(ellipse 45% 25% at 50% 83%, rgba(197, 121, 39, .055), transparent 76%), linear-gradient(180deg, #0e0b08 0%, #090908 56%, #080807 100%); content: ''; }
.home-copy { position: relative; z-index: 1; display: flex; width: min(100%, 1000px); flex-direction: column; align-items: center; padding: 30px 0; text-align: center; }
.home-title { width: 100%; max-width: none; margin: 0; font-size: clamp(46px, 8.3vw, 112px); font-weight: 500; letter-spacing: -.078em; line-height: .91; }
.home-title em { display: block; margin-top: .08em; }
.home-lead { max-width: 690px; margin: 24px 0 0; color: #b6aea2; font-size: 16px; line-height: 1.8; }
.home-label { display: flex; align-items: center; justify-content: center; gap: 10px; margin: 0 0 31px; color: #d3ae70; font-family: 'DM Mono', monospace; font-size: 12px; letter-spacing: .18em; text-transform: uppercase; }
.home-label::before { width: 27px; height: 1px; background: var(--gold); content: ''; }
.home-hero .cta-row { justify-content: center; gap: 11px; margin-top: 29px; }
.home-hero .button-primary { border-color: rgba(228, 173, 79, .42); background: rgba(50, 37, 20, .52); color: #e5c98e; font-weight: 500; }
.home-hero .button-primary:hover { border-color: rgba(245, 196, 107, .72); background: rgba(74, 52, 24, .58); filter: none; }
.home-hero .button-secondary { border-color: rgba(224, 174, 92, .23); background: rgba(10, 10, 9, .2); color: #c8b58e; }
.home-story { position: relative; padding: 68px var(--page-gutter) 86px; border-top: 1px solid rgba(214,157,83,.14); background: radial-gradient(ellipse 57% 50% at 85% 0%, rgba(116,69,30,.11), transparent 75%), linear-gradient(#11110f, #090908 62%); }
.home-story .page-frame { width: 100%; max-width: 1380px; }
.story-heading { display: grid; grid-template-columns: minmax(0, 1.1fr) minmax(250px, .7fr); align-items: end; gap: 44px; margin: 0 0 44px; }
.story-heading h2 { max-width: 730px; margin: 0; font-size: clamp(40px, 6.5vw, 76px); font-weight: 500; letter-spacing: -.07em; line-height: .97; }
.story-heading p { max-width: 420px; margin: 0; color: var(--muted); font-size: 15px; line-height: 1.8; }
.home-principles { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.home-principle { padding: 24px 24px 28px 0; }
.home-principle + .home-principle { padding-left: 24px; border-left: 1px solid var(--line-soft); }
.home-principle small { color: #a7834b; font-family: 'DM Mono', monospace; font-size: 11px; letter-spacing: .15em; }
.home-principle h3 { margin: 19px 0 9px; font-size: 17px; font-weight: 500; }
.home-principle p { max-width: 320px; margin: 0; color: var(--muted); font-size: 13px; line-height: 1.7; }
.home-closing { display: grid; grid-template-columns: minmax(0, 1fr) auto; align-items: center; gap: 20px; margin-top: 40px; }
.home-closing p { max-width: 500px; margin: 0; color: var(--muted); font-size: 14px; line-height: 1.8; }
.home-closing strong { display: block; margin-bottom: 9px; color: var(--amber); font-family: 'DM Mono', monospace; font-size: 12px; letter-spacing: .14em; }

/* Agent public page */
.agent-hero-aside { position: relative; min-height: 235px; padding: 25px; border: 1px solid var(--line); background: radial-gradient(ellipse 80% 90% at 100% 0%, rgba(180,116,39,.17), transparent 72%), rgba(16,17,15,.75); }
.agent-hero-aside::before { position: absolute; right: 20px; bottom: 13px; width: 120px; height: 120px; border: 1px solid rgba(227,173,83,.3); border-radius: 50%; content: ''; box-shadow: 0 0 40px rgba(205,139,52,.1), inset 0 0 25px rgba(205,139,52,.06); }
.agent-hero-aside img { position: absolute; right: 39px; bottom: 31px; width: 83px; height: 83px; object-fit: contain; }
.agent-aside-label { color: #b9aa8f; font-family: 'DM Mono', monospace; font-size: 11px; letter-spacing: .14em; }
.agent-aside-state { margin-top: 24px; color: #ded5c3; font-size: 16px; }
.agent-aside-state strong { display: block; margin-top: 7px; color: var(--amber); font-size: 21px; font-weight: 500; }
.agent-intelligence { display: grid; grid-template-columns: minmax(0, .8fr) minmax(0, 1.2fr); gap: 15px; }
.intel-list { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 1px; padding: 1px; background: var(--line-soft); }
.intel-item { min-height: 92px; padding: 17px; background: #11120f; }
.intel-item small { display: block; margin-bottom: 10px; color: var(--subtle); font-family: 'DM Mono', monospace; font-size: 11px; letter-spacing: .13em; }
.intel-item b { color: #cec4b2; font-size: 15px; font-weight: 500; }
.agent-boundary { padding: 21px; border-left: 1px solid var(--gold); background: rgba(64,47,22,.16); }
.agent-boundary h3 { margin: 0 0 10px; font-size: 18px; font-weight: 500; }
.agent-boundary p { margin: 0; color: var(--muted); font-size: 14px; line-height: 1.8; }
.agent-boundary .arch-flow { margin-top: 20px; color: #d7bd8e; font-family: 'DM Mono', monospace; font-size: 12px; line-height: 2.3; }

/* Application: dense financial instrument that preserves the working paper controls. */
.wrap { width: min(1440px, calc(100% - var(--page-gutter) - var(--page-gutter))) !important; margin: 0 auto !important; }
.wrap > .topbar { display: grid !important; grid-template-columns: auto minmax(0, 1fr) auto !important; align-items: center !important; gap: 25px !important; min-height: 76px !important; margin: 0 calc(0px - var(--page-gutter)) 30px !important; padding: 10px var(--page-gutter) !important; border-bottom: 1px solid var(--line-soft) !important; background: rgba(9,9,8,.8) !important; }
.wrap > .topbar .brand { display: inline-flex !important; align-items: center !important; gap: 10px !important; color: var(--ivory) !important; font-size: 15px !important; letter-spacing: .12em !important; }
.wrap > .topbar .brand img { width: 36px !important; height: 36px !important; object-fit: contain !important; }
.wrap > .topbar .nav { display: flex !important; justify-content: center !important; gap: clamp(13px, 2vw, 30px) !important; }
.wrap > .topbar .nav a { color: #aaa69d !important; font-size: 14px !important; }
.wrap > .topbar .nav a.current { color: var(--ivory) !important; }
.wrap > .topbar .env { max-width: 230px; padding: 7px 10px !important; border: 1px solid var(--line) !important; border-radius: 50px !important; color: #e1bd7d !important; font-family: 'DM Mono', monospace !important; font-size: 11px !important; letter-spacing: .06em !important; }
.wrap .intro { margin: 0 0 22px !important; }
.wrap .intro .eyebrow { margin-bottom: 13px !important; }
.wrap .intro h1 { max-width: 950px; margin: 0 0 10px !important; color: var(--ivory) !important; font-size: clamp(37px, 5.2vw, 65px) !important; font-weight: 500 !important; letter-spacing: -.06em !important; line-height: 1.04 !important; }
.wrap .intro p:not(.eyebrow) { max-width: 740px; margin-top: 0 !important; color: var(--muted) !important; font-size: 15px !important; line-height: 1.75 !important; }
.wrap .notice { margin: 18px 0 !important; border: 1px solid var(--line) !important; background: rgba(78,55,20,.16) !important; color: #ccc1ac !important; font-size: 13px !important; line-height: 1.7 !important; }
.wrap .stats { gap: 10px !important; margin: 20px 0 !important; }
.wrap .stat { min-width: 0; padding: 16px !important; border: 1px solid var(--line-soft) !important; background: linear-gradient(140deg, rgba(24,25,22,.9), rgba(12,13,12,.95)) !important; }
.wrap .stat small, .wrap .label, .wrap .hint { color: #978d7d !important; font-family: 'DM Mono', monospace !important; font-size: 11px !important; letter-spacing: .09em !important; text-transform: uppercase; }
.wrap .stat strong { color: var(--ivory) !important; font-size: 15px !important; font-weight: 500 !important; }
.wrap .layout { grid-template-columns: minmax(0, 1.04fr) minmax(360px, .96fr) !important; align-items: start !important; gap: 14px !important; }
.wrap .card { min-width: 0; padding: clamp(16px, 2.2vw, 24px) !important; border: 1px solid var(--line-soft) !important; background: linear-gradient(145deg, rgba(23,24,21,.92), rgba(13,14,12,.94)) !important; }
.wrap .card h2 { color: var(--ivory) !important; font-size: 19px !important; font-weight: 500 !important; letter-spacing: -.035em !important; }
.wrap .sub, .wrap .small, .wrap .risk-note { color: var(--muted) !important; font-size: 13px !important; line-height: 1.7 !important; }
.wrap .assets { grid-template-columns: repeat(2, minmax(0, 1fr)) !important; gap: 7px !important; }
.wrap .asset { min-width: 0; padding: 12px !important; border: 1px solid var(--line-soft) !important; background: rgba(7,8,7,.45) !important; }
.wrap .asset:has(input:checked) { border-color: rgba(228,173,79,.57) !important; background: rgba(89,63,23,.14) !important; }
.wrap .asset b { color: #e7ddc9 !important; font-size: 14px !important; }
.wrap .asset small, .wrap .quote { color: #9b9487 !important; font-size: 12px !important; }
.wrap input, .wrap textarea, .wrap select { min-height: 40px; border: 1px solid rgba(231,226,212,.16) !important; border-radius: 2px !important; background: #0c0d0b !important; color: var(--ivory) !important; }
.wrap input[type=checkbox] { min-height: 0; accent-color: var(--gold); }
.wrap .duration { min-height: 73px; border: 1px solid var(--line-soft) !important; background: rgba(7,8,7,.42) !important; color: #cfc5b2 !important; }
.wrap .duration.selected { border-color: rgba(236,184,88,.7) !important; background: rgba(109,77,27,.2) !important; }
.wrap .summary-box { padding: 17px !important; border: 1px solid var(--line) !important; background: rgba(15,15,13,.75) !important; }
.wrap .summary-grid, .wrap .riskgrid { gap: 12px !important; }
.wrap .summary-grid span, .wrap .riskcell span { color: #91897b !important; font-family: 'DM Mono', monospace !important; font-size: 11px !important; }
.wrap .summary-grid b, .wrap .riskcell b { color: #ece4d5 !important; font-size: 13px !important; font-weight: 500 !important; }
.wrap .primary, .wrap .secondary { min-height: 40px !important; border-radius: 2px !important; font-size: 13px !important; }
.wrap .primary { border-color: #e4ad4f !important; background: linear-gradient(135deg,#e7b34f,#bf822d) !important; color: #151009 !important; }
.wrap .secondary { border-color: var(--line) !important; background: rgba(11,12,10,.72) !important; color: #d7c498 !important; }
.wrap button:disabled { cursor: not-allowed !important; opacity: .47 !important; }
.wrap .monitor { min-width: 0; }
.wrap .agentbox, .wrap .chartbox { border: 1px solid var(--line) !important; background: radial-gradient(ellipse 80% 60% at 95% 0%, rgba(161,104,38,.1), transparent 70%), rgba(10,11,9,.77) !important; }
.wrap .agentbox { padding: 17px !important; }
.wrap .agenttop { gap: 8px !important; }
.wrap .badge { border: 1px solid var(--line) !important; color: #dec182 !important; font-family: 'DM Mono', monospace !important; font-size: 11px !important; }
.wrap .life { border-color: var(--line-soft) !important; background: rgba(10,10,9,.5) !important; color: #918a7d !important; font-family: 'DM Mono', monospace !important; font-size: 11px !important; }
.wrap .life.current, .wrap .life.done { border-color: rgba(229,177,88,.5) !important; color: #e0c180 !important; }
.wrap .chartbox { min-height: 230px; }
.wrap .chart-empty { color: #b49c70 !important; font-family: 'DM Mono', monospace !important; font-size: 12px !important; }
.wrap .chart-empty small { color: var(--subtle) !important; }
.wrap .chart text { fill: #b9a67f !important; font-family: 'DM Mono', monospace !important; font-size: 13px !important; }
.wrap .gridline { stroke: rgba(235,214,175,.09) !important; }
.wrap .line { stroke: var(--amber) !important; }
.wrap .area { fill: url(#shade) !important; }
.wrap .progress { background: rgba(236,225,201,.09) !important; }
.wrap .progress span, .wrap #bar { background: linear-gradient(90deg, #99642b, #f2c76d) !important; }
.wrap .risk { margin-top: 14px !important; padding: 16px !important; border: 1px solid var(--line-soft) !important; background: rgba(13,14,12,.64) !important; }
.wrap .activity { display: grid; gap: 8px; }
.wrap .event { padding: 11px 12px !important; border: 1px solid var(--line-soft) !important; background: rgba(7,8,7,.44) !important; color: #c4bfb4 !important; font-size: 12px !important; line-height: 1.55 !important; }
.wrap .event time { color: #a48857 !important; font-family: 'DM Mono', monospace !important; }
.wrap .empty, .wrap .foot { color: #8e887c !important; font-size: 12px !important; line-height: 1.7 !important; }
.wrap .toast { border: 1px solid var(--line) !important; background: #12130f !important; color: var(--ivory) !important; }
.wrap > .foot { display: flex; justify-content: space-between; gap: 15px; margin: 25px 0 0 !important; padding: 17px 0; border-top: 1px solid var(--line-soft); }

/* Documentation */
.docs-layout { display: grid; grid-template-columns: 210px minmax(0, 1fr); align-items: start; gap: clamp(25px, 5vw, 70px); }
.docs-toc { position: sticky; top: 22px; display: grid; gap: 4px; padding: 15px 0; border-top: 1px solid var(--line); }
.docs-toc small { margin: 0 0 9px; color: var(--gold); font-family: 'DM Mono', monospace; font-size: 11px; letter-spacing: .14em; text-transform: uppercase; }
.docs-toc a { padding: 8px 10px; border-left: 1px solid transparent; color: #9d988e; font-size: 13px; }
.docs-toc a:hover, .docs-toc a.active { border-left-color: var(--gold); color: var(--ivory); background: rgba(197,139,55,.07); }
.docs-content { min-width: 0; }
.docs-content > .status-strip { margin-bottom: 30px; }
.doc-block { margin-bottom: 14px; padding: clamp(22px, 3.3vw, 38px); scroll-margin-top: 24px; }
.doc-block .doc-kicker { margin: 0 0 11px; color: #c3984f; font-family: 'DM Mono', monospace; font-size: 11px; letter-spacing: .14em; text-transform: uppercase; }
.doc-block h2 { margin: 0 0 17px; font-size: clamp(22px, 3vw, 33px); font-weight: 500; letter-spacing: -.045em; }
.doc-block h3 { margin: 25px 0 8px; color: #e3d6be; font-size: 15px; font-weight: 500; }
.doc-block p, .doc-block li { color: #b2ada3; font-size: 15px; line-height: 1.85; }
.doc-block p:last-child { margin-bottom: 0; }
.doc-block ul { display: grid; gap: 7px; padding-left: 19px; }
.doc-block li::marker { color: var(--gold); }
.docs-table-wrap { overflow-x: auto; margin: 20px 0; border: 1px solid var(--line-soft); }
.docs-table { width: 100%; border-collapse: collapse; text-align: left; }
.docs-table th, .docs-table td { padding: 12px 14px; border-bottom: 1px solid var(--line-soft); color: #bab4a8; font-size: 13px; line-height: 1.6; vertical-align: top; }
.docs-table th { color: #d6b873; background: rgba(93,67,27,.16); font-family: 'DM Mono', monospace; font-size: 11px; font-weight: 400; letter-spacing: .09em; text-transform: uppercase; }
.docs-table tr:last-child td { border-bottom: 0; }
.code-block { overflow-x: auto; padding: 17px; border: 1px solid var(--line-soft); background: #090a08; color: #d0b77f; font-family: 'DM Mono', monospace; font-size: 13px; line-height: 1.8; white-space: pre; }
.doc-callout { margin: 19px 0; padding: 15px 17px; border-left: 1px solid var(--gold); background: rgba(80,57,21,.16); color: #c8bdab; font-size: 14px; line-height: 1.75; }
.docs-faq details { padding: 14px 0; border-top: 1px solid var(--line-soft); }
.docs-faq summary { color: #e0d5c1; font-size: 15px; cursor: pointer; }
.docs-faq p { margin-bottom: 0; }

/* Legacy/test utility screen remains isolated and carries an explicit internal label. */
.internal-wrap { width: min(1120px, calc(100% - var(--page-gutter) - var(--page-gutter))); margin: 0 auto; }
.internal-wrap .internal-card { margin: 14px 0; padding: clamp(19px, 3vw, 29px); border: 1px solid var(--line-soft); background: linear-gradient(145deg, rgba(25,26,23,.94), rgba(12,13,11,.95)); }
.internal-wrap .internal-card h1, .internal-wrap .internal-card h2 { margin: 0 0 12px; font-weight: 500; letter-spacing: -.04em; }
.internal-wrap .internal-card h1 { font-size: clamp(35px, 5vw, 58px); }
.internal-wrap .muted { color: var(--muted); font-size: 14px; line-height: 1.8; }
.internal-wrap textarea, .internal-wrap input { width: 100%; padding: 12px; border: 1px solid var(--line-soft); background: #090a08; }
.internal-wrap .out { overflow: auto; margin-top: 12px; padding: 13px; border: 1px solid var(--line-soft); background: #090a08; color: #c8bdab; font-family: 'DM Mono', monospace; font-size: 12px; line-height: 1.7; white-space: pre-wrap; }
.internal-wrap .internal-actions { display: flex; flex-wrap: wrap; gap: 9px; margin-top: 13px; }
.internal-wrap .internal-actions button { min-height: 38px; padding: 0 13px; border: 1px solid var(--line); background: rgba(100,70,26,.22); color: #e1c78e; font-size: 13px; }

@media (max-width: 980px) {
  .site-header { grid-template-columns: auto 1fr auto; }
  .site-nav { gap: 14px; }
  .site-nav a { font-size: 13px; }
  .header-cta { padding: 0 12px; font-size: 12px; }
  .wrap .layout { grid-template-columns: minmax(0, 1fr) minmax(300px, .9fr) !important; }
  .buyback-summary-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 11px; }
}
@media (max-width: 760px) {
  :root { --page-gutter: 22px; }
  .site-header { grid-template-columns: 1fr auto; min-height: 66px; gap: 12px; }
  .site-brand img { width: 34px; height: 34px; }
  .site-nav { display: none; }
  .header-actions { grid-column: 2; grid-row: 1; display: flex !important; width: 42px; min-width: 42px; justify-content: flex-end; overflow: visible; }
  .menu-toggle { display: grid !important; visibility: visible !important; opacity: 1 !important; }
  .header-cta { display: none !important; min-height: 36px; }
  .page-main { min-height: calc(100vh - 66px); padding-top: 46px; }
  .page-intro { grid-template-columns: 1fr; gap: 20px; margin-bottom: 34px; }
  .intro-aside { max-width: 520px; }
  .metrics-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .split-grid, .two-column, .agent-intelligence { grid-template-columns: 1fr; }
  .policy-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .arch-node { grid-template-columns: 48px minmax(0, 1fr); gap: 10px; }
  .arch-node small { grid-column: 2; }
  .arch-branches { grid-template-columns: 1fr; margin-left: 35px; }
  .arch-branch { min-height: 0; }
  .home-hero { min-height: min(650px, calc(100svh - 66px)); padding: 58px var(--page-gutter) 64px; }
  .home-copy { width: min(100%, 620px); padding: 24px 0; }
  .home-title { font-size: clamp(44px, 8.7vw, 72px); }
  .home-lead { max-width: 540px; font-size: 15px; }
  .home-label { margin-bottom: 25px; }
  .home-hero .cta-row { margin-top: 25px; }
  .home-story { padding: 48px var(--page-gutter) 58px; }
  .story-heading { grid-template-columns: 1fr; gap: 17px; margin-bottom: 29px; }
  .home-principles { grid-template-columns: 1fr; }
  .home-principle, .home-principle + .home-principle { padding: 18px 0; border-left: 0; border-bottom: 1px solid var(--line-soft); }
  .home-principle:last-child { border-bottom: 0; }
  .home-principle h3 { margin: 10px 0 6px; }
  .home-closing { grid-template-columns: 1fr; }
  .docs-layout { grid-template-columns: 1fr; gap: 21px; }
  .docs-toc { position: relative; top: auto; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 2px; padding: 11px 0; }
  .docs-toc small { grid-column: 1 / -1; }
  .docs-toc a { font-size: 12px; }
  .wrap { width: calc(100% - var(--page-gutter) - var(--page-gutter)) !important; min-width: 0; padding: 0 !important; }
  .wrap > .topbar { grid-template-columns: auto minmax(0,1fr) !important; gap: 10px !important; margin-bottom: 23px !important; }
  .wrap > .topbar .nav { display: none !important; }
  .wrap > .topbar.site-header { display: flex !important; flex-wrap: nowrap !important; justify-content: space-between; gap: 8px !important; }
  .wrap > .topbar .brand { flex: 0 0 auto; }
  .wrap > .topbar .env { flex: 0 1 auto; width: fit-content; max-width: 120px !important; min-width: 0; margin-left: auto; overflow: hidden; text-overflow: ellipsis; white-space: nowrap !important; text-align: center; }
  .wrap > .topbar .menu-toggle { display: grid !important; visibility: visible !important; opacity: 1 !important; flex: 0 0 42px; }
  .wrap .intro { display: block !important; }
  .wrap .intro > div { width: 100%; min-width: 0; }
  .wrap .layout { width: 100%; min-width: 0; grid-template-columns: minmax(0, 1fr) !important; }
  .wrap .layout > *, .wrap .stats > * { min-width: 0; }
  .wrap .notice { overflow-wrap: anywhere; }
  .wrap .stats { grid-template-columns: repeat(2,minmax(0,1fr)) !important; }
  .wrap .assets { grid-template-columns: repeat(2,minmax(0,1fr)) !important; }
  .site-footer { grid-template-columns: 1fr; }
  .footer-main { align-items: flex-start; flex-direction: column; gap: 18px; }
  .footer-links { gap: 12px 20px; }
  .footer-bottom { flex-direction: column; gap: 6px; }
}
@media (max-width: 480px) {
  :root { --page-gutter: 17px; }
  .site-brand { gap: 8px; font-size: 14px; }
  .site-brand img { width: 31px; height: 31px; }
  .header-cta { display: none; }
  .site-menu { right: var(--page-gutter); }
  .page-intro h1 { font-size: clamp(39px, 13vw, 57px); }
  .section-heading { align-items: start; flex-direction: column; }
  .metrics-grid, .policy-grid { grid-template-columns: 1fr 1fr; gap: 7px; }
  .metric { min-height: 88px; padding: 13px; }
  .buyback-summary-grid { grid-template-columns: 1fr; gap: 10px; }
  .buyback-stat { min-height: 120px; padding: 19px 20px; }
  .buyback-stat strong { padding-top: 14px; font-size: 17px; }
  .buyback-stat--detail strong { font-size: 15px; }
  .metric small { font-size: 11px; }
  .metric strong { font-size: 16px; }
  .home-hero { min-height: min(620px, calc(100svh - 66px)); padding: 48px var(--page-gutter) 54px; }
  .home-copy { width: 100%; padding: 20px 0; }
  .home-title { font-size: clamp(42px, 11.5vw, 54px); line-height: .96; letter-spacing: -.075em; }
  .home-lead { max-width: 350px; margin-top: 20px; font-size: 15px; line-height: 1.75; }
  .home-label { margin-bottom: 21px; font-size: 11px; letter-spacing: .15em; }
  .home-label::before { width: 18px; }
  .home-hero .cta-row { max-width: 100%; margin-top: 22px; gap: 9px; }
  .home-hero .button-primary, .home-hero .button-secondary { min-height: 38px; padding: 0 12px; font-size: 12px; }
  .flow-row { padding: 12px; }
  .flow-row span { font-size: 13px; }
  .flow-row strong { font-size: 15px; }
  .arch-node { padding: 14px; }
  .arch-branches { margin-left: 18px; }
  .docs-toc { grid-template-columns: 1fr 1fr; }
  .doc-block { padding: 20px 16px; }
  .doc-block p, .doc-block li { font-size: 14px; }
  .wrap .stats { grid-template-columns: 1fr 1fr !important; }
  .wrap .assets { grid-template-columns: 1fr !important; }
  .wrap .duration-grid { grid-template-columns: 1fr !important; }
  .wrap .duration { min-height: 58px; }
  .wrap .summary-grid, .wrap .riskgrid { grid-template-columns: 1fr 1fr !important; }
  .wrap .monitor-stats { grid-template-columns: 1fr 1fr !important; }
  .wrap .progress-label { font-size: 11px !important; }
  .wrap .card { padding: 16px !important; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { scroll-behavior: auto !important; animation-duration: .01ms !important; animation-iteration-count: 1 !important; transition-duration: .01ms !important; }
}
