/* ===== Database Explorer — premium glass UI ===== */

#explorer-modal.modal {
    background: rgba(0, 0, 0, 0.82);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
}

#explorer-modal .modal-content {
    position: relative;
    width: 92%;
    max-width: 780px;
    background: linear-gradient(180deg, rgba(22,22,22,0.88), rgba(10,10,10,0.95));
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 18px;
    box-shadow:
        0 30px 90px rgba(0, 0, 0, 0.65),
        0 0 0 1px rgba(255, 255, 255, 0.03) inset;
    backdrop-filter: blur(24px) saturate(160%);
    -webkit-backdrop-filter: blur(24px) saturate(160%);
    animation: dbModalPop 0.45s cubic-bezier(0.16, 1, 0.3, 1);
}

@keyframes dbModalPop {
    from { opacity: 0; transform: translateY(14px) scale(0.97); }
    to { opacity: 1; transform: translateY(0) scale(1); }
}

/* Animated glowing border trail — same technique as the welcome modal */
#explorer-modal .modal-content::after {
    content: "";
    position: absolute;
    inset: -1px;
    border-radius: inherit;
    padding: 1px;
    background: conic-gradient(
        from var(--border-angle),
        transparent 0%,
        transparent 74%,
        rgba(255, 255, 255, 0.9) 87%,
        rgba(255, 255, 255, 0.35) 92%,
        transparent 100%
    );
    -webkit-mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0);
    -webkit-mask-composite: xor;
    mask-composite: exclude;
    pointer-events: none;
    z-index: 2;
    animation: borderTravel 4.5s linear infinite;
}

#explorer-modal .title-bar {
    background: rgba(255, 255, 255, 0.03);
    padding: 16px 22px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.07);
}

#explorer-modal .title-bar span {
    font-size: 0.95rem;
    font-weight: 500;
    letter-spacing: 0.5px;
    color: #e8e8e8;
    text-transform: uppercase;
}

#explorer-modal .close-btn {
    width: 32px;
    height: 32px;
    border-radius: 8px;
    color: #cfcfcf;
    font-size: 1.3rem;
    transition: background 0.2s ease, color 0.2s ease, transform 0.2s ease;
}

#explorer-modal .close-btn:hover {
    background: rgba(255, 255, 255, 0.08);
    color: #ffffff;
    transform: scale(1.05);
}

#explorer-modal .sidebar {
    background: rgba(255, 255, 255, 0.02);
    border-right: 1px solid rgba(255, 255, 255, 0.07);
    padding: 20px 16px;
}

#explorer-modal .sidebar p {
    color: #7a7a7a;
    font-size: 0.75rem;
    font-weight: 500;
    letter-spacing: 1.5px;
    text-transform: uppercase;
    margin-bottom: 14px;
}

#explorer-modal .sidebar input[type="text"] {
    background: rgba(255, 255, 255, 0.03) !important;
    border: 1px solid rgba(255, 255, 255, 0.08) !important;
    border-radius: 8px !important;
    color: #e5e5e5 !important;
    padding: 10px 12px !important;
    font-size: 0.85rem !important;
    transition: border-color 0.2s ease, background 0.2s ease;
}

#explorer-modal .sidebar input[type="text"]:focus {
    outline: none;
    border-color: rgba(255, 255, 255, 0.25) !important;
    background: rgba(255, 255, 255, 0.05) !important;
}

#explorer-modal .sidebar li {
    color: #b5b5b5;
    font-size: 0.9rem;
    padding: 10px 14px;
    margin-bottom: 2px;
    border-radius: 8px;
    cursor: pointer;
    transition: background 0.2s ease, color 0.2s ease;
}

#explorer-modal .sidebar li:hover {
    background: rgba(255, 255, 255, 0.05);
    color: #ffffff;
}

#explorer-modal .sidebar li.active {
    background: rgba(255, 255, 255, 0.09);
    color: #ffffff;
}

#explorer-modal .main-folder {
    background: transparent;
    padding: 28px;
}

#explorer-modal .folder-path {
    color: #7a7a7a;
    font-size: 0.85rem;
    letter-spacing: 0.3px;
    margin-bottom: 22px;
}

@media (max-width: 768px) {
    #explorer-modal .modal-content {
        width: 94%;
    }

    #explorer-modal .title-bar {
        padding: 14px 18px;
    }

    #explorer-modal .main-folder {
        padding: 20px;
    }
}
