/* ===== Yoga CRM — общие стили приложения ===== */

:root {
    --bg: #f5f6fa;
    --surface: #ffffff;
    --surface-alt: #f9f9f9;
    --text: #212529;
    --text-muted: #6c757d;
    --border: #e0e0e0;
    --primary: #667eea;
    --primary-2: #764ba2;
    --accent: #4ECDC4;
    --danger: #dc3545;
    --success: #28a745;
    --shadow: rgba(0, 0, 0, 0.1);
    --radius: 12px;
}

[data-theme="yoga"] {
    --bg: #faf6f0;
    --surface: #ffffff;
    --surface-alt: #f6efe5;
    --text: #3e3428;
    --text-muted: #8a7a68;
    --border: #e6dccc;
    --primary: #b36b4b;
    --primary-2: #8d5a4a;
    --accent: #d9a05b;
    --danger: #c0392b;
    --success: #2e7d32;
    --shadow: rgba(179, 107, 75, 0.15);
}

[data-theme="forest"] {
    --bg: #f0f4ef;
    --surface: #ffffff;
    --surface-alt: #e9f0e7;
    --text: #23342a;
    --text-muted: #6d8578;
    --border: #cfdecb;
    --primary: #2d6a4f;
    --primary-2: #1b4332;
    --accent: #52b788;
    --danger: #c0392b;
    --success: #2e7d32;
    --shadow: rgba(45, 106, 79, 0.15);
}

[data-theme="ocean"] {
    --bg: #eef4f8;
    --surface: #ffffff;
    --surface-alt: #e7f0f6;
    --text: #1f2d3d;
    --text-muted: #6a8298;
    --border: #c8dcea;
    --primary: #1272a6;
    --primary-2: #0b4f73;
    --accent: #38b2ac;
    --danger: #c0392b;
    --success: #2e7d32;
    --shadow: rgba(18, 114, 166, 0.15);
}

[data-theme="midnight"] {
    --bg: #1b2230;
    --surface: #242c3d;
    --surface-alt: #1e2534;
    --text: #e8ecf4;
    --text-muted: #98a4ba;
    --border: #37415a;
    --primary: #6c8cff;
    --primary-2: #8a6bff;
    --accent: #4ECDC4;
    --danger: #e06c75;
    --success: #98c379;
    --shadow: rgba(0, 0, 0, 0.4);
    --radius: 12px;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
    background: var(--bg);
    color: var(--text);
    min-height: 100vh;
    line-height: 1.5;
}

a {
    color: var(--primary);
    text-decoration: none;
}

/* ===== Каркас приложения ===== */
.app-shell {
    display: flex;
    flex-direction: column;
    min-height: 100vh;
}

.page-content {
    flex: 1;
    width: 100%;
    max-width: 1080px;
    margin: 0 auto;
    padding: 24px 16px 110px;
}

/* ===== Верхняя панель ===== */
.topbar {
    background: var(--surface);
    border-bottom: 1px solid var(--border);
    padding: 0 16px;
    position: sticky;
    top: 0;
    z-index: 100;
}

.topbar-inner {
    max-width: 1080px;
    margin: 0 auto;
    display: flex;
    align-items: center;
    justify-content: space-between;
    height: 56px;
}

.topbar-brand {
    font-weight: 700;
    font-size: 18px;
    color: var(--text);
}

.topbar-right {
    display: flex;
    align-items: center;
    gap: 16px;
}

.topbar-greeting {
    font-weight: 600;
    font-size: 15px;
    cursor: default;
}

.topbar-link {
    font-size: 14px;
    color: var(--text-muted);
}

.topbar-link:hover {
    color: var(--primary);
}

.notification-bell-wrap {
    position: relative;
}

.notification-bell {
    position: relative;
    background: none;
    border: none;
    cursor: pointer;
    color: var(--text-muted);
    font-size: 20px;
    display: flex;
    align-items: center;
    padding: 4px;
}

.notification-bell:hover {
    color: var(--primary);
}

.notification-badge {
    position: absolute;
    top: -2px;
    right: -4px;
    background: var(--danger);
    color: #fff;
    font-size: 10px;
    font-weight: 700;
    border-radius: 10px;
    padding: 1px 5px;
    min-width: 16px;
    text-align: center;
}

.notification-dropdown {
    display: none;
    position: absolute;
    right: 0;
    top: calc(100% + 8px);
    width: 320px;
    max-height: 400px;
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    box-shadow: 0 8px 24px var(--shadow);
    overflow: hidden;
    z-index: 200;
}

.notification-dropdown.show {
    display: block;
}

.nd-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 10px 14px;
    border-bottom: 1px solid var(--border);
    font-weight: 600;
    font-size: 14px;
}

.nd-mark-all {
    background: none;
    border: none;
    color: var(--primary);
    font-size: 12px;
    cursor: pointer;
}

.nd-body {
    max-height: 340px;
    overflow-y: auto;
}

.nd-item {
    display: block;
    padding: 12px 14px;
    border-bottom: 1px solid var(--border);
    font-size: 13px;
}

.nd-item.unread {
    background: var(--surface-alt);
    border-left: 3px solid var(--primary);
}

.nd-item strong {
    display: block;
    margin-bottom: 4px;
}

.nd-text {
    display: block;
    color: var(--text-muted);
    font-size: 12px;
    margin-bottom: 4px;
}

.nd-time {
    font-size: 11px;
    color: var(--text-muted);
}

.nd-empty {
    padding: 20px;
    text-align: center;
    color: var(--text-muted);
    font-size: 13px;
}

/* ===== Нижняя панель (мобильная навигация) ===== */
.bottom-nav {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    background: var(--surface);
    border-top: 1px solid var(--border);
    display: flex;
    justify-content: space-around;
    align-items: center;
    height: 60px;
    z-index: 150;
}

.bottom-nav-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 3px;
    font-size: 11px;
    color: var(--text-muted);
    flex: 1;
    padding: 6px 0;
}

.bottom-nav-item i {
    font-size: 20px;
}

.bottom-nav-item.active {
    color: var(--primary);
    font-weight: 600;
}

/* ===== Кнопки ===== */
.btn {
    display: inline-block;
    padding: 12px 22px;
    font-size: 15px;
    font-weight: 600;
    text-decoration: none;
    border: none;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.25s ease;
    text-align: center;
}

.btn-primary {
    background: linear-gradient(135deg, var(--primary) 0%, var(--primary-2) 100%);
    color: #fff;
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 5px 18px var(--shadow);
}

.btn-secondary {
    background: linear-gradient(135deg, var(--primary) 0%, var(--primary-2) 100%);
    color: #fff;
}

.btn-outline {
    background: transparent;
    color: var(--primary);
    border: 2px solid var(--primary);
}

.btn-outline:hover {
    background: var(--primary);
    color: #fff;
}

.btn-outline.danger,
.btn.danger {
    background: transparent;
    color: var(--danger);
    border: 2px solid var(--danger);
}

.btn-outline.danger:hover,
.btn.danger:hover {
    background: var(--danger);
    color: #fff;
}

.btn-small {
    padding: 8px 16px;
    font-size: 13px;
}

.btn:disabled {
    opacity: 0.6;
    cursor: not-allowed;
    transform: none !important;
}

/* ===== Карточки ===== */
.dashboard {
    display: flex;
    flex-direction: column;
    gap: 24px;
}

.greeting-card {
    background: linear-gradient(135deg, var(--primary) 0%, var(--primary-2) 100%);
    color: #fff;
    padding: 28px;
    border-radius: var(--radius);
    box-shadow: 0 5px 20px var(--shadow);
    position: relative;
}

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

.greeting-card .notification-bell {
    color: #fff;
}

.greeting-card .notification-bell:hover {
    color: rgba(255, 255, 255, 0.85);
}

.greeting-text {
    font-size: 28px;
    margin-bottom: 6px;
}

.greeting-sub {
    opacity: 0.9;
}

.page-heading h1 {
    font-size: 26px;
}

.balance-card {
    background: var(--surface);
    border-radius: var(--radius);
    padding: 22px;
    box-shadow: 0 2px 10px var(--shadow);
    display: flex;
    flex-direction: column;
    gap: 8px;
    align-items: flex-start;
}

.balance-label {
    font-size: 14px;
    color: var(--text-muted);
}

.balance-value {
    font-size: 30px;
    font-weight: 700;
}

.subs-summary {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    align-items: center;
}

.subs-remaining {
    font-weight: 600;
    color: var(--primary);
}

.subs-name {
    font-size: 14px;
    color: var(--text-muted);
    background: var(--surface-alt);
    padding: 3px 10px;
    border-radius: 20px;
}

.profile-section,
.subscriptions-section,
.sessions-section,
.stories-section,
.renew-section {
    background: var(--surface);
    border-radius: var(--radius);
    padding: 24px;
    box-shadow: 0 2px 10px var(--shadow);
}

.profile-section h2,
.subscriptions-section h2,
.sessions-section h2,
.stories-section h2,
.renew-section h2 {
    font-size: 20px;
    margin-bottom: 16px;
    border-bottom: 2px solid var(--border);
    padding-bottom: 10px;
}

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

.section-head h1 {
    font-size: 24px;
}

.section-head h2 {
    font-size: 20px;
    border-bottom: 2px solid var(--border);
    padding-bottom: 10px;
    margin: 0;
}

.section-description {
    color: var(--text-muted);
    margin-bottom: 16px;
}

/* ===== Тарифы ===== */
.subscriptions-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
    gap: 18px;
}

.subscription-card {
    background: var(--surface-alt);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 22px;
    text-align: center;
    transition: transform 0.2s, box-shadow 0.2s;
}

.subscription-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 4px 16px var(--shadow);
}

.subscription-card h3 {
    font-size: 18px;
    margin-bottom: 10px;
}

.subscription-details {
    color: var(--text-muted);
    font-size: 15px;
    margin: 8px 0;
}

.subscription-validity {
    color: var(--text-muted);
    font-size: 13px;
}

.subscription-price {
    font-size: 22px;
    font-weight: 700;
    color: var(--accent);
    margin: 14px 0;
}

.subscription-card--locked {
    opacity: 0.75;
}

.subscription-card--locked .subscription-price {
    color: var(--text-muted);
}

.purchase-subscription-btn,
.tariff-request-btn {
    width: 100%;
    margin-top: 6px;
}

/* ===== Сессии ===== */
.sessions-list {
    display: grid;
    gap: 14px;
}

.session-card {
    display: flex;
    gap: 18px;
    padding: 18px;
    background: var(--surface-alt);
    border-radius: 8px;
    border-left: 4px solid;
}

.session-card.past {
    opacity: 0.8;
}

.session-time {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    min-width: 90px;
    padding-right: 18px;
    border-right: 1px solid var(--border);
}

.session-time .date {
    font-size: 13px;
    color: var(--text-muted);
}

.session-time .time {
    font-size: 18px;
    font-weight: 600;
}

.session-details h3 {
    font-size: 17px;
    margin-bottom: 6px;
}

.hall-name,
.duration {
    color: var(--text-muted);
    font-size: 13px;
}

/* ===== Модалки ===== */
.modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 1000;
    padding: 20px;
}

.modal-card {
    background: var(--surface);
    border-radius: var(--radius);
    padding: 28px;
    max-width: 460px;
    width: 100%;
    position: relative;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.3);
    color: var(--text);
}

.modal-close {
    position: absolute;
    top: 14px;
    right: 18px;
    font-size: 26px;
    line-height: 1;
    cursor: pointer;
    background: none;
    border: none;
    color: var(--text-muted);
}

.modal-close:hover {
    color: var(--text);
}

.modal-title {
    font-size: 20px;
    margin-bottom: 18px;
}

.modal-actions {
    display: flex;
    gap: 12px;
    justify-content: flex-end;
    margin-top: 22px;
    flex-wrap: wrap;
}

.modal-actions .btn {
    min-width: 110px;
}

.form-label {
    display: block;
    margin-bottom: 6px;
    color: var(--text-muted);
    font-weight: 500;
    font-size: 14px;
}

.form-control {
    width: 100%;
    padding: 12px 14px;
    border: 2px solid var(--border);
    border-radius: 8px;
    font-size: 15px;
    background: var(--surface);
    color: var(--text);
}

.form-control:focus {
    outline: none;
    border-color: var(--primary);
}

.form-error,
.warning-message {
    color: var(--danger);
    font-size: 13px;
    margin-top: 8px;
}

.needed-amount {
    color: var(--danger);
    font-weight: 700;
    font-size: 16px;
    margin-top: 4px;
}

.notification-card {
    text-align: center;
    background: var(--surface);
    color: var(--text);
}

.notification-message {
    font-size: 16px;
    font-weight: 600;
}

.notification-card.error .notification-message {
    color: var(--danger);
}

/* ===== Сторис ===== */
.carousel {
    display: flex;
    gap: 14px;
    overflow-x: auto;
    padding-bottom: 8px;
}

.news-card {
    min-width: 200px;
    max-width: 220px;
    background: linear-gradient(135deg, var(--primary) 0%, var(--primary-2) 100%);
    color: #fff;
    border-radius: var(--radius);
    padding: 18px;
    cursor: pointer;
    transition: transform 0.2s;
    flex-shrink: 0;
}

.news-card:hover {
    transform: translateY(-3px);
}

.carousel-card-title {
    font-weight: 700;
    font-size: 15px;
    margin-bottom: 8px;
}

.carousel-card-text {
    font-size: 12px;
    opacity: 0.9;
}

.stories-overlay .stories-modal {
    position: relative;
    background: var(--surface);
    border-radius: var(--radius);
    padding: 40px;
    max-width: 520px;
    width: 100%;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.3);
}

.stories-body {
    text-align: center;
    min-height: 120px;
}

.story-title {
    font-size: 22px;
    margin-bottom: 14px;
}

.story-content {
    color: var(--text-muted);
}

.stories-nav {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background: none;
    border: none;
    font-size: 28px;
    cursor: pointer;
    color: var(--text);
    padding: 8px;
}

.stories-nav-left {
    left: 8px;
}

.stories-nav-right {
    right: 8px;
}

/* ===== Ближайшие занятия ===== */
.avail-sessions-list {
    display: grid;
    gap: 12px;
    max-height: 380px;
    overflow-y: auto;
}

.avail-session-card {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 14px;
    padding: 14px;
    background: var(--surface-alt);
    border-radius: 8px;
}

.avail-session-info {
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.avail-session-time {
    font-weight: 600;
    font-size: 14px;
}

.avail-session-name {
    font-size: 15px;
}

.avail-session-hall,
.avail-session-reason {
    font-size: 12px;
    color: var(--text-muted);
}

.avail-session-reason {
    color: var(--danger);
    text-align: right;
    max-width: 160px;
}

/* ===== История ===== */
.history-list {
    max-height: 360px;
    overflow-y: auto;
}

.history-item {
    display: flex;
    justify-content: space-between;
    gap: 10px;
    padding: 10px 0;
    border-bottom: 1px solid var(--border);
    font-size: 14px;
}

.history-item:last-child {
    border-bottom: none;
}

.history-date {
    color: var(--text-muted);
    white-space: nowrap;
}

.history-name {
    text-align: right;
}

/* ===== Новости (админка) ===== */
.news-admin-list {
    display: grid;
    gap: 12px;
}

.news-admin-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 14px;
    padding: 16px;
    background: var(--surface-alt);
    border-radius: 8px;
}

.news-admin-info {
    display: flex;
    align-items: center;
    gap: 12px;
    flex-wrap: wrap;
}

.news-admin-type {
    background: var(--primary);
    color: #fff;
    font-size: 11px;
    padding: 2px 8px;
    border-radius: 12px;
}

.news-admin-title {
    font-weight: 600;
}

.news-admin-unpublished {
    color: var(--danger);
    font-size: 12px;
}

.news-admin-date {
    color: var(--text-muted);
    font-size: 12px;
}

.news-admin-actions {
    display: flex;
    gap: 8px;
    flex-shrink: 0;
}

.news-form {
    background: var(--surface);
    border-radius: var(--radius);
    padding: 24px;
    box-shadow: 0 2px 10px var(--shadow);
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.news-form .form-row {
    display: flex;
    flex-direction: column;
}

.news-form textarea {
    min-height: 150px;
    resize: vertical;
}

.news-form .form-check-input {
    width: auto;
}

/* ===== Лендинг ===== */
.landing {
    min-height: 100vh;
}

.landing-nav {
    background: var(--surface);
    border-bottom: 1px solid var(--border);
    padding: 0 16px;
    position: sticky;
    top: 0;
    z-index: 100;
}

.landing-nav-inner {
    max-width: 1080px;
    margin: 0 auto;
    display: flex;
    align-items: center;
    justify-content: space-between;
    height: 60px;
}

.landing-brand {
    font-weight: 700;
    font-size: 18px;
}

.landing-nav-links {
    display: flex;
    gap: 10px;
}

.hero {
    text-align: center;
    padding: 80px 20px;
    background: linear-gradient(135deg, var(--primary) 0%, var(--primary-2) 100%);
    color: #fff;
}

.hero h1 {
    font-size: 40px;
    margin-bottom: 14px;
}

.hero p {
    font-size: 17px;
    opacity: 0.92;
    max-width: 560px;
    margin: 0 auto 26px;
}

.landing-section {
    max-width: 1080px;
    margin: 0 auto;
    padding: 48px 20px;
}

.landing-section h2 {
    font-size: 26px;
    margin-bottom: 22px;
    text-align: center;
}

.class-types-list {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    justify-content: center;
}

.class-type-card {
    display: flex;
    align-items: center;
    gap: 10px;
    background: var(--surface);
    border-radius: 10px;
    padding: 12px 18px;
    box-shadow: 0 2px 8px var(--shadow);
    font-weight: 500;
}

.class-type-color {
    width: 14px;
    height: 14px;
    border-radius: 50%;
}

.class-type-duration {
    color: var(--text-muted);
    font-size: 13px;
}

.landing-news-list {
    display: grid;
    gap: 16px;
    max-width: 680px;
    margin: 0 auto;
}

.landing-news-item {
    background: var(--surface);
    border-radius: var(--radius);
    padding: 20px;
    box-shadow: 0 2px 8px var(--shadow);
}

.landing-news-item h3 {
    margin-bottom: 8px;
}

.landing-news-item p {
    color: var(--text-muted);
}

.landing-news-date {
    font-size: 12px;
    color: var(--text-muted);
}

.landing-footer {
    text-align: center;
    padding: 24px;
    color: var(--text-muted);
}

/* ===== Адаптивность ===== */
@media (min-width: 769px) {
    .page-content {
        padding-bottom: 96px;
    }
}

@media (max-width: 768px) {
    .page-content {
        padding: 16px 12px 110px;
    }

    .greeting-text {
        font-size: 22px;
    }

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

    .session-card {
        flex-direction: column;
        gap: 12px;
    }

    .session-time {
        flex-direction: row;
        gap: 12px;
        border-right: none;
        border-bottom: 1px solid var(--border);
        padding-right: 0;
        padding-bottom: 8px;
    }

    .modal-actions {
        flex-direction: column-reverse;
    }

    .modal-actions .btn {
        width: 100%;
    }

    .news-admin-item {
        flex-direction: column;
        align-items: flex-start;
    }

    .notification-dropdown {
        position: fixed;
        right: 10px;
        left: 10px;
        width: auto;
    }
}

/* ===== Профиль ===== */
.btn-danger {
    background: var(--danger);
    border-color: var(--danger);
    color: #fff;
}

.btn-danger:hover {
    filter: brightness(0.9);
}

.profile-page {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.profile-card {
    display: flex;
    gap: 20px;
    align-items: flex-start;
    flex-wrap: wrap;
}

.profile-avatar-wrap {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 10px;
    flex-shrink: 0;
}

.profile-avatar-img,
.profile-avatar-placeholder {
    width: 96px;
    height: 96px;
    border-radius: 50%;
    object-fit: cover;
    background: var(--surface-alt);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--text-muted);
    overflow: hidden;
}

.profile-avatar-img {
    width: 120px;
    height: 120px;
}

.profile-avatar-placeholder i {
    width: 44px;
    height: 44px;
}

.avatar-input {
    position: absolute;
    width: 1px;
    height: 1px;
    opacity: 0;
    overflow: hidden;
    clip: rect(0 0 0 0);
    white-space: nowrap;
}

.avatar-error,
.modal-error {
    color: var(--danger);
    font-size: 13px;
    margin-top: 6px;
    width: 100%;
}

.profile-info {
    flex: 1;
    min-width: 240px;
}

.profile-name {
    font-size: 24px;
    margin: 0 0 14px;
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
}

.profile-rows {
    display: flex;
    flex-direction: column;
    gap: 8px;
    margin-bottom: 16px;
}

.profile-row {
    display: flex;
    gap: 10px;
    font-size: 14px;
}

.profile-row-label {
    color: var(--text-muted);
    min-width: 70px;
}

.profile-row-value {
    color: var(--text);
    word-break: break-word;
}

.profile-actions {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
}

.logout-form {
    display: inline-block;
}

.balance-card-profile {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 16px;
}

.balance-card-profile .balance-value {
    font-size: 28px;
    font-weight: 700;
    color: var(--text);
}

.profile-subs {
    display: flex;
    flex-direction: column;
    gap: 10px;
    margin-bottom: 16px;
}

.profile-sub {
    display: flex;
    align-items: center;
    gap: 12px;
    flex-wrap: wrap;
    background: var(--surface-alt);
    border-radius: 8px;
    padding: 12px 14px;
    font-size: 14px;
}

.profile-sub-name {
    font-weight: 600;
}

.profile-sub-count {
    color: var(--text-muted);
}

.profile-sub-expires {
    color: var(--text-muted);
    font-size: 13px;
}

.profile-no-data {
    color: var(--text-muted);
    font-size: 14px;
    margin: 0;
}

.balance-history-title {
    font-size: 16px;
    margin: 0;
}

.balance-transactions-list {
    display: flex;
    flex-direction: column;
    gap: 8px;
    margin-top: 8px;
}

.balance-transaction {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 12px;
    padding: 10px 4px;
    border-bottom: 1px solid var(--border);
    font-size: 14px;
    flex-wrap: wrap;
}

.balance-transaction:last-child {
    border-bottom: none;
}

.balance-transaction-main {
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.balance-transaction-comment {
    color: var(--text);
}

.balance-transaction-date {
    color: var(--text-muted);
    font-size: 12px;
}

.balance-transaction-amounts {
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    gap: 2px;
    text-align: right;
}

.balance-amount {
    font-weight: 700;
    white-space: nowrap;
}

.amount-credit {
    color: var(--success, #2ecc71);
}

.amount-debit {
    color: var(--danger);
}

.amount-neutral {
    color: var(--text-muted);
}

.balance-after {
    color: var(--text-muted);
    font-size: 12px;
}

.social-block {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.vk-status {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.vk-status-text {
    margin: 0;
    font-weight: 600;
}

.vk-messages-off {
    margin: 0;
    color: var(--text-muted);
    font-size: 13px;
}

.social-actions {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
}

/* ===== Тепловая карта ===== */
.heatmap-section {
    margin-bottom: 16px;
}

.heatmap-title {
    font-size: 14px;
    color: var(--text-muted);
    margin: 0 0 10px;
}

.heatmap-grid {
    display: flex;
    gap: 3px;
    overflow-x: auto;
    padding-bottom: 4px;
}

.hm-column {
    display: flex;
    flex-direction: column;
    gap: 3px;
}

.hm-cell {
    width: 11px;
    height: 11px;
    border-radius: 2px;
    background: var(--surface-alt);
    border: 1px solid var(--border);
    box-sizing: border-box;
}

.hm-cell.l1 {
    background: #d6efc4;
    border-color: #b8df9b;
}

.hm-cell.l2 {
    background: #a9d98e;
    border-color: #8cc76b;
}

.hm-cell.l3 {
    background: #6fbf55;
    border-color: #56a83d;
}

.hm-cell.l4 {
    background: #2e9e44;
    border-color: #1f7d33;
}

.history-list {
    display: flex;
    flex-direction: column;
    gap: 10px;
    max-height: 320px;
    overflow-y: auto;
}

.history-item {
    display: flex;
    justify-content: space-between;
    gap: 12px;
    font-size: 14px;
    padding: 8px 0;
    border-bottom: 1px solid var(--border);
    flex-wrap: wrap;
}

.history-item:last-child {
    border-bottom: none;
}

.history-date {
    color: var(--text-muted);
    white-space: nowrap;
}

.history-name {
    color: var(--text);
}

.confirm-text {
    margin: 0;
    color: var(--text);
}

/* --- Демо-режим: карточка фейковой оплаты + плашка VK --- */
.demo-payment-card {
    text-align: center;
    padding: 2rem 1rem;
}
.demo-payment-note {
    font-size: 0.85rem;
    color: var(--text-secondary);
    margin-bottom: 0.5rem;
}
.demo-payment-amount {
    font-size: 1.4rem;
    font-weight: 600;
    color: var(--text);
    margin-bottom: 1.2rem;
}
.vk-demo-note {
    text-align: center;
    font-size: 0.9rem;
    color: var(--text-secondary);
    padding: 1rem;
}