﻿
/* ============================================================
   Partner Modal Fixes â€” modal-close, modal-footer, form-grid
   ============================================================ */

.modal-close {
    background: none;
    border: none;
    color: var(--text-secondary);
    font-size: 1.4rem;
    cursor: pointer;
    padding: 4px 8px;
    border-radius: 6px;
    transition: color 0.2s, background 0.2s;
    line-height: 1;
}

.modal-close:hover {
    color: #ef4444;
    background: rgba(239, 68, 68, 0.1);
}

.modal-footer {
    display: flex;
    justify-content: flex-end;
    gap: 10px;
    padding-top: 16px;
    border-top: 1px solid var(--glass-border);
    margin-top: 8px;
}

.form-grid {
    display: grid;
    gap: 12px;
}

/* Partner modal content max-height scroll */
#partnerModal .modal-content,
#partnerDetailModal .modal-content {
    max-height: 90vh;
    overflow-y: auto;
}

/* Select fix dark mode for partner modals */
#partnerModal select option,
#partnerDetailModal select option {
    background: #1a1d2e;
    color: #e5e7eb;
}
/* Toggle Company Card */
.company-toggle-card {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 8px 12px;
    border-radius: 8px;
    border: 1px solid rgba(255,255,255,0.1);
    background: rgba(255,255,255,0.04);
    cursor: pointer;
    transition: all 0.2s;
    user-select: none;
}
.company-toggle-card:hover {
    background: rgba(255,255,255,0.08);
}


/* ============================================================
   Vertical Tree (Collapsible Folder Style) for Partner Tree
   ============================================================ */
.vertical-tree, .vt-children {
    list-style: none;
    padding-left: 20px;
    margin: 0;
}
.vertical-tree {
    padding-left: 0;
    width: 100%;
}
.vt-li {
    margin-bottom: 5px;
}
.vt-node {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 10px 15px;
    border: 1px solid var(--glass-border);
    border-radius: 8px;
    background: rgba(30, 41, 59, 0.6);
    cursor: pointer;
    transition: all 0.2s;
    user-select: none;
}
.vt-node:hover {
    background: rgba(51, 65, 85, 0.8);
    border-color: var(--accent-primary);
}
.vt-info {
    display: flex;
    align-items: center;
    gap: 12px;
}
.vt-toggle-icon {
    width: 20px;
    display: inline-block;
    color: var(--text-secondary);
}
.vt-node.has-children .vt-toggle-icon {
    color: var(--accent-primary);
}
.vt-name {
    font-weight: 600;
    font-size: 1rem;
    color: var(--text-primary);
    min-width: 150px;
}
.vt-rank {
    font-size: 0.8rem;
    color: #cbd5e1;
    background: rgba(0,0,0,0.3);
    padding: 3px 8px;
    border-radius: 4px;
}
.vt-stats {
    font-size: 0.85rem;
    color: #10b981;
    font-weight: 500;
    display: flex;
    align-items: center;
    gap: 4px;
}
.vt-btn-detail {
    background: rgba(99, 102, 241, 0.15);
    border: 1px solid rgba(99, 102, 241, 0.3);
    color: #818cf8;
    padding: 6px 12px;
    border-radius: 6px;
    transition: all 0.2s;
}
.vt-btn-detail:hover {
    background: rgba(99, 102, 241, 0.3);
    color: #fff;
}
.vt-children {
    display: none;
    border-left: 1px dashed rgba(255,255,255,0.2);
    margin-left: 24px;
    padding-top: 5px;
}
.vt-li.expanded > .vt-children {
    display: block;
}

