/* Senerox cockpit · one responsive design system, no external assets. */
:root {
  --ink: #17243a;
  --muted: #617087;
  --green: #5654e8;
  --primary: #5654e8;
  --primary-hover: #4542c9;
  --primary-soft: #efefff;
  --positive: #087f72;
  --positive-soft: #e7f6f0;
  --warning: #95600a;
  --warning-soft: #fff5de;
  --negative: #b43b46;
  --negative-soft: #fff0f1;
  --lime: #dcdcff;
  --bg: #f5f6fa;
  --white: #fff;
  --line: #e3e7ef;
  --radius: 18px;
  --sidebar-width: 232px;
  --shadow: none;
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', ui-sans-serif, sans-serif;
  font-size: 15px;
  line-height: 1.6;
  font-synthesis: none;
  color: var(--ink);
  color-scheme: light;
  -webkit-font-smoothing: antialiased;
}
*, *::before, *::after { box-sizing: border-box; }
html { scroll-padding-top: 100px; }
body { margin: 0; background: var(--bg); }
button, input, select, textarea { font: inherit; }
button, a, input, select, textarea { -webkit-tap-highlight-color: transparent; outline-offset: 4px; }
button { color: inherit; cursor: pointer; transition: background .16s, border-color .16s; }
button:disabled { opacity: .48; cursor: not-allowed; }
a { color: inherit; text-decoration: none; }
svg { display: inline-block; vertical-align: middle; flex-shrink: 0; }
img { max-width: 100%; }
h1, h2, h3, p { margin-top: 0; }
h1 { font-size: clamp(28px, 2.6vw, 40px); line-height: 1.17; letter-spacing: -1.2px; font-weight: 720; margin-bottom: 12px; }
h2 { font-size: 21px; line-height: 1.35; letter-spacing: -.5px; font-weight: 680; }
h3 { font-size: 16px; line-height: 1.45; letter-spacing: -.2px; font-weight: 650; margin-bottom: 10px; }
p { margin-bottom: 16px; }
:focus-visible { outline: 3px solid #7b78f4; outline-offset: 3px; }
::selection { background: #dcdcff; color: #27216f; }
input, textarea, select { accent-color: var(--primary); }
button, .btn, .nav-item, .icon-btn, .tab, .row-link { touch-action: manipulation; }
.muted { color: var(--muted); }
.small { font-size: 13px; }
.tiny { font-size: 12px; }
.eyebrow { color: var(--primary); font-size: 10px; font-weight: 750; letter-spacing: 1.7px; text-transform: uppercase; }
.flex { display: flex; align-items: center; gap: 12px; }
.between { justify-content: space-between; }
.wrap { flex-wrap: wrap; }
.gap { gap: 24px; }
.stack { display: grid; gap: 22px; }
.mt { margin-top: 24px; }
.mb { margin-bottom: 24px; }
.padded { padding: 24px; }
.full { width: 100%; }
.truncate { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.money, .amount-main, .stat-number { font-variant-numeric: tabular-nums; }
.danger-text { color: var(--negative) !important; }
.required { color: var(--negative); }
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0,0,0,0); white-space: nowrap; border: 0; }

/* Buttons and small status indicators. */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 9px; min-height: 44px; padding: 11px 17px; border: 1px solid #d9dfeb; border-radius: 11px; background: #fff; color: #34445e; font-size: 13px; font-weight: 650; line-height: 1.4; text-align: center; white-space: nowrap; box-shadow: none; }
.btn:hover { background: #f7f7ff; border-color: #b6b5ed; }
.btn.primary { background: var(--primary); border-color: var(--primary); color: #fff; box-shadow: none; }
.btn.primary:hover { background: var(--primary-hover); border-color: var(--primary-hover); }
.btn.danger { color: var(--negative); border-color: #efcdd3; background: #fff9fa; }
.btn.ghost { background: transparent; border-color: transparent; box-shadow: none; }
.btn.ghost:hover { background: var(--primary-soft); color: var(--primary); }
.btn.sm { padding: 9px 12px; min-height: 40px; font-size: 12px; }
.icon-btn { display: inline-grid; place-items: center; width: 40px; height: 40px; flex-shrink: 0; background: #fff; border: 1px solid #dce2ed; border-radius: 11px; color: #53647d; }
.icon-btn:hover { color: var(--primary); background: var(--primary-soft); border-color: #c6c4fb; }
.pill, .stage, .scenario-kind, .tag { display: inline-flex; align-items: center; gap: 6px; max-width: 100%; padding: 5px 9px; border-radius: 7px; font-size: 11px; font-weight: 650; line-height: 1.5; white-space: nowrap; }
.pill { color: var(--positive); background: var(--positive-soft); }
.pill::before { content: ''; width: 5px; height: 5px; border-radius: 50%; background: currentColor; flex-shrink: 0; }
.pill.amber { color: var(--warning); background: var(--warning-soft); }
.pill.red { color: var(--negative); background: var(--negative-soft); }
.pill.blue { color: #365eab; background: #edf3ff; }
.pill.gray { color: #5b6c81; background: #eff2f7; }
.tag { padding: 4px 8px; margin: 2px; background: #f3f5f9; color: #5b6b82; border: 1px solid #e5e9f1; font-weight: 500; }
.stage { background: var(--primary-soft); color: #5e4cad; }
.evidence { background: var(--positive-soft); color: var(--positive); border-color: #cbe8dd; }
.scenario-kind { background: var(--primary-soft); color: var(--primary); }
.scenario-kind.optimistic { background: var(--positive-soft); color: var(--positive); }
.scenario-kind.pessimistic { background: var(--warning-soft); color: var(--warning); }

/* Persistent navigation. The same drawer is used on mobile. */
.brand-name { display: grid; gap: 3px; line-height: 1; }
.brand-name strong { font-size: 24px; letter-spacing: -.9px; font-weight: 760; }
.brand-name small { font-size: 7px; letter-spacing: 1.65px; font-weight: 600; color: #a6b3cf; }
.sidebar .workspace > span:last-child { min-width: 0; }
.sidebar .workspace .tiny { display: block; margin-top: 3px; }
.sidebar-session { display: flex; align-items: center; gap: 8px; margin: 0 0 16px 5px; color: var(--muted); font-size: 10px; }
.sidebar-user { min-width: 0; flex: 1; }
.sidebar-user .user-name { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.topbar-location { display: flex; align-items: center; gap: 12px; min-width: 0; }

.shell { display: flex; min-height: 100dvh; }
.sidebar { position: fixed; inset: 0 auto 0 0; z-index: 40; display: flex; flex-direction: column; width: var(--sidebar-width); background: #fff; color: var(--ink); padding: 28px 16px 18px; border-right: 1px solid var(--line); }
.brand-row { display: flex; align-items: center; justify-content: space-between; margin: 0 10px 28px; gap: 12px; }
.brand { display: flex; align-items: center; gap: 11px; font-size: 26px; font-weight: 760; letter-spacing: -1.1px; }
.sidebar .brand { color: var(--ink); }
.sidebar .brand-name small, .sidebar .brand-label { color: var(--muted); }
.brand-symbol { display: inline-grid; place-items: center; width: 37px; height: 39px; flex-shrink: 0; background: var(--primary); color: #fff; border-radius: 12px 12px 12px 4px; font-size: 28px; font-style: normal; font-weight: 750; line-height: 1; letter-spacing: -1px; box-shadow: none; }
.brand-label { display: inline-block; margin-top: 8px; color: #a6b3cf; font-size: 8px; letter-spacing: 1.6px; font-weight: 600; }
.workspace { display: flex; align-items: center; gap: 10px; padding: 13px; margin: 0 4px 10px; background: #f7f8fc; border: 1px solid var(--line); border-radius: 13px; font-size: 12px; color: #34445e; }
.workspace .square { width: 35px; height: 35px; border-radius: 10px; display: grid; place-items: center; background: var(--primary-soft); color: var(--primary); flex-shrink: 0; }
.workspace .tiny { color: var(--muted); font-size: 11px; }
.sidebar nav { flex: 1; min-height: 0; overflow-y: auto; scrollbar-width: thin; scrollbar-color: #c7cfdf transparent; }
.nav-group { margin-top: 13px; }
.nav-group > summary.nav-label { display: flex; align-items: center; justify-content: space-between; min-height: 44px; margin: 0; padding: 10px 12px; color: var(--muted); cursor: pointer; list-style: none; border-radius: 9px; }
.nav-group > summary.nav-label::-webkit-details-marker { display: none; }
.nav-group > summary.nav-label:hover { color: var(--ink); background: #f5f6fa; }
.nav-group > summary.nav-label svg { transition: transform .16s; }
.nav-group[open] > summary.nav-label svg { transform: rotate(90deg); }
.sidebar .nav-label, .nav-group-title { color: var(--muted); font-size: 9px; font-weight: 700; letter-spacing: 1.55px; margin: 0 12px 9px; }
.nav-item { display: flex; align-items: center; gap: 12px; width: 100%; min-height: 44px; padding: 11px 13px; margin: 3px 0; color: #455672; background: transparent; border: 1px solid transparent; border-radius: 10px; text-align: left; font-size: 12px; line-height: 1.4; }
.nav-item svg { width: 17px; height: 17px; opacity: .85; }
.nav-item:hover { background: #f4f3ff; color: var(--primary-hover); }
.nav-item.active { color: var(--primary-hover); background: var(--primary-soft); border-color: #d8d6fb; box-shadow: none; font-weight: 650; }
.nav-item.active svg { opacity: 1; }
.nav-count { margin-left: auto; padding: 1px 6px; border-radius: 5px; color: var(--muted); background: #eef1f6; font-size: 10px; }
.nav-item.active .nav-count { color: var(--primary-hover); background: #deddfa; }
.sidebar-foot { margin-top: 18px; padding: 18px 6px 0; border-top: 1px solid var(--line); }
.avatar { display: inline-grid; place-items: center; width: 37px; height: 37px; flex-shrink: 0; border-radius: 50%; background: #e8e9fd; color: #5750b0; font-size: 12px; font-weight: 750; }
.sidebar-foot .avatar { color: #5750b0; background: #e8e9fd; }
.sidebar-foot .icon-btn { background: transparent; border-color: var(--line); color: var(--muted); }
.sidebar-foot .icon-btn:hover { background: var(--primary-soft); color: var(--primary); }
.user-name { color: var(--ink); font-size: 11px; font-weight: 600; }
.user-role { color: var(--muted); font-size: 10px; }
.sidebar-close, .sidebar-overlay, .menu-backdrop, .mobile-nav, .bottom-nav, .mobile-page-title, .topbar .mobile-toggle { display: none; }
.main { width: calc(100% - var(--sidebar-width)); min-width: 0; margin-left: var(--sidebar-width); }
.topbar { position: sticky; top: 0; z-index: 25; display: flex; align-items: center; justify-content: space-between; gap: 20px; min-height: 68px; padding: 12px 30px; border-bottom: 1px solid var(--line); background: #fff; }
.crumb { display: flex; gap: 12px; align-items: center; color: #8290a5; font-size: 12px; }
.crumb strong { color: #3a4a65; font-size: 13px; font-weight: 600; }
.top-actions { display: flex; gap: 16px; align-items: center; }
.command-trigger, .global-search { display: flex; align-items: center; gap: 9px; min-height: 42px; width: 242px; padding: 9px 12px; background: #f7f8fc; border: 1px solid #e3e7f0; border-radius: 10px; color: #748198; text-align: left; font-size: 12px; }
.command-trigger:hover { border-color: #c9c6f8; background: #f2f1ff; }
.command-trigger > span { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.command-trigger kbd { flex-shrink: 0; white-space: nowrap; }
.command-trigger kbd, .key { font: inherit; font-size: 10px; color: #7a85a1; border: 1px solid #e0e4ef; border-radius: 5px; padding: 1px 5px; background: #fff; margin-left: auto; }
.global-search input { background: transparent; border: 0; outline: none; min-width: 0; width: 100%; padding: 0; }
.live { display: flex; align-items: center; gap: 7px; color: #6c7a91; font-size: 11px; white-space: nowrap; }
.dot { width: 6px; height: 6px; border-radius: 50%; background: var(--positive); box-shadow: none; }
.chat-shortcut { font-size: 12px; min-height: 42px; }
.skip-link { position: fixed; top: -90px; left: 16px; z-index: 200; background: var(--primary); color: #fff; border-radius: 10px; padding: 12px 18px; font-weight: 650; }
.skip-link:focus { top: 12px; }
.content { width: 100%; max-width: 1580px; min-width: 0; padding: 26px 30px 36px; margin: 0 auto; }
.page-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 20px; margin-bottom: 22px; }
.page-head h1 { font-size: clamp(26px, 2.2vw, 33px); margin-bottom: 7px; overflow-wrap: anywhere; }
.page-head > div { min-width: 0; max-width: 100%; }
.page-head p { color: var(--muted); font-size: 14px; margin: 0; max-width: 740px; line-height: 1.7; }
.page-head > .flex { align-self: center; flex-shrink: 0; }
.date-label { display: flex; align-items: center; gap: 8px; font-size: 12px; color: var(--muted); }
.footer { display: flex; justify-content: space-between; gap: 20px; color: #77849a; font-size: 10px; letter-spacing: .25px; border-top: 1px solid var(--line); margin-top: 34px; padding-top: 23px; }

/* Surface and table primitives. */
.panel { min-width: 0; max-width: 100%; background: #fff; border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; box-shadow: none; }
.panel-head { display: flex; align-items: center; justify-content: space-between; gap: 16px; border-bottom: 1px solid #edf0f5; padding: 17px 20px; }
.panel-head h2 { margin: 0; color: #243550; font-size: 16px; letter-spacing: -.25px; }
.panel-head p { margin: 6px 0 0; color: var(--muted); font-size: 12px; }
.panel-body { padding: 20px; min-width: 0; }
.grid2, .grid-equal { display: grid; gap: 24px; margin-bottom: 24px; align-items: start; }
.grid2 { grid-template-columns: minmax(0,1.55fr) minmax(0,1fr); }
.grid-equal { grid-template-columns: repeat(2,minmax(0,1fr)); }
.grid2 > *, .grid-equal > *, .simulation-layout > *, .scenario-inputs > *, .field-layout > *, .ai-settings-grid > *, .ai-watch-layout > *, #simulation-results, #simulation-results > * { min-width: 0; max-width: 100%; }
.toolbar { display: flex; align-items: center; justify-content: space-between; gap: 16px; padding: 14px 18px; border-bottom: 1px solid var(--line); flex-wrap: wrap; }
.toolbar > .flex { min-width: 0; flex-wrap: wrap; }
.search-box { display: flex; align-items: center; gap: 9px; min-height: 44px; padding: 10px 12px; border: 1px solid #dfe4ef; border-radius: 10px; background: #fafbfe; color: #7c88a0; }
.search-box input { width: 205px; max-width: 100%; min-width: 0; background: transparent; border: 0; padding: 0; outline: none; color: var(--ink); font-size: 13px; }
.search-box input::placeholder, input::placeholder, textarea::placeholder { color: #8792a7; opacity: 1; }
.toolbar select, .model-scope select, .comparison-toolbar select { max-width: 100%; min-height: 44px; padding: 10px 32px 10px 13px; border: 1px solid #dce2ed; border-radius: 10px; color: #455672; background: #fff; font-size: 13px; }
.model-scope select { min-width: 200px; }
.table-wrap { width: 100%; max-width: 100%; min-width: 0; overflow: auto; overscroll-behavior-inline: contain; scrollbar-width: thin; scrollbar-color: #c7cfdf transparent; }
table { width: 100%; border-collapse: collapse; white-space: nowrap; text-align: left; }
th { padding: 12px 18px; background: #f8f9fc; color: #66748e; font-size: 10px; text-transform: uppercase; letter-spacing: .85px; font-weight: 750; border-bottom: 1px solid #e9edf5; }
td { color: #4a5c75; padding: 14px 18px; font-size: 13px; line-height: 1.6; border-bottom: 1px solid #edf0f6; }
td strong { font-weight: 650; }
td .sub { color: #73829a; font-size: 11px; margin-top: 5px; }
tbody tr:last-child td { border-bottom: 0; }
tbody tr:hover { background: #fafaff; }
.row-link { display: inline; min-height: 32px; border: 0; background: none; padding: 0; color: #3f429f; text-align: left; font: inherit; font-weight: 650; }
.row-link:hover { color: var(--primary); text-decoration: underline; text-underline-offset: 4px; }
.table-footer { display: flex; justify-content: space-between; align-items: center; gap: 16px; padding: 15px 21px; border-top: 1px solid var(--line); background: #fcfcfe; color: var(--muted); font-size: 12px; }
.table-footer .icon-btn { width: 36px; height: 36px; }
.cards { display: grid; grid-template-columns: repeat(3,minmax(0,1fr)); gap: 22px; }
.record-card { min-width: 0; display: flex; flex-direction: column; padding: 25px; border: 1px solid var(--line); border-radius: var(--radius); background: #fff; transition: border-color .16s; }
.record-card:hover { border-color: #c1c0ef; box-shadow: none; }
.card-top { display: flex; align-items: center; justify-content: space-between; gap: 15px; margin-bottom: 20px; }
.brand-logo { display: inline-grid; place-items: center; width: 48px; height: 48px; flex-shrink: 0; overflow: hidden; background: #edeffd; border: 1px solid #e0e3f5; border-radius: 14px; color: #6559a8; font-size: 17px; font-weight: 700; }
.brand-logo img { width: 100%; height: 100%; object-fit: contain; background: #fff; }
.brand-logo.large { width: 72px; height: 72px; font-size: 27px; border-radius: 19px; }
/* Horizontal company wordmarks keep their proportions; conversation avatars stay compact. */
.record-card:has(> h2 > [data-nav="providers"]) > .card-top > .brand-logo:has(> img),
.company-progress-card > .flex > .brand-logo:has(> img),
.detail-hero > .brand-logo:has(> img) { width: 180px; height: 64px; max-width: 100%; min-width: 0; flex: 0 1 180px; padding: 8px 10px; border-radius: 10px; border-color: var(--line); background: #fff; }
.record-card:has(> h2 > [data-nav="providers"]):has(> .card-top > .brand-logo > img) > .card-top,
.company-progress-card:has(> .flex > .brand-logo > img) > .flex:first-child { flex-wrap: wrap; gap: 12px; }
.record-card h2 { font-size: 21px; margin-bottom: 8px; }
.record-card p { color: var(--muted); font-size: 13px; line-height: 1.8; }
.card-meta { display: flex; gap: 15px; align-items: center; flex-wrap: wrap; color: var(--muted); font-size: 12px; margin: 12px 0 20px; }
.card-bottom { display: flex; align-items: center; justify-content: space-between; gap: 12px; flex-wrap: wrap; margin-top: auto; padding-top: 18px; border-top: 1px solid var(--line); }
.empty { max-width: 560px; padding: 50px 26px; text-align: center; margin: auto; }
.empty-icon { display: inline-grid; place-items: center; width: 62px; height: 62px; margin-bottom: 18px; border-radius: 19px; background: var(--primary-soft); border: 1px solid #e2dffb; color: #7973bc; }
.empty h3 { font-size: 20px; margin-bottom: 9px; }
.empty p { font-size: 14px; color: var(--muted); line-height: 1.8; max-width: 380px; margin: 0 auto 22px; }
.notice { display: flex; align-items: flex-start; gap: 11px; border: 1px solid #d8d7fb; background: #f3f2ff; color: #565583; border-radius: 12px; padding: 16px 18px; font-size: 13px; line-height: 1.75; margin-bottom: 22px; }
.notice > svg { margin-top: 3px; }
.notice.amber { background: var(--warning-soft); border-color: #ecddba; color: #805c1a; }
.info-list { display: grid; grid-template-columns: repeat(2,minmax(0,1fr)); gap: 23px; margin: 0; }
.info-list dt { color: var(--muted); font-size: 12px; margin-bottom: 6px; }
.info-list dd { color: #293f5d; margin: 0; font-size: 14px; line-height: 1.7; overflow-wrap: anywhere; white-space: pre-wrap; }
.list-item { display: flex; align-items: center; gap: 15px; padding: 18px 0; border-bottom: 1px solid var(--line); min-width: 0; }
.list-item:last-child { border-bottom: 0; }
.list-item > div { min-width: 0; }
.list-item h3 { font-size: 14px; margin: 0 0 4px; }
.list-item p { font-size: 12px; color: var(--muted); margin: 0; }
.region-icon { display: inline-grid; place-items: center; width: 43px; height: 43px; flex-shrink: 0; background: #f0effb; border-radius: 12px; color: #6961b9; }
.activity { display: flex; gap: 13px; margin-bottom: 20px; }
.activity:last-child { margin: 0; }
.activity-dot { width: 8px; height: 8px; flex-shrink: 0; background: #9d9bdb; border: 2px solid #efeffd; border-radius: 50%; margin-top: 6px; }
.activity p { font-size: 13px; margin-bottom: 3px; }
.activity time { color: var(--muted); font-size: 11px; }
.upcoming { padding: 15px 0; border-bottom: 1px solid var(--line); }
.upcoming h3 { font-size: 13px; margin-bottom: 5px; }
.upcoming p { color: var(--muted); font-size: 12px; margin: 0; }

/* Dashboard: data, next steps, and useful shortcuts. */
.workspace-welcome, .hero { position: relative; display: grid; grid-template-columns: minmax(0,1.5fr) minmax(230px,.9fr); gap: 24px; background: #ebeafc; border: 1px solid #dcdbf3; border-radius: 22px; overflow: hidden; margin-bottom: 26px; }
.workspace-welcome { padding: 35px 38px; min-height: 265px; }
.workspace-welcome h2, .hero h2 { font-size: clamp(29px,2.8vw,42px); line-height: 1.16; letter-spacing: -1.3px; font-weight: 700; margin: 15px 0 17px; color: #2c2b58; }
.workspace-welcome h2 span { color: #6b65a2; }
.workspace-welcome p, .hero p { color: #626385; font-size: 14px; line-height: 1.85; max-width: 560px; margin-bottom: 23px; }
.workspace-welcome .eyebrow { color: #655daa; }
.workspace-welcome .btn:not(.primary) { background: #ffffffa8; border-color: #d2cfed; }
.hero-copy { padding: 35px 38px; }
.map { display: grid; place-items: center; position: relative; overflow: hidden; }
.map svg { width: 100%; color: #9490ca; }
.map-tag { position: absolute; right: 20px; bottom: 20px; padding: 9px 12px; background: #ffffffc9; border: 1px solid #d8d4f2; border-radius: 10px; color: #686087; font-size: 11px; }
.welcome-orbit { position: relative; display: grid; place-items: center; min-height: 210px; max-width: 310px; width: 100%; margin: auto; }
.orbit-line { position: absolute; width: 210px; height: 210px; border: 1px solid #bab7e370; border-radius: 50%; }
.orbit-line::before { content: ''; position: absolute; inset: 30px; border: 1px dashed #c0bce6; border-radius: inherit; }
.orbit-center { display: grid; place-items: center; width: 83px; height: 85px; background: var(--primary); border-radius: 23px 23px 23px 8px; color: #fff; font-size: 64px; font-style: normal; font-weight: 750; box-shadow: none; }
.orbit-label { position: absolute; display: flex; align-items: center; gap: 9px; padding: 11px 15px; border: 1px solid #dcd8f1; border-radius: 12px; background: #ffffffed; box-shadow: none; color: #666186; font-size: 12px; white-space: nowrap; }
.orbit-idea { top: 8px; left: 0; }
.orbit-model { top: 85px; right: -8px; }
.orbit-action { bottom: 0; left: 20px; }
.stats { display: grid; grid-template-columns: repeat(4,minmax(0,1fr)); gap: 18px; margin-bottom: 25px; }
.stat { min-width: 0; padding: 22px; border: 1px solid var(--line); border-radius: 16px; background: #fff; box-shadow: none; }
.stat-label { display: flex; align-items: center; justify-content: space-between; gap: 9px; color: #65748d; font-size: 12px; line-height: 1.6; }
.stat-icon { display: inline-grid; place-items: center; padding: 7px; background: #f3f2fd; color: #8077c2; border: 1px solid #e9e6f9; border-radius: 9px; }
.stat-number { font-size: clamp(28px,2.5vw,37px); font-weight: 720; letter-spacing: -1.3px; line-height: 1.25; margin: 14px 0 8px; color: #243550; overflow-wrap: normal; }
.stat-foot { color: #738198; font-size: 11px; line-height: 1.7; }
.dashboard-section { margin-top: 24px; }
.section-heading { display: flex; justify-content: space-between; align-items: center; gap: 16px; margin-bottom: 14px; }
.section-heading h2 { font-size: 21px; margin: 4px 0 0; }
.section-heading .eyebrow { font-size: 9px; color: #8185a5; }
.company-progress-grid, .dashboard-scenarios { display: grid; grid-template-columns: repeat(3,minmax(0,1fr)); gap: 19px; }
.company-progress-grid { grid-template-columns: repeat(auto-fit,minmax(min(100%,290px),1fr)); }
.company-progress-card, .dashboard-scenario { min-width: 0; background: #fff; border: 1px solid var(--line); border-radius: 16px; padding: 20px; display: flex; flex-direction: column; }
.company-progress-card h3, .dashboard-scenario h3 { font-size: 19px; letter-spacing: -.5px; margin: 14px 0 6px; }
.company-progress-card h3 .row-link, .dashboard-scenario h3 .row-link { color: #253954; }
.company-progress-card > p { color: var(--muted); font-size: 13px; line-height: 1.8; margin-bottom: 14px; min-height: 0; overflow-wrap: anywhere; }
.company-progress-card > .small { margin-top: auto; color: var(--muted); font-size: 11px; }
.company-progress-card > .small strong { color: var(--primary); }
.company-progress-card progress { appearance: none; display: block; width: 100%; height: 6px; border: 0; border-radius: 8px; background: #eeeef8; overflow: hidden; margin: 9px 0 10px; }
.company-progress-card progress::-webkit-progress-bar { background: #eeeef8; border-radius: 8px; }
.company-progress-card progress::-webkit-progress-value { background: var(--primary); border-radius: 8px; }
.company-progress-card progress::-moz-progress-bar { background: var(--primary); border-radius: 8px; }
.company-next { display: flex; align-items: center; justify-content: space-between; gap: 13px; padding-top: 17px; border-top: 1px solid var(--line); }
.company-next > span { color: var(--muted); font-size: 11px; line-height: 1.7; }
.company-next > span svg { color: var(--primary); margin-right: 3px; }
.company-next .btn { color: var(--primary); background: #f8f7ff; border-color: #e0def8; }
.dashboard-scenario > .small { font-size: 12px; color: var(--muted); margin-bottom: 22px; }
.dashboard-scenario > .flex > .small { font-size: 11px; color: var(--muted); }
.scenario-figures { display: grid; grid-template-columns: repeat(2,minmax(0,1fr)); gap: 14px; margin: 1px 0 16px; }
.scenario-figures > div > span { display: block; color: var(--muted); font-size: 11px; line-height: 1.6; margin-bottom: 7px; }
.scenario-figures strong { display: block; color: #2b405e; font-size: clamp(17px,1.5vw,23px); font-weight: 700; line-height: 1.4; letter-spacing: -.6px; font-variant-numeric: tabular-nums; overflow-wrap: normal; }
.scenario-status { margin-top: auto; padding-top: 15px; border-top: 1px solid var(--line); }
.scenario-status .pill { white-space: normal; font-size: 10px; }
.dashboard-scenario > .btn.ghost { margin-top: 9px; padding: 14px 0 0; color: var(--primary); justify-content: space-between; font-size: 12px; }
.radar-item { display: flex; align-items: center; gap: 14px; width: 100%; padding: 17px 0; border: 0; border-bottom: 1px solid var(--line); background: transparent; text-align: left; }
.radar-item:first-child { padding-top: 0; }
.radar-item:last-child { border-bottom: 0; padding-bottom: 0; }
.radar-item > span:nth-child(2) { flex: 1; min-width: 0; }
.radar-item strong { display: block; color: #344760; font-size: 13px; }
.radar-item small { display: block; margin-top: 5px; color: var(--muted); font-size: 12px; line-height: 1.7; }
.radar-item:hover strong { color: var(--primary); }
.radar-item > svg:last-child { color: #8d96ad; }
.decision-links { display: grid; gap: 14px; }
.decision-links > button { display: flex; align-items: center; gap: 14px; width: 100%; padding: 17px; border: 1px solid #e7e9f4; background: #fafaff; border-radius: 12px; text-align: left; }
.decision-links > button:hover { background: #f1f0ff; border-color: #cbc8f5; }
.decision-links > button > span:nth-child(2) { min-width: 0; flex: 1; }
.decision-links strong { display: block; font-size: 13px; color: #34445f; }
.decision-links small { display: block; margin-top: 4px; font-size: 12px; line-height: 1.7; color: var(--muted); }
.decision-links > button > svg:last-child { color: #a09bbc; }
.onboarding { display: grid; grid-template-columns: repeat(3,minmax(0,1fr)); gap: 14px; }
.step-card { display: block; text-align: left; padding: 20px; background: #fafaff; border: 1px solid #e7e4f6; border-radius: 13px; }
.step-card:hover { background: #f1f0ff; border-color: #c6c2f1; }
.step-card.done { background: #edf8f3; border-color: #cfe9dc; }
.step-number { display: grid; place-items: center; width: 30px; height: 30px; border-radius: 9px; background: #eae8fc; color: var(--primary); font-size: 11px; font-weight: 700; margin-bottom: 15px; }
.step-card h3 { font-size: 14px; margin-bottom: 8px; }
.step-card p { font-size: 12px; color: var(--muted); line-height: 1.75; margin: 0; }

/* Detail pages, simulations, charts and saved calculations. */
/* Decision-first dashboard: concise priority and reference brief. */
.cockpit-overview { display: grid; grid-template-columns: minmax(0,1fr) 230px; gap: 16px; margin-bottom: 16px; }
.cockpit-priority { display: flex; align-items: center; flex-wrap: wrap; gap: 14px; padding: 19px 21px; background: #fff; border: 1px solid #dcdcf0; border-left: 4px solid var(--primary); border-radius: 15px; }
.priority-icon { display: grid; place-items: center; width: 42px; height: 42px; flex-shrink: 0; color: var(--primary); background: var(--primary-soft); border-radius: 12px; }
.cockpit-priority-copy { min-width: 0; flex: 1; }
.cockpit-priority-copy .eyebrow { font-size: 9px; color: #746a9c; }
.cockpit-priority-copy h2 { color: #283a55; font-size: 18px; letter-spacing: -.35px; margin: 4px 0; }
.cockpit-priority-copy p { margin: 0; color: var(--muted); font-size: 12px; line-height: 1.65; }
.cockpit-priority > .btn { margin-left: 56px; }
.cockpit-brief { display: grid; grid-template-columns: 1fr 1fr; align-content: center; gap: 10px 16px; padding: 18px; border: 1px solid var(--line); border-radius: 15px; background: #fff; }
.cockpit-brief > div { min-width: 0; }
.cockpit-brief strong { display: block; color: #263954; font-size: 27px; line-height: 1.2; letter-spacing: -.8px; font-variant-numeric: tabular-nums; }
.cockpit-brief strong small { font-size: 15px; color: #6e65ad; margin-left: 2px; }
.cockpit-brief span { display: block; color: var(--muted); font-size: 10px; margin-top: 5px; }
.cockpit-brief > p { grid-column: 1/-1; color: var(--muted); font-size: 10px; line-height: 1.55; margin: 0; }
.workspace-stats { gap: 0; border: 1px solid var(--line); border-radius: 14px; background: #fff; overflow: hidden; margin-bottom: 20px; }
.workspace-stats .stat { border: 0; border-right: 1px solid var(--line); border-radius: 0; padding: 13px 18px; box-shadow: none; }
.workspace-stats .stat:last-child { border-right: 0; }
.workspace-stats .stat-icon { display: none; }
.workspace-stats .stat-number { font-size: 27px; margin: 4px 0 1px; }
.workspace-stats .stat-label { font-size: 11px; }
.workspace-stats .stat-foot { font-size: 10px; }
.section-actions { display: flex; align-items: center; flex-wrap: wrap; gap: 8px; }
.company-checks { margin: 0 0 12px; color: var(--muted); }
.company-checks > summary { min-height: 36px; padding: 8px 0; cursor: pointer; color: #4b5777; font-size: 11px; font-weight: 600; }
.company-checks[open] > summary { color: var(--primary); }
.company-checks .company-checklist { margin: 8px 0 4px; }
.dashboard-support { display: grid; grid-template-columns: repeat(2,minmax(0,1fr)); gap: 18px; }
.dashboard-support > * { min-width: 0; }
.dashboard-support .decision-links { gap: 9px; }
.dashboard-support .decision-links > button { padding: 12px; }
.dashboard-clear { display: flex; align-items: center; gap: 13px; padding: 4px 0; }
.dashboard-clear strong { display: block; font-size: 13px; color: #344760; }
.dashboard-clear p { margin: 6px 0 0; color: var(--muted); font-size: 12px; line-height: 1.7; }
.company-progress-meta { display: flex; align-items: center; justify-content: space-between; margin-top: auto; color: var(--muted); font-size: 11px; gap: 10px; }
.company-progress-meta strong { color: var(--primary); font-weight: 700; }
.company-checklist { display: grid; gap: 7px; list-style: none; padding: 0; margin: 0 0 22px; }
.company-checklist li { display: flex; align-items: center; gap: 9px; color: #7b879d; font-size: 11px; line-height: 1.6; }
.company-checklist li svg { color: #9dabc1; }
.company-checklist li.complete { color: #4b6c65; }
.company-checklist li.complete svg { color: var(--positive); }
.scenario-card-title { margin: 15px 0 17px; }
.scenario-card-title h3 { margin: 0 0 6px; }
.scenario-card-title p { margin: 0; color: var(--muted); font-size: 12px; }
.scenario-horizon { color: var(--muted); font-size: 11px; }
.scenario-mini-chart { padding: 0; margin: 0 0 17px; color: var(--positive); }
.scenario-mini-chart figcaption { display: flex; align-items: center; justify-content: space-between; color: #708199; font-size: 10px; margin-bottom: 8px; }
.scenario-mini-chart svg { display: block; width: 100%; height: 58px; }
.scenario-zero-line { stroke: #dfe7ed; stroke-width: 1; stroke-dasharray: 3 4; }
.scenario-period { display: flex; justify-content: space-between; color: #71829a; font-size: 9px; }
.scenario-card-footer { display: flex; align-items: center; justify-content: space-between; gap: 10px; padding-top: 15px; margin-top: 8px; }
.scenario-card-footer > span { color: #6a7a93; font-size: 10px; }
.scenario-card-footer .btn { color: var(--primary); padding-right: 0; }
.cockpit-workflows { display: grid; grid-template-columns: repeat(3,minmax(0,1fr)); gap: 18px; margin-top: 28px; }
.cockpit-workflows > button { display: flex; align-items: flex-start; gap: 13px; background: #fff; border: 1px solid var(--line); border-radius: 14px; padding: 23px 20px; text-align: left; }
.cockpit-workflows > button:hover { border-color: #c1bef0; background: #fafaff; }
.cockpit-workflows > button > svg:first-child { color: #8075be; margin-top: 3px; }
.cockpit-workflows > button > span { min-width: 0; flex: 1; }
.cockpit-workflows strong { display: block; color: #40516a; font-size: 12px; line-height: 1.6; }
.cockpit-workflows small { display: block; color: #6f7d93; font-size: 11px; line-height: 1.8; margin-top: 7px; }
.cockpit-workflows > button > svg:last-child { color: #8c8aaa; margin-top: 4px; }
.money-value { display: inline-flex; flex-wrap: wrap; align-items: baseline; gap: 0 .25em; max-width: 100%; line-height: 1.35; }
.money-amount { min-width: 0; overflow-wrap: anywhere; }
.money-currency { display: inline-block; white-space: nowrap; font-size: .7em; letter-spacing: 0; color: currentColor; }
.scenario-context { display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: 16px; background: #fff; border: 1px solid var(--line); border-radius: 13px; padding: 17px 20px; margin: 0 0 23px; }
.scenario-context-meta { display: flex; align-items: center; flex-wrap: wrap; gap: 10px 17px; color: #5b6e89; font-size: 12px; min-width: 0; }
.scenario-context-meta > span { display: inline-flex; align-items: center; gap: 7px; }
.scenario-context-meta > .small { flex-basis: 100%; font-size: 11px; }
.scenario-calculation-status { flex-shrink: 0; font-size: 10px; }
.slider-baseline { display: flex; align-items: center; flex-wrap: wrap; gap: 4px 6px; color: #6e7e97; font-size: 10px; line-height: 1.8; margin-top: 8px; }
.slider-baseline > span { color: #929cb0; }
.slider-baseline output { color: #6152a1; font-weight: 700; }
.sensitivity-actions { display: grid; gap: 11px; margin-top: 20px; }
.sensitivity-actions .btn { width: 100%; font-size: 11px; padding-inline: 10px; }
.financial-figure { margin: 0; min-width: 0; }
.chart-summary { display: block; color: #6d7f98; font-size: 11px; line-height: 1.8; margin: 17px 0 0; }
.monthly-table caption { padding: 14px 21px; caption-side: top; text-align: left; color: var(--muted); font-size: 11px; white-space: normal; }
.month-negative { background: #fff6f7; }
.comparison-context { color: #596985; font-size: 13px; margin: 0 0 22px; line-height: 1.8; }

.detail-hero { display: flex; align-items: center; gap: 23px; padding: 30px; background: #fff; border: 1px solid var(--line); border-radius: 19px; margin-bottom: 24px; }
.detail-hero h1 { margin: 0 0 8px; font-size: 30px; }
.detail-hero p { font-size: 13px; color: var(--muted); margin: 0; max-width: 680px; line-height: 1.8; }
.detail-section { margin-top: 24px; }
.tabs { display: flex; gap: 25px; border-bottom: 1px solid #dfe4ee; margin-bottom: 25px; max-width: 100%; min-width: 0; overflow-x: auto; }
.tab { flex-shrink: 0; padding: 13px 1px; min-height: 47px; color: #728098; background: transparent; border: 0; border-bottom: 3px solid transparent; font-size: 13px; line-height: 1.5; white-space: nowrap; }
.tab.active { border-color: var(--primary); color: var(--primary); font-weight: 700; }
.back { display: flex; align-items: center; gap: 7px; margin-bottom: 20px; color: var(--muted); font-size: 12px; }
.amount-main { color: #253b59; font-size: 27px; font-weight: 720; line-height: 1.4; letter-spacing: -.75px; }
.plan-card .plan-code { font-size: 11px; color: var(--muted); margin-bottom: 13px; }
.plan-card .plan-name { font-size: 24px; }
.plan-card .plan-lines { min-height: 70px; margin: 18px 0; }
.plan-line { display: flex; align-items: flex-start; gap: 9px; margin: 12px 0; font-size: 13px; line-height: 1.7; color: #60718b; }
.plan-line svg { color: var(--positive); margin-top: 2px; }
.simulation-layout { display: grid; grid-template-columns: minmax(0,1fr) 300px; align-items: start; gap: 24px; }
.simulation-side { display: grid; align-self: start; gap: 22px; min-width: 0; }
.simulation-side > .mt { margin-top: 0; }
.simulation-side .panel-body { padding: 21px; }
.simulation-layout .panel-head { flex-wrap: wrap; }
.simulation-layout .grid-equal { grid-template-columns: 1fr; }
.sensitivity-grid { display: grid; gap: 24px; }
.slider-control { display: block; }
.slider-control > span { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin-bottom: 12px; font-size: 12px; color: #596c86; }
.slider-control strong { padding: 3px 7px; background: var(--primary-soft); border-radius: 6px; color: var(--primary); font-size: 11px; font-weight: 700; }
.slider-control input { display: block; width: 100%; min-height: 25px; margin: 0; cursor: pointer; accent-color: var(--primary); }
.simulation-stats { grid-template-columns: repeat(2,minmax(0,1fr)); }
.simulation-stats .stat { padding: 20px; }
.simulation-stats .stat-number { font-size: clamp(21px,1.95vw,28px); letter-spacing: -.8px; white-space: normal; overflow-wrap: normal; }
.simulation-stats .stat-label { min-height: 38px; align-items: flex-start; }
.event-line { padding: 18px 0; border-bottom: 1px solid var(--line); }
.event-line:last-child { padding-bottom: 0; border: 0; }
.event-line strong { display: block; font-size: 13px; }
.event-line small { display: block; color: var(--muted); font-size: 11px; line-height: 1.7; margin-top: 5px; }
.event-line .check { flex: 1; gap: 10px; }
.event-line .icon-btn { margin-left: auto; }
.event-line .flex { align-items: flex-start; }
.financial-chart { display: block; width: 100%; max-width: 100%; height: auto; min-width: 0; overflow: visible; }
.financial-chart text { font: 10px -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif; fill: #7987a0; }
.chart-legend { display: flex; flex-wrap: wrap; gap: 12px 21px; font-size: 11px; color: #6c7c96; margin-bottom: 20px; }
.chart-legend > span { display: flex; align-items: center; gap: 7px; }
.chart-legend i { width: 7px; height: 7px; display: block; border-radius: 50%; }
.methodology { background: #fafbff; border: 1px solid #e4e7f3; border-radius: 13px; padding: 18px 21px; font-size: 12px; color: var(--muted); }
.methodology summary { cursor: pointer; color: #566381; font-weight: 650; }
.methodology p { margin: 16px 0 0; line-height: 1.9; }
.scenario-insights { display: grid; grid-template-columns: repeat(3,minmax(0,1fr)); gap: 16px; margin-bottom: 24px; }
.scenario-insight { min-width: 0; padding: 22px; border: 1px solid #e1e3f3; background: #fafaff; border-radius: 15px; }
.scenario-insight .eyebrow { color: #747397; font-size: 9px; line-height: 1.8; }
.scenario-insight strong { display: block; margin: 12px 0 9px; color: #41477b; font-size: 24px; line-height: 1.4; font-weight: 700; letter-spacing: -.7px; }
.scenario-insight p { font-size: 12px; line-height: 1.7; color: var(--muted); margin: 0; }
.scenario-exploration.notice { border-left: 3px solid var(--primary); }
.comparison-toolbar { display: flex; align-items: center; flex-wrap: wrap; gap: 14px; padding: 21px 23px; margin-bottom: 23px; background: #fff; border: 1px solid var(--line); border-radius: 14px; color: var(--muted); font-size: 13px; }
.comparison-toolbar label { font-weight: 650; color: #475974; }
.comparison-toolbar select { flex: 1; min-width: min(100%,280px); }
.comparison-toolbar > .small { flex-basis: 100%; }
.comparison-delta { display: block; margin-top: 6px; color: #6c7294; font-size: 11px; line-height: 1.8; font-weight: 400; }
.comparison-same { background: #faf9ff; }
.comparison-different { color: #77758b; }
.comparison-unavailable { background: var(--warning-soft); color: var(--warning); border-color: #eeddb9; }
.model-note { padding: 20px 0; border-bottom: 1px solid var(--line); }
.model-note:last-child { border: 0; }
.model-note h3 { margin: 10px 0; font-size: 15px; }
.model-note p { font-size: 13px; line-height: 1.9; color: var(--muted); white-space: pre-wrap; }
.model-note small, .risk-impact { font-size: 12px; color: var(--muted); }
.bar-chart { display: flex; align-items: flex-end; gap: 15px; height: 155px; border-bottom: 1px solid var(--line); margin-top: 16px; }
.bar-wrap { display: flex; flex: 1; flex-direction: column; align-items: center; justify-content: flex-end; height: 100%; gap: 8px; }
.bar { width: 70%; max-width: 45px; min-height: 2px; background: #b3aef6; border-radius: 6px 6px 0 0; }
.bar-wrap:nth-child(3n) .bar { background: #7770df; }
.bar-label { color: var(--muted); font-size: 10px; }
.currency-tabs { display: flex; flex-wrap: wrap; gap: 6px; }
.currency-tabs button { border: 1px solid var(--line); color: var(--muted); background: #fff; padding: 8px 12px; border-radius: 9px; }
.currency-tabs button.active { background: var(--primary); border-color: var(--primary); color: #fff; }
.progress-track { height: 6px; background: #eeeef8; border-radius: 6px; overflow: hidden; }
.progress-track span { display: block; height: 100%; background: var(--primary); }


.scenario-workspace { min-width: 0; }
.jump-label-short { display: none; }
.scenario-jumpbar { position: sticky; top: 78px; z-index: 18; display: flex; flex-wrap: wrap; align-items: center; gap: 8px; padding: 8px; margin: 0 0 18px; border: 1px solid var(--line); border-radius: 12px; background: #fff; box-shadow: none; }
.scenario-jumpbar > span { color: var(--muted); font-size: 11px; margin: 0 auto 0 8px; }
.scenario-jumpbar .btn { min-height: 40px; font-size: 12px; }
#scenario-results, #scenario-levers { scroll-margin-top: 150px; }
#scenario-results:focus, #scenario-levers:focus { outline: none; }
#scenario-results:focus-visible, #scenario-levers:focus-visible { outline: 3px solid #7b78f4; outline-offset: 4px; }
.simulation-overview { min-width: 0; }
.simulation-disclosure, .simulation-explorer { min-width: 0; margin: 0 0 16px; border: 1px solid var(--line); background: #fff; border-radius: 15px; overflow: hidden; }
.simulation-disclosure > summary, .simulation-explorer > summary { display: flex; align-items: center; justify-content: space-between; gap: 14px; min-height: 67px; padding: 16px 19px; cursor: pointer; list-style: none; }
.simulation-disclosure > summary::-webkit-details-marker, .simulation-explorer > summary::-webkit-details-marker { display: none; }
.simulation-disclosure > summary:hover, .simulation-explorer > summary:hover { background: #fafaff; }
.disclosure-copy { display: block; min-width: 0; }
.disclosure-copy strong { display: block; color: #2e4261; font-size: 13px; font-weight: 650; }
.disclosure-copy small { display: block; color: var(--muted); font-size: 11px; margin-top: 4px; line-height: 1.6; }
.disclosure-icon { display: grid; place-items: center; width: 29px; height: 29px; flex-shrink: 0; color: var(--primary); background: var(--primary-soft); border-radius: 8px; }
.simulation-disclosure[open] > summary, .simulation-explorer[open] > summary { border-bottom: 1px solid var(--line); }
.simulation-disclosure[open] .disclosure-icon, .simulation-explorer[open] > summary .disclosure-icon { transform: rotate(90deg); }
.simulation-disclosure-body { min-width: 0; padding: 20px; }
.simulation-disclosure-body > .panel, .simulation-disclosure-body > .grid-equal > .panel { box-shadow: none; }
.simulation-explorer-body { min-width: 0; padding: 18px; }
.simulation-explorer-body > .panel { border: 0; border-radius: 0; box-shadow: none; }
.simulation-explorer-body > .panel > .panel-head { padding: 16px 0; }
.simulation-explorer-body > .panel > .panel-body { padding: 17px 0 0; }

/* Forms and dialogs. */
.form-grid { display: grid; grid-template-columns: repeat(2,minmax(0,1fr)); gap: 20px; }
.field { display: flex; flex-direction: column; gap: 7px; min-width: 0; }
.field.wide, .form-section { grid-column: 1/-1; }
.field label { color: #455874; font-size: 12px; font-weight: 650; }
.field input, .field select, .field textarea { width: 100%; min-width: 0; min-height: 46px; padding: 11px 13px; border: 1px solid #dbe1ed; border-radius: 10px; background: #fff; color: #253a58; font-size: 14px; transition: border-color .16s, box-shadow .16s; }
.field input:focus, .field select:focus, .field textarea:focus, .ai-composer textarea:focus { border-color: #9893eb; box-shadow: 0 0 0 3px #7971ed14; outline: none; }
.field input:disabled, .field select:disabled { background: #f5f6fa; color: #8490a5; }
.field textarea { min-height: 105px; resize: vertical; line-height: 1.8; }
.field small { color: #73829b; font-size: 11px; line-height: 1.75; }
.check { display: flex; align-items: flex-start; gap: 10px; color: #5a6c86; font-size: 13px; line-height: 1.8; }
.check input, .check-option input { width: 17px; height: 17px; flex-shrink: 0; margin: 4px 0 0; accent-color: var(--primary); }
.form-section { display: flex; align-items: center; gap: 10px; font-size: 13px; font-weight: 700; color: #4c547e; margin: 10px 0 0; padding-bottom: 12px; border-bottom: 1px solid var(--line); }
.form-error { border: 1px solid #eccdd3; border-radius: 11px; background: var(--negative-soft); color: #a33c49; padding: 14px 16px; font-size: 13px; line-height: 1.8; margin-top: 18px; overflow-wrap: anywhere; }
.form-error .btn { white-space: normal; margin-top: 8px; }
.form-note { color: #74839c; font-size: 11px; line-height: 1.8; margin: 10px 0; }
.form-actions { display: flex; justify-content: flex-end; align-items: center; flex-wrap: wrap; gap: 10px; padding-top: 24px; margin-top: 24px; border-top: 1px solid var(--line); }
dialog { width: min(760px,calc(100% - 32px)); max-height: 90dvh; padding: 0; color: var(--ink); background: #fff; border: 1px solid #e3e6f2; border-radius: 18px; box-shadow: none; overflow: hidden; }
dialog[open] { display: flex; flex-direction: column; }
dialog::backdrop { background: #111d3466; }
.wide-modal { width: min(1020px,calc(100% - 32px)); }
.modal-head { position: relative; flex-shrink: 0; z-index: 5; display: flex; justify-content: space-between; align-items: flex-start; gap: 20px; background: #fff; padding: 20px 24px; border-bottom: 1px solid var(--line); }
.modal-head h2 { font-size: 23px; margin: 0 0 7px; }
.modal-head p { color: var(--muted); font-size: 12px; line-height: 1.75; margin: 0; }
.modal-head .icon-btn { width: 44px; height: 44px; }
.modal-body { padding: 22px 24px; min-width: 0; min-height: 0; overflow-y: auto; overscroll-behavior: contain; }
.modal-body .panel { margin-top: 20px; }
.modal-footer { padding: 19px 28px; background: #fafbfe; border-top: 1px solid var(--line); }
.quote, .balance-box { background: #f5f4ff; border: 1px solid #dedcf8; border-radius: 13px; padding: 23px; margin: 22px 0; }
.quote-row { display: flex; justify-content: space-between; gap: 15px; padding: 11px 0; border-bottom: 1px solid #e1dff4; font-size: 13px; }
.quote-row:last-child { border: 0; }
.quote small { color: var(--muted); }
.code { display: inline-block; background: #f0effb; border: 1px solid #e2def7; padding: 7px 10px; border-radius: 8px; font: 12px 'SFMono-Regular', Consolas, monospace; color: #6b5ca6; letter-spacing: .4px; }
.check-option { display: flex; gap: 12px; align-items: flex-start; padding: 17px; margin-bottom: 12px; background: #fafaff; border: 1px solid var(--line); border-radius: 11px; font-size: 13px; }
.schema-row { display: grid; grid-template-columns: 1fr 1.3fr 1fr auto auto; gap: 9px; align-items: center; margin-top: 12px; }
.schema-row input, .schema-row select { min-width: 0; min-height: 44px; padding: 10px; font-size: 12px; border: 1px solid var(--line); border-radius: 9px; }
.schema-row input[type=checkbox] { width: 17px; height: 17px; min-height: 0; }
.schema-row label { font-size: 12px; }
.split-fields { display: grid; grid-template-columns: repeat(2,minmax(0,1fr)); gap: 9px; }
.password-wrap { display: flex; align-items: center; width: 100%; position: relative; }
.password-wrap input { padding-right: 54px; }
.password-wrap .icon-btn { position: absolute; right: 4px; background: transparent; border-color: transparent; }


.form-intro { margin: 0 0 18px; color: var(--muted); font-size: 12px; line-height: 1.7; }
.entity-form-section { min-width: 0; margin: 0 0 22px; padding: 0; border: 0; }
.entity-form-section > legend { width: 100%; padding: 0 0 12px; margin-bottom: 16px; color: #2e4160; border-bottom: 1px solid var(--line); font-size: 13px; font-weight: 700; }
.form-more { margin: 0 0 18px; border: 1px solid var(--line); border-radius: 12px; background: #fcfcff; }
.form-more > summary { display: flex; align-items: center; gap: 10px; min-height: 49px; padding: 13px 15px; cursor: pointer; color: #465573; font-size: 12px; font-weight: 650; list-style: none; }
.form-more > summary::-webkit-details-marker { display: none; }
.form-more > summary::before { content: '+'; display: grid; place-items: center; width: 21px; height: 21px; color: var(--primary); border: 1px solid #dcd8fb; background: var(--primary-soft); border-radius: 6px; font-size: 15px; font-weight: 500; }
.form-more[open] > summary::before { content: '−'; }
.form-more-count { margin-left: auto; color: var(--muted); font-size: 10px; font-weight: 500; }
.form-more > .form-grid, .form-more > .entity-form-section { padding: 4px 16px 16px; margin-bottom: 0; }
.form-savebar { position: sticky; bottom: -22px; z-index: 4; margin: 22px -24px -22px; padding: 14px 24px; background: #fff; box-shadow: none; }
.form-save-status { flex: 1; min-width: 110px; color: var(--muted); font-size: 11px; line-height: 1.5; }
.modal-discard-confirm { position: sticky; top: -22px; z-index: 8; margin: -22px -24px 20px; padding: 16px 24px; border-bottom: 1px solid #e9d8b1; background: #fff7e4; box-shadow: none; }
.modal-discard-confirm p { margin: 0 0 12px; color: #765119; font-size: 13px; line-height: 1.6; }
.modal-discard-actions { display: flex; flex-wrap: wrap; gap: 9px; }
.modal-discard-actions .btn { min-height: 42px; white-space: normal; }
.field.has-error input, .field.has-error textarea, .field.has-error select, [aria-invalid=true] { border-color: #bd5261; background: #fffafb; }
.field-error { margin: 0; color: #a52f42 !important; font-size: 11px; line-height: 1.6; }
.form-validation-summary { margin: 0 0 18px; }
.local-preview-short { display: none; }
.local-preview-badge { display: inline-flex; align-items: center; gap: 5px; max-width: 120px; padding: 5px 8px; border: 1px solid #e8d9b3; border-radius: 7px; color: #7b5917; background: #fff8e8; font-size: 10px; line-height: 1.4; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }

/* Sign-in and recovery. */
.login-screen { min-height: 100dvh; display: grid; grid-template-columns: 1.05fr 1fr; background: #fff; }
.login-story { display: flex; flex-direction: column; justify-content: center; position: relative; overflow: hidden; padding: 8vh 9%; background: #111c30; color: #fff; }
.login-story::after { content: ''; position: absolute; width: 500px; height: 500px; right: -270px; top: -260px; border-radius: 50%; border: 1px solid #ffffff0a; box-shadow: none; pointer-events: none; }
.login-story .brand { position: relative; z-index: 1; color: #fff; margin-bottom: 80px; }
.login-story .brand-symbol { background: #6a61ed; }
.login-story h1 { font-size: clamp(38px,4vw,63px); letter-spacing: -2.5px; line-height: 1.08; font-weight: 700; margin-bottom: 25px; }
.login-story p { color: #acbcd4; font-size: 16px; line-height: 1.9; max-width: 420px; }
.login-art { margin: 30px -10% 35px; opacity: .6; }
.login-art svg { width: 100%; max-height: 240px; color: #9e9af7; }
.login-foot { color: #8298b6; font-size: 10px; letter-spacing: 2px; margin-top: auto; }
.login-main { display: flex; justify-content: center; align-items: center; padding: 65px 8%; background: #fff; }
.login-form { width: 100%; max-width: 400px; }
.login-form h2 { font-size: 37px; line-height: 1.15; letter-spacing: -1.3px; margin: 16px 0 18px; }
.login-form > p { font-size: 14px; line-height: 1.8; color: var(--muted); }
.login-form .field { margin-bottom: 22px; }
.login-form .field input { min-height: 52px; background: #fbfcff; }
.login-form .btn.primary { min-height: 52px; width: 100%; margin-top: 7px; font-size: 14px; }
.login-form .fine { font-size: 11px; color: #7b8aa2; text-align: center; margin-top: 22px; line-height: 1.8; }
.login-divider { display: flex; align-items: center; gap: 15px; color: #8b96aa; font-size: 9px; font-weight: 650; letter-spacing: 2px; margin: 35px 0 23px; }
.login-divider::before, .login-divider::after { content: ''; height: 1px; flex: 1; background: var(--line); }
.login-form .btn.client { width: 100%; }
.registration { max-width: 750px; margin: 35px auto; padding: 28px; }
.registration .brand { margin-bottom: 32px; }
.registration .panel-body { padding: 28px; }
.initial, .error-screen { display: flex; min-height: 100dvh; align-items: center; justify-content: center; flex-direction: column; padding: 32px; text-align: center; }
.initial p { color: var(--muted); margin-top: 23px; }
.error-screen { max-width: 650px; margin: auto; }
.error-screen h1 { font-size: 32px; }
.error-screen p { color: var(--muted); font-size: 15px; line-height: 1.8; }
.error-screen .brand-symbol { margin-bottom: 20px; }
#toast { position: fixed; bottom: 26px; left: 50%; z-index: 200; max-width: min(560px,calc(100% - 32px)); transform: translate(-50%,12px); padding: 14px 21px; border-radius: 12px; background: #17243a; color: #fff; box-shadow: none; font-size: 13px; line-height: 1.75; opacity: 0; visibility: hidden; transition: opacity .2s, transform .2s; }
#toast.show { opacity: 1; visibility: visible; transform: translate(-50%,0); }
.preview-banner { position: fixed; top: 0; left: 0; right: 0; z-index: 100; padding: 8px 18px; background: #fff1d3; color: #8b5d07; font-size: 12px; text-align: center; }
.preview-banner a { font-weight: 750; text-decoration: underline; margin-left: 10px; }

/* Search and command navigation. */
.login-story-copy { position: relative; z-index: 1; }
.login-story-copy > .eyebrow { color: #aaa8ef; }
.login-path { display: grid; grid-template-columns: repeat(3,minmax(0,1fr)); gap: 15px; margin: 36px 0; }
.login-path > div { display: grid; grid-template-columns: 1fr auto; align-items: start; gap: 10px 5px; border: 1px solid #ffffff13; background: #ffffff04; border-radius: 13px; padding: 17px 14px; }
.login-path > div > span { color: #9a9de4; font-size: 10px; }
.login-path svg { color: #a3a0ed; }
.login-path strong { grid-column: 1/-1; font-size: 14px; color: #e2e9f5; }
.login-path small { grid-column: 1/-1; color: #aabdd6; font-size: 10px; line-height: 1.8; }
.login-principles { display: flex; flex-wrap: wrap; gap: 15px 22px; color: #b8c5dc; font-size: 11px; line-height: 1.8; }
.login-principles span { display: flex; align-items: center; gap: 9px; }
.login-principles svg { color: #a19aed; }

.command-palette .search-box { padding: 13px 15px; min-height: 52px; background: #fafaff; border-color: #dddbf4; }
.command-palette .search-box input { width: 100%; font-size: 15px; }
.command-palette .nav-label { font-size: 10px; font-weight: 700; letter-spacing: 1.5px; color: #7e89a1; margin: 22px 0 10px; }
#command-results { max-height: 53dvh; overflow-y: auto; margin-top: 16px; scrollbar-width: thin; }
.command-result { display: flex; align-items: center; gap: 13px; width: 100%; min-height: 65px; text-align: left; border: 1px solid transparent; border-radius: 11px; padding: 11px 10px; background: #fff; }
.command-result:hover, .command-result:focus-visible, .command-result.is-active { background: #f4f3ff; border-color: #e1ddfa; }
.command-result > strong, .command-result > span:nth-child(2) { flex: 1; min-width: 0; }
.command-result strong { display: block; color: #394765; font-size: 14px; font-weight: 650; overflow-wrap: anywhere; }
.command-result small { display: block; color: var(--muted); font-size: 12px; margin-top: 4px; }
.command-result > svg:last-child { margin-left: auto; color: #9b97b3; }
.command-status { color: var(--muted); font-size: 11px; margin: 10px 0 0; min-height: 18px; }
.command-hint { border-top: 1px solid var(--line); color: #7f8aa1; font-size: 11px; padding-top: 18px; margin-top: 14px; }
.workspace-search-form { display: flex; align-items: center; gap: 12px; padding: 20px; margin-bottom: 25px; background: #fff; border: 1px solid var(--line); border-radius: 15px; }
.workspace-search-form input { flex: 1; min-width: 0; padding: 12px 14px; min-height: 48px; border: 1px solid #dfdff1; background: #fafaff; border-radius: 10px; font-size: 15px; color: var(--ink); }
.search-results { background: #fff; border: 1px solid var(--line); border-radius: 16px; padding: 18px; }

/* Assistant: threads, messages, proposals and photos. */
.main:has(.ai-page--focused) { display: flex; flex-direction: column; height: 100dvh; min-height: 0; overflow: hidden; }
.content:has(.ai-page--focused) { display: flex; flex-direction: column; flex: 1; min-height: 0; overflow: hidden; padding: 18px 24px; }
.content:has(.ai-page) > .footer { display: none; }
.ai-page { display: flex; flex-direction: column; gap: 10px; min-width: 0; min-height: 0; height: 100%; }
.ai-page > .page-head { margin-bottom: 0; flex-shrink: 0; }
.ai-page-head { flex-wrap: nowrap; align-items: center; gap: 14px; }
.ai-page-head h1 { font-size: 26px; margin-bottom: 4px; }
.ai-page-head p { font-size: 12px; line-height: 1.5; }
.ai-page-head > .ai-settings-shortcut { flex-shrink: 0; }
.ai-page > .notice { margin: 0; flex-shrink: 0; padding: 11px 14px; }
.ai-scope-bar, .ai-company-bar { display: flex; align-items: center; gap: 14px; padding: 10px 13px; border: 1px solid var(--line); background: #fff; border-radius: 12px; flex-shrink: 0; }
.ai-company-bar { margin-bottom: 20px; justify-content: space-between; flex-wrap: wrap; }
.ai-context-summary { display: flex; align-items: center; gap: 10px; flex: 1; min-width: 0; }
.ai-context-summary > div { min-width: 0; }
.ai-scope-bar strong { display: block; font-size: 12px; margin-top: 2px; color: #364962; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.ai-scope-bar .eyebrow, .ai-company-bar .eyebrow { font-size: 9px; color: #667089; }
.ai-scope-bar .brand-logo { width: 34px; height: 34px; border-radius: 10px; font-size: 11px; }
.ai-company-bar h2 { margin: 4px 0 0; font-size: 22px; }
.ai-scope-select { max-width: 360px; min-width: 0; flex: 1; }
.ai-scope-select select { width: 100%; min-height: 42px; padding: 9px 11px; border: 1px solid #dfe2ee; border-radius: 9px; background: #fafaff; color: #475b78; font-size: 13px; }
.ai-idea-symbol { display: grid; place-items: center; width: 34px; height: 34px; flex-shrink: 0; border-radius: 10px; color: var(--primary); background: var(--primary-soft); }
.ai-workspace { display: grid; grid-template-columns: 210px minmax(0,1fr); flex: 0 0 var(--ai-workspace-height,calc(100dvh - 240px)); height: var(--ai-workspace-height,calc(100dvh - 240px)); min-height: 0; background: #fff; border: 1px solid #dfe3ee; border-radius: 15px; overflow: hidden; }
.ai-conversations { padding: 20px 15px; background: #f9faff; border-right: 1px solid #e7eaf3; overflow-y: auto; min-height: 0; }
.ai-conversations > .flex { margin-bottom: 21px; }
.ai-conversations h3 { font-size: 13px; margin: 0; color: #596383; }
.ai-conversations .icon-btn { background: #fff; }
.ai-thread { display: block; width: 100%; text-align: left; background: transparent; border: 1px solid transparent; border-radius: 11px; padding: 13px 11px; margin: 7px 0; color: #667089; }
.ai-thread:hover { background: #f1efff; color: #58529d; }
.ai-thread.selected { background: #eeecff; border-color: #e1dcfb; }
.ai-thread strong { display: block; color: #545f7a; font-size: 12px; font-weight: 650; overflow-wrap: anywhere; line-height: 1.6; }
.ai-thread.selected strong { color: #5148a4; }
.ai-thread small { display: block; font-size: 10px; margin-top: 4px; color: #667089; }
.ai-context-note { margin: 28px 8px 0; padding-top: 23px; border-top: 1px solid #e5e7f2; font-size: 11px; color: #667089; line-height: 1.8; }
.ai-context-note svg { color: #667089; display: block; margin-bottom: 12px; }
.ai-context-note strong { display: block; margin-bottom: 8px; color: #5d6b84; }
.ai-chat { display: flex; min-width: 0; min-height: 0; flex-direction: column; }
.ai-chat-head { display: flex; align-items: center; gap: 12px; min-height: 60px; padding: 10px 17px; border-bottom: 1px solid var(--line); flex-shrink: 0; }
.ai-chat-head h3 { margin: 0 0 3px; font-size: 15px; color: #34465f; }
.ai-chat-head .small { font-size: 11px; line-height: 1.5; }
.ai-chat-head .brand-logo { width: 38px; height: 38px; border-radius: 12px; font-size: 13px; }
.ai-chat-head > .pill { margin-left: auto; font-size: 10px; }
.ai-chat-persona { display: flex; align-items: center; gap: 10px; min-width: 0; flex: 1; }
.ai-chat-persona > div { min-width: 0; }
.ai-chat-persona .small { display: block; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.ai-mobile-thread { display: none; }
.ai-transcript-wrap { position: relative; display: flex; flex: 1; min-height: 0; overflow: hidden; }
.ai-messages { flex: 1; width: 100%; height: 100%; min-width: 0; min-height: 0; max-height: none; overflow: auto; overscroll-behavior: contain; padding: 20px 23px; scrollbar-width: thin; scrollbar-color: #d5d8e8 transparent; scroll-padding-block: 12px; }
.ai-jump-latest { position: absolute; left: 50%; bottom: 12px; z-index: 3; transform: translateX(-50%); min-height: 36px; padding: 8px 12px; background: #fff; border-color: #ccc8f3; box-shadow: none; font-size: 11px; }
.ai-jump-latest[hidden] { display: none; }
.ai-welcome { text-align: center; max-width: 600px; margin: auto; padding: 25px 10px; }
.ai-welcome > svg { width: 45px; height: 45px; margin-bottom: 20px; color: #667089; padding: 9px; background: #f3f1ff; border-radius: 14px; }
.ai-welcome h2 { font-size: 29px; letter-spacing: -.9px; margin-bottom: 14px; color: #36415f; }
.ai-welcome p { font-size: 13px; line-height: 1.85; color: #667089; max-width: 470px; margin: 0 auto 24px; }
.ai-prompts { display: grid; gap: 9px; max-width: 490px; margin: auto; }
.ai-prompts button { display: flex; justify-content: space-between; align-items: center; gap: 16px; background: #fff; border: 1px solid #e7e4f4; border-radius: 11px; padding: 13px 15px; text-align: left; color: #6b6a8e; font-size: 12px; line-height: 1.6; min-height: 46px; }
.ai-prompts button:hover { border-color: #c7c0ef; background: #f8f6ff; }
.ai-message { margin-bottom: 30px; }
.ai-message:last-child { margin-bottom: 0; }
.ai-message-identity { display: flex; align-items: center; flex-wrap: wrap; gap: 10px; font-size: 12px; margin-bottom: 13px; }
.ai-message-identity strong { color: #485872; font-size: 12px; }
.ai-message-identity small { margin-left: auto; color: #667089; font-size: 10px; }
.ai-message-identity .brand-logo, .ai-message-identity .avatar { width: 28px; height: 28px; font-size: 10px; border-radius: 9px; }
.ai-prose { white-space: pre-wrap; overflow-wrap: anywhere; font-size: 14px; line-height: 1.9; color: #4f5e78; }
.from-user .ai-prose { padding: 16px 19px; background: #f1f0fc; border: 1px solid #e7e3f7; border-radius: 0 13px 13px 13px; color: #5a547b; }
.ai-proposals { border: 1px solid #dad7f0; border-radius: 13px; margin-top: 22px; background: #fff; overflow: hidden; }
.ai-proposals-head { display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: 15px; padding: 20px; background: #f8f6ff; border-bottom: 1px solid #e4e0f5; }
.ai-proposals-head h3 { margin: 5px 0 0; font-size: 17px; color: #5a527e; }
.ai-proposals-head .eyebrow { font-size: 9px; color: #667089; }
.ai-operation { padding: 20px; border-bottom: 1px solid #eeeaf8; }
.ai-operation.applied { background: #f5faf8; }
.ai-operation-check { display: flex; align-items: flex-start; gap: 12px; cursor: pointer; }
.ai-operation-check input { width: 18px; height: 18px; flex-shrink: 0; margin: 4px 0 0; accent-color: var(--primary); }
.ai-operation-check strong { display: block; font-size: 13px; color: #5b557d; }
.ai-operation-check small { display: block; font-size: 11px; color: #667089; line-height: 1.7; margin-top: 4px; }
.ai-operation > p { font-size: 12px; line-height: 1.85; color: #667089; margin: 12px 0; }
.ai-operation details { margin: 14px 0 0 30px; font-size: 12px; color: #667089; }
.ai-operation summary { color: #77718f; font-size: 11px; cursor: pointer; }
.ai-operation details[open] summary { margin-bottom: 13px; }
.ai-diff { white-space: normal; font-size: 11px; }
.ai-diff td, .ai-diff th { padding: 9px 12px; font-size: 11px; overflow-wrap: anywhere; }
.ai-apply-bar { display: flex; justify-content: space-between; align-items: center; flex-wrap: wrap; gap: 16px; padding: 17px 20px; background: #fcfbff; }
.ai-apply-bar > span { color: #667089; font-size: 11px; }
.ai-context-details { margin-top: 18px; font-size: 11px; color: #667089; }
.ai-context-details summary { cursor: pointer; margin-bottom: 8px; }
.ai-thinking { display: flex; align-items: center; gap: 12px; padding: 18px 0; color: #667089; font-size: 12px; }
.ai-dots { display: inline-block; animation: pulse 1.2s ease-in-out infinite; }
@keyframes pulse { 50% { opacity: .3; } }
.ai-composer { position: relative; flex-shrink: 0; padding: 10px 15px; border-top: 1px solid var(--line); background: #fcfcff; }
.ai-composer textarea { display: block; width: 100%; min-height: 44px; max-height: 112px; padding: 10px 12px; border: 1px solid #dfe1ee; border-radius: 10px; background: #fff; color: #344865; font-size: 14px; line-height: 1.6; resize: none; }
.ai-composer-actions { position: relative; display: flex; align-items: center; gap: 10px; margin-top: 8px; }
.ai-composer-actions > .btn.primary { margin-left: auto; min-height: 40px; padding: 9px 14px; }
.ai-composer-details { min-width: 0; }
.ai-composer-details > summary { display: inline-flex; align-items: center; gap: 7px; min-height: 40px; padding: 8px 10px; border: 1px solid #e0def1; border-radius: 9px; color: #5e568a; background: #f5f3fe; cursor: pointer; font-size: 11px; list-style: none; }
.ai-composer-details > summary::-webkit-details-marker { display: none; }
.ai-composer-details[open] > summary { background: #eae6ff; border-color: #c7bdf3; }
.ai-composer-options { position: absolute; z-index: 12; left: 0; right: 0; bottom: calc(100% + 8px); min-height: 64px; max-height: max(64px,min(210px,calc(var(--ai-workspace-height,420px) - 180px))); overflow-y: auto; overscroll-behavior: contain; padding: 14px; border: 1px solid #d7d3ee; border-radius: 12px; background: #fff; box-shadow: none; }
.ai-composer-options .ai-photo-composer { margin-top: 0; }
.ai-composer-options .ai-photo-drafts { flex-wrap: nowrap; overflow-x: auto; padding: 8px 4px; margin: 10px -4px 0; }
.ai-composer-options .ai-photo-drafts figure { flex-shrink: 0; }
.ai-composer-status { min-width: 0; color: var(--muted); font-size: 10px; line-height: 1.5; }
.ai-compose-privacy { display: block; margin-top: 6px; color: #667089; font-size: 10px; line-height: 1.5; }
.ai-options-note { margin: 9px 0 0; color: var(--muted); font-size: 10px; line-height: 1.65; }
.ai-keyboard-open > .ai-page-head, .ai-keyboard-open > .ai-scope-bar, .ai-keyboard-open > .notice { display: none; }
.shell:has(.ai-keyboard-open) .mobile-nav { display: none; }
.ai-load-error { margin: 0 0 22px; padding: 18px; background: var(--warning-soft); border: 1px solid #eadcba; border-radius: 13px; color: #856329; font-size: 13px; line-height: 1.8; }
.ai-load-error .btn { display: flex; width: fit-content; margin-top: 12px; }
.ai-settings-grid { display: grid; grid-template-columns: minmax(0,1.55fr) minmax(270px,1fr); gap: 25px; align-items: start; }
.ai-persona-preview { text-align: center; padding: 22px; }
.ai-persona-preview .brand-logo { margin: 0 auto 17px; }
.ai-persona-preview h2 { margin-bottom: 13px; font-size: 25px; }
.ai-principles p { display: flex; align-items: flex-start; gap: 13px; margin-bottom: 21px; color: #667089; font-size: 12px; line-height: 1.85; }
.ai-principles svg { color: #667089; margin-top: 3px; }
.ai-business-picker { max-width: 1050px; margin: 35px auto; }
.ai-business-picker > h2 { font-size: 30px; margin: 13px 0; }
.ai-business-grid { display: grid; grid-template-columns: repeat(2,minmax(0,1fr)); gap: 18px; margin-top: 28px; }
.ai-business-card { display: flex; align-items: center; gap: 15px; width: 100%; min-width: 0; padding: 23px; text-align: left; background: #fff; border: 1px solid var(--line); border-radius: 15px; }
.ai-business-card:hover { background: #faf9ff; border-color: #ccc4ed; }
.ai-business-card > span { flex: 1; min-width: 0; }
.ai-business-card strong, .ai-business-card small { display: block; }
.ai-business-card strong { color: #4e5278; font-size: 15px; }
.ai-business-card small { color: #667089; font-size: 12px; margin-top: 5px; }
.ai-photo-composer { margin-top: 12px; }
.ai-photo-composer > .flex > small { max-width: none; font-size: 10px; }
.ai-photo-picker { min-height: 40px; color: #72659c; background: #f5f2fd; border-color: #e4dff2; font-size: 11px; cursor: pointer; }
.ai-photo-picker.disabled { opacity: .45; cursor: not-allowed; }
.ai-file-input { position: absolute; width: 1px; height: 1px; opacity: 0; overflow: hidden; }
.ai-photo-composer:focus-within .ai-photo-picker { outline: 3px solid #a59bd4; outline-offset: 3px; }
.ai-photo-drafts { display: flex; flex-wrap: wrap; gap: 13px; margin: 15px 0 6px; }
.ai-photo-drafts figure { position: relative; width: 100px; padding: 5px; margin: 0; background: #fff; border: 1px solid var(--line); border-radius: 10px; }
.ai-photo-drafts img { display: block; width: 88px; height: 75px; object-fit: cover; border-radius: 6px; }
.ai-photo-drafts figcaption { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; color: #667089; font-size: 9px; margin: 6px 2px 0; }
.ai-photo-drafts .icon-btn { position: absolute; right: -7px; top: -7px; width: 27px; height: 27px; border-radius: 50%; box-shadow: none; }
.ai-message-photos { display: flex; gap: 13px; flex-wrap: wrap; margin: 18px 0; }
.ai-message-photos > button { max-width: 180px; padding: 5px; border: 1px solid var(--line); background: #fff; border-radius: 11px; text-align: left; }
.ai-message-photos > button:hover { border-color: #b7a9df; }
.ai-message-photos img { display: block; width: 158px; height: 120px; object-fit: cover; border-radius: 7px; }
.ai-message-photos span { display: block; max-width: 158px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; padding: 7px 3px 2px; color: #667089; font-size: 10px; }
.ai-photo-full { display: block; width: 100%; max-height: 75dvh; object-fit: contain; border-radius: 10px; }
.ai-model-tools { display: flex; align-items: center; flex-wrap: wrap; gap: 10px; margin: 10px 0 6px; }
.ai-model-tools small, #ai-model-message { display: block; color: #667089; font-size: 11px; line-height: 1.8; }
.ai-model-tools .btn { min-height: 38px; font-size: 11px; }
.ai-idea-step { margin-top: 15px; border: 1px solid #deddec; border-radius: 11px; background: #fff; padding: 17px; }
.ai-idea-step strong { font-size: 13px; color: #645d87; }
.ai-idea-step p { font-size: 12px; color: #667089; line-height: 1.8; margin: 8px 0; }
.ai-idea-step small { font-size: 10px; color: #667089; }

/* Monitoring and field action plan. */
.ai-welcome-badge { display: inline-flex; align-items: center; gap: 8px; background: #f1effc; border: 1px solid #e5dff7; border-radius: 25px; padding: 7px 12px; color: #71628f; font-size: 10px; margin: 0 0 21px; }
.ai-prompt-icon { display: inline-grid; place-items: center; width: 36px; height: 36px; flex-shrink: 0; border-radius: 10px; background: #f2effc; color: #667089; }
.ai-prompts button > span:nth-child(2) { flex: 1; min-width: 0; }
.ai-prompt-title { display: block; font-size: 12px; color: #655879; font-weight: 650; }
.ai-prompt-description { display: block; margin-top: 4px; font-size: 11px; line-height: 1.7; color: #667089; }
.ai-message-tools { display: flex; justify-content: flex-end; padding-top: 11px; }
.ai-message-tools .btn { min-height: 34px; font-size: 10px; padding: 7px 10px; background: #fff; color: #7c6e8c; }
.ai-rich-text { white-space: normal; }
.ai-rich-text > :last-child { margin-bottom: 0; }
.ai-rich-text h3, .ai-rich-text h4 { color: #4f4665; font-weight: 700; font-size: 17px; line-height: 1.5; margin: 24px 0 13px; }
.ai-rich-text h3:first-child, .ai-rich-text h4:first-child { margin-top: 0; }
.ai-rich-text h4 { font-size: 15px; }
.ai-rich-text p { margin-bottom: 16px; }
.ai-rich-text ul, .ai-rich-text ol { padding-left: 23px; margin: 14px 0 18px; }
.ai-rich-text li { padding: 3px 0; }
.ai-rich-text blockquote { margin: 18px 0; padding: 12px 18px; border-left: 3px solid #c0b2d4; border-radius: 0 8px 8px 0; background: #f8f5fc; color: #776286; }
.ai-rich-text code { background: #f0ecf8; color: #735586; border-radius: 5px; padding: 2px 5px; font: .87em 'SFMono-Regular', Consolas, monospace; overflow-wrap: anywhere; }
.ai-rich-text pre { padding: 18px; overflow-x: auto; max-width: 100%; background: #f5f2fa; border: 1px solid #e9e1f0; border-radius: 11px; white-space: pre; line-height: 1.8; }
.ai-rich-text pre code { background: transparent; padding: 0; overflow-wrap: normal; white-space: pre; }
.ai-composer-meta { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin-top: 12px; color: #667089; font-size: 10px; }
.ai-character-count { flex-shrink: 0; font-variant-numeric: tabular-nums; }
.ai-connection-status { align-items: center; }
.ai-connection-status > div { min-width: 0; flex: 1; }
.ai-connection-status strong { font-size: 13px; }
.ai-connection-status p { font-size: 12px; margin: 5px 0 0; line-height: 1.8; }
.ai-thread-heading .eyebrow { display: block; color: #667089; font-size: 8px; margin-bottom: 4px; }
.ai-thread-heading h3 { font-size: 13px; }
.ai-thread-count { display: inline-grid; place-items: center; min-width: 20px; min-height: 20px; margin-left: 3px; color: #667089; background: #eee8f5; border-radius: 6px; font-size: 10px; }
.ai-history-empty { font-size: 11px; line-height: 1.8; margin: 24px 9px; color: #82708f; }
.ai-loading { font-size: 12px; padding: 10px 0; }

.ai-watch-intro, .field-hero { display: flex; justify-content: space-between; align-items: center; gap: 30px; padding: 32px; background: #ecebf9; border: 1px solid #dddcf0; border-radius: 19px; margin-bottom: 25px; }
.ai-watch-intro h2, .field-hero h2 { font-size: clamp(27px,2.6vw,37px); line-height: 1.2; letter-spacing: -1.1px; color: #494567; margin: 14px 0; }
.ai-watch-intro p, .field-hero p { max-width: 580px; color: #667089; font-size: 13px; line-height: 1.85; margin: 0; }
.ai-watch-number { min-width: 150px; text-align: center; font-size: 60px; line-height: 1.2; letter-spacing: -3px; color: #6f5b9b; }
.ai-watch-number span { display: block; font-size: 11px; letter-spacing: 0; color: #667089; margin-top: 8px; }
.ai-watch-layout { display: grid; grid-template-columns: minmax(0,1.5fr) minmax(280px,1fr); align-items: start; gap: 25px; }
.ai-finding { padding: 26px 0; border-bottom: 1px solid var(--line); }
.ai-finding:first-child { padding-top: 0; }
.ai-finding:last-child { padding-bottom: 0; border: 0; }
.ai-finding h3 { font-size: 18px; margin: 18px 0 13px; }
.ai-finding p { font-size: 13px; line-height: 1.9; color: #667089; white-space: pre-wrap; }
.ai-sources { display: flex; gap: 8px; flex-wrap: wrap; margin: 17px 0 12px; }
.ai-sources a { background: #f4f1fb; border: 1px solid #e4ddf1; border-radius: 7px; padding: 6px 9px; font-size: 10px; color: #667089; overflow-wrap: anywhere; }
.ai-sources a:hover { text-decoration: underline; }
.ai-watch-rule { padding-bottom: 23px; margin-bottom: 23px; border-bottom: 1px solid var(--line); }
.ai-watch-rule:last-child { padding: 0; margin: 0; border: 0; }
.ai-watch-rule h3 { font-size: 14px; margin: 0; }
.ai-watch-rule p { font-size: 12px; color: #667089; line-height: 1.85; margin: 14px 0; }
.ai-watch-rule > small { color: #667089; font-size: 11px; }
.ai-watch-rule dl { display: grid; grid-template-columns: 1fr 1.1fr; gap: 9px; font-size: 11px; margin: 18px 0; }
.ai-watch-rule dt { color: #667089; }
.ai-watch-rule dd { margin: 0; text-align: right; color: #7c6989; }
.ai-run { padding: 15px 0; border-bottom: 1px solid var(--line); font-size: 11px; }
.ai-run > .pill { margin-right: 8px; }
.ai-run small { color: #667089; font-size: 10px; }
.ai-run p { color: #667089; font-size: 12px; line-height: 1.8; margin: 11px 0; }
.ai-review-sources { display: grid; gap: 8px; color: #667089; font-size: 12px; margin-bottom: 22px; }
.ai-review-sources a:hover { text-decoration: underline; }
.field-progress { display: flex; gap: 30px; flex-shrink: 0; text-align: center; }
.field-progress strong { display: block; color: #69558b; font-size: 36px; font-weight: 700; letter-spacing: -1px; }
.field-progress span { display: block; color: #667089; font-size: 11px; }
.field-toolbar { display: flex; align-items: center; justify-content: space-between; gap: 16px; flex-wrap: wrap; margin-bottom: 22px; }
.field-filters { display: flex; flex-wrap: wrap; gap: 4px; background: #eeedf5; padding: 5px; border: 1px solid #e1dfeb; border-radius: 11px; }
.field-filters button { min-height: 38px; padding: 9px 12px; border: 0; border-radius: 8px; background: transparent; color: #667089; font-size: 11px; }
.field-filters button.selected { background: #fff; color: #6b5283; font-weight: 700; box-shadow: none; }
.field-layout { display: grid; grid-template-columns: minmax(270px,.9fr) minmax(0,1.5fr); gap: 24px; align-items: start; }
.field-list { display: grid; gap: 14px; }
.field-card { display: block; width: 100%; min-width: 0; padding: 22px; text-align: left; background: #fff; border: 1px solid var(--line); border-radius: 15px; }
.field-card:hover { border-color: #c5b5d8; }
.field-card.selected { border-color: #ae94ca; box-shadow: none; }
.field-card h3 { color: #665071; font-size: 16px; line-height: 1.5; margin: 17px 0 10px; }
.field-card > p { color: #667089; font-size: 12px; line-height: 1.85; margin-bottom: 18px; }
.field-priority { color: #667089; font-size: 10px; white-space: nowrap; }
.field-priority.high { color: var(--warning); }
.field-priority.low { color: #667089; }
.field-card-meta { color: #667089; font-size: 11px; gap: 13px; flex-wrap: wrap; }
.field-card-meta > span { display: flex; align-items: center; gap: 5px; }
.field-card-source { display: block; border-top: 1px solid var(--line); padding-top: 13px; margin-top: 17px; color: #667089; font-size: 10px; }
.field-advice { display: block; color: #667089; background: #fbf4e5; border-radius: 8px; padding: 8px 10px; margin-top: 14px; font-size: 11px; }
.field-detail { min-width: 0; }
.field-detail-head { padding: 26px; background: #fcfaff; border-bottom: 1px solid var(--line); }
.field-detail-head h2 { color: #62506b; font-size: 25px; letter-spacing: -.7px; line-height: 1.35; margin: 19px 0 13px; }
.field-detail-head > p { color: #667089; font-size: 13px; line-height: 1.9; margin-bottom: 19px; }
.field-detail-meta { display: flex; flex-wrap: wrap; gap: 13px; color: #667089; font-size: 11px; }
.field-detail > .panel > .panel-body { padding: 26px; }
.field-detail .panel-body > h3 { color: #7f668c; font-size: 14px; }
.field-steps { list-style: none; counter-reset: steps; display: grid; gap: 16px; padding: 0; margin: 20px 0 25px; }
.field-steps li { counter-increment: steps; display: flex; align-items: flex-start; gap: 13px; color: #667089; font-size: 13px; line-height: 1.85; white-space: pre-wrap; overflow-wrap: anywhere; }
.field-steps li::before { content: counter(steps); display: grid; place-items: center; width: 28px; height: 28px; flex-shrink: 0; border: 1px solid #e7ddec; background: #f5eef8; border-radius: 9px; color: #667089; font-size: 11px; font-weight: 700; margin-top: 1px; }
.field-success { display: flex; gap: 13px; padding: 18px; margin: 22px 0; background: #f1f8f5; border: 1px solid #d8e9e0; border-radius: 12px; }
.field-success svg { color: var(--positive); margin-top: 3px; }
.field-success strong { color: var(--positive); font-size: 12px; }
.field-success p { color: #667089; font-size: 12px; line-height: 1.85; margin: 7px 0 0; white-space: pre-wrap; }
.field-reason { border-bottom: 1px solid var(--line); margin: 24px 0; padding-bottom: 22px; }
.field-reason > .eyebrow { font-size: 10px; }
.field-reason p { color: #667089; font-size: 12px; line-height: 1.9; margin: 12px 0 0; white-space: pre-wrap; }
.field-report { border: 1px solid #e4deed; border-radius: 14px; padding: 22px; margin: 26px 0; background: #fcf9ff; }
.field-report > .flex { flex-wrap: wrap; align-items: flex-start; gap: 5px; margin-bottom: 20px; }
.field-report h3 { color: #806288; margin: 0; font-size: 14px; }
.field-report > .flex > span, .field-report .check { color: #667089; font-size: 11px; }
.field-report .form-actions { margin: 19px 0; }
.field-report .form-actions + .small { color: #667089; font-size: 11px; line-height: 1.85; margin: 0; }
.field-history { margin-top: 28px; }
.field-history > h3 { color: #87638b; font-size: 14px; }
.field-feedback { border-bottom: 1px solid var(--line); padding: 22px 0; }
.field-feedback:last-child { border: 0; }
.field-feedback > .flex strong { color: #8b658c; font-size: 12px; }
.field-feedback > .flex small { color: #667089; font-size: 10px; }
.field-feedback > p { font-size: 13px; line-height: 1.9; margin: 14px 0; }
.field-text { white-space: pre-wrap; overflow-wrap: anywhere; }
.field-ai-reply { padding: 19px; margin-top: 18px; background: #f8f4fc; border: 1px solid #eadeef; border-radius: 0 13px 13px 13px; }
.field-ai-reply .brand-logo { width: 29px; height: 29px; font-size: 10px; }
.field-ai-reply strong { color: #906590; font-size: 12px; }
.field-ai-reply p { color: #667089; font-size: 12px; line-height: 1.9; margin: 14px 0 0; }
.field-ai-reply .btn { margin-top: 16px; }
.field-revisions { border-top: 1px solid var(--line); padding-top: 22px; margin-top: 26px; color: #667089; font-size: 11px; }
.field-revisions summary { cursor: pointer; color: #667089; }
.field-revisions > article { border-bottom: 1px solid var(--line); padding: 18px 0; }
.field-revisions > article strong { color: #667089; font-size: 12px; }
.field-revisions > article small { font-size: 10px; }
.field-revisions > article p, .field-revisions li { font-size: 12px; line-height: 1.8; margin: 10px 0; }
.field-revisions > article details { margin-top: 12px; }
.field-chat-plan { border: 1px solid #dce4ed; border-radius: 13px; background: #f4f8fc; padding: 19px; margin-top: 22px; }
.field-chat-plan .eyebrow { color: #667089; font-size: 9px; }
.field-chat-plan h3 { color: #506d8a; font-size: 16px; margin: 7px 0 0; }
.field-chat-plan > button { display: flex; align-items: center; gap: 12px; width: 100%; background: #fff; border: 1px solid #e1e8f0; border-radius: 10px; padding: 14px; margin-top: 13px; text-align: left; }
.field-chat-plan > button:hover { border-color: #b5c8dc; background: #fbfdff; }
.field-chat-plan > button > span:nth-child(2) { flex: 1; min-width: 0; }
.field-chat-plan > button strong { display: block; color: #667089; font-size: 12px; }
.field-chat-plan > button small { display: block; color: #667089; font-size: 11px; margin-top: 4px; }
.field-next-icon { display: grid; place-items: center; width: 31px; height: 31px; flex-shrink: 0; background: #edf3f9; color: #667089; border-radius: 9px; }
.field-chat-plan > p { color: #667089; font-size: 11px; line-height: 1.8; margin: 14px 0 0; }

/* Documents can still be printed without the application chrome. */
.contract-paper { padding: 32px; background: #fff; border: 1px solid var(--line); border-radius: 14px; }
.contract-paper h1 { font-size: 27px; }
.contract-terms { font-size: 13px; line-height: 1.9; color: var(--muted); white-space: pre-wrap; padding-top: 22px; }
.contract-paper table { white-space: normal; }
.contract-paper th, .contract-paper td { padding: 11px; font-size: 12px; }
@media print {
  .shell, .login-screen, #toast, .mobile-nav, .bottom-nav { display: none !important; }
  dialog:not([open]) { display: none; }
  dialog[open] { position: static; width: 100%; max-width: 100%; max-height: none; border: 0; overflow: visible; box-shadow: none; }
  dialog::backdrop { background: none; }
  .modal-head, .no-print, .form-actions { display: none !important; }
  .modal-body { padding: 0; }
  .contract-paper { padding: 0; border: 0; }
  .contract-paper td, .contract-terms { color: #222; }
  .page-break { break-before: page; }
}

/* Responsive composition. Desktop sidebar hands off to a real mobile drawer. */
@media (min-width: 1500px) {
  .field-layout { grid-template-columns: 350px minmax(0,1fr); }
  .simulation-layout { grid-template-columns: minmax(0,1fr) 310px; }
}
@media (max-width: 1260px) {
  .topbar { padding-inline: 24px; }
  .content { padding-inline: 24px; }
  .command-trigger { width: 190px; }
  .cards, .dashboard-scenarios { grid-template-columns: repeat(2,minmax(0,1fr)); }
  .cockpit-overview { grid-template-columns: minmax(0,1fr) 200px; gap: 12px; }
  .cockpit-priority { padding: 17px; }
  .cockpit-priority > .btn { margin-left: 56px; }
  .simulation-layout { grid-template-columns: 1fr; gap: 16px; }
  .simulation-side { grid-template-columns: 1fr; }
  .simulation-layout .grid-equal { grid-template-columns: repeat(2,minmax(0,1fr)); }
  .simulation-stats { grid-template-columns: repeat(4,minmax(0,1fr)); }
  .simulation-stats .stat { padding: 16px 13px; }
  .simulation-stats .stat-number { font-size: 22px; }
  .ai-workspace { grid-template-columns: 180px minmax(0,1fr); }
  .field-layout { grid-template-columns: 275px minmax(0,1fr); }
  .scenario-insight { padding: 16px; }
  .scenario-insight strong { font-size: 22px; }
}
@media (max-width: 1060px) {
  .page-head { flex-wrap: wrap; }
  .page-head > .flex { max-width: 100%; flex-shrink: 1; }
  .cockpit-overview { grid-template-columns: 1fr; }
  .cockpit-brief { grid-template-columns: 1fr 1fr 1.4fr; align-items: center; padding: 13px 18px; }
  .cockpit-brief strong { font-size: 24px; }
  .cockpit-brief > p { grid-column: auto; }
  .cockpit-priority > .btn { margin-left: 56px; }
  .command-trigger { width: 42px; justify-content: center; padding: 10px; }
  .command-trigger span, .command-trigger kbd, .top-actions .global-search { display: none; }
  .top-actions { gap: 10px; }
  .live { display: none; }
  .stats { grid-template-columns: repeat(2,minmax(0,1fr)); }
  .workspace-stats .stat:nth-child(2) { border-right: 0; }
  .workspace-stats .stat:nth-child(-n+2) { border-bottom: 1px solid var(--line); }
  .workspace-stats .stat-foot { display: none; }
  .grid2, .grid-equal, .dashboard-support, .ai-settings-grid, .ai-watch-layout { grid-template-columns: 1fr; }
  .ai-watch-layout > aside { display: grid; grid-template-columns: repeat(2,minmax(0,1fr)); }
  .ai-conversations { padding-inline: 12px; }
  .ai-workspace { grid-template-columns: 165px minmax(0,1fr); }
  .ai-page-head { flex-wrap: nowrap; }
  .ai-page-head p { display: none; }
  .ai-context-summary { display: none; }
  .ai-scope-select { max-width: none; }
  .ai-chat-head, .ai-composer { padding-inline: 14px; }
  .ai-messages { padding: 18px; }
  .scenario-insights { grid-template-columns: 1fr; gap: 10px; }
  .scenario-insight { display: grid; grid-template-columns: minmax(0,1fr) auto; gap: 4px 16px; padding: 15px 18px; }
  .scenario-insight strong { grid-column: 2; grid-row: 1/3; margin: 0; align-self: center; font-size: 23px; }
  .scenario-insight p { grid-column: 1; }
  .field-layout { grid-template-columns: 1fr; }
  .field-list { grid-template-columns: repeat(2,minmax(0,1fr)); }
  .field-hero { align-items: flex-start; flex-direction: column; }
  .field-progress { gap: 32px; }
  .login-story { padding-inline: 11%; }
  .login-story h1 { font-size: 44px; }
  .login-form h2 { font-size: 33px; }
}
@media (min-width: 1061px) {
  .company-progress-card:only-child { display: grid; grid-template-columns: minmax(0,1.05fr) minmax(0,1fr); column-gap: 32px; }
  .company-progress-card:only-child > .flex { grid-column: 1; grid-row: 1; }
  .company-progress-card:only-child > h3 { grid-column: 1; grid-row: 2; margin: 10px 0 7px; }
  .company-progress-card:only-child > p { grid-column: 1; grid-row: 3; margin: 0; min-height: 0; }
  .company-progress-card:only-child > .company-progress-meta { grid-column: 2; grid-row: 1; align-self: end; margin-top: 0; }
  .company-progress-card:only-child > progress { grid-column: 2; grid-row: 2; align-self: center; margin: 10px 0; }
  .company-progress-card:only-child > .company-checks { grid-column: 2; grid-row: 3; margin-bottom: 0; }
  .company-progress-card:only-child .company-checklist { grid-template-columns: repeat(2,minmax(0,1fr)); }
  .company-progress-card:only-child > .company-next { grid-column: 1/-1; grid-row: 4; margin-top: 16px; }
}
@media (min-width: 761px) and (max-width: 900px) {
  .dashboard-scenarios, .cards, .field-list { grid-template-columns: 1fr; }
  .section-heading { flex-wrap: wrap; }
}
@media (max-width: 760px) {
  html { scroll-padding-top: 84px; }
  .sidebar { width: min(300px,calc(100% - 36px)); padding-top: 23px; transform: translateX(-105%); visibility: hidden; transition: transform .22s ease, visibility 0s linear .22s; z-index: 60; }
  .shell.menu-open .sidebar { transform: translateX(0); visibility: visible; transition: transform .22s ease, visibility 0s; box-shadow: none; }
  .brand-row { margin-inline: 8px 0; margin-bottom: 26px; }
  .brand-label { display: none; }
  .sidebar-close { display: grid; width: 44px; height: 44px; background: #f7f8fc; border-color: var(--line); color: #53647d; }
  .sidebar-overlay { position: fixed; inset: 0; z-index: 55; background: #111c3070; border: 0; opacity: 0; transition: opacity .22s; }
  .shell.menu-open .sidebar-overlay { display: block; opacity: 1; }
  .shell.menu-open .mobile-nav { pointer-events: none; }
  .main { margin-left: 0; width: 100%; }
  .topbar { min-height: 68px; padding: 12px 16px; gap: 10px; }
  .topbar .mobile-toggle { display: inline-grid; width: 44px; height: 44px; }
  .topbar-location { flex: 1; min-width: 0; }
  .mobile-page-title { display: block; min-width: 0; max-width: 150px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; color: #40516c; font-size: 14px; font-weight: 650; }
  .crumb, .topbar .chat-shortcut { display: none; }
  .topbar .flex { gap: 8px; }
  .command-trigger { width: 44px; min-height: 44px; }
  .local-preview-badge { max-width: 72px; padding: 4px 6px; font-size: 9px; }
  .local-preview-full { display: none; }
  .local-preview-short { display: inline; }
  .content { padding: 20px 16px calc(94px + env(safe-area-inset-bottom)); }
  .page-head { gap: 13px; flex-wrap: wrap; margin-bottom: 18px; }
  .page-head h1 { font-size: 27px; letter-spacing: -.8px; margin-bottom: 7px; }
  .page-head p { font-size: 13px; line-height: 1.7; }
  .page-head > .flex { flex-shrink: 1; max-width: 100%; }
  .page-head .date-label { display: none; }
  .page-head .btn { min-height: 44px; font-size: 12px; padding: 10px 12px; }
  .model-scope { min-width: 0; flex: 1; }
  .model-scope select { width: 100%; min-width: 0; font-size: 14px; }
  .btn.sm { min-height: 44px; }
  .icon-btn { width: 44px; height: 44px; }
  .cockpit-overview { gap: 10px; margin-bottom: 12px; }
  .cockpit-priority { padding: 16px; align-items: flex-start; gap: 11px; }
  .cockpit-priority-copy { flex-basis: calc(100% - 53px); }
  .cockpit-priority-copy h2 { font-size: 16px; }
  .cockpit-priority-copy p { font-size: 12px; }
  .cockpit-priority > .btn { margin: 0 0 0 53px; min-height: 44px; max-width: calc(100% - 53px); white-space: normal; }
  .cockpit-brief { padding: 12px 15px; gap: 8px 15px; grid-template-columns: 1fr 1fr; }
  .cockpit-brief > p { grid-column: 1/-1; font-size: 10px; }
  .cockpit-brief strong { font-size: 25px; }
  .stats { gap: 12px; }
  .stat { padding: 17px; border-radius: 14px; }
  .stat-number { font-size: 30px; }
  .workspace-stats { gap: 0; margin-bottom: 18px; }
  .workspace-stats .stat { padding: 11px 14px; }
  .workspace-stats .stat-number { font-size: 25px; }
  .workspace-stats .stat-label { font-size: 11px; }
  .cards, .company-progress-grid, .dashboard-scenarios { grid-template-columns: 1fr; gap: 14px; }
  .record-card, .company-progress-card, .dashboard-scenario { padding: 20px; }
  .record-card h2, .company-progress-card h3, .dashboard-scenario h3 { font-size: 20px; }
  .company-progress-card > p { font-size: 13px; }
  .company-next > span { font-size: 11px; }
  .company-next .btn { min-height: 44px; }
  .scenario-figures > div > span { font-size: 11px; }
  .scenario-figures strong { font-size: 21px; }
  .scenario-status .pill { font-size: 11px; }
  .scenario-horizon, .scenario-card-title p { font-size: 11px; }
  .scenario-card-footer > span { font-size: 10px; }
  .scenario-mini-chart svg { height: 52px; }
  .section-heading { gap: 12px; align-items: flex-start; flex-wrap: wrap; }
  .section-heading h2 { font-size: 21px; }
  .section-actions { width: 100%; justify-content: space-between; }
  .section-actions .btn { font-size: 11px; padding-inline: 10px; }
  .dashboard-section { margin-top: 22px; }
  .dashboard-support { gap: 14px; }
  .onboarding { grid-template-columns: 1fr; }
  .step-card { padding: 19px; }
  .panel-head { padding: 16px 18px; flex-wrap: wrap; }
  .panel-body { padding: 18px; }
  .toolbar { padding: 14px; }
  .toolbar > .flex { width: 100%; }
  .search-box { flex: 1; min-width: 0; }
  .search-box input { width: 100%; font-size: 16px; }
  .toolbar select { font-size: 14px; }
  th, td { padding-inline: 15px; }
  .table-footer { padding: 13px 15px; }
  .detail-hero { padding: 21px; flex-wrap: wrap; gap: 16px; }
  .detail-hero h1 { font-size: 27px; }
  .detail-hero .btn { margin-left: 0 !important; }
  .detail-hero .flex { flex-wrap: wrap; }
  .tabs { gap: 20px; margin-bottom: 18px; }
  .tab { font-size: 12px; }
  .scenario-context { padding: 12px 14px; gap: 10px; margin-bottom: 16px; }
  .scenario-context-meta { font-size: 11px; gap: 8px 12px; }
  .scenario-context-meta > span:first-child { flex-basis: 100%; }
  .scenario-context-meta > .small { font-size: 10px; }
  .scenario-jumpbar { top: 75px; gap: 5px; padding: 6px; margin-bottom: 14px; }
  .scenario-jumpbar > span, .jump-label-full { display: none; }
  .jump-label-short { display: inline; }
  .scenario-jumpbar > .flex { display: contents; }
  .scenario-jumpbar .btn { flex: 1; min-width: 0; min-height: 42px; font-size: 11px; padding: 8px; }
  #scenario-results, #scenario-levers { scroll-margin-top: 142px; }
  .simulation-layout { display: flex; flex-direction: column; gap: 14px; }
  .simulation-layout > div { order: 2; width: 100%; }
  .simulation-layout > .simulation-side { order: 1; width: 100%; }
  .simulation-side { display: grid; grid-template-columns: minmax(0,1fr); width: 100%; }
  .simulation-side .sensitivity-grid { gap: 19px; }
  .simulation-layout .grid-equal { grid-template-columns: 1fr; }
  .simulation-stats { grid-template-columns: repeat(2,minmax(0,1fr)); gap: 12px; }
  .simulation-stats .stat { padding: 16px 14px; }
  .simulation-stats .stat-number { font-size: 20px; letter-spacing: -.7px; }
  .simulation-stats .stat-label { min-height: 36px; }
  .simulation-stats .stat-foot { font-size: 10px; }
  .scenario-insight { display: grid; padding: 15px 16px; }
  .scenario-insight strong { font-size: 22px; }
  .scenario-insight .eyebrow { font-size: 9px; }
  .scenario-insight p { font-size: 11px; }
  .simulation-disclosure > summary, .simulation-explorer > summary { min-height: 65px; padding: 14px 16px; gap: 11px; }
  .simulation-disclosure-body, .simulation-explorer-body { padding: 16px; }
  .info-list { gap: 18px 15px; }
  .info-list dd { font-size: 13px; }
  .financial-chart text { font-size: 11px; }
  .chart-legend { gap: 10px 14px; font-size: 10px; margin-bottom: 15px; }
  .comparison-toolbar { padding: 16px; }
  .comparison-toolbar select { min-height: 46px; width: 100%; flex-basis: 100%; font-size: 16px; }
  .form-grid { grid-template-columns: 1fr; gap: 18px; }
  .field input, .field textarea, .field select { min-height: 48px; font-size: 16px; }
  .field label { font-size: 13px; }
  .field small, .form-note { font-size: 12px; }
  .form-actions { padding-top: 18px; margin-top: 18px; gap: 9px; }
  .form-actions .btn { min-height: 46px; }
  .schema-row { grid-template-columns: repeat(2,minmax(0,1fr)); }
  .schema-row input, .schema-row select { font-size: 14px; }
  dialog, .wide-modal { width: calc(100% - 16px); max-height: 94dvh; border-radius: 16px; }
  .modal-head { padding: 16px 18px; gap: 12px; }
  .modal-head h2 { font-size: 20px; }
  .modal-head p { font-size: 11px; }
  .modal-body { padding: 18px; }
  .form-intro { font-size: 12px; margin-bottom: 17px; }
  .entity-form-section { margin-bottom: 18px; }
  .form-more > summary { min-height: 49px; font-size: 12px; padding: 12px; }
  .form-more > .form-grid, .form-more > .entity-form-section { padding-inline: 13px; }
  .form-savebar { bottom: -18px; margin: 18px -18px -18px; padding: 12px 18px calc(12px + env(safe-area-inset-bottom)); }
  .form-save-status { flex-basis: 100%; font-size: 10px; }
  .form-savebar > .btn { flex: 1; }
  .modal-discard-confirm { top: -18px; margin: -18px -18px 18px; padding: 14px 18px; }
  .modal-discard-actions .btn { flex: 1; font-size: 12px; }
  .quote, .balance-box { padding: 18px; }
  .contract-paper { padding: 18px; }
  .workspace-search-form { flex-wrap: wrap; padding: 16px; }
  .workspace-search-form input { min-width: min(170px,100%); font-size: 16px; }
  .command-palette .search-box input { font-size: 16px; }
  .command-hint { display: none; }
  .command-result { padding-inline: 7px; min-height: 60px; }
  .search-results { padding: 12px; }
  .content:has(.ai-page--focused) { padding: 10px 10px 0; }
  .ai-page { gap: 8px; }
  .ai-page-head { flex-wrap: nowrap; gap: 10px; align-items: center; }
  .ai-page-head h1 { font-size: 22px; margin: 0; }
  .ai-page-head p, .ai-settings-label { display: none; }
  .ai-page-head > .ai-settings-shortcut { width: 42px; min-width: 42px; min-height: 42px; padding: 9px; }
  .ai-scope-bar { padding: 6px 9px; gap: 8px; min-height: 52px; }
  .ai-context-summary, .ai-scope-bar > .btn { display: none; }
  .ai-scope-select { flex: 1; max-width: none; }
  .ai-scope-select select { font-size: 13px; min-height: 39px; padding: 7px 9px; }
  .ai-workspace { grid-template-columns: minmax(0,1fr); border-radius: 13px; }
  .ai-conversations { display: none; }
  .ai-chat-head { min-height: 55px; padding: 7px 10px; gap: 8px; }
  .ai-chat-persona { flex: 0 0 28px; }
  .ai-chat-persona > div { display: none; }
  .ai-chat-persona .brand-logo { width: 28px; height: 28px; border-radius: 8px; font-size: 10px; }
  .ai-chat-head .ai-mobile-thread { display: flex; align-items: center; flex: 1; min-width: 0; gap: 7px; padding: 0; border: 0; background: transparent; color: var(--muted); font-size: 10px; }
  .ai-mobile-thread > span { display: none; }
  .ai-mobile-thread select { flex: 1; min-width: 0; max-width: 100%; min-height: 39px; padding: 8px; border: 1px solid #e2dced; background: #fff; border-radius: 8px; font-size: 12px; color: #465778; }
  .ai-chat-head > .icon-btn { width: 39px; height: 39px; }
  .ai-messages { padding: 15px; }
  .ai-welcome { padding: 13px 0; }
  .ai-welcome-badge { font-size: 9px; margin-bottom: 14px; padding: 6px 8px; }
  .ai-welcome h2 { font-size: 23px; margin-bottom: 10px; }
  .ai-welcome p { font-size: 12px; margin-bottom: 16px; }
  .ai-prompts button { font-size: 11px; padding: 10px; gap: 10px; }
  .ai-prompt-title { font-size: 12px; }
  .ai-prompt-description { display: none; }
  .ai-prompt-icon { width: 30px; height: 30px; }
  .ai-composer { padding: 8px 10px; }
  .ai-composer textarea { min-height: 44px; max-height: 88px; font-size: 16px; padding: 9px 10px; }
  .ai-composer-actions { gap: 7px; margin-top: 7px; }
  .ai-composer-actions > .btn.primary { min-height: 40px; font-size: 12px; padding: 9px 12px; }
  .ai-composer-details > summary { min-height: 40px; padding: 8px; font-size: 10px; gap: 5px; }
  .ai-composer-status { font-size: 9px; }
  .ai-composer-options { padding: 11px; }
  .ai-compose-privacy { margin-top: 5px; font-size: 9px; line-height: 1.4; }
  .ai-prose { font-size: 14px; line-height: 1.8; }
  .ai-operation { padding: 15px; }
  .ai-operation details { margin-left: 0; }
  .ai-proposals-head { padding: 15px; }
  .ai-proposals-head .btn { font-size: 10px; padding-inline: 9px; }
  .ai-proposals-head h3 { font-size: 16px; }
  .ai-apply-bar { padding: 15px; }
  .ai-apply-bar .btn { white-space: normal; }
  .ai-business-grid { grid-template-columns: 1fr; }
  .ai-business-picker > h2 { font-size: 27px; }
  .ai-company-bar { align-items: flex-start; flex-direction: column; }
  .ai-company-bar h2 { font-size: 21px; }
  .ai-connection-status { align-items: center; gap: 8px; }
  .ai-connection-status > svg { display: none; }
  .ai-connection-status strong { font-size: 11px; }
  .ai-connection-status p { display: none; }
  .ai-connection-status .btn { margin-left: 0; min-height: 40px; font-size: 10px; padding: 8px; }
  .ai-photo-picker { font-size: 11px; min-height: 42px; }
  .ai-message-photos img { width: 120px; height: 92px; }
  .ai-message-photos span { max-width: 120px; }
  .ai-photo-composer > .flex { gap: 8px; }
  .ai-photo-composer > .flex > small { font-size: 10px; }
  .ai-message-tools .btn { min-height: 40px; }
  .ai-watch-intro, .field-hero { padding: 23px; align-items: flex-start; flex-direction: column; gap: 20px; }
  .ai-watch-intro h2, .field-hero h2 { font-size: 28px; }
  .ai-watch-number { font-size: 42px; text-align: left; }
  .ai-watch-layout > aside, .field-list { grid-template-columns: 1fr; }
  .field-detail { scroll-margin-top: 82px; }
  .field-detail-head, .field-detail > .panel > .panel-body { padding: 21px; }
  .field-detail-head h2 { font-size: 22px; }
  .field-filters button { min-height: 44px; padding-inline: 10px; }
  .field-progress { gap: 26px; }
  .field-progress strong { font-size: 30px; }
  .field-report { padding: 17px; }
  .field-report .form-actions .btn { width: 100%; }
  .field-chat-plan { padding: 15px; }
  .field-chat-plan > .flex { flex-wrap: wrap; }
  .login-screen { display: block; }
  .login-story { padding: 25px 22px; min-height: 0; }
  .login-story .brand { margin: 0; }
  .login-story h1, .login-story p, .login-story-copy, .login-art, .login-foot { display: none; }
  .login-main { padding: 35px 24px; min-height: calc(100dvh - 90px); align-items: flex-start; }
  .login-form { max-width: 430px; }
  .login-form h2 { font-size: 34px; }
  .registration { margin: 20px auto; padding: 18px; }
  .registration .panel-body { padding: 20px; }
  .footer { gap: 14px; flex-wrap: wrap; font-size: 9px; margin-top: 26px; }
  .mobile-nav, .bottom-nav { display: flex; position: fixed; inset: auto 0 0; z-index: 35; justify-content: space-around; align-items: stretch; padding: 7px 6px max(8px,env(safe-area-inset-bottom)); background: #fff; border-top: 1px solid #e3e7f2; box-shadow: none; }
  .mobile-nav button, .bottom-nav button { display: flex; flex: 1; min-width: 0; min-height: 48px; align-items: center; justify-content: center; flex-direction: column; gap: 4px; background: transparent; border: 0; padding: 5px 6px; color: #6d7b92; border-radius: 10px; font-size: 10px; font-weight: 550; }
  .mobile-nav button svg { width: 20px; height: 20px; }
  .mobile-nav button.active, .bottom-nav button.active { background: #efedff; color: var(--primary); font-weight: 700; }
  .mobile-nav button:hover { background: #f5f3ff; }
  #toast { bottom: calc(82px + env(safe-area-inset-bottom)); }
}
@media (max-width: 380px) {
  .content { padding-inline: 12px; }
  .topbar { padding-inline: 12px; gap: 8px; }
  .mobile-page-title { max-width: 106px; font-size: 13px; }
  .top-actions { gap: 7px; }
  .local-preview-badge { max-width: 65px; font-size: 8px; }
  .cockpit-priority { padding: 15px; }
  .cockpit-priority .priority-icon { width: 37px; height: 37px; }
  .cockpit-priority-copy { flex-basis: calc(100% - 48px); }
  .cockpit-priority > .btn { margin-left: 0; max-width: 100%; width: 100%; }
  .section-actions .btn { font-size: 10px; padding-inline: 8px; }
  .scenario-card-footer { flex-wrap: wrap; }
  .stat-icon { display: none; }
  .simulation-stats { grid-template-columns: 1fr; }
  .simulation-stats .stat-number { font-size: 26px; }
  .simulation-stats .stat-label { min-height: 0; }
  .scenario-figures { gap: 10px; }
  .scenario-figures strong { font-size: 19px; }
  .company-next { flex-wrap: wrap; }
  .ai-page-head h1 { font-size: 20px; }
  .ai-composer-status { display: none; }
  .ai-character-count { font-size: 9px; }
  .field-progress { gap: 22px; }
  .onboarding { gap: 12px; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { scroll-behavior: auto !important; animation-duration: .001ms !important; animation-iteration-count: 1 !important; transition-duration: .001ms !important; }
}
