﻿:root {
    --primary: #336e78;
    --primary-dark: #2980b9;
    --accent: #3498db;
}

* {
    box-sizing: border-box;
}

body {
    font-family: Arial, sans-serif;
    margin: 0;
    padding: 0;
    background-color: #f5f5f5;
    color: #333;
}

.top-bar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    background-color: var(--primary);
    color: white;
    padding: 10px 24px;
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.15);
}

.top-bar .brand {
    display: flex;
    align-items: center;
    flex-shrink: 0;
    text-decoration: none;
    line-height: 0;
    background: #fff;
    border-radius: 8px;
    padding: 3px 10px;
}

.top-bar .brand__logo {
    display: block;
    height: 32px;
    width: auto;
    max-width: min(180px, 42vw);
    object-fit: contain;
}

.top-actions {
    display: flex;
    gap: 12px;
}

.nav-btn {
    background-color: rgba(255, 255, 255, 0.15);
    color: white;
    border: 1px solid rgba(255, 255, 255, 0.4);
    padding: 10px 22px;
    border-radius: 30px;
    cursor: pointer;
    font-size: 15px;
    font-weight: 600;
    transition: all 0.25s ease;
}

.nav-btn:hover {
    background-color: white;
    color: var(--primary);
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.2);
}

.nav-btn.primary {
    background-color: var(--accent);
    border-color: var(--accent);
}

.nav-btn.primary:hover {
    background-color: white;
    color: var(--accent);
}

.container {
    max-width: 900px;
    margin: 40px auto;
    background: white;
    padding: 40px;
    border-radius: 10px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.08);
}

h1 {
    color: var(--primary);
    text-align: center;
    margin-top: 0;
}

p {
    line-height: 1.7;
    color: #555;
    font-size: 16px;
}

ul {
    line-height: 1.9;
    color: #555;
}

.procedure-block {
    text-align: center;
    margin-top: 35px;
    padding-top: 25px;
    border-top: 1px solid #eee;
}

.procedure-btn {
    display: inline-block;
    background-color: var(--primary);
    color: white;
    text-decoration: none;
    padding: 14px 36px;
    border-radius: 30px;
    font-size: 17px;
    font-weight: 700;
    border: none;
    cursor: pointer;
    transition: all 0.25s ease;
}

.procedure-btn:hover {
    background-color: var(--primary-dark);
    transform: translateY(-2px);
    box-shadow: 0 6px 18px rgba(0, 0, 0, 0.2);
}

.android-install-hint {
    margin-top: 14px;
    font-size: 14px;
    color: #777;
    line-height: 1.5;
}

.session-info {
    display: flex;
    align-items: center;
    gap: 10px;
}

.session-label {
    font-size: 14px;
    font-weight: 600;
    padding: 8px 14px;
    background: rgba(255, 255, 255, 0.18);
    border-radius: 20px;
    white-space: nowrap;
}

.dropdown {
    position: relative;
}

.dropdown-menu {
    position: absolute;
    right: 0;
    top: calc(100% + 8px);
    background: white;
    border-radius: 8px;
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.18);
    min-width: 240px;
    padding: 8px 0;
    z-index: 1100;
}

.dropdown-menu button {
    display: block;
    width: 100%;
    text-align: left;
    background: none;
    border: none;
    padding: 12px 18px;
    font-size: 15px;
    font-weight: 600;
    color: #333;
    cursor: pointer;
}

.dropdown-menu button:hover {
    background: #f0f7fa;
    color: var(--primary);
}

.dropdown-menu button:disabled {
    color: #999;
    cursor: not-allowed;
}

.dropdown-menu button:disabled:hover {
    background: none;
    color: #999;
}

.dropdown-submenu-wrap {
    position: relative;
}

.dropdown-submenu-toggle {
    display: block;
    width: 100%;
    text-align: left;
    background: none;
    border: none;
    padding: 12px 18px;
    font-size: 15px;
    font-weight: 600;
    color: #333;
    cursor: pointer;
}

.dropdown-submenu-toggle:hover {
    background: #f0f7fa;
    color: var(--primary);
}

.dropdown-menu--nested {
    right: calc(100% + 4px);
    left: auto;
    top: 0;
    min-width: 220px;
}

.dropdown-menu .dropdown-menu-sep {
    height: 1px;
    margin: 6px 0;
    background: #e5e7eb;
    border: none;
    padding: 0;
}

.modal-backdrop {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.35);
    z-index: 900;
}

/* РјРѕРґР°Р»РєРё РїРѕРІРµСЂС… С„РѕРЅР° (account.css Р·Р°РґР°С‘С‚ z-index 1000) */
.modal {
    z-index: 1000;
}

/* РґРµСЂРµРІРѕ РІС‹Р±РѕСЂР° РјРѕРґРµР»Рё РїСЂРёР±РѕСЂР° РЅР° РіР»Р°РІРЅРѕР№ */
#treeModelsModal.modal-overlay {
    z-index: 1200;
}

#treeModelsModal .modal-window--tree {
    max-width: 560px;
    width: 90%;
    max-height: 80vh;
    display: flex;
    flex-direction: column;
    padding: 0;
}

#treeModelsModal .modal-body {
    min-height: 280px;
    max-height: 50vh;
    overflow: auto;
}

#copyToLibModal.modal-overlay,
#moveLibModal.modal-overlay {
    z-index: 1200;
}

#copyToLibModal .modal-window--copy-to-lib,
#moveLibModal .modal-window--copy-to-lib {
    max-width: 920px;
    width: 94%;
    max-height: 85vh;
    height: 85vh;
    display: flex;
    flex-direction: column;
    padding: 0;
    position: relative;
    top: auto;
    left: auto;
    transform: none;
    overflow: hidden;
}

#copyToLibModal .modal-header,
#moveLibModal .modal-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    padding: 14px 16px;
    border-bottom: 1px solid #e5e7eb;
    flex-shrink: 0;
}

#copyToLibModal .modal-header h2,
#moveLibModal .modal-header h2 {
    margin: 0;
    font-size: 1.15rem;
}

#copyToLibModal .copy-to-lib-body,
#moveLibModal .copy-to-lib-body {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 0;
    flex: 1 1 auto;
    min-height: 0;
    overflow: hidden;
}

#copyToLibModal .copy-to-lib-pane,
#moveLibModal .copy-to-lib-pane {
    display: flex;
    flex-direction: column;
    min-width: 0;
    min-height: 0;
    height: 100%;
    overflow: hidden;
    border-right: 1px solid #e5e7eb;
}

#copyToLibModal .copy-to-lib-pane:last-child,
#moveLibModal .copy-to-lib-pane:last-child {
    border-right: none;
}

#copyToLibModal .copy-to-lib-pane__title,
#moveLibModal .copy-to-lib-pane__title {
    padding: 10px 14px;
    font-weight: 600;
    font-size: 0.92rem;
    background: #f8fafc;
    border-bottom: 1px solid #e5e7eb;
    flex-shrink: 0;
}

#copyToLibModal .copy-to-lib-tree,
#moveLibModal .copy-to-lib-tree {
    flex: 1 1 auto;
    min-height: 0;
    overflow-x: hidden;
    overflow-y: auto;
    padding: 8px 10px;
    -webkit-overflow-scrolling: touch;
}

#copyToLibModal .copy-to-lib-dest-actions,
#moveLibModal .copy-to-lib-dest-actions {
    padding: 8px 12px 12px;
    border-top: 1px solid #e5e7eb;
    flex-shrink: 0;
}

#copyToLibModal .copy-to-lib-status,
#moveLibModal .copy-to-lib-status {
    padding: 8px 16px;
    font-size: 0.88rem;
    color: #4b5563;
    border-top: 1px solid #e5e7eb;
    min-height: 1.4em;
    flex-shrink: 0;
}

#copyToLibModal .modal-footer.buttons,
#moveLibModal .modal-footer.buttons {
    flex-wrap: wrap;
    justify-content: center;
    padding: 12px 16px 16px;
    flex-shrink: 0;
}

#copyToLibModal .tree-children,
#moveLibModal .tree-children {
    display: block;
    margin-left: 16px;
}

#copyToLibModal .tree-item.selected,
#moveLibModal .tree-item.selected {
    background: #dbeafe;
}

#copyToLibModal .tree-item.is-folder,
#moveLibModal .tree-item.is-folder {
    font-weight: 600;
}

#copyToLibModal .btn-close,
#moveLibModal .btn-close {
    border: none;
    background: transparent;
    color: inherit;
    font-size: 1.25rem;
    line-height: 1;
    cursor: pointer;
    padding: 4px 8px;
}

@media (max-width: 720px) {
    #copyToLibModal .modal-window--copy-to-lib,
    #moveLibModal .modal-window--copy-to-lib {
        height: 90vh;
        max-height: 90vh;
    }

    #copyToLibModal .copy-to-lib-body,
    #moveLibModal .copy-to-lib-body {
        grid-template-columns: 1fr;
        overflow-y: auto;
    }

    #copyToLibModal .copy-to-lib-pane,
    #moveLibModal .copy-to-lib-pane {
        border-right: none;
        border-bottom: 1px solid #e5e7eb;
        min-height: 220px;
        max-height: 40vh;
        height: auto;
    }
}

#treeModelsModal .modal-footer.buttons {
    flex-wrap: wrap;
    justify-content: center;
}

@media (max-width: 768px) {
    .top-bar {
        flex-direction: column;
        gap: 12px;
        align-items: stretch;
    }

    .top-actions {
        flex-wrap: wrap;
        justify-content: flex-end;
    }

    .session-label {
        white-space: normal;
    }
}


