.toast[data-type="error"] { background: var(--seel-danger); color: #fff; }
.toast[data-type="success"] { background: var(--seel-success); color: #fff; }

/* Hide the removed Theme category in the currently compiled editor. */
.ci-design [data-ci-open="theme"] { display:none; }

.link-workspace > header { display:flex; align-items:center; gap:12px; margin-bottom:16px; }
.link-workspace > header h2 { flex:1; min-width:0; overflow:hidden; white-space:nowrap; text-overflow:ellipsis; margin:0; }
.link-workspace > header button { flex:none; }
.link-tabs { display:flex; padding:3px; background:#ececec; border-radius:999px; margin-bottom:16px; }
.properties .link-tabs button { display:flex; align-items:center; justify-content:center; gap:6px; flex:1; min-height:32px; border:0; background:transparent; border-radius:999px; padding:6px 8px; font-size:12px; line-height:1.25; }
.link-tabs button img { width:14px; height:14px; flex:none; }
.link-tabs button[aria-selected="true"] { background:white; box-shadow:0 1px 3px #0002; }
.link-workspace [data-panel] > label { display:block; margin-bottom:12px; }
.link-layout { border-top:1px solid #e3e3e3; margin:22px 0; padding-top:18px; }
.link-layout h3 { margin:0 0 12px; }
.link-layout > div { display:flex; gap:10px; }
.link-layout button { flex:1; min-height:68px; border:1px solid #d5d5d5; border-radius:10px; background:#f5f5f5; }
.link-layout button[aria-pressed="true"] { border:2px solid #202020; }
.link-option-list { display:flex; flex-direction:column; }
.link-option-list[hidden],.link-option-view[hidden] { display:none; }
.properties .link-option-list > button { display:flex; align-items:center; gap:14px; padding:16px 4px; min-height:76px; border:0; border-bottom:1px solid #e8e8e8; border-radius:0; background:transparent; text-align:left; }
.link-option-list > button > img { width:20px; height:20px; flex:none; }
.link-option-list > button > span { display:grid; flex:1; gap:5px; }
.link-option-list strong { font-size:14px; }
.link-option-list small { font-size:12px; color:#626864; }
.link-option-list > button > .option-chevron { width:14px; height:14px; }
.properties .link-option-back { display:inline-flex; align-items:center; gap:7px; min-height:36px; padding:6px 0; border:0; background:transparent; font-size:12px; }
.link-option-back img { width:16px; height:16px; }
.link-option-view h3 { margin:16px 0 8px; font-size:20px; }
.link-option-controls { margin-top:20px; }
.motion-gallery { display:grid; grid-template-columns:repeat(4,minmax(0,1fr)); gap:8px; }
.properties .motion-gallery > button { display:flex; align-items:center; flex-direction:column; justify-content:center; gap:7px; min-height:100px; padding:10px 4px; border:1px solid #e0e2e1; border-radius:10px; background:#fff; font-size:12px; }
.motion-gallery > button[aria-pressed="true"] { border-color:#202321; box-shadow:0 0 0 1px #202321; }
.motion-art { display:block; width:52px; height:52px; background-image:url('assets/motion/effects-atlas.png'); background-size:400% 400%; background-repeat:no-repeat; }
.motion-status { min-height:38px; margin:16px 0 8px; }
.properties .motion-replay { min-height:36px; font-size:12px; }
@media(max-width:450px) { .motion-gallery { grid-template-columns:repeat(3,minmax(0,1fr)); } }
.link-advanced { margin-top:24px; }
.link-advanced > summary { cursor:pointer; }
.link-workspace-advanced { padding-top:12px; }
.link-preview-controls { margin-top:10px; }
.link-preview-controls button { font-size:12px; }
.link-preview-controls p { min-height:1.5em; margin:8px 0 0; }
.link-workspace .property-media { display:flex; align-items:center; gap:12px; flex-wrap:wrap; }
.link-workspace .property-media > img { width:64px; height:64px; object-fit:cover; border-radius:8px; }
.link-workspace .property-media > details { flex-basis:100%; }
#link-preview-status { min-height: 1.5em; }
.link-workspace [data-panel="details"] > label > .reset-property { display:none; }
.properties:has(.link-workspace) .inspector-top { display:none; }
/* Link statistics stay inside the existing inspector beside the page preview. */
.link-stats { --stats-purple:#6c3cff; --stats-muted:#536077; font-size:15px; }
.stats-kpis { display:grid; grid-template-columns:repeat(4,minmax(0,1fr)); gap:20px; margin-bottom:22px; }
.stats-card,.stats-surface { background:#fff; border:1px solid #dee1e9; border-radius:16px; box-shadow:0 4px 9px #252b3f06; }
.stats-card { padding:20px 18px 17px; display:grid; grid-template-columns:52px minmax(0,1fr); gap:10px 18px; align-items:start; }
.stats-kpi-icon { width:52px; height:52px; display:grid; place-items:center; border-radius:14px; background:#f0eaff; }
.stats-kpi-icon img { width:26px; height:26px; filter:invert(27%) sepia(99%) saturate(3400%) hue-rotate(248deg) brightness(99%) contrast(103%); }
.stats-kpi-label { color:var(--stats-muted); font-size:16px; font-weight:500; display:block; white-space:nowrap; }
.stats-card strong { display:block; font-size:30px; line-height:1.35; letter-spacing:-.035em; font-weight:700; white-space:nowrap; }
.stats-card > p { grid-column:1 / -1; margin:0; display:flex; align-items:center; justify-content:flex-end; gap:6px; font-size:12px; color:var(--stats-muted); flex-wrap:wrap; min-height:20px; }
.stats-trend { display:inline-flex; align-items:center; gap:2px; color:#008a26; font-weight:650; }
.stats-trend img { width:14px; height:14px; filter:invert(32%) sepia(91%) saturate(1189%) hue-rotate(106deg); }
.stats-trend.is-down { color:#b93d35; }
.stats-trend.is-down img { filter:invert(30%) sepia(65%) saturate(1500%) hue-rotate(335deg); }
.stats-last-state { display:inline-flex; align-items:center; gap:8px; }
.stats-last-state i { width:7px; height:7px; border-radius:50%; background:#059b3d; }
.stats-trend-muted { color:#697489; }
.stats-surface { padding:20px 28px; }
#studio .stats-surface h3 { font-size:23px; line-height:1.3; font-weight:700; margin:0; letter-spacing:-.035em; }
.stats-surface p { margin:1px 0 0; color:var(--stats-muted); font-size:16px; }
.stats-chart-panel { margin-bottom:22px; }
.stats-chart-panel > header { display:flex; justify-content:space-between; align-items:center; gap:16px; }
.properties .stats-date-range { display:flex; align-items:center; gap:10px; margin:0; padding:0 12px; border:1px solid #d9dce5; border-radius:12px; background:#fff; }
.stats-date-range img { width:20px; height:20px; }
.properties .stats-date-range select { border:0; background:transparent; width:auto; min-height:44px; padding:8px 4px; font-size:15px; color:#10141e; font-weight:600; box-shadow:none; }
.stats-chart-wrap { margin-top:22px; width:100%; }
.stats-chart-wrap canvas { display:block; width:100%; height:250px; touch-action:pan-y; }
.stats-surface .stats-chart-readout { min-height:20px; font-size:12px; margin:4px 0 0; }
.stats-data { margin-top:6px; color:var(--stats-muted); font-size:12px; }
.stats-data summary { cursor:pointer; width:fit-content; }
.stats-data table { width:100%; text-align:left; border-collapse:collapse; margin-top:12px; }
.stats-data :is(th,td) { padding:5px 8px; border-bottom:1px solid #e4e6ed; }
.stats-data td { text-align:right; }
.stats-breakdowns { display:grid; grid-template-columns:1.1fr 1fr; gap:22px; }
.stats-source-list { display:grid; gap:22px; padding:27px 0 12px; }
.stats-source-row { display:grid; grid-template-columns:22px 128px minmax(40px,1fr) 42px; align-items:center; gap:14px; }
.stats-source-row > img { width:21px; height:21px; opacity:.68; }
.stats-source-row > span:nth-child(2) { font-weight:550; }
.stats-source-row b { font-weight:500; text-align:right; }
.stats-bar { height:13px; background:#edeef3; border-radius:20px; overflow:hidden; }
.stats-bar i { display:block; height:100%; background:#a183fa; border-radius:inherit; }
.stats-source-row:nth-child(2) .stats-bar i { background:#b199ff; }
.stats-source-row:nth-child(3) .stats-bar i { background:#ac8eff; }
.stats-device-content { display:flex; align-items:center; gap:clamp(20px,3vw,52px); padding-top:12px; }
.stats-donut { flex:none; width:160px; height:160px; border-radius:50%; display:grid; place-items:center; }
.stats-donut.is-empty { background:#edeef3 !important; }
.stats-donut > span { width:112px; height:112px; background:#fff; border-radius:50%; display:flex; align-items:center; justify-content:center; flex-direction:column; }
.stats-donut strong { font-size:24px; line-height:1.3; letter-spacing:-.035em; }
.stats-donut > span > span { font-size:15px; color:var(--stats-muted); }
.stats-device-content ul { flex:1; list-style:none; padding:0; margin:0; display:grid; gap:20px; min-width:0; }
.stats-device-content li { display:flex; align-items:center; gap:10px; color:var(--stats-muted); }
.stats-device-content li i { width:16px; height:16px; border-radius:4px; flex:none; background:#6c3cff; }
.stats-device-content .device-mobile { background:#b6a0ff; }
.stats-device-content .device-tablet { background:#e2e4ef; }
.stats-device-content .device-unknown { background:#a2a8b7; }
.stats-device-content b { margin-left:auto; color:#202938; font-weight:500; }
.stats-coverage { display:flex; gap:12px; color:var(--stats-muted); margin:18px 0 0; font-size:14px; font-style:italic; }
.stats-coverage img { width:20px; height:20px; flex:none; opacity:.65; }
.stats-definition { color:#697489; font-size:12px; line-height:1.5; margin:10px 0 0; }
.stats-loading,.stats-error { background:white; border:1px solid #dee1e9; border-radius:16px; padding:32px; min-height:200px; color:var(--stats-muted); }
.stats-sr-only { position:absolute; width:1px; height:1px; overflow:hidden; clip-path:inset(50%); white-space:nowrap; }

/* The inspector is deliberately compact, independent of the browser width. */
.stats-kpis { grid-template-columns:repeat(2,minmax(0,1fr)); gap:10px; margin-bottom:16px; }
.stats-card { grid-template-columns:32px minmax(0,1fr); gap:7px 10px; padding:14px 12px 12px; border-radius:12px; }
.stats-kpi-icon { width:32px; height:36px; border-radius:10px; }
.stats-kpi-icon img { width:20px; height:20px; }
.stats-kpi-label { font-size:12px; white-space:normal; }
.stats-card strong { font-size:21px; }
.stats-card > p { justify-content:flex-start; font-size:10px; line-height:1.5; min-height:30px; }
.stats-surface { padding:16px 14px; border-radius:12px; }
#studio .stats-surface h3 { font-size:18px; }
.stats-surface p { font-size:12px; }
.stats-chart-panel { margin-bottom:14px; }
.stats-chart-panel > header { align-items:flex-start; gap:10px; flex-wrap:wrap; }
.properties .stats-date-range { padding:0 7px; border-radius:8px; gap:5px; }
.stats-date-range img { width:16px; height:16px; }
.properties .stats-date-range select { font-size:12px; min-height:34px; }
.stats-chart-wrap { margin-top:15px; }
.stats-chart-wrap canvas { height:195px; }
.stats-surface .stats-chart-readout,.stats-data { font-size:10px; }
.stats-breakdowns { grid-template-columns:1fr; gap:14px; }
.stats-source-list { gap:18px; padding:22px 0 4px; }
.stats-source-row { grid-template-columns:18px 92px minmax(30px,1fr) 34px; gap:9px; font-size:12px; }
.stats-source-row > img { width:18px; height:18px; }
.stats-bar { height:10px; }
.stats-device-content { gap:28px; padding-top:16px; }
.stats-donut { width:126px; height:126px; }
.stats-donut > span { width:88px; height:88px; }
.stats-donut strong { font-size:22px; }
.stats-donut > span > span,.stats-device-content li { font-size:12px; }
.stats-device-content ul { gap:16px; }
.stats-device-content li i { width:13px; height:13px; border-radius:3px; }
.stats-coverage { font-size:11px; gap:8px; margin-top:14px; }
.stats-coverage img { width:16px; height:16px; }
.stats-definition { font-size:10px; }
@media(max-width:400px) { .stats-card { padding:12px 9px; gap:7px; } .stats-card strong { font-size:19px; } .stats-source-row { grid-template-columns:16px 84px minmax(20px,1fr) 30px; gap:6px; } .stats-device-content { gap:18px; } }
/* Protected analytics contain redacted geometry only; no paid values are rendered. */
.stats-locked { position:relative; overflow:hidden; cursor:pointer; }
.stats-locked .stats-kpi-label { padding-right:6px; }
.stats-locked-badge { position:absolute; right:10px; bottom:9px; display:inline-flex; align-items:center; gap:4px; color:#72796f; font-size:10px; z-index:1; }
.stats-locked-badge img { width:11px; height:11px; }
.stats-redacted { filter:blur(5px); opacity:.5; pointer-events:none; user-select:none; display:grid; gap:10px; padding:8px 0; }
.stats-redacted i { display:block; height:14px; max-width:100%; width:76px; border-radius:5px; background:#b5aec7; }
.stats-redacted i + i { width:100px; height:6px; background:#d3cedd; }
.stats-upgrade-overlay { position:absolute; inset:0; z-index:2; display:flex; flex-direction:column; align-items:center; justify-content:center; gap:7px; padding:12px; text-align:center; background:#fffffff2; opacity:0; transform:translateY(8px); pointer-events:none; }
.stats-upgrade-overlay strong { display:flex; align-items:center; justify-content:center; gap:5px; font-size:13px; line-height:1.3; }
.stats-upgrade-overlay strong img { width:16px; height:16px; }
.stats-upgrade-overlay > span { color:#626864; font-size:11px; line-height:1.4; }
.stats-upgrade-links { display:flex; gap:8px; flex-wrap:wrap; justify-content:center; }
.stats-upgrade-links a { display:inline-flex; align-items:center; justify-content:center; min-height:32px; padding:5px 10px; border-radius:7px; background:#202321; color:#fff; font-size:11px; text-decoration:none; }
.stats-upgrade-links a + a { background:#eee9f7; color:#4f2c86; }
.stats-locked:hover .stats-upgrade-overlay,.stats-locked:focus-within .stats-upgrade-overlay,.stats-locked.is-revealed .stats-upgrade-overlay { opacity:1; transform:translateY(0); pointer-events:auto; }
.stats-locked:focus-visible { outline:2px solid #5920b0; outline-offset:3px; }
.stats-locked.stats-card { min-height:110px; }
.stats-locked.stats-card .stats-upgrade-overlay { gap:5px; padding:9px; }
.stats-locked.stats-card .stats-upgrade-overlay strong { font-size:12px; }
.stats-locked.stats-card .stats-upgrade-links { gap:5px; }
.stats-locked.stats-card .stats-upgrade-links a { min-height:28px; padding:4px 7px; font-size:10px; }
.stats-redacted-graph { min-height:200px; gap:28px; padding:26px 10px; background:repeating-linear-gradient(transparent 0 36px,#e3e1e9 37px 38px); align-content:center; }
.stats-redacted-graph i,.stats-redacted-graph i + i { width:80%; height:7px; background:#a797cc; }
.stats-redacted-graph i:nth-child(2) { width:55%; }
.stats-redacted-graph i:nth-child(3) { width:70%; }
.stats-redacted-graph i:nth-child(4) { width:45%; }
.stats-redacted-sources { min-height:130px; gap:25px; padding:28px 0 15px; }
.stats-redacted-sources i,.stats-redacted-sources i + i { width:85%; height:10px; }
.stats-redacted-device { min-height:150px; display:flex; align-items:center; gap:35px; }
.stats-redacted-device > i { width:120px; height:120px; border-radius:50%; border:24px solid #b5a2e1; background:transparent; box-sizing:border-box; }
.stats-redacted-device > span { display:grid; gap:20px; }
@media(prefers-reduced-motion:no-preference) { .stats-upgrade-overlay { transition:opacity 180ms ease,transform 180ms ease; } }
