:root {
    --bg: #f6f7f9;
    --panel: #ffffff;
    --panel-soft: #f9fafb;
    --text: #111827;
    --muted: #667085;
    --line: #e4e7ec;
    --line-strong: #d0d5dd;
    --border-color: var(--line);
    --bg-soft: var(--panel-soft);
    --primary: #0f766e;
    --primary-dark: #115e59;
    --primary-soft: #ccfbf1;
    --danger: #b42318;
    --danger-soft: #fee4e2;
    --green: #067647;
    --green-soft: #dcfae6;
    --amber: #b54708;
    --amber-soft: #fef0c7;
    --sidebar: #101828;
    --sidebar-soft: #182230;
    --sidebar-text: #eef2f6;
    --sidebar-muted: #98a2b3;
    --shadow: 0 14px 34px rgba(16, 24, 40, .07);
    --shadow-soft: 0 8px 20px rgba(16, 24, 40, .05);
}

* {
    box-sizing: border-box;
}

html {
    min-width: 320px;
}

body {
    margin: 0;
    background: var(--bg);
    color: var(--text);
    font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
    font-size: 14px;
    line-height: 1.5;
}

a {
    color: inherit;
    text-decoration: none;
}

button,
input,
select,
textarea {
    font: inherit;
}

.admin-shell {
    display: grid;
    grid-template-columns: 272px minmax(0, 1fr);
    min-height: 100vh;
}

.sidebar {
    position: sticky;
    top: 0;
    height: 100vh;
    overflow-y: auto;
    padding: 22px 18px;
    background: var(--sidebar);
    color: var(--sidebar-text);
}

.brand {
    display: flex;
    gap: 12px;
    align-items: center;
    min-height: 64px;
    margin-bottom: 22px;
    padding: 10px;
    border: 1px solid rgba(255, 255, 255, .08);
    border-radius: 8px;
    background: var(--sidebar-soft);
}

.brand-mark {
    display: grid;
    width: 42px;
    height: 42px;
    flex: 0 0 auto;
    place-items: center;
    border-radius: 8px;
    background: #f2c94c;
    color: #101828;
    font-weight: 900;
}

.brand strong,
.brand small {
    display: block;
}

.brand strong {
    font-size: 16px;
}

.brand small,
.nav-link {
    color: var(--sidebar-muted);
}

.nav {
    display: grid;
    gap: 5px;
}

.nav-link {
    display: flex;
    min-height: 42px;
    gap: 10px;
    align-items: center;
    padding: 9px 10px;
    border: 1px solid transparent;
    border-radius: 8px;
    font-weight: 750;
}

.nav-link span {
    display: grid;
    width: 26px;
    height: 26px;
    flex: 0 0 auto;
    place-items: center;
    border-radius: 7px;
    background: rgba(255, 255, 255, .06);
    color: #d0d5dd;
    font-size: 13px;
    line-height: 1;
}

.nav-link.active,
.nav-link:hover {
    border-color: rgba(255, 255, 255, .08);
    background: #1d2939;
    color: #ffffff;
}

.nav-link.active span,
.nav-link:hover span {
    background: var(--primary);
    color: #ffffff;
}

.main {
    min-width: 0;
    padding: 28px 32px 42px;
}

.topbar {
    position: sticky;
    z-index: 5;
    top: 0;
    display: flex;
    justify-content: space-between;
    gap: 20px;
    align-items: flex-start;
    margin: -28px -32px 22px;
    padding: 26px 32px 18px;
    border-bottom: 1px solid rgba(228, 231, 236, .7);
    background: rgba(246, 247, 249, .94);
    backdrop-filter: blur(12px);
}

.topbar-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    justify-content: flex-end;
}

.eyebrow {
    margin: 0 0 4px;
    color: var(--muted);
    font-size: 12px;
    font-weight: 800;
    letter-spacing: 0;
    text-transform: uppercase;
}

h1,
h2,
h3 {
    margin: 0;
    letter-spacing: 0;
}

h1 {
    font-size: 28px;
    line-height: 1.2;
}

h2 {
    font-size: 17px;
    line-height: 1.3;
}

h3 {
    font-size: 15px;
}

.button {
    display: inline-flex;
    min-height: 40px;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 0 14px;
    border: 1px solid var(--line-strong);
    border-radius: 8px;
    background: #ffffff;
    color: var(--text);
    cursor: pointer;
    font-weight: 800;
    white-space: nowrap;
    transition: background-color .15s ease, border-color .15s ease, color .15s ease, box-shadow .15s ease, transform .15s ease;
}

.button:hover {
    border-color: #b8c0cc;
    background: var(--panel-soft);
    box-shadow: var(--shadow-soft);
    transform: translateY(-1px);
}

.button:focus-visible,
input:focus-visible,
select:focus-visible,
textarea:focus-visible,
a:focus-visible {
    outline: 3px solid rgba(15, 118, 110, .18);
    outline-offset: 2px;
}

.button.primary {
    border-color: var(--primary);
    background: var(--primary);
    color: #ffffff;
}

.button.primary:hover {
    border-color: var(--primary-dark);
    background: var(--primary-dark);
}

.button.ghost {
    background: #ffffff;
}

.button.danger {
    border-color: #fecdca;
    background: #fff5f4;
    color: var(--danger);
}

.button.danger:hover {
    border-color: #fda29b;
    background: var(--danger-soft);
}

.button.full {
    width: 100%;
}

.metrics {
    display: grid;
    grid-template-columns: repeat(4, minmax(170px, 1fr));
    gap: 14px;
    margin-bottom: 18px;
}

.ops-board,
.catalog-summary {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 14px;
    margin-bottom: 18px;
}

.catalog-summary {
    grid-template-columns: repeat(2, minmax(0, 1fr));
}

.ops-card {
    display: grid;
    gap: 8px;
    padding: 16px;
    border: 1px solid var(--line);
    border-radius: 8px;
    background: #ffffff;
    box-shadow: var(--shadow-soft);
}

.ops-card span,
.tree-note p {
    color: var(--muted);
}

.ops-card strong {
    font-size: 28px;
    line-height: 1;
}

.ops-card a {
    color: var(--primary);
    font-weight: 900;
}

.ops-card.warning {
    border-color: #fedf89;
    background: #fffbeb;
}

.ops-card.danger {
    border-color: #fecdca;
    background: #fff5f4;
}

.ops-card.muted {
    background: var(--panel-soft);
}

.avatar-initial {
    display: grid;
    width: 38px;
    height: 38px;
    flex: 0 0 auto;
    place-items: center;
    border-radius: 8px;
    background: var(--primary-soft);
    color: var(--primary-dark);
    font-weight: 900;
    text-transform: uppercase;
}

.metric,
.panel {
    border: 1px solid var(--line);
    border-radius: 8px;
    background: var(--panel);
    box-shadow: var(--shadow);
}

.metric {
    position: relative;
    overflow: hidden;
    padding: 18px;
}

.metric::before {
    content: "";
    position: absolute;
    inset: 0 auto 0 0;
    width: 4px;
    background: var(--primary);
}

.metric span,
small,
.hint {
    color: var(--muted);
}

.metric span {
    display: block;
    font-weight: 800;
}

.metric strong {
    display: block;
    margin-top: 7px;
    font-size: 30px;
    line-height: 1.1;
}

.metric .metric-text,
.metric-text {
    font-size: 19px;
}

.grid {
    display: grid;
    gap: 18px;
}

.grid.two {
    grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
}

.form-layout {
    grid-template-columns: minmax(0, 1fr) 330px;
    align-items: start;
}

.panel {
    padding: 18px;
}

.panel:has(.table) {
    overflow-x: auto;
}

.panel-head {
    display: flex;
    justify-content: space-between;
    gap: 14px;
    align-items: center;
    margin-bottom: 14px;
}

.panel-head a {
    color: var(--primary);
    font-weight: 800;
}

.list {
    display: grid;
    gap: 8px;
}

.list-item,
.entity {
    display: flex;
    gap: 12px;
    align-items: center;
    min-width: 0;
}

.list-item {
    padding: 12px;
    border: 1px solid transparent;
    border-radius: 8px;
    background: var(--panel-soft);
}

.list-item:hover {
    border-color: #bfe7df;
    background: #f0fdfa;
}

.list-item strong,
.entity strong {
    display: block;
}

.list-item small,
.entity small {
    display: block;
    overflow-wrap: anywhere;
}

.swatch,
.pin {
    flex: 0 0 auto;
    width: 14px;
    height: 14px;
    border-radius: 999px;
}

.pin {
    width: 18px;
    height: 18px;
    border: 3px solid #ffffff;
    box-shadow: 0 0 0 5px rgba(15, 118, 110, .12);
}

.table {
    width: 100%;
    min-width: 760px;
    border-collapse: collapse;
}

.table th {
    color: var(--muted);
    font-size: 11px;
    font-weight: 900;
    text-align: left;
    text-transform: uppercase;
}

.table th,
.table td {
    padding: 13px 10px;
    border-bottom: 1px solid var(--line);
    vertical-align: middle;
}

.table tbody tr:hover {
    background: #fcfcfd;
}

.table tr:last-child td {
    border-bottom: 0;
}

.table-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    justify-content: flex-end;
}

.table-actions form {
    margin: 0;
}

.badge {
    display: inline-flex;
    min-height: 26px;
    align-items: center;
    gap: 5px;
    padding: 0 9px;
    border-radius: 999px;
    font-size: 12px;
    font-weight: 900;
    line-height: 1;
    white-space: nowrap;
}

.badge.green {
    background: var(--green-soft);
    color: var(--green);
}

.badge.gray {
    background: #eef2f6;
    color: #475467;
}

.badge.amber {
    background: var(--amber-soft);
    color: var(--amber);
}

.badge.danger {
    background: var(--danger-soft);
    color: var(--danger);
}

.chip-list {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
}

.filters {
    display: grid;
    grid-template-columns: minmax(240px, 1fr) 190px 170px auto auto;
    gap: 10px;
    align-items: center;
    margin-bottom: 14px;
}

.filters.compact {
    grid-template-columns: minmax(240px, 1fr) 190px 190px auto;
}

.filters.access-create {
    grid-template-columns: minmax(180px, 1fr) auto;
}

.filters.store-products {
    grid-template-columns: minmax(220px, 1fr) 180px 150px 140px auto auto;
}

.store-workspace .filters.store-products {
    grid-template-columns: minmax(220px, 1fr) 180px 150px 130px auto auto;
}

input,
select,
textarea {
    width: 100%;
    min-height: 42px;
    border: 1px solid var(--line-strong);
    border-radius: 8px;
    background: #ffffff;
    color: var(--text);
    padding: 10px 12px;
    transition: border-color .15s ease, box-shadow .15s ease, background-color .15s ease;
}

input:hover,
select:hover,
textarea:hover {
    border-color: #b8c0cc;
}

input:focus,
select:focus,
textarea:focus {
    border-color: var(--primary);
    box-shadow: 0 0 0 4px rgba(15, 118, 110, .12);
}

textarea {
    resize: vertical;
}

.form-grid {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
    gap: 16px;
}

.form-grid.single {
    grid-template-columns: 1fr;
}

label {
    display: grid;
    gap: 7px;
    color: #344054;
    font-weight: 800;
}

label small {
    font-weight: 600;
}

.span-2 {
    grid-column: span 2;
}

.toggle {
    display: flex;
    gap: 10px;
    align-items: center;
    min-height: 42px;
}

.toggle input {
    width: 18px;
    min-height: 18px;
}

.permission-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 10px;
    margin-top: 12px;
}

.permission-toggle {
    padding: 10px;
    border: 1px solid var(--line);
    border-radius: 8px;
    background: var(--panel-soft);
}

.working-hours-grid {
    display: grid;
    gap: 10px;
    margin-top: 12px;
}

.working-hour-row {
    display: grid;
    grid-template-columns: 140px 1fr 1fr 130px;
    gap: 10px;
    align-items: end;
    padding: 10px;
    border: 1px solid var(--line);
    border-radius: 8px;
    background: var(--panel-soft);
}

.address-list {
    display: grid;
    gap: 12px;
    margin-top: 18px;
}

.address-card {
    padding: 14px;
    border: 1px solid var(--line);
    border-radius: 8px;
    background: var(--panel-soft);
}

.form-actions {
    display: flex;
    flex-wrap: wrap;
    justify-content: flex-end;
    gap: 10px;
    margin-top: 20px;
}

.form-actions.vertical {
    display: grid;
}

.product-editor {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 340px;
    gap: 18px;
    align-items: start;
}

.compact-product-editor {
    grid-template-columns: minmax(0, 1fr) 300px;
    gap: 16px;
}

.product-editor-main {
    display: grid;
    gap: 18px;
    min-width: 0;
}

.compact-product-editor .product-editor-main {
    gap: 14px;
}

.product-editor-side {
    position: sticky;
    top: 92px;
    display: grid;
    gap: 14px;
}

.compact-product-side {
    gap: 12px;
}

.editor-section {
    display: grid;
    gap: 16px;
}

.compact-editor-section {
    gap: 12px;
}

.section-head {
    display: flex;
    justify-content: space-between;
    gap: 16px;
    align-items: flex-start;
}

.section-head.compact {
    align-items: center;
}

.section-head p {
    max-width: 720px;
    margin: 4px 0 0;
    color: var(--muted);
}

.product-core-grid {
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 12px;
}

.product-core-grid .span-2 {
    grid-column: span 2;
}

.editor-toggle {
    align-self: end;
    min-height: 42px;
    padding: 10px 12px;
    border: 1px solid var(--line);
    border-radius: 8px;
    background: var(--panel-soft);
}

.editor-toggle span {
    display: grid;
    gap: 2px;
}

.compact-toggle {
    padding: 9px 10px;
}

.media-editor {
    display: grid;
    gap: 14px;
}

.compact-media-grid {
    display: grid;
    grid-template-columns: 220px minmax(0, 1fr);
    gap: 14px;
}

.media-upload-column,
.media-content-column {
    display: grid;
    gap: 10px;
    align-content: start;
}

.upload-box {
    padding: 14px;
    border: 1px dashed var(--line-strong);
    border-radius: 8px;
    background: var(--panel-soft);
}

.upload-title {
    font-weight: 900;
}

.compact-upload {
    padding: 11px;
}

.media-strip,
.media-grid {
    display: grid;
    gap: 10px;
}

.media-grid {
    grid-template-columns: repeat(auto-fill, minmax(118px, 1fr));
}

.media-card {
    overflow: hidden;
    border: 1px solid var(--line);
    border-radius: 8px;
    background: #ffffff;
}

.media-card.large {
    max-width: 220px;
}

.compact-main-media {
    max-width: 220px;
}

.compact-gallery {
    grid-template-columns: repeat(auto-fill, minmax(92px, 1fr));
}

.media-card img {
    display: block;
    width: 100%;
    aspect-ratio: 1;
    object-fit: cover;
    background: #eef2f6;
}

.media-check {
    display: flex;
    gap: 8px;
    align-items: center;
    padding: 9px;
    color: var(--muted);
    font-size: 12px;
    font-weight: 800;
}

.media-check input {
    width: 16px;
    min-height: 16px;
}

.external-images {
    display: grid;
    gap: 10px;
    padding: 14px;
    border: 1px solid var(--line);
    border-radius: 8px;
    background: #ffffff;
}

.compact-external-images {
    padding: 12px;
}

.url-list {
    display: grid;
    gap: 8px;
}

.compact-url-list {
    gap: 7px;
}

.file-list {
    display: grid;
    gap: 8px;
}

.compact-files-row {
    display: grid;
    grid-template-columns: 220px minmax(0, 1fr);
    gap: 14px;
}

.compact-file-list {
    align-content: start;
}

.file-row {
    display: flex;
    justify-content: space-between;
    gap: 12px;
    align-items: center;
    padding: 10px 12px;
    border: 1px solid var(--line);
    border-radius: 8px;
    background: #ffffff;
}

.file-row input {
    width: 16px;
    min-height: 16px;
}

.preview-panel {
    overflow: hidden;
    padding: 0;
}

.preview-image {
    display: grid;
    min-height: 230px;
    place-items: center;
    background: #eef2f6;
    color: var(--muted);
    font-weight: 900;
}

.compact-preview-image {
    min-height: 176px;
}

.preview-image img {
    width: 100%;
    height: 100%;
    min-height: 230px;
    object-fit: cover;
}

.compact-preview-image img {
    min-height: 176px;
}

.preview-body {
    display: grid;
    gap: 4px;
    padding: 16px;
}

.preview-body p {
    margin: 0;
    color: var(--muted);
}

.preview-body strong {
    margin-top: 8px;
    font-size: 20px;
}

.compact-preview-panel .preview-body {
    padding: 14px;
}

.compact-preview-panel .preview-body h2 {
    font-size: 17px;
}

.compact-preview-panel .preview-body strong {
    font-size: 18px;
}

.editor-summary,
.editor-help {
    display: grid;
    gap: 12px;
}

.compact-details {
    gap: 9px;
}

.compact-details div {
    padding-bottom: 9px;
}

.editor-help ul {
    display: grid;
    gap: 8px;
    margin: 0;
    padding-left: 18px;
    color: var(--muted);
}

.compact-help ul {
    gap: 6px;
}

.compact-empty {
    margin: 0;
    padding: 18px;
}

.sticky-actions {
    position: sticky;
    top: 92px;
}

.required-mark {
    color: var(--danger);
}

.side-panel {
    position: sticky;
    top: 92px;
}

.map-preview {
    position: relative;
    overflow: hidden;
    height: 210px;
    margin: 16px 0;
    border: 1px solid var(--line);
    border-radius: 8px;
    background: #d9efe6;
}

.map-grid {
    position: absolute;
    inset: -30px;
    background:
        linear-gradient(115deg, transparent 0 42%, rgba(255, 255, 255, .95) 42% 45%, transparent 45% 100%),
        linear-gradient(35deg, transparent 0 54%, rgba(255, 255, 255, .8) 54% 57%, transparent 57% 100%),
        linear-gradient(90deg, rgba(15, 118, 110, .11) 1px, transparent 1px),
        linear-gradient(rgba(15, 118, 110, .11) 1px, transparent 1px);
    background-size: 100% 100%, 100% 100%, 28px 28px, 28px 28px;
}

.map-pin {
    position: absolute;
    top: 50%;
    left: 50%;
    width: 22px;
    height: 22px;
    border: 4px solid #ffffff;
    border-radius: 50% 50% 50% 0;
    background: var(--danger);
    box-shadow: 0 12px 26px rgba(180, 35, 24, .24);
    transform: translate(-50%, -70%) rotate(-45deg);
}

.product-thumb {
    display: grid;
    width: 46px;
    height: 46px;
    flex: 0 0 auto;
    place-items: center;
    overflow: hidden;
    border: 1px solid var(--line);
    border-radius: 8px;
    background: #eef2f6;
}

.product-thumb::before {
    content: "";
    width: 18px;
    height: 14px;
    border: 2px solid #98a2b3;
    border-radius: 4px;
}

.product-thumb:has(img)::before {
    content: "";
    width: 0;
    height: 0;
    border: 0;
}

.product-thumb img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.inline-form {
    display: grid;
    grid-template-columns: 120px 120px auto;
    gap: 8px;
    align-items: center;
}

.inline-form select {
    min-height: 36px;
    padding: 6px 8px;
}

.order-block {
    margin-bottom: 16px;
}

.details {
    display: grid;
    gap: 12px;
}

.details div {
    display: flex;
    justify-content: space-between;
    gap: 14px;
    padding-bottom: 12px;
    border-bottom: 1px solid var(--line);
}

.details div:last-child {
    border-bottom: 0;
    padding-bottom: 0;
}

.details span {
    color: var(--muted);
}

.lower-grid {
    margin-top: 18px;
}

.store-profile {
    overflow: hidden;
    padding: 0;
    margin-bottom: 18px;
}

.store-workspace {
    display: grid;
    grid-template-columns: minmax(0, 68fr) minmax(320px, 32fr);
    gap: 18px;
    align-items: start;
}

.store-products-column {
    display: grid;
    gap: 14px;
    min-width: 0;
}

.store-info-column {
    position: sticky;
    top: 92px;
    display: grid;
    gap: 14px;
    min-width: 0;
}

.store-compact-metrics {
    grid-template-columns: repeat(3, minmax(0, 1fr));
    margin-bottom: 0;
}

.store-products-table {
    min-width: 860px;
}

.compact-store-profile {
    margin-bottom: 0;
}

.compact-store-profile .store-cover {
    min-height: 150px;
}

.compact-store-profile .store-profile-body {
    grid-template-columns: 72px minmax(0, 1fr);
    gap: 12px;
    padding: 0 14px 16px;
}

.compact-store-profile .store-logo {
    width: 72px;
    height: 72px;
    font-size: 26px;
}

.compact-store-profile .store-profile-body h2 {
    font-size: 20px;
}

.compact-store-profile .store-profile-body p {
    max-width: none;
}

.user-profile {
    display: flex;
    gap: 16px;
    align-items: center;
    margin-bottom: 18px;
}

.user-profile h2 {
    margin-top: 8px;
    font-size: 24px;
}

.user-profile p {
    margin: 6px 0;
    color: var(--muted);
}

.user-avatar {
    display: grid;
    width: 82px;
    height: 82px;
    flex: 0 0 auto;
    place-items: center;
    overflow: hidden;
    border-radius: 8px;
    background: var(--primary-soft);
    color: var(--primary-dark);
    font-size: 30px;
    font-weight: 900;
    text-transform: uppercase;
}

.user-avatar img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.store-cover {
    position: relative;
    min-height: 180px;
    background: #d9efe6;
    background-position: center;
    background-size: cover;
}

.store-cover::after {
    content: "";
    position: absolute;
    inset: 0;
    background: rgba(16, 24, 40, .16);
}

.store-cover-label {
    position: absolute;
    z-index: 1;
    right: 16px;
    bottom: 16px;
    padding: 7px 10px;
    border-radius: 999px;
    background: rgba(255, 255, 255, .92);
    color: var(--text);
    font-weight: 900;
}

.store-profile-body {
    display: grid;
    grid-template-columns: 92px minmax(0, 1fr);
    gap: 16px;
    align-items: end;
    padding: 0 18px 18px;
}

.store-logo {
    display: grid;
    width: 92px;
    height: 92px;
    place-items: center;
    overflow: hidden;
    margin-top: -34px;
    border: 4px solid #ffffff;
    border-radius: 8px;
    background: var(--primary-soft);
    color: var(--primary-dark);
    font-size: 34px;
    font-weight: 900;
    box-shadow: var(--shadow-soft);
}

.store-logo img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.store-profile-body h2 {
    margin-top: 8px;
    font-size: 24px;
}

.store-profile-body p {
    max-width: 820px;
    margin: 6px 0;
    color: var(--muted);
}

.hours-list {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-top: 14px;
}

.hours-list span {
    padding: 7px 9px;
    border: 1px solid var(--line);
    border-radius: 8px;
    background: var(--panel-soft);
    color: var(--muted);
    font-weight: 800;
}

.hours-list.vertical {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
}

.order-hero {
    display: flex;
    justify-content: space-between;
    gap: 18px;
    align-items: flex-start;
    margin-bottom: 18px;
}

.order-hero h2 {
    margin-top: 10px;
    font-size: 24px;
}

.order-hero p {
    margin: 6px 0;
    color: var(--muted);
}

.order-total {
    display: grid;
    gap: 4px;
    min-width: 190px;
    padding: 14px;
    border: 1px solid var(--line);
    border-radius: 8px;
    background: var(--panel-soft);
}

.order-total span,
.suborder-total span {
    color: var(--muted);
    font-weight: 800;
}

.order-total strong {
    font-size: 24px;
}

.status-steps {
    display: grid;
    grid-template-columns: repeat(5, minmax(0, 1fr));
    gap: 10px;
    margin-bottom: 18px;
}

.status-step {
    display: grid;
    gap: 8px;
    padding: 12px;
    border: 1px solid var(--line);
    border-radius: 8px;
    background: var(--panel-soft);
    color: var(--muted);
}

.status-step span {
    display: grid;
    width: 28px;
    height: 28px;
    place-items: center;
    border-radius: 999px;
    background: #ffffff;
    color: var(--muted);
    font-weight: 900;
}

.status-step.done {
    border-color: #abefc6;
    background: var(--green-soft);
    color: var(--green);
}

.status-step.done span {
    background: var(--green);
    color: #ffffff;
}

.status-step.danger {
    border-color: #fecdca;
    background: var(--danger-soft);
    color: var(--danger);
}

.status-step.danger span {
    background: var(--danger);
    color: #ffffff;
}

.suborder-total {
    display: flex;
    justify-content: flex-end;
    gap: 16px;
    padding-top: 14px;
    font-size: 16px;
}

.tree-note {
    display: grid;
    gap: 6px;
}

.tree-note p {
    margin: 0;
}

.category-node {
    display: flex;
    gap: 10px;
    align-items: center;
    padding-left: calc(var(--depth) * 22px);
}

.tree-line {
    width: 20px;
    height: 20px;
    flex: 0 0 auto;
    border-bottom: 2px solid var(--line-strong);
    border-left: 2px solid var(--line-strong);
    border-radius: 0 0 0 6px;
}

.category-node[style*="--depth: 0"] .tree-line {
    border-left: 0;
}

.alert {
    margin-bottom: 16px;
    padding: 12px 14px;
    border: 1px solid transparent;
    border-radius: 8px;
    font-weight: 800;
}

.alert.success {
    border-color: #abefc6;
    background: var(--green-soft);
    color: var(--green);
}

.alert.danger {
    border-color: #fecdca;
    background: var(--danger-soft);
    color: var(--danger);
}

.empty {
    padding: 22px;
    color: var(--muted);
    text-align: center;
}

.pagination {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    align-items: center;
    margin: 16px 0 0;
    padding: 0;
    list-style: none;
}

.page-item .page-link,
.page-item span.page-link {
    display: inline-flex;
    min-width: 36px;
    min-height: 36px;
    align-items: center;
    justify-content: center;
    padding: 0 10px;
    border: 1px solid var(--line-strong);
    border-radius: 8px;
    background: #ffffff;
    color: var(--text);
    font-weight: 800;
    text-decoration: none;
}

.page-item .page-link:hover {
    border-color: #b8c0cc;
    background: var(--panel-soft);
}

.page-item.active span.page-link {
    border-color: var(--primary);
    background: var(--primary);
    color: #ffffff;
}

.page-item.disabled span.page-link {
    background: var(--panel-soft);
    color: var(--muted);
}

@media (max-width: 1180px) {
    .admin-shell {
        grid-template-columns: 236px minmax(0, 1fr);
    }

    .main {
        padding-right: 22px;
        padding-left: 22px;
    }

    .topbar {
        margin-right: -22px;
        margin-left: -22px;
        padding-right: 22px;
        padding-left: 22px;
    }

    .metrics {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

@media (max-width: 980px) {
    .admin-shell,
    .grid.two,
    .form-layout,
    .product-editor,
    .store-workspace,
    .ops-board,
    .catalog-summary,
    .status-steps,
    .metrics,
    .filters,
    .filters.compact,
    .filters.store-products,
    .filters.access-create {
        grid-template-columns: 1fr;
    }

    .admin-shell {
        display: block;
    }

    .sidebar {
        position: static;
        height: auto;
    }

    .nav {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .topbar {
        position: static;
        flex-direction: column;
        align-items: stretch;
        margin-top: 0;
    }

    .topbar-actions,
    .table-actions,
    .form-actions {
        justify-content: flex-start;
    }

    .form-grid,
    .permission-grid,
    .working-hour-row {
        grid-template-columns: 1fr;
    }

    .span-2 {
        grid-column: span 1;
    }

    .product-core-grid,
    .compact-media-grid,
    .compact-files-row {
        grid-template-columns: 1fr;
    }

    .product-core-grid .span-2 {
        grid-column: span 1;
    }

    .side-panel {
        position: static;
    }

    .product-editor-side,
    .store-info-column,
    .sticky-actions {
        position: static;
    }

    .section-head,
    .section-head.compact,
    .order-hero,
    .user-profile,
    .file-row {
        flex-direction: column;
        align-items: stretch;
    }

    .store-profile-body {
        grid-template-columns: 72px minmax(0, 1fr);
    }

    .store-logo {
        width: 72px;
        height: 72px;
        font-size: 26px;
    }

    .store-compact-metrics {
        grid-template-columns: 1fr;
    }

    .hours-list.vertical {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 560px) {
    .main {
        padding: 18px 14px 28px;
    }

    .topbar {
        margin-right: -14px;
        margin-bottom: 16px;
        margin-left: -14px;
        padding: 18px 14px;
    }

    h1 {
        font-size: 23px;
    }

    .nav {
        grid-template-columns: 1fr;
    }

    .panel,
    .metric {
        padding: 14px;
    }

    .button,
    .topbar-actions .button {
        width: 100%;
    }
}
