:root {
  --ink: #071a2a;
  --ink-2: #0d273a;
  --ink-3: #17384d;
  --paper: #f5f4ef;
  --surface: #ffffff;
  --surface-2: #f7f9fa;
  --line: #dbe2e6;
  --line-dark: #b9c6cc;
  --muted: #60727d;
  --muted-2: #87959d;
  --accent: #27c995;
  --accent-dark: #087b61;
  --blue: #1768e5;
  --blue-soft: #e9f1ff;
  --amber: #b66a08;
  --amber-soft: #fff2db;
  --red: #bd2d3d;
  --red-soft: #ffedf0;
  --green-soft: #e7f8f1;
  --shadow-sm: 0 1px 2px rgba(7, 26, 42, .05), 0 4px 14px rgba(7, 26, 42, .04);
  --shadow-lg: 0 26px 70px rgba(7, 26, 42, .16);
  --radius-sm: 8px;
  --radius: 14px;
  --radius-lg: 22px;
  --sans: Inter, ui-sans-serif, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  --serif: Iowan Old Style, Charter, "Palatino Linotype", Georgia, serif;
  --mono: "SFMono-Regular", Consolas, "Liberation Mono", monospace;
}

* { box-sizing: border-box; }
[hidden] { display: none !important; }
html { scroll-behavior: smooth; }
body { margin: 0; min-width: 320px; color: var(--ink); background: var(--paper); font-family: var(--sans); font-size: 16px; line-height: 1.5; -webkit-font-smoothing: antialiased; }
button, input, select, textarea { font: inherit; }
button, a { -webkit-tap-highlight-color: transparent; }
button { color: inherit; }
a { color: inherit; }
img, svg { display: block; max-width: 100%; }
p, h1, h2, h3, h4, dl, dd, ol, ul { margin: 0; }
ul, ol { padding: 0; }
button:focus-visible, a:focus-visible, input:focus-visible, select:focus-visible, textarea:focus-visible { outline: 3px solid rgba(23, 104, 229, .28); outline-offset: 2px; }

.sr-only { position: absolute !important; width: 1px !important; height: 1px !important; padding: 0 !important; margin: -1px !important; overflow: hidden !important; clip: rect(0, 0, 0, 0) !important; white-space: nowrap !important; border: 0 !important; }
.skip-link { position: fixed; top: 12px; left: 12px; z-index: 1000; transform: translateY(-150%); padding: 10px 14px; color: white; background: var(--blue); border-radius: 8px; text-decoration: none; font-weight: 700; }
.skip-link:focus { transform: translateY(0); }
.shell { width: min(1210px, calc(100% - 48px)); margin-inline: auto; }
.eyebrow, .overline { color: var(--accent-dark); font-size: 11px; font-weight: 800; letter-spacing: .14em; line-height: 1.2; text-transform: uppercase; }
.status-dot { display: inline-block; width: 8px; height: 8px; border-radius: 999px; background: var(--accent); box-shadow: 0 0 0 4px rgba(39, 201, 149, .13); }
.muted { color: var(--muted); }

.brand { display: inline-flex; align-items: center; gap: 11px; color: var(--ink); text-decoration: none; }
.brand img { border-radius: 10px; box-shadow: 0 7px 18px rgba(7, 26, 42, .13); }
.brand span { display: grid; line-height: 1.06; }
.brand strong { font-size: 15px; letter-spacing: -.01em; }
.brand small { margin-top: 4px; color: var(--muted); font-size: 9px; font-weight: 700; letter-spacing: .13em; text-transform: uppercase; }

.button { min-height: 46px; display: inline-flex; align-items: center; justify-content: center; gap: 9px; padding: 0 19px; border: 1px solid transparent; border-radius: 9px; cursor: pointer; text-decoration: none; font-size: 13px; font-weight: 750; letter-spacing: .005em; transition: transform .18s ease, background .18s ease, color .18s ease, border-color .18s ease, box-shadow .18s ease; }
.button:hover:not(:disabled) { transform: translateY(-1px); }
.button:disabled { cursor: not-allowed; opacity: .48; }
.button-primary { color: #03140e; background: var(--accent); box-shadow: 0 6px 18px rgba(39, 201, 149, .18); }
.button-primary:hover:not(:disabled) { background: #39dca9; box-shadow: 0 8px 24px rgba(39, 201, 149, .27); }
.button-secondary { color: var(--ink); background: var(--surface); border-color: var(--line-dark); box-shadow: 0 1px 2px rgba(7, 26, 42, .03); }
.button-secondary:hover:not(:disabled) { border-color: #8da0aa; background: #f9fbfb; }
.button-dark { color: white; background: var(--ink); }
.button-small { min-height: 36px; padding-inline: 14px; font-size: 12px; }
.button-full { width: 100%; }
.button-badge { min-width: 22px; height: 22px; display: inline-grid; place-items: center; padding-inline: 6px; border-radius: 999px; background: rgba(7, 26, 42, .14); font-size: 11px; }
.text-link, .text-button { padding: 0; border: 0; color: var(--ink); background: none; cursor: pointer; font-size: 13px; font-weight: 750; text-decoration: none; }
.text-link:hover, .text-button:hover { color: var(--accent-dark); }

/* Public landing */
.landing { background: var(--paper); }
.site-header { height: 84px; display: flex; align-items: center; justify-content: space-between; border-bottom: 1px solid rgba(7, 26, 42, .09); }
.header-nav { display: flex; align-items: center; gap: 30px; }
.header-nav > a:not(.button) { color: #40545f; font-size: 13px; font-weight: 650; text-decoration: none; }
.header-nav > a:not(.button):hover { color: var(--ink); }
.hero { min-height: 676px; display: grid; grid-template-columns: minmax(0, .88fr) minmax(560px, 1.12fr); align-items: center; gap: 60px; padding-block: 86px 90px; }
.hero-copy { max-width: 540px; }
.hero .eyebrow { display: flex; align-items: center; gap: 10px; margin-bottom: 25px; }
.hero h1 { max-width: 660px; font-size: clamp(44px, 5vw, 72px); font-weight: 680; letter-spacing: -.057em; line-height: .99; }
.hero h1 em { color: var(--accent-dark); font-family: var(--serif); font-weight: 500; }
.hero-lede { max-width: 570px; margin-top: 27px; color: #4e616c; font-size: 18px; line-height: 1.67; }
.hero-actions { display: flex; align-items: center; gap: 26px; margin-top: 34px; }
.hero-facts { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; margin-top: 51px; padding-top: 24px; border-top: 1px solid rgba(7, 26, 42, .11); }
.hero-facts div { min-width: 0; }
.hero-facts dt { color: var(--muted-2); font-size: 10px; font-weight: 800; letter-spacing: .12em; text-transform: uppercase; }
.hero-facts dd { margin-top: 7px; font-size: 12px; font-weight: 700; white-space: nowrap; }

.research-window { overflow: hidden; color: white; background: var(--ink); border: 1px solid #294253; border-radius: 18px; box-shadow: 0 34px 85px rgba(7, 26, 42, .25); transform: perspective(1200px) rotateY(-2deg) rotateX(1deg); }
.window-bar { height: 50px; display: flex; align-items: center; justify-content: space-between; padding: 0 18px; border-bottom: 1px solid #244052; background: #0b2233; }
.window-title { font-size: 11px; font-weight: 700; letter-spacing: .04em; }
.window-badge { padding: 5px 8px; color: #a8b9c2; background: #142e40; border: 1px solid #315064; border-radius: 5px; font-size: 8px; font-weight: 700; letter-spacing: .09em; text-transform: uppercase; }
.window-grid { min-height: 474px; display: grid; grid-template-columns: 64px 1fr; }
.mini-sidebar { display: flex; flex-direction: column; align-items: center; gap: 21px; padding-top: 24px; border-right: 1px solid #203b4c; background: #081e2d; }
.mini-logo { width: 27px; height: 27px; border: 1px solid #335265; border-radius: 8px; background: linear-gradient(135deg, var(--accent) 0 28%, transparent 29%); }
.mini-line { width: 25px; height: 5px; border-radius: 999px; background: #385365; opacity: .7; }
.mini-line.active { background: var(--accent); opacity: 1; }
.mini-line.short { width: 16px; }
.mini-content { padding: 27px 29px 25px; }
.mini-topline { display: flex; align-items: center; justify-content: space-between; color: #7e9aaa; font-size: 8px; font-weight: 800; letter-spacing: .13em; }
.mini-topline b { padding: 5px 8px; color: #74e4bf; background: rgba(39, 201, 149, .1); border: 1px solid rgba(39, 201, 149, .2); border-radius: 999px; font-size: 8px; }
.mini-content h2 { margin-top: 8px; font-size: 22px; font-weight: 650; letter-spacing: -.025em; }
.metric-row { display: grid; grid-template-columns: repeat(3, 1fr); gap: 9px; margin-top: 23px; }
.metric-row > div { min-height: 78px; padding: 13px 14px; background: #102b3d; border: 1px solid #274657; border-radius: 8px; }
.metric-row small { display: block; color: #819aa8; font-size: 8px; }
.metric-row strong { display: inline-block; margin-top: 7px; color: #f4f8f8; font-size: 17px; letter-spacing: -.02em; }
.metric-row i { margin-left: 5px; color: #6f8b9b; font-size: 8px; font-style: normal; }
.chart-card { margin-top: 12px; padding: 14px 15px 5px; border: 1px solid #274657; border-radius: 8px; background: #0d2738; }
.chart-labels { display: flex; justify-content: space-between; color: #8aa1ad; font-size: 8px; font-weight: 700; }
.chart-card svg { margin-top: 4px; }
.chart-grid { fill: none; stroke: #264456; stroke-width: 1; }
.chart-line { fill: none; stroke: var(--accent); stroke-width: 2.4; stroke-linecap: round; }
.mini-table { display: grid; grid-template-columns: 1.55fr .8fr 1fr; gap: 0; margin-top: 12px; overflow: hidden; border: 1px solid #274657; border-radius: 8px; }
.mini-table > * { min-height: 27px; display: flex; align-items: center; padding: 0 10px; border-bottom: 1px solid #213f51; color: #9ab0bc; font-size: 8px; }
.mini-table > :nth-last-child(-n+3) { border-bottom: 0; }
.mini-table > span { min-height: 24px; color: #6f8998; background: #102b3d; font-size: 7px; font-weight: 800; letter-spacing: .1em; }
.mini-table b { color: #e2e9ec; font-weight: 600; }
.mini-table code { color: #86a5b5; font-family: var(--mono); }
.mini-table i { color: #6cddb8; font-style: normal; }

.ticker { overflow: hidden; border-block: 1px solid rgba(7, 26, 42, .09); background: rgba(255, 255, 255, .32); }
.ticker-track { min-height: 54px; display: flex; align-items: center; justify-content: space-between; gap: 23px; color: #5b6c75; font-size: 10px; font-weight: 800; letter-spacing: .1em; text-transform: uppercase; white-space: nowrap; }
.ticker-track i { width: 4px; height: 4px; flex: 0 0 auto; border-radius: 50%; background: var(--accent); }
.section { padding-block: 112px; }
.section-heading { margin-bottom: 50px; }
.section-heading h2 { max-width: 700px; margin-top: 12px; font-size: clamp(35px, 4vw, 54px); font-weight: 650; letter-spacing: -.047em; line-height: 1.08; }
.split-heading { display: grid; grid-template-columns: 1.2fr .8fr; align-items: end; gap: 70px; }
.split-heading > p { max-width: 470px; padding-bottom: 6px; color: var(--muted); font-size: 16px; line-height: 1.7; }
.feature-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 18px; }
.feature-card { min-height: 360px; position: relative; overflow: hidden; padding: 34px; background: rgba(255, 255, 255, .72); border: 1px solid rgba(7, 26, 42, .11); border-radius: var(--radius); }
.feature-card-wide { grid-column: 1 / -1; min-height: 318px; display: grid; grid-template-columns: 58px 1fr 1fr; gap: 36px; align-items: start; }
.feature-index { color: var(--muted-2); font-family: var(--mono); font-size: 11px; }
.feature-card h3 { max-width: 470px; margin-top: 18px; font-size: 25px; font-weight: 650; letter-spacing: -.025em; }
.feature-card > p, .feature-card > div > p { max-width: 520px; margin-top: 15px; color: var(--muted); line-height: 1.7; }
.dictionary-sample { align-self: stretch; padding: 24px; background: var(--ink); border-radius: 10px; box-shadow: 0 18px 35px rgba(7, 26, 42, .15); }
.dictionary-sample div { display: flex; align-items: center; justify-content: space-between; gap: 15px; }
.dictionary-sample b { color: white; font-family: var(--mono); font-size: 12px; }
.dictionary-sample code { padding: 4px 7px; color: #91ead0; background: rgba(39, 201, 149, .1); border-radius: 4px; font-size: 10px; }
.dictionary-sample p { min-height: 70px; margin-block: 23px !important; padding-block: 18px; border-block: 1px solid #284353; color: #adc0c9 !important; font-size: 12px; }
.dictionary-sample span { display: inline-flex; margin: 0 8px 8px 0; padding: 5px 7px; color: #8ea6b2; background: #112c3d; border-radius: 4px; font-size: 9px; }
.format-list { display: flex; flex-wrap: wrap; gap: 9px; margin-top: 37px; list-style: none; }
.format-list li { min-width: 65px; padding: 9px 12px; color: var(--ink); background: white; border: 1px solid var(--line); border-radius: 6px; font-family: var(--mono); font-size: 11px; text-align: center; }
.checksum-sample { display: grid; grid-template-columns: auto 1fr auto; gap: 12px; align-items: center; margin-top: 45px; padding: 15px; color: white; background: var(--ink); border-radius: 8px; }
.checksum-sample span { color: #8199a7; font-size: 9px; font-weight: 800; }
.checksum-sample code { overflow: hidden; color: #d7e4e8; font-size: 11px; text-overflow: ellipsis; }
.checksum-sample b { color: #62dfb9; font-size: 10px; }

.section-ink { color: white; background: var(--ink); }
.section-heading.inverse .eyebrow { color: #5be0b8; }
.section-heading.inverse > p { color: #9eb2bc; }
.workflow-steps { display: grid; grid-template-columns: repeat(4, 1fr); border: 1px solid #2b4657; border-radius: var(--radius); list-style: none; }
.workflow-steps li { min-height: 220px; display: flex; gap: 18px; padding: 31px 26px; border-right: 1px solid #2b4657; }
.workflow-steps li:last-child { border: 0; }
.workflow-steps li > span { flex: 0 0 auto; color: var(--accent); font-family: var(--mono); font-size: 11px; }
.workflow-steps h3 { font-size: 20px; font-weight: 620; }
.workflow-steps p { margin-top: 13px; color: #92aab6; font-size: 13px; line-height: 1.65; }
.governance-grid { display: grid; grid-template-columns: .85fr 1.15fr; gap: 100px; }
.governance-grid h2 { max-width: 440px; margin-top: 15px; font-size: 45px; font-weight: 650; letter-spacing: -.045em; line-height: 1.08; }
.governance-list { border-top: 1px solid var(--line-dark); }
.governance-list article { display: grid; grid-template-columns: 36px 1fr; gap: 16px; padding-block: 28px; border-bottom: 1px solid var(--line-dark); }
.governance-list article > span { color: var(--accent-dark); font-family: var(--mono); font-size: 18px; }
.governance-list h3 { font-size: 17px; }
.governance-list p { margin-top: 7px; color: var(--muted); font-size: 13px; line-height: 1.7; }

.access-section { padding-block: 108px; color: white; background: #0a2233; }
.access-grid { display: grid; grid-template-columns: 1fr 460px; gap: 100px; align-items: center; }
.access-copy .eyebrow { color: #5be0b8; }
.access-copy h2 { max-width: 560px; margin-top: 16px; font-size: 48px; font-weight: 630; letter-spacing: -.045em; line-height: 1.07; }
.access-copy > p { max-width: 560px; margin-top: 22px; color: #9eb1bb; line-height: 1.7; }
.security-note { max-width: 560px; display: flex; gap: 16px; margin-top: 35px; padding-top: 27px; border-top: 1px solid #2c495a; }
.security-note > span { color: var(--accent); font-size: 23px; }
.security-note p { color: #93a8b3; font-size: 12px; line-height: 1.65; }
.security-note strong { display: block; margin-bottom: 4px; color: white; }
.login-card { padding: 32px; color: var(--ink); background: white; border-radius: 16px; box-shadow: var(--shadow-lg); }
.login-card-header { display: flex; align-items: center; gap: 15px; padding-bottom: 24px; border-bottom: 1px solid var(--line); }
.login-card-header img { border-radius: 10px; }
.login-card-header h2 { margin-top: 3px; font-size: 23px; letter-spacing: -.025em; }
.login-form { display: grid; margin-top: 25px; }
.login-form label { margin: 15px 0 7px; color: #394f5b; font-size: 11px; font-weight: 750; }
.login-form input { width: 100%; height: 50px; padding: 0 14px; color: var(--ink); background: #f8fafb; border: 1px solid var(--line-dark); border-radius: 8px; }
.login-form input::placeholder { color: #9aa8af; }
.login-form .button { margin-top: 23px; justify-content: space-between; }
.form-message { min-height: 20px; margin-top: 12px; color: var(--red); font-size: 12px; }
.form-message.success { color: var(--accent-dark); }
.secure-entry { display: grid; gap: 18px; margin-top: 23px; }
.secure-entry > p { color: var(--muted); font-size: 12px; line-height: 1.65; }
.secure-entry ol { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; list-style: none; }
.secure-entry li { min-height: 52px; display: flex; align-items: center; gap: 8px; padding: 10px; color: #425762; background: #f5f8f9; border: 1px solid var(--line); border-radius: 7px; font-size: 9px; font-weight: 650; }
.secure-entry li span { width: 21px; height: 21px; display: grid; place-items: center; flex: 0 0 auto; color: #063025; background: var(--accent); border-radius: 50%; font-family: var(--mono); font-size: 8px; }
.login-footnote { display: flex; align-items: center; gap: 8px; margin-top: 11px; color: #86949b; font-size: 10px; text-align: center; }
.login-footnote span { color: var(--accent); font-size: 8px; }
.site-footer { min-height: 120px; display: grid; grid-template-columns: 200px 1fr auto; gap: 35px; align-items: center; }
.site-footer > p { color: var(--muted); font-size: 11px; text-align: center; }
.site-footer > a { color: var(--muted); font-size: 11px; font-weight: 700; text-decoration: none; }

/* Portal shell */
.portal { color: var(--ink); background: #f3f6f7; }
.password-gate { position: fixed; inset: 0; z-index: 500; display: grid; place-items: center; padding: 20px; background: radial-gradient(circle at 50% 20%, #173c51, var(--ink) 56%); }
.password-gate[hidden] { display: none; }
.password-gate-card { width: min(440px, 100%); padding: 29px; background: white; border: 1px solid #385469; border-radius: 15px; box-shadow: 0 35px 90px rgba(0, 0, 0, .38); }
.password-gate-card .login-card-header h1 { margin-top: 3px; font-size: 22px; letter-spacing: -.025em; }
.gate-intro { margin-top: 20px; color: var(--muted); font-size: 11px; line-height: 1.65; }
.gate-intro strong { color: var(--ink); }
.gate-exit { display: block; margin-top: 4px; color: var(--muted); font-size: 9px; font-weight: 650; text-align: center; }
.portal-shell { min-height: 100vh; display: grid; grid-template-columns: 236px minmax(0, 1fr); grid-template-rows: 64px minmax(0, 1fr); }
.portal-topbar { position: sticky; top: 0; z-index: 40; grid-column: 1 / -1; display: grid; grid-template-columns: 236px 1fr auto; align-items: center; color: white; background: var(--ink); border-bottom: 1px solid #254153; }
.portal-brand { height: 64px; padding-inline: 20px; color: white; border-right: 1px solid #254153; }
.portal-brand img { box-shadow: none; }
.portal-brand small { color: #8fa6b2; }
.warehouse-state { display: flex; align-items: center; gap: 11px; padding-left: 24px; }
.warehouse-state > span:nth-child(2) { display: grid; line-height: 1.15; }
.warehouse-state small { color: #7f98a5; font-size: 8px; font-weight: 750; letter-spacing: .1em; text-transform: uppercase; }
.warehouse-state strong { margin-top: 3px; font-size: 11px; font-weight: 650; }
.topbar-actions { display: flex; align-items: center; padding-right: 13px; }
.icon-button { width: 40px; height: 40px; display: grid; place-items: center; border: 0; background: transparent; cursor: pointer; }
.mobile-menu-button { display: none; color: white; }
.account-menu { position: relative; }
.account-button { min-width: 230px; height: 46px; display: flex; align-items: center; gap: 10px; padding: 0 12px; color: white; background: transparent; border: 0; border-left: 1px solid #254153; cursor: pointer; }
.avatar { width: 30px; height: 30px; display: grid; place-items: center; flex: 0 0 auto; color: #09241c; background: var(--accent); border-radius: 50%; font-size: 10px; font-weight: 850; }
.account-copy { min-width: 0; display: grid; flex: 1; text-align: left; }
.account-copy strong { overflow: hidden; font-size: 10px; font-weight: 700; text-overflow: ellipsis; white-space: nowrap; }
.account-copy small { margin-top: 2px; color: #849daa; font-size: 8px; }
.account-popover { position: absolute; top: calc(100% + 8px); right: 0; z-index: 50; width: 260px; padding: 15px; color: var(--ink); background: white; border: 1px solid var(--line); border-radius: 10px; box-shadow: var(--shadow-lg); }
.account-popover p { display: grid; }
.account-popover strong { overflow: hidden; font-size: 12px; text-overflow: ellipsis; }
.account-popover span { margin-top: 3px; color: var(--muted); font-size: 10px; }
.account-popover button { width: 100%; margin-top: 13px; padding: 9px; color: var(--red); background: var(--red-soft); border: 0; border-radius: 6px; cursor: pointer; font-size: 11px; font-weight: 750; text-align: left; }

.portal-sidebar { position: sticky; top: 64px; height: calc(100vh - 64px); z-index: 30; display: flex; flex-direction: column; overflow-y: auto; color: #c9d5da; background: #0b2233; border-right: 1px solid #203e4f; }
.sidebar-section { padding: 23px 13px 8px; }
.sidebar-label { margin: 0 10px 10px; color: #607d8d; font-size: 8px; font-weight: 850; letter-spacing: .14em; text-transform: uppercase; }
.portal-nav { display: grid; gap: 3px; }
.nav-item { width: 100%; min-height: 42px; display: grid; grid-template-columns: 25px minmax(0, 1fr) auto; align-items: center; padding: 0 10px; color: #9bb0ba; background: transparent; border: 0; border-radius: 7px; cursor: pointer; font-size: 11px; font-weight: 650; text-align: left; }
.nav-item:hover { color: white; background: #112d3e; }
.nav-item.active { color: white; background: #17374a; box-shadow: inset 3px 0 var(--accent); }
.nav-item > span:first-child { width: 21px; color: #7f9aa8; font-family: var(--mono); font-size: 13px; text-align: center; }
.nav-item.active > span:first-child { color: var(--accent); }
.nav-item b { min-width: 22px; padding: 2px 5px; color: #8fa7b2; background: #18384a; border-radius: 999px; font-size: 8px; text-align: center; }
.nav-item i { padding: 2px 5px; color: #73e0bd; background: rgba(39, 201, 149, .11); border-radius: 3px; font-family: var(--mono); font-size: 7px; font-style: normal; }
.sidebar-card { display: flex; gap: 10px; margin: auto 14px 0; padding: 14px; background: #112d3e; border: 1px solid #284658; border-radius: 9px; }
.sidebar-card-icon { width: 22px; height: 22px; display: grid; place-items: center; flex: 0 0 auto; color: #09231c; background: var(--accent); border-radius: 50%; font-size: 11px; font-weight: 800; }
.sidebar-card p { display: grid; gap: 5px; }
.sidebar-card strong { color: white; font-size: 10px; }
.sidebar-card span { color: #829ba8; font-size: 8px; line-height: 1.5; }
.sidebar-build { display: flex; justify-content: space-between; margin: 16px 24px 19px; color: #587687; font-family: var(--mono); font-size: 8px; }

.workspace-main { min-width: 0; padding: 35px 40px 70px; }
.workspace-view { display: none; width: min(1440px, 100%); margin-inline: auto; }
.workspace-view.active { display: block; animation: view-in .22s ease both; }
@keyframes view-in { from { opacity: .3; transform: translateY(3px); } to { opacity: 1; transform: translateY(0); } }
.workspace-heading { min-height: 84px; display: flex; align-items: flex-end; justify-content: space-between; gap: 30px; margin-bottom: 26px; }
.workspace-heading h1 { margin-top: 7px; font-size: 31px; font-weight: 660; letter-spacing: -.04em; line-height: 1.08; }
.workspace-heading > div > p:last-child { margin-top: 7px; color: var(--muted); font-size: 12px; }
.heading-actions { display: flex; align-items: center; gap: 9px; }
.mode-pill { align-self: center; display: inline-flex; align-items: center; gap: 9px; padding: 8px 12px; color: var(--accent-dark); background: var(--green-soft); border: 1px solid #bce7d6; border-radius: 999px; font-size: 10px; font-weight: 750; }
.mode-pill .status-dot { width: 6px; height: 6px; }
.global-notice { width: min(1440px, 100%); margin: 0 auto 17px; padding: 12px 15px; color: #754b0b; background: var(--amber-soft); border: 1px solid #e9cc96; border-radius: 8px; font-size: 11px; }
.global-notice.error { color: #8c2431; background: var(--red-soft); border-color: #efb9c0; }
.global-notice.success { color: #08644e; background: var(--green-soft); border-color: #bce7d6; }

.coverage-notice { display: flex; gap: 13px; margin-bottom: 18px; padding: 14px 17px; color: #2c4a58; background: #eaf1f4; border: 1px solid #ccdae0; border-radius: 9px; }
.coverage-notice > span { width: 23px; height: 23px; display: grid; place-items: center; flex: 0 0 auto; color: #f7fbfc; background: #517585; border-radius: 50%; font-family: var(--serif); font-size: 14px; font-weight: 800; }
.coverage-notice strong { font-size: 11px; }
.coverage-notice p { margin-top: 3px; color: #5b717c; font-size: 10px; line-height: 1.55; }
.methodology-strip { display: grid; grid-template-columns: repeat(4, 1fr); margin-bottom: 14px; color: white; background: var(--ink); border-radius: 9px; }
.methodology-strip > div { min-width: 0; display: grid; padding: 13px 15px; border-right: 1px solid #2a4656; }
.methodology-strip > div:last-child { border: 0; }
.methodology-strip span { color: #7894a3; font-size: 7px; font-weight: 800; letter-spacing: .08em; text-transform: uppercase; }
.methodology-strip strong { margin-top: 5px; overflow: hidden; font-size: 10px; text-overflow: ellipsis; white-space: nowrap; }
.methodology-strip small { margin-top: 4px; color: #78909d; font-size: 7px; line-height: 1.4; }
.metric-cards { display: grid; grid-template-columns: repeat(4, 1fr); gap: 13px; }
.metric-card { min-height: 132px; padding: 18px; background: white; border: 1px solid var(--line); border-radius: 10px; box-shadow: var(--shadow-sm); }
.metric-card > div { display: flex; align-items: center; justify-content: space-between; gap: 7px; }
.metric-card > div > span { color: var(--muted); font-size: 9px; font-weight: 700; letter-spacing: .04em; text-transform: uppercase; }
.metric-card > strong { display: block; margin-top: 18px; font-size: 27px; letter-spacing: -.04em; }
.metric-card > p { margin-top: 4px; color: var(--muted-2); font-size: 9px; }
.trend { padding: 3px 6px; border-radius: 4px; font-size: 7px; font-weight: 800; text-transform: uppercase; }
.trend.good { color: #087059; background: var(--green-soft); }
.trend.neutral { color: #346173; background: #e9f0f3; }
.overview-grid { display: grid; grid-template-columns: 1.35fr .65fr; gap: 14px; margin-top: 14px; }
.panel { background: white; border: 1px solid var(--line); border-radius: 10px; box-shadow: var(--shadow-sm); }
.overview-catalog-panel { grid-row: span 2; }
.panel-header { min-height: 67px; display: flex; align-items: center; justify-content: space-between; gap: 18px; padding: 16px 19px; border-bottom: 1px solid var(--line); }
.panel-header h2 { margin-top: 3px; font-size: 15px; letter-spacing: -.02em; }
.domain-list { padding: 5px 19px 12px; }
.domain-row { display: grid; grid-template-columns: 31px 1fr auto; gap: 12px; align-items: center; padding-block: 15px; border-bottom: 1px solid #e8edef; }
.domain-row:last-child { border-bottom: 0; }
.domain-icon { width: 31px; height: 31px; display: grid; place-items: center; color: var(--accent-dark); background: var(--green-soft); border-radius: 7px; font-family: var(--mono); font-size: 11px; font-weight: 800; }
.domain-row p { display: grid; }
.domain-row strong { font-size: 11px; }
.domain-row small { margin-top: 3px; color: var(--muted); font-size: 9px; }
.domain-row > span:last-child { color: var(--muted); font-family: var(--mono); font-size: 10px; }
.health-pill { padding: 5px 8px; color: #087059; background: var(--green-soft); border: 1px solid #c2ebdc; border-radius: 999px; font-size: 8px; font-weight: 800; text-transform: uppercase; }
.health-pill.neutral { color: #49636f; background: #edf2f4; border-color: #d8e2e6; }
.freshness-clock { display: grid; padding: 22px 19px 17px; }
.freshness-clock span { color: var(--muted); font-size: 9px; text-transform: uppercase; }
.freshness-clock strong { margin-top: 7px; font-family: var(--mono); font-size: 18px; letter-spacing: -.03em; }
.freshness-clock small { margin-top: 4px; color: var(--muted-2); font-size: 9px; }
.fact-list { padding: 0 19px 15px; }
.fact-list div { display: flex; justify-content: space-between; gap: 15px; padding-block: 9px; border-top: 1px solid #e8edef; font-size: 9px; }
.fact-list dt { color: var(--muted); }
.fact-list dd { font-weight: 650; text-align: right; }
.compact-jobs { padding: 5px 19px 12px; }
.compact-job { display: grid; grid-template-columns: 1fr auto; gap: 12px; padding-block: 12px; border-bottom: 1px solid #e8edef; }
.compact-job:last-child { border-bottom: 0; }
.compact-job p { display: grid; }
.compact-job strong { font-size: 10px; }
.compact-job small { margin-top: 3px; color: var(--muted); font-size: 8px; }
.compact-job > span { align-self: center; color: var(--accent-dark); font-size: 9px; font-weight: 750; }
.empty-state { min-height: 190px; display: grid; place-content: center; justify-items: center; color: var(--muted-2); text-align: center; }
.empty-state.compact { min-height: 95px; }
.empty-state > span { font-size: 22px; }
.empty-state p { margin-top: 7px; font-size: 10px; }
.loading-block > span { display: block; height: 45px; margin-block: 10px; background: linear-gradient(90deg, #eef2f3 25%, #f9fbfb 50%, #eef2f3 75%); background-size: 200% 100%; border-radius: 6px; animation: shimmer 1.35s infinite; }
@keyframes shimmer { to { background-position: -200% 0; } }

/* Owner adoption dashboard */
.adoption-metrics { display: grid; grid-template-columns: repeat(6, minmax(0, 1fr)); gap: 10px; margin-bottom: 13px; }
.adoption-metrics article { min-width: 0; min-height: 120px; display: grid; align-content: start; padding: 15px; background: white; border: 1px solid var(--line); border-radius: 9px; box-shadow: var(--shadow-sm); }
.adoption-metrics article > span { min-height: 29px; color: var(--muted); font-size: 8px; font-weight: 750; line-height: 1.35; text-transform: uppercase; }
.adoption-metrics article > strong { margin-top: 10px; font-size: 24px; letter-spacing: -.04em; }
.adoption-metrics article > small { margin-top: 5px; overflow: hidden; color: var(--muted-2); font-size: 7px; text-overflow: ellipsis; white-space: nowrap; }
.info-tip { width: 15px; height: 15px; display: inline-grid; place-items: center; margin-left: 3px; padding: 0; color: var(--muted); background: #edf2f4; border: 0; border-radius: 50%; cursor: help; font-family: var(--serif); font-size: 8px; font-weight: 850; }
.adoption-grid { display: grid; grid-template-columns: minmax(0, 1.35fr) minmax(280px, .65fr); gap: 13px; align-items: start; }
.funnel-panel, .retention-summary-panel, .adoption-series-panel, .cohort-panel, .metric-definitions { overflow: hidden; }
.funnel-chart { display: grid; gap: 8px; padding: 17px 19px 20px; }
.funnel-row { display: grid; grid-template-columns: 145px minmax(100px, 1fr) 64px; gap: 12px; align-items: center; }
.funnel-row > span { overflow: hidden; color: #405661; font-size: 9px; font-weight: 650; text-overflow: ellipsis; white-space: nowrap; }
.funnel-track { height: 24px; overflow: hidden; background: #edf2f4; border-radius: 4px; }
.funnel-bar { height: 100%; min-width: 2px; display: flex; align-items: center; padding-left: 8px; color: #05251c; background: linear-gradient(90deg, #23c793, #74e1be); border-radius: 4px; font-size: 7px; font-weight: 800; transition: width .35s ease; }
.funnel-value { display: grid; text-align: right; }
.funnel-value strong { font-family: var(--mono); font-size: 9px; }
.funnel-value small { color: var(--muted); font-size: 7px; }
.retention-rings { display: grid; grid-template-columns: repeat(2, 1fr); gap: 10px; padding: 22px 19px 13px; }
.retention-rings > div { aspect-ratio: 1.5; display: grid; place-content: center; justify-items: center; background: radial-gradient(circle at 50% 50%, white 49%, transparent 50%), conic-gradient(var(--accent) var(--retention, 0%), #e8eef0 0); border-radius: 50%; }
.retention-rings span { font-family: var(--mono); font-size: 16px; font-weight: 750; }
.retention-rings small { margin-top: 2px; color: var(--muted); font-size: 7px; font-weight: 800; }
.retention-note { margin: 0 19px 18px; padding-top: 11px; color: var(--muted); border-top: 1px solid var(--line); font-size: 8px; line-height: 1.55; }
.adoption-series-panel, .cohort-panel, .metric-definitions { grid-column: 1 / -1; }
.chart-legend { display: flex; align-items: center; gap: 12px; color: var(--muted); font-size: 7px; }
.chart-legend span { display: flex; align-items: center; gap: 5px; }
.chart-legend i { width: 7px; height: 7px; border-radius: 2px; }
.legend-launch { background: var(--accent); }.legend-use { background: var(--blue); }.legend-return { background: #9568d8; }
.series-chart { min-height: 270px; padding: 16px 19px 18px; }
.series-chart svg { width: 100%; height: 235px; overflow: visible; }
.series-grid-line { stroke: #e2e8ea; stroke-width: 1; }
.series-axis-label { fill: #82929a; font-family: var(--sans); font-size: 8px; }
.series-path { fill: none; stroke-linejoin: round; stroke-linecap: round; stroke-width: 2.2; }
.series-area { opacity: .08; }
.cohort-table { min-width: 650px; }
.cohort-table td:not(:first-child) { font-family: var(--mono); }
.cohort-heat { display: inline-flex; min-width: 42px; justify-content: center; padding: 5px 7px; color: #064e3b; background: rgba(39, 201, 149, var(--heat, .1)); border-radius: 4px; font-size: 8px; font-weight: 750; }
.cohort-heat.withheld { color: var(--muted); background: #edf2f4; }
.metric-definitions { margin-top: 13px; }
.metric-definitions dl { display: grid; grid-template-columns: repeat(3, 1fr); padding: 0 19px 16px; }
.metric-definitions dl > div { padding: 16px 17px 4px 0; }
.metric-definitions dt { font-size: 9px; font-weight: 750; }
.metric-definitions dd { margin-top: 6px; color: var(--muted); font-size: 8px; line-height: 1.55; }

/* Catalog */
.toolbar { display: flex; align-items: end; gap: 10px; padding: 13px; background: white; border: 1px solid var(--line); border-radius: 9px; box-shadow: var(--shadow-sm); }
.search-field { min-width: 240px; height: 40px; display: flex; align-items: center; flex: 1; gap: 9px; padding-inline: 12px; background: #f7f9fa; border: 1px solid var(--line); border-radius: 7px; }
.search-field > span:not(.sr-only) { color: var(--muted-2); font-size: 17px; }
.search-field input { min-width: 0; width: 100%; height: 100%; padding: 0; color: var(--ink); background: transparent; border: 0; outline: 0; font-size: 11px; }
.search-field input::placeholder { color: #92a0a7; }
.search-field.small { min-width: 0; height: 35px; margin: 12px; }
.select-field { display: grid; gap: 4px; }
.select-field > span { color: var(--muted); font-size: 8px; font-weight: 750; text-transform: uppercase; }
.select-field select { height: 40px; min-width: 135px; padding: 0 30px 0 11px; color: var(--ink); background: #f7f9fa; border: 1px solid var(--line); border-radius: 7px; font-size: 10px; }
.catalog-toolbar > .text-button { height: 40px; margin-left: auto; padding-inline: 10px; color: var(--red); font-size: 10px; }
.catalog-summary-line { display: flex; justify-content: space-between; margin: 17px 2px 9px; color: var(--muted); font-size: 10px; }
.catalog-summary-line strong, .catalog-summary-line span { color: var(--ink); font-weight: 750; }
.dataset-catalog { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
.dataset-card { align-self: start; overflow: hidden; background: white; border: 1px solid var(--line); border-radius: 10px; box-shadow: var(--shadow-sm); transition: border-color .18s ease, box-shadow .18s ease; }
.dataset-card.selected { border-color: #63cdb0; box-shadow: 0 0 0 2px rgba(39, 201, 149, .1); }
.dataset-card-header { min-height: 105px; display: grid; grid-template-columns: 26px minmax(0, 1fr) auto; gap: 10px; align-items: start; padding: 17px; }
.dataset-check { margin-top: 2px; }
.dataset-check input { position: absolute; opacity: 0; pointer-events: none; }
.dataset-check span, .custom-checkbox { width: 18px; height: 18px; display: grid; place-items: center; border: 1px solid #aebdc4; border-radius: 4px; background: white; }
.dataset-check input:checked + span, .field-row input:checked + .custom-checkbox { background: var(--accent); border-color: var(--accent-dark); }
.dataset-check input:checked + span::after, .field-row input:checked + .custom-checkbox::after { content: "✓"; color: #06271e; font-size: 11px; font-weight: 900; }
.dataset-check input:focus-visible + span, .field-row input:focus-visible + .custom-checkbox { outline: 3px solid rgba(23, 104, 229, .25); outline-offset: 2px; }
.dataset-title > div { display: flex; align-items: center; flex-wrap: wrap; gap: 6px; }
.domain-pill, .freshness-tag { display: inline-flex; padding: 3px 6px; border-radius: 4px; font-size: 7px; font-weight: 850; letter-spacing: .05em; text-transform: uppercase; }
.domain-pill { color: #29586c; background: #e9f0f3; }
.freshness-tag { color: #087059; background: var(--green-soft); }
.freshness-tag.stale { color: #865108; background: var(--amber-soft); }
.dataset-title h2 { margin-top: 8px; font-family: var(--mono); font-size: 13px; letter-spacing: -.02em; }
.dataset-title p { margin-top: 5px; color: var(--muted); font-size: 9px; line-height: 1.5; }
.dataset-expand { display: flex; align-items: center; gap: 7px; margin-top: 2px; padding: 6px 8px; color: var(--muted); background: #f6f8f9; border: 1px solid var(--line); border-radius: 5px; cursor: pointer; font-size: 8px; font-weight: 750; }
.dataset-expand > span:last-child { transition: transform .18s ease; }
.dataset-expand[aria-expanded="true"] > span:last-child { transform: rotate(180deg); }
.dataset-facts { display: grid; grid-template-columns: .8fr 1.2fr .8fr 1.1fr; border-top: 1px solid #e6ecee; }
.dataset-facts div { min-width: 0; padding: 11px 12px; border-right: 1px solid #e6ecee; }
.dataset-facts div:last-child { border: 0; }
.dataset-facts dt { color: var(--muted-2); font-size: 7px; font-weight: 750; text-transform: uppercase; }
.dataset-facts dd { overflow: hidden; margin-top: 4px; font-size: 8px; font-weight: 650; text-overflow: ellipsis; white-space: nowrap; }
.dataset-fields { border-top: 1px solid var(--line); }
.field-toolbar { height: 37px; display: flex; align-items: center; justify-content: space-between; padding-inline: 14px; color: var(--muted); background: #f7f9fa; border-bottom: 1px solid var(--line); font-size: 8px; font-weight: 750; text-transform: uppercase; }
.field-toolbar button { padding: 0; color: var(--blue); background: none; border: 0; cursor: pointer; font-size: 8px; font-weight: 750; }
.field-list { max-height: 325px; overflow-y: auto; }
.field-row { min-height: 48px; position: relative; display: grid; grid-template-columns: 18px minmax(110px, 1fr) auto auto 24px; gap: 10px; align-items: center; padding: 8px 12px; border-bottom: 1px solid #edf1f2; cursor: pointer; }
.field-row:last-child { border: 0; }
.field-row:hover { background: #fafcfc; }
.field-row > input { position: absolute; opacity: 0; pointer-events: none; }
.field-name { min-width: 0; display: grid; }
.field-name strong { overflow: hidden; font-family: var(--mono); font-size: 9px; text-overflow: ellipsis; white-space: nowrap; }
.field-name small { overflow: hidden; margin-top: 3px; color: var(--muted); font-size: 8px; text-overflow: ellipsis; white-space: nowrap; }
.field-type { padding: 3px 5px; color: #376375; background: #ecf2f4; border-radius: 3px; font-size: 7px; }
.field-quality { color: #087059; font-size: 7px; font-weight: 750; }
.field-info { width: 20px; height: 20px; display: grid; place-items: center; color: var(--muted); background: transparent; border: 1px solid var(--line); border-radius: 50%; cursor: pointer; font-family: var(--serif); font-size: 10px; font-weight: 800; }
.dataset-catalog > .empty-state { grid-column: 1 / -1; background: white; border: 1px solid var(--line); border-radius: 10px; }

/* Dictionary */
.dictionary-version { min-width: 170px; align-self: center; display: grid; padding: 11px 14px; background: white; border: 1px solid var(--line); border-radius: 8px; }
.dictionary-version span { color: var(--muted); font-size: 8px; text-transform: uppercase; }
.dictionary-version strong { margin-top: 4px; font-family: var(--mono); font-size: 12px; }
.dictionary-version small { margin-top: 3px; color: var(--muted-2); font-size: 8px; }
.dictionary-stats { display: grid; grid-template-columns: repeat(4, 1fr); margin-bottom: 12px; background: var(--ink); border-radius: 9px; }
.dictionary-stats div { display: flex; align-items: baseline; justify-content: space-between; gap: 10px; padding: 13px 16px; border-right: 1px solid #284555; }
.dictionary-stats div:last-child { border: 0; }
.dictionary-stats span { color: #8aa1ad; font-size: 8px; text-transform: uppercase; }
.dictionary-stats strong { color: white; font-family: var(--mono); font-size: 13px; }
.dictionary-caveat { display: grid; grid-template-columns: 25px 1fr; gap: 10px; align-items: start; margin-bottom: 12px; padding: 12px 14px; color: #5f4a22; background: #fff6e7; border: 1px solid #e8d1aa; border-radius: 8px; }
.dictionary-caveat > span { color: var(--amber); font-family: var(--mono); }
.dictionary-caveat p { font-size: 8px; line-height: 1.55; }
.dictionary-caveat strong { display: inline; color: #4d3917; }
.dictionary-toolbar { border-radius: 9px 9px 0 0; box-shadow: none; }
.dictionary-table-wrap { border-inline: 1px solid var(--line); }
.table-wrap { overflow-x: auto; background: white; }
.data-table { width: 100%; border-collapse: collapse; }
.data-table th { height: 37px; padding: 0 13px; color: #657882; background: #f4f7f8; border-bottom: 1px solid var(--line); font-size: 7px; font-weight: 850; letter-spacing: .08em; text-align: left; text-transform: uppercase; white-space: nowrap; }
.data-table td { min-height: 47px; padding: 11px 13px; border-bottom: 1px solid #e9eef0; color: #40545f; font-size: 9px; vertical-align: top; }
.dictionary-table th:nth-child(1) { width: 18%; }
.dictionary-table th:nth-child(2) { width: 36%; }
.dictionary-table td:first-child strong { display: block; color: var(--ink); font-family: var(--mono); font-size: 9px; }
.dictionary-table td:first-child small { display: block; margin-top: 4px; color: var(--muted); font-size: 7px; }
.dictionary-table .definition-cell { max-width: 430px; line-height: 1.55; }
.type-chip, .quality-chip { display: inline-flex; padding: 3px 5px; border-radius: 3px; font-family: var(--mono); font-size: 7px; }
.type-chip { color: #315d70; background: #eaf1f4; }
.quality-chip { color: #087059; background: var(--green-soft); font-family: var(--sans); font-weight: 750; }
.table-loading { min-height: 160px; display: grid; place-items: center; color: var(--muted); font-size: 10px; }
.table-footer { min-height: 51px; display: flex; align-items: center; justify-content: space-between; padding: 0 14px; background: white; border: 1px solid var(--line); border-radius: 0 0 9px 9px; }
.table-footer > p { color: var(--muted); font-size: 9px; }
.pagination { display: flex; align-items: center; gap: 10px; }
.pagination button { padding: 5px 8px; background: #f7f9fa; border: 1px solid var(--line); border-radius: 5px; cursor: pointer; font-size: 8px; }
.pagination button:disabled { opacity: .45; cursor: not-allowed; }
.pagination span { color: var(--muted); font-size: 8px; }

/* Query */
.query-safety { display: grid; grid-template-columns: 185px 1fr; gap: 20px; margin-bottom: 13px; padding: 13px 16px; color: #6b480d; background: var(--amber-soft); border: 1px solid #e7cd9e; border-radius: 8px; }
.query-safety strong { font-size: 10px; }
.query-safety p { font-size: 9px; line-height: 1.55; }
.query-layout { display: grid; grid-template-columns: 230px minmax(0, 1fr); gap: 13px; align-items: start; }
.query-browser { position: sticky; top: 82px; overflow: hidden; }
.query-browser > header { min-height: 60px; display: flex; align-items: center; justify-content: space-between; padding: 13px; border-bottom: 1px solid var(--line); }
.query-browser h2 { margin-top: 3px; font-size: 13px; }
.schema-tree { max-height: 560px; overflow: auto; padding: 4px 12px 14px; }
.schema-dataset { border-bottom: 1px solid #e8edef; }
.schema-dataset > button { width: 100%; min-height: 38px; display: flex; align-items: center; justify-content: space-between; padding: 0; background: none; border: 0; cursor: pointer; font-family: var(--mono); font-size: 9px; font-weight: 700; text-align: left; }
.schema-dataset > button span { color: var(--muted); font-family: var(--sans); font-size: 8px; }
.schema-fields { display: none; padding: 0 0 9px 7px; }
.schema-dataset.open .schema-fields { display: grid; }
.schema-fields button { min-height: 27px; display: flex; align-items: center; justify-content: space-between; gap: 7px; padding: 0 4px; color: #425964; background: none; border: 0; cursor: pointer; font-family: var(--mono); font-size: 8px; text-align: left; }
.schema-fields button:hover { color: var(--blue); }
.schema-fields code { color: var(--muted-2); font-size: 7px; }
.query-workbench { min-width: 0; }
.query-editor-card { overflow: hidden; background: #0b2233; border: 1px solid #294758; border-radius: 10px; box-shadow: var(--shadow-sm); }
.editor-bar { height: 43px; display: flex; align-items: center; justify-content: space-between; padding-inline: 13px; color: #9ab0bc; background: #102a3b; border-bottom: 1px solid #294758; }
.editor-bar > div { display: flex; align-items: center; gap: 6px; }
.editor-bar strong { margin-left: 6px; font-family: var(--mono); font-size: 8px; font-weight: 550; }
.editor-dot { width: 7px; height: 7px; border-radius: 50%; }
.editor-dot.red { background: #e36976; }.editor-dot.amber { background: #e7a74a; }.editor-dot.green { background: #4fcba1; }
.editor-bar button { padding: 4px 6px; color: #8da4af; background: transparent; border: 0; cursor: pointer; font-size: 8px; }
.editor-shell { min-height: 280px; display: grid; grid-template-columns: 42px minmax(0, 1fr); }
.line-numbers { padding: 19px 10px; color: #4f6b7a; background: #091f2e; border-right: 1px solid #233f50; font-family: var(--mono); font-size: 11px; line-height: 1.72; text-align: right; white-space: pre-line; user-select: none; }
.editor-shell textarea { width: 100%; min-height: 280px; resize: vertical; padding: 18px; color: #dbebef; background: #0b2233; border: 0; outline: 0; font-family: var(--mono); font-size: 11px; line-height: 1.72; tab-size: 2; }
.editor-shell textarea::placeholder { color: #527080; }
.query-actions { min-height: 60px; display: flex; align-items: center; justify-content: space-between; gap: 20px; padding: 9px 12px; background: #102a3b; border-top: 1px solid #294758; }
.select-field.inline { display: flex; align-items: center; gap: 8px; }
.select-field.inline span { color: #7f98a5; }
.select-field.inline select { width: 72px; min-width: 0; height: 34px; color: white; background: #173649; border-color: #355264; }
.query-actions > div { display: flex; gap: 8px; }
.query-actions .button-secondary { color: #c1d0d6; background: transparent; border-color: #3c596a; }
.query-examples { display: flex; align-items: center; gap: 7px; margin-block: 9px; }
.query-examples span { color: var(--muted); font-size: 8px; text-transform: uppercase; }
.query-examples button { padding: 5px 8px; color: #41606f; background: white; border: 1px solid var(--line); border-radius: 5px; cursor: pointer; font-size: 8px; }
.query-results-panel { overflow: hidden; }
.result-meta { display: flex; align-items: center; gap: 14px; color: var(--muted); font-size: 8px; }
.result-meta button:disabled { cursor: not-allowed; opacity: .45; }
.preview-placeholder { min-height: 245px; display: grid; place-content: center; justify-items: center; padding: 25px; color: var(--muted-2); text-align: center; }
.preview-placeholder > span { width: 38px; height: 38px; display: grid; place-items: center; background: #edf2f4; border-radius: 50%; font-family: var(--mono); }
.preview-placeholder h3 { margin-top: 12px; color: #4d626d; font-size: 12px; }
.preview-placeholder p { max-width: 390px; margin-top: 6px; font-size: 9px; line-height: 1.55; }
.preview-placeholder.small { min-height: 100px; margin-top: 10px; padding: 12px; background: #f7f9fa; border: 1px dashed var(--line-dark); border-radius: 7px; }
.preview-table-wrap { max-height: 380px; overflow: auto; }
.preview-table { min-width: 650px; }
.preview-table td { font-family: var(--mono); font-size: 8px; white-space: nowrap; }

/* Exports */
.export-principles { display: grid; grid-template-columns: repeat(3, 1fr); gap: 11px; margin-bottom: 13px; }
.export-principles > div { min-height: 75px; display: flex; align-items: center; gap: 12px; padding: 14px; background: white; border: 1px solid var(--line); border-radius: 8px; }
.export-principles > div > span { width: 31px; height: 31px; display: grid; place-items: center; flex: 0 0 auto; color: var(--accent-dark); background: var(--green-soft); border-radius: 7px; font-family: var(--mono); font-size: 12px; }
.export-principles p { display: grid; }
.export-principles strong { font-size: 10px; }
.export-principles small { margin-top: 3px; color: var(--muted); font-size: 8px; }
.jobs-panel { overflow: hidden; }
.jobs-table { min-width: 970px; }
.job-name strong { display: block; color: var(--ink); font-family: var(--mono); font-size: 9px; }
.job-name small { display: block; margin-top: 4px; color: var(--muted); font-size: 7px; }
.file-format { display: inline-flex; padding: 4px 6px; color: #315c6e; background: #eaf1f4; border-radius: 4px; font-family: var(--mono); font-size: 8px; font-weight: 750; text-transform: uppercase; }
.job-integrity code { display: block; max-width: 120px; overflow: hidden; color: var(--muted); font-size: 7px; text-overflow: ellipsis; }
.job-integrity button, .job-actions a, .job-actions button { margin-top: 4px; padding: 0; color: var(--blue); background: none; border: 0; cursor: pointer; font-size: 8px; text-decoration: none; }
.job-status { display: inline-flex; align-items: center; gap: 5px; padding: 4px 7px; border-radius: 999px; font-size: 7px; font-weight: 800; text-transform: uppercase; }
.job-status.complete { color: #087059; background: var(--green-soft); }
.job-status.processing, .job-status.queued { color: #81510a; background: var(--amber-soft); }
.job-status.failed { color: #982835; background: var(--red-soft); }

/* API */
.api-layout { display: grid; grid-template-columns: .72fr 1.28fr; gap: 13px; align-items: start; }
.api-layout > div { display: grid; gap: 13px; }
.api-token-panel, .api-rules-panel, .api-docs-panel { overflow: hidden; }
.api-token-panel > p { padding: 18px 19px 0; color: var(--muted); font-size: 10px; line-height: 1.6; }
.token-state { display: flex; align-items: center; justify-content: space-between; gap: 15px; margin: 17px 19px 19px; padding: 14px; background: #f5f8f9; border: 1px solid var(--line); border-radius: 7px; }
.token-state > div { display: grid; }
.token-state strong { font-size: 10px; }
.token-state span { margin-top: 4px; color: var(--muted); font-size: 8px; }
.token-result { margin: 0 19px 19px; padding: 14px; color: #65450f; background: var(--amber-soft); border: 1px solid #e5c993; border-radius: 7px; }
.token-result label { font-size: 9px; font-weight: 750; }
.token-result > div { display: flex; margin-top: 7px; }
.token-result input { min-width: 0; height: 38px; flex: 1; padding-inline: 10px; border: 1px solid #cba862; border-radius: 6px 0 0 6px; font-family: var(--mono); font-size: 9px; }
.token-result button { border: 1px solid #cba862; border-left: 0; border-radius: 0 6px 6px 0; background: white; cursor: pointer; font-size: 9px; }
.token-result p { margin-top: 6px; font-size: 8px; }
.token-inventory { margin: 0 19px 19px; border-top: 1px solid var(--line); padding-top: 14px; }
.token-inventory-heading { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 9px; }
.token-inventory-heading strong { font-size: 9px; }
.token-inventory-heading button { border: 0; color: var(--blue); background: transparent; cursor: pointer; font-size: 8px; font-weight: 750; }
.token-list { display: grid; gap: 7px; }
.token-list-item { display: grid; grid-template-columns: minmax(0, 1fr) auto; align-items: center; gap: 10px; padding: 10px 11px; border: 1px solid var(--line); border-radius: 7px; background: #fbfcfc; }
.token-list-item > div { min-width: 0; display: grid; gap: 3px; }
.token-list-item strong { overflow: hidden; font-size: 9px; text-overflow: ellipsis; white-space: nowrap; }
.token-list-item small { color: var(--muted); font-family: var(--mono); font-size: 7px; line-height: 1.45; }
.token-list-item button { border: 1px solid #e1b5b5; border-radius: 5px; padding: 6px 8px; color: #a52c2c; background: #fff6f6; cursor: pointer; font-size: 8px; font-weight: 750; }
.rule-list { padding: 7px 19px 12px; list-style: none; }
.rule-list li { display: grid; grid-template-columns: 25px 1fr; gap: 10px; padding-block: 12px; border-bottom: 1px solid #e8edef; }
.rule-list li:last-child { border: 0; }
.rule-list li > span { color: var(--accent-dark); font-family: var(--mono); font-size: 8px; }
.rule-list p { display: grid; }
.rule-list strong { font-size: 10px; }
.rule-list small { margin-top: 3px; color: var(--muted); font-size: 8px; }
.api-version { padding: 4px 7px; color: var(--accent-dark); background: var(--green-soft); border-radius: 4px; font-family: var(--mono); font-size: 8px; }
.code-tabs { display: flex; gap: 3px; padding: 12px 16px 0; }
.code-tabs button { padding: 7px 11px; color: var(--muted); background: transparent; border: 0; border-bottom: 2px solid transparent; cursor: pointer; font-size: 9px; font-weight: 700; }
.code-tabs button.active { color: var(--ink); border-color: var(--accent); }
.code-sample { display: none; padding: 9px 19px 18px; }
.code-sample.active { display: block; }
.endpoint-line { display: flex; align-items: center; gap: 9px; margin-bottom: 8px; }
.endpoint-line span { padding: 4px 6px; color: #09231b; background: var(--accent); border-radius: 4px; font-size: 7px; font-weight: 850; }
.endpoint-line code { font-size: 10px; font-weight: 700; }
.code-sample pre { overflow: auto; margin: 0; padding: 17px; color: #c9dce3; background: var(--ink); border-radius: 7px; font-size: 9px; line-height: 1.7; }
.code-sample > p { margin-top: 10px; color: var(--muted); font-size: 9px; line-height: 1.55; }
.api-note { display: grid; grid-template-columns: 70px 1fr; gap: 12px; margin: 0 19px 19px; padding: 12px; color: #6d4a0e; background: var(--amber-soft); border: 1px solid #ead0a0; border-radius: 7px; }
.api-note strong { font-size: 9px; }
.api-note p { font-size: 8px; line-height: 1.5; }

/* Export drawer */
.export-drawer { position: fixed; inset: 0; z-index: 100; visibility: hidden; }
.export-drawer.open { visibility: visible; }
.drawer-backdrop { position: absolute; inset: 0; opacity: 0; background: rgba(2, 13, 22, .58); backdrop-filter: blur(2px); transition: opacity .22s ease; }
.export-drawer.open .drawer-backdrop { opacity: 1; }
.drawer-panel { position: absolute; inset: 0 0 0 auto; width: min(620px, 100%); display: grid; grid-template-rows: auto minmax(0, 1fr) auto; background: white; box-shadow: -24px 0 55px rgba(7, 26, 42, .2); transform: translateX(100%); transition: transform .24s ease; }
.export-drawer.open .drawer-panel { transform: translateX(0); }
.drawer-header { min-height: 75px; display: flex; align-items: center; justify-content: space-between; padding: 16px 22px; border-bottom: 1px solid var(--line); }
.drawer-header h2 { margin-top: 4px; font-size: 19px; }
.drawer-header > button { width: 35px; height: 35px; display: grid; place-items: center; color: var(--muted); background: #f4f7f8; border: 1px solid var(--line); border-radius: 50%; cursor: pointer; font-size: 21px; }
.drawer-content { overflow-y: auto; }
.drawer-section { padding: 22px; border-bottom: 1px solid var(--line); }
.drawer-section-title { display: grid; grid-template-columns: 26px 1fr; gap: 11px; align-items: start; }
.drawer-section-title > span { width: 24px; height: 24px; display: grid; place-items: center; color: #073226; background: var(--accent); border-radius: 50%; font-family: var(--mono); font-size: 9px; font-weight: 850; }
.drawer-section-title h3 { font-size: 13px; }
.drawer-section-title p { margin-top: 3px; color: var(--muted); font-size: 9px; }
.export-selection-list { display: grid; gap: 6px; margin: 13px 0 0 37px; }
.export-selection-item { display: flex; justify-content: space-between; gap: 12px; padding: 8px 10px; background: #f6f8f9; border-radius: 6px; font-size: 8px; }
.export-selection-item strong { font-family: var(--mono); }
.export-selection-item span { color: var(--muted); }
.date-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 10px; margin: 13px 0 0 37px; }
.date-grid label { display: grid; gap: 5px; color: var(--muted); font-size: 8px; font-weight: 750; text-transform: uppercase; }
.date-grid input { height: 40px; padding-inline: 10px; color: var(--ink); background: #f7f9fa; border: 1px solid var(--line); border-radius: 6px; font-size: 10px; }
.format-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 8px; margin: 13px 0 0 37px; }
.format-option { position: relative; display: grid; gap: 2px; padding: 11px 9px; background: #f7f9fa; border: 1px solid var(--line); border-radius: 6px; cursor: pointer; }
.format-option:has(input:checked) { background: var(--green-soft); border-color: #68cdb0; box-shadow: 0 0 0 1px #68cdb0; }
.format-option input { position: absolute; opacity: 0; pointer-events: none; }
.format-option strong { font-family: var(--mono); font-size: 9px; }
.format-option small { color: var(--muted); font-size: 7px; }
.option-stack { display: grid; gap: 8px; margin: 13px 0 0 37px; }
.check-option { display: grid; grid-template-columns: 17px 1fr; gap: 10px; align-items: start; padding: 10px; background: #f7f9fa; border: 1px solid var(--line); border-radius: 6px; cursor: pointer; }
.check-option input { margin-top: 2px; accent-color: var(--accent-dark); }
.check-option span { display: grid; }
.check-option strong { font-size: 9px; }
.check-option small { margin-top: 3px; color: var(--muted); font-size: 8px; }
.preview-section > .button, .preview-section > .preview-placeholder { width: calc(100% - 37px); margin-left: 37px; }
.drawer-footer { min-height: 76px; display: flex; align-items: center; justify-content: space-between; gap: 18px; padding: 13px 22px; border-top: 1px solid var(--line); box-shadow: 0 -8px 18px rgba(7, 26, 42, .04); }
.drawer-footer > div { display: grid; }
.drawer-footer span { color: var(--muted); font-size: 8px; text-transform: uppercase; }
.drawer-footer strong { margin-top: 4px; font-size: 10px; }

/* Admin access */
.entitlement-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 11px; margin-bottom: 13px; }
.entitlement-stat { padding: 16px; background: white; border: 1px solid var(--line); border-radius: 9px; }
.entitlement-stat span { color: var(--muted); font-size: 8px; font-weight: 750; text-transform: uppercase; }
.entitlement-stat strong { display: block; margin-top: 10px; font-size: 22px; letter-spacing: -.03em; }
.access-admin-layout { display: grid; grid-template-columns: minmax(0, 1fr) 340px; gap: 13px; align-items: start; }
.users-panel { overflow: hidden; }
.users-table { min-width: 780px; }
.user-identity { display: grid; }
.user-identity strong { color: var(--ink); font-size: 9px; }
.user-identity small { color: var(--muted); font-size: 7px; }
.plan-chip, .role-chip { display: inline-flex; padding: 3px 6px; border-radius: 4px; font-size: 7px; font-weight: 800; text-transform: uppercase; }
.plan-chip { color: #315d70; background: #eaf1f4; }
.role-chip { color: #6d4908; background: var(--amber-soft); }
.user-status { display: inline-flex; color: #087059; font-size: 8px; font-weight: 750; }
.user-status.suspended { color: var(--red); }
.user-actions button { margin-right: 7px; padding: 0; color: var(--blue); background: none; border: 0; cursor: pointer; font-size: 8px; }
.invite-panel { position: sticky; top: 82px; padding-bottom: 18px; }
.invite-form { display: grid; gap: 12px; padding: 17px; }
.invite-form label { display: grid; gap: 5px; color: var(--muted); font-size: 8px; font-weight: 750; text-transform: uppercase; }
.invite-form input, .invite-form select { width: 100%; height: 39px; padding: 0 10px; color: var(--ink); background: #f7f9fa; border: 1px solid var(--line); border-radius: 6px; font-size: 10px; }
.scope-box { padding: 10px; background: #f7f9fa; border: 1px solid var(--line); border-radius: 6px; }
.scope-box > span { display: block; margin-bottom: 7px; color: var(--muted); font-size: 8px; font-weight: 750; text-transform: uppercase; }
.scope-box label { display: flex; align-items: center; gap: 8px; min-height: 25px; color: var(--ink); font-size: 9px; font-weight: 600; text-transform: none; }
.scope-box input { width: auto; height: auto; accent-color: var(--accent-dark); }
.form-split { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.invite-form label small { margin-top: 2px; color: var(--muted); font-size: 7px; font-weight: 500; line-height: 1.45; text-transform: none; }
.invite-form select[multiple] { height: auto; min-height: 106px; padding-block: 7px; }
.invite-form .token-result { margin: 0; }
.users-table .plan-chip + .role-chip { margin-left: 4px; }

@media (max-width: 1120px) {
  .hero { grid-template-columns: 1fr; padding-block: 70px; }
  .hero-copy { max-width: 760px; }
  .research-window { max-width: 760px; transform: none; }
  .portal-shell { grid-template-columns: 210px minmax(0, 1fr); }
  .portal-topbar { grid-template-columns: 210px 1fr auto; }
  .portal-brand { padding-inline: 14px; }
  .workspace-main { padding-inline: 24px; }
  .metric-cards { grid-template-columns: repeat(2, 1fr); }
  .adoption-metrics { grid-template-columns: repeat(3, 1fr); }
  .methodology-strip { grid-template-columns: 1fr 1fr; }
  .methodology-strip > div:nth-child(2) { border-right: 0; }
  .methodology-strip > div:nth-child(-n+2) { border-bottom: 1px solid #2a4656; }
  .dataset-catalog { grid-template-columns: 1fr; }
  .api-layout { grid-template-columns: 1fr; }
  .access-admin-layout { grid-template-columns: 1fr; }
  .invite-panel { position: static; }
}

@media (max-width: 860px) {
  .shell { width: min(100% - 30px, 1210px); }
  .header-nav > a:not(.button) { display: none; }
  .hero { min-height: 0; gap: 48px; }
  .hero h1 { font-size: clamp(43px, 11vw, 65px); }
  .ticker-track { justify-content: flex-start; overflow-x: auto; }
  .split-heading, .governance-grid, .access-grid { grid-template-columns: 1fr; gap: 30px; }
  .feature-card-wide { grid-template-columns: 35px 1fr; }
  .dictionary-sample { grid-column: 2; }
  .workflow-steps { grid-template-columns: repeat(2, 1fr); }
  .workflow-steps li:nth-child(2) { border-right: 0; }
  .workflow-steps li:nth-child(-n+2) { border-bottom: 1px solid #2b4657; }
  .access-grid { gap: 50px; }
  .login-card { max-width: 520px; }
  .site-footer { grid-template-columns: 1fr auto; }
  .site-footer > p { display: none; }

  .portal-shell { display: block; }
  .portal-topbar { grid-template-columns: 1fr auto; }
  .portal-brand { border: 0; }
  .warehouse-state { display: none; }
  .mobile-menu-button { display: grid; }
  .account-button { min-width: 0; border-left: 0; }
  .account-copy { display: none; }
  .portal-sidebar { position: fixed; inset: 64px auto 0 0; width: 236px; height: auto; transform: translateX(-102%); box-shadow: 18px 0 45px rgba(7, 26, 42, .24); transition: transform .2s ease; }
  .portal-sidebar.open { transform: translateX(0); }
  .workspace-main { padding: 27px 18px 60px; }
  .overview-grid { grid-template-columns: 1fr; }
  .adoption-grid { grid-template-columns: 1fr; }
  .adoption-series-panel, .cohort-panel, .metric-definitions { grid-column: auto; }
  .metric-definitions dl { grid-template-columns: 1fr; }
  .overview-catalog-panel { grid-row: auto; }
  .query-layout { grid-template-columns: 1fr; }
  .query-browser { position: static; }
  .schema-tree { max-height: 260px; }
  .export-principles, .entitlement-grid { grid-template-columns: 1fr; }
  .dictionary-toolbar { flex-wrap: wrap; }
}

@media (max-width: 600px) {
  .site-header { height: 70px; }
  .header-nav .button { min-height: 38px; padding-inline: 12px; }
  .hero { padding-block: 52px 60px; }
  .hero-lede { font-size: 16px; }
  .hero-actions { align-items: flex-start; flex-direction: column; }
  .hero-facts { grid-template-columns: 1fr; gap: 14px; }
  .hero-facts dd { white-space: normal; }
  .research-window { border-radius: 12px; }
  .window-grid { grid-template-columns: 42px 1fr; }
  .mini-sidebar { gap: 15px; }
  .mini-content { padding: 18px 14px; }
  .metric-row { grid-template-columns: 1fr; }
  .metric-row > div:nth-child(n+2) { display: none; }
  .mini-table { grid-template-columns: 1fr .65fr; }
  .mini-table > :nth-child(3n) { display: none; }
  .section { padding-block: 78px; }
  .section-heading h2, .governance-grid h2, .access-copy h2 { font-size: 36px; }
  .feature-grid { grid-template-columns: 1fr; }
  .feature-card-wide { grid-column: auto; grid-template-columns: 1fr; }
  .feature-card-wide .feature-index { display: none; }
  .dictionary-sample { grid-column: auto; }
  .feature-card { min-height: 0; padding: 25px; }
  .workflow-steps { grid-template-columns: 1fr; }
  .workflow-steps li { min-height: 140px; border-right: 0; border-bottom: 1px solid #2b4657; }
  .workflow-steps li:nth-child(3) { border-bottom: 1px solid #2b4657; }
  .access-section { padding-block: 75px; }
  .login-card { padding: 23px; }

  .account-popover { right: -5px; width: 240px; }
  .workspace-heading { align-items: flex-start; flex-direction: column; }
  .workspace-heading > .button, .workspace-heading .heading-actions { width: 100%; }
  .workspace-heading .heading-actions { align-items: stretch; flex-direction: column; }
  .workspace-heading .heading-actions .button { width: 100%; }
  .metric-cards, .dictionary-stats { grid-template-columns: 1fr 1fr; }
  .adoption-metrics { grid-template-columns: 1fr 1fr; }
  .funnel-row { grid-template-columns: 100px minmax(70px, 1fr) 48px; gap: 7px; }
  .dictionary-stats div:nth-child(2) { border-right: 0; }
  .dictionary-stats div:nth-child(-n+2) { border-bottom: 1px solid #284555; }
  .toolbar { align-items: stretch; flex-direction: column; }
  .search-field, .select-field select { width: 100%; min-width: 0; }
  .catalog-toolbar > .text-button { margin: 0; text-align: left; }
  .catalog-summary-line { align-items: flex-start; flex-direction: column; gap: 5px; }
  .dataset-card-header { grid-template-columns: 24px 1fr; }
  .dataset-expand { grid-column: 2; width: fit-content; }
  .dataset-facts { grid-template-columns: 1fr 1fr; }
  .dataset-facts div:nth-child(2) { border-right: 0; }
  .dataset-facts div:nth-child(-n+2) { border-bottom: 1px solid #e6ecee; }
  .field-row { grid-template-columns: 18px minmax(0, 1fr) auto 20px; }
  .field-quality { display: none; }
  .query-safety { grid-template-columns: 1fr; gap: 5px; }
  .editor-shell { grid-template-columns: 31px minmax(0, 1fr); }
  .query-actions { align-items: stretch; flex-direction: column; }
  .query-actions > div { display: grid; grid-template-columns: 1fr 1fr; }
  .query-examples { overflow-x: auto; white-space: nowrap; }
  .format-grid { grid-template-columns: repeat(2, 1fr); margin-left: 0; }
  .date-grid, .option-stack, .export-selection-list { margin-left: 0; }
  .preview-section > .button, .preview-section > .preview-placeholder { width: 100%; margin-left: 0; }
  .drawer-footer { align-items: stretch; flex-direction: column; }
  .drawer-footer .button { width: 100%; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { scroll-behavior: auto !important; animation-duration: .01ms !important; animation-iteration-count: 1 !important; transition-duration: .01ms !important; }
}
