:root {
  color-scheme: dark;
  --bg: #07101f;
  --bg-deep: #050b16;
  --sidebar: rgba(8, 20, 38, .94);
  --panel: rgba(15, 31, 55, .76);
  --panel-solid: #10223c;
  --panel-soft: rgba(24, 45, 75, .58);
  --line: rgba(139, 170, 211, .16);
  --line-strong: rgba(126, 164, 217, .28);
  --text: #edf5ff;
  --muted: #91a5c1;
  --muted-2: #667b99;
  --blue: #377ffc;
  --blue-bright: #61a2ff;
  --cyan: #30cfdf;
  --green: #25cc91;
  --amber: #f4b347;
  --red: #ff6175;
  --shadow: 0 24px 70px rgba(0, 0, 0, .32);
  --radius-xl: 28px;
  --radius-lg: 20px;
  --radius-md: 14px;
  --sidebar-width: 256px;
  font-family: Inter, ui-sans-serif, -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Microsoft YaHei", sans-serif;
}

* { box-sizing: border-box; }
html { min-height: 100%; background: var(--bg-deep); }
body { min-height: 100vh; margin: 0; color: var(--text); background: radial-gradient(circle at 74% -10%, #17396b 0, transparent 31%), linear-gradient(145deg, #07101e 0%, #09162a 52%, #07101f 100%); }
button, input, select { font: inherit; }
button { color: inherit; }
button:focus-visible, input:focus-visible, select:focus-visible { outline: 2px solid var(--blue-bright); outline-offset: 2px; }
svg { width: 100%; height: 100%; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.is-hidden { display: none !important; }
.ambient { position: fixed; pointer-events: none; border-radius: 50%; filter: blur(90px); opacity: .18; z-index: 0; }
.ambient-one { width: 28rem; height: 28rem; background: #1e77ff; top: -12rem; right: 8%; }
.ambient-two { width: 22rem; height: 22rem; background: #11c4c2; bottom: -10rem; left: 18%; opacity: .09; }

.login-layer { position: fixed; inset: 0; z-index: 50; display: grid; place-items: center; padding: 24px; background: rgba(3, 9, 18, .72); backdrop-filter: blur(18px); }
.login-card { width: min(440px, 100%); display: grid; gap: 20px; padding: 34px; border: 1px solid var(--line-strong); border-radius: 30px; background: linear-gradient(150deg, rgba(19, 42, 73, .97), rgba(8, 20, 38, .98)); box-shadow: var(--shadow); }
.login-mark, .brand-mark { display: grid; place-items: center; background: linear-gradient(135deg, var(--blue), #2963e4); color: white; box-shadow: 0 12px 30px rgba(55, 127, 252, .28); }
.login-mark { width: 64px; height: 64px; padding: 15px; border-radius: 20px; }
.login-card h1 { margin: 5px 0 7px; font-size: 30px; letter-spacing: -.035em; }
.login-card label, .dialog-shell label { display: grid; gap: 8px; color: #bac8da; font-size: 13px; font-weight: 650; }
input, select { width: 100%; min-height: 46px; padding: 0 14px; border: 1px solid var(--line-strong); border-radius: 12px; color: var(--text); background: rgba(6, 16, 31, .8); }
input::placeholder { color: #5f7593; }
.form-error { min-height: 18px; margin: -6px 0; color: #ff93a1; font-size: 13px; }

.app-shell { position: relative; z-index: 1; min-height: 100vh; }
.sidebar { position: fixed; inset: 0 auto 0 0; z-index: 20; width: var(--sidebar-width); display: flex; flex-direction: column; padding: 26px 18px 18px; border-right: 1px solid var(--line); background: var(--sidebar); backdrop-filter: blur(22px); }
.brand { display: flex; align-items: center; gap: 13px; padding: 0 10px 24px; }
.brand-mark { width: 44px; height: 44px; flex: 0 0 auto; padding: 10px; border-radius: 14px; }
.brand strong { display: block; font-size: 18px; letter-spacing: -.02em; }
.brand small { display: block; margin-top: 3px; color: var(--muted); font-size: 11px; letter-spacing: .08em; }
.app-nav { display: grid; gap: 6px; }
.nav-item { position: relative; display: flex; align-items: center; gap: 13px; min-height: 49px; padding: 0 14px; border: 0; border-radius: 13px; background: transparent; color: var(--muted); cursor: pointer; text-align: left; transition: .2s ease; }
.nav-item b { width: 23px; color: #8198b7; font-size: 20px; font-weight: 500; text-align: center; }
.nav-item span { font-size: 14px; font-weight: 650; }
.nav-item:hover { color: var(--text); background: rgba(77, 117, 176, .1); }
.nav-item.is-active { color: #fff; background: linear-gradient(100deg, rgba(55, 127, 252, .27), rgba(55, 127, 252, .1)); box-shadow: inset 3px 0 0 var(--blue); }
.nav-item.is-active b { color: var(--blue-bright); }
.sidebar-foot { margin-top: auto; display: flex; align-items: center; justify-content: space-between; padding: 16px 10px 3px; border-top: 1px solid var(--line); }
.service-dot { display: flex; align-items: center; gap: 8px; color: var(--muted); font-size: 11px; }
.service-dot i, .health-chip i, .mode-pill i, .live-badge i { width: 7px; height: 7px; border-radius: 50%; background: var(--green); box-shadow: 0 0 0 4px rgba(37, 204, 145, .12); }
.text-button { border: 0; padding: 4px; color: var(--blue-bright); background: transparent; cursor: pointer; font-size: 12px; }

.main-area { min-height: 100vh; margin-left: var(--sidebar-width); }
.topbar { position: sticky; top: 0; z-index: 15; min-height: 92px; display: flex; align-items: center; justify-content: space-between; gap: 24px; padding: 18px 34px; border-bottom: 1px solid var(--line); background: rgba(7, 17, 32, .78); backdrop-filter: blur(22px); }
.topbar h1 { margin: 3px 0 0; font-size: 25px; letter-spacing: -.03em; }
.breadcrumb, .eyebrow, .kicker { margin: 0; color: #6f88a9; font-size: 10px; font-weight: 750; letter-spacing: .17em; text-transform: uppercase; }
.top-actions { display: flex; align-items: center; gap: 10px; }
.button { min-height: 42px; padding: 0 17px; border: 1px solid transparent; border-radius: 12px; cursor: pointer; font-size: 13px; font-weight: 720; transition: transform .18s ease, background .18s ease, border .18s ease; }
.button:hover { transform: translateY(-1px); }
.button.primary { color: white; background: linear-gradient(135deg, #347efc, #2865e8); box-shadow: 0 10px 25px rgba(55, 127, 252, .25); }
.button.ghost { border-color: var(--line-strong); background: rgba(17, 35, 59, .6); }
.button.soft { color: #a9cbff; border-color: rgba(68, 137, 255, .2); background: rgba(55, 127, 252, .11); }
.button.danger { color: white; background: linear-gradient(135deg, #f3566b, #c83c53); }
.button.full { width: 100%; }
.button:disabled { opacity: .45; cursor: not-allowed; transform: none; }
.mode-pill, .live-badge, .security-note { display: inline-flex; align-items: center; gap: 8px; min-height: 34px; padding: 0 12px; border: 1px solid rgba(244, 179, 71, .2); border-radius: 999px; color: #ffd28b; background: rgba(244, 179, 71, .08); font-size: 11px; font-weight: 700; }
.mode-pill i { background: var(--amber); box-shadow: 0 0 0 4px rgba(244, 179, 71, .11); }
.mode-pill.neutral { color: #a7bad2; border-color: var(--line); background: rgba(86, 111, 148, .09); }
.live-badge { color: #7ce2bd; border-color: rgba(37, 204, 145, .2); background: rgba(37, 204, 145, .08); }
.security-note { color: #9fb5d0; border-color: var(--line); background: var(--panel-soft); }

.content { width: min(1500px, 100%); margin: 0 auto; padding: 30px 34px 60px; }
.view { display: none; animation: view-in .24s ease; }
.view.is-active { display: block; }
@keyframes view-in { from { opacity: 0; transform: translateY(6px); } to { opacity: 1; transform: none; } }
.panel { border: 1px solid var(--line); border-radius: var(--radius-lg); background: linear-gradient(150deg, rgba(18, 38, 65, .82), rgba(11, 25, 46, .76)); box-shadow: 0 18px 50px rgba(0, 0, 0, .12); }
.hero { position: relative; min-height: 300px; display: grid; grid-template-columns: minmax(0, 1.35fr) minmax(280px, .65fr); align-items: center; overflow: hidden; padding: 42px 48px; }
.hero::before { content: ""; position: absolute; inset: 0 44% 0 0; background: radial-gradient(circle at 35% 40%, rgba(55, 127, 252, .15), transparent 68%); }
.hero-copy { position: relative; z-index: 2; max-width: 720px; }
.hero h2, .page-intro h2 { margin: 10px 0 12px; font-size: clamp(28px, 4vw, 47px); line-height: 1.08; letter-spacing: -.05em; }
.hero h2 em { color: #77acff; font-style: normal; }
.hero p { max-width: 650px; margin: 0; color: #a7b8ce; font-size: 15px; line-height: 1.8; }
.hero-actions { display: flex; gap: 10px; margin-top: 26px; }
.safety-orbit { position: relative; width: 230px; height: 230px; justify-self: center; border: 1px solid rgba(91, 145, 233, .24); border-radius: 50%; box-shadow: inset 0 0 70px rgba(39, 99, 196, .08); }
.safety-orbit::before, .safety-orbit::after { content: ""; position: absolute; border-radius: 50%; border: 1px dashed rgba(103, 151, 220, .15); }
.safety-orbit::before { inset: 24px; }
.safety-orbit::after { inset: 58px; background: rgba(18, 51, 95, .24); }
.orbit-core { position: absolute; z-index: 2; inset: 77px; display: grid; place-content: center; border: 1px solid rgba(91, 155, 255, .34); border-radius: 50%; background: linear-gradient(145deg, #1c54ad, #0d2e62); box-shadow: 0 0 55px rgba(55, 127, 252, .28); text-align: center; }
.orbit-core strong { font-size: 20px; letter-spacing: .08em; }.orbit-core small { color: #8fb8f7; font-size: 9px; letter-spacing: .2em; }
.orbit-node { position: absolute; z-index: 3; display: grid; place-items: center; width: 48px; height: 28px; border: 1px solid var(--line-strong); border-radius: 20px; color: #a9c2e1; background: #102844; font-size: 10px; }
.node-a { top: -8px; left: 91px; }.node-b { right: -13px; top: 101px; }.node-c { bottom: -8px; left: 91px; }.node-d { left: -13px; top: 101px; }

.health-strip { display: flex; flex-wrap: wrap; gap: 9px; margin: 18px 0; }
.health-chip { display: inline-flex; align-items: center; gap: 9px; min-height: 36px; padding: 0 13px; border: 1px solid var(--line); border-radius: 999px; color: #a6b9d0; background: rgba(14, 30, 52, .72); font-size: 11px; }
.health-chip.warning i { background: var(--amber); box-shadow: 0 0 0 4px rgba(244, 179, 71, .12); }
.health-chip.offline i { background: var(--red); box-shadow: 0 0 0 4px rgba(255, 97, 117, .12); }
.health-chip.loading { opacity: .75; }
.metric-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 14px; margin: 18px 0; }
.metric-grid.compact { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.metric-card { position: relative; min-height: 135px; padding: 22px; overflow: hidden; border: 1px solid var(--line); border-radius: 18px; background: rgba(15, 31, 54, .72); }
.metric-card::after { content: ""; position: absolute; width: 90px; height: 90px; right: -32px; top: -33px; border-radius: 50%; background: rgba(76, 126, 203, .08); }
.metric-card span { display: block; color: var(--muted); font-size: 12px; }.metric-card strong { display: block; margin: 12px 0 5px; font-size: 31px; letter-spacing: -.04em; }.metric-card small { color: #6f86a5; font-size: 11px; }
.accent-blue { border-top-color: rgba(55, 127, 252, .68); }.accent-cyan { border-top-color: rgba(48, 207, 223, .65); }.accent-amber { border-top-color: rgba(244, 179, 71, .65); }.accent-green { border-top-color: rgba(37, 204, 145, .65); }
.split-grid { display: grid; grid-template-columns: 1.15fr .85fr; gap: 16px; }
.section-card { min-height: 340px; padding: 23px; }
.section-head, .page-intro { display: flex; align-items: center; justify-content: space-between; gap: 20px; }
.section-head h3 { margin: 5px 0 0; font-size: 17px; }.page-intro { margin: 3px 0 24px; }.page-intro h2 { margin-bottom: 7px; font-size: 34px; }.page-intro p { margin: 0; color: var(--muted); font-size: 13px; line-height: 1.65; }
.stack-list, .timeline { display: grid; gap: 9px; margin-top: 18px; }
.decision-row { display: grid; grid-template-columns: auto 1fr auto; align-items: center; gap: 13px; padding: 13px; border: 1px solid var(--line); border-radius: 13px; background: rgba(8, 20, 38, .46); }
.decision-icon { width: 34px; height: 34px; display: grid; place-items: center; border-radius: 10px; color: #9cb7da; background: #172e4f; }
.decision-row h4 { margin: 0 0 4px; font-size: 13px; }.decision-row p { margin: 0; color: var(--muted); font-size: 11px; }
.status { display: inline-flex; align-items: center; padding: 5px 9px; border-radius: 999px; font-size: 10px; font-weight: 750; }
.status.remove_local { color: #87b6ff; background: rgba(55, 127, 252, .15); }.status.remove_share { color: #ff9cab; background: rgba(255, 97, 117, .13); }.status.protect_tracking, .status.report_only { color: #6fe1b8; background: rgba(37, 204, 145, .12); }.status.keep_both { color: #c0cee0; background: rgba(141, 164, 195, .12); }
.timeline-entry { position: relative; padding: 4px 0 4px 23px; }.timeline-entry::before { content: ""; position: absolute; left: 4px; top: 10px; width: 7px; height: 7px; border-radius: 50%; background: var(--blue-bright); box-shadow: 0 0 0 4px rgba(55, 127, 252, .12); }.timeline-entry::after { content: ""; position: absolute; left: 7px; top: 22px; bottom: -12px; width: 1px; background: var(--line); }.timeline-entry:last-child::after { display: none; }.timeline-entry strong { display: block; font-size: 12px; }.timeline-entry span { color: var(--muted); font-size: 10px; }
.empty-state { display: grid; place-items: center; min-height: 120px; padding: 20px; color: #66809f; border: 1px dashed var(--line-strong); border-radius: 14px; text-align: center; font-size: 12px; }.empty-state.wide { grid-column: 1 / -1; min-height: 230px; }

.filter-panel { display: flex; gap: 16px; align-items: center; padding: 14px; margin-bottom: 20px; }
.search-box { min-width: 250px; flex: 1; display: flex; align-items: center; gap: 8px; padding: 0 13px; border: 1px solid var(--line); border-radius: 12px; background: rgba(7, 18, 34, .5); }.search-box span { color: #7892b4; font-size: 20px; }.search-box input { min-height: 40px; padding: 0; border: 0; background: transparent; }
.segmented { display: flex; gap: 4px; padding: 4px; border: 1px solid var(--line); border-radius: 12px; background: rgba(7, 18, 34, .5); }.segmented button { min-height: 32px; padding: 0 12px; border: 0; border-radius: 8px; color: var(--muted); background: transparent; cursor: pointer; font-size: 11px; }.segmented button.is-active { color: white; background: #244e88; }
.catalog-count { color: #8ea5c3; font-size: 13px; }
.poster-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(185px, 1fr)); gap: 17px; }
.poster-card { position: relative; min-width: 0; overflow: hidden; border: 1px solid var(--line); border-radius: 18px; background: #0e2038; transition: transform .2s ease, border-color .2s ease; }.poster-card:hover { transform: translateY(-3px); border-color: rgba(93, 151, 245, .36); }
.poster-art { position: relative; aspect-ratio: 2/2.65; display: flex; align-items: flex-end; overflow: hidden; padding: 14px; background: linear-gradient(150deg, hsl(var(--hue) 62% 34%), #071323 72%); }.poster-art::before { content: attr(data-letter); position: absolute; top: 50%; left: 50%; transform: translate(-50%, -50%); color: rgba(255,255,255,.09); font-size: 90px; font-weight: 900; }.poster-art::after { content: ""; position: absolute; inset: 0; background: linear-gradient(transparent 46%, rgba(4, 11, 21, .9)); }
.poster-badges { position: absolute; z-index: 2; top: 11px; left: 11px; right: 11px; display: flex; justify-content: space-between; gap: 6px; }.poster-badges span { padding: 5px 7px; border: 1px solid rgba(255,255,255,.13); border-radius: 8px; color: #dae8fa; background: rgba(5, 14, 27, .72); backdrop-filter: blur(8px); font-size: 9px; font-weight: 750; }
.quality-badge { position: relative; z-index: 2; display: inline-flex; padding: 6px 8px; border-radius: 8px; color: #7be2bd; background: rgba(15, 103, 78, .75); font-size: 9px; font-weight: 800; }
.poster-copy { min-height: 102px; padding: 14px; }.poster-copy h3 { margin: 0 0 7px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: 14px; }.poster-copy p { margin: 0; color: #7990af; font-size: 10px; }.poster-copy small { display: block; margin-top: 8px; overflow: hidden; color: #526c8d; text-overflow: ellipsis; white-space: nowrap; font-size: 9px; }

.rule-ribbon { display: flex; flex-wrap: wrap; gap: 10px; margin-bottom: 18px; }.rule-ribbon span { display: inline-flex; align-items: center; gap: 8px; padding: 9px 12px; border: 1px solid var(--line); border-radius: 12px; color: var(--muted); background: rgba(12, 27, 48, .62); font-size: 10px; }.rule-ribbon i { width: 7px; height: 7px; border-radius: 50%; }.rule-ribbon .blue { background: var(--blue); }.rule-ribbon .red { background: var(--red); }.rule-ribbon .green { background: var(--green); }
.decision-board, .plan-grid, .subscription-list, .report-list { display: grid; gap: 12px; }
.governance-card { display: grid; grid-template-columns: minmax(180px, .8fr) minmax(260px, 1.2fr) auto; gap: 18px; align-items: center; padding: 19px; border: 1px solid var(--line); border-radius: 16px; background: rgba(13, 29, 51, .72); }.governance-card h3 { margin: 0 0 5px; font-size: 14px; }.governance-card p { margin: 0; color: var(--muted); font-size: 11px; line-height: 1.55; }.evidence { display: flex; flex-wrap: wrap; gap: 6px; }.evidence span { padding: 6px 8px; border-radius: 7px; color: #89a5c7; background: rgba(85, 119, 165, .1); font-size: 9px; }
.table-panel { padding: 8px 20px; }.mapping-row { display: grid; grid-template-columns: 1fr .45fr .75fr auto; align-items: center; gap: 15px; min-height: 68px; border-bottom: 1px solid var(--line); }.mapping-row:last-child { border: 0; }.mapping-row strong { font-size: 13px; }.mapping-row span { color: var(--muted); font-size: 11px; }
.plan-card { padding: 20px; border: 1px solid var(--line); border-radius: 17px; background: rgba(14, 30, 52, .75); }.plan-top { display: flex; align-items: center; justify-content: space-between; gap: 15px; }.plan-card h3 { margin: 0; font-size: 15px; }.plan-meta { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 12px; color: var(--muted); font-size: 10px; }.plan-bottom { display: flex; align-items: center; justify-content: space-between; margin-top: 17px; padding-top: 13px; border-top: 1px solid var(--line); }
.subscription-layout { display: grid; grid-template-columns: minmax(0, 1fr) 320px; gap: 17px; }.subscription-card { display: grid; grid-template-columns: auto 1fr auto; align-items: center; gap: 14px; padding: 17px; border: 1px solid var(--line); border-radius: 16px; background: rgba(14, 30, 52, .7); }.subscription-avatar { width: 42px; height: 42px; display: grid; place-items: center; border-radius: 13px; color: #9fc3ff; background: rgba(55, 127, 252, .16); font-weight: 800; }.subscription-card h3 { margin: 0 0 4px; font-size: 13px; }.subscription-card p { margin: 0; color: var(--muted); font-size: 10px; }.recommendation-card { min-height: 250px; padding: 22px; }.recommendation-card h3 { margin: 8px 0; }.recommendation-card p { color: var(--muted); font-size: 11px; line-height: 1.65; }.mini-empty { margin-top: 20px; padding: 14px; border-radius: 12px; color: #69809d; background: rgba(8, 19, 35, .46); text-align: center; font-size: 10px; }
.recommendation-item { display: grid; gap: 12px; margin-top: 12px; padding: 14px; border: 1px solid var(--line); border-radius: 13px; background: rgba(8, 19, 35, .55); }.recommendation-item b, .recommendation-item small { display: block; }.recommendation-item small { margin-top: 5px; color: var(--muted); font-size: 9px; }.button.compact { width: 100%; padding: 9px 12px; font-size: 10px; }
.report-card { padding: 21px; border: 1px solid var(--line); border-radius: 17px; background: rgba(14, 30, 52, .7); }.report-head { display: flex; justify-content: space-between; gap: 15px; }.report-card h3 { margin: 0 0 5px; }.report-card p { margin: 0; color: var(--muted); font-size: 11px; }.report-stats { display: grid; grid-template-columns: repeat(4, 1fr); gap: 9px; margin-top: 16px; }.report-stats div { padding: 11px; border-radius: 11px; background: rgba(7, 18, 34, .48); }.report-stats b { display: block; font-size: 17px; }.report-stats span { color: var(--muted); font-size: 9px; }
.log-actions { display: flex; gap: 9px; }.log-console { overflow: hidden; }.console-bar { display: flex; align-items: center; gap: 7px; height: 44px; padding: 0 16px; border-bottom: 1px solid var(--line); background: rgba(7, 16, 30, .72); }.console-bar span { width: 8px; height: 8px; border-radius: 50%; background: #ff667a; }.console-bar span:nth-child(2) { background: #f6bd53; }.console-bar span:nth-child(3) { background: #36cc91; }.console-bar b { margin-left: 8px; color: #6f87a5; font-family: ui-monospace, SFMono-Regular, Menlo, monospace; font-size: 10px; font-weight: 500; }.console-body { min-height: 480px; max-height: calc(100vh - 260px); overflow: auto; padding: 16px; background: rgba(3, 10, 20, .58); font-family: ui-monospace, SFMono-Regular, Menlo, monospace; }.console-row { display: grid; grid-template-columns: 74px 72px 150px 1fr; gap: 10px; padding: 7px 5px; border-bottom: 1px solid rgba(116, 151, 198, .07); color: #9bb1cb; font-size: 10px; line-height: 1.5; }.console-row .time { color: #536d8d; }.console-row .level { color: #66d9a9; }.console-row .event { color: #77aaf8; }.console-empty { color: #5f7898; font-size: 11px; }
.settings-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; }.setting-card { min-height: 250px; padding: 23px; }.setting-card h3 { margin: 0 0 18px; font-size: 16px; }.setting-card dl { display: grid; grid-template-columns: 125px 1fr; gap: 13px 15px; margin: 0; }.setting-card dt { color: var(--muted); font-size: 10px; }.setting-card dd { min-width: 0; margin: 0; overflow: hidden; color: #c3d3e7; text-overflow: ellipsis; white-space: nowrap; font-size: 11px; }.integration-list, .score-list { display: grid; gap: 9px; }.integration-item, .score-list div { display: flex; align-items: center; justify-content: space-between; min-height: 39px; padding: 0 11px; border-radius: 10px; color: #9fb2ca; background: rgba(7, 18, 34, .48); font-size: 10px; }.score-list b { color: #79adfc; }.danger-card { border-color: rgba(255, 97, 117, .17); }.danger-card ul { margin: 0; padding-left: 19px; color: #aabbd0; font-size: 11px; line-height: 2.1; }

dialog { color: var(--text); }.plan-dialog, .small-dialog { width: min(760px, calc(100vw - 30px)); max-height: calc(100vh - 30px); padding: 0; border: 1px solid var(--line-strong); border-radius: 23px; background: #0d1d34; box-shadow: var(--shadow); }.small-dialog { width: min(500px, calc(100vw - 30px)); }dialog::backdrop { background: rgba(1, 7, 15, .76); backdrop-filter: blur(10px); }.dialog-shell { display: grid; gap: 17px; max-height: calc(100vh - 32px); overflow: auto; padding: 24px; }.dialog-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 15px; }.dialog-head h2 { margin: 7px 0 0; font-size: 22px; }.icon-button { width: 34px; height: 34px; border: 1px solid var(--line); border-radius: 10px; background: rgba(22, 42, 69, .7); cursor: pointer; font-size: 22px; }.dialog-warning { display: grid; gap: 5px; padding: 13px; border: 1px solid rgba(244, 179, 71, .2); border-radius: 13px; background: rgba(244, 179, 71, .07); }.dialog-warning b { color: #ffd18a; font-size: 12px; }.dialog-warning span { color: #a99779; font-size: 10px; line-height: 1.55; }.dialog-items { display: grid; gap: 8px; max-height: 300px; overflow: auto; }.dialog-item { padding: 12px; border: 1px solid var(--line); border-radius: 11px; background: rgba(5, 15, 29, .5); }.dialog-item strong { display: block; margin-bottom: 5px; font-size: 11px; }.dialog-item code { display: block; overflow: hidden; color: #7088a7; text-overflow: ellipsis; white-space: nowrap; font-size: 9px; }.confirm-field small { color: #ffbd70; }.dialog-actions { display: flex; justify-content: flex-end; gap: 9px; padding-top: 4px; }
.toast-region { position: fixed; z-index: 80; right: 22px; bottom: 22px; display: grid; gap: 9px; }.toast { min-width: 250px; max-width: 390px; padding: 13px 15px; border: 1px solid var(--line-strong); border-radius: 13px; color: #cbd9e9; background: #122640; box-shadow: var(--shadow); font-size: 11px; animation: toast-in .22s ease; }.toast.error { border-color: rgba(255, 97, 117, .34); }.toast.success { border-color: rgba(37, 204, 145, .34); }@keyframes toast-in { from { opacity: 0; transform: translateY(8px); } }

@media (max-width: 1180px) {
  :root { --sidebar-width: 92px; }
  .sidebar { padding-inline: 12px; }
  .brand { justify-content: center; padding-inline: 0; }.brand > div:last-child { display: none; }
  .app-nav { gap: 5px; }.nav-item { min-height: 61px; flex-direction: column; justify-content: center; gap: 4px; padding: 5px; text-align: center; }.nav-item span { font-size: 9px; }.nav-item b { font-size: 18px; }.nav-item.is-active { box-shadow: inset 0 3px 0 var(--blue); }
  .sidebar-foot { justify-content: center; }.service-dot span, .sidebar-foot .text-button { display: none; }
  .hero { padding: 34px; }.metric-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }.subscription-layout { grid-template-columns: 1fr; }.recommendation-card { min-height: auto; }
}

@media (max-width: 760px) {
  :root { --radius-lg: 17px; }
  .ambient { display: none; }
  .app-shell { display: flex; flex-direction: column; }
  .sidebar { position: relative; inset: auto; width: 100%; height: auto; padding: max(16px, env(safe-area-inset-top)) 14px 13px; border-right: 0; border-bottom: 1px solid var(--line); }
  .brand { justify-content: flex-start; padding: 0 3px 13px; }.brand > div:last-child { display: block; }.brand-mark { width: 38px; height: 38px; }.brand strong { font-size: 16px; }
  .app-nav { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 6px; }
  .nav-item { min-width: 0; min-height: 51px; flex-direction: row; justify-content: flex-start; gap: 7px; padding: 6px 9px; border: 1px solid transparent; border-radius: 11px; }.nav-item span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: 10px; }.nav-item b { width: 16px; font-size: 15px; }.nav-item.is-active { border-color: rgba(87, 145, 236, .24); box-shadow: none; }
  .sidebar-foot { position: absolute; top: 19px; right: 15px; padding: 0; border: 0; }.service-dot { display: none; }.sidebar-foot .text-button { display: block; }
  .main-area { margin-left: 0; }.topbar { position: relative; min-height: 74px; padding: 14px 16px; }.topbar h1 { font-size: 20px; }.breadcrumb { display: none; }.top-actions { gap: 7px; }.top-actions .mode-pill, #open-logs { display: none; }.button { min-height: 39px; padding-inline: 13px; font-size: 11px; }
  .content { padding: 18px 14px 42px; }
  .hero { min-height: 0; display: block; padding: 25px 21px; }.hero h2 { font-size: 31px; }.hero p { font-size: 13px; line-height: 1.7; }.safety-orbit { display: none; }
  .health-strip { flex-wrap: nowrap; overflow-x: auto; padding-bottom: 3px; scrollbar-width: none; }.health-chip { flex: 0 0 auto; }
  .metric-grid, .metric-grid.compact { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 9px; }.metric-card { min-height: 114px; padding: 16px; }.metric-card strong { font-size: 26px; }
  .split-grid, .settings-grid { grid-template-columns: 1fr; }.section-card { min-height: auto; padding: 17px; }
  .page-intro { align-items: flex-end; margin-bottom: 17px; }.page-intro h2 { font-size: 27px; }.page-intro p { display: none; }
  .filter-panel { display: grid; gap: 10px; padding: 10px; }.search-box { min-width: 0; }.segmented { width: 100%; }.segmented button { flex: 1; }
  .poster-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }.poster-card { border-radius: 14px; }.poster-copy { min-height: 91px; padding: 11px; }.poster-copy h3 { font-size: 12px; }.poster-art { padding: 10px; }.poster-badges { top: 8px; left: 8px; right: 8px; }.poster-badges span { font-size: 8px; }
  .governance-card { grid-template-columns: 1fr auto; gap: 10px; padding: 14px; }.governance-card .evidence { grid-column: 1 / -1; grid-row: 2; }.rule-ribbon { overflow-x: auto; flex-wrap: nowrap; }.rule-ribbon span { flex: 0 0 auto; }
  .mapping-row { grid-template-columns: 1fr auto; gap: 7px; padding: 12px 0; }.mapping-row span:nth-child(2), .mapping-row span:nth-child(3) { grid-column: 1; }.table-panel { padding-inline: 15px; }
  .plan-bottom { align-items: flex-start; gap: 10px; }.subscription-card { grid-template-columns: auto 1fr; }.subscription-card > :last-child { grid-column: 1 / -1; justify-self: stretch; }
  .report-stats { grid-template-columns: repeat(2, 1fr); }.console-row { grid-template-columns: 62px 55px 1fr; }.console-row .message { grid-column: 1 / -1; }.console-body { min-height: 420px; max-height: 60vh; }
  .setting-card { min-height: 0; padding: 18px; }.setting-card dl { grid-template-columns: 95px 1fr; }
  .dialog-shell { padding: 18px; }.dialog-actions .button { flex: 1; }.toast-region { left: 14px; right: 14px; bottom: 14px; }.toast { min-width: 0; max-width: none; }
}

@media (max-width: 390px) {
  .nav-item { padding-inline: 6px; }.nav-item span { font-size: 9px; }.hero-actions { display: grid; }.top-actions #scan-button { padding-inline: 10px; }.metric-card small { font-size: 9px; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { scroll-behavior: auto !important; animation: none !important; transition: none !important; }
}
