.admin-shell {
  --admin-ink: #182027;
  --admin-muted: #66727b;
  --admin-faint: #929ca3;
  --admin-line: #dfe4e7;
  --admin-page: #f5f7f8;
  --admin-surface: #fff;
  --admin-soft: #eef2f4;
  --admin-accent: #2864dc;
  --admin-accent-soft: #edf3ff;
  --admin-green: #24765f;
  --admin-green-soft: #e8f4ef;
  --admin-amber: #8a5a1d;
  --admin-amber-soft: #fff3df;
  color-scheme: light;
  display: grid;
  width: 100%;
  max-width: 100%;
  min-height: 100dvh;
  grid-template-columns: 176px minmax(0, 1fr);
  overflow-x: hidden;
  color: var(--admin-ink);
  background: var(--admin-page);
}

.admin-shell *,
.admin-shell *::before,
.admin-shell *::after { box-sizing: border-box; letter-spacing: 0; }
.admin-shell button,
.admin-shell input,
.admin-shell textarea { font: inherit; }
.admin-shell .sidebar { position: sticky; top: 0; display: flex; width: 176px; height: 100dvh; flex-direction: column; border: 0; border-right: 1px solid #29343c; padding: 22px 12px; color: #dfe6ea; background: #202a31; }
.admin-shell .brand { padding: 0 10px; color: #fff; font-size: 16px; font-weight: 800; }
.admin-shell .admin-nav { display: grid; gap: 3px; margin-top: 25px; }
.admin-shell .admin-nav a { min-height: 38px; border-radius: 6px; padding: 10px 12px; color: #9eabb3; font-size: 12px; font-weight: 600; }
.admin-shell .admin-nav a:hover { color: #fff; background: #29353d; }
.admin-shell .admin-nav a.active { color: #fff; background: #34424b; }

.admin-sidebar-footer { display: grid; gap: 9px; margin-top: auto; padding: 14px 10px 0; border-top: 1px solid #344149; color: #9eabb3; font-size: 11px; }
.admin-logout { width: max-content; border: 0; padding: 0; color: #cbd4d8; background: transparent; font-size: 11px; cursor: pointer; }
.admin-logout:hover { color: #fff; }

.admin-login-page { display: grid; min-height: 100dvh; place-items: center; padding: 24px; background: #f5f7f8; }
.admin-login-panel { width: min(420px, 100%); padding: 38px; border: 1px solid #dfe4e7; border-radius: 8px; background: #fff; box-shadow: 0 18px 55px #18202712; }
.admin-login-kicker { color: #2864dc; font-size: 11px; font-weight: 800; letter-spacing: .08em; }
.admin-login-panel h1 { margin: 14px 0 5px; color: #182027; font-size: 26px; line-height: 1.2; }
.admin-login-subtitle { margin: 0 0 26px; color: #66727b; font-size: 12px; }
.admin-login-form { display: grid; gap: 16px; }
.admin-login-form label { display: grid; gap: 7px; color: #66727b; font-size: 12px; font-weight: 700; }
.admin-login-form input:not([type="hidden"]) { width: 100%; height: 44px; border: 1px solid #dfe4e7; border-radius: 6px; padding: 0 12px; color: #182027; background: #fff; font-size: 15px; outline: none; }
.admin-login-form input:focus { border-color: #2864dc; box-shadow: 0 0 0 3px #2864dc18; }
.admin-login-submit { height: 44px; margin-top: 4px; border: 1px solid #2864dc; border-radius: 6px; color: #fff; background: #2864dc; font-size: 13px; font-weight: 800; cursor: pointer; }
.admin-login-submit:hover { background: #2058c6; }
.admin-login-error { margin: 0 0 16px; border-radius: 5px; padding: 10px 12px; color: #a43f39; background: #fff0ee; font-size: 12px; }

.admin-shell .admin-main { width: 100%; max-width: 1440px; min-width: 0; margin: 0 auto; padding: 28px 28px 48px; }
.admin-shell .admin-page-head,
.admin-shell .ip-admin-topbar,
.admin-shell .catalog-admin-topbar { display: flex; min-height: 40px; align-items: center; justify-content: space-between; gap: 16px; margin: 0 0 18px; }
.admin-shell .admin-page-head > div { display: flex; min-width: 0; align-items: baseline; gap: 9px; }
.admin-shell .admin-page-head h1,
.admin-shell .ip-admin-topbar h1,
.admin-shell .catalog-admin-topbar h1 { margin: 0; color: var(--admin-ink); font-size: 23px; font-weight: 800; line-height: 1.2; }
.admin-shell .admin-page-head span { color: var(--admin-muted); font-size: 12px; }
.admin-shell .primary,
.admin-shell .secondary { display: inline-flex; min-height: 38px; align-items: center; justify-content: center; border-radius: 6px; padding: 0 14px; font-size: 12px; font-weight: 700; white-space: nowrap; cursor: pointer; }
.admin-shell .primary { border: 1px solid var(--admin-accent); color: #fff; background: var(--admin-accent); }
.admin-shell .secondary { border: 1px solid var(--admin-line); color: var(--admin-ink); background: var(--admin-surface); }
.admin-shell .primary:hover { background: #2058c6; }
.admin-shell .secondary:hover { border-color: #aeb8be; background: var(--admin-soft); }

.admin-shell .admin-stats { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); overflow: hidden; margin: 0 0 12px; border: 1px solid var(--admin-line); border-radius: 7px; background: var(--admin-surface); }
.admin-shell .admin-stats > div { display: flex; min-width: 0; min-height: 58px; align-items: center; justify-content: space-between; gap: 10px; border-right: 1px solid var(--admin-line); padding: 0 16px; }
.admin-shell .admin-stats > div:last-child { border-right: 0; }
.admin-shell .admin-stats span { color: var(--admin-muted); font-size: 11px; }
.admin-shell .admin-stats strong { margin: 0; color: var(--admin-ink); font-size: 18px; font-variant-numeric: tabular-nums; }

.admin-shell .project-panel,
.admin-shell .catalog-admin-layout,
.admin-shell .ip-list-panel { min-width: 0; overflow: visible; border: 1px solid var(--admin-line); border-radius: 7px; background: var(--admin-surface); }
.admin-shell .admin-toolbar,
.admin-shell .catalog-actions { min-height: 58px; border-bottom: 1px solid var(--admin-line); padding: 9px 12px; background: var(--admin-surface); }
.admin-shell .admin-search { display: grid; width: min(520px, 100%); grid-template-columns: minmax(0, 1fr) auto; gap: 7px; padding: 0; border: 0; }
.admin-shell .admin-search input,
.admin-shell .catalog-search input,
.admin-shell .catalog-create > input[type="text"] { min-width: 0; min-height: 38px; border: 1px solid var(--admin-line); border-radius: 6px; padding: 0 11px; color: var(--admin-ink); background: var(--admin-page); font-size: 12px; outline: none; }
.admin-shell .admin-search input:focus,
.admin-shell .catalog-search input:focus,
.admin-shell .catalog-create > input[type="text"]:focus { border-color: var(--admin-accent); background: var(--admin-surface); box-shadow: 0 0 0 2px #2864dc18; }

.project-table-head,
.project-summary { display: grid; grid-template-columns: minmax(240px, 2fr) minmax(112px, .8fr) 56px 72px 76px 112px; align-items: center; gap: 12px; }
.project-table-head,
.ip-table-head,
.taxonomy-table-head,
.member-table-head { min-height: 34px; border-bottom: 1px solid var(--admin-line); padding: 0 14px; color: var(--admin-faint); background: #fafbfb; font-size: 11px; font-weight: 700; }
.admin-shell .project-list { display: grid; }
.admin-shell .project-row { min-width: 0; border-bottom: 1px solid var(--admin-line); }
.admin-shell .project-row:last-child { border-bottom: 0; }
.admin-shell .project-summary { min-height: 64px; padding: 9px 14px; }
.admin-shell .project-cover { display: grid; width: 40px; height: 40px; flex: 0 0 40px; overflow: hidden; place-items: center; border-radius: 6px; color: #6b7680; background: var(--admin-soft); font-size: 12px; font-weight: 800; }
.admin-shell .project-cover img { width: 100%; height: 100%; object-fit: contain; }
.admin-shell .project-summary > .project-cover { grid-column: 1; grid-row: 1; }
.admin-shell .project-identity { display: grid; min-width: 0; grid-column: 1; grid-row: 1; gap: 2px; padding-left: 52px; }
.admin-shell .project-identity span { overflow: hidden; color: var(--admin-muted); font-size: 11px; text-overflow: ellipsis; white-space: nowrap; }
.admin-shell .project-identity h2 { overflow: hidden; margin: 0; color: var(--admin-ink); font-size: 13px; font-weight: 800; text-overflow: ellipsis; white-space: nowrap; }
.admin-shell .project-fact span { display: block; color: var(--admin-faint); font-size: 11px; }
.admin-shell .project-fact b { display: block; margin-top: 2px; font-size: 11px; font-weight: 700; }
.admin-shell .status { display: inline-flex; width: max-content; max-width: 100%; align-items: center; border-radius: 5px; padding: 4px 7px; color: var(--admin-amber); background: var(--admin-amber-soft); font-size: 11px; font-weight: 700; white-space: nowrap; }
.admin-shell .status.success { color: var(--admin-green); background: var(--admin-green-soft); }
.admin-shell .status.muted { color: var(--admin-muted); background: var(--admin-soft); }
.admin-shell .project-sync { font-size: 11px; font-weight: 700; white-space: nowrap; }
.admin-shell .sync-ok { color: var(--admin-green); }
.admin-shell .sync-pending { color: var(--admin-amber); }
.admin-shell .sync-error { color: #b44d46; }
.project-row-actions,
.ip-row-actions,
.taxonomy-row-actions { display: flex; justify-content: flex-end; gap: 5px; }
.project-row-actions { min-width: 0; flex-wrap: wrap; }
.project-row-actions form { display: contents; }
.project-row-actions button,
.ip-row-actions button,
.taxonomy-row-actions button,
.row-panel > header button { min-height: 30px; border: 1px solid var(--admin-line); border-radius: 5px; padding: 0 9px; color: var(--admin-muted); background: var(--admin-surface); font-size: 11px; font-weight: 700; cursor: pointer; }
.project-row-actions button:hover,
.project-row-actions button.is-active,
.ip-row-actions button:hover,
.ip-row-actions button.is-active,
.taxonomy-row-actions button:hover,
.taxonomy-row-actions button.is-active { border-color: var(--admin-accent); color: var(--admin-accent); background: var(--admin-accent-soft); }
.project-row-actions .row-action-toggle { color: var(--admin-amber); }
.project-row-actions .row-action-danger { border-color: #efd5d2; color: #b44d46; }
.project-row-actions .row-action-danger:hover { border-color: #d79a94; color: #9e3933; background: #fff2f0; }

.admin-shell .row-panel { border-top: 1px solid var(--admin-line); padding: 14px; background: #f8fafb; }
.admin-shell .row-panel[hidden] { display: none; }
.admin-shell .row-panel > header { display: flex; min-height: 30px; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 12px; }
.admin-shell .row-panel > header h3 { margin: 0; font-size: 12px; }
.admin-shell .row-panel > header > div { display: grid; min-width: 0; gap: 3px; }
.admin-shell .row-panel > header > div > span { color: var(--admin-faint); font-size: 10px; }
.admin-shell .row-panel > header button { border: 0; background: transparent; }
.admin-shell .price-editor-list { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 7px; padding: 0; }
.admin-shell .price-editor-row { display: grid; min-width: 0; grid-template-columns: minmax(70px, 1fr) 100px 52px; align-items: center; gap: 6px; border: 1px solid var(--admin-line); border-radius: 6px; padding: 6px; background: var(--admin-surface); }
.admin-shell .price-editor-row b { overflow: hidden; font-size: 12px; text-overflow: ellipsis; white-space: nowrap; }
.admin-shell .price-editor-row input,
.admin-shell .project-edit-form input:not([type="file"]),
.admin-shell .ip-profile-form input,
.admin-shell .taxonomy-editor input { min-width: 0; height: 34px; border: 1px solid var(--admin-line); border-radius: 5px; padding: 0 8px; color: var(--admin-ink); background: var(--admin-surface); font-size: 12px; }
.admin-shell .price-editor-row .secondary { min-height: 34px; padding: 0 9px; }
.admin-shell .status-editor-list { display: grid; gap: 6px; min-width: 0; }
.admin-shell .status-editor-empty { margin: 0; border: 1px dashed var(--admin-line); border-radius: 6px; padding: 18px; color: var(--admin-muted); background: var(--admin-surface); font-size: 11px; text-align: center; }
.admin-shell .status-editor-row { display: grid; min-width: 0; grid-template-columns: minmax(170px, 1.5fr) minmax(130px, 1fr) minmax(130px, 1fr) auto; align-items: end; gap: 8px; border: 1px solid var(--admin-line); border-radius: 6px; padding: 8px; background: var(--admin-surface); }
.admin-shell .status-editor-identity { display: grid; min-width: 0; align-content: center; gap: 3px; min-height: 34px; }
.admin-shell .status-editor-identity b { overflow: hidden; color: var(--admin-ink); font-size: 12px; text-overflow: ellipsis; white-space: nowrap; }
.admin-shell .status-editor-identity span { overflow: hidden; color: var(--admin-muted); font-size: 10px; text-overflow: ellipsis; white-space: nowrap; }
.admin-shell .status-editor-field { display: grid; min-width: 0; gap: 4px; color: var(--admin-muted); font-size: 10px; font-weight: 700; }
.admin-shell .status-editor-field .custom-select-trigger { width: 100%; min-width: 0; min-height: 34px; }
.admin-shell .status-editor-row > .secondary { min-height: 34px; padding: 0 10px; }
.admin-shell .project-edit-form { display: grid; gap: 11px; padding: 0; }
.admin-shell .project-edit-form .form-grid { gap: 8px; margin: 0; }
.admin-shell .project-edit-form label,
.admin-shell .project-edit-form .form-field { display: grid; gap: 5px; color: var(--admin-muted); font-size: 11px; font-weight: 700; }
.admin-shell .edit-toggles { display: flex; flex-wrap: wrap; gap: 18px; padding: 4px 0; }
.admin-shell .toggle-control { display: inline-flex !important; width: max-content; align-items: center; gap: 7px !important; margin: 0; color: var(--admin-ink) !important; }
.admin-shell .toggle-control > button { position: relative; width: 32px; height: 18px; border: 0; border-radius: 9px; padding: 0; background: #cbd2d6; cursor: pointer; }
.admin-shell .toggle-control > button span { position: absolute; top: 3px; left: 3px; width: 12px; height: 12px; border-radius: 50%; background: #fff; box-shadow: none; }
.admin-shell .toggle-control > button.is-on { background: var(--admin-accent); }
.admin-shell .toggle-control > button.is-on span { transform: translateX(14px); }
.admin-shell .toggle-control b { font-size: 11px; }
.admin-shell .project-edit-actions { display: flex; justify-content: flex-end; padding-top: 2px; }
.admin-shell .project-danger-action,
.admin-shell .ip-danger-action { margin-top: 12px; padding-top: 10px; border-top: 1px solid var(--admin-line); }
.admin-shell .danger-link { border: 0; padding: 0; color: #b24e48; background: transparent; font-size: 11px; cursor: pointer; }

.admin-shell .pagination { display: flex; justify-content: flex-end; gap: 5px; border-top: 1px solid var(--admin-line); padding: 10px 12px; }
.admin-shell .pagination a,
.admin-shell .pagination .current { min-width: 30px; border: 1px solid var(--admin-line); border-radius: 5px; padding: 6px 9px; color: var(--admin-muted); background: var(--admin-surface); font-size: 11px; text-align: center; }
.admin-shell .pagination .current { color: #fff; background: var(--admin-ink); }
.admin-shell .admin-blank,
.admin-shell .catalog-empty,
.admin-shell .ip-empty { display: grid; min-height: 220px; place-items: center; align-content: center; gap: 12px; color: var(--admin-muted); font-size: 11px; }

.admin-shell .catalog-actions { display: grid; grid-template-columns: minmax(260px, 1fr) minmax(420px, auto); gap: 10px; }
.admin-shell .catalog-search,
.admin-shell .catalog-create { display: flex; min-width: 0; gap: 7px; }
.admin-shell .catalog-search input { flex: 1; }
.admin-shell .catalog-create > input[type="text"] { width: 170px; background: var(--admin-surface); }
.taxonomy-table-head,
.taxonomy-entry { display: grid; grid-template-columns: minmax(220px, 1fr) 80px 80px; align-items: center; gap: 12px; }
.admin-shell .taxonomy-entry { position: relative; min-height: 56px; border-bottom: 1px solid var(--admin-line); padding: 8px 14px; }
.admin-shell .taxonomy-entry:last-child { border-bottom: 0; }
.admin-shell .taxonomy-cover { width: 36px; height: 36px; grid-column: 1; grid-row: 1; border-radius: 6px; color: var(--admin-muted); background: var(--admin-soft); }
.admin-shell .taxonomy-cover img { object-fit: contain; }
.admin-shell .taxonomy-entry-main { min-width: 0; grid-column: 1; grid-row: 1; padding-left: 48px; }
.admin-shell .taxonomy-entry-main b { overflow: hidden; font-size: 13px; text-overflow: ellipsis; white-space: nowrap; }
.admin-shell .taxonomy-cover-state { color: var(--admin-muted); font-size: 11px; }
.admin-shell .taxonomy-editor { grid-column: 1 / -1; margin: 0 -14px -8px; }
.admin-shell .taxonomy-editor form { display: grid; grid-template-columns: minmax(160px, 1fr) minmax(220px, 1fr) auto; gap: 8px; }

.ip-table-head,
.ip-config-head { display: grid; grid-template-columns: minmax(220px, 1.5fr) minmax(150px, 1fr) 48px 76px 112px; align-items: center; gap: 12px; }
.admin-shell .ip-config { min-width: 0; border-bottom: 1px solid var(--admin-line); padding: 0; }
.admin-shell .ip-config:last-child { border-bottom: 0; }
.admin-shell .ip-config-head { min-height: 62px; padding: 8px 14px; }
.admin-shell .ip-config-head .cover { width: 38px; height: 38px; grid-column: 1; grid-row: 1; border-radius: 6px; }
.admin-shell .ip-config-head .cover img { object-fit: contain; }
.admin-shell .ip-config-name { min-width: 0; grid-column: 1; grid-row: 1; padding-left: 50px; }
.admin-shell .ip-config-name h3 { margin: 0; font-size: 12px; }
.admin-shell .ip-table-id { overflow: hidden; color: var(--admin-muted); font-family: ui-monospace, SFMono-Regular, Consolas, monospace; font-size: 11px; text-overflow: ellipsis; white-space: nowrap; }
.admin-shell .ip-allocation-limit { font-size: 12px; font-variant-numeric: tabular-nums; }
.admin-shell .ip-profile-editor,
.admin-shell .field-map { margin: 0; }
.admin-shell .ip-profile-form { display: grid; grid-template-columns: minmax(180px, 1fr) minmax(240px, 1.5fr) auto; gap: 8px; padding: 0; }
.admin-shell .field-map-form { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 8px; margin: 0; padding: 0; background: transparent; }
.admin-shell .field-map-field { display: grid; min-width: 0; gap: 4px; color: var(--admin-muted); font-size: 11px; font-weight: 700; }
.admin-shell .field-map-form > .secondary { align-self: end; min-height: 40px; }

.ip-create-dialog { position: fixed; inset: 0; width: min(760px, calc(100vw - 32px)); max-height: min(760px, calc(100dvh - 32px)); margin: auto; overflow: auto; border: 0; border-radius: 8px; padding: 0; color: var(--admin-ink); background: var(--admin-surface); box-shadow: 0 24px 80px #17212635; }
.ip-create-dialog::backdrop { background: #17212666; }
.ip-create-dialog > header { display: flex; min-height: 54px; align-items: center; justify-content: space-between; border-bottom: 1px solid var(--admin-line); padding: 0 18px; }
.ip-create-dialog > header h2 { margin: 0; font-size: 16px; }
.ip-create-dialog > header button { width: 30px; height: 30px; border: 0; border-radius: 5px; color: var(--admin-muted); background: var(--admin-soft); font-size: 18px; cursor: pointer; }
.ip-create-dialog .ip-create-form { display: grid; margin: 0; }
.ip-create-fields { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; padding: 18px; }
.admin-shell .ip-create-field { display: grid; min-width: 0; gap: 6px; color: var(--admin-muted); font-size: 11px; font-weight: 700; }
.admin-shell .ip-create-field input { width: 100%; min-width: 0; min-height: 40px; border: 1px solid var(--admin-line); border-radius: 6px; padding: 0 10px; color: var(--admin-ink); background: var(--admin-surface); font-size: 12px; }
.ip-create-dialog footer { display: flex; justify-content: flex-end; gap: 7px; border-top: 1px solid var(--admin-line); padding: 11px 18px; }
.query-import-preview { display: grid; gap: 9px; border-top: 1px solid var(--admin-line); padding: 14px 18px; }
.query-import-preview > header { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.query-import-preview > header b { font-size: 12px; }
.query-import-preview > header span { color: var(--admin-muted); font-size: 11px; }
.query-import-preview > header span.is-error { color: #b24e48; }
.query-import-list { display: grid; gap: 6px; max-height: 280px; overflow: auto; }
.query-import-item { display: grid; grid-template-columns: 20px minmax(180px, 240px) minmax(0, 1fr); align-items: center; gap: 8px; border: 1px solid var(--admin-line); border-radius: 6px; padding: 7px 9px; }
.query-import-item input[type="text"] { width: 100%; min-width: 0; height: 34px; border: 1px solid var(--admin-line); border-radius: 5px; padding: 0 8px; font-size: 11px; }
.query-import-item p { margin: 0; color: var(--admin-muted); font-size: 10px; line-height: 1.45; }
.query-import-item.is-unsupported { background: var(--admin-soft); opacity: .72; }

.member-table-head,
.member-row { display: grid; grid-template-columns: minmax(220px, 1fr) 140px 112px; align-items: center; gap: 16px; }
.admin-shell .member-row { min-height: 54px; border-bottom: 1px solid var(--admin-line); padding: 7px 14px; }
.admin-shell .member-row:last-child { border-bottom: 0; }
.admin-shell .member-identity { display: grid; gap: 2px; }
.admin-shell .member-identity b { font-size: 13px; }
.admin-shell .member-row small { color: var(--admin-muted); font-size: 11px; }
.admin-shell .member-permission-form { justify-self: start; }
.admin-shell .member-permission-form .toggle-control { cursor: pointer; }

.admin-shell .group-dialog { width: min(1040px, calc(100vw - 32px)); height: min(800px, calc(100dvh - 32px)); max-height: calc(100dvh - 32px); border-radius: 8px; }
.admin-shell .group-dialog-head { height: 56px; padding: 0 18px; }
.admin-shell .group-dialog-head h2 { font-size: 16px; }
.admin-shell .group-create-form { display: grid; height: calc(100% - 56px); max-height: none; grid-template-rows: minmax(0, 1fr) auto; overflow: hidden; padding: 0; }
.admin-shell .group-create-workspace { display: grid; min-width: 0; min-height: 0; grid-template-columns: minmax(0, 1fr) 280px; overflow-y: auto; }
.admin-shell .group-create-main { min-width: 0; }
.admin-shell .form-section { padding: 15px 18px; }
.admin-shell .form-section:last-child { border-bottom: 0; }
.admin-shell .form-section h3,
.admin-shell .group-create-assets h3 { margin: 0 0 11px; color: var(--admin-ink); font-size: 12px; font-weight: 800; }
.admin-shell .group-create-form label,
.admin-shell .group-create-form .form-field { color: var(--admin-muted); font-size: 11px; }
.admin-shell .group-create-form input:not([type="checkbox"]):not([type="file"]),
.admin-shell .group-create-form textarea { min-height: 38px; border-radius: 6px; font-size: 12px; }
.admin-shell .group-create-form textarea { min-height: 88px; resize: vertical; }
.admin-shell .group-create-form .form-grid.two { gap: 10px; margin: 0; }
.admin-shell .schedule-dates { margin-bottom: 10px !important; }
.admin-shell .schedule-settings { display: grid; grid-template-columns: 132px minmax(120px, 1fr) auto; align-items: end; gap: 10px; }
.admin-shell .create-toggles { display: flex; min-height: 38px; align-items: center; gap: 16px; padding: 0 2px; }
.admin-shell .role-section { padding-bottom: 18px; }
.admin-shell .role-section > label + label { margin-top: 10px; }
.admin-shell .catalog-picker { max-width: 100%; overflow-x: auto; margin-top: 8px; }
.admin-shell .option-price-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 7px; margin-top: 10px; }
.admin-shell .option-price-grid label { gap: 5px; border-radius: 6px; padding: 7px; background: var(--admin-page); }
.admin-shell .option-price-grid input { min-height: 34px !important; }
.admin-shell .group-create-assets { min-width: 0; border-left: 1px solid var(--admin-line); padding: 15px; background: #f7f9fa; }
.admin-shell .asset-upload { display: grid; gap: 8px; border-top: 1px solid var(--admin-line); padding: 14px 0; }
.admin-shell .asset-upload:first-of-type { border-top: 0; padding-top: 0; }
.admin-shell .asset-upload b { color: var(--admin-ink); font-size: 11px; }
.admin-shell .group-create-assets .file-picker { grid-template-columns: 1fr; gap: 6px; }
.admin-shell .group-create-assets .file-picker-button { width: 100%; justify-content: flex-start; background: var(--admin-surface); }
.admin-shell .group-create-assets .file-picker-name { min-height: 18px; }
.admin-shell .group-cover-preview { width: 100%; max-height: 300px; aspect-ratio: 4 / 3; border: 1px solid var(--admin-line); border-radius: 6px; object-fit: contain; background: var(--admin-surface); }
.admin-shell .ocr-submit { width: 100%; }
.admin-shell .ocr-submit:disabled { border-color: var(--admin-line); color: var(--admin-faint); background: #eef1f2; cursor: default; }
.admin-shell .ocr-feedback { min-width: 0; }
.admin-shell .ocr-status,
.admin-shell .ocr-result { border-radius: 6px; padding: 9px 10px; font-size: 11px; }
.admin-shell .ocr-status { color: var(--admin-accent); background: var(--admin-accent-soft); }
.admin-shell .ocr-result p { margin: 3px 0 0; }
.admin-shell .group-dialog-actions { position: static; flex: 0 0 auto; padding: 10px 18px; background: var(--admin-surface); backdrop-filter: none; }
.admin-shell .group-dialog-actions > * { min-width: 84px; }
.admin-shell .custom-select-trigger,
.admin-shell .file-picker-button { border-color: var(--admin-line); border-radius: 6px; color: var(--admin-ink); background: var(--admin-surface); }
.admin-shell .custom-select-trigger { min-height: 38px; }
.admin-shell .file-picker-name { color: var(--admin-muted); }

@media (max-width: 1050px) {
  .project-table-head,
  .project-summary { grid-template-columns: minmax(220px, 2fr) minmax(104px, .8fr) 52px 68px 104px; }
  .project-table-head span:nth-child(5),
  .project-summary > .project-sync { display: none; }
  .admin-shell .price-editor-list { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .admin-shell .status-editor-row { grid-template-columns: minmax(150px, 1.2fr) repeat(2, minmax(120px, 1fr)) auto; }
  .admin-shell .field-map-form { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}

@media (max-width: 800px) {
  .admin-shell { display: block; }
  .admin-shell .sidebar { position: sticky; z-index: 10; top: 0; display: grid; width: 100%; height: auto; grid-template-columns: auto minmax(0, 1fr); align-items: center; gap: 12px; border: 0; border-bottom: 1px solid #29343c; padding: 9px 12px; }
  .admin-shell .brand { padding: 0; font-size: 13px; }
  .admin-shell .admin-nav { display: flex; min-width: 0; gap: 2px; overflow-x: auto; margin: 0; scrollbar-width: none; }
  .admin-shell .admin-nav::-webkit-scrollbar { display: none; }
  .admin-shell .admin-nav a { min-height: 32px; flex: 0 0 auto; padding: 8px 10px; font-size: 11px; }
  .admin-shell .admin-main { padding: 18px 14px 36px; }
  .admin-shell .admin-stats { grid-template-columns: 1fr 1fr; }
  .admin-shell .admin-stats > div { min-height: 50px; }
  .admin-shell .admin-stats > div:nth-child(2) { border-right: 0; }
  .admin-shell .admin-stats > div:nth-child(-n+2) { border-bottom: 1px solid var(--admin-line); }
  .project-table-head,
  .project-summary { grid-template-columns: minmax(0, 1fr) 64px 100px; gap: 8px; }
  .project-table-head span:nth-child(2),
  .project-table-head span:nth-child(3),
  .project-table-head span:nth-child(5),
  .project-summary > .project-fact,
  .project-summary > .project-sync { display: none; }
  .project-table-head span:nth-child(4) { grid-column: 2; }
  .project-table-head span:nth-child(6) { grid-column: 3; text-align: right; }
  .admin-shell .price-editor-list { grid-template-columns: 1fr; }
  .admin-shell .status-editor-row { grid-template-columns: minmax(0, 1fr) minmax(108px, .8fr) minmax(108px, .8fr); }
  .admin-shell .status-editor-row > .secondary { grid-column: 3; justify-self: end; }
  .admin-shell .project-edit-form .form-grid.three,
  .admin-shell .project-edit-form .form-grid.four { grid-template-columns: 1fr 1fr; }
  .admin-shell .catalog-actions { grid-template-columns: 1fr; }
  .admin-shell .field-map-form { grid-template-columns: 1fr 1fr; }
  .ip-table-head,
  .ip-config-head { grid-template-columns: minmax(0, 1fr) 72px 104px; gap: 8px; }
  .ip-table-head span:nth-child(2),
  .ip-table-head span:nth-child(3),
  .ip-config-head > .ip-table-id,
  .ip-config-head > .ip-allocation-limit { display: none; }
  .ip-table-head span:nth-child(4) { grid-column: 2; }
  .ip-table-head span:nth-child(5) { grid-column: 3; text-align: right; }
  .admin-shell .ip-profile-form { grid-template-columns: 1fr; }
  .admin-shell .group-create-workspace { grid-template-columns: minmax(0, 1fr) 230px; }
  .admin-shell .schedule-settings { grid-template-columns: 120px minmax(110px, 1fr); }
  .admin-shell .create-toggles { grid-column: 1 / -1; }
  .admin-shell .option-price-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

@media (max-width: 520px) {
  .admin-shell .admin-page-head h1,
  .admin-shell .ip-admin-topbar h1,
  .admin-shell .catalog-admin-topbar h1 { font-size: 20px; }
  .admin-shell .admin-page-head > div { display: grid; gap: 2px; }
  .admin-shell .admin-stats span { font-size: 11px; }
  .admin-shell .admin-stats strong { font-size: 15px; }
  .admin-shell .project-cover { width: 36px; height: 36px; }
  .admin-shell .project-identity { padding-left: 46px; }
  .project-row-actions button,
  .ip-row-actions button { padding: 0 7px; }
  .admin-shell .project-edit-form .form-grid.three,
  .admin-shell .project-edit-form .form-grid.four { grid-template-columns: 1fr; }
  .admin-shell .catalog-create { display: grid; grid-template-columns: minmax(0, 1fr) auto; }
  .admin-shell .catalog-create > input[type="text"] { width: 100%; }
  .admin-shell .catalog-create .file-picker { grid-column: 1; }
  .admin-shell .catalog-create .primary { grid-column: 2; grid-row: 1 / 3; }
  .taxonomy-table-head,
  .taxonomy-entry { grid-template-columns: minmax(0, 1fr) 72px; }
  .taxonomy-table-head span:nth-child(2),
  .taxonomy-cover-state { display: none; }
  .taxonomy-table-head span:nth-child(3) { grid-column: 2; text-align: right; }
  .admin-shell .taxonomy-editor form { grid-template-columns: 1fr; }
  .member-table-head,
  .member-row { grid-template-columns: minmax(0, 1fr) 94px; gap: 8px; }
  .member-table-head span:nth-child(2),
  .member-row > small { display: none; }
  .member-table-head span:nth-child(3) { grid-column: 2; }
  .ip-create-dialog { width: 100vw; height: 100dvh; max-height: none; margin: 0; border-radius: 0; }
  .ip-create-fields { grid-template-columns: 1fr; }
  .admin-shell .group-dialog { width: 100vw; height: 100dvh; max-height: none; border-radius: 0; }
  .admin-shell .group-create-form { height: calc(100dvh - 56px); max-height: none; }
  .admin-shell .group-create-workspace { display: flex; flex-direction: column; }
  .admin-shell .group-create-main { display: contents; }
  .admin-shell .group-create-assets { order: 2; border-top: 1px solid var(--admin-line); border-left: 0; background: var(--admin-surface); }
  .admin-shell .role-section { order: 3; }
  .admin-shell .schedule-settings { grid-template-columns: 120px minmax(0, 1fr); }
  .admin-shell .create-toggles { gap: 12px; }
  .admin-shell .option-price-grid { grid-template-columns: 1fr; }
}
