:root {
    /* Colors - Deep & Vibrant */
    --bg-dark: #050508;
    --bg-panel: rgba(20, 20, 30, 0.4);
    --accent-cyan: #00f2ff;
    --accent-magenta: #ff00ea;
    --accent-green: #00ff88;
    --accent-yellow: #f4ff00;
    --text-main: #e0e0f0;
    --text-muted: #8888aa;
    --glass-border: rgba(255, 255, 255, 0.1);
    --shadow-neon: 0 0 20px rgba(0, 242, 255, 0.3);
    
    /* Transitions */
    --transition-slow: 0.5s cubic-bezier(0.4, 0, 0.2, 1);
    --transition-fast: 0.2s ease;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    cursor: default;
}

body {
    font-family: 'Inter', sans-serif;
    background-color: var(--bg-dark);
    color: var(--text-main);
    overflow: hidden;
    height: 100vh;
    width: 100vw;
}

#noise-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 200 200' xmlns='http://www.w3.org/2003/svg'%3E%3Cfilter id='noiseFilter'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.65' numOctaves='3' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23noiseFilter)'/%3E%3C/svg%3E");
    opacity: 0.05;
    pointer-events: none;
    z-index: 100;
}

/* Background Blurs */
.bg-blur {
    position: fixed;
    border-radius: 50%;
    filter: blur(100px);
    z-index: -1;
    opacity: 0.4;
    animation: drift 20s infinite alternate ease-in-out;
}

.blur-1 { width: 500px; height: 500px; background: var(--accent-cyan); top: -100px; left: -100px; }
.blur-2 { width: 600px; height: 600px; background: var(--accent-magenta); bottom: -200px; right: -100px; animation-delay: -5s; }
.blur-3 { width: 400px; height: 400px; background: var(--accent-green); top: 50%; left: 50%; opacity: 0.2; animation-delay: -10s; }

@keyframes drift {
    0% { transform: translate(0, 0) scale(1); }
    100% { transform: translate(50px, 100px) scale(1.1); }
}

/* App Container */
.app-container {
    display: flex;
    height: 100vh;
    padding: 20px;
    gap: 20px;
    position: relative;
    z-index: 1;
}

.glass {
    background: var(--bg-panel);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border: 1px solid var(--glass-border);
    border-radius: 24px;
    box-shadow: 0 8px 32px 0 rgba(0, 0, 0, 0.82);
}

.glass-inner {
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(255, 255, 255, 0.05);
    border-radius: 16px;
    padding: 20px;
}

/* Sidebar Styling */
.sidebar {
    width: 380px;
    display: flex;
    flex-direction: column;
    padding: 25px;
    flex-shrink: 0;
    overflow: hidden; /* Content inside will scroll */
}

.sidebar-content {
    flex-grow: 1;
    overflow-y: auto;
    padding-right: 10px;
}

.sidebar-footer {
    padding-top: 15px;
    border-top: 1px solid rgba(255, 255, 255, 0.05);
}

header {
    margin-bottom: 25px;
}

h1.glitch {
    font-family: 'Orbitron', sans-serif;
    font-size: 2.5rem;
    font-weight: 900;
    letter-spacing: 4px;
    color: var(--accent-cyan);
    position: relative;
    text-shadow: 0 0 10px rgba(0, 242, 255, 0.5);
}

.subtitle {
    font-size: 0.75rem;
    letter-spacing: 2px;
    color: var(--text-muted);
    text-transform: uppercase;
    margin-top: 5px;
}

.control-group {
    margin-bottom: 25px;
}

h3 {
    font-family: 'Orbitron', sans-serif;
    font-size: 0.9rem;
    text-transform: uppercase;
    letter-spacing: 1px;
    margin-bottom: 15px;
    color: var(--text-muted);
}

/* Product Grid (Campaigns) */
.product-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 10px;
}

.product-card {
    padding: 12px;
    font-size: 0.85rem;
    text-align: center;
    border-radius: 12px;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid transparent;
    transition: var(--transition-fast);
    cursor: pointer;
}

.product-card:hover {
    background: rgba(255, 255, 255, 0.1);
    border-color: var(--accent-cyan);
}

.product-card.active {
    background: var(--accent-cyan);
    color: var(--bg-dark);
    font-weight: bold;
    box-shadow: 0 0 15px var(--accent-cyan);
}

/* Filter Items */
.filter-item {
    margin-bottom: 20px;
}

.filter-item label {
    display: block;
    font-size: 0.8rem;
    margin-bottom: 8px;
    font-weight: 600;
}

.range-container {
    position: relative;
    height: 30px;
}

input[type="range"] {
    width: 100%;
    accent-color: var(--accent-cyan);
}

.tag-cloud {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.tag-filter {
    padding: 5px 12px;
    font-size: 0.75rem;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 20px;
    cursor: pointer;
    transition: var(--transition-fast);
}

.tag-filter.active {
    background: var(--accent-magenta);
    border-color: var(--accent-magenta);
    box-shadow: 0 0 10px var(--accent-magenta);
}

/* Custom Checks */
.checkbox-group {
    display: flex;
    gap: 15px;
}

.custom-checkbox {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 0.8rem;
    cursor: pointer;
}

.custom-checkbox input {
    accent-color: var(--accent-green);
}

/* Stats Card */
.stats-card {
    margin-top: auto;
}

.stats-card h4 {
    font-size: 0.8rem;
    text-transform: uppercase;
    margin-bottom: 12px;
    color: var(--accent-yellow);
}

.stat-row {
    display: flex;
    justify-content: space-between;
    font-size: 0.9rem;
    margin-bottom: 8px;
}

.stat-value { color: var(--accent-cyan); font-family: 'Orbitron', sans-serif; }
.stat-value-alt { color: var(--accent-magenta); font-family: 'Orbitron', sans-serif; }

.progress-bar-container {
    width: 100%;
    height: 4px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 2px;
    margin-top: 10px;
    overflow: hidden;
}

.progress-bar {
    height: 100%;
    width: 0%;
    background: linear-gradient(90deg, var(--accent-cyan), var(--accent-green));
    transition: width 1s ease-out;
}

.btn-primary {
    width: 100%;
    padding: 12px;
    margin-top: 15px;
    background: transparent;
    border: 2px solid var(--accent-cyan);
    color: var(--accent-cyan);
    font-family: 'Orbitron', sans-serif;
    font-weight: 700;
    border-radius: 12px;
    cursor: pointer;
    transition: var(--transition-fast);
    letter-spacing: 2px;
}

.copyright {
    font-size: 0.65rem;
    color: var(--text-muted);
    text-align: center;
    margin-top: 12px;
    letter-spacing: 1px;
    opacity: 0.6;
}

.btn-primary:hover {
    background: var(--accent-cyan);
    color: var(--bg-dark);
    box-shadow: 0 0 25px var(--accent-cyan);
}

/* Main Display Area */
.data-display {
    flex-grow: 1;
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.main-header {
    padding: 20px 30px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.active-campaign-info .label {
    color: var(--text-muted);
    font-size: 0.8rem;
    margin-right: 10px;
}

#current-mission-name {
    color: var(--accent-cyan);
    font-weight: 800;
    font-size: 1.1rem;
}

#data-counter {
    background: rgba(255, 255, 255, 0.05);
    padding: 8px 20px;
    border-radius: 20px;
    font-family: 'Orbitron', sans-serif;
    font-size: 0.9rem;
}

.data-grid {
    flex-grow: 1;
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(120px, 1fr));
    gap: 15px;
    padding: 10px;
    overflow-y: auto;
    align-content: start;
}

/* Data Node (Individual User Tiny-Card) */
.user-node {
    height: 120px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 10px;
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(255, 255, 255, 0.05);
    border-radius: 16px;
    transition: var(--transition-slow);
    opacity: 1;
    transform: scale(1);
    position: relative;
    overflow: hidden;
}

.user-node:hover {
    transform: translateY(-5px) scale(1.05);
    background: rgba(255, 255, 255, 0.08);
    border-color: rgba(255, 255, 255, 0.2);
    z-index: 10;
}

.user-node.filtered-out {
    opacity: 0.1;
    filter: grayscale(1) blur(2px);
    transform: scale(0.95);
    pointer-events: none;
}

.user-node.is-target {
    border-color: var(--accent-green);
    background: rgba(0, 255, 136, 0.05);
}

.avatar-sphere {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--accent-cyan), var(--accent-magenta));
    margin-bottom: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.2rem;
    box-shadow: inset 0 0 10px rgba(0,0,0,0.5);
    transition: var(--transition-slow);
}

.user-node:hover .avatar-sphere {
    transform: scale(0.8) translateY(-10px);
    opacity: 0.3;
}

.user-name {
    font-size: 0.7rem;
    font-weight: 600;
    text-align: center;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    width: 100%;
}

.user-meta {
    font-size: 0.6rem;
    color: var(--text-muted);
}

.user-interests {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(5, 5, 8, 0.96); /* Etwas dunkler für besseren Kontrast */
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px); /* Fix für Safari/Edge */
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 10px;
    text-align: center;
    opacity: 0;
    transition: opacity 0.3s ease-in-out, transform 0.3s ease-out;
    transform: translateY(10px); /* Leichter Slide-Up Effekt */
    z-index: 1000; /* Sehr hoher Wert für Edge */
    pointer-events: none;
}

.user-node:hover .user-interests {
    opacity: 1;
    transform: translateY(0);
}

.interest-tag-container {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 4px;
    margin-top: 5px;
}

.interest-tag {
    font-size: 0.6rem;
    padding: 2px 8px;
    background: rgba(0, 242, 255, 0.1);
    border: 1px solid var(--accent-cyan);
    color: var(--accent-cyan);
    border-radius: 10px;
    white-space: nowrap;
    text-shadow: 0 0 5px var(--accent-cyan);
    box-shadow: 0 0 5px rgba(0, 242, 255, 0.2);
}

.interest-label {
    font-size: 0.55rem;
    text-transform: uppercase;
    color: var(--text-muted);
    letter-spacing: 1px;
    margin-bottom: 8px;
}

/* Scrollbar Styling */
::-webkit-scrollbar { width: 6px; }
::-webkit-scrollbar-track { background: transparent; }
::-webkit-scrollbar-thumb { background: rgba(255, 255, 255, 0.1); border-radius: 3px; }
::-webkit-scrollbar-thumb:hover { background: rgba(255, 255, 255, 0.2); }

/* Animations */
@keyframes pulse {
    0% { transform: scale(1); opacity: 1; }
    50% { transform: scale(1.05); opacity: 0.8; }
    100% { transform: scale(1); opacity: 1; }
}

.pulse { animation: pulse 2s infinite ease-in-out; }

/* Responsive adjustments */
@media (max-width: 1000px) {
    .app-container { flex-direction: column; overflow-y: auto; height: auto; }
    .sidebar { width: 100%; }
    body { overflow-y: auto; }
}
