:root {
    --bg-main: #0A0A0B;
    --bg-card: rgba(20, 20, 22, 0.6);
    --bg-input: rgba(255, 255, 255, 0.05);
    
    --text-primary: #EDEDED;
    --text-secondary: #A1A1A8;
    
    --accent: #6C5CE7;
    --accent-hover: #8073F0;
    --border: rgba(255, 255, 255, 0.08);
    
    --radius: 12px;
    --transition: 0.3s cubic-bezier(0.2, 0.8, 0.2, 1);
}

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

body {
    font-family: 'Inter', sans-serif;
    background-color: var(--bg-main);
    color: var(--text-primary);
    min-height: 100vh;
    line-height: 1.5;
    position: relative;
    overflow-x: hidden;
}

.background-mesh {
    position: fixed;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: radial-gradient(circle at 50% 30%, rgba(108, 92, 231, 0.15), transparent 40%),
                radial-gradient(circle at 80% 80%, rgba(46, 204, 113, 0.05), transparent 30%);
    z-index: -1;
    pointer-events: none;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 3rem 2rem;
}

header {
    margin-bottom: 3rem;
    text-align: center;
}

.logo {
    display: inline-flex;
    align-items: center;
    gap: 0.75rem;
    font-weight: 700;
    font-size: 1.2rem;
    color: var(--accent);
    margin-bottom: 1rem;
}

h1 {
    font-size: 2.5rem;
    font-weight: 600;
    letter-spacing: -0.03em;
    margin-bottom: 0.5rem;
}

header p {
    color: var(--text-secondary);
    font-size: 1.1rem;
}

.dashboard-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 2rem;
}

@media (max-width: 900px) {
    .dashboard-grid {
        grid-template-columns: 1fr;
    }
}

.card {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 2rem;
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.2);
}

.card-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 2rem;
}

h2 {
    font-size: 1.25rem;
    font-weight: 500;
}

.section-title {
    font-size: 0.85rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: var(--text-secondary);
    margin: 1.5rem 0 1rem;
    border-bottom: 1px solid var(--border);
    padding-bottom: 0.5rem;
}

.grid-2 {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1rem;
}

.form-group {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
    margin-bottom: 1rem;
}

label {
    font-size: 0.9rem;
    color: var(--text-secondary);
}

input {
    background: var(--bg-input);
    border: 1px solid var(--border);
    color: var(--text-primary);
    padding: 0.75rem 1rem;
    border-radius: 8px;
    font-family: inherit;
    font-size: 1rem;
    transition: var(--transition);
}

input:focus {
    outline: none;
    border-color: var(--accent);
    background: rgba(255, 255, 255, 0.1);
}

button {
    font-family: inherit;
    cursor: pointer;
    border: none;
    transition: var(--transition);
}

.btn-primary {
    background: var(--accent);
    color: white;
    width: 100%;
    padding: 1rem;
    border-radius: 8px;
    font-size: 1rem;
    font-weight: 500;
    margin-top: 1.5rem;
    display: flex;
    justify-content: center;
    align-items: center;
}

.btn-primary:hover {
    background: var(--accent-hover);
    transform: translateY(-2px);
}

.btn-ghost {
    background: transparent;
    color: var(--text-secondary);
    font-size: 0.85rem;
    padding: 0.5rem 1rem;
    border-radius: 6px;
    border: 1px solid var(--border);
}

.btn-ghost:hover {
    color: var(--text-primary);
    background: var(--bg-input);
}

/* Loader */
.loader {
    width: 20px;
    height: 20px;
    border: 3px solid rgba(255,255,255,0.3);
    border-radius: 50%;
    border-top-color: white;
    animation: spin 1s ease-in-out infinite;
}
@keyframes spin { to { transform: rotate(360deg); } }
.hidden { display: none !important; }

/* Results */
.empty-state {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
    height: 300px;
    color: var(--text-secondary);
    gap: 1rem;
}

.headline-metric {
    background: linear-gradient(135deg, rgba(108, 92, 231, 0.2), rgba(108, 92, 231, 0.05));
    border: 1px solid rgba(108, 92, 231, 0.3);
    padding: 2rem;
    border-radius: 12px;
    text-align: center;
    margin-bottom: 2rem;
    margin-top: 1rem;
}

.headline-metric .value {
    font-size: 3rem;
    font-weight: 700;
    color: #fff;
    margin-top: 0.5rem;
}

.headline-metric .unit {
    font-size: 1.2rem;
    font-weight: 400;
    color: var(--text-secondary);
}

.category-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1rem;
    border-bottom: 1px solid var(--border);
    animation: slideUp 0.4s ease forwards;
    opacity: 0;
    transform: translateY(10px);
}

@keyframes slideUp {
    to { opacity: 1; transform: translateY(0); }
}

.cat-details h4 {
    font-weight: 500;
    margin-bottom: 0.25rem;
}
.cat-details p {
    font-size: 0.8rem;
    color: var(--text-secondary);
}
.cat-value {
    font-weight: 600;
    font-family: monospace;
    font-size: 1.1rem;
}
.tag {
    font-size: 0.7rem;
    padding: 2px 6px;
    border-radius: 4px;
    margin-left: 8px;
    font-weight: 600;
}
.tag-ACTUAL { background: rgba(46, 204, 113, 0.2); color: #2ecc71; }
.tag-PROXY { background: rgba(241, 196, 15, 0.2); color: #f1c40f; }
.tag-FALLBACK { background: rgba(231, 76, 60, 0.2); color: #e74c3c; }
