/**
 * Cybsoft Admin — полный визуальный слой под бренд cybsoft.tech
 * Жёлтый акцент, Unbounded/Onest, тёмные поверхности. Логика классов не меняется.
 */

html body {
    font-family: var(--font-body);
    font-size: 16px;
    line-height: 1.55;
    color: var(--text);
    background: var(--bg);
    -webkit-font-smoothing: antialiased;
}

html body.has-sidebar {
    background: var(--bg);
}

html body h1, html body h2, html body h3, html body .doc-title,
html body .doc-toolbar .doc-title,
html body .header h1 {
    font-family: var(--font-display);
    letter-spacing: -0.02em;
    color: var(--text);
}

html body .skip-link {
    position: absolute;
    left: 12px;
    top: -48px;
    z-index: 10050;
    padding: 10px 14px;
    background: var(--accent);
    color: var(--accent-on);
    border-radius: var(--btn-radius);
    font-weight: 700;
    text-decoration: none;
}
html body .skip-link:focus { top: 12px; outline: none; box-shadow: var(--focus-ring); }

html body a, html body button, html body [role="button"], html body .btn,
html body .tab-btn, html body .sidebar-1c-section-btn, html body .sidebar-1c-item,
html body .sidebar-toggle, html body .theme-toggle-btn, html body .sidebar-1c-logout-btn,
html body .sidebar-1c-manual-link, html body label[for], html body summary,
html body .collapsible-block-summary, html body .doc-list-filters-trigger,
html body .doc-list-row, html body .doc-list-sort-link {
    cursor: pointer;
}

html body a:focus-visible,
html body button:focus-visible,
html body input:focus-visible,
html body select:focus-visible,
html body textarea:focus-visible,
html body .tab-btn:focus-visible,
html body .sidebar-1c-section-btn:focus-visible,
html body .sidebar-1c-item:focus-visible {
    outline: none;
    box-shadow: var(--focus-ring);
}

/* ——— Buttons ——— */
html body .btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    min-height: 44px;
    padding: 10px 16px;
    border-radius: var(--btn-radius);
    font-family: var(--font-body);
    font-weight: 600;
    font-size: 14px;
    border: 1px solid transparent;
    transition: background var(--duration) ease, color var(--duration) ease, border-color var(--duration) ease, opacity var(--duration) ease;
}
html body .btn-primary,
html body .doc-form .doc-form-actions .btn-primary,
html body .doc-form .doc-cmd-write,
html body .doc-period-modal .modal-actions .btn-primary,
html body .club-actions .btn-primary,
html.theme-dark body .btn-primary,
html.theme-dark body .doc-form .doc-form-actions .btn-primary,
html.theme-dark body .doc-form .doc-cmd-write,
html.theme-dark body .modal-actions .btn-primary,
html.theme-dark body .modal-actions .btn-modal-primary,
html.theme-dark body .modal-actions button[type="submit"] {
    background: var(--accent) !important;
    color: var(--accent-on) !important;
    width: auto;
    background-image: none;
    box-shadow: none;
}
html body .btn-primary:hover,
html body .doc-form .doc-form-actions .btn-primary:hover,
html body .doc-form .doc-cmd-write:hover,
html.theme-dark body .btn-primary:hover,
html.theme-dark body .doc-form .doc-form-actions .btn-primary:hover,
html.theme-dark body .doc-form .doc-cmd-write:hover,
html.theme-dark body .modal-actions .btn-primary:hover:not(:disabled),
html.theme-dark body .modal-actions .btn-modal-primary:hover:not(:disabled),
html.theme-dark body .modal-actions button[type="submit"]:hover:not(:disabled) {
    background: var(--accent-soft) !important;
    color: var(--accent-on) !important;
    opacity: 1;
    transform: none;
    box-shadow: none;
}
html body .btn-secondary {
    background: var(--bg-elevated);
    color: var(--text);
    border-color: var(--border);
}
html body .btn-secondary:hover { background: var(--bg-card); border-color: var(--accent); }
html body .btn-danger { background: var(--danger); color: #fff; }
html body .btn-success { background: var(--ok); color: #052e16; }

/* ——— Surfaces ——— */
html body .header,
html body .no-clubs,
html body .table-container,
html body .stats-section,
html body .navigation-section,
html body .info-section,
html body .page-content-card,
html body .club-card,
html body .revenue-compare-wrap,
html body .stats-kpi-card,
html body .stats-chart-wrap,
html body .report-page.report-1c .stats-kpi-card,
html body .report-page.report-1c .report-summary {
    background: var(--bg-card);
    color: var(--text);
    border: 1px solid var(--border);
    border-radius: var(--card-radius);
    box-shadow: none;
}
html body .page-content-card {
    box-shadow: var(--shadow-sm);
}
html body .header h1 { font-size: 1.35rem; font-weight: 600; }
html body .subtitle { color: var(--text-muted); }

html body .stat-card {
    background: var(--bg-elevated);
    color: var(--text);
    border: 1px solid var(--border);
    border-radius: var(--card-radius);
}
html body .stat-card .stat-value { color: var(--accent); }

html body .alert { border-radius: var(--btn-radius); border: 1px solid transparent; }
html body .alert-success { background: var(--ok-bg); color: var(--ok); }
html body .alert-error { background: var(--danger-bg); color: #fecaca; }
html body:not(.theme-dark) .alert-error,
html:not(.theme-dark) body .alert-error { color: #991b1b; }
html body .alert-info { background: var(--info-bg); color: var(--info); }
html body .alert-warning,
html body .demo-banner {
    display: flex;
    align-items: center;
    gap: 8px;
    background: var(--warn-bg);
    color: var(--text);
    border: 1px solid rgba(250, 204, 21, 0.35);
    border-radius: var(--btn-radius);
}
html body .demo-banner .nav-svg {
    width: 18px;
    height: 18px;
    flex-shrink: 0;
    color: var(--accent);
}
html body .demo-banner a { color: var(--accent); font-weight: 700; }

html body .badge-success { background: var(--ok-bg); color: var(--ok); }
html body .badge-danger { background: var(--danger-bg); color: var(--danger); }

/* ——— Shell / sidebar (как шапка cybsoft.tech) ——— */
html body .main-content { background: var(--bg); }
html body:has(.sidebar.sidebar-1c) .main-content { margin-left: var(--sidebar-width); }

html body .sidebar.sidebar-1c {
    width: var(--sidebar-width);
    background: #323541;
    box-shadow: 4px 0 24px rgba(0, 0, 0, 0.25);
}
html body .sidebar.sidebar-1c .sidebar-1c-rail {
    width: var(--sidebar-width);
    background: #323541;
    padding: 12px 10px 14px;
}
html body .sidebar-1c-brand {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 6px 8px 14px;
    margin-bottom: 4px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
    color: #facc15;
}
html body .sidebar-1c-brand-logo {
    width: 36px;
    height: 36px;
    border-radius: 10px;
    flex-shrink: 0;
    display: block;
}
html body .sidebar-1c-brand-name {
    font-family: var(--font-display);
    font-weight: 500;
    font-size: 14px;
    color: #facc15;
    letter-spacing: 0.02em;
}
html body .sidebar-1c-brand-sub {
    display: block;
    font-size: 11px;
    font-weight: 500;
    color: #a1a1aa;
    margin-top: 1px;
    font-family: var(--font-body);
}

html body .sidebar-1c-close-btn,
html body .sidebar-1c-panel-back {
    background: transparent;
    color: #e5e7eb;
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}
html body .sidebar.sidebar-1c .sidebar-1c-section-btn {
    color: #e5e7eb;
    border-radius: 10px;
    min-height: 44px;
}
html body .sidebar.sidebar-1c .sidebar-1c-section-btn::before { background: #facc15; }
html body .sidebar.sidebar-1c .sidebar-1c-section-btn:hover,
html body .sidebar.sidebar-1c .sidebar-1c-section-btn.active {
    background: rgba(250, 204, 21, 0.1);
    color: #fafafa;
    border-color: transparent;
    box-shadow: none;
}
html body .sidebar.sidebar-1c .sidebar-1c-section-btn.active .sidebar-1c-section-icon,
html body .sidebar.sidebar-1c .sidebar-1c-section-btn:hover .sidebar-1c-section-icon {
    color: #facc15;
}
html body .sidebar.sidebar-1c .sidebar-1c-section-icon { color: #a1a1aa; }
html body .nav-svg { width: 20px; height: 20px; display: block; flex-shrink: 0; }

html body .sidebar.sidebar-1c .sidebar-tabs-wrap { border-top-color: rgba(255, 255, 255, 0.08); }
html body .sidebar.sidebar-1c .sidebar-tabs-wrap .tab-btn {
    background: rgba(255, 255, 255, 0.04);
    border-color: rgba(255, 255, 255, 0.08);
    color: #a1a1aa;
}
html body .sidebar.sidebar-1c .sidebar-tabs-wrap .tab-btn.active {
    background: var(--accent-dim);
    color: #facc15;
    border-color: rgba(250, 204, 21, 0.35);
    border-bottom: 1px solid rgba(250, 204, 21, 0.35);
}

html body .sidebar-1c-manual-link,
html body .theme-toggle-btn,
html body .sidebar-1c-logout-btn {
    background: rgba(255, 255, 255, 0.04);
    border: 1px solid rgba(255, 255, 255, 0.08);
    color: #e5e7eb;
    min-height: 44px;
    border-radius: 10px;
}
html body .sidebar-1c-manual-link.active,
html body .sidebar-1c-manual-link:hover,
html body .theme-toggle-btn:hover {
    background: rgba(250, 204, 21, 0.12);
    color: #facc15;
}
html body .sidebar-1c-logout-btn { color: #fca5a5; }
html body .sidebar-1c-logout-btn:hover { background: rgba(239, 68, 68, 0.16); }
html body .theme-toggle-btn.theme-toggle-btn-icon { min-width: 44px; min-height: 44px; }
html body .theme-toggle-icon { display: grid; place-items: center; }
html body .theme-toggle-icon .icon-sun { display: none; }
html.theme-dark body .theme-toggle-icon .icon-moon { display: none; }
html.theme-dark body .theme-toggle-icon .icon-sun { display: block; }

html body .sidebar.sidebar-1c .sidebar-1c-panel,
html body .sidebar.sidebar-1c .sidebar-1c-panel-body {
    background: var(--bg-card);
    color: var(--text);
    border-color: var(--border);
}
html body .sidebar.sidebar-1c .sidebar-1c-general-col-title,
html body .sidebar.sidebar-1c .sidebar-1c-panel-section-title {
    color: var(--text-muted);
    border-bottom-color: var(--border);
    font-family: var(--font-display);
    font-size: 11px;
}
html body .sidebar.sidebar-1c .sidebar-1c-item {
    color: var(--text);
    border-radius: 8px;
    padding: 8px 10px;
    min-height: 40px;
}
html body .sidebar.sidebar-1c .sidebar-1c-item:hover { background: var(--bg-elevated); }
html body .sidebar.sidebar-1c .sidebar-1c-item.active {
    background: var(--accent-dim);
    color: var(--accent);
    font-weight: 600;
}
html body .sidebar.sidebar-1c .sidebar-1c-item-icon { color: var(--text-muted); }
html body .sidebar.sidebar-1c .sidebar-1c-item.active .sidebar-1c-item-icon { color: var(--accent); }

html body .sidebar-toggle {
    display: none;
    background: var(--accent);
    color: var(--accent-on);
    min-width: 44px;
    min-height: 44px;
    border-radius: var(--btn-radius);
    padding: 10px;
    box-shadow: var(--shadow-md);
}
html body .sidebar-overlay { background: rgba(15, 17, 23, 0.55); }

html body .main-content > .tabs-bar {
    background: var(--bg-card);
    border-bottom: 1px solid var(--border);
}
html body .main-content > .tabs-bar-inner .tab-btn {
    background: var(--bg-elevated);
    color: var(--text-muted);
    border: 1px solid var(--border);
    min-height: 40px;
}
html body .main-content > .tabs-bar-inner .tab-btn.active {
    background: var(--bg-card);
    color: var(--text);
    box-shadow: inset 0 -2px 0 var(--accent);
}

/* ——— Tables (global) ——— */
html body table thead,
html body .doc-list .doc-table th,
html body .pc-table th,
html body .products-table th,
html body .cart-table th {
    background: var(--bg-elevated);
    color: var(--text-muted);
    border-bottom: 1px solid var(--border);
    font-size: 12px;
    text-transform: uppercase;
    letter-spacing: 0.04em;
    font-weight: 600;
}
html body td,
html body .doc-list .doc-table td {
    color: var(--text);
    border-bottom-color: var(--border);
}
html body tr:hover,
html body .doc-list .doc-table tbody tr:hover,
html body .pc-table tr:hover,
html body .products-table tr:hover,
html body .cart-table tr:hover {
    background: var(--accent-dim);
}

/* ——— Lists / directories / reports ——— */
html body .doc-list .doc-toolbar,
html body .report-page.report-1c .doc-toolbar,
html body .doc-form .doc-toolbar {
    gap: 12px;
    margin-bottom: 16px;
    padding-bottom: 12px;
    border-bottom: 1px solid var(--border);
}
html body .doc-list .doc-toolbar .doc-title,
html body .report-page.report-1c .doc-toolbar .doc-title,
html body .doc-form .doc-toolbar .doc-title {
    color: var(--text);
    font-size: 1.25rem;
    font-weight: 600;
}

html body .doc-list .doc-table-wrap,
html body .report-page.report-1c .doc-table-wrap {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--card-radius);
    box-shadow: none;
}

html body .doc-list .doc-list-search-input,
html body .doc-list .doc-list-filters select,
html body .doc-list .doc-list-period-display,
html body .doc-list .doc-list-per-page-select,
html body .search-box input {
    background: var(--bg-elevated);
    color: var(--text);
    border: 1px solid var(--border);
    border-radius: var(--btn-radius);
    min-height: 40px;
}
html body .doc-list .doc-list-search-input:hover:not(:disabled),
html body .doc-list .doc-list-filters select:hover:not(:disabled),
html body .search-box input:hover:not(:disabled) {
    border-color: var(--accent);
    box-shadow: inset 0 0 0 1px var(--accent);
}
html body .doc-list .doc-list-search-input:focus,
html body .doc-list .doc-list-filters select:focus,
html body .search-box input:focus {
    border-color: var(--accent);
    outline: none;
    box-shadow: inset 0 0 0 2px var(--accent);
}
html body .doc-list .doc-list-filters label,
html body .doc-list .doc-list-period-label { color: var(--text-muted); }

html body .doc-list-filters-trigger {
    background: var(--bg-elevated);
    color: var(--text);
    border: 1px solid var(--border);
    min-height: 44px;
    border-radius: var(--btn-radius);
    font-weight: 600;
}
html body .doc-list-filters-trigger:hover {
    border-color: var(--accent);
    background: var(--bg-card);
}

html body .doc-list .doc-list-pagination {
    color: var(--text-muted);
    padding-top: 12px;
}
html body .doc-list .doc-list-totals-bar,
html body .doc-form .doc-table-card .doc-table .doc-totals-row {
    background: var(--bg-elevated);
    color: var(--text);
    border-top: 1px solid var(--border);
}
html body .doc-list .doc-table .doc-list-empty { color: var(--text-muted); }

html body .doc-list .doc-list-sort-link { color: var(--text-muted); text-decoration: none; }
html body .doc-list .doc-list-sort-link.active,
html body .doc-list .doc-list-sort-link:hover { color: var(--accent); }

/* ——— Objects / document forms ——— */
html body .doc-form .doc-header,
html body .doc-form .doc-table-card,
html body .preview-zoom-popup {
    background: var(--bg-card);
    border: 1px solid var(--border);
    color: var(--text);
    box-shadow: none;
}
html body .doc-form .doc-header .doc-header-field label {
    color: var(--text-muted);
}
html body .doc-form .doc-header .doc-section-divider { border-top-color: var(--border); }
html body .doc-form .doc-form-actions {
    background: var(--bg-card);
    border-top-color: var(--border);
}
html body .form-group label,
html body .admin-settings-section-title,
html body .doc-form .doc-section-title { color: var(--text); }
html body .form-group input,
html body .form-group select,
html body .form-group textarea,
html body .admin-settings-row select,
html body .admin-settings-row input[type="text"],
html body .admin-settings-row input[type="number"],
html body .admin-settings-row input[type="password"],
html body .doc-form .doc-table-card .doc-table input[type="text"],
html body .doc-form .doc-table-card .doc-table input[type="number"],
html body .doc-form .doc-table-card .doc-table select {
    background: var(--bg-elevated);
    color: var(--text);
    border: 1px solid var(--border);
    border-radius: var(--btn-radius);
}
html body .form-group input:hover:not(:disabled),
html body .form-group select:hover:not(:disabled),
html body .form-group textarea:hover:not(:disabled),
html body .doc-form .doc-table-card .doc-table input:hover:not(:disabled),
html body .doc-form .doc-table-card .doc-table select:hover:not(:disabled) {
    border-color: var(--accent);
    box-shadow: inset 0 0 0 1px var(--accent);
}
html body .form-group input:focus,
html body .form-group select:focus,
html body .form-group textarea:focus,
html body .doc-form .doc-table-card .doc-table input:focus,
html body .doc-form .doc-table-card .doc-table select:focus {
    border-color: var(--accent);
    outline: none;
    box-shadow: inset 0 0 0 2px var(--accent);
}
html body .admin-settings-row { border-bottom-color: var(--border); }
html body .admin-settings-row label { color: var(--text); }
html body .admin-settings-row .hint { color: var(--text-muted); }
html body .admin-settings-integration-info { background: var(--bg-elevated); color: var(--text-muted); }

html body .float-line__input {
    color: var(--text) !important;
    border-bottom-color: var(--border) !important;
}
html body .float-line__input:focus { border-bottom-color: var(--accent) !important; }
html body .float-line__label { color: var(--text-muted); }
html body .float-line__input:focus ~ .float-line__label,
html body .float-line:has(.float-line__input:focus) .float-line__label {
    color: var(--accent) !important;
}

html body .modal-content,
html body .doc-period-modal .modal-box {
    background: var(--bg-card) !important;
    background-color: var(--bg-card) !important;
    border: 1px solid var(--border);
    color: var(--text);
    border-radius: var(--card-radius) !important;
    box-shadow: var(--shadow-md);
}

html body .tab-close-control.tab-close-icon-btn {
    background: var(--bg-elevated) !important;
    border: 1px solid var(--border) !important;
    color: var(--text) !important;
}
html body.in-tab-frame .tab-close-control.tab-close-icon-btn {
    background: var(--bg-card) !important;
}
@media (max-width: 768px) {
    html body .tab-close-control.tab-close-floating-btn,
    html body .tab-close-control.tab-close-icon-btn,
    html body.in-tab-frame .tab-close-control.tab-close-floating-btn,
    html body.in-tab-frame .tab-close-control.tab-close-icon-btn,
    html.theme-dark body.in-tab-frame .tab-close-control.tab-close-floating-btn,
    html.theme-dark body.in-tab-frame .tab-close-control.tab-close-icon-btn {
        width: 44px !important;
        min-width: 44px !important;
        max-width: 44px !important;
        height: 44px !important;
        background: var(--danger) !important;
        border: 1px solid var(--danger) !important;
        color: #fff !important;
        box-shadow: 0 2px 10px rgba(220, 38, 38, 0.45);
    }
    html body .tab-close-control.tab-close-floating-btn:hover,
    html body .tab-close-control.tab-close-icon-btn:hover,
    html.theme-dark body.in-tab-frame .tab-close-control.tab-close-floating-btn:hover,
    html.theme-dark body.in-tab-frame .tab-close-control.tab-close-icon-btn:hover {
        background: #b91c1c !important;
        border-color: #b91c1c !important;
        color: #fff !important;
    }
}

html body .pc-free { color: var(--ok); }
html body .reserves-schedule-block { background: var(--accent); color: var(--accent-on); }

html body:has(.sidebar.sidebar-1c) .main-content:has(.workplace-container) {
    width: calc(100vw - var(--sidebar-width));
}
@media (min-width: 993px) {
    html body:has(.sidebar.sidebar-1c) .main-content:has(.workplace-container) {
        left: var(--sidebar-width);
        width: auto;
    }
}

html body .club-stats-page h2 { color: var(--text); }
html body .stats-kpi-card .stats-kpi-label { color: var(--text-muted); }
html body .stats-kpi-card .stats-kpi-value { color: var(--text); font-family: var(--font-display); }
html body .stats-kpi-card.income .stats-kpi-value { color: var(--ok); }
html body .stats-kpi-card.expense .stats-kpi-value { color: var(--danger); }
html body .top-spent-item:nth-child(n+4) { background: var(--bg-elevated); color: var(--text); }

html.theme-dark body .page-content-card,
html.theme-dark body .header,
html.theme-dark body .doc-form .doc-header,
html.theme-dark body .main-content:has(.doc-form) .page-content-card,
html.theme-dark body .main-content:has(.doc-form) .container.doc-form-full {
    background: var(--bg-card) !important;
    color: var(--text);
    border-color: var(--border);
}
html.theme-dark body.has-sidebar,
html.theme-dark body .main-content,
html.theme-dark body.in-tab-frame {
    background: var(--bg) !important;
    color: var(--text);
}

@media (prefers-reduced-motion: reduce) {
    html body *, html body *::before, html body *::after {
        animation-duration: 0.01ms !important;
        transition-duration: 0.01ms !important;
    }
}

/* ——— Tablet ——— */
@media (max-width: 1024px) {
    html body .sidebar.sidebar-1c .sidebar-1c-general-content {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
    html body .doc-form form:has(.doc-table-card) .doc-header-grid {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 992px) {
    html body .sidebar-toggle { display: grid; place-items: center; }
    html body:has(.sidebar.sidebar-1c) .main-content { margin-left: 0; }
    html body .sidebar.sidebar-1c .sidebar-1c-rail,
    html body .sidebar.sidebar-1c.open { background: #323541; }

    html body .doc-list-filters-with-menu .doc-list-filters-dropdown {
        background: var(--bg-card) !important;
        border-color: var(--border) !important;
        color: var(--text);
        width: min(100%, 420px) !important;
        max-width: calc(100vw - 24px) !important;
        box-shadow: var(--shadow-md) !important;
        max-height: min(70vh, calc(100dvh - 96px));
        overflow-x: hidden;
        overflow-y: auto;
        -webkit-overflow-scrolling: touch;
        overscroll-behavior: contain;
    }

    html body .header-content { flex-direction: column; align-items: flex-start; gap: 12px; }
    html body .doc-list .doc-list-search-form,
    html body .doc-form .doc-form-actions,
    html body .doc-toolbar {
        flex-wrap: wrap;
    }
    html body .doc-form .doc-form-actions .btn { flex: 1 1 auto; min-width: 140px; }
}

@media (max-width: 768px) {
    html body .doc-list-filters-with-menu.is-open .doc-list-filters-dropdown {
        position: fixed !important;
        top: max(12px, env(safe-area-inset-top, 0px)) !important;
        left: 12px !important;
        right: 12px !important;
        width: auto !important;
        max-width: none !important;
        margin-top: 0 !important;
        max-height: calc(100dvh - 24px - env(safe-area-inset-bottom, 0px)) !important;
        overflow-x: hidden !important;
        overflow-y: auto !important;
        -webkit-overflow-scrolling: touch;
        overscroll-behavior: contain;
        z-index: 400 !important;
    }
}

/* Mobile: списки как карточки, объекты столбиком */
@media (max-width: 767px) {
    html body .sidebar.sidebar-1c .sidebar-1c-general-content { grid-template-columns: 1fr; }
    html body .page-content-card > .container { padding: 10px; }
    html body .main-content:has(.doc-list) .container,
    html body .main-content:has(.workplace-container) .container {
        padding-left: 12px;
        padding-right: 12px;
    }

    html body .doc-list .doc-list-table-scroll .doc-table thead { display: none; }
    html body .doc-list .doc-list-table-scroll .doc-table,
    html body .doc-list .doc-list-table-scroll .doc-table tbody {
        display: block;
        width: 100%;
    }
    html body .doc-list .doc-list-table-scroll .doc-table tbody tr.doc-list-row {
        display: grid;
        grid-template-columns: 36px 1fr;
        gap: 6px 10px;
        width: 100%;
        margin: 0 0 10px;
        padding: 12px;
        background: var(--bg-elevated);
        border: 1px solid var(--border);
        border-radius: var(--card-radius);
        box-sizing: border-box;
    }
    html body .doc-list .doc-list-table-scroll .doc-table tbody td {
        display: flex;
        justify-content: space-between;
        align-items: baseline;
        gap: 12px;
        grid-column: 1 / -1;
        width: 100%;
        min-width: 0 !important;
        padding: 4px 0;
        border: none;
        font-size: 14px;
        font-weight: 600;
        white-space: normal;
        color: var(--accent);
    }
    html body .doc-list .doc-list-table-scroll .doc-table tbody td a {
        color: var(--accent);
    }
    html body .doc-list .doc-list-table-scroll .doc-table tbody td::before {
        content: attr(data-label);
        color: var(--text-muted);
        font-size: 11px;
        font-weight: 600;
        text-transform: uppercase;
        letter-spacing: 0.04em;
        flex: 0 0 42%;
        max-width: 42%;
    }
    html body .doc-list .doc-list-table-scroll .doc-table tbody td.doc-list-col-check {
        grid-column: 1;
        grid-row: 1;
        justify-content: flex-start;
        padding: 0;
        color: var(--text);
    }
    html body .doc-list .doc-list-table-scroll .doc-table tbody td.doc-list-col-check::before { content: none; }
    html body .doc-list .doc-list-table-scroll .doc-table tbody td:nth-child(2) {
        grid-column: 2;
        grid-row: 1;
        font-weight: 700;
        font-family: var(--font-display);
        font-size: 15px;
        color: var(--accent);
    }
    html body .doc-list .doc-list-table-scroll .doc-table .doc-list-empty {
        display: block;
        border: none;
        color: var(--text-muted);
        font-weight: 500;
    }
    html body .doc-list .doc-list-table-scroll .doc-table .doc-list-empty::before { content: none; }

    html body .doc-list .doc-list-totals-bar { overflow-x: auto; }

    html body .btn { width: 100%; }
    html body .doc-list .doc-list-actions .btn,
    html body .doc-list .doc-list-search-form .btn { width: auto; flex: 1 1 auto; }

    html body .stats-kpi { grid-template-columns: 1fr 1fr; gap: 8px; }

    html body .doc-form .doc-header { padding: 14px; }
    html body .doc-header-grid { grid-template-columns: 1fr !important; }
}

@media (max-width: 480px) {
    html body .stats-kpi { grid-template-columns: 1fr; }
    html body .header h1 { font-size: 1.15rem; }
}

html body .doc-form .doc-permission-check {
    color: var(--text);
    padding: 8px 10px;
    border-radius: 8px;
    background: var(--bg-elevated);
    border: 1px solid var(--border);
    min-height: 44px;
}
html body .doc-form .doc-permission-check input { accent-color: var(--accent); }
html body .doc-permissions-section { margin-bottom: 16px; }
html body .lic-row-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    align-items: center;
}
html body .lic-row-actions .btn { min-height: 40px; width: auto; }

@media (max-width: 767px) {
    html body .doc-form .doc-permissions-grid { grid-template-columns: 1fr; }
    html body .lic-row-actions { width: 100%; }
    html body .lic-row-actions .btn { flex: 1 1 100%; }
}

/* ============================================================
   Документы и карточки — 1С Taxi, но читаемее
   Командная панель → шапка реквизитов → табличная часть → записать
   ============================================================ */

html body .doc-list .doc-toolbar .doc-title,
html body .doc-form .doc-toolbar .doc-title,
html body .report-page.report-1c .doc-toolbar .doc-title {
    display: block !important;
    margin: 0;
    font-family: var(--font-display);
    font-size: 1.05rem;
    font-weight: 500;
    letter-spacing: -0.02em;
    color: var(--text);
    flex: 1 1 auto;
    min-width: 0;
    order: 0;
}

html body .doc-list .doc-toolbar,
html body .doc-form .doc-toolbar,
html body .report-page.report-1c .doc-toolbar {
    display: flex;
    align-items: center;
    gap: 12px;
    flex-wrap: wrap;
    margin: 0 0 12px;
    padding: 10px 14px;
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--card-radius);
    border-left: 3px solid var(--accent);
    position: sticky;
    top: 0;
    z-index: 8;
    flex-shrink: 0;
}
html body .doc-form .doc-toolbar .doc-toolbar-actions,
html body .doc-list .doc-toolbar .doc-toolbar-actions {
    display: flex;
    align-items: center;
    gap: 8px;
    order: 2;
    margin-left: auto;
    flex-wrap: wrap;
}
html body .doc-form form:has(.doc-cmd-write) .doc-form-actions {
    display: none !important;
}

html body .doc-form .doc-cmd-write {
    min-height: 40px;
    padding: 8px 16px;
}

/* Шапка: плитки реквизитов */
html body .doc-form form:has(.doc-table-card),
html body .doc-form form.doc-form-document {
    display: flex !important;
    flex-direction: column;
    grid-template-columns: none !important;
    grid-template-rows: none !important;
    gap: 12px;
    min-height: 0;
    flex: 1 1 0;
}
html body .doc-form form:has(.doc-table-card) .doc-toolbar,
html body .doc-form form.doc-form-document .doc-toolbar {
    grid-column: auto;
    flex: 0 0 auto;
}
html body .doc-form form:has(.doc-table-card) .doc-header-grid,
html body .doc-form form.doc-form-document .doc-header-grid {
    grid-column: auto !important;
    grid-row: auto !important;
    align-self: stretch;
    flex: 0 0 auto;
    max-width: 1120px;
    width: 100%;
    overflow: visible;
    display: grid;
    grid-template-columns: repeat(12, 1fr);
}
html body .doc-form form:has(.doc-table-card) .doc-table-card,
html body .doc-form form.doc-form-document .doc-table-card {
    grid-column: auto !important;
    grid-row: auto !important;
    flex: 1 1 0;
    min-height: 220px;
    width: 100%;
}

html body .doc-form form .doc-header-grid {
    gap: 12px;
    padding: 8px;
    max-width: 1120px;
    margin: 0;
    overflow: visible;
}
html body .doc-form:has(form.doc-form-card) form .doc-header-grid,
html body .doc-form form.doc-form-card .doc-header-grid {
    max-width: 1120px;
    margin: 0;
}
html body .doc-form form .doc-header-grid .doc-header.doc-header-tile--wide {
    grid-column: span 6 !important;
}
html body .doc-form form .doc-header-grid .doc-header.doc-header-tile--wide:only-child,
html body .doc-form form .doc-header-grid .doc-tile-media {
    grid-column: 1 / -1 !important;
}
html body .doc-form .doc-header,
html body .doc-form .doc-header.doc-header-tile {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--card-radius);
    padding: 14px 16px 16px;
    box-shadow: none;
    overflow: visible;
}
html body .doc-form .doc-header-tile {
    border-left: 3px solid var(--accent);
}
html body .doc-form .doc-header-tile--accent-blue,
html body .doc-form .doc-header-tile--accent-indigo {
    border-left-color: var(--accent);
}
html body .doc-form .doc-section-title,
html body .doc-form .doc-header-tile .doc-section-title,
html body .doc-form .doc-header.doc-header-tile--wide > .doc-section-title {
    font-family: var(--font-display);
    font-size: 11px;
    font-weight: 600;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: var(--accent);
    border-bottom: 1px solid var(--border);
    padding-bottom: 8px;
    margin: 0 0 12px;
}

html body .doc-form .doc-header.doc-header-tile--wide {
    display: flex;
    flex-direction: column;
    gap: 12px;
    align-items: stretch;
}
html body .doc-form .doc-header.doc-header-tile--wide > .doc-section-title {
    grid-column: 1 / -1;
    flex: unset;
    width: 100%;
}
html body .doc-form .doc-field-span {
    grid-column: 1 / -1;
}
html body .doc-form .doc-header-tile.doc-fields-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 12px 16px;
    align-items: start;
}
html body .doc-form .doc-header-tile.doc-fields-grid > .doc-section-title,
html body .doc-form .doc-header-tile.doc-fields-grid > .doc-field-span {
    grid-column: 1 / -1;
}
html body .doc-form .doc-header.doc-header-tile--wide > .doc-header-field {
    flex: unset;
    min-width: 0;
}
html body .doc-form .doc-header .doc-header-field textarea {
    min-height: 88px;
    width: 100%;
    resize: vertical;
    box-sizing: border-box;
}
html body .doc-form .doc-field-locked,
html body .doc-form .readonly-field {
    display: block;
    width: 100%;
    box-sizing: border-box;
    padding: 8px 12px;
    min-height: 40px;
    overflow-wrap: anywhere;
    word-break: break-word;
}
html body .doc-form .doc-header-field .btn {
    width: auto;
    margin-top: 8px;
}
html body .doc-period-block {
    width: 100%;
}
html body .doc-period-display {
    flex: 1 1 auto;
    min-width: 0;
}

html body .doc-form .doc-header .doc-header-field label {
    display: block;
    margin-bottom: 6px;
    font-size: 12px;
    font-weight: 600;
    letter-spacing: 0.02em;
    text-transform: none;
    color: var(--text-muted);
}
html body .doc-form .doc-header .doc-header-field input[type="date"],
html body .doc-form .doc-header .doc-header-field input[type="datetime-local"],
html body .doc-form .doc-header .doc-header-field input[type="text"],
html body .doc-form .doc-header .doc-header-field input[type="number"],
html body .doc-form .doc-header .doc-header-field input[type="url"],
html body .doc-form .doc-header .doc-header-field input[type="password"],
html body .doc-form .doc-header .doc-header-field input[data-type="date"],
html body .doc-form .doc-header .doc-header-field input[data-type="time"],
html body .doc-form .doc-header .doc-header-field input[data-type="datetime"],
html body .doc-form .doc-header .doc-header-field select,
html body .doc-form .doc-header .doc-header-field textarea,
html body .doc-form .doc-header .doc-header-field-readonly .doc-field-locked,
html body .doc-period-display {
    background: var(--bg-elevated);
    color: var(--text);
    border: 1px solid var(--border);
    border-radius: 8px;
    min-height: 40px;
}
html body .doc-form .doc-header .doc-header-field input:hover:not(:disabled),
html body .doc-form .doc-header .doc-header-field select:hover:not(:disabled),
html body .doc-form .doc-header .doc-header-field textarea:hover:not(:disabled) {
    border-color: var(--accent);
    box-shadow: inset 0 0 0 1px var(--accent);
}
html body .doc-form .doc-header .doc-header-field input:focus,
html body .doc-form .doc-header .doc-header-field select:focus,
html body .doc-form .doc-header .doc-header-field textarea:focus {
    border-color: var(--accent);
    outline: none;
    box-shadow: inset 0 0 0 2px var(--accent);
}
html body .doc-form .doc-header .doc-header-field > select {
    color-scheme: inherit;
    cursor: pointer;
}
html body .doc-form .doc-header .doc-header-field > select option {
    background: var(--bg-card);
    color: var(--text);
}
html body .doc-form .doc-header .doc-field-hint {
    display: block;
    white-space: normal;
    overflow-wrap: anywhere;
    word-break: break-word;
    max-width: 100%;
}
html body .doc-form form.club-app-form .doc-header.doc-header-tile--wide {
    flex-direction: column;
    flex-wrap: nowrap;
    align-items: stretch;
    gap: 12px;
}
html body .doc-form form.club-app-form .doc-header.doc-header-tile--wide > .doc-section-title,
html body .doc-form form.club-app-form .doc-header.doc-header-tile--wide > .doc-header-field,
html body .doc-form form.club-app-form .doc-header.doc-header-tile--wide > .doc-field-hint {
    flex: 0 0 auto;
    width: 100%;
    max-width: 36rem;
}
html body .main-content:has(.settings-card-form),
html body .main-content:has(.settings-card-form) .page-content-card,
html body .main-content:has(.settings-card-form) .container.doc-form-full,
html body .main-content:has(.settings-card-form) .doc-form,
html body .main-content:has(.settings-card-form) .doc-form form {
    overflow: visible;
    height: auto;
    max-height: none;
    flex: none;
}
html body .doc-period-block {
    display: flex;
    align-items: center;
    gap: 8px;
    flex-wrap: wrap;
}
html body .doc-period-display {
    display: inline-flex;
    align-items: center;
    padding: 8px 12px;
    font-variant-numeric: tabular-nums;
    min-width: 180px;
}
html body .doc-period-btn-icon {
    min-width: 40px;
    min-height: 40px;
    border-radius: 8px;
    background: var(--bg-elevated);
    border: 1px solid var(--border);
    color: var(--text);
    cursor: pointer;
}
html body .doc-period-btn-icon:hover {
    border-color: var(--accent);
    color: var(--accent);
}

html body .doc-form .doc-header-field.doc-header-field--primary input[type="number"] {
    font-family: var(--font-display);
    font-size: 1.5rem;
    color: var(--accent);
    min-height: 48px;
}
html body .doc-form .level-progress-fill { background: var(--accent); }
html body .doc-form .level-badge {
    background: var(--accent-dim);
    border-color: var(--accent);
    color: var(--accent);
}
html body .doc-form .pc-time-tab.active {
    background: var(--accent-dim);
    border-color: var(--accent);
    color: var(--accent);
}
html body .doc-form .doc-permissions-section,
html body .doc-form .doc-permissions-fieldset {
    background: var(--bg-card);
    border-color: var(--border);
    color: var(--text);
}
html body .doc-form .doc-permissions-section-title { color: var(--text); border-bottom-color: var(--border); }

/* Табличная часть документа */
html body .doc-form .doc-table-card {
    display: flex;
    flex-direction: column;
    min-height: 0;
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--card-radius);
    overflow: hidden;
}
html body .doc-form .doc-table-card:has(.nom-picker.is-open) {
    overflow: visible;
}
html body .doc-form .doc-table-card:has(.nom-picker.is-open) .doc-form-table-scroll {
    overflow: visible;
}
html body .doc-form .doc-table-card .nom-cell {
    min-width: 220px;
    overflow: visible;
    position: relative;
    z-index: 1;
}
html body .doc-form .doc-table-card tr:has(.nom-picker.is-open) {
    z-index: 5;
    position: relative;
}
html body .doc-form .doc-table-card .doc-table-head {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 8px;
    padding: 10px 14px;
    background: var(--bg-elevated);
    border-bottom: 1px solid var(--border);
}
html body .doc-form .doc-table-card .doc-table-head .doc-table-title {
    margin: 0 auto 0 0;
    font-family: var(--font-display);
    font-size: 11px;
    font-weight: 500;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: var(--accent);
}
html body .doc-form .doc-table-card .doc-table-head .btn {
    min-height: 36px;
    padding: 6px 12px;
    width: auto;
}
html body .doc-form .doc-table-card .doc-form-table-scroll .doc-table th {
    background: var(--bg-elevated);
    color: var(--text-muted);
    box-shadow: 0 1px 0 0 var(--border);
}
html body .doc-form .doc-table-card .doc-table tbody tr:nth-child(even) {
    background: rgba(255, 255, 255, 0.02);
}
html body .doc-form .doc-table-card .doc-table tbody tr:hover,
html body .doc-form .doc-table-card .doc-table tbody tr.selected {
    background: var(--accent-dim);
}
html body .doc-form .doc-table-card .doc-table tbody tr.selected {
    box-shadow: inset 3px 0 0 var(--accent);
}
html body .doc-form .doc-table-card .doc-form-totals-bar {
    background: var(--bg-elevated);
    border-top: 1px solid var(--border);
}
html body .doc-form .doc-table-card .doc-form-totals-bar .doc-totals-row td {
    font-weight: 700;
    font-variant-numeric: tabular-nums;
    color: var(--text);
}
html body .doc-form .doc-table-card .doc-table th.sortable.sort-asc::after,
html body .doc-form .doc-table-card .doc-table th.sortable.sort-desc::after,
html body .doc-form .doc-table-card .doc-table.sortable:not(:has(.sort-asc, .sort-desc)) th.sortable:hover::after {
    color: var(--accent);
}

/* Журнал (список) — как список документов 1С */
html body .doc-list .doc-table tbody tr.doc-list-row:hover {
    background: var(--accent-dim);
}
html body .doc-list .doc-table-wrap {
    border-left: 3px solid transparent;
}
html body .doc-list .doc-list-num,
html body .doc-form .doc-table td.num {
    font-variant-numeric: tabular-nums;
}

@media (max-width: 767px) {
    html body .doc-list .doc-toolbar,
    html body .doc-form .doc-toolbar {
        position: static;
        flex-direction: column;
        align-items: stretch;
    }
    html body .doc-form .doc-toolbar .doc-toolbar-actions,
    html body .doc-list .doc-toolbar .doc-toolbar-actions {
        margin-left: 0;
        width: 100%;
    }
    html body .doc-form .doc-toolbar .doc-toolbar-actions .btn,
    html body .doc-form .doc-cmd-write {
        flex: 1 1 auto;
    }
    html body .doc-form .doc-header-tile.doc-fields-grid {
        grid-template-columns: 1fr;
    }
    html body .doc-form form .doc-header-grid .doc-header.doc-header-tile--wide {
        grid-column: 1 / -1 !important;
    }
    html body .doc-form .doc-table-card .doc-form-table-scroll {
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
    }
    html body .doc-form .doc-table-card .doc-table {
        min-width: 640px;
    }
}

/* ============================================================
   Рабочее место: ПК слева на всю ширину, товары+корзина справа столбиком
   ============================================================ */

html body.page-admin-workplace .main-content:has(.workplace-container) {
    height: 100dvh;
    max-height: 100dvh;
    overflow: hidden;
}
html body.page-admin-workplace .main-content:has(.workplace-container) .page-content-card,
html body.page-admin-workplace .main-content:has(.workplace-container) .container {
    flex: 1 1 0;
    min-height: 0;
    overflow: hidden;
    display: flex;
    flex-direction: column;
}
html body.page-admin-workplace .main-content:has(.workplace-container) .container {
    padding: 8px 10px 10px;
    gap: 8px;
}
html body.page-admin-workplace .demo-banner {
    flex-shrink: 0;
    margin-bottom: 0;
    font-size: 13px;
    padding: 8px 12px;
}

html body.page-admin-workplace .workplace-container {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(240px, 30%);
    grid-template-rows: minmax(0, 1fr);
    gap: 10px;
    flex: 1 1 0;
    min-height: 0;
    overflow: hidden;
}

html body.page-admin-workplace .workplace-left,
html body.page-admin-workplace .workplace-right {
    display: flex;
    flex-direction: column;
    min-height: 0;
    min-width: 0;
    max-height: 100%;
    overflow: hidden;
    background: transparent;
    gap: 10px;
}
html body.page-admin-workplace .workplace-left {
    width: 100%;
}
html body.page-admin-workplace .workplace-left .workplace-section {
    flex: 1 1 0;
}
html body.page-admin-workplace .workplace-right .workplace-section {
    flex: 1 1 0;
}

html body.page-admin-workplace .workplace-section {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--card-radius);
    border-left: 3px solid var(--accent);
    box-shadow: none;
    padding: 10px 12px;
    min-height: 0;
    overflow: hidden;
    display: flex;
    flex-direction: column;
}
html body.page-admin-workplace .workplace-section h3 {
    margin: 0 0 8px;
    padding: 0 0 8px;
    border-bottom: 1px solid var(--border);
    font-family: var(--font-display);
    font-size: 0.82rem;
    font-weight: 500;
    letter-spacing: 0.04em;
    text-transform: uppercase;
    color: var(--text);
    cursor: default;
}
html body.page-admin-workplace #cart-section > h3 {
    cursor: pointer;
}
html body.page-admin-workplace .workplace-section h3:hover {
    color: var(--text);
}
html body.page-admin-workplace #cart-section > h3:hover {
    color: var(--accent);
}
html body.page-admin-workplace .collapse-btn {
    display: inline-flex;
    color: var(--text-muted);
}
html body.page-admin-workplace .collapse-btn:hover {
    color: var(--accent);
    background: var(--accent-dim);
}
html body.page-admin-workplace #cart-section.collapsed {
    flex: 0 0 auto;
    height: auto;
    min-height: 0;
    max-height: none;
}
html body.page-admin-workplace #cart-section.collapsed h3 {
    margin-bottom: 0;
    padding-bottom: 0;
    border-bottom: 0;
    min-height: 0;
    max-height: none;
}
html body.page-admin-workplace .workplace-right #products-section:not(.collapsed),
html body.page-admin-workplace .workplace-right #cart-section:not(.collapsed) {
    flex: 1 1 0;
}

html body.page-admin-workplace .workplace-toolbar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
    flex-wrap: wrap;
    margin-bottom: 8px;
    flex-shrink: 0;
}
html body.page-admin-workplace .workplace-toolbar h3 {
    margin: 0;
    padding: 0;
    border: 0;
}
html body.page-admin-workplace .workplace-toolbar-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    align-items: center;
}
html body.page-admin-workplace .workplace-toolbar-actions .btn {
    min-height: 36px;
    cursor: pointer;
}
html body.page-admin-workplace .dropdown-wrapper {
    position: relative;
}
html body.page-admin-workplace .pcs-columns-dropdown {
    position: absolute;
    top: calc(100% + 4px);
    left: 0;
    z-index: 30;
    min-width: 200px;
    padding: 10px 12px;
    background: var(--bg-card);
    color: var(--text);
    border: 1px solid var(--border);
    border-radius: 8px;
    box-shadow: var(--shadow-md);
}
html body.page-admin-workplace .pcs-columns-dropdown-title {
    font-weight: 600;
    margin-bottom: 6px;
    font-size: 12px;
    color: var(--text-muted);
}
html body.page-admin-workplace .pcs-columns-dropdown label {
    color: var(--text);
    cursor: pointer;
}

html body.page-admin-workplace .search-box {
    margin-bottom: 8px;
}
html body.page-admin-workplace .search-box input {
    min-height: 40px;
    width: 100%;
    background: var(--bg-elevated);
    color: var(--text);
    border: 1px solid var(--border);
    border-radius: 8px;
    padding: 8px 12px;
}
html body.page-admin-workplace .search-box input:focus {
    border-color: var(--accent);
    outline: none;
    box-shadow: var(--focus-ring);
}

html body.page-admin-workplace #pcs-container,
html body.page-admin-workplace #products-container,
html body.page-admin-workplace #cart-container {
    flex: 1 1 0;
    min-height: 0;
    overflow: auto;
    -webkit-overflow-scrolling: touch;
}

html body.page-admin-workplace .pc-table,
html body.page-admin-workplace .products-table,
html body.page-admin-workplace .cart-table {
    border-color: var(--border);
    background: var(--bg-card);
}
html body.page-admin-workplace .pc-table th,
html body.page-admin-workplace .products-table th,
html body.page-admin-workplace .cart-table th {
    background: var(--bg-elevated);
    color: var(--text-muted);
    border-bottom-color: var(--border);
    position: sticky;
    top: 0;
    z-index: 1;
}
html body.page-admin-workplace .pc-table td,
html body.page-admin-workplace .products-table td,
html body.page-admin-workplace .cart-table td {
    border-bottom-color: var(--border);
    color: var(--text);
}
html body.page-admin-workplace .pc-table th,
html body.page-admin-workplace .pc-table td,
html body.page-admin-workplace .products-table th,
html body.page-admin-workplace .products-table td,
html body.page-admin-workplace .cart-table th,
html body.page-admin-workplace .cart-table td {
    padding: 6px 8px;
    font-size: 13px;
}

html body.page-admin-workplace .cart-summary {
    flex-shrink: 0;
    margin-top: 8px;
    padding-top: 8px;
    border-top: 1px solid var(--border);
}
html body.page-admin-workplace .cart-summary-row {
    color: var(--text-muted);
    font-size: 13px;
}
html body.page-admin-workplace .cart-summary-total {
    color: var(--text);
    font-weight: 700;
}
html body.page-admin-workplace .btn-checkout {
    width: 100%;
    min-height: 44px;
    margin-top: 8px;
    cursor: pointer;
    background: var(--accent);
    color: var(--accent-on);
    border: 0;
    border-radius: var(--btn-radius);
    font-weight: 700;
}
html body.page-admin-workplace .btn-checkout:hover {
    filter: brightness(1.05);
}
html body.page-admin-workplace .btn-checkout:focus-visible {
    outline: none;
    box-shadow: var(--focus-ring);
}

html body.page-admin-workplace .wp-mobile-nav {
    display: none;
}

@media (max-width: 899px) {
    html body.page-admin-workplace .main-content:has(.workplace-container),
    html body.page-admin-workplace.page-admin-workplace .main-content {
        height: 100dvh !important;
        max-height: 100dvh !important;
        overflow: hidden !important;
    }
    html body.page-admin-workplace .page-content-card,
    html body.page-admin-workplace .page-content-card > .container {
        flex: 1 1 0 !important;
        min-height: 0 !important;
        overflow: hidden !important;
    }
    html body.page-admin-workplace .workplace-container {
        display: flex;
        flex-direction: column;
        gap: 0;
        overflow: hidden;
        max-height: none;
    }
    html body.page-admin-workplace .wp-mobile-nav {
        display: grid;
        grid-template-columns: repeat(3, 1fr);
        gap: 6px;
        order: 5;
        flex-shrink: 0;
        padding: 8px 0 calc(8px + env(safe-area-inset-bottom, 0px));
        background: var(--bg);
    }
    html body.page-admin-workplace .wp-mobile-nav button {
        min-height: 44px;
        cursor: pointer;
        border: 1px solid var(--border);
        border-radius: 10px;
        background: var(--bg-card);
        color: var(--text);
        font-family: var(--font-body);
        font-size: 13px;
        font-weight: 600;
    }
    html body.page-admin-workplace .wp-mobile-nav button.is-active {
        background: var(--accent);
        color: var(--accent-on);
        border-color: var(--accent);
    }
    html body.page-admin-workplace .wp-mobile-nav button:focus-visible {
        outline: none;
        box-shadow: var(--focus-ring);
    }
    html body.page-admin-workplace #wp-cart-count {
        display: inline-flex;
        min-width: 18px;
        height: 18px;
        margin-left: 4px;
        padding: 0 5px;
        border-radius: 999px;
        background: #18181b;
        color: #facc15;
        font-size: 11px;
        align-items: center;
        justify-content: center;
    }
    html body.page-admin-workplace #wp-cart-count[hidden] {
        display: none !important;
    }

    html body.page-admin-workplace.wp-tab-pcs .workplace-right,
    html body.page-admin-workplace.wp-tab-products .workplace-left,
    html body.page-admin-workplace.wp-tab-cart .workplace-left {
        display: none !important;
    }
    html body.page-admin-workplace.wp-tab-products #cart-section,
    html body.page-admin-workplace.wp-tab-cart #products-section {
        display: none !important;
    }
    html body.page-admin-workplace .workplace-left,
    html body.page-admin-workplace .workplace-right {
        flex: 1 1 0;
        min-height: 0;
        width: 100%;
        max-height: none;
    }
    html body.page-admin-workplace .workplace-section,
    html body.page-admin-workplace #products-section,
    html body.page-admin-workplace #cart-section {
        flex: 1 1 0;
        min-height: 0;
        max-height: none;
    }
    html body.page-admin-workplace #pcs-container,
    html body.page-admin-workplace #products-container,
    html body.page-admin-workplace #cart-container {
        max-height: none;
        flex: 1 1 0;
    }
    html body.page-admin-workplace .workplace-toolbar-actions .btn {
        min-height: 44px;
    }
}

@media (prefers-reduced-motion: reduce) {
    html body.page-admin-workplace * {
        scroll-behavior: auto;
    }
}

html body .visually-hidden {
    position: absolute !important;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}

/* Плавающие подписи ломали сетку карточек — обычные подписи сверху */
html body .doc-form .doc-header .doc-header-field {
    position: relative;
    overflow: visible;
    min-width: 0;
}
html body .doc-form .doc-header .doc-header-field > label:not(:has(input)),
html body .doc-form .doc-header .doc-header-field > div:not(.doc-field-hint) > label:not(:has(input)),
html body .doc-form .doc-header .doc-header-field.doc-header-field-readonly > label:not(:has(input)),
html body .doc-form .doc-header .doc-header-field:has(> input:focus) > label:not(:has(input)):first-of-type,
html body .doc-form .doc-header .doc-header-field:has(> textarea:focus) > label:not(:has(input)):first-of-type,
html body .doc-form .doc-header .doc-header-field:has(> select:focus) > label:not(:has(input)):first-of-type,
html body .doc-form .doc-header .doc-header-field:has(> input:placeholder-shown) > label:not(:has(input)):first-of-type,
html body .doc-form .doc-header .doc-header-field:has(> input:not(:placeholder-shown)) > label:not(:has(input)):first-of-type,
html body .doc-form .doc-header .doc-header-field:has(> textarea:placeholder-shown) > label:not(:has(input)):first-of-type,
html body .doc-form .doc-header .doc-header-field:has(> textarea:not(:placeholder-shown)) > label:not(:has(input)):first-of-type,
html body .doc-form .doc-header .doc-header-field > label:not(:has(input)):has(+ select) {
    position: static !important;
    top: auto !important;
    left: auto !important;
    transform: none !important;
    max-width: none !important;
    overflow: visible !important;
    text-overflow: unset !important;
    white-space: normal !important;
    pointer-events: auto !important;
    display: block !important;
    margin: 0 0 6px !important;
    font-size: 12px !important;
    font-weight: 600 !important;
    line-height: 1.35 !important;
    letter-spacing: 0.02em;
    text-transform: none;
    color: var(--text-muted) !important;
    z-index: auto;
}
html body .doc-form .doc-header .doc-header-field-check > label,
html body .doc-form .doc-header .doc-header-field > label:has(> input[type="checkbox"]) {
    display: flex !important;
    align-items: flex-start !important;
    gap: 10px !important;
    font-size: 14px !important;
    font-weight: 500 !important;
    color: var(--text) !important;
    text-transform: none !important;
    cursor: pointer;
}
html body .doc-form .doc-header .doc-header-field > input:not([type="hidden"]):not([type="checkbox"]):not([type="radio"]),
html body .doc-form .doc-header .doc-header-field > textarea,
html body .doc-form .doc-header .doc-header-field > select,
html body .doc-form .doc-header .doc-header-field > div:not(.doc-field-hint) > input,
html body .doc-form .doc-header .doc-header-field-readonly .doc-field-locked {
    width: 100% !important;
    max-width: 100% !important;
    box-sizing: border-box !important;
    padding: 8px 12px !important;
    margin-top: 0 !important;
    min-height: 40px;
    font-size: 14px !important;
    line-height: 1.45 !important;
    color: var(--text) !important;
    background: var(--bg-elevated) !important;
    border: 1px solid var(--border) !important;
    border-radius: 8px !important;
    box-shadow: none !important;
}
html body .doc-form .doc-header .doc-header-field > input:not([type="hidden"]):not([type="checkbox"]):not([type="radio"]):hover:not(:disabled),
html body .doc-form .doc-header .doc-header-field > textarea:hover:not(:disabled),
html body .doc-form .doc-header .doc-header-field > select:hover:not(:disabled),
html body .doc-form .doc-header .doc-header-field > div:not(.doc-field-hint) > input:hover:not(:disabled),
html body .doc-form .doc-header .doc-header-field > div:not(.doc-field-hint) > textarea:hover:not(:disabled),
html body .doc-form .doc-header .doc-header-field > div:not(.doc-field-hint) > select:hover:not(:disabled) {
    border-color: var(--accent) !important;
    border-bottom-width: 1px !important;
    outline: none !important;
    box-shadow: inset 0 0 0 1px var(--accent) !important;
}
html body .doc-form .doc-header .doc-header-field > input:focus,
html body .doc-form .doc-header .doc-header-field > textarea:focus,
html body .doc-form .doc-header .doc-header-field > select:focus,
html body .doc-form .doc-header .doc-header-field > div:not(.doc-field-hint) > input:focus,
html body .doc-form .doc-header .doc-header-field > div:not(.doc-field-hint) > textarea:focus,
html body .doc-form .doc-header .doc-header-field > div:not(.doc-field-hint) > select:focus {
    border-color: var(--accent) !important;
    border-bottom-width: 1px !important;
    outline: none !important;
    box-shadow: inset 0 0 0 2px var(--accent) !important;
}
html body .doc-form .doc-header .doc-header-field > div:not(.doc-field-hint) {
    position: static;
    display: block;
    min-width: 0;
}
html body .doc-form .doc-media-field {
    display: grid !important;
    grid-template-columns: minmax(0, 1fr) 160px;
    gap: 16px;
    align-items: start;
}
html body .doc-form .doc-media-url,
html body .doc-form .doc-media-preview {
    min-width: 0;
    position: static;
}
html body .doc-form .doc-header-tile.doc-tile-media .doc-media-field,
html body .doc-form .doc-header-tile.doc-tile-media > .doc-header-field {
    grid-column: 1 / -1;
}
html body .doc-form .doc-media-preview-label {
    display: block;
    margin-bottom: 6px;
    font-size: 12px;
    font-weight: 600;
    color: var(--text-muted);
}
html body .doc-form .doc-image-preview {
    width: 160px;
    height: 160px;
    border: 1px solid var(--border);
    border-radius: 8px;
    background: var(--bg-elevated);
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
}
html body .doc-form .doc-image-preview img {
    max-width: 100%;
    max-height: 100%;
    object-fit: contain;
}
html body .doc-form .doc-image-empty {
    color: var(--text-muted);
    font-size: 13px;
    padding: 8px;
    text-align: center;
}
html body .doc-form .doc-hint-link {
    color: var(--accent);
}
html body .doc-form .doc-header-field-check {
    min-height: 40px;
}
@media (max-width: 767px) {
    html body .doc-form .doc-media-field {
        grid-template-columns: 1fr;
    }
    html body .doc-form .doc-image-preview {
        width: 100%;
        max-width: 200px;
    }
}

html body .doc-period-btn-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    min-width: 40px;
    min-height: 40px;
    padding: 8px;
    cursor: pointer;
    color: var(--text);
    background: var(--bg-elevated);
    border: 1px solid var(--border);
    border-radius: 8px;
}
html body .doc-period-btn-icon .nav-svg,
html body .doc-period-btn-icon .ui-icon-calendar {
    width: 20px;
    height: 20px;
    display: block;
    flex-shrink: 0;
}
html body .doc-period-btn-icon .doc-period-btn-text {
    font-size: 13px;
    font-weight: 600;
}
html body .doc-period-btn-icon:hover {
    border-color: var(--accent);
    color: var(--accent);
}

html body.page-admin-workplace .workplace-container .search-box input[type="text"],
html body.page-admin-workplace .workplace-container .search-box input[type="search"] {
    border: 1px solid var(--border) !important;
    border-radius: 8px !important;
    background: var(--bg-elevated) !important;
    color: var(--text) !important;
    box-shadow: none !important;
    padding: 8px 12px !important;
}
html body.page-admin-workplace .workplace-container .search-box input:focus {
    border-color: var(--accent) !important;
    border-bottom-width: 1px !important;
    box-shadow: var(--focus-ring) !important;
}
html body.page-admin-workplace .pc-free,
html body.page-admin-workplace .pc-busy,
html body.page-admin-workplace .pc-table tr.pc-free,
html body.page-admin-workplace .pc-table tr.pc-busy {
    color: var(--text);
    font-weight: 400;
}
html body.page-admin-workplace .pc-table tr:hover,
html body.page-admin-workplace .products-table tr:hover,
html body.page-admin-workplace .cart-table tr:hover,
html body.page-admin-workplace .wp-data-row.is-menu-open {
    background: var(--accent-dim);
}
html body.page-admin-workplace .wp-data-row {
    cursor: pointer;
}
html body.page-admin-workplace .wp-status-col,
html body.page-admin-workplace .wp-status-cell {
    width: 28px;
    min-width: 28px;
    text-align: center;
    padding-left: 8px !important;
    padding-right: 4px !important;
}
html body.page-admin-workplace .wp-status-dot {
    display: inline-block;
    width: 10px;
    height: 10px;
    border-radius: 50%;
    vertical-align: middle;
    box-shadow: 0 0 0 2px var(--bg-card);
}
html body.page-admin-workplace .wp-status-dot.is-free { background: var(--ok); }
html body.page-admin-workplace .wp-status-dot.is-booked {
    background: var(--accent);
    box-shadow: 0 0 0 2px var(--bg-card);
}
html body.page-admin-workplace .wp-status-dot.is-busy { background: var(--danger); }
html body.page-admin-workplace .cart-summary {
    background: var(--bg-elevated);
    color: var(--text);
}
html body.page-admin-workplace .cart-summary-total {
    color: var(--text) !important;
    border-top-color: var(--border);
}
html body.page-admin-workplace .cart-shell-badge {
    background: var(--bg-elevated);
    color: var(--text-muted);
    border: 1px solid var(--border);
}
html body.page-admin-workplace .cart-pc-cell {
    color: var(--text-muted);
}
html body.page-admin-workplace .btn-warning {
    background: var(--warn-bg);
    color: var(--accent-on);
    border: 1px solid var(--accent);
}
html body .wp-row-menu {
    position: fixed;
    z-index: 100000;
    min-width: 220px;
    padding: 6px;
    background: var(--bg-card);
    color: var(--text);
    border: 1px solid var(--border);
    border-radius: 10px;
    box-shadow: var(--shadow-md);
}
html body .wp-row-menu-item {
    display: block;
    width: 100%;
    text-align: left;
    min-height: 40px;
    padding: 8px 12px;
    border: 0;
    background: transparent;
    color: var(--text);
    cursor: pointer;
    border-radius: 8px;
    font-family: var(--font-body);
    font-size: 14px;
}
html body .wp-row-menu-item:hover,
html body .wp-row-menu-item:focus-visible {
    background: var(--accent-dim);
    outline: none;
}
html body .wp-row-menu-item.is-disabled {
    cursor: default;
    color: var(--text-muted);
    min-height: auto;
    font-size: 12px;
}

/* Модалки: те же токены, SVG, поля-коробки */
html body .modal.active {
    background: rgba(24, 24, 27, 0.55) !important;
}
html body .modal-content,
html body .doc-period-modal .modal-box {
    padding: 24px !important;
    min-width: min(100%, 420px);
    max-width: min(560px, calc(100vw - 32px));
    color: var(--text) !important;
}
html body .modal-header {
    margin-bottom: 16px;
    padding: 0 0 14px;
    min-height: 0;
    border-bottom: 1px solid var(--border);
}
html body .modal-header h3,
html body .doc-period-modal .modal-box > h3 {
    display: flex;
    align-items: center;
    gap: 10px;
    font-family: var(--font-display);
    font-size: 1.15rem !important;
    font-weight: 500 !important;
    color: var(--text) !important;
    line-height: 1.3 !important;
}
html body .modal-header h3 .nav-svg,
html body .doc-period-modal .modal-box > h3 .nav-svg {
    width: 22px;
    height: 22px;
    flex-shrink: 0;
    color: var(--accent);
}
html body .modal-close {
    width: 40px !important;
    height: 40px !important;
    min-width: 40px;
    background: var(--bg-elevated) !important;
    border: 1px solid var(--border) !important;
    color: var(--text) !important;
    border-radius: 8px !important;
    box-shadow: none !important;
    cursor: pointer;
}
html body .modal-close .nav-svg {
    width: 18px;
    height: 18px;
}
html body .modal-close:hover {
    border-color: var(--accent) !important;
    color: var(--accent) !important;
}
html body .modal-close:focus-visible {
    outline: none;
    box-shadow: var(--focus-ring) !important;
}
html body .modal-form-group,
html body .doc-period-modal .step {
    position: relative;
    margin-bottom: 14px;
    padding-top: 0 !important;
}
html body .modal-form-group > label:not(:has(input)),
html body .doc-period-modal .step > label:not(:has(input)),
html body .modal-form-group:has(> input:focus) > label:not(:has(input)):first-of-type,
html body .modal-form-group:has(> select:focus) > label:not(:has(input)):first-of-type,
html body .modal-form-group:has(.payment-type-group) > label:not(:has(input)):first-of-type,
html body .modal-form-group > label:not(:has(input)):has(+ select) {
    position: static !important;
    top: auto !important;
    pointer-events: auto !important;
    display: block !important;
    margin: 0 0 6px !important;
    font-size: 12px !important;
    font-weight: 600 !important;
    color: var(--text-muted) !important;
}
html body .modal-form-group > input:not([type="hidden"]):not([type="checkbox"]):not([type="radio"]),
html body .modal-form-group > textarea,
html body .modal-form-group > select,
html body .doc-period-modal .step > input,
html body .modal-content textarea {
    padding: 8px 12px !important;
    min-height: 40px;
    color: var(--text) !important;
    background: var(--bg-elevated) !important;
    border: 1px solid var(--border) !important;
    border-radius: 8px !important;
    border-bottom-width: 1px !important;
}
html body .modal-form-group > input:hover:not(:disabled),
html body .modal-form-group > textarea:hover:not(:disabled),
html body .modal-form-group > select:hover:not(:disabled),
html body .doc-period-modal .step > input:hover:not(:disabled) {
    border-color: var(--accent) !important;
    box-shadow: inset 0 0 0 1px var(--accent) !important;
}
html body .modal-form-group > input:focus,
html body .modal-form-group > textarea:focus,
html body .modal-form-group > select:focus,
html body .doc-period-modal .step > input:focus {
    border-color: var(--accent) !important;
    border-bottom-width: 1px !important;
    box-shadow: inset 0 0 0 2px var(--accent) !important;
}
html body .modal-form-group small,
html body .modal-form-group .doc-field-hint {
    color: var(--text-muted) !important;
}
html body .payment-type-group {
    gap: 8px;
}
html body .payment-type-radio,
html body .modal-content .payment-type-radio {
    background: var(--bg-elevated) !important;
    border: 1px solid var(--border) !important;
    color: var(--text) !important;
    min-height: 44px !important;
    height: auto !important;
    max-height: none !important;
    padding: 10px 12px !important;
    cursor: pointer;
}
html body .payment-type-radio > div {
    gap: 8px;
    color: inherit !important;
}
html body .payment-type-radio .nav-svg {
    width: 18px;
    height: 18px;
}
html body .payment-type-radio.selected,
html body .modal-content .payment-type-radio.selected {
    background: var(--accent) !important;
    border-color: var(--accent) !important;
    color: var(--accent-on) !important;
}
html body .payment-type-radio.selected > div,
html body .modal-content .payment-type-radio.selected > div {
    color: var(--accent-on) !important;
}
html body .payment-type-radio:hover:not(.selected) {
    border-color: var(--accent) !important;
    background: var(--accent-dim) !important;
}
html body .modal-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    justify-content: flex-end;
    margin-top: 8px;
}
html body .modal-actions .btn-modal-primary,
html body .modal-actions button[type="submit"],
html body .doc-period-modal .modal-actions .btn-primary {
    background: var(--accent) !important;
    color: var(--accent-on) !important;
    min-height: 44px;
    padding: 10px 16px;
    border: 0;
    border-radius: var(--btn-radius);
    cursor: pointer;
    font-weight: 700;
}
html body .modal-actions .btn-modal-secondary,
html body .modal-actions .btn-secondary {
    background: var(--bg-elevated) !important;
    color: var(--text) !important;
    border: 1px solid var(--border) !important;
    min-height: 44px;
    padding: 10px 16px;
    border-radius: var(--btn-radius);
    cursor: pointer;
}
html body .modal-actions .btn-modal-primary:focus-visible,
html body .modal-actions .btn-modal-secondary:focus-visible,
html body .payment-type-radio:focus-within {
    outline: none;
    box-shadow: var(--focus-ring);
}

html body .modal-notify-overlay,
html body .modal-notify-overlay[data-theme="light"],
html body .modal-notify-overlay[data-theme="dark"] {
    background: rgba(24, 24, 27, 0.55) !important;
}
html body .modal-notify-box {
    background: var(--bg-card) !important;
    color: var(--text) !important;
    border: 1px solid var(--border) !important;
    border-radius: var(--card-radius) !important;
}
html body .modal-notify-box.modal-notify-error { border-left-color: var(--danger) !important; }
html body .modal-notify-box.modal-notify-warning { border-left-color: var(--accent) !important; }
html body .modal-notify-box.modal-notify-success { border-left-color: var(--ok) !important; }
html body .modal-notify-box.modal-notify-info { border-left-color: var(--info) !important; }
html body .modal-notify-icon {
    font-size: 0 !important;
    color: var(--accent);
}
html body .modal-notify-icon .nav-svg {
    width: 36px;
    height: 36px;
    margin: 0 auto;
    display: block;
}
html body .modal-notify-error .modal-notify-icon { color: var(--danger); }
html body .modal-notify-success .modal-notify-icon { color: var(--ok); }
html body .modal-notify-info .modal-notify-icon { color: var(--info); }
html body .modal-notify-message {
    color: var(--text) !important;
    font-family: var(--font-body);
}
html body .modal-notify-btn-primary {
    background: var(--accent) !important;
    color: var(--accent-on) !important;
}
html body .modal-notify-btn-primary:hover {
    filter: brightness(1.05);
}
html body .modal-notify-btn-secondary {
    background: var(--bg-elevated) !important;
    color: var(--text) !important;
}
html body .modal-notify-btn-danger {
    background: var(--danger) !important;
    color: #fff !important;
}
html body .modal-notify-btn:focus-visible {
    outline: none;
    box-shadow: var(--focus-ring) !important;
}

@media (max-width: 767px) {
    html body .modal-content,
    html body .doc-period-modal .modal-box {
        min-width: 0;
        width: calc(100vw - 24px);
        padding: 16px !important;
        margin: 12px auto;
    }
    html body .payment-type-group {
        flex-direction: column;
    }
    html body .modal-actions .btn-modal-primary,
    html body .modal-actions .btn-modal-secondary {
        flex: 1 1 100%;
    }
}

/* Выбор смены: 15 записей + прокрутка + поиск */
html body .shift-picker {
    position: relative;
    width: 100%;
}
html body .shift-picker-toggle {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
    width: 100%;
    min-height: 40px;
    padding: 8px 12px;
    text-align: left;
    font: inherit;
    font-size: 14px;
    color: var(--text);
    background: var(--bg-elevated);
    border: 1px solid var(--border);
    border-radius: 8px;
    cursor: pointer;
}
html body .shift-picker-toggle-text {
    min-width: 0;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}
html body .shift-picker-chevron {
    width: 18px;
    height: 18px;
    flex-shrink: 0;
    color: var(--text-muted);
}
html body .shift-picker.is-open .shift-picker-chevron {
    transform: rotate(180deg);
}
html body .shift-picker-toggle:hover,
html body .shift-picker-q:hover {
    border-color: var(--accent);
    box-shadow: inset 0 0 0 1px var(--accent);
}
html body .shift-picker-toggle:focus-visible,
html body .shift-picker.is-open .shift-picker-toggle,
html body .shift-picker-q:focus {
    border-color: var(--accent);
    outline: none;
    box-shadow: inset 0 0 0 2px var(--accent);
}
html body .shift-picker-panel {
    display: none !important;
    position: absolute;
    left: 0;
    right: 0;
    top: calc(100% + 4px);
    z-index: 80;
    flex-direction: column;
    max-height: 280px;
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: 8px;
    box-shadow: var(--shadow-md);
}
html body .shift-picker.is-open .shift-picker-panel {
    display: flex !important;
}
html body .shift-picker-q {
    width: 100%;
    min-height: 40px;
    margin: 8px 8px 0;
    padding: 8px 12px;
    box-sizing: border-box;
    font: inherit;
    font-size: 14px;
    color: var(--text);
    background: var(--bg-elevated);
    border: 1px solid var(--border);
    border-radius: 8px;
}
html body .shift-picker-list {
    overflow-y: auto;
    max-height: 220px;
    padding: 6px;
    -webkit-overflow-scrolling: touch;
}
html body .shift-picker-item {
    display: block;
    width: 100%;
    padding: 10px 12px;
    min-height: 44px;
    text-align: left;
    font: inherit;
    font-size: 13px;
    line-height: 1.35;
    color: var(--text);
    background: transparent;
    border: 0;
    border-radius: 6px;
    cursor: pointer;
}
html body .shift-picker-item:hover,
html body .shift-picker-item:focus-visible {
    background: var(--accent-dim);
    outline: none;
}
html body .shift-picker-item.is-selected {
    background: var(--accent-dim);
    box-shadow: inset 3px 0 0 var(--accent);
}
html body .shift-picker-empty {
    padding: 12px;
    font-size: 13px;
    color: var(--text-muted);
}
html body .manager-op-card .doc-header-field input:hover:not(:disabled),
html body .manager-op-card .doc-header-field select:hover:not(:disabled),
html body .manager-op-card .doc-header-field textarea:hover:not(:disabled) {
    border-color: var(--accent) !important;
    box-shadow: inset 0 0 0 1px var(--accent);
}
html body .manager-op-card .doc-header-field input:focus,
html body .manager-op-card .doc-header-field select:focus,
html body .manager-op-card .doc-header-field textarea:focus {
    border-color: var(--accent) !important;
    outline: none;
    box-shadow: inset 0 0 0 2px var(--accent);
}
@media (prefers-reduced-motion: reduce) {
    html body .shift-picker-chevron { transform: none; }
}

html body .doc-stock-hint::before,
html body .doc-stock-hint::after {
    content: none !important;
    display: none !important;
}
html body .ui-float-tooltip {
    position: fixed;
    z-index: 10050;
    max-width: min(360px, calc(100vw - 16px));
    padding: 10px 12px;
    font-family: var(--font-body);
    font-size: 13px;
    line-height: 1.45;
    color: var(--text);
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: 8px;
    box-shadow: var(--shadow-md);
    pointer-events: none;
    white-space: normal;
    overflow-wrap: anywhere;
}
html body .ui-float-tooltip[hidden] {
    display: none !important;
}

html body .doc-form form.doc-admin-form {
    max-width: none;
    overflow: hidden;
}
html body .doc-form form.doc-admin-form .doc-admin-layout {
    display: grid;
    grid-template-columns: minmax(0, 1fr);
    gap: 12px;
    align-items: start;
    width: 100%;
    max-width: none;
    padding: 8px;
    box-sizing: border-box;
    flex: 1 1 0;
    min-height: 0;
    overflow: hidden;
}
html body .doc-form form.doc-admin-form .doc-admin-layout:has(.doc-admin-perms) {
    grid-template-columns: minmax(0, 1fr) minmax(300px, 420px);
}
html body .doc-form form.doc-admin-form .doc-header-grid {
    max-width: none;
    width: 100%;
    margin: 0;
    padding: 0;
    overflow-x: hidden;
    overflow-y: auto;
    max-height: 100%;
}
html body .doc-form form.doc-admin-form .doc-admin-perms {
    position: sticky;
    top: 12px;
    min-width: 0;
    max-height: calc(100dvh - 120px);
    display: flex;
    flex-direction: column;
}
html body .doc-form form.doc-admin-form .doc-admin-perms > .doc-header {
    flex: 1 1 auto;
    min-height: 0;
    max-height: calc(100dvh - 120px);
    overflow: hidden;
}
html body .doc-form form.doc-admin-form .doc-admin-perms .doc-header-field-full {
    flex: 1 1 auto;
    min-height: 0;
    display: flex;
    flex-direction: column;
}
html body .doc-form form.doc-admin-form .doc-admin-perms .doc-permissions-fieldset {
    flex: 1 1 auto;
    min-height: 0;
    display: flex;
    flex-direction: column;
    overflow: hidden;
}
html body .doc-form form.doc-admin-form .doc-admin-perms .doc-permissions-by-section {
    flex: 1 1 auto;
    min-height: 0;
    overflow-y: auto;
    max-height: calc(100dvh - 280px);
    padding-right: 4px;
    -webkit-overflow-scrolling: touch;
}
html body .doc-form form.doc-admin-form .doc-admin-perms .doc-permissions-grid {
    grid-template-columns: 1fr;
}
@media (max-width: 1100px) {
    html body .doc-form form.doc-admin-form .doc-admin-layout {
        grid-template-columns: 1fr;
    }
    html body .doc-form form.doc-admin-form .doc-admin-perms {
        position: static;
        max-height: none;
    }
    html body .doc-form form.doc-admin-form .doc-admin-perms > .doc-header {
        max-height: none;
        overflow: hidden;
    }
    html body .doc-form form.doc-admin-form .doc-admin-perms .doc-permissions-by-section {
        max-height: min(60vh, 520px);
    }
}
