/*
 * AtlasMCP dashboard shell (AI-62). See DESIGN.md.
 *
 * Only layout and the few parts WordPress has no component for (app shell,
 * table, drawer, chips, status bar, search results). Everything interactive
 * is a real @wordpress/components part. Tokens are --atlasmcp-* on
 * .atlasmcp-root (never :root), each aliasing a WordPress 7.1 --wpds-* token
 * with a fallback for older WordPress.
 *
 * Breakpoints: 1280 (rail shrinks to icons), 960 (search becomes an icon,
 * grids stack, group lists fold into a select), 782 (wp-admin mobile: rail
 * becomes a slide-in menu, drawer goes full width, the page scrolls).
 */

/* ---------- Our page only: let the app fill the space below the admin bar ---------- */
body.toplevel_page_ai-workflow-automation-ai-agent-hub #wpcontent { padding-left: 0; }
body.toplevel_page_ai-workflow-automation-ai-agent-hub #wpbody-content { padding-bottom: 0; }
body.toplevel_page_ai-workflow-automation-ai-agent-hub #wpfooter { display: none; }

/* ---------- Tokens ---------- */
.atlasmcp-root {
	--atlasmcp-brand: var(--wp-admin-theme-color, #6d28d9);
	--atlasmcp-brand-weak: var(--wpds-color-background-surface-brand, #f3effd);
	--atlasmcp-surface: var(--wpds-color-background-surface-neutral-strong, #fff);
	--atlasmcp-canvas: var(--wpds-color-background-surface-neutral-weak, #f4f4f4);
	--atlasmcp-line: var(--wpds-color-stroke-surface-neutral, #e0e0e0);
	--atlasmcp-line-weak: var(--wpds-color-stroke-surface-neutral-weak, #f0f0f0);
	--atlasmcp-ink: var(--wpds-color-foreground-content-neutral, #1e1e1e);
	--atlasmcp-ink-weak: var(--wpds-color-foreground-content-neutral-weak, #757575);
	--atlasmcp-ok: var(--wpds-color-foreground-content-success, #007f30);
	--atlasmcp-ok-weak: var(--wpds-color-background-surface-success-weak, #ebffed);
	--atlasmcp-warn: var(--wpds-color-foreground-content-warning, #926300);
	--atlasmcp-warn-weak: var(--wpds-color-background-surface-warning-weak, #fff7e1);
	--atlasmcp-error: var(--wpds-color-foreground-content-error, #cc1818);
	--atlasmcp-error-weak: var(--wpds-color-background-surface-error-weak, #fff6f5);
	--atlasmcp-info: var(--wpds-color-foreground-content-info, #006bd7);
	--atlasmcp-info-weak: var(--wpds-color-background-surface-info-weak, #f3f9ff);
	--atlasmcp-pro: #1e1e1e;
	--atlasmcp-on-pro: #f3d27a;
	--atlasmcp-radius: var(--wpds-border-radius-md, 4px);
	--atlasmcp-radius-lg: var(--wpds-border-radius-lg, 8px);
	--atlasmcp-mono: var(--wpds-typography-font-family-mono, Menlo, Consolas, monaco, monospace);
	--atlasmcp-header: 64px;
	--atlasmcp-rail: 232px;
	--atlasmcp-statusbar: 28px;
	--atlasmcp-shadow: 0 8px 24px rgba(0, 0, 0, .12), 0 1px 3px rgba(0, 0, 0, .08);

	height: calc(100vh - var(--wp-admin--admin-bar--height, 32px));
	display: grid;
	grid-template-columns: var(--atlasmcp-rail) minmax(0, 1fr);
	grid-template-rows: var(--atlasmcp-header) minmax(0, 1fr) var(--atlasmcp-statusbar);
	background: var(--atlasmcp-surface, #fff);
	color: var(--atlasmcp-ink);
	font-size: 13px;
	line-height: 1.5;
	position: relative;
}
.atlasmcp-root *, .atlasmcp-root *::before, .atlasmcp-root *::after { box-sizing: border-box; }
.atlasmcp-root h1, .atlasmcp-root h2, .atlasmcp-root h3 { margin: 0; color: inherit; }
.atlasmcp-root p { margin: 0; }
.atlasmcp-root :focus-visible { outline-color: var(--atlasmcp-brand, #6d28d9); }
.atlasmcp-mono { font-family: var(--atlasmcp-mono); font-size: 12px; }
.atlasmcp-weak { color: var(--atlasmcp-ink-weak); }
.atlasmcp-ellipsis { display: block; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.atlasmcp-show-md { display: none; }
.atlasmcp-scroll-x { max-width: 100%; overflow-x: auto; }

/* ---------- Rail ---------- */
.atlasmcp-rail { grid-row: 1 / 3; display: flex; flex-direction: column; min-height: 0; border-right: 1px solid var(--atlasmcp-line, #e0e0e0); background: var(--atlasmcp-surface, #fff); z-index: 30; }
.atlasmcp-rail-brand { height: var(--atlasmcp-header); flex: none; display: flex; align-items: center; gap: 10px; padding: 0 16px; border-bottom: 1px solid var(--atlasmcp-line, #e0e0e0); }
.atlasmcp-logo { width: 32px; height: 32px; border-radius: 6px; background: #1e1e1e; color: #fff; display: grid; place-items: center; flex: none; overflow: hidden; }
.atlasmcp-rail-brand b { font-size: 14px; font-weight: 600; display: flex; align-items: center; gap: 6px; line-height: 1.2; white-space: nowrap; }
.atlasmcp-rail-brand small { font-size: 11px; color: var(--atlasmcp-ink-weak); white-space: nowrap; }
.atlasmcp-rail-close { margin-left: auto; }
.atlasmcp-rail-nav { flex: 1; overflow: auto; padding: 8px 8px 16px; }
.atlasmcp-rail-group { padding: 12px 8px 4px; font-size: 11px; font-weight: 500; text-transform: uppercase; letter-spacing: .02em; color: var(--atlasmcp-ink-weak); }
.atlasmcp-rail .atlasmcp-rail-item.components-button { width: 100%; height: 32px; justify-content: flex-start; gap: 8px; padding: 0 8px; color: var(--atlasmcp-ink); font-weight: 400; text-decoration: none; }
.atlasmcp-rail .atlasmcp-rail-item.components-button svg { flex: none; }
.atlasmcp-rail .atlasmcp-rail-item.components-button:hover { background: var(--atlasmcp-canvas, #f4f4f4); color: var(--atlasmcp-ink); }
.atlasmcp-rail .atlasmcp-rail-item.is-current.components-button { background: var(--atlasmcp-brand-weak, #f3effd); color: var(--atlasmcp-brand, #6d28d9); font-weight: 500; }
.atlasmcp-rail-label { min-width: 0; }
.atlasmcp-rail-item .atlasmcp-rail-end { margin-left: auto; display: inline-flex; align-items: center; gap: 4px; }
.atlasmcp-rail-foot { flex: none; border-top: 1px solid var(--atlasmcp-line, #e0e0e0); padding: 12px 16px; display: flex; align-items: center; gap: 8px; font-size: 12px; flex-wrap: wrap; }
.atlasmcp-rail-backdrop { position: fixed; inset: 0; background: rgba(0, 0, 0, .35); z-index: 99994; }

/* ---------- Header (editor-style) ---------- */
.atlasmcp-header { grid-column: 2; display: grid; grid-template-columns: minmax(0, 1fr) minmax(280px, 480px) minmax(0, 1fr); align-items: center; gap: 16px; padding: 0 16px; border-bottom: 1px solid var(--atlasmcp-line, #e0e0e0); background: var(--atlasmcp-surface, #fff); position: relative; z-index: 20; }
.atlasmcp-header-title { display: flex; align-items: center; gap: 8px; min-width: 0; }
.atlasmcp-header-title h1 { font-size: 15px; font-weight: 600; line-height: 24px; padding: 0; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.atlasmcp-menu-btn { display: none !important; }
.atlasmcp-header-end { display: flex; align-items: center; justify-content: flex-end; gap: 4px; min-width: 0; }
.atlasmcp-header-actions { display: inline-flex; align-items: center; gap: 8px; white-space: nowrap; margin-right: 4px; }
.atlasmcp-notices { width: 420px; max-width: calc(100vw - 32px); max-height: 70vh; overflow: auto; padding: 8px; }
.atlasmcp-notices-list > * { margin: 0 0 8px !important; }
.atlasmcp-notices-foot { font-size: 12px; color: var(--atlasmcp-ink-weak); padding: 4px; }

/* Search box, where the block editor puts its document bar */
.atlasmcp-search { position: relative; }
.atlasmcp-search-box { display: flex; align-items: center; gap: 6px; height: 36px; padding: 0 6px 0 10px; border-radius: var(--atlasmcp-radius, 4px); background: var(--atlasmcp-canvas, #f4f4f4); border: 1px solid transparent; }
.atlasmcp-search-box:focus-within { background: #fff; border-color: var(--atlasmcp-brand, #6d28d9); box-shadow: 0 0 0 1px var(--atlasmcp-brand, #6d28d9); }
.atlasmcp-search-box input, .atlasmcp-search-box input:focus { flex: 1; min-width: 0; border: 0; background: transparent; font: inherit; outline: none; height: 34px; color: var(--atlasmcp-ink); box-shadow: none; padding: 0; }
.atlasmcp-search-box input::placeholder { color: var(--atlasmcp-ink-weak); }
.atlasmcp-kbd { font: 11px/18px var(--atlasmcp-mono); padding: 0 5px; border-radius: 3px; background: #fff; border: 1px solid var(--atlasmcp-line, #e0e0e0); color: var(--atlasmcp-ink-weak); white-space: nowrap; }
.atlasmcp-search-results { position: absolute; top: 42px; left: 0; right: 0; max-height: min(420px, 70vh); overflow: auto; background: #fff; border: 1px solid var(--atlasmcp-line, #e0e0e0); border-radius: var(--atlasmcp-radius-lg, 8px); box-shadow: var(--atlasmcp-shadow); padding: 6px 0; z-index: 50; }
.atlasmcp-search-group { padding: 8px 12px 4px; font-size: 11px; font-weight: 500; text-transform: uppercase; color: var(--atlasmcp-ink-weak); }
.atlasmcp-search-hit { display: flex; align-items: center; gap: 10px; width: 100%; padding: 7px 12px; border: 0; background: none; font: inherit; text-align: left; cursor: pointer; color: var(--atlasmcp-ink); }
.atlasmcp-search-hit.is-active, .atlasmcp-search-hit:hover { background: var(--atlasmcp-brand-weak, #f3effd); }
.atlasmcp-search-hit small { margin-left: auto; color: var(--atlasmcp-ink-weak); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; max-width: 55%; }
.atlasmcp-search-foot { border-top: 1px solid var(--atlasmcp-line-weak); margin-top: 6px; padding: 8px 12px 2px; font-size: 12px; color: var(--atlasmcp-ink-weak); display: flex; gap: 12px; flex-wrap: wrap; }
.atlasmcp-search-foot-end { margin-left: auto; }

/* ---------- Work area ---------- */
.atlasmcp-work { grid-column: 2; display: flex; min-height: 0; min-width: 0; }
.atlasmcp-main { flex: 1; min-width: 0; display: flex; flex-direction: column; min-height: 0; background: var(--atlasmcp-surface, #fff); }
.atlasmcp-main.is-canvas { background: var(--atlasmcp-canvas, #f4f4f4); }
.atlasmcp-tabs { flex: none; padding: 0 16px; border-bottom: 1px solid var(--atlasmcp-line, #e0e0e0); background: var(--atlasmcp-surface, #fff); display: flex; align-items: center; gap: 12px; }
.atlasmcp-tabs-scroll { min-width: 0; overflow-x: auto; }
.atlasmcp-tabs .components-tab-panel__tabs { border: 0; flex-wrap: nowrap; }
.atlasmcp-tabs .components-tab-panel__tabs-item { white-space: nowrap; }
.atlasmcp-tabs .atlasmcp-tabs-end { margin-left: auto; display: flex; align-items: center; gap: 12px; white-space: nowrap; }
.atlasmcp-scroll { flex: 1; min-height: 0; overflow: auto; }
.atlasmcp-pad { padding: 24px; }
.atlasmcp-pad-x { padding: 8px 16px 0; }
.atlasmcp-footer { flex: none; display: flex; align-items: center; gap: 8px; padding: 12px 16px; border-top: 1px solid var(--atlasmcp-line, #e0e0e0); background: var(--atlasmcp-surface, #fff); flex-wrap: wrap; }
.atlasmcp-footer .atlasmcp-footer-note { margin-right: auto; color: var(--atlasmcp-ink-weak); display: inline-flex; align-items: center; gap: 6px; }
.atlasmcp-main > .components-notice { margin: 0; flex: none; }
.atlasmcp-kv { display: grid; grid-template-columns: 120px 1fr; gap: 8px 12px; margin: 0; }
.atlasmcp-kv dt { color: var(--atlasmcp-ink-weak); }
.atlasmcp-kv dd { margin: 0; min-width: 0; overflow-wrap: anywhere; }

/* ---------- Drawer: the "Edit prompt" panel pattern ---------- */
.atlasmcp-drawer-backdrop { position: fixed; inset: 0; background: rgba(15, 23, 42, .3); z-index: 99990; animation: atlasmcp-fade .15s ease-out; }
.atlasmcp-drawer { --atlasmcp-drawer-w: 560px; position: fixed; top: var(--wp-admin--admin-bar--height, 32px); right: 0; bottom: 0; width: min(var(--atlasmcp-drawer-w), 100vw); background: #fff; box-shadow: -12px 0 32px rgba(0, 0, 0, .14); z-index: 99991; display: flex; flex-direction: column; outline: none; animation: atlasmcp-slide .18s ease-out; font-size: 13px; line-height: 1.5; color: #1e1e1e; }
.atlasmcp-drawer-head { flex: none; display: flex; align-items: flex-start; gap: 8px; padding: 20px 20px 16px; border-bottom: 1px solid #e0e0e0; }
.atlasmcp-drawer-titles { flex: 1; min-width: 0; }
.atlasmcp-drawer-kicker { font-size: 12px; color: #757575; }
.atlasmcp-drawer-head h2 { font-size: 18px; font-weight: 600; line-height: 1.3; margin: 2px 0 0; overflow-wrap: anywhere; }
.atlasmcp-drawer-body { flex: 1; overflow: auto; min-height: 0; }
.atlasmcp-drawer-section { padding: 16px 20px; border-bottom: 1px solid #f0f0f0; }
.atlasmcp-drawer-section:last-child { border-bottom: 0; }
.atlasmcp-drawer-section h3 { font-size: 13px; font-weight: 600; margin: 0 0 8px; }
.atlasmcp-drawer-sechead { display: flex; align-items: center; justify-content: space-between; gap: 8px; margin-bottom: 8px; }
.atlasmcp-drawer-sechead h3 { margin: 0; }
.atlasmcp-drawer .atlasmcp-footer { border-top: 1px solid #e0e0e0; }
@keyframes atlasmcp-slide { from { transform: translateX(24px); opacity: 0; } to { transform: none; opacity: 1; } }
@keyframes atlasmcp-fade { from { opacity: 0; } to { opacity: 1; } }

/* ---------- Toolbar, table, pager ---------- */
.atlasmcp-toolbar { display: flex; align-items: center; gap: 8px; padding: 12px 16px; border-bottom: 1px solid var(--atlasmcp-line-weak); flex-wrap: wrap; flex: none; background: var(--atlasmcp-surface, #fff); }
.atlasmcp-toolbar .components-search-control { width: 240px; max-width: 100%; }
.atlasmcp-toolbar .atlasmcp-toolbar-end { margin-left: auto; display: flex; align-items: center; gap: 8px; }
.atlasmcp-bulkbar { display: flex; align-items: center; gap: 8px; padding: 8px 16px; background: var(--atlasmcp-brand-weak, #f3effd); border-bottom: 1px solid var(--atlasmcp-line, #e0e0e0); flex: none; flex-wrap: wrap; }
.atlasmcp-table-wrap { overflow-x: auto; }
.atlasmcp-table { width: 100%; border-collapse: collapse; }
.atlasmcp-table th { position: sticky; top: 0; z-index: 1; background: var(--atlasmcp-surface, #fff); text-align: left; font-weight: 500; font-size: 12px; color: var(--atlasmcp-ink-weak); height: 40px; padding: 0 12px; border-bottom: 1px solid var(--atlasmcp-line, #e0e0e0); white-space: nowrap; }
.atlasmcp-table td { padding: 8px 12px; border-bottom: 1px solid var(--atlasmcp-line-weak); vertical-align: middle; height: 52px; white-space: nowrap; }
.atlasmcp-table td.atlasmcp-cell-main { white-space: normal; width: 100%; max-width: 0; min-width: 180px; }
.atlasmcp-table tr.is-clickable { cursor: pointer; }
.atlasmcp-table tr.is-clickable:hover td { background: #f8f8f8; }
.atlasmcp-table tr.is-clickable:focus-visible { outline: 2px solid var(--atlasmcp-brand, #6d28d9); outline-offset: -2px; }
.atlasmcp-table tr.is-selected td { background: var(--atlasmcp-brand-weak, #f3effd); }
.atlasmcp-table tr.is-off td { color: var(--atlasmcp-ink-weak); }
.atlasmcp-table td:first-child, .atlasmcp-table th:first-child { padding-left: 16px; }
.atlasmcp-table td:last-child, .atlasmcp-table th:last-child { padding-right: 16px; }
.atlasmcp-table td.atlasmcp-td-end { text-align: right; }
.atlasmcp-table .components-base-control { margin: 0; }
.atlasmcp-cell-title { font-weight: 500; display: block; }
.atlasmcp-cell-sub { display: block; color: var(--atlasmcp-ink-weak); font-size: 12px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.atlasmcp-pager { display: flex; align-items: center; justify-content: space-between; gap: 8px; padding: 8px 16px; color: var(--atlasmcp-ink-weak); font-size: 12px; border-top: 1px solid var(--atlasmcp-line, #e0e0e0); background: var(--atlasmcp-surface, #fff); flex: none; flex-wrap: wrap; }

/* ---------- Chips, badges, notes ---------- */
.atlasmcp-chip { display: inline-flex; align-items: center; gap: 4px; height: 20px; padding: 0 6px; border-radius: 2px; font-size: 12px; font-weight: 500; white-space: nowrap; background: #f0f0f0; color: #1e1e1e; border: 0; font-family: inherit; }
.atlasmcp-chip.is-ok { background: var(--atlasmcp-ok-weak); color: var(--atlasmcp-ok); }
.atlasmcp-chip.is-warn { background: var(--atlasmcp-warn-weak); color: var(--atlasmcp-warn); }
.atlasmcp-chip.is-err { background: var(--atlasmcp-error-weak); color: var(--atlasmcp-error); }
.atlasmcp-chip.is-info { background: var(--atlasmcp-info-weak); color: var(--atlasmcp-info); }
.atlasmcp-chip.is-brand { background: var(--atlasmcp-brand-weak, #f3effd); color: var(--atlasmcp-brand, #6d28d9); }
.atlasmcp-dot { width: 8px; height: 8px; border-radius: 50%; display: inline-block; background: currentColor; flex: none; }
.atlasmcp-pro { display: inline-flex; align-items: center; height: 18px; padding: 0 6px; border-radius: 2px; background: var(--atlasmcp-pro); color: var(--atlasmcp-on-pro); font-size: 10px; font-weight: 600; letter-spacing: .04em; flex: none; }
.atlasmcp-count { display: inline-flex; align-items: center; justify-content: center; min-width: 18px; height: 18px; padding: 0 5px; border-radius: 9px; background: #e0e0e0; font-size: 11px; font-weight: 600; color: #1e1e1e; }
.atlasmcp-count.is-brand { background: var(--atlasmcp-brand, #6d28d9); color: #fff; }
.atlasmcp-pronote { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; padding: 10px 12px; border: 1px dashed #d6d6d6; border-radius: var(--atlasmcp-radius-lg, 8px); color: var(--atlasmcp-ink-weak); background: #fcfcfc; }
.atlasmcp-pronote span:not(.atlasmcp-pro) { flex: 1; min-width: 200px; }

/* ---------- Sections, grids, stats ---------- */
.atlasmcp-section { margin-bottom: 24px; }
.atlasmcp-section-head { display: flex; align-items: flex-end; gap: 12px; margin-bottom: 12px; flex-wrap: wrap; }
.atlasmcp-section-head h2 { font-size: 15px; font-weight: 600; }
.atlasmcp-section-head p { color: var(--atlasmcp-ink-weak); }
.atlasmcp-section-head .atlasmcp-section-end { margin-left: auto; display: flex; gap: 8px; align-items: center; }
.atlasmcp-card-title { font-size: 13px; font-weight: 600; }
.atlasmcp-grid { display: grid; gap: 16px; }
.atlasmcp-grid.is-2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.atlasmcp-grid.is-3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.atlasmcp-form > * + * { margin-top: 16px; }
.atlasmcp-stats { display: grid; grid-template-columns: repeat(var(--atlasmcp-cols, 4), minmax(0, 1fr)); }
.atlasmcp-stat { padding: 16px; border-left: 1px solid var(--atlasmcp-line, #e0e0e0); min-width: 0; }
.atlasmcp-stat:first-child { border-left: 0; }
.atlasmcp-stat span { display: block; color: var(--atlasmcp-ink-weak); font-size: 12px; }
.atlasmcp-stat b { display: block; font-size: 24px; line-height: 32px; font-weight: 600; font-variant-numeric: tabular-nums; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.atlasmcp-stat b.is-ok { color: var(--atlasmcp-ok); }
.atlasmcp-stat b.is-warn { color: var(--atlasmcp-warn); }
.atlasmcp-stat b.is-err { color: var(--atlasmcp-error); }
.atlasmcp-stat small { color: var(--atlasmcp-ink-weak); font-size: 12px; }
.atlasmcp-empty { padding: 48px 24px; text-align: center; color: var(--atlasmcp-ink-weak); }
.atlasmcp-empty b { display: block; color: var(--atlasmcp-ink); font-size: 15px; margin-bottom: 4px; }
.atlasmcp-empty-action { margin-top: 12px; }
.atlasmcp-code { font: 12px/1.6 var(--atlasmcp-mono, Menlo, Consolas, monospace); background: #1e1e1e; color: #e0e0e0; border-radius: 4px; padding: 12px; white-space: pre-wrap; overflow-wrap: anywhere; margin: 0; }
/* AI-92: a line diff in a code block (Pro development pack: draft copies). */
.atlasmcp-codediff span { display: block; }
.atlasmcp-codediff .is-add { background: rgba(0, 160, 60, .25); }
.atlasmcp-codediff .is-del { background: rgba(220, 40, 40, .25); }
.atlasmcp-codediff .is-hunk { color: #9ec2e6; }

/* ---------- Card rows, banners, addresses ---------- */
.atlasmcp-row { display: flex; align-items: center; gap: 12px; width: 100%; }
.atlasmcp-row-mark { fill: #949494; flex: none; }
.atlasmcp-row-text { flex: 1; min-width: 0; }
.atlasmcp-row-text.is-done { color: var(--atlasmcp-ink-weak); }
.atlasmcp-num { width: 88px; flex: none; }
.atlasmcp-how { margin: 0; padding-left: 20px; display: flex; flex-direction: column; gap: 8px; }
.atlasmcp-how li { margin: 0; }
.atlasmcp-row-action { color: var(--atlasmcp-brand, #6d28d9); font-weight: 500; white-space: nowrap; }
.atlasmcp-step-dot { width: 20px; height: 20px; border-radius: 50%; border: 1px solid #949494; display: grid; place-items: center; flex: none; background: #fff; }
.atlasmcp-step-dot.is-done { background: var(--atlasmcp-ok); border-color: var(--atlasmcp-ok); }
.atlasmcp-step-dot.is-done svg { fill: #fff; }
.atlasmcp-item-link.components-item { text-decoration: none; color: inherit; }
.atlasmcp-issue { display: flex; align-items: center; gap: 12px; }
.atlasmcp-issue-text { flex: 1; min-width: 0; display: flex; flex-direction: column; text-align: left; }
.atlasmcp-banner { display: flex; align-items: center; gap: 24px; flex-wrap: wrap; }
.atlasmcp-banner-text { flex: 1; min-width: 240px; display: flex; flex-direction: column; gap: 6px; }
.atlasmcp-banner-text h2 { display: flex; align-items: center; gap: 8px; }
.atlasmcp-banner-actions { display: flex; flex-direction: column; align-items: flex-end; gap: 4px; }
.atlasmcp-address { display: flex; align-items: flex-end; gap: 8px; margin-top: 12px; }
.atlasmcp-grow { flex: 1; min-width: 0; }
.atlasmcp-meter { height: 4px; border-radius: 2px; background: #e0e0e0; overflow: hidden; position: relative; display: block; max-width: 320px; }
.atlasmcp-meter i { position: absolute; inset: 0 auto 0 0; background: var(--atlasmcp-brand, #6d28d9); }
.atlasmcp-meter.is-warn i { background: #dba617; }
.atlasmcp-root .components-card__header { gap: 8px; }

/* ---------- Split (group list + table) ---------- */
.atlasmcp-split { display: flex; min-height: 0; flex: 1; min-width: 0; }
.atlasmcp-split-side { width: 248px; flex: none; border-right: 1px solid var(--atlasmcp-line, #e0e0e0); overflow: auto; background: var(--atlasmcp-surface, #fff); }
.atlasmcp-split-main { flex: 1; min-width: 0; display: flex; flex-direction: column; min-height: 0; }
.atlasmcp-side-group { padding: 16px 16px 6px; font-size: 11px; font-weight: 500; text-transform: uppercase; color: var(--atlasmcp-ink-weak); }
.atlasmcp-side-row { display: flex; align-items: center; gap: 8px; width: 100%; padding: 8px 16px; border: 0; background: none; font: inherit; text-align: left; cursor: pointer; color: var(--atlasmcp-ink); }
.atlasmcp-side-row:hover { background: #f8f8f8; }
.atlasmcp-side-row:focus-visible { outline: 2px solid var(--atlasmcp-brand, #6d28d9); outline-offset: -2px; }
.atlasmcp-side-row.is-current { background: var(--atlasmcp-brand-weak, #f3effd); }
.atlasmcp-side-row.is-muted { cursor: default; opacity: .6; }
.atlasmcp-side-text { flex: 1; min-width: 0; }
.atlasmcp-side-text b { display: block; font-weight: 500; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.atlasmcp-side-text small { color: var(--atlasmcp-ink-weak); font-size: 12px; }
.atlasmcp-side-row .components-base-control { margin: 0; }

/*
 * Modals, popovers and snackbars render in portals outside the themed root,
 * so they get the brand here, on AtlasMCP's own admin page only.
 */
body.toplevel_page_ai-workflow-automation-ai-agent-hub .components-modal__screen-overlay,
body.toplevel_page_ai-workflow-automation-ai-agent-hub .components-popover,
body.toplevel_page_ai-workflow-automation-ai-agent-hub .components-snackbar-list {
	--wp-admin-theme-color: #6d28d9;
	--wp-admin-theme-color--rgb: 109, 40, 217;
	--wp-admin-theme-color-darker-10: #5b21b6;
	--wp-admin-theme-color-darker-10--rgb: 91, 33, 182;
	--wp-admin-theme-color-darker-20: #4c1d95;
	--wp-admin-theme-color-darker-20--rgb: 76, 29, 149;
	--wp-components-color-accent: #6d28d9;
	--wp-components-color-accent-darker-10: #5b21b6;
	--wp-components-color-accent-darker-20: #4c1d95;
}

/* ---------- Connections (AI-69) ---------- */
.atlasmcp-avatar { display: grid; place-items: center; width: 36px; height: 36px; border-radius: var(--atlasmcp-radius-lg, 8px); color: #fff; font-size: 12px; font-weight: 600; flex: none; }
.atlasmcp-check { display: flex; align-items: flex-start; gap: 12px; }
.atlasmcp-check-mark { flex: none; display: grid; place-items: center; fill: var(--atlasmcp-ink-weak); }
.atlasmcp-check-mark.is-ok { fill: #00a32a; }
.atlasmcp-check-mark.is-warn { fill: #dba617; }
.atlasmcp-check-mark.is-err { fill: #d63638; }
.atlasmcp-check-fix { margin-top: 6px; padding: 8px 10px; border-radius: var(--atlasmcp-radius, 4px); background: var(--atlasmcp-canvas, #f4f4f4); font-size: 12px; color: var(--atlasmcp-ink); overflow-wrap: anywhere; }
.atlasmcp-gap-s { margin-top: 8px; }
.atlasmcp-stack.is-loose { gap: 16px; }
.atlasmcp-stack p { margin: 0; }
.atlasmcp-grid.is-tight { gap: 8px; }
.atlasmcp-tile.is-compact { align-items: center; padding: 10px 12px; }
.atlasmcp-err { margin: 0; color: var(--atlasmcp-error); font-size: 12px; }
.atlasmcp-end { display: flex; justify-content: flex-end; gap: 8px; }
.atlasmcp-between { display: flex; justify-content: space-between; align-items: center; gap: 8px; flex-wrap: wrap; }
.atlasmcp-waiting { display: flex; flex-direction: column; align-items: center; gap: 8px; padding: 16px 0; text-align: center; }
.atlasmcp-waiting .components-spinner { margin: 0; }
.atlasmcp-address.is-mono input { font-family: var(--atlasmcp-mono); font-size: 12px; }
.atlasmcp-pad-x.atlasmcp-stack { padding-bottom: 12px; }
.atlasmcp-tabs-end .components-toggle-control .components-base-control__field { margin: 0; }
.atlasmcp-table .atlasmcp-row-text { display: flex; flex-direction: column; gap: 2px; }

/* ---------- Tools (AI-70) ---------- */
.atlasmcp-side-row.is-sub { padding-left: 24px; }
.atlasmcp-side-row.is-sub .atlasmcp-side-text b { font-weight: 400; }
.atlasmcp-side-row.is-current .atlasmcp-side-text b { color: var(--atlasmcp-brand, #6d28d9); }
.atlasmcp-side-more { padding: 4px 16px 12px 24px; }
.atlasmcp-gradebar { display: flex; height: 3px; border-radius: 2px; overflow: hidden; background: var(--atlasmcp-line-weak); margin-top: 6px; }
.atlasmcp-gradebar i.is-a { background: #00a32a; }
.atlasmcp-gradebar i.is-b { background: #dba617; }
.atlasmcp-gradebar i.is-c { background: #d63638; }
.atlasmcp-toolbar .components-select-control { width: auto; }
.atlasmcp-tools-folded { align-items: center; gap: 8px; flex-wrap: wrap; }
.atlasmcp-gradehelp { flex-basis: 100%; list-style: none; margin: 0; padding: 10px 12px; border-radius: var(--atlasmcp-radius, 4px); background: var(--atlasmcp-canvas, #f4f4f4); display: flex; flex-direction: column; gap: 6px; font-size: 12px; }
.atlasmcp-gradehelp li { margin: 0; display: flex; align-items: center; gap: 8px; }
.atlasmcp-scroll.is-loading .atlasmcp-table { opacity: .6; }
.atlasmcp-nowrap { flex-wrap: nowrap; max-width: 100%; }
.atlasmcp-nowrap > .atlasmcp-ellipsis { min-width: 0; }
.atlasmcp-table td .components-form-toggle, .atlasmcp-table th .components-checkbox-control__input-container, .atlasmcp-table td .components-checkbox-control__input-container { margin: 0; vertical-align: middle; }
.atlasmcp-idrow { display: flex; align-items: center; gap: 8px; padding: 6px 6px 6px 10px; border-radius: var(--atlasmcp-radius, 4px); background: var(--atlasmcp-canvas, #f4f4f4); }
.atlasmcp-idrow code { flex: 1; min-width: 0; background: none; padding: 0; overflow-wrap: anywhere; }
.atlasmcp-reads { padding: 12px; border: 1px solid var(--atlasmcp-line, #e0e0e0); border-radius: var(--atlasmcp-radius-lg, 8px); white-space: pre-line; overflow-wrap: anywhere; }
.atlasmcp-reads p { margin-top: 8px; white-space: normal; font-size: 12px; }
.atlasmcp-params { margin: 0 0 8px; border: 1px solid var(--atlasmcp-line, #e0e0e0); border-radius: var(--atlasmcp-radius-lg, 8px); overflow: hidden; font-size: 12px; }
.atlasmcp-params > div { display: grid; grid-template-columns: 150px minmax(0, 1fr); gap: 12px; padding: 8px 12px; border-top: 1px solid var(--atlasmcp-line-weak); }
.atlasmcp-params > div:first-child { border-top: 0; }
.atlasmcp-params > div.is-missing { background: var(--atlasmcp-warn-weak); }
.atlasmcp-params dt { overflow-wrap: anywhere; }
.atlasmcp-params dd { margin: 0; }
.atlasmcp-params .is-missing dd b { color: var(--atlasmcp-warn); font-weight: 600; }
.atlasmcp-param-field .components-base-control__label { font-family: var(--atlasmcp-mono); text-transform: none; }
.atlasmcp-group.is-off .atlasmcp-group-title { color: var(--atlasmcp-ink-weak); }
.atlasmcp-group-title { font-weight: 500; }
.atlasmcp-root .atlasmcp-changenote.components-notice { margin: 0; }
.atlasmcp-changenote-steps { margin: 6px 0 0 18px; padding: 0; }
.atlasmcp-changenote-steps li { margin: 0 0 2px; }
.atlasmcp-label { font-size: 11px; font-weight: 500; text-transform: uppercase; letter-spacing: .02em; color: var(--atlasmcp-ink-weak); }
.atlasmcp-grid.is-4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.atlasmcp-btn-count { margin-left: 6px; opacity: .7; font-variant-numeric: tabular-nums; }
.atlasmcp-self-start { align-self: flex-start; }
.atlasmcp-source + .atlasmcp-source { border-top: 1px solid var(--atlasmcp-line, #e0e0e0); }
.atlasmcp-source-body { margin-top: 12px; padding-left: 44px; }
.atlasmcp-pills { gap: 6px; }
.atlasmcp-pills .components-button.is-secondary:not(.is-on) { color: var(--atlasmcp-ink); box-shadow: inset 0 0 0 1px var(--atlasmcp-line, #e0e0e0); }
.atlasmcp-pills .components-button.is-secondary.is-on { background: var(--atlasmcp-brand-weak, #f3effd); }
.atlasmcp-savebar { position: sticky; bottom: 0; z-index: 5; display: flex; align-items: center; gap: 12px 16px; flex-wrap: wrap; padding: 12px 16px; border: 1px solid var(--atlasmcp-line, #e0e0e0); border-radius: var(--atlasmcp-radius-lg, 8px); background: var(--atlasmcp-surface, #fff); box-shadow: var(--atlasmcp-shadow); }
.atlasmcp-savebar-text { display: flex; flex-direction: column; min-width: 0; }

/* ---------- Access control (AI-71) ---------- */
.atlasmcp-access-bar { display: flex; align-items: center; gap: 8px 16px; flex-wrap: wrap; }
.atlasmcp-access-role { flex: none; min-width: 200px; }
.atlasmcp-access-count { display: inline-flex; align-items: baseline; gap: 8px; flex-wrap: wrap; }
.atlasmcp-access-count > b { font-size: 24px; line-height: 32px; font-weight: 600; font-variant-numeric: tabular-nums; }
.atlasmcp-access-count .atlasmcp-chip { align-self: center; }
.atlasmcp-access-hint { flex: 1 1 220px; min-width: 0; }
.atlasmcp-access-actions { margin-left: auto; display: inline-flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.atlasmcp-access-side { display: flex; flex-direction: column; }
.atlasmcp-access-search { padding: 12px 12px 4px; position: sticky; top: 0; background: var(--atlasmcp-surface, #fff); z-index: 1; }
.atlasmcp-access-none { padding: 12px 16px; }
.atlasmcp-access-row { padding: 0 8px 0 16px; cursor: default; }
.atlasmcp-access-row .components-checkbox-control__input-container { margin: 0; }
.atlasmcp-access-row.is-off .atlasmcp-side-text b { color: var(--atlasmcp-ink-weak); }
.atlasmcp-access-pick { flex: 1; min-width: 0; display: flex; align-items: center; gap: 8px; padding: 8px 0; border: 0; background: none; font: inherit; text-align: left; cursor: pointer; color: inherit; }
.atlasmcp-access-pick:focus-visible { outline: 2px solid var(--atlasmcp-brand, #6d28d9); outline-offset: 2px; }
.atlasmcp-access-row.is-current .atlasmcp-side-text b { color: var(--atlasmcp-brand, #6d28d9); }
.atlasmcp-access-title { min-width: 0; margin-right: 8px; }
.atlasmcp-access-modes { gap: 12px; }
.atlasmcp-access-modes .components-checkbox-control__label { white-space: nowrap; }
.atlasmcp-access-pronote { padding-bottom: 8px; }
.atlasmcp-access-folded > .atlasmcp-toolbar { flex: 1; min-width: 0; }
.atlasmcp-access-ok { fill: var(--atlasmcp-ok); flex: none; }
.atlasmcp-access-held { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 6px; }
.atlasmcp-access-held li { margin: 0; }
.atlasmcp-access-group { font-weight: 500; margin-bottom: 6px; }
.atlasmcp-access-chips { display: flex; flex-wrap: wrap; gap: 6px; }

/* ---------- Activity log and Workflows (AI-72) ---------- */
.atlasmcp-activity-record .components-base-control__field { margin: 0; }
.atlasmcp-activity-record .components-toggle-control__label { white-space: nowrap; }
.atlasmcp-workflow-top { padding-bottom: 8px; }
.atlasmcp-workflow-steps { min-height: 56px; padding: 8px; border: 1px dashed var(--atlasmcp-line, #e0e0e0); border-radius: var(--atlasmcp-radius-lg, 8px); background: var(--atlasmcp-canvas, #f4f4f4); }
.atlasmcp-workflow-steps > p { padding: 8px; }
.atlasmcp-workflow-steps ol { margin: 0; padding: 0; list-style: none; counter-reset: atlasmcp-step; display: flex; flex-direction: column; gap: 4px; }
.atlasmcp-workflow-steps li, .atlasmcp-workflow-pick li { display: flex; align-items: center; gap: 8px; margin: 0; min-width: 0; }
.atlasmcp-workflow-steps li { counter-increment: atlasmcp-step; padding: 4px 4px 4px 8px; border-radius: var(--atlasmcp-radius, 4px); background: var(--atlasmcp-surface, #fff); border: 1px solid var(--atlasmcp-line, #e0e0e0); }
.atlasmcp-workflow-steps li::before { content: counter(atlasmcp-step); flex: none; width: 20px; height: 20px; border-radius: 50%; display: grid; place-items: center; font-size: 11px; font-weight: 600; background: var(--atlasmcp-brand-weak, #f3effd); color: var(--atlasmcp-brand, #6d28d9); }
.atlasmcp-workflow-steps .atlasmcp-grow, .atlasmcp-workflow-pick .atlasmcp-grow { display: flex; flex-direction: column; min-width: 0; }
.atlasmcp-workflow-find { display: flex; align-items: center; gap: 8px; margin-bottom: 8px; }
.atlasmcp-workflow-find .components-search-control { flex: 1; min-width: 0; }
.atlasmcp-workflow-pick { list-style: none; margin: 0; padding: 0; border: 1px solid var(--atlasmcp-line, #e0e0e0); border-radius: var(--atlasmcp-radius-lg, 8px); }
.atlasmcp-workflow-pick li { padding: 8px 8px 8px 12px; border-top: 1px solid var(--atlasmcp-line-weak); cursor: grab; }
.atlasmcp-workflow-pick li:first-child { border-top: 0; }
.atlasmcp-workflow-pick b { font-weight: 500; }
.atlasmcp-workflow-desc { font-size: 12px; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.atlasmcp-drawer-body > .atlasmcp-pad-x { padding: 16px 20px 0; }

/* ---------- Shopping assistant (AI-73) ---------- */
.atlasmcp-main.is-embedded { flex: none; min-height: 0; border: 1px solid var(--atlasmcp-line, #e0e0e0); border-radius: var(--atlasmcp-radius-lg, 8px); overflow: clip; }
.atlasmcp-main.is-embedded .atlasmcp-scroll { overflow: visible; }
.atlasmcp-main.is-embedded .atlasmcp-pad { padding: 16px; }
.atlasmcp-main.is-embedded > .atlasmcp-footer { position: sticky; bottom: 0; z-index: 5; }
.atlasmcp-fieldset { border: 0; margin: 0; padding: 0; min-width: 0; }
.atlasmcp-fieldset legend { padding: 0; margin-bottom: 8px; }
.atlasmcp-fieldset:disabled > * { opacity: .6; }
.atlasmcp-shop-title { font-size: 15px; font-weight: 600; }
.atlasmcp-shop-demo { width: 124px; height: 247px; border-radius: 24px; box-shadow: var(--atlasmcp-shadow); flex: none; }
.atlasmcp-shop-demo.is-large { width: 207px; height: 412px; }
.atlasmcp-shop-how { display: flex; align-items: center; gap: 24px; }
.atlasmcp-shop-points { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 6px; }
.atlasmcp-shop-points.is-row { flex-direction: row; flex-wrap: wrap; gap: 6px 20px; }
.atlasmcp-shop-points li { display: flex; align-items: flex-start; gap: 6px; margin: 0; }
.atlasmcp-shop-points svg { fill: #00a32a; flex: none; margin-top: -1px; }
.atlasmcp-shop-steps { list-style: none; margin: 0; padding: 0; counter-reset: atlasmcp-shop; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px 24px; }
.atlasmcp-shop-steps li { counter-increment: atlasmcp-shop; position: relative; padding-left: 32px; margin: 0; display: flex; flex-direction: column; gap: 2px; }
.atlasmcp-shop-steps li::before { content: counter(atlasmcp-shop); position: absolute; left: 0; top: 0; width: 22px; height: 22px; border-radius: 50%; display: grid; place-items: center; font-size: 11px; font-weight: 600; background: var(--atlasmcp-brand-weak, #f3effd); color: var(--atlasmcp-brand, #6d28d9); }
.atlasmcp-shop-steps b { font-weight: 500; }
.atlasmcp-shop-checks { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 6px; }
.atlasmcp-shop-checks li { margin: 0; align-items: center; }
.atlasmcp-shop-button { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 16px; align-items: start; }
.atlasmcp-shop-color { display: flex; align-items: flex-end; gap: 8px; }
.atlasmcp-mono-input input, .atlasmcp-mono-input textarea { font-family: var(--atlasmcp-mono); font-size: 12px; }
.atlasmcp-shop-preview { position: relative; display: grid; grid-template-columns: 1fr 1fr; grid-template-rows: repeat(3, 72px); gap: 8px; padding: 12px; border: 1px solid var(--atlasmcp-line, #e0e0e0); border-radius: var(--atlasmcp-radius-lg, 8px); background: repeating-linear-gradient(180deg, var(--atlasmcp-canvas, #f4f4f4) 0 10px, transparent 10px 22px) 50% 50% / 46% 60% no-repeat, #fff; }
.atlasmcp-shop-spot { display: flex; align-items: center; padding: 0 4px; border: 1px dashed transparent; border-radius: var(--atlasmcp-radius, 4px); background: none; cursor: pointer; font: inherit; min-width: 0; }
.atlasmcp-shop-spot.is-top-right, .atlasmcp-shop-spot.is-middle-right, .atlasmcp-shop-spot.is-bottom-right { justify-content: flex-end; }
.atlasmcp-shop-spot.is-top-left, .atlasmcp-shop-spot.is-top-right { align-items: flex-start; }
.atlasmcp-shop-spot.is-bottom-left, .atlasmcp-shop-spot.is-bottom-right { align-items: flex-end; }
.atlasmcp-shop-spot:hover:not(:disabled) { border-color: var(--atlasmcp-line, #e0e0e0); }
.atlasmcp-shop-spot:focus-visible { outline: 2px solid var(--atlasmcp-brand, #6d28d9); outline-offset: 1px; }
.atlasmcp-shop-spot:disabled { cursor: default; }
.atlasmcp-shop-pill { display: inline-block; max-width: 100%; padding: 6px 12px; border-radius: 999px; color: #fff; font-size: 12px; font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; box-shadow: 0 2px 6px rgba(0, 0, 0, .18); }
.atlasmcp-shop-ghost { width: 56px; height: 20px; border-radius: 999px; border: 1px dashed #c3c4c7; }
.atlasmcp-shop-apps { gap: 8px 20px; }
.atlasmcp-shop-narrow { max-width: 420px; }
.atlasmcp-shop-termshead { margin-bottom: 6px; }
.atlasmcp-shop-switch .components-base-control__field { margin: 0; }
.atlasmcp-shop-switch .components-toggle-control__label { white-space: nowrap; }

/* ---------- Experiments, AI provider and Usage (AI-74) ---------- */
.atlasmcp-experiments-top { padding-bottom: 8px; }
.atlasmcp-experiments-hideall .components-base-control__field { margin: 0; }
.atlasmcp-experiments-hideall .components-toggle-control__label { white-space: nowrap; }
.atlasmcp-experiments-pro { padding-bottom: 16px; }
.atlasmcp-table td .components-select-control { min-width: 180px; }
.atlasmcp-usage-top { padding-bottom: 12px; }
.atlasmcp-usage-chart { display: flex; align-items: flex-end; gap: 2px; height: 128px; }
.atlasmcp-usage-day { flex: 1; min-width: 0; height: 100%; display: flex; align-items: flex-end; }
.atlasmcp-usage-day i { display: block; width: 100%; min-height: 2px; border-radius: 2px 2px 0 0; background: var(--atlasmcp-brand, #6d28d9); opacity: .75; }
.atlasmcp-usage-day:hover i { opacity: 1; }
.atlasmcp-usage-axis { margin-top: 6px; font-size: 11px; color: var(--atlasmcp-ink-weak); }
.atlasmcp-usage-tokens { display: flex; flex-direction: column; gap: 4px; min-width: 160px; }
.atlasmcp-usage-tokens b { font-weight: 600; font-variant-numeric: tabular-nums; }

/* ---------- Error debugger and Versions (AI-75) ---------- */
.atlasmcp-errors-top { padding-bottom: 8px; }
.atlasmcp-errors-source { max-width: 200px; color: var(--atlasmcp-ink-weak); }
.atlasmcp-errors-checks { gap: 8px 24px; }
.atlasmcp-errors-checks .components-base-control__field { margin: 0; }
.atlasmcp-errors-hook { display: grid; grid-template-columns: 180px minmax(0, 1fr); gap: 16px; align-items: start; }
.atlasmcp-errors-chart { display: flex; align-items: flex-end; gap: 8px; height: 144px; }
.atlasmcp-errors-day { flex: 1; min-width: 0; height: 100%; display: flex; flex-direction: column; align-items: center; justify-content: flex-end; gap: 4px; font-size: 11px; color: var(--atlasmcp-ink-weak); }
.atlasmcp-errors-day i, .atlasmcp-errors-legend i { display: block; width: 100%; min-height: 4px; border-radius: 2px 2px 0 0; background: var(--atlasmcp-line, #e0e0e0); }
.atlasmcp-errors-legend i { width: 10px; height: 10px; min-height: 0; border-radius: 2px; }
.atlasmcp-errors-day i.is-fatal, .atlasmcp-errors-legend i.is-fatal { background: var(--atlasmcp-error); }
.atlasmcp-errors-day i.is-other, .atlasmcp-errors-legend i.is-other { background: #dba617; }
.atlasmcp-versions-top { padding-bottom: 12px; }
.atlasmcp-versions-installed { display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.atlasmcp-versions-installed b { font-size: 15px; font-weight: 600; }
.atlasmcp-root .atlasmcp-versions-note { margin: 8px 0 0; font-size: 12px; }
.atlasmcp-versions-note.is-warn { color: var(--atlasmcp-warn); }
.atlasmcp-versions-note.is-err { color: var(--atlasmcp-error); }
.atlasmcp-versions-list { margin: 0 0 0 18px; padding: 0; display: flex; flex-direction: column; gap: 4px; list-style: disc; }
.atlasmcp-versions-list li { margin: 0; }

/* ---------- Plans and Documentation (AI-76) ---------- */
.atlasmcp-plans { align-items: stretch; }
.atlasmcp-plan.is-featured { box-shadow: 0 0 0 2px var(--atlasmcp-brand, #6d28d9); }
.atlasmcp-plan .components-card__body { display: flex; flex-direction: column; height: 100%; }
.atlasmcp-root .atlasmcp-plan-name { margin: 0; font-size: 15px; font-weight: 600; }
.atlasmcp-root .atlasmcp-plan-price { margin: 12px 0 0; display: flex; align-items: baseline; gap: 2px; }
.atlasmcp-plan-price b { font-size: 32px; line-height: 40px; font-weight: 600; font-variant-numeric: tabular-nums; }
.atlasmcp-plan-price span { color: var(--atlasmcp-ink-weak); }
.atlasmcp-root .atlasmcp-plan-per { margin: 0; min-height: 20px; display: flex; align-items: center; gap: 8px; font-size: 12px; color: var(--atlasmcp-ink-weak); }
.atlasmcp-plan-cta { margin: 16px 0; justify-content: center; width: 100%; }
div.atlasmcp-plan-cta { display: flex; }
.atlasmcp-plan-features { flex: 1; }
.atlasmcp-root .atlasmcp-plan-billed { margin: 16px 0 0; font-size: 12px; text-align: center; }
.atlasmcp-plans-guarantee { color: var(--atlasmcp-ok); font-weight: 500; }
.atlasmcp-plans-nocard { margin-left: 4px; font-weight: 400; opacity: .8; }
.atlasmcp-compare { border: 1px solid var(--atlasmcp-line, #e0e0e0); border-radius: var(--atlasmcp-radius-lg, 8px); background: var(--atlasmcp-surface, #fff); overflow: hidden; }
.atlasmcp-compare .atlasmcp-table td { height: 40px; }
.atlasmcp-compare-yes { display: inline-flex; }
.atlasmcp-compare-yes svg { fill: var(--atlasmcp-ok); }
.atlasmcp-docs-icon { fill: var(--atlasmcp-ink-weak); flex: none; }
.atlasmcp-side-row.is-current .atlasmcp-docs-icon { fill: var(--atlasmcp-brand, #6d28d9); }
.atlasmcp-root .atlasmcp-docs-title { margin: 0 0 4px; font-size: 20px; line-height: 28px; font-weight: 500; }
.atlasmcp-root .atlasmcp-docs-lead { margin: 8px 0 0; font-size: 14px; max-width: 640px; }
.atlasmcp-root .atlasmcp-docs-p { margin: 8px 0 12px; }
.atlasmcp-root .atlasmcp-docs-intro { margin: 0 0 16px; }
.atlasmcp-docs-fold { padding: 12px 16px; border-bottom: 1px solid var(--atlasmcp-line-weak); flex: none; }
.atlasmcp-docs-fold .components-base-control { flex: 1; }

/* ---------- Setup wizard (AI-68) ---------- */
.atlasmcp-steps-side { display: flex; flex-direction: column; }
.atlasmcp-steps { list-style: none; margin: 0; padding: 12px 8px; }
.atlasmcp-steps li { margin: 0; }
.atlasmcp-step { display: flex; align-items: center; gap: 10px; width: 100%; padding: 8px; border: 0; border-radius: var(--atlasmcp-radius, 4px); background: none; font: inherit; text-align: left; cursor: pointer; color: var(--atlasmcp-ink); }
.atlasmcp-step:hover:not(:disabled) { background: #f8f8f8; }
.atlasmcp-step:disabled { cursor: default; color: var(--atlasmcp-ink-weak); }
.atlasmcp-step:focus-visible { outline: 2px solid var(--atlasmcp-brand, #6d28d9); outline-offset: -2px; }
.atlasmcp-step.is-current { background: var(--atlasmcp-brand-weak, #f3effd); color: var(--atlasmcp-brand, #6d28d9); font-weight: 500; }
.atlasmcp-step-n { width: 24px; height: 24px; border-radius: 50%; border: 1px solid #949494; display: grid; place-items: center; flex: none; font-size: 12px; background: #fff; }
.atlasmcp-step.is-current .atlasmcp-step-n { border-color: var(--atlasmcp-brand, #6d28d9); background: var(--atlasmcp-brand, #6d28d9); color: #fff; }
.atlasmcp-step.is-done:not(.is-current) .atlasmcp-step-n { border-color: var(--atlasmcp-ok); background: var(--atlasmcp-ok); }
.atlasmcp-step.is-done .atlasmcp-step-n svg { fill: #fff; }
.atlasmcp-step-label { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.atlasmcp-steps-note { margin: auto 0 0; padding: 0 16px 16px; font-size: 12px; color: var(--atlasmcp-ink-weak); }
.atlasmcp-stepcount { margin: 0 0 4px; font-size: 12px; }
.atlasmcp-stephead { margin-bottom: 16px; }
.atlasmcp-stephead h2 { margin: 0 0 4px; font-size: 20px; line-height: 28px; font-weight: 500; }
.atlasmcp-stephead p { margin: 0; }
.atlasmcp-tile { display: flex; align-items: flex-start; gap: 12px; width: 100%; padding: 16px; border: 1px solid var(--atlasmcp-line, #e0e0e0); border-radius: var(--atlasmcp-radius-lg, 8px); background: var(--atlasmcp-surface, #fff); font: inherit; text-align: left; cursor: pointer; color: var(--atlasmcp-ink); }
.atlasmcp-tile:hover:not(:disabled) { border-color: #949494; }
.atlasmcp-tile:focus-visible { outline: 2px solid var(--atlasmcp-brand, #6d28d9); outline-offset: 1px; }
.atlasmcp-tile.is-on { border-color: var(--atlasmcp-brand, #6d28d9); box-shadow: 0 0 0 1px var(--atlasmcp-brand, #6d28d9); background: var(--atlasmcp-brand-weak, #f3effd); }
.atlasmcp-tile:disabled { cursor: not-allowed; opacity: .6; }
.atlasmcp-tile-icon { flex: none; width: 36px; height: 36px; border-radius: var(--atlasmcp-radius, 4px); display: grid; place-items: center; background: var(--atlasmcp-canvas, #f4f4f4); }
.atlasmcp-tile.is-on .atlasmcp-tile-icon { background: #fff; fill: var(--atlasmcp-brand, #6d28d9); }
.atlasmcp-tile-text { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 4px; }
.atlasmcp-tile-text b { font-weight: 500; display: inline-flex; align-items: center; gap: 6px; flex-wrap: wrap; }
.atlasmcp-tile-text > span { color: var(--atlasmcp-ink-weak); font-size: 13px; }
.atlasmcp-tile-count { font-weight: 600; color: var(--atlasmcp-ink); }
.atlasmcp-tile-check { flex: none; fill: var(--atlasmcp-brand, #6d28d9); }
.atlasmcp-gap { margin-top: 16px; }
.atlasmcp-gap-b { margin-bottom: 16px; }
.atlasmcp-stack { display: flex; flex-direction: column; gap: 8px; }
.atlasmcp-stack .atlasmcp-address { margin-top: 0; }
.atlasmcp-inline { display: inline-flex; align-items: center; gap: 8px; flex-wrap: wrap; margin: 0; }
.atlasmcp-inline .components-spinner { margin: 0; }

/* ---------- Status bar ---------- */
.atlasmcp-status { grid-column: 1 / 3; display: flex; align-items: center; gap: 16px; padding: 0 12px; border-top: 1px solid var(--atlasmcp-line, #e0e0e0); background: var(--atlasmcp-surface, #fff); font-size: 12px; color: var(--atlasmcp-ink-weak); min-width: 0; }
.atlasmcp-status-item { display: inline-flex; align-items: center; gap: 6px; white-space: nowrap; }
.atlasmcp-status-item.is-ok { color: var(--atlasmcp-ok); }
.atlasmcp-status-item.is-warn { color: var(--atlasmcp-warn); }
.atlasmcp-status-end { margin-left: auto; display: inline-flex; align-items: center; gap: 8px; white-space: nowrap; }
.atlasmcp-status .components-button.is-link { font-size: 12px; }

/* Snackbars sit above the status bar, beside the admin menu */
.atlasmcp-snackbars { position: fixed; left: 176px; bottom: 40px; z-index: 100000; max-width: calc(100vw - 32px); }
.atlasmcp-snackbars .components-snackbar { width: max-content; max-width: min(560px, calc(100vw - 32px)); }
body.folded .atlasmcp-snackbars { left: 52px; }

/* ---------- Screens not rebuilt yet ---------- */
.atlasmcp-root .aah-legacy { font-size: 14px; line-height: 1.5; }

/* ---------- 1280: rail shrinks to icons ---------- */
@media (max-width: 1279px) {
	.atlasmcp-header { grid-template-columns: minmax(0, 1fr) minmax(220px, 360px) auto; }
}
@media (max-width: 1279px) and (min-width: 782px) {
	.atlasmcp-root { --atlasmcp-rail: 56px; }
	.atlasmcp-rail-label, .atlasmcp-rail-group span { display: none; }
	.atlasmcp-rail-group { padding: 6px 0; border-top: 1px solid var(--atlasmcp-line-weak); margin: 6px 4px 0; }
	.atlasmcp-rail-brand { padding: 0 12px; }
	.atlasmcp-rail .atlasmcp-rail-item.components-button { justify-content: center; padding: 0; }
	.atlasmcp-rail-foot { display: none; }
	.atlasmcp-drawer { --atlasmcp-drawer-w: 520px; }
}

/* ---------- 960: tablet ---------- */
@media (max-width: 959px) {
	.atlasmcp-header { grid-template-columns: minmax(0, 1fr) auto auto; gap: 8px; }
	.atlasmcp-search.is-floating { position: absolute; left: 8px; right: 8px; top: 14px; z-index: 60; }
	.atlasmcp-grid.is-2, .atlasmcp-grid.is-3 { grid-template-columns: minmax(0, 1fr); }
	.atlasmcp-stats { grid-template-columns: repeat(2, minmax(0, 1fr)); }
	.atlasmcp-stat:nth-child(3) { border-left: 0; }
	.atlasmcp-stat:nth-child(n+3) { border-top: 1px solid var(--atlasmcp-line, #e0e0e0); }
	.atlasmcp-hide-md { display: none !important; }
	.atlasmcp-show-md { display: flex; }
	.atlasmcp-header-actions .components-toggle-control__label { display: none; }
}

/* ---------- 782: wp-admin mobile ---------- */
@media (max-width: 781px) {
	.atlasmcp-root { --atlasmcp-header: 56px; height: auto; min-height: calc(100vh - var(--wp-admin--admin-bar--height, 46px)); grid-template-columns: minmax(0, 1fr); grid-template-rows: var(--atlasmcp-header) 1fr auto; }
	.atlasmcp-rail { position: fixed; top: var(--wp-admin--admin-bar--height, 46px); bottom: 0; left: 0; width: min(300px, 86vw); transform: translateX(-105%); transition: transform .2s ease-out; z-index: 99995; box-shadow: var(--atlasmcp-shadow); }
	.atlasmcp-rail.is-open { transform: none; }
	.atlasmcp-menu-btn { display: inline-flex !important; margin-left: -8px; }
	.atlasmcp-header, .atlasmcp-work, .atlasmcp-status { grid-column: 1; }
	.atlasmcp-header { position: sticky; top: var(--wp-admin--admin-bar--height, 46px); padding: 0 12px; }
	.atlasmcp-header-actions { display: none; }
	.atlasmcp-work { display: block; }
	.atlasmcp-main, .atlasmcp-split, .atlasmcp-split-main { display: block; min-height: 0; }
	.atlasmcp-scroll { overflow: visible; }
	.atlasmcp-split-side { display: none; }
	.atlasmcp-split-side.atlasmcp-steps-side { display: block; width: auto; border-right: 0; border-bottom: 1px solid var(--atlasmcp-line, #e0e0e0); overflow-x: auto; }
	.atlasmcp-steps { display: flex; gap: 4px; padding: 8px; }
	.atlasmcp-step-label, .atlasmcp-steps-note { display: none; }
	.atlasmcp-step.is-current .atlasmcp-step-label { display: inline; }
	.atlasmcp-pad { padding: 16px; }
	.atlasmcp-toolbar { padding: 12px; }
	.atlasmcp-toolbar .components-search-control { width: 100%; }
	.atlasmcp-toolbar .atlasmcp-toolbar-end { margin-left: 0; width: 100%; justify-content: space-between; }
	.atlasmcp-tabs { padding: 0 8px; }
	.atlasmcp-tabs { flex-wrap: wrap; }
	.atlasmcp-tabs .atlasmcp-tabs-end { margin-left: 0; width: 100%; justify-content: space-between; padding: 8px 0; flex-wrap: wrap; white-space: normal; }
	.atlasmcp-footer { position: sticky; bottom: 32px; z-index: 15; }
	.atlasmcp-status { position: sticky; bottom: 0; gap: 8px; height: 32px; z-index: 16; }
	.atlasmcp-hide-sm { display: none !important; }
	.atlasmcp-drawer { width: 100vw; }
	.atlasmcp-kv { grid-template-columns: minmax(0, 1fr); gap: 2px; }
	.atlasmcp-kv dd { margin-bottom: 8px; }
	.atlasmcp-snackbars { left: 16px; bottom: 48px; }
	.atlasmcp-section-head .atlasmcp-section-end { margin-left: 0; }
	.atlasmcp-address { flex-direction: column; align-items: stretch; }
	.atlasmcp-banner-actions { align-items: stretch; width: 100%; }
	.atlasmcp-toolbar .components-select-control { flex: 1 1 140px; }
	.atlasmcp-grid.is-4 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
	.atlasmcp-source-body { padding-left: 0; }
	.atlasmcp-params > div { grid-template-columns: minmax(0, 1fr); gap: 2px; }
	.atlasmcp-savebar { bottom: 40px; }
	.atlasmcp-access-role { flex: 1 1 100%; min-width: 0; }
	.atlasmcp-access-actions { margin-left: 0; }
	.atlasmcp-access-modes { margin-left: 0; width: 100%; justify-content: flex-start; flex-wrap: wrap; }
	.atlasmcp-workflow-find { flex-wrap: wrap; }
	.atlasmcp-shop-how { flex-direction: column; align-items: flex-start; }
	.atlasmcp-shop-steps, .atlasmcp-shop-button { grid-template-columns: minmax(0, 1fr); }
	.atlasmcp-main.is-embedded > .atlasmcp-footer { position: static; }
	.atlasmcp-experiments-hideall .components-toggle-control__label { white-space: normal; }
	.atlasmcp-table td .components-select-control { min-width: 150px; }
	.atlasmcp-errors-hook { grid-template-columns: minmax(0, 1fr); }
	.atlasmcp-experiments-table th:nth-child(2), .atlasmcp-experiments-table td:nth-child(2), .atlasmcp-experiments-table th:nth-child(3), .atlasmcp-experiments-table td:nth-child(3) { display: none; }
	.atlasmcp-plans-nocard { display: none; }
}

@media (prefers-reduced-motion: reduce) {
	.atlasmcp-root *, .atlasmcp-drawer, .atlasmcp-drawer-backdrop, .atlasmcp-rail { transition: none !important; animation: none !important; }
}

/* ---------- AI-88: safety foundation (Changes, Checkpoints, presets) ---------- */
.atlasmcp-activity-top { padding-top: 16px; }
.atlasmcp-activity-top:empty { display: none; }
.atlasmcp-diff { display: flex; flex-direction: column; gap: 10px; }
.atlasmcp-diff-row { display: grid; gap: 4px; min-width: 0; }
.atlasmcp-diff-row del, .atlasmcp-diff-row ins { display: block; padding: 6px 8px; border-radius: 4px; text-decoration: none; overflow-wrap: anywhere; white-space: pre-wrap; }
.atlasmcp-diff-row del { background: var(--atlasmcp-error-weak); color: var(--atlasmcp-error); }
.atlasmcp-diff-row del::before { content: "Before  "; font-weight: 600; }
.atlasmcp-diff-row ins { background: var(--atlasmcp-ok-weak); color: var(--atlasmcp-ok); }
.atlasmcp-diff-row ins::before { content: "After  "; font-weight: 600; }
.atlasmcp-preset { display: flex; flex-direction: column; gap: 8px; }
.atlasmcp-radio-row { display: flex; align-items: flex-start; gap: 12px; padding: 12px 16px; border: 1px solid var(--atlasmcp-line, #e0e0e0); border-radius: var(--atlasmcp-radius, 4px); cursor: pointer; background: var(--atlasmcp-surface, #fff); }
.atlasmcp-radio-row.is-on { background: var(--atlasmcp-brand-weak, #f3effd); border-color: var(--atlasmcp-brand, #6d28d9); }
.atlasmcp-radio-row input { accent-color: var(--atlasmcp-brand, #6d28d9); width: 16px; height: 16px; margin: 2px 0 0; flex: none; }
.atlasmcp-radio-row > span { display: flex; flex-direction: column; min-width: 0; overflow-wrap: anywhere; }
.atlasmcp-checkpoint-form { display: flex; flex-direction: column; gap: 16px; }
.atlasmcp-checkpoints .atlasmcp-ellipsis { display: block; max-width: 360px; }
.atlasmcp-checkpoints .atlasmcp-td-end .atlasmcp-inline { flex-wrap: nowrap; }
.atlasmcp-consent { display: flex; flex-direction: column; gap: 12px; padding: 16px; border: 1px solid var(--atlasmcp-line, #e0e0e0); border-radius: var(--atlasmcp-radius-lg, 8px); background: var(--atlasmcp-canvas, #f4f4f4); }
.atlasmcp-consent fieldset { border: 0; margin: 0; padding: 0; }
.atlasmcp-consent .atlasmcp-list { margin: 0; padding-left: 18px; display: flex; flex-direction: column; gap: 4px; }

/* ---------- Everything your role can do (AI-89) ---------- */
.atlasmcp-gap-l { margin-top: 16px; }
.atlasmcp-limits-banner { margin: 0 0 8px; }
.atlasmcp-job { display: flex; align-items: center; gap: 8px; margin-top: 6px; max-width: 320px; }
.atlasmcp-job .atlasmcp-meter { flex: 1; height: 6px; }
.atlasmcp-sql { width: 100%; min-height: 72px; font-family: var(--atlasmcp-mono); font-size: 12px; }
.atlasmcp-sql textarea { font-family: var(--atlasmcp-mono); font-size: 12px; line-height: 1.6; }
.atlasmcp-setting { display: flex; flex-direction: column; gap: 2px; min-width: 0; text-align: left; }
.atlasmcp-setting label, .atlasmcp-setting b { display: block; }

/* AI-91 Workflows v2: builder (conditions, actions with inputs), run step log, copyable values. */
.atlasmcp-gap-top { margin-top: 12px; }
.atlasmcp-cond { display: grid; grid-template-columns: minmax(0, 1.3fr) minmax(0, 1fr) minmax(0, 1fr) auto; gap: 6px; align-items: center; }
.atlasmcp-cond .atlasmcp-cond-custom { grid-column: 1 / -1; }
.atlasmcp-addlist { display: flex; flex-wrap: wrap; gap: 4px; margin-top: 8px; }
.atlasmcp-actions { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; border: 1px solid var(--atlasmcp-line, #e0e0e0); border-radius: var(--atlasmcp-radius-lg, 8px); }
.atlasmcp-actions > li { margin: 0; padding: 8px 8px 8px 12px; border-top: 1px solid var(--atlasmcp-line-weak, #f0f0f0); min-width: 0; }
.atlasmcp-actions > li:first-child { border-top: 0; }
.atlasmcp-actions .atlasmcp-grow { display: flex; flex-direction: column; min-width: 0; flex: 1; }
.atlasmcp-actions .atlasmcp-between { gap: 8px; align-items: center; }
.atlasmcp-actions .atlasmcp-inline { flex: none; gap: 0; }
.atlasmcp-steplog { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 10px; }
.atlasmcp-steplog li { display: flex; gap: 8px; align-items: flex-start; margin: 0; }
.atlasmcp-steplog li > span { display: flex; flex-direction: column; min-width: 0; overflow-wrap: anywhere; }
.atlasmcp-steplog li > svg { flex: none; }
.atlasmcp-steplog li.is-ok > svg { color: var(--atlasmcp-ok); fill: currentColor; }
.atlasmcp-steplog li.is-skip > svg { color: #949494; fill: currentColor; }
.atlasmcp-steplog li.is-error > svg { color: var(--atlasmcp-error); fill: currentColor; }
.atlasmcp-copyable { display: flex; align-items: flex-end; gap: 8px; margin-bottom: 12px; }
.atlasmcp-copyable .components-base-control { flex: 1; min-width: 0; }
.atlasmcp-copyable input { font-family: var(--atlasmcp-mono, monospace); font-size: 12px; }
@media (max-width: 600px) {
	.atlasmcp-cond { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); }
	.atlasmcp-actions .atlasmcp-between { flex-wrap: wrap; }
}

/* AI-93 Plans: the "direct, no middleman, no limits" line; four plans wrap to one column on phones. */
.atlasmcp-claim { display: flex; align-items: center; flex-wrap: wrap; gap: 4px 8px; padding: 12px 16px; border-radius: var(--atlasmcp-radius-lg, 8px); background: var(--atlasmcp-brand-weak, #f3effe); color: var(--atlasmcp-brand); margin: 0 0 16px; }
.atlasmcp-claim .atlasmcp-weak { flex-basis: 100%; }
@media (max-width: 600px) {
	.atlasmcp-grid.is-4.atlasmcp-plans { grid-template-columns: minmax(0, 1fr); }
}
