/* [СВО] 2026-07-07 — Упрощённый кабинет: формы и карточки */
.cabinet-quick-actions {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 14px;
    margin-top: 20px;
}
.cabinet-quick-action {
    border: 1px solid var(--border);
    border-radius: 14px;
    background: var(--surface);
    padding: 18px 16px;
    text-align: left;
    cursor: pointer;
    transition: border-color 0.2s, box-shadow 0.2s;
    box-shadow: var(--shadow-sm);
}
.cabinet-quick-action:hover {
    border-color: var(--accent);
    box-shadow: var(--shadow-md);
}
.cabinet-quick-action__icon {
    width: 42px;
    height: 42px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 18px;
    margin-bottom: 12px;
}
.cabinet-quick-action__title {
    font-size: 15px;
    font-weight: 700;
    color: var(--primary);
    margin-bottom: 6px;
}
.cabinet-quick-action__desc {
    font-size: 12px;
    color: var(--text-muted);
    line-height: 1.45;
}
.cabinet-form {
    display: grid;
    gap: 14px;
}
.cabinet-form__row {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 14px;
}
.cabinet-field {
    display: flex;
    flex-direction: column;
    gap: 6px;
}
.cabinet-field label {
    font-size: 13px;
    font-weight: 600;
    color: var(--text-secondary);
}
.cabinet-field input,
.cabinet-field select,
.cabinet-field textarea {
    min-height: 44px;
    padding: 10px 12px;
    border: 1px solid var(--border);
    border-radius: 10px;
    font-size: 15px;
    font-family: inherit;
    background: #fff;
}
.cabinet-field textarea {
    min-height: 110px;
    resize: vertical;
}
.cabinet-field--full { grid-column: 1 / -1; }
.cabinet-form__submit {
    margin-top: 4px;
}
.cabinet-status-card {
    padding: 20px;
    border-radius: 14px;
    border: 1px solid var(--border);
    background: linear-gradient(135deg, #f8fafc, #fff);
}
.cabinet-status-card__title {
    font-size: 16px;
    font-weight: 700;
    color: var(--primary);
    margin-bottom: 8px;
}
.cabinet-status-card__text {
    font-size: 14px;
    color: var(--text-secondary);
    line-height: 1.5;
    margin-bottom: 14px;
}
.cabinet-empty {
    color: var(--text-muted);
    font-size: 14px;
    margin: 0;
}
.cabinet-stat--click {
    border: 1px solid var(--border);
    border-radius: var(--radius);
    background: var(--surface);
    box-shadow: var(--shadow-sm);
    cursor: pointer;
    text-align: left;
    width: 100%;
    font-family: inherit;
    transition: border-color 0.2s, box-shadow 0.2s;
}
.cabinet-stat--click:hover {
    border-color: var(--accent);
    box-shadow: var(--shadow-md);
}
.cabinet-profile-banner {
    padding: 20px;
    margin-bottom: 20px;
    border-radius: 14px;
    background: #fff8e6;
    border: 1px solid #f0d78c;
}
.cabinet-profile-banner p {
    margin: 0 0 14px;
    font-size: 14px;
    color: #7c5e10;
    line-height: 1.5;
}
.cabinet-agree {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    font-size: 13px;
    color: var(--text-secondary);
    cursor: pointer;
}
.cabinet-agree input { margin-top: 3px; }
.cabinet-app-item:active { opacity: 0.92; }
.cabinet-app-detail p { margin: 0 0 10px; font-size: 14px; line-height: 1.5; }

/* Шапка кабинета: На сайт / Выход */
.cabinet-header-actions {
    display: flex;
    align-items: center;
    gap: 8px;
}
.cabinet-action-btn {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    min-height: 36px;
    padding: 0 12px;
    border-radius: 10px;
    border: 1px solid var(--border);
    background: var(--surface);
    color: var(--text-secondary);
    font-size: 13px;
    font-weight: 600;
    font-family: inherit;
    cursor: pointer;
    transition: background 0.2s, border-color 0.2s, color 0.2s;
}
.cabinet-action-btn i { font-size: 14px; }
.cabinet-action-btn--site:hover {
    border-color: var(--blue);
    color: var(--blue);
    background: var(--blue-bg);
}
.cabinet-action-btn--logout {
    border-color: #fecaca;
    color: #b91c1c;
    background: #fef2f2;
}
.cabinet-action-btn--logout:hover {
    background: #fee2e2;
    border-color: #f87171;
}
.cabinet-header-avatar { flex-shrink: 0; }

.cabinet-menu-user {
    padding: 4px 4px 14px;
    margin-bottom: 8px;
    border-bottom: 1px solid var(--border-light);
}
.cabinet-menu-user strong {
    display: block;
    font-size: 16px;
    color: var(--primary);
}
.cabinet-menu-user span {
    font-size: 12px;
    color: var(--text-muted);
}
.cabinet-menu-actions {
    display: flex;
    flex-direction: column;
    gap: 10px;
}
.cabinet-menu-action {
    display: flex;
    align-items: flex-start;
    gap: 12px;
    width: 100%;
    padding: 14px;
    border-radius: 14px;
    border: 1px solid var(--border);
    background: var(--surface-hover);
    text-align: left;
    font-family: inherit;
    cursor: pointer;
}
.cabinet-menu-action i {
    font-size: 18px;
    margin-top: 2px;
}
.cabinet-menu-action span {
    display: flex;
    flex-direction: column;
    gap: 4px;
}
.cabinet-menu-action strong {
    font-size: 14px;
    color: var(--primary);
}
.cabinet-menu-action small {
    font-size: 12px;
    color: var(--text-muted);
    line-height: 1.35;
}
.cabinet-menu-action--site {
    border-color: #bfdbfe;
    background: #eff6ff;
}
.cabinet-menu-action--site i { color: #2563eb; }
.cabinet-menu-action--logout {
    border-color: #fecaca;
    background: #fef2f2;
}
.cabinet-menu-action--logout i { color: #dc2626; }
.cabinet-menu-action--logout strong { color: #b91c1c; }

@media (max-width: 1024px) {
    #dashboard-app .header-btn { display: none; }
    .cabinet-action-btn span { display: inline; }
    .cabinet-header-avatar { display: none; }
    #dashboard-app .header {
        padding-right: 10px;
    }
    .cabinet-header-actions {
        gap: 6px;
    }
    .cabinet-action-btn {
        padding: 0 10px;
        font-size: 12px;
    }
}

@media (max-width: 380px) {
    .cabinet-action-btn span { display: none; }
    .cabinet-action-btn {
        width: 38px;
        padding: 0;
        justify-content: center;
    }
}
.nav-item--site {
    color: #bfdbfe !important;
    border: 1px solid rgba(191, 219, 254, 0.25);
}
.nav-item--site:hover {
    background: rgba(59, 130, 246, 0.15) !important;
    color: #fff !important;
}
.nav-item--logout {
    color: #fca5a5 !important;
    margin-top: 8px;
    border: 1px solid rgba(252, 165, 165, 0.35);
}
.nav-item--logout:hover {
    background: rgba(239, 68, 68, 0.15) !important;
    color: #fff !important;
}
.mobile-menu__logout .mobile-menu__item {
    color: var(--red);
    font-weight: 700;
}

/* [СВО] 2026-07-07 — Прокрутка кабинета на мобильных */
@media (max-width: 1024px) {
    body.cabinet-mode {
        overflow: hidden;
        height: 100dvh;
        width: 100%;
        position: relative;
    }

    body.cabinet-mode #dashboard-app {
        height: 100dvh;
        min-height: 100dvh;
        overflow: hidden;
        display: flex;
        flex-direction: column;
    }

    body.cabinet-mode #dashboard-app .app {
        flex: 1;
        min-height: 0;
        display: flex;
        flex-direction: column;
        overflow: hidden;
        width: 100%;
    }

    body.cabinet-mode #dashboard-app .main {
        flex: 1;
        min-height: 0;
        margin-left: 0;
        display: flex;
        flex-direction: column;
        overflow: hidden;
        width: 100%;
    }

    body.cabinet-mode #dashboard-app .header {
        flex-shrink: 0;
    }

    body.cabinet-mode #dashboard-app .content {
        flex: 1;
        min-height: 0;
        overflow-x: hidden;
        overflow-y: auto;
        -webkit-overflow-scrolling: touch;
        overscroll-behavior-y: contain;
        touch-action: pan-y;
        padding-bottom: var(--page-bottom);
    }

    body.cabinet-mode #dashboard-app .page-section,
    body.cabinet-mode #dashboard-app .page-section.active {
        overflow: visible;
        min-height: min-content;
    }

    body.cabinet-mode #dashboard-app .grid-2 {
        grid-template-columns: 1fr;
    }

    body.cabinet-menu-open #dashboard-app .content {
        overflow: hidden;
    }
}

@media (max-width: 900px) {
    .cabinet-quick-actions { grid-template-columns: 1fr; }
    .cabinet-form__row { grid-template-columns: 1fr; }
}
