:root { font-family: var(--font-body); color: var(--cat-ink-900); background: var(--cat-paper); font-synthesis: none; }
* { box-sizing: border-box; }
body { margin: 0; min-width: 320px; background: var(--cat-paper); }
button, input, select { font: inherit; }
button { cursor: pointer; }
button, .primary-button, .secondary-button, .text-button {
    -webkit-appearance: none;
    appearance: none;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    line-height: 1;
    text-decoration: none;
    white-space: nowrap;
    transition: background-color 140ms ease, border-color 140ms ease, color 140ms ease, box-shadow 140ms ease, transform 140ms ease;
}
button:focus-visible, .primary-button:focus-visible, .secondary-button:focus-visible, .text-button:focus-visible {
    outline: 3px solid color-mix(in oklab, var(--accent) 45%, transparent);
    outline-offset: 2px;
}
button:disabled, .primary-button[aria-disabled="true"], .secondary-button[aria-disabled="true"], .text-button[aria-disabled="true"] {
    cursor: not-allowed;
    opacity: .5;
    box-shadow: none;
}
.app-shell { min-height: 100vh; display: grid; grid-template-columns: 246px 1fr; }
.sidebar { position: sticky; top: 0; height: 100vh; padding: 28px 18px 20px; background: #1b1b1d; color: #d7d7db; display: flex; flex-direction: column; }
.brand { display: flex; align-items: center; gap: 11px; padding: 0 10px 30px; color: white; text-decoration: none; font: 700 20px var(--font-display); }
.brand em { color: #f58634; font-size: 12px; font-style: normal; vertical-align: super; }
.brand-mark { width: 31px; height: 31px; display: grid; place-items: center; border: 2px solid #f58634; border-radius: 10px 3px 10px 3px; color: #f58634; }
.sidebar nav { display: flex; flex-direction: column; gap: 4px; }
.sidebar nav p { margin: 23px 11px 7px; color: #72727e; font-size: 10px; font-weight: 700; letter-spacing: 1.4px; }
.sidebar nav a { display: flex; align-items: center; gap: 12px; min-height: 41px; padding: 0 12px; border-radius: 7px; color: #acacb4; font-size: 14px; text-decoration: none; }
.sidebar nav a span { width: 18px; color: #848490; font-size: 17px; text-align: center; }
.sidebar nav a:hover, .sidebar nav a.active { color: white; background: #2e2e33; }
.sidebar nav a.active span { color: #f58634; }
.tenant-card { margin-top: auto; padding: 14px 10px 0; border-top: 1px solid #35353b; display: flex; align-items: center; gap: 10px; color: inherit; text-decoration: none; }
.avatar, .user-avatar { display: grid; place-items: center; border-radius: 50%; background: var(--cat-orange-100); color: var(--tone-accent-fg); font-size: 11px; font-weight: 700; }
.avatar { width: 35px; height: 35px; }
.tenant-card > span:nth-child(2) { display: flex; flex: 1; flex-direction: column; }
.tenant-card strong { font-size: 12px; color: #efeff0; }
.tenant-card small { margin-top: 2px; color: #848490; font-size: 10px; }
.tenant-card button { border: 0; background: transparent; color: #72727e; }
main { min-width: 0; }
.topbar { height: 64px; padding: 0 31px; background: var(--cat-surface); border-bottom: 1px solid var(--cat-border); display: flex; align-items: center; justify-content: space-between; }
.environment { font-size: 13px; font-weight: 600; color: #52525b; }
.environment i { display: inline-block; width: 7px; height: 7px; margin-right: 8px; border-radius: 50%; background: #3fae6a; box-shadow: 0 0 0 3px var(--tone-ok-bg); }
.top-actions { display: flex; align-items: center; gap: 11px; }
.icon-button { width: 31px; height: 31px; border: 0; border-radius: 50%; background: transparent; color: var(--cat-ink); }
.icon-button:hover { background: var(--cat-surface-alt); }
.user-avatar { width: 32px; height: 32px; background: #2e2e33; color: #ececee; }
.content { padding: 37px 36px 60px; max-width: 1480px; margin: 0 auto; }
.page-heading { display: flex; align-items: flex-end; justify-content: space-between; margin-bottom: 29px; }
.eyebrow { color: var(--cat-muted); font-size: 10px; font-weight: 700; letter-spacing: 1.5px; }
h1 { margin: 5px 0 5px; font: 700 31px var(--font-display); letter-spacing: -1px; }
.page-heading p { margin: 0; color: var(--cat-muted); font-size: 13px; }
.primary-button { min-height: 38px; padding: 0 17px; border: 1px solid var(--accent); border-radius: 7px; background: var(--accent); color: var(--fg-on-accent); font-size: 13px; font-weight: 600; box-shadow: var(--shadow-1); }
.primary-button:hover:not(:disabled) { border-color: var(--accent-hover); background: var(--accent-hover); box-shadow: var(--shadow-2); transform: translateY(-1px); }
.primary-button:active:not(:disabled) { transform: translateY(0); }
.primary-button span { margin-right: 7px; font-size: 17px; }
.metric-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 13px; margin-bottom: 18px; }
.metric-grid article { min-height: 111px; padding: 20px; display: flex; align-items: center; gap: 15px; border: 1px solid var(--cat-border); border-radius: 9px; background: var(--cat-surface); box-shadow: var(--shadow-1); }
.metric-grid article div { display: flex; flex-direction: column; }
.metric-grid small { margin-bottom: 3px; color: var(--cat-muted); font-size: 9px; font-weight: 700; letter-spacing: 1px; }
.metric-grid strong { font: 700 25px var(--font-display); }
.metric-grid em { margin-top: 2px; color: var(--cat-muted); font-size: 10px; font-style: normal; }
.metric-icon { width: 41px; height: 41px; flex: 0 0 41px; display: grid; place-items: center; border-radius: 9px; font-size: 19px; }
.metric-icon.blue { color: var(--tone-info-fg); background: var(--tone-info-bg); }.metric-icon.violet { color: var(--tone-violet-fg); background: var(--tone-violet-bg); }.metric-icon.green { color: var(--tone-ok-fg); background: var(--tone-ok-bg); }.metric-icon.amber { color: var(--tone-warn-fg); background: var(--tone-warn-bg); }
.catalog-panel { overflow: hidden; border: 1px solid var(--cat-border); border-radius: 9px; background: var(--cat-surface); box-shadow: var(--shadow-1); }
.panel-tools { padding: 15px 18px; display: flex; gap: 9px; border-bottom: 1px solid var(--cat-border); }
.catalog-toolbar { align-items: center; justify-content: space-between; }
.search-box { height: 36px; max-width: 410px; flex: 1; display: flex; align-items: center; gap: 9px; padding: 0 12px; border: 1px solid var(--cat-border); border-radius: 6px; color: var(--cat-muted); }
.search-box input { min-width: 0; width: 100%; border: 0; outline: none; color: var(--cat-ink-900); font-size: 12px; }
.search-box input::placeholder { color: var(--cat-muted-2); }
.product-filters { display: grid; grid-template-columns: repeat(4, minmax(145px, 1fr)); gap: 12px; background: var(--cat-paper); }
.filter-field { min-width: 0; display: flex; flex-direction: column; gap: 6px; color: var(--cat-label); font-size: 9px; font-weight: 700; letter-spacing: .45px; text-transform: uppercase; }
.filter-field > input, .filter-field > select, .percentage-input { width: 100%; height: 38px; border: 1px solid var(--cat-border); border-radius: 6px; background: var(--cat-surface); color: var(--cat-ink-900); font-size: 11px; font-weight: 500; letter-spacing: 0; text-transform: none; }
.filter-field > input, .filter-field > select { padding: 0 11px; outline: none; }
.filter-field > select { cursor: pointer; }
.filter-field > input::placeholder { color: var(--cat-muted-2); }
.filter-field > input:focus, .filter-field > select:focus, .percentage-input:focus-within { border-color: var(--accent); box-shadow: 0 0 0 3px var(--cat-orange-100); }
.percentage-input { display: flex; align-items: center; overflow: hidden; }
.percentage-input input { min-width: 0; width: 100%; height: 100%; padding: 0 4px 0 11px; border: 0; outline: 0; background: transparent; color: inherit; font-size: inherit; }
.percentage-input b { padding: 0 11px 0 5px; color: var(--cat-muted); font-size: 11px; font-weight: 600; }
.view-switch { padding: 3px; display: flex; align-items: center; gap: 2px; border: 1px solid var(--cat-border); border-radius: 7px; background: var(--cat-surface-alt); }
.view-switch button { min-height: 29px; padding: 0 10px; border: 0; border-radius: 5px; background: transparent; color: var(--cat-ink); font-size: 10px; font-weight: 600; }
.view-switch button:hover { color: var(--tone-accent-fg); background: var(--cat-surface-alt); }.view-switch button.active { background: var(--cat-surface); color: var(--tone-accent-fg); box-shadow: var(--shadow-1); }.view-switch button span { font-size: 13px; }
.secondary-button { min-height: 36px; padding: 0 13px; border: 1px solid var(--cat-border); border-radius: 6px; background: var(--cat-surface); color: var(--cat-ink-700); font-size: 11px; font-weight: 600; box-shadow: var(--shadow-1); }
.secondary-button:hover:not(:disabled) { border-color: var(--cat-border-strong); background: var(--cat-surface-alt); color: var(--tone-accent-fg); }
.text-button { min-height: 32px; padding: 0 11px; border: 1px solid var(--cat-border); border-radius: 6px; background: var(--cat-surface); color: var(--tone-accent-fg); font-size: 11px; font-weight: 600; box-shadow: var(--shadow-1); }
.text-button:hover:not(:disabled) { border-color: var(--cat-border-strong); background: var(--cat-orange-50); color: var(--tone-accent-fg); }
.text-button.danger, .secondary-button.danger { border-color: var(--tone-err-border); color: var(--tone-err-fg); }
.text-button.danger:hover:not(:disabled), .secondary-button.danger:hover:not(:disabled) { border-color: var(--tone-err-border-hover); background: var(--tone-err-bg-soft); color: var(--tone-err-fg-strong); }
.secondary-button b { margin-left: 4px; padding: 1px 5px; border-radius: 8px; background: var(--cat-orange-50); color: var(--tone-accent-fg); font-size: 9px; }
.table-wrap { overflow-x: auto; }
table { width: 100%; border-collapse: collapse; font-size: 12px; }
th { height: 40px; padding: 0 16px; background: var(--cat-paper); border-bottom: 1px solid var(--cat-border); color: var(--cat-muted); text-align: left; font-size: 9px; letter-spacing: .65px; }
td { height: 69px; padding: 0 16px; border-bottom: 1px solid var(--cat-border); color: var(--cat-ink); white-space: nowrap; }
tbody tr:hover { background: var(--cat-surface-alt); }
.product-cell { min-width: 290px; display: flex; align-items: center; gap: 12px; }
.product-cell > span:last-child { display: flex; flex-direction: column; }
.product-cell strong { color: var(--cat-ink-900); font-size: 12px; font-weight: 600; }
.product-cell small { margin-top: 4px; color: var(--cat-muted); font-size: 10px; }
.product-thumb { width: 40px; height: 40px; display: grid; place-items: center; border: 1px solid color-mix(in srgb, var(--accent), var(--cat-surface) 70%); border-radius: 7px; background: color-mix(in srgb, var(--accent), var(--cat-surface) 88%); color: var(--accent); font-size: 16px; }
.product-thumb.has-image { overflow: hidden; border-color: var(--cat-border); background: var(--cat-surface-alt); }.product-thumb.has-image img { width: 100%; height: 100%; display: block; object-fit: cover; }
.completeness { display: flex; align-items: center; gap: 8px; }
.completeness > span { width: 67px; height: 5px; overflow: hidden; border-radius: 4px; background: var(--cat-border); }
.completeness i { display: block; height: 100%; border-radius: 4px; background: var(--accent); }
.completeness b { color: var(--cat-ink); font-size: 10px; font-weight: 600; }
.status { display: inline-flex; align-items: center; gap: 6px; padding: 5px 9px; border-radius: 11px; font-size: 10px; font-weight: 600; }
.status i { width: 5px; height: 5px; border-radius: 50%; background: currentColor; }.status.published { color: var(--tone-ok-fg); background: var(--tone-ok-bg); }.status.review { color: var(--tone-warn-fg); background: var(--tone-warn-bg); }.status.draft { color: var(--tone-neutral-fg); background: var(--tone-neutral-bg); }.status.incomplete { color: var(--tone-err-fg); background: var(--tone-err-bg); }
.row-menu { display: inline-flex; padding: 8px; border: 0; background: transparent; color: var(--cat-muted); text-decoration: none; }
.product-card-grid { padding: 18px; display: grid; grid-template-columns: repeat(auto-fill, minmax(230px, 1fr)); gap: 15px; background: var(--cat-paper); }
.product-list-card { min-width: 0; overflow: hidden; border: 1px solid var(--cat-border); border-radius: 9px; background: var(--cat-surface); box-shadow: var(--shadow-1); transition: border-color 140ms ease, box-shadow 140ms ease, transform 140ms ease; }
.product-list-card:hover { border-color: var(--cat-border-strong); box-shadow: var(--shadow-2); transform: translateY(-2px); }
.product-card-image { height: 180px; display: grid; place-items: center; overflow: hidden; border-bottom: 1px solid var(--cat-border); background: var(--cat-surface-alt); text-decoration: none; }
.product-card-image img { width: 100%; height: 100%; display: block; object-fit: contain; background: var(--cat-surface); }.product-card-image > span { width: 62px; height: 62px; display: grid; place-items: center; border-radius: 14px; background: color-mix(in srgb, var(--accent), var(--cat-surface) 87%); color: var(--accent); font-size: 25px; }
.product-card-content { padding: 14px 15px 16px; }.product-card-topline { display: flex; align-items: center; justify-content: space-between; gap: 10px; }.product-card-topline > small { overflow: hidden; color: var(--cat-muted); font-size: 9px; font-weight: 600; text-overflow: ellipsis; white-space: nowrap; }
.product-card-content > a { color: inherit; text-decoration: none; }.product-card-content h3 { min-height: 38px; margin: 10px 0 4px; overflow: hidden; font: 700 15px/1.25 var(--font-display); display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; }.product-card-content > a:hover h3 { color: var(--tone-accent-fg); }
.product-card-content > p { margin: 0; overflow: hidden; color: var(--cat-muted); font-size: 10px; text-overflow: ellipsis; white-space: nowrap; }.product-card-content > p span { margin: 0 3px; color: var(--cat-border-strong); }
.product-card-stats { margin-top: 15px; display: flex; justify-content: space-between; gap: 10px; color: var(--cat-muted); font-size: 9px; }.product-card-stats b { color: var(--cat-ink); font-size: 10px; }
.product-card-progress { height: 5px; margin-top: 7px; overflow: hidden; border-radius: 5px; background: var(--cat-border); }.product-card-progress i { display: block; height: 100%; border-radius: inherit; background: var(--accent); }
.product-list-empty { padding: 38px 20px; display: flex; align-items: center; flex-direction: column; color: var(--cat-muted); text-align: center; }.product-list-empty > span { width: 42px; height: 42px; display: grid; place-items: center; border-radius: 10px; background: var(--cat-orange-50); color: var(--tone-accent-fg); font-size: 18px; }.product-list-empty strong { margin-top: 10px; color: var(--cat-ink); font-size: 12px; }.product-list-empty p { margin: 5px 0 0; font-size: 10px; }
.panel-footer { min-height: 58px; padding: 0 18px; display: flex; align-items: center; justify-content: space-between; color: var(--cat-muted); font-size: 10px; }
.panel-footer div { display: flex; gap: 4px; }.panel-footer button { min-width: 27px; height: 27px; border: 1px solid var(--cat-border); border-radius: 5px; background: var(--cat-surface); color: var(--cat-ink); font-size: 10px; }.panel-footer button.current { border-color: var(--tone-accent-fg); background: var(--cat-orange-50); color: var(--tone-accent-fg); font-weight: 700; }
.module-grid { display: grid; grid-template-columns: minmax(280px, 360px) 1fr; align-items: start; gap: 18px; }
.form-card, .list-card { padding: 22px; border: 1px solid var(--cat-border); border-radius: 9px; background: var(--cat-surface); box-shadow: var(--shadow-1); }
.form-card h2, .list-card h2 { margin: 0; font: 700 17px var(--font-display); }
.form-card > p, .list-title p { margin: 5px 0 20px; color: var(--cat-muted); font-size: 11px; }
.form-card label { display: flex; flex-direction: column; gap: 6px; margin: 15px 0; color: var(--cat-label); font-size: 11px; font-weight: 800; }
.form-card input, .form-card select { width: 100%; height: 39px; padding: 0 11px; border: 1px solid var(--cat-border); border-radius: 6px; outline: none; background: var(--cat-surface); color: var(--cat-ink-900); font-size: 15px; }
.form-card textarea { font-size: 15px; }
.form-card input:focus, .form-card select:focus { border-color: var(--accent); box-shadow: 0 0 0 3px var(--cat-orange-100); }
.form-card .primary-button { width: 100%; margin-top: 8px; }
.form-card > .text-button { width: 100%; margin-top: 8px; }
.form-card .field-hint { margin-top: -2px; color: var(--cat-muted); font-size: 9px; font-weight: 500; }
.form-message { margin: 12px 0; padding: 9px 11px; border-radius: 6px; font-size: 11px; }.form-message.error { color: var(--tone-err-fg); background: var(--tone-err-bg); }.form-message.success { color: var(--tone-ok-fg); background: var(--tone-ok-bg); }
.list-title { border-bottom: 1px solid var(--cat-border); }
.definition-row { min-height: 68px; display: flex; align-items: center; gap: 12px; border-bottom: 1px solid var(--cat-border); }
.definition-icon { width: 37px; height: 37px; display: grid; place-items: center; border-radius: 8px; background: var(--cat-orange-50); color: var(--tone-accent-fg); font-size: 16px; }
.definition-row > div { flex: 1; display: flex; flex-direction: column; gap: 3px; }.definition-row strong { font-size: 12px; }.definition-row small { color: var(--cat-muted); font-size: 10px; }.definition-row > b { padding: 5px 8px; border-radius: 10px; background: var(--cat-surface-alt); color: var(--cat-muted); font-size: 9px; font-weight: 600; }
.definition-row > .text-button, .definition-row > .secondary-button { flex: 0 0 auto; }
.member-row .definition-icon { font-size: 10px; font-weight: 700; }
.member-row .member-actions { flex: 0 0 auto; flex-direction: row; align-items: center; gap: 8px; }
.member-actions select { height: 36px; padding: 0 9px; border: 1px solid var(--cat-border); border-radius: 6px; background: var(--cat-surface); color: var(--cat-ink); font-size: 11px; }
.empty-message { padding: 26px 0 8px; color: var(--cat-muted); font-size: 12px; text-align: center; }
.organization-list { max-width: 760px; }.organization-list .definition-row form { margin-left: 8px; }
.editor-empty-state { min-height: 180px; padding: 28px; display: flex; align-items: center; justify-content: center; flex-direction: column; border: 1px dashed var(--cat-border); border-radius: 8px; background: var(--cat-paper); color: var(--cat-muted); text-align: center; }
.editor-empty-state > span { width: 40px; height: 40px; margin-bottom: 10px; display: grid; place-items: center; border-radius: 10px; background: var(--cat-orange-50); color: var(--tone-accent-fg); font-size: 18px; }
.editor-empty-state strong { color: var(--cat-ink-700); font-size: 12px; }.editor-empty-state p { max-width: 290px; margin: 5px 0 0; font-size: 10px; }
.media-library-card { min-width: 0; }
.media-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(210px, 1fr)); gap: 14px; }
.media-card { position: relative; min-width: 0; overflow: hidden; border: 1px solid var(--cat-border); border-radius: 9px; background: var(--cat-surface); transition: border-color 140ms ease, box-shadow 140ms ease, transform 140ms ease; }
.media-card:hover { border-color: var(--cat-border-strong); box-shadow: var(--shadow-2); transform: translateY(-1px); }
.media-preview { height: 156px; display: grid; place-items: center; overflow: hidden; border-bottom: 1px solid var(--cat-border); background: var(--cat-surface-alt); text-decoration: none; }
.media-preview img { width: 100%; height: 100%; display: block; object-fit: contain; background: linear-gradient(45deg, var(--cat-surface-alt) 25%, transparent 25%), linear-gradient(-45deg, var(--cat-surface-alt) 25%, transparent 25%), linear-gradient(45deg, transparent 75%, var(--cat-surface-alt) 75%), linear-gradient(-45deg, transparent 75%, var(--cat-surface-alt) 75%), var(--cat-surface); background-position: 0 0, 0 8px, 8px -8px, -8px 0; background-size: 16px 16px; }
.media-preview > span { display: flex; align-items: center; flex-direction: column; gap: 8px; color: var(--tone-accent-fg); font-size: 35px; }.media-preview > span small { padding: 4px 7px; border-radius: 5px; background: var(--cat-orange-100); color: var(--tone-accent-fg); font-size: 9px; font-weight: 700; }
.media-card-body { padding: 13px 13px 47px; }.media-card-body > a { display: block; overflow: hidden; color: var(--cat-ink-900); font-size: 12px; text-overflow: ellipsis; text-decoration: none; white-space: nowrap; }.media-card-body > a:hover { color: var(--tone-accent-fg); }
.media-metadata { margin-top: 9px; display: flex; flex-wrap: wrap; gap: 5px; }.media-metadata span { padding: 3px 6px; border-radius: 4px; background: var(--cat-surface-alt); color: var(--cat-muted); font-size: 9px; }
.media-delete { position: absolute; right: 12px; bottom: 11px; }
.auth-page { min-height: 100vh; display: grid; place-items: center; padding: 30px; background: var(--cat-paper); }
.auth-card { width: min(100%, 430px); padding: 34px; border: 1px solid var(--cat-border); border-radius: 12px; background: var(--cat-surface); box-shadow: var(--shadow-3); }
.auth-card.wide { width: min(100%, 620px); }.auth-card h1 { margin-top: 28px; }.auth-card > p { color: var(--cat-muted); font-size: 13px; }.auth-card form, .auth-card label { display: flex; flex-direction: column; }.auth-card form { gap: 15px; margin: 24px 0; }.auth-card label { gap: 6px; color: var(--cat-label); font-size: 11px; font-weight: 600; }.auth-card input { height: 42px; padding: 0 11px; border: 1px solid var(--cat-border); border-radius: 6px; }.auth-card .checkbox-label { flex-direction: row; align-items: center; }.auth-card .checkbox-label input { width: 16px; height: 16px; }.auth-card > small, .auth-card form > small { color: var(--cat-muted); font-size: 11px; }.auth-card a { color: var(--tone-accent-fg); }.auth-brand { display: flex; align-items: center; gap: 10px; color: var(--cat-ink-900) !important; text-decoration: none; font: 700 19px var(--font-display); }.auth-brand em { color: var(--accent); font-size: 11px; font-style: normal; }.auth-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 15px; }
#blazor-error-ui { display: none; position: fixed; bottom: 0; width: 100%; padding: 12px; background: var(--tone-warn-bg); color: var(--tone-warn-fg); border-top: 1px solid var(--cat-border); z-index: 1000; }

@media (max-width: 1050px) { .metric-grid { grid-template-columns: repeat(2, 1fr); } .app-shell { grid-template-columns: 210px 1fr; } .product-filters { grid-template-columns: repeat(2, minmax(0, 1fr)); } .media-grid { grid-template-columns: repeat(auto-fill, minmax(180px, 1fr)); } }
@media (max-width: 760px) { .app-shell { display: block; } .sidebar { position: static; width: 100%; height: auto; padding: 18px; } .sidebar nav, .tenant-card { display: none; } .brand { padding: 0; } .content { padding: 24px 16px; } .metric-grid, .module-grid, .product-filters { grid-template-columns: 1fr; } .page-heading { align-items: flex-start; gap: 20px; } .panel-tools { flex-wrap: wrap; } .search-box { flex-basis: 100%; max-width: none; } .catalog-toolbar .view-switch { margin-left: auto; } .product-card-grid { grid-template-columns: 1fr; padding: 13px; } .product-card-image { height: 220px; } }
