:root {
  color: #142923;
  background: #f2f4ef;
  font-family: Inter, "Segoe UI", Arial, sans-serif;
  font-synthesis: none;
  --ink: #142923;
  --muted: #68746f;
  --line: #dfe5de;
  --paper: #fbfcf8;
  --green: #176e54;
  --green-soft: #e5f4ed;
  --coral: #e7795f;
  --nav: #102721;
  --shadow: 0 12px 36px rgba(24, 48, 41, 0.06);
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body { margin: 0; min-width: 320px; min-height: 100vh; background: #f2f4ef; color: var(--ink); }
button, select { font: inherit; }
button { cursor: pointer; }
code, pre { font-family: ui-monospace, SFMono-Regular, Consolas, monospace; }

.app-shell { min-height: 100vh; display: grid; grid-template-columns: 242px minmax(0, 1fr); }
.sidebar {
  position: sticky; top: 0; height: 100vh; padding: 26px 18px 20px; background: var(--nav); color: #edf5f0;
  display: flex; flex-direction: column; z-index: 30;
}
.brand { display: flex; align-items: center; gap: 12px; padding: 0 8px 28px; }
.brand-mark { width: 34px; height: 34px; border: 1px solid rgba(255,255,255,.16); border-radius: 10px; display: flex; align-items: center; justify-content: center; gap: 2px; transform: rotate(-4deg); }
.brand-mark span { width: 5px; border-radius: 4px; background: #6ec5a8; transform: rotate(22deg); }
.brand-mark span:nth-child(1) { height: 11px; }
.brand-mark span:nth-child(2) { height: 18px; background: #fff5ce; }
.brand-mark span:nth-child(3) { height: 13px; background: #e78d72; }
.brand strong { display: block; font: 700 17px/1 Inter, "Segoe UI", sans-serif; letter-spacing: -.4px; }
.brand small { display: block; margin-top: 5px; color: #7f9d93; font-size: 10px; text-transform: uppercase; letter-spacing: 1.3px; }
.nav-label { padding: 0 12px; margin: 4px 0 9px; color: #658379; font-size: 10px; font-weight: 700; text-transform: uppercase; letter-spacing: 1.5px; }
.nav-label.second { margin-top: 28px; }
.nav-item { width: 100%; height: 43px; padding: 0 11px; margin: 3px 0; border: 0; border-radius: 8px; display: flex; align-items: center; gap: 11px; color: #94aaa3; background: transparent; text-align: left; font-size: 13px; transition: .2s ease; }
.nav-item:hover { color: white; background: rgba(255,255,255,.04); }
.nav-item.is-active { color: white; background: #1c3a32; box-shadow: inset 2px 0 #6ec5a8; }
.nav-icon { width: 20px; color: #77988d; text-align: center; font-size: 16px; }
.nav-item.is-active .nav-icon { color: #7dd1b4; }
.nav-meta { margin-left: auto; min-width: 20px; height: 20px; display: grid; place-items: center; border-radius: 10px; background: rgba(255,255,255,.08); font-size: 10px; }
.sidebar-foot { margin-top: auto; padding: 16px 8px 2px; border-top: 1px solid rgba(255,255,255,.08); display: grid; grid-template-columns: 31px 1fr auto; align-items: center; gap: 9px; }
.operator-avatar { width: 31px; height: 31px; border-radius: 9px; display: grid; place-items: center; background: #d9a55d; color: #142923; font-size: 10px; font-weight: 800; }
.sidebar-foot strong, .sidebar-foot span { display: block; }
.sidebar-foot strong { font-size: 11px; }
.sidebar-foot span { margin-top: 3px; color: #718e84; font-size: 9px; }
.sidebar-foot .chevron { color: #718e84; font-size: 15px; }

.workspace { min-width: 0; display: flex; flex-direction: column; min-height: 100vh; }
.topbar { height: 66px; padding: 0 clamp(22px, 3vw, 42px); border-bottom: 1px solid var(--line); background: rgba(251,252,248,.88); backdrop-filter: blur(10px); display: flex; align-items: center; justify-content: space-between; position: sticky; top: 0; z-index: 20; }
.breadcrumb { display: flex; gap: 10px; align-items: center; font-size: 12px; }
.breadcrumb span { color: #8b9692; }
.breadcrumb b { color: #c4cbc7; font-weight: 400; }
.breadcrumb strong { font-weight: 600; }
.top-actions { display: flex; gap: 14px; align-items: center; }
.hawaii-clock { padding-right: 16px; border-right: 1px solid var(--line); display: flex; gap: 7px; align-items: center; font-size: 10px; }
.hawaii-clock span { padding: 3px 5px; color: #4b7668; background: #e9efeb; border-radius: 3px; font: 500 9px "DM Mono"; }
.hawaii-clock strong { font-size: 10px; font-weight: 600; }
.status-badge { width: fit-content; padding: 5px 8px; border-radius: 999px; display: inline-flex; align-items: center; gap: 6px; white-space: nowrap; color: #33705d; background: var(--green-soft); font-size: 9px; font-weight: 700; text-transform: uppercase; letter-spacing: .45px; }
.status-badge.danger { color: #a64339; background: #fbe8e5; }
.status-badge.warning { color: #9a6c1b; background: #fff3d8; }
.status-dot { width: 5px; height: 5px; border-radius: 50%; background: #47a082; box-shadow: 0 0 0 3px rgba(71,160,130,.12); }
.danger .status-dot { background: #d76055; }
.warning .status-dot { background: #d69d34; }
.icon-button { width: 34px; height: 34px; padding: 0; border: 1px solid var(--line); border-radius: 8px; position: relative; display: grid; place-items: center; background: white; color: var(--ink); font-size: 17px; }
.icon-button i { min-width: 14px; height: 14px; padding: 0 3px; border-radius: 7px; position: absolute; right: -4px; top: -5px; display: grid; place-items: center; background: var(--coral); color: white; font: normal 700 8px "DM Sans"; }
.mobile-menu { display: none; border: 0; background: transparent; font-size: 20px; }

.content { width: 100%; max-width: 1540px; margin: 0 auto; padding: 38px clamp(22px, 3vw, 44px) 50px; }
.hero { display: flex; justify-content: space-between; gap: 30px; align-items: flex-end; margin-bottom: 30px; }
.eyebrow, .panel-kicker { color: #77827e; font-size: 9px; font-weight: 700; text-transform: uppercase; letter-spacing: 1.45px; }
.eyebrow { display: flex; align-items: center; gap: 8px; color: #437867; }
.eyebrow-line { width: 23px; height: 1px; background: #5b9d87; }
h1, h2 { font-family: "Manrope", sans-serif; }
.hero h1, .page-heading h1 { margin: 10px 0 7px; font-size: clamp(27px, 3vw, 39px); line-height: 1.08; letter-spacing: -1.6px; }
.hero p, .page-heading p { max-width: 690px; margin: 0; color: var(--muted); font-size: 13px; line-height: 1.6; }
.hero-action { display: flex; flex-direction: column; align-items: flex-end; gap: 8px; }
.last-run { color: #89938f; font-size: 9px; }
.primary-button, .secondary-button { border-radius: 8px; font-weight: 700; transition: .2s ease; }
.primary-button { min-height: 42px; padding: 0 18px; border: 0; color: white; background: var(--green); box-shadow: 0 7px 18px rgba(23,110,84,.2); font-size: 11px; }
.primary-button:hover { transform: translateY(-1px); background: #105d46; }
.primary-button:disabled { opacity: .75; cursor: wait; transform: none; }
.button-play { margin-right: 7px; font-size: 8px; }
.secondary-button { min-height: 34px; padding: 0 12px; border: 1px solid var(--line); color: #395148; background: white; font-size: 10px; }
.secondary-button:hover { border-color: #9ab5ac; background: #f6f9f6; }
.spinner { width: 13px; height: 13px; margin-right: 8px; display: inline-block; border: 2px solid rgba(255,255,255,.35); border-top-color: white; border-radius: 50%; animation: spin .7s linear infinite; vertical-align: -3px; }
@keyframes spin { to { transform: rotate(360deg); } }

.metrics-grid { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 11px; margin-bottom: 17px; }
.metric-card { min-width: 0; min-height: 92px; padding: 17px; border: 1px solid var(--line); border-radius: 9px; display: flex; gap: 12px; align-items: flex-start; background: var(--paper); box-shadow: 0 5px 15px rgba(24,48,41,.025); }
.metric-icon { width: 28px; height: 28px; flex: 0 0 28px; border-radius: 7px; display: grid; place-items: center; color: #536d64; background: #e9eeea; font-size: 13px; font-weight: 800; }
.metric-card.mint .metric-icon { color: #267257; background: #dcf1e9; }
.metric-card.blue .metric-icon { color: #3f668e; background: #e2eaf3; }
.metric-card.sand .metric-icon { color: #97723a; background: #f4ead8; }
.metric-card.violet .metric-icon { color: #6f6685; background: #eae7ef; }
.metric-card.danger .metric-icon { color: #b5473c; background: #f8dfdc; }
.metric-card span, .metric-card strong, .metric-card small { display: block; min-width: 0; }
.metric-card span { color: #7c8783; font-size: 9px; font-weight: 700; text-transform: uppercase; letter-spacing: .6px; }
.metric-card strong { margin-top: 4px; font: 700 19px "Manrope"; letter-spacing: -.7px; }
.metric-card small { margin-top: 3px; overflow: hidden; color: #89938f; font-size: 9px; white-space: nowrap; text-overflow: ellipsis; }

.panel { border: 1px solid var(--line); border-radius: 10px; background: var(--paper); box-shadow: var(--shadow); }
.panel-header { min-height: 71px; padding: 18px 21px; border-bottom: 1px solid var(--line); display: flex; justify-content: space-between; align-items: center; gap: 20px; }
.panel-header.compact { min-height: 64px; }
.panel-header h2 { margin: 4px 0 0; font-size: 16px; letter-spacing: -.45px; }
.runner-panel { margin-bottom: 17px; }
.scenario-id { padding: 7px 9px; color: #73807b; background: #eef1ed; border-radius: 5px; font: 500 8px "DM Mono"; letter-spacing: .5px; }
.scenario-id strong { color: #47685d; }
.control-grid { padding: 19px 21px 15px; display: grid; grid-template-columns: repeat(3, 1fr); gap: 15px; }
.control-grid label > span { display: block; margin-bottom: 7px; color: #596a64; font-size: 9px; font-weight: 700; text-transform: uppercase; letter-spacing: .7px; }
.control-grid select { width: 100%; height: 39px; padding: 0 36px 0 12px; border: 1px solid #d7ded8; border-radius: 7px; color: var(--ink); background: white; font-size: 11px; outline: none; }
.control-grid select:focus { border-color: #599d85; box-shadow: 0 0 0 3px rgba(89,157,133,.1); }
.control-grid small { display: block; margin: 6px 2px 0; color: #929b98; font-size: 8px; }
.payload-bar { margin: 0 21px 18px; min-height: 38px; padding: 0 11px; border-radius: 6px; display: flex; justify-content: space-between; align-items: center; color: #b6c7c0; background: #1a2c27; }
.payload-bar div, .modal-endpoint { display: flex; align-items: center; gap: 9px; }
.method { padding: 4px 6px; border-radius: 3px; color: #b7e8d5; background: rgba(92,181,149,.16); font: 500 8px "DM Mono"; }
.payload-bar code { font-size: 9px; }
.text-button { padding: 5px; border: 0; color: #4c806f; background: transparent; font-size: 9px; font-weight: 700; }
.payload-bar .text-button { color: #b7dacf; }
.text-button span { margin-left: 3px; }

.pipeline-panel { margin-bottom: 17px; overflow: hidden; }
.pipeline { min-height: 230px; padding: 22px; display: grid; grid-template-columns: minmax(120px,1fr) 64px minmax(120px,1fr) 64px minmax(130px,1.12fr) 70px minmax(180px,1.25fr); align-items: stretch; }
.pipeline-step { min-width: 0; padding: 13px; border: 1px solid #e2e6e2; border-radius: 8px; background: #f8f9f6; display: flex; flex-direction: column; align-items: center; text-align: center; }
.pipeline-step.featured { border-color: #a8cabb; background: #f2f8f5; box-shadow: inset 0 0 0 1px rgba(64,133,107,.07); }
.step-top { width: 100%; display: flex; justify-content: space-between; align-items: center; }
.step-number { color: #9aa4a0; font: 500 8px "DM Mono"; }
.step-state { color: #318064; font-size: 7px; font-weight: 700; text-transform: uppercase; letter-spacing: .5px; }
.step-state.danger { color: #b64f43; }
.channel-logo, .domain-icon { width: 39px; height: 39px; margin: 16px 0 10px; border-radius: 10px; display: grid; place-items: center; color: white; background: var(--channel-color); font: 800 15px "Manrope"; box-shadow: 0 5px 12px rgba(31,48,42,.12); }
.domain-icon { color: #2a6d58; background: #dceee7; }
.domain-icon.lock { color: white; background: #276f57; }
.pipeline-step > strong { font: 700 12px "Manrope"; }
.pipeline-step > span:not(.step-number):not(.step-state) { margin-top: 4px; color: #77837e; font-size: 9px; }
.pipeline-step > code { max-width: 100%; margin-top: 13px; padding: 5px 7px; border-radius: 4px; overflow: hidden; color: #64756f; background: #eaefeb; font-size: 7px; text-overflow: ellipsis; }
.connector { display: flex; flex-direction: column; justify-content: center; align-items: center; }
.connector span { width: 100%; height: 1px; background: #cbd5d0; position: relative; }
.connector span::after { content: ""; position: absolute; right: -1px; top: -3px; width: 5px; height: 5px; border-top: 1px solid #91a098; border-right: 1px solid #91a098; transform: rotate(45deg); }
.connector b { margin-top: 7px; color: #9aa49f; font: 500 7px "DM Mono"; letter-spacing: .7px; }
.pipeline-targets { padding: 2px 0; display: flex; flex-direction: column; justify-content: center; gap: 8px; }
.target-row { min-width: 0; padding: 10px; border: 1px solid #e2e6e2; border-radius: 8px; display: grid; grid-template-columns: 28px minmax(0,1fr) auto; gap: 9px; align-items: center; background: #f8f9f6; }
.channel-dot { width: 28px; height: 28px; border-radius: 7px; display: grid; place-items: center; color: #172a24; background: var(--channel-color); font-size: 10px; font-weight: 800; }
.target-row strong, .target-row span { display: block; }
.target-row strong { font-size: 9px; }
.target-row > div span { margin-top: 2px; color: #8a9490; font: 400 7px "DM Mono"; }
.target-row .status-badge { padding: 4px 6px; font-size: 7px; }

.two-column { display: grid; grid-template-columns: 1.14fr .86fr; gap: 17px; margin-bottom: 17px; }
.proof-card, .requirements-card { min-width: 0; }
.score { width: 44px; height: 28px; border-radius: 6px; display: grid; place-items: center; color: #26745a; background: #e4f2ec; font: 600 9px "DM Mono"; }
.race-visual { padding: 15px 20px; }
.request-row { min-height: 48px; padding: 8px 11px; border: 1px solid #e3e7e3; display: grid; grid-template-columns: 29px 1fr auto; gap: 10px; align-items: center; background: #f8f9f6; }
.request-row:first-child { border-radius: 7px 7px 0 0; }
.request-row:last-child { margin-top: -1px; border-radius: 0 0 7px 7px; }
.request-row.winner { border-left: 2px solid #46977b; }
.request-row.rejected { border-left: 2px solid #d88a74; }
.request-source { width: 27px; height: 27px; border-radius: 7px; display: grid; place-items: center; color: #46665b; background: #e4ece7; font-weight: 800; font-size: 10px; }
.request-row strong, .request-row span { display: block; }
.request-row strong { font-size: 9px; }
.request-row span { margin-top: 3px; color: #8b9490; font: 400 7px "DM Mono"; }
.request-result { text-align: right; }
.winner .request-result strong { color: #28775c; }
.rejected .request-result strong { color: #b75c49; }
.proof-footer { min-height: 45px; padding: 9px 20px; border-top: 1px solid var(--line); display: flex; align-items: center; gap: 18px; color: #68756f; font-size: 8px; }
.proof-footer i { color: #368064; font-style: normal; }
.proof-footer .text-button { margin-left: auto; }
.coverage-ring { width: 40px; height: 40px; border: 4px solid #5aa288; border-left-color: #dfe9e4; border-radius: 50%; display: grid; place-items: center; color: #3a705e; font: 700 8px "DM Mono"; transform: rotate(-20deg); }
.coverage-ring::first-line { transform: rotate(20deg); }
.requirement-list { padding: 6px 20px 10px; }
.requirement-row { min-height: 48px; display: grid; grid-template-columns: 22px 1fr auto; gap: 9px; align-items: center; border-bottom: 1px solid #e8ebe8; }
.requirement-row:last-child { border-bottom: 0; }
.check-circle { width: 19px; height: 19px; border-radius: 50%; display: grid; place-items: center; color: #2d795e; background: #e2f1eb; font-size: 9px; font-weight: 800; }
.requirement-row strong, .requirement-row span { display: block; }
.requirement-row strong { font-size: 9px; }
.requirement-row div span { margin-top: 3px; color: #8a9490; font-size: 7px; }
.requirement-row code { color: #6e7e78; font-size: 7px; }

.log-panel { overflow: hidden; }
.log-actions { display: flex; align-items: center; gap: 10px; color: #8d9693; font-size: 9px; }
.table-wrap { overflow-x: auto; }
table { width: 100%; border-collapse: collapse; font-size: 9px; }
th { height: 34px; padding: 0 13px; color: #87918d; background: #f0f3ef; text-align: left; text-transform: uppercase; letter-spacing: .6px; font-size: 7px; }
td { height: 48px; padding: 8px 13px; border-top: 1px solid #e5e9e5; color: #65736e; white-space: nowrap; }
td strong, td span { display: block; }
td strong { color: #2a3b35; font-size: 9px; }
td span { margin-top: 2px; color: #929b97; font: 400 7px "DM Mono"; }
td code { padding: 3px 5px; border-radius: 3px; background: #edf0ed; font-size: 7px; }
td .code-danger { color: #ac463d; background: #f8e6e3; }
td .code-success { color: #2a785c; background: #e2f1eb; }
.key-code { color: #5a6f67; }
.empty-cell { height: 120px; color: #8d9693; text-align: center; }

.page-heading { display: flex; justify-content: space-between; align-items: flex-end; gap: 30px; margin-bottom: 26px; }
.page-heading h1 { font-size: 31px; }
.adapter-grid { display: grid; grid-template-columns: repeat(2,1fr); gap: 17px; margin-bottom: 17px; }
.adapter-card { padding: 21px; min-width: 0; }
.adapter-heading { display: grid; grid-template-columns: 41px 1fr auto; gap: 12px; align-items: center; }
.adapter-heading .domain-icon { margin: 0; }
.adapter-heading h2 { margin: 0 0 4px; font-size: 15px; }
.adapter-heading code { color: #7d8a85; font-size: 8px; }
pre { max-height: 310px; margin: 20px 0; padding: 17px; overflow: auto; border-radius: 8px; color: #b8d2c9; background: #172923; font-size: 9px; line-height: 1.65; }
.adapter-output { padding: 12px; border: 1px solid #dbe5df; border-radius: 7px; background: #f2f7f4; display: grid; grid-template-columns: auto 1fr auto; gap: 12px; align-items: center; }
.adapter-output span { color: #80908a; font-size: 8px; }
.adapter-output strong { font-size: 9px; }
.adapter-output code { color: #507367; font-size: 7px; }
.mapping-test { min-height: 115px; padding: 20px 22px; display: flex; justify-content: space-between; align-items: center; gap: 25px; }
.mapping-test h2 { margin: 4px 0; font-size: 15px; }
.mapping-test p { margin: 0; color: #77827e; font-size: 10px; }
.error-result { min-width: 370px; padding: 13px; border: 1px solid #ecd8c8; border-radius: 8px; display: grid; grid-template-columns: 30px 1fr auto; gap: 10px; align-items: center; background: #fff8ed; }
.error-icon { width: 29px; height: 29px; border-radius: 8px; display: grid; place-items: center; color: #9a5e28; background: #f8e1bf; font-weight: 800; }
.error-result strong, .error-result span { display: block; }
.error-result strong { font: 500 8px "DM Mono"; }
.error-result div span { margin-top: 4px; color: #907a68; font-size: 8px; }

.inventory-layout { display: grid; grid-template-columns: 1.15fr .85fr; gap: 17px; margin-bottom: 17px; }
.room-card { overflow: hidden; display: grid; grid-template-columns: 42% 1fr; min-height: 260px; }
.room-art { min-height: 260px; padding: 18px; overflow: hidden; position: relative; color: rgba(255,255,255,.85); background: linear-gradient(175deg,#6caeaa 0%,#b8d7c7 55%,#e1c085 56%,#b6844e 100%); font-size: 8px; letter-spacing: 1.4px; }
.sun { width: 64px; height: 64px; border-radius: 50%; position: absolute; right: 18%; top: 18%; background: rgba(255,241,183,.78); box-shadow: 0 0 60px #fff0aa; }
.island { width: 170%; height: 70%; position: absolute; left: -25%; bottom: -40%; border-radius: 50%; background: #225d4b; transform: rotate(-5deg); box-shadow: 0 -12px 0 rgba(22,83,65,.45); }
.room-copy { padding: 32px; }
.room-copy h2 { margin: 8px 0 4px; font-size: 23px; letter-spacing: -.8px; }
.room-copy > code { color: #6d8078; font-size: 9px; }
.room-facts { margin-top: 28px; display: grid; grid-template-columns: repeat(3,1fr); gap: 10px; }
.room-facts span { padding-top: 10px; border-top: 1px solid var(--line); color: #8a9490; font-size: 8px; }
.room-facts b { display: block; margin-top: 5px; color: #243831; font-size: 10px; }
.mapping-panel { padding-bottom: 10px; }
.mapping-count { color: #34735e; font: 600 12px "DM Mono"; }
.mapping-row { min-height: 56px; margin: 10px 17px; padding: 8px; border: 1px solid #e1e6e1; border-radius: 8px; display: grid; grid-template-columns: 33px 1fr auto; gap: 10px; align-items: center; }
.mapping-row.source { border-color: #edc999; background: #fffaf1; }
.channel-logo.mini { width: 32px; height: 32px; margin: 0; font-size: 11px; }
.mapping-row strong, .mapping-row code { display: block; }
.mapping-row strong { font-size: 9px; }
.mapping-row code { margin-top: 3px; color: #8a9490; font-size: 7px; }
.mapping-row > span { color: #507468; font-size: 8px; font-weight: 700; }
.inventory-ledger { overflow: hidden; }
.ledger-row { min-height: 49px; padding: 8px 20px; border-top: 1px solid var(--line); display: grid; grid-template-columns: 25px 120px 1fr 50px 75px; gap: 15px; align-items: center; font-size: 8px; }
.ledger-row > span { width: 20px; height: 20px; border-radius: 50%; display: grid; place-items: center; background: #ebefeb; }
.ledger-row code { font-size: 7px; }
.ledger-row strong { font-weight: 500; }
.ledger-row em { padding: 4px; border-radius: 4px; text-align: center; font: normal 700 7px "DM Mono"; }
.ledger-row em.good { color: #267055; background: #e2f1ea; }
.ledger-row em.bad { color: #a85042; background: #f8e6e1; }

.alerts-panel { min-height: 320px; }
.alert-row { min-height: 132px; padding: 23px; border-bottom: 1px solid var(--line); display: grid; grid-template-columns: 39px 1fr auto; gap: 16px; align-items: start; }
.alert-row:last-child { border-bottom: 0; }
.alert-symbol { width: 39px; height: 39px; border-radius: 10px; display: grid; place-items: center; color: #a84c40; background: #f8e4e0; font-weight: 800; }
.alert-row h2 { margin: 5px 0; font-size: 15px; }
.alert-row p { margin: 0 0 8px; color: #7a8581; font-size: 9px; }
.alert-row code { color: #8f5f57; font-size: 7px; }
.alert-meta { display: flex; flex-direction: column; align-items: flex-end; gap: 8px; color: #8d9693; font-size: 8px; }
.empty-state { min-height: 320px; display: flex; flex-direction: column; align-items: center; justify-content: center; text-align: center; }
.empty-icon { width: 48px; height: 48px; border-radius: 50%; display: grid; place-items: center; color: #2c765b; background: #e2f1eb; font-size: 17px; }
.empty-state h2 { margin: 14px 0 4px; font-size: 15px; }
.empty-state p { margin: 0 0 16px; color: #89938f; font-size: 9px; }

.toast { max-width: calc(100vw - 30px); padding: 11px 15px; border-radius: 8px; position: fixed; z-index: 100; right: 24px; bottom: 24px; color: white; background: #176e54; box-shadow: 0 12px 30px rgba(20,41,35,.2); font-size: 10px; opacity: 0; transform: translateY(12px); pointer-events: none; transition: .25s ease; }
.toast.warning { background: #986428; }
.toast.is-visible { opacity: 1; transform: translateY(0); }
.modal-backdrop { position: fixed; inset: 0; z-index: 90; padding: 20px; display: grid; place-items: center; background: rgba(11,29,24,.55); backdrop-filter: blur(5px); }
.modal { width: min(600px,100%); max-height: calc(100vh - 40px); padding: 23px; overflow: auto; border-radius: 12px; background: var(--paper); box-shadow: 0 30px 80px rgba(10,30,24,.3); }
.modal-header { display: flex; justify-content: space-between; align-items: flex-start; }
.modal-header h2 { margin: 5px 0 0; font-size: 19px; }
.modal-endpoint { margin-top: 20px; padding: 10px; border-radius: 6px; color: #c3d5ce; background: #1a2c27; }
.modal-endpoint code { font-size: 9px; }
.modal pre { max-height: 360px; }
.modal-note { padding: 13px; border: 1px solid #dce7e1; border-radius: 8px; display: flex; gap: 12px; color: #3c705e; background: #f0f7f3; }
.modal-note > span { font-size: 21px; }
.modal-note strong { font-size: 10px; }
.modal-note p { margin: 3px 0 0; color: #74847e; font-size: 8px; line-height: 1.5; }
footer { margin-top: auto; min-height: 50px; padding: 0 clamp(22px, 3vw, 44px); border-top: 1px solid var(--line); display: flex; justify-content: space-between; align-items: center; color: #8f9894; font-size: 8px; }

@media (max-width: 1180px) {
  .metrics-grid { grid-template-columns: repeat(3,1fr); }
  .pipeline { grid-template-columns: 1fr 45px 1fr 45px 1fr; }
  .pipeline .split { display: none; }
  .pipeline-targets { grid-column: 1 / -1; margin-top: 12px; display: grid; grid-template-columns: repeat(2,1fr); }
}

@media (max-width: 900px) {
  .app-shell { grid-template-columns: 1fr; }
  .sidebar { position: fixed; left: -250px; transition: left .25s ease; box-shadow: 20px 0 60px rgba(10,30,24,.2); }
  .sidebar-open .sidebar { left: 0; }
  .mobile-menu { display: block; }
  .breadcrumb { margin-right: auto; margin-left: 10px; }
  .hawaii-clock { display: none; }
  .two-column, .inventory-layout { grid-template-columns: 1fr; }
  .adapter-output { grid-template-columns: 1fr; }
}

@media (max-width: 700px) {
  .topbar { padding: 0 15px; }
  .top-actions > .status-badge { display: none; }
  .content { padding: 27px 15px 40px; }
  .hero, .page-heading { align-items: stretch; flex-direction: column; }
  .hero-action { align-items: stretch; }
  .metrics-grid { grid-template-columns: repeat(2,1fr); }
  .control-grid { grid-template-columns: 1fr; }
  .pipeline { grid-template-columns: 1fr; gap: 8px; }
  .connector { height: 30px; transform: rotate(90deg); }
  .pipeline-targets { grid-column: auto; grid-template-columns: 1fr; }
  .two-column, .adapter-grid { grid-template-columns: 1fr; }
  .proof-footer { flex-wrap: wrap; }
  .proof-footer .text-button { margin-left: 0; }
  .room-card { grid-template-columns: 1fr; }
  .room-art { min-height: 190px; }
  .room-facts { grid-template-columns: 1fr; }
  .mapping-test { align-items: stretch; flex-direction: column; }
  .error-result { min-width: 0; }
  .ledger-row { grid-template-columns: 25px 1fr 55px; }
  .ledger-row strong, .ledger-row code:nth-child(2) { display: none; }
  footer { padding: 15px; gap: 10px; align-items: flex-start; flex-direction: column; }
}

@media (max-width: 430px) {
  .breadcrumb span, .breadcrumb b { display: none; }
  .metrics-grid { grid-template-columns: 1fr; }
  .payload-bar { align-items: flex-start; flex-direction: column; padding: 10px; }
  .request-row { grid-template-columns: 28px 1fr; }
  .request-result { grid-column: 2; text-align: left; }
  .requirement-row { grid-template-columns: 22px 1fr; }
  .requirement-row code { display: none; }
}
