:root {
    --bg-page: #060B16;
    --accent-blue: #2563EB;
    --light-blue: #60a5fa;
    --text-main: #CBD5E1;
    --glass: rgba(255, 255, 255, 0.02);
    --glass-border: rgba(255, 255, 255, 0.08);
}

body {
    background-color: var(--bg-page);
    color: var(--text-main);
    font-family: 'Montserrat', sans-serif;
    margin: 0;
    overflow-x: hidden;
}

/* Фон с анимацией свечения */
.bg-visual {
    position: fixed;
    top: 0; left: 0; width: 100%; height: 100%;
    background: radial-gradient(circle at 50% -20%, rgba(37, 99, 235, 0.15) 0%, transparent 60%);
    z-index: -1;
}

/* ФИРМЕННАЯ КНОПКА (КАК В НОВОСТЯХ) */
.back-btn {
    position: absolute;
    top: 30px;
    left: 30px;
    z-index: 100;
    color: #fff;
    text-decoration: none;
    font-weight: 700;
    text-transform: uppercase;
    font-size: 0.75rem;
    letter-spacing: 2px;
    background: rgba(37, 99, 235, 0.1);
    padding: 12px 24px;
    border: 1px solid var(--accent-blue);
    border-radius: 4px;
    transition: 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.back-btn:hover {
    background: var(--accent-blue);
    box-shadow: 0 0 25px rgba(37, 99, 235, 0.5);
    transform: scale(1.05);
}

header { padding: 100px 20px 40px; text-align: center; }
header h1 { 
    font-family: 'Orbitron'; font-size: 3.5rem; letter-spacing: 12px; color: #fff; margin: 0;
}
.subtitle { color: var(--accent-blue); letter-spacing: 4px; font-weight: bold; margin-top: 10px; }

/* СЕТКА С АНИМАЦИЕЙ КАСКАДА */
.org-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 40px;
    max-width: 1200px;
    margin: 0 auto 100px;
    padding: 20px;
}

.org-card {
    background: var(--glass);
    border: 1px solid var(--glass-border);
    border-radius: 20px;
    aspect-ratio: 1/1;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    position: relative;
    overflow: hidden;
    backdrop-filter: blur(10px);
    transition: all 0.5s cubic-bezier(0.23, 1, 0.32, 1);
    opacity: 0;
    transform: translateY(50px);
}

/* Класс для анимации через JS */
.org-card.show {
    opacity: 1;
    transform: translateY(0);
}

.org-card:hover {
    transform: translateY(-15px) scale(1.03);
    border-color: var(--accent-blue);
    background: rgba(37, 99, 235, 0.05);
    box-shadow: 0 20px 40px rgba(0,0,0,0.6), 0 0 20px rgba(37, 99, 235, 0.2);
}

.rank-tag {
    position: absolute;
    top: 20px; left: 20px;
    font-family: 'Orbitron'; font-size: 2rem; color: rgba(255,255,255,0.05);
    transition: 0.3s;
}

.org-card:hover .rank-tag { color: var(--accent-blue); opacity: 0.3; }

.card-logo {
    width: 120px; height: 120px;
    background-size: contain; background-repeat: no-repeat; background-position: center;
    margin-bottom: 15px;
    transition: 0.6s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

.org-card:hover .card-logo { transform: scale(1.1) rotate(5deg); }

.card-name { font-family: 'Orbitron'; color: #fff; font-size: 1.1rem; letter-spacing: 2px; }

/* Индикатор влияния */
.influence-bar {
    position: absolute; bottom: 0; left: 0; width: 100%; height: 4px;
    background: rgba(255,255,255,0.05);
}
.influence-fill {
    height: 100%; background: var(--accent-blue); width: 0;
    transition: width 1.5s ease;
    box-shadow: 0 0 10px var(--accent-blue);
}

/* МОДАЛЬНОЕ ОКНО */
.modal-overlay {
    position: fixed; top: 0; left: 0; width: 100%; height: 100%;
    background: rgba(0,0,0,0.9); backdrop-filter: blur(20px);
    display: none; align-items: center; justify-content: center; z-index: 1000;
}

.modal-window {
    background: #0a0f1d; border: 1px solid var(--accent-blue); border-radius: 30px;
    width: 90%; max-width: 450px; padding: 50px 40px; text-align: center;
    animation: modalIn 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

@keyframes modalIn { from { opacity: 0; transform: scale(0.8); } to { opacity: 1; transform: scale(1); } }

.modal-rank-badge {
    background: var(--accent-blue); color: #fff; padding: 5px 15px; border-radius: 5px;
    display: inline-block; font-family: 'Orbitron'; font-size: 0.8rem; margin: 15px 0;
}

.ds-link {
    display: block; margin-top: 30px; padding: 15px;
    border: 1px solid var(--accent-blue); color: #fff; text-decoration: none;
    font-family: 'Orbitron'; font-size: 0.8rem; transition: 0.3s;
}

.ds-link:hover { background: var(--accent-blue); box-shadow: 0 0 20px rgba(37, 99, 235, 0.4); }

.modal-close {
    position: absolute; top: 20px; right: 20px; background: none; border: none;
    color: #fff; font-size: 2rem; cursor: pointer; opacity: 0.5;
}
.modal-close:hover { opacity: 1; }

