/* ============================================
   Б-Запись SPA — Стили бизнес-дашборда
   ============================================ */

/* Бизнес-режим */
#app.business-mode {
    display: block;
    min-height: 100vh;
    padding: 0;
    align-items: stretch;
}

body.business-body {
    background: #f5f5f5;
    padding-top: 0;
    padding-bottom: 0;
}

/* Обёртка */
.business-layout {
    display: flex;
    flex-direction: column;
    min-height: 100vh;
}

@media (min-width: 768px) {
    .business-layout {
        flex-direction: row;
    }
}

/* Основная область */
.business-main {
    flex: 1;
    display: flex;
    flex-direction: column;
    min-height: 100vh;
    width: 100%;
}

@media (min-width: 768px) {
    .business-main {
        width: calc(100% - 260px);
    }
}

/* Хедер */
.business-header {
    background: #ffffff;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.06);
    padding: 12px 16px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    position: sticky;
    top: 0;
    z-index: 100;
    width: 100%;
}

.business-header-left {
    display: flex;
    align-items: center;
    gap: 12px;
}

.business-header-right {
    display: flex;
    align-items: center;
    gap: 16px;
    margin-left: auto;
}

.business-header-center {
    display: flex;
    align-items: center;
    gap: 8px;
}

.business-header-center img {
    width: 28px;
    height: auto;
}

.business-header-center span {
    font-size: 18px;
    font-weight: 600;
    color: #1a1a1a;
}

.business-menu-btn {
    background: none;
    border: none;
    cursor: pointer;
    padding: 4px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.business-menu-btn svg {
    width: 24px;
    height: 24px;
    stroke: #1a1a1a;
}

@media (min-width: 768px) {
    .business-menu-btn {
        display: none !important;
    }
}

.business-divider {
    width: 1px;
    height: 28px;
    background: #e0e0e0;
}

@media (min-width: 768px) {
    .business-divider {
        display: none !important;
    }
}

/* Контейнер */
.business-container {
    flex: 1;
    max-width: 800px;
    margin: 0 auto;
    padding: 20px 16px;
    width: 100%;
}

/* Заголовок секции */
.business-section-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 20px;
}

.business-section-header h2 {
    font-size: 22px;
    font-weight: 600;
    color: #1a1a1a;
    margin: 0;
}

.business-add-btn {
    background: linear-gradient(135deg, #dd1847, #c1163d);
    color: white;
    border: none;
    width: 40px;
    height: 40px;
    border-radius: 12px;
    font-size: 24px;
    font-weight: 400;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 2px 8px rgba(221, 24, 71, 0.3);
    transition: all 0.2s;
    text-decoration: none;
    font-family: inherit;
}

.business-add-btn:hover {
    transform: scale(1.05);
    box-shadow: 0 4px 12px rgba(221, 24, 71, 0.4);
}

.business-add-btn.business-add-btn-text {
    width: auto;
    padding: 12px 24px;
    font-size: 16px;
    border-radius: 12px;
}

/* Карточка проекта */
.business-project-card {
    background: #ffffff;
    border-radius: 16px;
    padding: 16px;
    margin-bottom: 12px;
    display: flex;
    align-items: center;
    gap: 16px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.04);
    transition: all 0.2s;
    border: 1px solid #f0f0f0;
    cursor: pointer;
}

.business-project-card:hover {
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
    border-color: #e0e0e0;
}

.business-project-icon {
    width: 56px;
    height: 56px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    overflow: hidden;
    background: #f8f8f8;
}

.business-project-icon img {
    width: 56px;
    height: 56px;
    border-radius: 12px;
    object-fit: cover;
}

.business-project-info {
    flex: 1;
    min-width: 0;
}

.business-project-name {
    font-size: 18px;
    font-weight: 600;
    color: #1a1a1a;
    margin-bottom: 4px;
}

.business-project-address {
    font-size: 14px;
    color: #888;
}

.business-project-arrow {
    flex-shrink: 0;
}

.business-project-arrow svg {
    width: 20px;
    height: 20px;
    stroke: #ccc;
}

/* Ссылка на онлайн-запись */
.business-booking-link {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    margin-top: 8px;
    background: #fafafa;
    border: 1px solid #e5e5e5;
    border-radius: 8px;
    padding: 6px 12px;
    font-size: 12px;
    font-weight: 500;
    color: #333;
    cursor: pointer;
    transition: all 0.2s ease;
    user-select: none;
    position: relative;
}

.business-booking-link:hover {
    background: #f5f5f5;
    border-color: #d5d5d5;
}

.business-booking-link.inactive {
    color: #bbb;
    border-color: #f0f0f0;
    filter: blur(0.6px);
    cursor: default;
}

.business-booking-link.inactive:hover {
    background: #fafafa;
    border-color: #f0f0f0;
}

.business-booking-link-text {
    white-space: nowrap;
}

.business-booking-link-copy {
    flex-shrink: 0;
    opacity: 0.5;
    transition: opacity 0.15s;
    stroke: #666;
    cursor: pointer;
}

.business-booking-link-copy:hover {
    opacity: 1;
}

.business-copy-tooltip {
    position: absolute;
    top: -28px;
    left: 50%;
    transform: translateX(-50%);
    background: #1a1a1a;
    color: #fff;
    padding: 4px 10px;
    border-radius: 6px;
    font-size: 11px;
    white-space: nowrap;
    display: none;
}

/* Пустое состояние */
.business-empty-state {
    text-align: center;
    padding: 60px 20px;
    display: flex;
    flex-direction: column;
    align-items: center;
}

.business-empty-state img {
    width: 120px;
    height: 120px;
    opacity: 0.5;
    margin-bottom: 20px;
}

.business-empty-state h3 {
    font-size: 18px;
    font-weight: 600;
    color: #1a1a1a;
    margin-bottom: 8px;
}

.business-empty-state p {
    color: #888;
    margin-bottom: 24px;
}

/* Боковое меню */
.business-sidebar {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 1000;
    visibility: hidden;
    transition: visibility 0.3s;
}

.business-sidebar.active {
    visibility: visible;
}

.business-sidebar-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0,0,0,0.5);
    opacity: 0;
    transition: opacity 0.3s;
}

.business-sidebar.active .business-sidebar-overlay {
    opacity: 1;
}

.business-sidebar-content {
    position: absolute;
    top: 0;
    left: 0;
    width: 280px;
    max-width: 85%;
    height: 100%;
    background: white;
    transform: translateX(-100%);
    transition: transform 0.3s;
    display: flex;
    flex-direction: column;
}

.business-sidebar.active .business-sidebar-content {
    transform: translateX(0);
}

@media (min-width: 768px) {
    .business-sidebar {
        visibility: visible !important;
        position: relative;
        width: 260px;
        height: 100vh;
        z-index: 1;
        flex-shrink: 0;
    }
    
    .business-sidebar .business-sidebar-content {
        transform: translateX(0) !important;
        position: relative;
        width: 100%;
        max-width: 100%;
        box-shadow: none;
        border-right: 1px solid #f0f0f0;
    }
    
    .business-sidebar-overlay {
        display: none !important;
    }
}

.business-sidebar-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 16px 20px;
    border-bottom: 1px solid #f0f0f0;
}

.business-sidebar-logo {
    display: flex;
    align-items: center;
    gap: 8px;
}

.business-sidebar-logo img {
    width: 150px;
    height: auto;
}

.business-sidebar-close {
    background: none;
    border: none;
    width: 32px;
    height: 32px;
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    color: #666;
}

.business-sidebar-close:hover {
    background: #f5f5f5;
}

@media (min-width: 768px) {
    .business-sidebar-close {
        display: none !important;
    }
}

.business-sidebar-menu {
    flex: 1;
    overflow-y: auto;
    padding: 16px 12px;
}

.business-menu-section {
    margin-bottom: 24px;
}

.business-menu-section-title {
    font-size: 12px;
    font-weight: 600;
    color: #999;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    padding: 0 12px;
    margin-bottom: 8px;
}

.business-menu-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 16px;
    border-radius: 10px;
    color: #1a1a1a;
    text-decoration: none;
    font-size: 15px;
    font-weight: 500;
    transition: all 0.2s;
    margin-bottom: 4px;
    cursor: pointer;
    border: none;
    background: none;
    width: 100%;
    text-align: left;
    font-family: inherit;
}

.business-menu-item:hover {
    background: #f5f5f5;
}

.business-menu-item.active {
    background: linear-gradient(135deg, #dd1847, #c1163d);
    color: white;
}

.business-menu-item svg {
    width: 20px;
    height: 20px;
    flex-shrink: 0;
}

.business-menu-item.active svg {
    stroke: white;
}

/* Скелетоны */
.business-skeleton-card {
    background: #fff;
    border-radius: 16px;
    padding: 16px;
    margin-bottom: 12px;
    display: flex;
    align-items: center;
    gap: 16px;
    border: 1px solid #f0f0f0;
}

.business-skeleton-icon {
    width: 56px;
    height: 56px;
    border-radius: 12px;
    flex-shrink: 0;
}

.business-skeleton-info {
    flex: 1;
}

.business-skeleton-name {
    width: 160px;
    height: 18px;
    border-radius: 4px;
    margin-bottom: 6px;
}

.business-skeleton-address {
    width: 200px;
    height: 14px;
    border-radius: 4px;
    margin-bottom: 8px;
}

.business-skeleton-link {
    width: 220px;
    height: 28px;
    border-radius: 8px;
}

/* ============================================
   CREATE PROJECT MODAL
   ============================================ */

.create-project-modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    z-index: 9999;
    visibility: hidden;
    transition: visibility 0.3s;
    display: flex;
    align-items: center;
    justify-content: center;
}

.create-project-modal.active {
    visibility: visible;
}

.create-project-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    opacity: 0;
    transition: opacity 0.3s;
}

.create-project-modal.active .create-project-overlay {
    opacity: 1;
}

.create-project-content {
    position: relative;
    width: 100%;
    max-width: 100%;
    height: 100vh;
    max-height: 100vh;
    background: white;
    overflow-y: auto;
    opacity: 0;
    transform: translateY(20px);
    transition: opacity 0.3s, transform 0.3s;
}

.create-project-modal.active .create-project-content {
    opacity: 1;
    transform: translateY(0);
}

.create-project-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 16px 20px;
    border-bottom: 1px solid #f0f0f0;
    position: sticky;
    top: 0;
    background: white;
    z-index: 10;
}

.create-project-header h2 {
    font-size: 18px;
    font-weight: 600;
    margin: 0;
}

.create-project-back, .create-project-close {
    background: none;
    border: none;
    width: 36px;
    height: 36px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    color: #666;
    transition: background 0.15s;
}

.create-project-back:hover, .create-project-close:hover {
    background: #f5f5f5;
}

.create-project-back svg, .create-project-close svg {
    width: 20px;
    height: 20px;
}

/* Индикатор шагов */
.step-indicator {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0;
    padding: 16px 40px;
}

.step-dot {
    width: 12px;
    height: 12px;
    border-radius: 50%;
    background: #e0e0e0;
    transition: all 0.3s;
    position: relative;
}

.step-dot.active {
    background: #dd1847;
    box-shadow: 0 0 0 4px rgba(221, 24, 71, 0.15);
}

.step-dot.completed {
    background: #dd1847;
}

.step-line {
    flex: 1;
    height: 2px;
    background: #e0e0e0;
    margin: 0 8px;
    transition: background 0.3s;
}

.step-line.completed {
    background: #dd1847;
}

.create-project-body {
    padding: 20px;
}

.project-step {
    display: none;
}

.project-step.active {
    display: block;
    animation: fadeSlideIn 0.3s ease;
}

@keyframes fadeSlideIn {
    from { opacity: 0; transform: translateY(10px); }
    to { opacity: 1; transform: translateY(0); }
}

.project-type-grid {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.project-type-card {
    padding: 24px 20px;
    background: #f8f9fa;
    border-radius: 16px;
    cursor: pointer;
    transition: all 0.2s;
    border: 2px solid transparent;
    text-align: center;
    position: relative;
    overflow: hidden;
}

.project-type-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(135deg, rgba(221, 24, 71, 0.05), transparent);
    opacity: 0;
    transition: opacity 0.2s;
}

.project-type-card:hover {
    border-color: #dd1847;
    background: white;
    transform: translateY(-2px);
    box-shadow: 0 8px 24px rgba(221, 24, 71, 0.1);
}

.project-type-card:hover::before {
    opacity: 1;
}

.project-type-card:active {
    transform: scale(0.98);
}

.type-icon {
    margin-bottom: 12px;
    position: relative;
    z-index: 1;
}

.type-title {
    font-size: 18px;
    font-weight: 600;
    margin-bottom: 4px;
    position: relative;
    z-index: 1;
}

.type-desc {
    font-size: 14px;
    color: #888;
    position: relative;
    z-index: 1;
}

.sphere-grid {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.sphere-card {
    padding: 16px;
    background: #f8f9fa;
    border-radius: 12px;
    cursor: pointer;
    transition: all 0.2s;
    display: flex;
    align-items: center;
    gap: 12px;
    position: relative;
    overflow: hidden;
}

.sphere-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(135deg, #dd1847, #c1163d);
    opacity: 0;
    transition: opacity 0.2s;
}

.sphere-card:hover {
    transform: translateX(4px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
}

.sphere-card:hover::before {
    opacity: 1;
}

.sphere-card:hover .sphere-name {
    color: white;
}

.sphere-card:hover .sphere-examples {
    color: rgba(255, 255, 255, 0.8);
}

.sphere-card:hover .sphere-icon {
    background: rgba(255, 255, 255, 0.2);
}

.sphere-card:hover .sphere-icon img {
    filter: brightness(0) invert(1);
}

.sphere-icon {
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: white;
    border-radius: 10px;
    flex-shrink: 0;
    transition: background 0.2s;
    position: relative;
    z-index: 1;
}

.sphere-info {
    flex: 1;
    position: relative;
    z-index: 1;
}

.sphere-name {
    font-size: 16px;
    font-weight: 600;
    display: block;
    margin-bottom: 2px;
    transition: color 0.2s;
}

.sphere-examples {
    font-size: 12px;
    color: #888;
    display: block;
    transition: color 0.2s;
}

/* Подкатегории */
.subcategories-title {
    font-size: 16px;
    font-weight: 600;
    margin-bottom: 16px;
    text-align: center;
}

.subcategories-grid {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.subcategory-chip {
    padding: 10px 16px;
    background: #f8f9fa;
    border: 2px solid transparent;
    border-radius: 20px;
    cursor: pointer;
    font-size: 14px;
    font-weight: 500;
    color: #666;
    transition: all 0.15s;
    white-space: nowrap;
}

.subcategory-chip:hover {
    border-color: #dd1847;
    color: #dd1847;
    transform: translateY(-1px);
}

.subcategory-chip.selected {
    background: #dd1847;
    color: white;
    border-color: #dd1847;
}

.subcategory-chip:active {
    transform: scale(0.95);
}

.subcategories-next {
    width: 100%;
    padding: 16px;
    background: #dd1847;
    color: white;
    border: none;
    border-radius: 12px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    margin-top: 24px;
    transition: opacity 0.15s;
    font-family: inherit;
}

.subcategories-next:hover {
    opacity: 0.9;
}

.form-group {
    margin-bottom: 16px;
    position: relative;
}

.form-group label {
    display: block;
    font-size: 14px;
    font-weight: 500;
    margin-bottom: 6px;
    color: #333;
}

.form-group input {
    width: 100%;
    padding: 14px;
    border: 2px solid #e0e0e0;
    border-radius: 12px;
    font-size: 15px;
    box-sizing: border-box;
    transition: border-color 0.2s;
    outline: none;
    font-family: inherit;
}

.form-group input:focus {
    border-color: #dd1847;
    box-shadow: 0 0 0 3px rgba(221, 24, 71, 0.1);
}

.form-group input::placeholder {
    color: #aaa;
}

.address-suggestions {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    margin-top: 4px;
    border: 1px solid #e0e0e0;
    border-radius: 12px;
    background: white;
    max-height: 300px;
    overflow-y: auto;
    display: none;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.12);
    z-index: 100;
}

.address-suggestions.active {
    display: block;
    animation: fadeSlideIn 0.2s ease;
}

.suggestion-item {
    padding: 12px 14px;
    border-bottom: 1px solid #f0f0f0;
    cursor: pointer;
    font-size: 14px;
    transition: background 0.15s;
}

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

.suggestion-item:hover {
    background: #f8f9fa;
}

.suggestion-item.loading {
    text-align: center;
    color: #999;
    cursor: default;
}

.suggestion-item .main-text {
    font-weight: 500;
    color: #1a1a1a;
}

.suggestion-item .secondary-text {
    font-size: 12px;
    color: #888;
    margin-top: 2px;
}

.terms-section {
    margin: 20px 0;
}

.checkbox-label {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    margin-bottom: 12px;
    font-size: 13px;
    color: #666;
    cursor: pointer;
    line-height: 1.5;
}

.checkbox-label input[type="checkbox"] {
    width: 18px;
    height: 18px;
    margin-top: 2px;
    flex-shrink: 0;
    accent-color: #dd1847;
}

.checkbox-label a {
    color: #dd1847;
    text-decoration: none;
    font-weight: 500;
}

.checkbox-label a:hover {
    text-decoration: underline;
}

.create-project-submit {
    width: 100%;
    padding: 16px;
    background: linear-gradient(135deg, #dd1847, #c1163d);
    color: white;
    border: none;
    border-radius: 12px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    margin-top: 20px;
    transition: all 0.2s;
    position: relative;
    overflow: hidden;
    font-family: inherit;
}

.create-project-submit:hover:not(:disabled) {
    transform: translateY(-1px);
    box-shadow: 0 8px 20px rgba(221, 24, 71, 0.3);
}

.create-project-submit:active:not(:disabled) {
    transform: scale(0.98);
}

.create-project-submit:disabled {
    opacity: 0.6;
    cursor: not-allowed;
}

.create-project-submit.loading {
    pointer-events: none;
}

.btn-loader svg {
    animation: spin 1s linear infinite;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

/* Адаптация для десктопа */
@media (min-width: 768px) {
    .create-project-content {
        max-width: 520px;
        max-height: 90vh;
        height: auto;
        border-radius: 20px;
        box-shadow: 0 20px 60px rgba(0, 0, 0, 0.15);
    }
    
    .create-project-header {
        border-radius: 20px 20px 0 0;
    }
}

/* ===== NETWORKS ===== */
.networks-container { max-width: 800px; }
.networks-list { display: flex; flex-direction: column; gap: 12px; }
.network-card {
    background: #fff; border: 1px solid #f0f0f0; border-radius: 16px;
    padding: 16px 20px; display: flex; align-items: center; justify-content: space-between;
    gap: 16px;
}
.network-card-logo {
    width: 56px; height: 56px; border-radius: 14px;
    background: #f8f8f8; display: flex; align-items: center;
    justify-content: center; overflow: hidden; flex-shrink: 0;
    border: 1px dashed #ccc;
}
.network-card-logo img { width: 100%; height: 100%; object-fit: cover; }
.network-info { flex: 1; min-width: 0; }
.network-name { font-size: 16px; font-weight: 600; color: #1a1a1a; margin-bottom: 4px; }
.network-link {
    display: inline-flex; align-items: center; gap: 6px;
    font-size: 12px; color: #dd1847; cursor: pointer; position: relative;
    background: #fdf2f5; padding: 4px 10px; border-radius: 6px;
}
.network-link:hover { background: #fde8ee; }
.network-count { font-size: 12px; color: #999; margin-top: 4px; }
.network-actions { display: flex; gap: 8px; flex-shrink: 0; }
.network-edit-btn, .network-delete-btn {
    width: 36px; height: 36px; border-radius: 10px; border: 1px solid #e0e0e0;
    background: #fff; cursor: pointer; display: flex; align-items: center; justify-content: center;
    transition: all .15s;
}
.network-edit-btn:hover { background: #f5f5f5; }
.network-delete-btn:hover { background: #fff0f0; border-color: #f44336; color: #f44336; }

/* Форма */
.modal-overlay {
    position: fixed; top: 0; left: 0; right: 0; bottom: 0;
    background: rgba(0,0,0,.5); z-index: 2000;
    display: flex; align-items: center; justify-content: center;
}
.modal-content {
    background: #fff; border-radius: 20px; width: 90%;
    max-height: 80vh; display: flex; flex-direction: column;
}
.modal-header {
    display: flex; align-items: center; justify-content: space-between;
    padding: 20px; border-bottom: 1px solid #f0f0f0;
}
.modal-header h3 { margin: 0; font-size: 18px; font-weight: 600; }
.modal-back-btn {
    background: none; border: none; padding: 4px; cursor: pointer;
    display: flex; align-items: center; justify-content: center;
    border-radius: 8px; transition: background 0.2s; stroke: #666;
}
.modal-back-btn:hover { background: #f5f5f5; }
.modal-close-btn { background: none; border: none; cursor: pointer; color: #666; padding: 4px; }
.modal-body { flex: 1; overflow-y: auto; padding: 20px; }
.modal-footer {
    display: flex; gap: 10px; padding: 20px;
    border-top: 1px solid #f0f0f0;
}
.btn-cancel {
    flex: 1; padding: 14px; background: #f5f5f5;
    border: none; border-radius: 12px; font-size: 14px; cursor: pointer; font-family: inherit;
}
.btn-save {
    flex: 1; padding: 14px; background: #dd1847; color: #fff;
    border: none; border-radius: 12px; font-size: 14px; font-weight: 600; cursor: pointer;
    font-family: inherit; transition: opacity 0.2s;
}
.btn-save:hover { opacity: 0.9; }
.btn-save:disabled { opacity: 0.6; cursor: not-allowed; }
.btn-save-loader svg { animation: spin 1s linear infinite; }

/* Блок логотип + название */
.network-header-block {
    display: flex; align-items: stretch; gap: 16px;
    background: #f8f8f8; border: 1px solid #e0e0e0;
    border-radius: 14px; padding: 16px;
}
.network-logo-upload {
    width: 86px; height: 86px; border-radius: 16px;
    background: #fff; display: flex; align-items: center;
    justify-content: center; flex-shrink: 0; cursor: pointer;
    position: relative; overflow: visible; border: 2px dashed #ddd;
    transition: all 0.15s;
}
.network-logo-upload:hover { border-color: #dd1847; background: #fdf2f5; }
.network-logo-preview {
    width: 100%; height: 100%; display: flex; align-items: center;
    justify-content: center; border-radius: 14px; overflow: hidden;
}
.network-logo-preview img { width: 100%; height: 100%; object-fit: cover; border-radius: 14px; }
.network-logo-overlay {
    position: absolute; top: 0; left: 0; width: 100%; height: 100%;
    background: rgba(0,0,0,0.5); border-radius: 14px;
    display: flex; align-items: center; justify-content: center;
    opacity: 0; transition: opacity 0.2s; pointer-events: none;
}
.network-logo-upload:hover .network-logo-overlay { opacity: 1; }
.network-logo-delete {
    position: absolute; top: -8px; right: -8px;
    width: 26px; height: 26px; border-radius: 50%;
    background: #f44336; border: 2px solid #fff;
    color: #fff; cursor: pointer; display: flex;
    align-items: center; justify-content: center; padding: 0;
    box-shadow: 0 2px 6px rgba(0,0,0,0.15); transition: all 0.2s; z-index: 5;
}
.network-logo-delete:hover { background: #d32f2f; transform: scale(1.05); }
.network-header-info {
    flex: 1; min-width: 0; display: flex;
    flex-direction: column; justify-content: center; gap: 8px;
}
.network-header-info .form-input { background: #fff; }
.network-slug-display {
    display: flex; align-items: center; gap: 4px;
    padding: 8px 12px; background: #fff;
    border: 1px solid #e0e0e0; border-radius: 8px;
    font-size: 12px; overflow: hidden; white-space: nowrap; text-overflow: ellipsis;
}

/* Телефон */
.network-phone-wrapper { position: relative; }
.network-country-selector {
    position: absolute; left: 0; top: 0; height: 100%;
    display: flex; align-items: center; justify-content: center; gap: 4px;
    padding: 0 10px; background: #f8f8f8; border: 1px solid #e0e0e0;
    border-right: 1px solid rgba(0,0,0,0.08); border-radius: 12px 0 0 12px;
    cursor: pointer; z-index: 10; box-sizing: border-box;
    font-size: 13px; color: #666; min-width: 62px; user-select: none;
}
.network-phone-input { padding-left: 78px !important; }

/* Строка соцсетей */
.network-section-row {
    display: flex; align-items: center; justify-content: space-between;
    padding: 14px 16px; background: #f8f8f8; border: 1px solid #e0e0e0;
    border-radius: 12px; cursor: pointer; transition: all 0.15s; gap: 12px;
}
.network-section-row:hover { background: #f0f0f0; border-color: #dd1847; }
.network-section-label { font-size: 14px; font-weight: 500; color: #1a1a1a; }
.network-section-value { display: flex; align-items: center; gap: 8px; color: #888; font-size: 13px; }
.network-social-icons { display: flex; gap: 6px; align-items: center; }
.network-social-icons img { width: 18px; height: 18px; object-fit: contain; }

/* Попап соцсетей */
.network-sub-overlay {
    position: fixed; top: 0; left: 0; right: 0; bottom: 0;
    background: rgba(0,0,0,0.5); z-index: 2100;
    display: flex; align-items: flex-end; justify-content: center;
}
@media (min-width: 768px) { .network-sub-overlay { align-items: center; } }
.network-sub-popup {
    background: #fff; border-radius: 20px 20px 0 0;
    width: 100%; max-width: 500px; max-height: 80vh;
    display: flex; flex-direction: column; animation: nwSlideUp 0.25s ease;
}
@media (min-width: 768px) { .network-sub-popup { border-radius: 20px; max-height: 70vh; } }
@keyframes nwSlideUp { from { transform: translateY(100%); } to { transform: translateY(0); } }
.network-sub-header {
    display: flex; align-items: center; justify-content: space-between;
    padding: 20px; border-bottom: 1px solid #f0f0f0; flex-shrink: 0;
}
.network-sub-header h3 { margin: 0; font-size: 18px; font-weight: 600; }
.network-sub-header button { background: none; border: none; padding: 8px; cursor: pointer; border-radius: 8px; }
.network-sub-header button:hover { background: #f5f5f5; }
.network-sub-body { flex: 1; overflow-y: auto; padding: 16px 20px; }
.network-sub-footer { padding: 20px; border-top: 1px solid #f0f0f0; flex-shrink: 0; }
.network-sub-save-btn {
    width: 100%; padding: 14px; background: #dd1847; color: #fff;
    border: none; border-radius: 12px; font-size: 15px; font-weight: 600; cursor: pointer; font-family: inherit;
}
.network-sub-save-btn:hover { background: #c4153e; }

/* Проекты в сети */
.network-project-item {
    display: flex; align-items: center; gap: 12px;
    padding: 12px 14px; border: 1px solid #f0f0f0;
    border-radius: 14px; margin-bottom: 8px; cursor: pointer;
    transition: all 0.15s;
}
.network-project-item:hover { border-color: #ddd; }
.network-project-item.selected { border-color: #dd1847; background: #fdf2f5; }
.network-project-item.disabled { opacity: 0.5; cursor: not-allowed; }
.network-project-item.disabled:hover { border-color: #f0f0f0; background: transparent; }
.network-project-avatar {
    width: 44px; height: 44px; border-radius: 12px;
    background: #f8f8f8; display: flex; align-items: center;
    justify-content: center; overflow: hidden; flex-shrink: 0;
}
.network-project-avatar img { width: 100%; height: 100%; object-fit: cover; }
.network-project-info { flex: 1; min-width: 0; }
.network-project-name { font-size: 14px; font-weight: 600; color: #1a1a1a; }
.network-project-addr { font-size: 12px; color: #999; margin-top: 2px; }
.network-project-status { font-size: 11px; color: #999; margin-top: 2px; }
.network-project-status.online { color: #2e7d32; }
.network-project-status.offline { color: #c62828; }
.network-project-check {
    width: 22px; height: 22px; border: 2px solid #ccc; border-radius: 50%;
    display: flex; align-items: center; justify-content: center; flex-shrink: 0;
}
.network-project-item.selected .network-project-check {
    border-color: #dd1847; background: #dd1847;
}
.network-project-item.selected .network-project-check::after {
    content: ''; width: 6px; height: 10px; border: solid #fff;
    border-width: 0 2px 2px 0; transform: rotate(45deg); margin-top: -2px;
}

/* ===== МОДАЛКИ НЕ ПЕРЕКРЫВАЮТ САЙДБАР НА ПК ===== */
@media (min-width: 768px) {
    .business-sidebar {
        z-index: 1000 !important;
    }
    
    .profile-modal,
    .quick-login-modal {
        z-index: 999 !important;
    }
}

/* ===== EMBEDDED-РЕЖИМ (страницы профиль/быстрый вход) ===== */
.business-container .profile-modal,
.business-container .quick-login-modal {
    position: relative !important;
    z-index: auto !important;
    visibility: visible !important;
    display: block !important;
    left: auto !important;
    width: 100% !important;
}

.business-container .profile-modal-overlay,
.business-container .quick-login-overlay {
    display: none !important;
}

.business-container .profile-modal-content,
.business-container .quick-login-content {
    position: relative !important;
    left: auto !important;
    width: 100% !important;
    max-width: 100% !important;
    height: auto !important;
    max-height: none !important;
    border-radius: 16px !important;
    box-shadow: none !important;
    opacity: 1 !important;
    transform: none !important;
}
/* ===== PROFILE MODAL (контент) ===== */
.profile-modal-body {
    padding: 20px 0;
}
.profile-avatar-section {
    text-align: center;
    margin-bottom: 24px;
}
.profile-avatar-wrapper {
    position: relative;
    display: inline-block;
}
.profile-avatar {
    width: 100px;
    height: 100px;
    margin: 0 auto 8px;
    border-radius: 50%;
    background: #f0f0f0 !important;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    position: relative;
    overflow: hidden;
    border: 3px solid white;
    box-shadow: 0 4px 12px rgba(0,0,0,0.1);
}
.profile-avatar img { width: 100%; height: 100%; object-fit: cover; }
.avatar-overlay {
    position: absolute; top: 0; left: 0; width: 100%; height: 100%;
    background: rgba(0,0,0,0.5); display: flex; align-items: center;
    justify-content: center; opacity: 0; transition: opacity 0.2s; border-radius: 50%;
}
.profile-avatar:hover .avatar-overlay { opacity: 1; }
.avatar-loading {
    position: absolute; top: 0; left: 0; width: 100%; height: 100%;
    background: rgba(255,255,255,0.7); border-radius: 50%;
    display: flex; align-items: center; justify-content: center;
}
.avatar-spinner {
    width: 30px; height: 30px; border: 3px solid #f0f0f0;
    border-top-color: #dd1847; border-radius: 50%; animation: spin 0.8s linear infinite;
}
.profile-avatar-delete {
    position: absolute; bottom: 5px; right: 5px; width: 28px; height: 28px;
    border-radius: 50%; background: #f44336; border: 2px solid white;
    color: white; cursor: pointer; display: flex; align-items: center;
    justify-content: center; padding: 0; box-shadow: 0 2px 6px rgba(0,0,0,0.15);
    transition: all 0.2s; z-index: 5;
}
.avatar-hint { font-size: 13px; color: #999; margin: 8px 0 0; }

.profile-section { margin-bottom: 20px; }
.profile-section-title { font-size: 14px; font-weight: 600; color: #1a1a1a; margin-bottom: 10px; }
.profile-input {
    width: 100%; padding: 16px 18px; border: 1px solid #e0e0e0;
    border-radius: 12px; font-size: 15px; background: #f8f8f8;
    transition: all 0.2s; font-family: inherit; box-sizing: border-box;
}
.profile-input:focus { outline: none; border-color: #dd1847; background: #fff; }
.profile-input.error { border-color: #f44336; background: #fff5f5; }
.profile-name-fields { display: flex; gap: 12px; }
.profile-name-fields .profile-input { flex: 1; min-width: 0; }
.profile-email-error, .profile-password-error { color: #f44336; font-size: 12px; margin-top: 6px; }
.profile-logout-link {
    display: block; text-align: center; color: #999; font-size: 14px;
    text-decoration: none; padding: 10px;
}
.profile-save-bar {
    position: sticky; bottom: 0; background: #fff; padding: 12px 0;
    box-shadow: 0 -4px 20px rgba(0,0,0,.08); transform: translateY(100%);
    transition: transform .3s; margin-top: 20px;
}
.profile-save-bar.visible { transform: translateY(0); }
.profile-save-bar-btn {
    width: 100%; padding: 14px 24px; background: #dd1847; color: #fff;
    border: 0; border-radius: 12px; font-size: 15px; font-weight: 600;
    cursor: pointer; display: flex; align-items: center; justify-content: center;
    gap: 8px; font-family: inherit;
}

/* ===== QUICK LOGIN METHODS (контент) ===== */
.quick-login-subtitle { color: #666; font-size: 14px; margin: 0 0 20px 0; }
.quick-login-methods { display: flex; flex-direction: column; gap: 12px; }
.method-card {
    display: flex; align-items: center; justify-content: space-between;
    padding: 16px; background: #f8f9fa; border-radius: 16px; gap: 12px;
}
.method-left { display: flex; align-items: flex-start; gap: 12px; flex: 1; }
.method-icon {
    width: 44px; height: 44px; background: white; border-radius: 12px;
    display: flex; align-items: center; justify-content: center; flex-shrink: 0;
}
.method-info { flex: 1; }
.method-title { font-size: 16px; font-weight: 600; color: #1a1a1a; margin-bottom: 2px; }
.method-desc { font-size: 13px; color: #888; margin-bottom: 4px; }
.method-status { font-size: 12px; color: #dd1847; font-weight: 500; }
.method-status.connected { color: #2E7D32; }
.method-actions { display: flex; flex-direction: column; gap: 6px; align-items: flex-end; }
.method-action {
    padding: 10px 16px; background: white; color: #dd1847;
    border: 1px solid #dd1847; border-radius: 10px; font-size: 13px;
    font-weight: 600; cursor: pointer; font-family: inherit;
}
.method-action:hover:not(:disabled) { background: #dd1847; color: white; }
.method-delete {
    padding: 6px 12px; background: transparent; color: #f44336;
    border: 1px solid #f44336; border-radius: 8px; font-size: 12px;
    font-weight: 500; cursor: pointer; font-family: inherit;
}
.method-delete:hover:not(:disabled) { background: #f44336; color: white; }
.method-action:disabled, .method-delete:disabled { opacity: 0.6; cursor: not-allowed; }

/* ===== PIN FULLSCREEN ===== */
.pin-fullscreen-container {
    position: fixed; top: 0; left: 0; width: 100%; height: 100%;
    background: white; z-index: 1300; display: none;
    flex-direction: column; justify-content: flex-start;
}
.pin-fullscreen-container.active { display: flex; }
.pin-fullscreen-close-btn {
    position: absolute; top: 16px; right: 16px; background: transparent;
    border: none; width: 44px; height: 44px; border-radius: 50%;
    display: flex; align-items: center; justify-content: center; cursor: pointer;
    color: #666; z-index: 10;
}
.pin-fullscreen-header { text-align: center; padding: 50px 20px 20px; }
.pin-fullscreen-title { font-size: 24px; font-weight: 600; color: #1a1a1a; margin: 0 0 8px 0; }
.pin-fullscreen-subtitle { font-size: 16px; color: #666; margin: 0; }
.pin-display-container { text-align: center; padding: 10px 24px 5px; }
.pin-dots { display: flex; justify-content: center; gap: 16px; margin-bottom: 8px; }
.pin-dot { width: 14px; height: 14px; background: #e0e0e0; border-radius: 50%; transition: all 0.2s; }
.pin-dot.filled { background: #dd1847; transform: scale(1.1); }
.pin-dot.error { background: #f44336; }
.pin-error-message { color: #f44336; font-size: 14px; min-height: 20px; margin-top: 8px; }
.pin-fields-container { display: flex; justify-content: center; gap: 12px; margin: 20px 0; }
.pin-field { width: 56px; height: 56px; border: 2px solid #e0e0e0; border-radius: 12px; text-align: center; font-size: 24px; font-weight: 600; background: #f8f9fa; }
.pin-hidden-input { position: absolute; opacity: 0; pointer-events: none; width: 1px; height: 1px; }
.pin-keypad { background: white; padding: 10px 24px 40px; margin-top: 50px; }
.pin-confirm-text { font-size: 14px; color: #666; text-align: center; margin-bottom: 16px; }
.pin-keypad-grid { display: grid; gap: 16px; max-width: 320px; margin: 0 auto; justify-content: center; grid-template-columns: repeat(3, 1fr); }
.pin-key-btn { aspect-ratio: 1; background: #f8f9fa; border: none; border-radius: 50%; font-size: 32px; font-weight: 500; color: #1a1a1a; cursor: pointer; display: flex; align-items: center; justify-content: center; font-family: inherit; }
.pin-forgot-link { text-align: center; margin-top: 8px; }

@media (min-width: 768px) {
    .pin-keypad { display: none; }
    .pin-fields-container { display: flex; }
    .pin-dots { display: none; }
    .pin-fullscreen-container {
        position: fixed; top: 50%; left: 50%; transform: translate(-50%, -50%);
        width: 440px; height: auto; min-height: 380px; max-height: 80vh;
        border-radius: 24px; box-shadow: 0 20px 60px rgba(0,0,0,0.3);
    }
    .pin-forgot-link { display: block; }
}
/* ===== PIN-ВВОД: только клавиатура на всех экранах ===== */
.pin-fields-container {
    display: none !important;
}

.pin-keypad {
    display: block !important;
}

.pin-dots {
    display: flex !important;
}

.pin-forgot-link {
    display: none !important;
}

/* На ПК — клавиатура всё равно скрыта, только на мобильных */
@media (min-width: 768px) {
    .pin-keypad {
        display: none !important;
    }
    
    .pin-fields-container {
        display: flex !important;
    }
    
    .pin-dots {
        display: none !important;
    }
    
    .pin-forgot-link {
        display: block !important;
    }
}