/* ==========================================================================
   PROFIL-HEADER: FARBIGES DISTRIKT-BADGE (STATT STERNE)
   ========================================================================== */

.id-district-badge {
    --badge-color: var(--capitol-cyan);
    display: inline-flex;
    align-items: center;
    gap: 6px;
    font-family: 'Rajdhani', sans-serif;
    font-size: 12px;
    font-weight: 700;
    letter-spacing: 1.5px;
    text-transform: uppercase;
    color: var(--badge-color);
    background: rgba(5, 8, 13, 0.85);
    border: 1px solid var(--badge-color);
    border-left: 3px solid var(--badge-color);
    padding: 2px 12px 2px 9px;
    clip-path: polygon(0 0, calc(100% - 7px) 0, 100% 7px, 100% 100%, 7px 100%, 0 calc(100% - 7px));
    box-shadow: 0 0 12px rgba(0, 240, 255, 0.18);
}

/* Automatische Sektor-Farben je nach Profilfeld-Wert */
.id-district-badge[data-district*="Kapitol" i] { --badge-color: #ffb703; box-shadow: 0 0 12px rgba(255, 183, 3, 0.25); }
.id-district-badge[data-district*="Distrikt 1"]          { --badge-color: #e879f9; box-shadow: 0 0 12px rgba(232, 121, 249, 0.25); }
.id-district-badge[data-district*="Distrikt 2"]          { --badge-color: #f97316; box-shadow: 0 0 12px rgba(249, 115, 22, 0.25); }
.id-district-badge[data-district*="Distrikt 3"]          { --badge-color: #00f0ff; box-shadow: 0 0 12px rgba(0, 240, 255, 0.25); }
.id-district-badge[data-district*="Distrikt 4"]          { --badge-color: #0ea5e9; box-shadow: 0 0 12px rgba(14, 165, 233, 0.25); }
.id-district-badge[data-district*="Distrikt 5"]          { --badge-color: #facc15; box-shadow: 0 0 12px rgba(250, 204, 21, 0.25); }
.id-district-badge[data-district*="Distrikt 6"]          { --badge-color: #818cf8; box-shadow: 0 0 12px rgba(129, 140, 248, 0.25); }
.id-district-badge[data-district*="Distrikt 7"]          { --badge-color: #10b981; box-shadow: 0 0 12px rgba(16, 185, 129, 0.25); }
.id-district-badge[data-district*="Distrikt 8"]          { --badge-color: #fb7185; box-shadow: 0 0 12px rgba(251, 113, 133, 0.25); }
.id-district-badge[data-district*="Distrikt 9"]          { --badge-color: #eab308; box-shadow: 0 0 12px rgba(234, 179, 8, 0.25); }
.id-district-badge[data-district*="Distrikt 10"]         { --badge-color: #d97706; box-shadow: 0 0 12px rgba(217, 119, 6, 0.25); }
.id-district-badge[data-district*="Distrikt 11"]         { --badge-color: #84cc16; box-shadow: 0 0 12px rgba(132, 204, 22, 0.25); }
.id-district-badge[data-district*="Distrikt 12"]         { --badge-color: #ef4444; box-shadow: 0 0 12px rgba(239, 68, 68, 0.25); }
.id-district-badge[data-district*="Distrikt 13"]         { --badge-color: #22c55e; box-shadow: 0 0 12px rgba(34, 197, 94, 0.25); }

/* ==========================================================================
   MEMBER PROFILE (CITIZEN DOSSIER & ZUSÄTZLICHE INFORMATIONEN HUD)
   ========================================================================== */

.capitol-profile-wrapper {
    display: flex;
    flex-direction: column;
    gap: 18px;
}

/* 1. Obere ID-Karte */
.capitol-id-header {
    display: flex;
    align-items: center;
    gap: 22px;
    background: linear-gradient(135deg, rgba(13, 19, 29, 0.96) 0%, rgba(7, 11, 18, 0.98) 100%);
    border: 1px solid rgba(0, 240, 255, 0.28);
    border-left: 4px solid var(--capitol-cyan);
    padding: 20px 24px;
    position: relative;
    clip-path: polygon(0 0, calc(100% - 16px) 0, 100% 16px, 100% 100%, 16px 100%, 0 calc(100% - 16px));
    box-shadow: 0 6px 25px rgba(0, 0, 0, 0.55);
}

.id-avatar-frame {
    width: 110px;
    height: 110px;
    min-width: 110px;
    border: 1px solid var(--capitol-cyan);
    background: rgba(0, 240, 255, 0.05);
    padding: 3px;
    clip-path: polygon(10px 0, 100% 0, 100% calc(100% - 10px), calc(100% - 10px) 100%, 0 100%, 0 10px);
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    box-shadow: 0 0 15px rgba(0, 240, 255, 0.2);
}

.id-avatar-frame img {
    width: 100% !important;
    height: 100% !important;
    object-fit: cover !important;
    object-position: center top !important;
    display: block !important;
}

.id-main-meta {
    flex: 1;
    min-width: 0;
}

.id-top-tag {
    font-family: 'Rajdhani', monospace, sans-serif;
    font-size: 11px;
    font-weight: 700;
    letter-spacing: 2px;
    color: var(--capitol-gold);
    margin-bottom: 4px;
}

.id-username {
    margin: 0 0 4px 0 !important;
    font-family: 'Rajdhani', sans-serif !important;
    font-size: 28px !important;
    font-weight: 800 !important;
    letter-spacing: 1px !important;
    text-transform: uppercase !important;
    color: #f8fafc !important;
}

.id-subline {
    display: flex;
    align-items: center;
    gap: 10px;
    flex-wrap: wrap;
    font-size: 12.5px;
    color: var(--text-muted);
    margin-bottom: 12px;
}

.id-quick-pills {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.id-pill {
    background: rgba(5, 8, 13, 0.78);
    border: 1px solid rgba(0, 240, 255, 0.18);
    padding: 4px 10px;
    font-size: 11.5px;
    color: #cbd5e1;
}

.id-pill strong {
    color: var(--capitol-cyan);
    font-family: 'Rajdhani', sans-serif;
    letter-spacing: 0.6px;
    margin-right: 4px;
}

/* 2. 2-Spalten Grid (34% Links Metriken / 66% Rechts Zusätzliche Informationen) */
.capitol-profile-grid {
    display: grid;
    grid-template-columns: 340px 1fr;
    gap: 18px;
    align-items: start;
}

.profile-col-side,
.profile-col-main {
    display: flex;
    flex-direction: column;
    gap: 16px;
    min-width: 0;
}

/* 3. Zusätzliche Informationen (Profilfelder-Tabelle im Dossier-Look) */
.profile-dossier-fields table.tborder {
    width: 100% !important;
    border: 1px solid rgba(0, 240, 255, 0.22) !important;
    border-left: 3px solid var(--capitol-gold) !important;
    background: rgba(10, 15, 24, 0.95) !important;
}

.profile-dossier-fields td.thead {
    background: linear-gradient(90deg, rgba(255, 183, 3, 0.14) 0%, rgba(10, 15, 24, 0.98) 100%) !important;
    border-bottom: 1px solid rgba(255, 183, 3, 0.35) !important;
    color: var(--capitol-gold) !important;
    font-family: 'Rajdhani', sans-serif !important;
    letter-spacing: 1.5px !important;
    text-transform: uppercase !important;
}

.profile-dossier-fields tr:not(:first-child) {
    display: flex;
    flex-direction: column;
    padding: 10px 16px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.06);
    background: transparent !important;
}

.profile-dossier-fields tr:not(:first-child):hover {
    background: rgba(0, 240, 255, 0.03) !important;
}

/* Feldname (z. B. Spitzname, Distrikt, Beruf, Steckbrief) */
.profile-dossier-fields tr:not(:first-child) > td:first-child {
    width: 100% !important;
    background: transparent !important;
    border: none !important;
    padding: 0 0 4px 0 !important;
    font-family: 'Rajdhani', sans-serif !important;
    font-size: 11.5px !important;
    font-weight: 700 !important;
    letter-spacing: 1.2px !important;
    text-transform: uppercase !important;
    color: var(--capitol-cyan) !important;
}

/* Feldwert (Text / langer Steckbrief) */
.profile-dossier-fields tr:not(:first-child) > td:last-child {
    width: 100% !important;
    background: rgba(5, 8, 13, 0.55) !important;
    border: none !important;
    border-left: 2px solid rgba(0, 240, 255, 0.25) !important;
    padding: 7px 12px !important;
    font-size: 13px !important;
    line-height: 1.6 !important;
    color: #e2e8f0 !important;
    max-height: 280px;
    overflow-y: auto;
}

.profile-action-bar {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    justify-content: center;
}

@media (max-width: 900px) {
    .capitol-profile-grid {
        grid-template-columns: 1fr;
    }
    .capitol-id-header {
        flex-direction: column;
        text-align: center;
    }
    .id-quick-pills, .id-subline {
        justify-content: center;
    }
}

/* ==========================================================================
   PROFIL-HEADER: FARBIGES DISTRIKT-BADGE (STATT STERNE)
   ========================================================================== */

.id-district-badge {
    --badge-color: var(--capitol-cyan);
    display: inline-flex;
    align-items: center;
    gap: 6px;
    font-family: 'Rajdhani', sans-serif;
    font-size: 12px;
    font-weight: 700;
    letter-spacing: 1.5px;
    text-transform: uppercase;
    color: var(--badge-color);
    background: rgba(5, 8, 13, 0.85);
    border: 1px solid var(--badge-color);
    border-left: 3px solid var(--badge-color);
    padding: 2px 12px 2px 9px;
    clip-path: polygon(0 0, calc(100% - 7px) 0, 100% 7px, 100% 100%, 7px 100%, 0 calc(100% - 7px));
    box-shadow: 0 0 12px rgba(0, 240, 255, 0.18);
}

/* Automatische Sektor-Farben je nach Profilfeld-Wert */
.id-district-badge[data-district*="Kapitol" i] { --badge-color: #ffb703; box-shadow: 0 0 12px rgba(255, 183, 3, 0.25); }
.id-district-badge[data-district*="Distrikt 1"]          { --badge-color: #e879f9; box-shadow: 0 0 12px rgba(232, 121, 249, 0.25); }
.id-district-badge[data-district*="Distrikt 2"]          { --badge-color: #f97316; box-shadow: 0 0 12px rgba(249, 115, 22, 0.25); }
.id-district-badge[data-district*="Distrikt 3"]          { --badge-color: #00f0ff; box-shadow: 0 0 12px rgba(0, 240, 255, 0.25); }
.id-district-badge[data-district*="Distrikt 4"]          { --badge-color: #0ea5e9; box-shadow: 0 0 12px rgba(14, 165, 233, 0.25); }
.id-district-badge[data-district*="Distrikt 5"]          { --badge-color: #facc15; box-shadow: 0 0 12px rgba(250, 204, 21, 0.25); }
.id-district-badge[data-district*="Distrikt 6"]          { --badge-color: #818cf8; box-shadow: 0 0 12px rgba(129, 140, 248, 0.25); }
.id-district-badge[data-district*="Distrikt 7"]          { --badge-color: #10b981; box-shadow: 0 0 12px rgba(16, 185, 129, 0.25); }
.id-district-badge[data-district*="Distrikt 8"]          { --badge-color: #fb7185; box-shadow: 0 0 12px rgba(251, 113, 133, 0.25); }
.id-district-badge[data-district*="Distrikt 9"]          { --badge-color: #eab308; box-shadow: 0 0 12px rgba(234, 179, 8, 0.25); }
.id-district-badge[data-district*="Distrikt 10"]         { --badge-color: #d97706; box-shadow: 0 0 12px rgba(217, 119, 6, 0.25); }
.id-district-badge[data-district*="Distrikt 11"]         { --badge-color: #84cc16; box-shadow: 0 0 12px rgba(132, 204, 22, 0.25); }
.id-district-badge[data-district*="Distrikt 12"]         { --badge-color: #ef4444; box-shadow: 0 0 12px rgba(239, 68, 68, 0.25); }
.id-district-badge[data-district*="Distrikt 13"]         { --badge-color: #22c55e; box-shadow: 0 0 12px rgba(34, 197, 94, 0.25); }

/* ==========================================================================
   PROFIL TABS, KOMPAKTE SIDEBAR & GESPLITTETE CHARAKTER-AKTE
   ========================================================================== */

.capitol-profile-grid {
    grid-template-columns: 290px 1fr !important;
}

/* Linke Sidebar-Cards */
.hud-side-card {
    background: linear-gradient(135deg, rgba(13, 19, 29, 0.96) 0%, rgba(8, 12, 19, 0.98) 100%);
    border: 1px solid rgba(0, 240, 255, 0.2);
    border-left: 3px solid var(--capitol-cyan);
    padding: 14px 16px;
    clip-path: polygon(0 0, calc(100% - 10px) 0, 100% 10px, 100% 100%, 10px 100%, 0 calc(100% - 10px));
}

.hud-card-head {
    font-family: 'Rajdhani', sans-serif;
    font-size: 12px;
    font-weight: 700;
    letter-spacing: 1.5px;
    color: var(--capitol-gold);
    border-bottom: 1px solid rgba(255, 183, 3, 0.25);
    padding-bottom: 6px;
    margin-bottom: 12px;
}

.hud-stat-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 10px;
}

.hud-mini-stat {
    background: rgba(5, 8, 13, 0.75);
    border: 1px solid rgba(0, 240, 255, 0.16);
    padding: 10px 8px;
    text-align: center;
}

.hms-val {
    display: block;
    font-family: 'Rajdhani', sans-serif;
    font-size: 20px;
    font-weight: 800;
    color: var(--capitol-cyan);
}

.hms-lbl {
    display: block;
    font-size: 9.5px;
    letter-spacing: 1px;
    color: var(--text-muted);
    margin-top: 2px;
}

.hud-side-links {
    display: flex;
    flex-direction: column;
    gap: 5px;
    margin-top: 10px;
    font-size: 11.5px;
}

.hud-side-card table.tborder {
    border: none !important;
    background: transparent !important;
}

.hud-side-card td.thead {
    display: none !important;
}

.hud-side-card td.trow1,
.hud-side-card td.trow2 {
    background: transparent !important;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05) !important;
    padding: 6px 2px !important;
    font-size: 12px !important;
}

/* Tab-Leiste */
.capitol-tab-bar {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
    border-bottom: 1px solid rgba(0, 240, 255, 0.25);
    padding-bottom: 10px;
}

.capitol-tab-btn {
    background: rgba(8, 12, 19, 0.9);
    border: 1px solid rgba(0, 240, 255, 0.25);
    color: var(--text-muted);
    font-family: 'Rajdhani', sans-serif;
    font-size: 12.5px;
    font-weight: 700;
    letter-spacing: 1.2px;
    padding: 8px 16px;
    cursor: pointer;
    clip-path: polygon(6px 0, 100% 0, 100% calc(100% - 6px), calc(100% - 6px) 100%, 0 100%, 0 6px);
    transition: all 0.2s ease;
}

.capitol-tab-btn:hover {
    border-color: var(--capitol-cyan);
    color: #fff;
}

.capitol-tab-btn.active {
    background: rgba(0, 240, 255, 0.14);
    border-color: var(--capitol-cyan);
    color: var(--capitol-cyan);
    box-shadow: 0 0 12px rgba(0, 240, 255, 0.2);
}

.capitol-tab-panel {
    display: none;
    flex-direction: column;
    gap: 14px;
}

.capitol-tab-panel.active {
    display: flex;
}

/* Dossier Sektionen & Eckdaten-Raster */
.dossier-section-title {
    font-family: 'Rajdhani', monospace, sans-serif;
    font-size: 11.5px;
    font-weight: 700;
    letter-spacing: 1.5px;
    color: var(--capitol-gold);
}

.dossier-facts-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(210px, 1fr));
    gap: 10px;
}

.dossier-fact-box {
    background: rgba(10, 15, 24, 0.94);
    border: 1px solid rgba(0, 240, 255, 0.16);
    border-left: 2px solid var(--capitol-cyan);
    padding: 9px 12px;
}

.df-label {
    display: block;
    font-family: 'Rajdhani', sans-serif;
    font-size: 10px;
    font-weight: 700;
    letter-spacing: 1.2px;
    color: var(--text-muted);
    margin-bottom: 2px;
}

.df-value {
    display: block;
    font-size: 13px;
    font-weight: 600;
    color: #f1f5f9;
}

/* Lange Steckbrief-Blöcke */
.dossier-long-stack {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.dossier-text-card {
    background: rgba(10, 15, 24, 0.95);
    border: 1px solid rgba(0, 240, 255, 0.18);
    border-left: 3px solid var(--capitol-gold);
    padding: 14px 16px;
}

.dtc-head {
    font-family: 'Rajdhani', sans-serif;
    font-size: 12.5px;
    font-weight: 700;
    letter-spacing: 1.2px;
    color: var(--capitol-cyan);
    margin-bottom: 8px;
    padding-bottom: 5px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.06);
}

.dtc-body {
    font-size: 13px;
    line-height: 1.65;
    color: #dbe4f0;
    white-space: pre-line;
}


/* ==========================================================================
   OPERATOR & MEDIA BOX (LINKS) + KAPITOL-ÜBERWACHUNGSINDEX (RECHTS)
   ========================================================================== */

.hud-operator-card {
    border-left-color: var(--capitol-gold) !important;
}

.operator-meta-list {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.op-row {
    background: rgba(5, 8, 13, 0.72);
    border: 1px solid rgba(255, 255, 255, 0.06);
    padding: 7px 10px;
}

.op-lbl {
    display: block;
    font-family: 'Rajdhani', sans-serif;
    font-size: 9.5px;
    font-weight: 700;
    letter-spacing: 1.2px;
    color: var(--text-muted);
}

.op-val {
    display: block;
    font-size: 12.5px;
    font-weight: 600;
    color: #f1f5f9;
    margin-top: 1px;
}

.operator-media-links {
    display: flex;
    flex-direction: column;
    gap: 8px;
    margin-top: 10px;
}

.op-media-box {
    background: rgba(5, 8, 13, 0.85);
    border: 1px solid rgba(0, 240, 255, 0.22);
    padding: 8px 10px;
    font-size: 12px;
    word-break: break-word;
}

.op-media-tag {
    display: block;
    font-family: 'Rajdhani', sans-serif;
    font-size: 10px;
    font-weight: 700;
    letter-spacing: 1.2px;
    color: var(--capitol-cyan);
    margin-bottom: 3px;
}

.op-media-content a {
    color: var(--capitol-gold) !important;
    text-decoration: underline;
}

/* Kapitol-Überwachungsindex (Positiv / Neutral / Negativ farblich codiert) */
.dossier-stance-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 12px;
}

.stance-card {
    --stance-color: var(--capitol-cyan);
    background: linear-gradient(135deg, rgba(13, 19, 29, 0.96) 0%, rgba(7, 11, 18, 0.98) 100%);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-left: 4px solid var(--stance-color);
    padding: 12px 15px;
    clip-path: polygon(0 0, calc(100% - 10px) 0, 100% 10px, 100% 100%, 10px 100%, 0 calc(100% - 10px));
}

.stance-lbl {
    display: block;
    font-family: 'Rajdhani', sans-serif;
    font-size: 10.5px;
    font-weight: 700;
    letter-spacing: 1.2px;
    color: var(--text-muted);
    margin-bottom: 3px;
}

.stance-val {
    display: block;
    font-family: 'Rajdhani', sans-serif;
    font-size: 16px;
    font-weight: 800;
    letter-spacing: 0.8px;
    text-transform: uppercase;
    color: var(--stance-color);
}

.stance-card[data-stance="Positiv"] { --stance-color: #22c55e; }
.stance-card[data-stance="Neutral"] { --stance-color: #eab308; }
.stance-card[data-stance="Negativ"] { --stance-color: #ef4444; }