:root {
    color-scheme: dark;
    --bg: #0f1120;
    --card: #181b2d;
    --surface: #20253a;
    --border: #303650;
    --text: #e5e7eb;
    --muted: #b6bfd7;
    --accent: #3b82f6;
    --ok: #22c55e;
    --bad: #ef4444;
    --ctl-h: 44px;
}
* { box-sizing: border-box; }
html { scrollbar-gutter: stable; min-width: 320px; background: var(--bg); }
body { margin: 0; min-height: 100vh; background: var(--bg); color: var(--text); font: 15px/1.5 Arial, sans-serif; }
.sku-menu { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; width: 100%; padding: 14px max(24px, calc((100% - 1760px) / 2)); border-bottom: 1px solid var(--border); background: var(--card); }
.sku-menu a:not(.sku-auth-button) { display: inline-flex; align-items: center; justify-content: center; min-height: 44px; padding: 10px 18px; border: 1px solid transparent; border-radius: 10px; color: var(--muted); text-decoration: none; font-weight: 600; }
.sku-menu a:not(.sku-auth-button):hover { background: #252b43; color: #fff; }
.sku-menu a.active { border-color: #375987; background: #203456; color: #d9e9ff; }
.sku-menu .sku-auth-button { margin-left: auto; }
.site-page-header { display: flex; align-items: center; justify-content: space-between; gap: 24px; max-width: 1808px; margin: 0 auto; padding: 32px 24px 24px; }
.site-page-header h1 { margin: 0 0 6px; color: #f3f4f6; font-size: clamp(25px, 2.2vw, 32px); line-height: 1.2; }
.site-page-header p { margin: 0; color: var(--muted); }
.container { max-width: 1808px; min-width: 0; margin: 0 auto; padding: 0 24px 40px; }
.card { min-width: 0; padding: 22px; border: 1px solid var(--border); border-radius: 16px; background: var(--card); box-shadow: none; }
button, input, select, textarea { font-family: Arial, sans-serif; }
button { min-height: 44px; padding: 10px 16px; border: 1px solid var(--accent); border-radius: 10px; background: var(--accent); color: #fff; font-size: 14px; font-weight: 600; line-height: 1.4; cursor: pointer; transition: background-color .15s, border-color .15s; }
button:hover { background: #2563eb; border-color: #2563eb; }
button.secondary { background: #252b43; border-color: #3b435e; color: var(--text); }
button.secondary:hover { background: #303852; border-color: #596480; }
button.danger { background: #412332; border-color: #a4485b; color: #fecdd3; }
button.danger:hover { background: #5a293c; border-color: #cd7588; }
button:disabled { opacity: .6; cursor: not-allowed; }
input:not([type="checkbox"]):not([type="radio"]):not([type="hidden"]):not([type="submit"]):not([type="button"]), select, textarea { min-height: 46px; border: 1px solid #434d6a; border-radius: 10px; background: var(--bg); color: #f3f4f6; padding: 10px 12px; font: 15px/1.4 Arial, sans-serif; }
input::placeholder, textarea::placeholder { color: #9ba6bf; opacity: 1; }
input:focus, select:focus, textarea:focus { border-color: #93c5fd; }
label { color: #d5dbec; font-size: 14px; }
input[type="checkbox"], input[type="radio"] { accent-color: var(--accent); }
a { color: #93c5fd; }
button:focus-visible, a:focus-visible, input:focus-visible, select:focus-visible, textarea:focus-visible { outline: 3px solid #93c5fd; outline-offset: 3px; }
[hidden] { display: none !important; }
* { scrollbar-width: thin; scrollbar-color: #56617f #181b2d; }
@media (max-width: 600px) {
    .sku-menu { gap: 6px; padding: 10px 12px; }
    .sku-menu a:not(.sku-auth-button) { padding: 10px 12px; font-size: 14px; }
    .sku-menu .sku-auth-button { padding: 10px 12px; }
    .site-page-header { flex-direction: column; align-items: flex-start; gap: 18px; padding: 24px 12px 20px; }
    .site-page-header p { font-size: 14px; }
    .container { padding: 0 12px 24px; }
    .card { padding: 16px; border-radius: 14px; }
}
@media (prefers-reduced-motion: reduce) { button { transition: none; } }

/* The same table surface and row scale in both data sections. */
:is(.catalog-page, .site-domains) .container table { border-collapse: separate; border-spacing: 0; font-size: 14px; }
:is(.catalog-page, .site-domains) .container th { background: var(--surface); color: #d5dbec; font-size: 13px; font-weight: 600; }
:is(.catalog-page, .site-domains) .container :is(th, td) { padding: 14px 16px; border-bottom: 1px solid var(--border); text-align: left; vertical-align: middle; }
.site-domains .domain-table-scroll { border: 1px solid var(--border); border-radius: 12px; }
:is(.catalog-page, .site-domains) .container tr:last-child td { border-bottom: 0; }

/* Text lists use compact row actions; image rows retain a vertical action pair. */
.catalog-page .actions-cell { width: 260px; white-space: nowrap; }
.catalog-page .actions-cell button { display: inline-flex; width: auto; min-width: 0; }
.catalog-page .actions-cell button + button { margin-top: 0; margin-left: 8px; }
.catalog-page tr:has(.product-photo-cell) .actions-cell { width: 180px; }
.catalog-page tr:has(.product-photo-cell) .actions-cell button { display: flex; width: 100%; min-width: 130px; }
.catalog-page tr:has(.product-photo-cell) .actions-cell button + button { margin-top: 8px; margin-left: 0; }
