/* core/userProfileModal.css — modal profilu / zmiana hasła */

.user-profile-modal {
    position: fixed;
    inset: 0;
    z-index: 120000;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 16px;
    background: rgba(4, 12, 28, 0.72);
    backdrop-filter: blur(4px);
}

.user-profile-modal.hidden {
    display: none;
}

.user-profile-modal__panel {
    width: min(420px, 100%);
    border-radius: 12px;
    border: 1px solid rgba(120, 180, 255, 0.35);
    background: linear-gradient(165deg, rgba(18, 42, 92, 0.98), rgba(10, 24, 52, 0.98));
    box-shadow: 0 18px 48px rgba(0, 0, 0, 0.45);
    color: #e8f2ff;
}

.user-profile-modal__head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    padding: 14px 16px 10px;
    border-bottom: 1px solid rgba(120, 180, 255, 0.2);
}

.user-profile-modal__head h2 {
    margin: 0;
    font-size: 1.05rem;
    font-weight: 700;
    letter-spacing: 0.04em;
}

.user-profile-modal__alert {
    margin: 12px 16px 0;
    padding: 10px 12px;
    border-radius: 8px;
    font-size: 0.9rem;
    line-height: 1.4;
}

.user-profile-modal__alert.hidden {
    display: none;
}

.user-profile-modal__alert.is-err {
    background: rgba(180, 40, 60, 0.25);
    border: 1px solid rgba(255, 120, 140, 0.45);
    color: #ffd6dc;
}

.user-profile-modal__alert.is-ok {
    background: rgba(30, 120, 70, 0.28);
    border: 1px solid rgba(120, 255, 170, 0.4);
    color: #d8ffe8;
}

.user-profile-modal__body {
    display: flex;
    flex-direction: column;
    gap: 6px;
    padding: 14px 16px 8px;
}

.user-profile-modal__body label {
    margin-top: 8px;
    font-size: 0.78rem;
    font-weight: 600;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    color: rgba(200, 225, 255, 0.85);
}

.user-profile-inp {
    width: 100%;
    box-sizing: border-box;
    padding: 10px 12px;
    border-radius: 8px;
    border: 1px solid rgba(120, 170, 255, 0.35);
    background: rgba(8, 20, 45, 0.85);
    color: #f0f7ff;
    font-size: 0.95rem;
}

.user-profile-inp:focus {
    outline: none;
    border-color: rgba(130, 200, 255, 0.85);
    box-shadow: 0 0 0 2px rgba(80, 160, 255, 0.25);
}

.user-profile-inp--readonly {
    opacity: 0.85;
    cursor: default;
}

.user-profile-pass-wrap {
    position: relative;
    width: 100%;
}

.user-profile-pass-wrap .user-profile-inp {
    width: 100%;
    padding-right: 44px;
}

.user-profile-pass-toggle {
    position: absolute;
    right: 6px;
    top: 50%;
    transform: translateY(-50%);
    width: 32px;
    height: 32px;
    padding: 0;
    border: none;
    border-radius: 6px;
    background: transparent;
    color: rgba(200, 225, 255, 0.78);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
}

.user-profile-pass-toggle:hover {
    color: #fff;
    background: rgba(255, 255, 255, 0.08);
}

.user-profile-pass-icon {
    width: 20px;
    height: 20px;
    display: block;
}

.user-profile-pass-icon--hide {
    display: none;
}

.user-profile-pass-toggle.is-visible .user-profile-pass-icon--show {
    display: none;
}

.user-profile-pass-toggle.is-visible .user-profile-pass-icon--hide {
    display: block;
}

.user-profile-modal__body--locked .user-profile-pass-toggle {
    pointer-events: none;
    opacity: 0.45;
}

.user-profile-modal__body--locked .user-profile-inp:not(.user-profile-inp--readonly) {
    opacity: 0.45;
    pointer-events: none;
}

.user-profile-modal__foot {
    display: flex;
    justify-content: flex-end;
    gap: 10px;
    padding: 12px 16px 16px;
}

.user-profile-modal__foot--send-docs {
    flex-wrap: wrap;
    align-items: center;
}

.user-profile-modal__foot--send-docs .tb-btn--ghost {
    opacity: 0.92;
    border-color: rgba(120, 180, 255, 0.28);
}

#user-send-docs-share {
    font-weight: 700;
    letter-spacing: 0.03em;
}

.user-profile-modal__panel--menu {
    width: min(360px, 100%);
}

.user-profile-modal__panel--wide {
    width: min(560px, 100%);
}

.user-profile-menu__body {
    display: flex;
    flex-direction: column;
    gap: 12px;
    padding: 20px 16px 8px;
}

.user-profile-menu-btn {
    width: 100%;
    padding: 14px 16px;
    border-radius: 10px;
    border: 1px solid rgba(120, 180, 255, 0.35);
    background: rgba(8, 24, 52, 0.9);
    color: #e8f2ff;
    font-size: 0.95rem;
    font-weight: 700;
    letter-spacing: 0.06em;
    cursor: pointer;
    text-align: center;
    transition: background 0.15s, border-color 0.15s, transform 0.1s;
}

.user-profile-menu-btn:hover {
    background: rgba(20, 48, 96, 0.95);
    border-color: rgba(140, 200, 255, 0.6);
}

.user-profile-menu-btn:active {
    transform: scale(0.98);
}

.user-profile-menu-btn--accent {
    border-color: rgba(120, 255, 170, 0.45);
    background: rgba(20, 70, 45, 0.55);
}

.user-profile-menu-btn--accent:hover {
    background: rgba(28, 95, 58, 0.72);
    border-color: rgba(140, 255, 190, 0.65);
}

.user-send-docs-hint {
    margin: 12px 16px 0;
    font-size: 0.85rem;
    line-height: 1.45;
    color: rgba(200, 225, 255, 0.82);
}

.user-send-docs-prepared {
    margin: 10px 16px 0;
    padding: 10px 12px;
    border-radius: 8px;
    border: 1px solid rgba(120, 255, 170, 0.35);
    background: rgba(20, 70, 45, 0.35);
}

.user-send-docs-prepared.hidden {
    display: none;
}

.user-send-docs-prepared.is-loading {
    border-color: rgba(120, 180, 255, 0.4);
    background: rgba(8, 24, 52, 0.55);
}

.user-send-docs-progress {
    height: 8px;
    border-radius: 999px;
    overflow: hidden;
    background: rgba(255, 255, 255, 0.08);
    margin-bottom: 8px;
}

.user-send-docs-progress-bar {
    height: 100%;
    width: 0;
    border-radius: inherit;
    background: linear-gradient(90deg, rgba(80, 180, 255, 0.95), rgba(120, 255, 190, 0.95));
    transition: width 0.2s ease;
}

.user-send-docs-loading-file {
    margin: 0;
    font-size: 0.78rem;
    color: rgba(200, 225, 255, 0.82);
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.user-send-docs-prepared-title {
    margin: 0 0 8px;
    font-size: 0.82rem;
    font-weight: 700;
    letter-spacing: 0.04em;
    color: rgba(200, 255, 220, 0.95);
}

.user-send-docs-prepared-list {
    margin: 0;
    padding-left: 18px;
    font-size: 0.8rem;
    color: rgba(210, 235, 255, 0.88);
    max-height: 120px;
    overflow-y: auto;
}

.user-send-docs-prepared-list li {
    margin: 2px 0;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.user-send-docs-list {
    display: flex;
    flex-direction: column;
    gap: 8px;
    max-height: min(52vh, 420px);
    overflow-y: auto;
    margin: 14px 16px 4px;
    padding: 4px 2px;
}

.user-send-docs-item {
    display: grid;
    grid-template-columns: auto 1fr;
    grid-template-rows: auto auto;
    gap: 2px 10px;
    align-items: center;
    padding: 10px 12px;
    border-radius: 8px;
    border: 1px solid rgba(120, 170, 255, 0.22);
    background: rgba(6, 16, 38, 0.75);
    cursor: pointer;
}

.user-send-docs-item:hover {
    border-color: rgba(130, 200, 255, 0.45);
    background: rgba(10, 26, 58, 0.85);
}

.user-send-docs-item input[type="checkbox"] {
    grid-row: 1 / span 2;
    width: 18px;
    height: 18px;
    accent-color: #3ecf7a;
    cursor: pointer;
}

.user-send-docs-item-label {
    font-weight: 700;
    font-size: 0.88rem;
    letter-spacing: 0.04em;
}

.user-send-docs-item-file {
    grid-column: 2;
    font-size: 0.78rem;
    color: rgba(180, 210, 255, 0.72);
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.user-send-docs-empty {
    margin: 0;
    padding: 16px 12px;
    text-align: center;
    font-size: 0.9rem;
    color: rgba(200, 220, 255, 0.75);
}

.user-profile-modal__foot .hidden {
    display: none;
}

#topbar .topbar-profile-btn,
body.module-toolbar-green #topbar .topbar-profile-btn {
    margin-right: 8px;
    min-width: 72px;
    font-weight: 700;
    letter-spacing: 0.05em;
    background: #1a1a1a;
    border: 1px solid #333;
    color: #fff;
    box-shadow:
        0 0 6px rgba(0, 0, 0, 0.5),
        inset 0 0 4px rgba(255, 255, 255, 0.08);
}

#topbar .topbar-profile-btn:hover,
body.module-toolbar-green #topbar .topbar-profile-btn:hover {
    background: #2d2d2d;
    border-color: #444;
    color: #fff;
    box-shadow:
        0 0 10px rgba(0, 0, 0, 0.65),
        inset 0 0 6px rgba(255, 255, 255, 0.12);
}

#topbar .topbar-profile-btn:active,
body.module-toolbar-green #topbar .topbar-profile-btn:active {
    background: #0d0d0d;
    border-color: #333;
    color: #fff;
    transform: scale(0.96);
}

#topbar .topbar-right {
    display: flex;
    align-items: center;
    flex-shrink: 0;
    margin-left: auto;
}
