/* === COMPARISON (H2H) CARD STYLES === */

.compare-card {
    background: #1e293b;
    border: 1px solid #334155;
    border-radius: 16px;
    overflow: hidden;
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.5);
    font-family: 'Montserrat', sans-serif;
    max-width: 500px; /* Трохи ширше для таблиці */
    margin: 0 auto;
}

/* --- 1. PLAYERS HEADER --- */
.cmp-players {
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: linear-gradient(to bottom, #0f172a, #1e293b);
    padding: 20px;
    border-bottom: 1px solid #334155;
    position: relative;
}

.player-col {
    display: flex;
    align-items: center;
    gap: 12px;
    width: 45%;
}

.p-red { justify-content: flex-end; }

.p-avatar {
    width: 50px; height: 50px;
    background: #334155;
    border-radius: 50%;
    position: relative;
    display: flex; align-items: center; justify-content: center;
    font-weight: 800; color: #cbd5e1;
    border: 2px solid #475569;
}

/* Dynamic Borders */
.p-blue .p-avatar { border-color: #3b82f6; box-shadow: 0 0 10px rgba(59, 130, 246, 0.3); }
.p-red .p-avatar { border-color: #ef4444; box-shadow: 0 0 10px rgba(239, 68, 68, 0.3); }

.p-ovr {
    position: absolute; bottom: -5px; right: -5px;
    width: 20px; height: 20px;
    border-radius: 50%;
    background: #fff; color: #000;
    font-size: 10px; font-weight: 800;
    display: flex; align-items: center; justify-content: center;
    border: 2px solid #1e293b;
}

.p-name { display: block; font-size: 0.9rem; font-weight: 700; color: #fff; line-height: 1.2; }
.p-pos { display: block; font-size: 0.7rem; color: #94a3b8; }
.right-align { text-align: right; }

.vs-badge {
    position: absolute;
    left: 50%; top: 50%; transform: translate(-50%, -50%);
    background: #0f172a;
    border: 1px solid #334155;
    color: #94a3b8;
    font-weight: 900; font-style: italic; font-size: 0.8rem;
    padding: 5px 8px;
    border-radius: 8px;
    z-index: 2;
}

/* --- 2. SPLIT CONTENT --- */
.cmp-content {
    display: flex;
    padding: 20px;
    gap: 20px;
}

/* Left: Radar Zone */
.cmp-radar-zone {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
}

.cmp-svg {
    width: 140px; height: 140px;
    overflow: visible;
}

.c-grid { fill: none; stroke: #334155; stroke-width: 0.5; }
.c-axis { stroke: #334155; stroke-width: 0.5; }
.c-lbl { font-size: 8px; fill: #64748b; font-weight: 700; text-anchor: middle; dominant-baseline: middle; }

/* Comparison Shapes */
.shape-a { fill: rgba(59, 130, 246, 0.3); stroke: #3b82f6; stroke-width: 2; } /* Blue */
.shape-b { fill: rgba(239, 68, 68, 0.3); stroke: #ef4444; stroke-width: 2; } /* Red */

.radar-legend {
    margin-top: 10px;
    display: flex; flex-direction: column; gap: 4px;
}
.radar-legend span { font-size: 0.7rem; color: #cbd5e1; display: flex; align-items: center; gap: 5px; }
.dot { width: 6px; height: 6px; border-radius: 50%; }
.dot.blue { background: #3b82f6; }
.dot.red { background: #ef4444; }


/* Right: Stats Table */
.cmp-stats-table {
    flex: 1.5; /* Takes more space than radar */
    display: flex;
    flex-direction: column;
    gap: 15px;
    justify-content: center;
}

.stat-row {
    background: rgba(255,255,255,0.02);
    border-radius: 8px;
    padding: 8px;
}

.s-label {
    font-size: 0.7rem; color: #94a3b8; text-transform: uppercase; margin-bottom: 4px; font-weight: 600;
}

.s-data {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 0.85rem;
    font-weight: 700;
    color: #cbd5e1;
    margin-bottom: 6px;
}

.val-a { color: #3b82f6; } /* Blue Text */
.val-b { color: #ef4444; } /* Red Text */
.val-a.win { text-shadow: 0 0 5px rgba(59, 130, 246, 0.5); font-weight: 800; }
.val-b.win { text-shadow: 0 0 5px rgba(239, 68, 68, 0.5); font-weight: 800; }


/* DIFF BADGE */
.diff-badge {
    font-size: 0.7rem;
    padding: 1px 5px;
    border-radius: 4px;
    font-weight: 700;
}
.diff-badge.positive {
    background: rgba(34, 197, 94, 0.2); color: #4ade80; /* Green */
}
.diff-badge.negative {
    background: rgba(239, 68, 68, 0.2); color: #f87171; /* Red */
}

/* Comparison Bars */
.s-bar-group {
    display: flex; flex-direction: column; gap: 2px;
}
.s-bar { height: 4px; border-radius: 2px; opacity: 0.8; }
.s-bar.blue { background: #3b82f6; }
.s-bar.red { background: #ef4444; }

/* Mobile */
@media (max-width: 768px) {
    .cmp-content { flex-direction: column; }
    .cmp-stats-table { width: 100%; }
}