/* Reset & Base */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: 'Rajdhani', sans-serif;
    background: #000;
    color: #fff;
    overflow-x: hidden;
}

/* Canvas & Fixed Elements */
#canvas-container {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100vh;
    z-index: 1;
}

.stars {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: 0;
}

/* Scroll Container */
#scroll-container {
    position: relative;
    z-index: 2;
    pointer-events: none;
}

/* Sections */
.section {
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    padding: 4rem 2rem;
    pointer-events: none;
    /* Allow clicks to pass through to canvas */
}

.section>* {
    pointer-events: auto;
    /* Enable interaction with text */
}

/* ... existing code ... */

/* Hero Section */
.hero-section {
    text-align: center;
    position: relative;
    /* Ensure positioning context for absolute children */
}

.hero-title {
    font-size: clamp(1.5rem, 8vw, 4rem);
    font-weight: 600;
    letter-spacing: 0.05em;
    text-transform: uppercase;
    color: #fff;
    /* Solid white */
    margin-bottom: 1.5rem;
    opacity: 0;
    animation: fadeInUp 1s ease forwards;
    animation-delay: 0.3s;
}

.hero-subtitle {
    font-size: clamp(1rem, 2vw, 1.25rem);
    font-weight: 400;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    color: rgba(255, 255, 255, 0.6);
    max-width: 600px;
    line-height: 1.6;
    opacity: 0;
    animation: fadeInUp 1s ease forwards;
    animation-delay: 0.6s;
}

/* Scroll Indicator - Bottom Left */
.scroll-indicator {
    position: fixed;
    /* Fixed so it stays on screen during initial view, or absolute if relative to hero */
    bottom: 3rem;
    left: 3rem;
    transform: none;
    /* Remove centering transform */
    display: flex;
    flex-direction: row;
    /* Horizontal layout */
    align-items: center;
    gap: 1rem;
    opacity: 0;
    animation: fadeIn 1s ease forwards;
    animation-delay: 1.2s;
    z-index: 10;
}

.scroll-indicator span {
    font-size: 0.85rem;
    text-transform: uppercase;
    letter-spacing: 0.2em;
    color: rgba(255, 255, 255, 0.4);
    font-weight: 500;
}

.scroll-indicator .arrow {
    width: 0;
    height: 0;
    border-left: 5px solid transparent;
    border-right: 5px solid transparent;
    border-top: 5px solid #fff;
    transform: none;
    border-bottom: none;
}

/* Data Sections */
.data-section {
    min-height: 100vh;
}

/* Stat Cards */
.stat-card {
    background: rgba(0, 0, 0, 0.7);
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 4px;
    /* Sharper corners */
    padding: 3rem;
    max-width: 500px;
    text-align: left;
    /* Technical look implies left align usually */
    transform: translateY(50px);
    opacity: 0;
    transition: all 0.8s cubic-bezier(0.16, 1, 0.3, 1);
}

.stat-card.visible {
    transform: translateY(0);
    opacity: 1;
}

.stat-icon {
    width: 48px;
    height: 48px;
    background: transparent;
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 4px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 0 1.5rem 0;
    font-size: 1.25rem;
    color: #fff;
}

.stat-value {
    font-size: 5rem;
    /* Larger, thinner */
    font-weight: 300;
    color: #fff;
    background: none;
    -webkit-text-fill-color: initial;
    margin-bottom: 0.25rem;
    letter-spacing: -0.02em;
}

.stat-trend {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.9rem;
    color: #fff;
    opacity: 0.7;
    margin-bottom: 1.5rem;
    text-transform: uppercase;
    letter-spacing: 0.1em;
}

.stat-title {
    font-size: 1.25rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    margin-bottom: 1rem;
    color: #fff;
}

.stat-description {
    font-size: 1rem;
    color: rgba(255, 255, 255, 0.6);
    line-height: 1.6;
    font-weight: 300;
}

/* Progress Bar */
.progress-bar {
    background: #fff;
    /* Solid white */
}

/* Animations */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }

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

@keyframes fadeIn {
    from {
        opacity: 0;
    }

    to {
        opacity: 1;
    }
}

/* Dashboard UI */
.dashboard-sidebar {
    position: fixed;
    top: 50%;
    left: 2rem;
    transform: translateY(-50%);
    z-index: 100;
    pointer-events: auto;
}

.dashboard-sidebar h3 {
    font-size: 0.8rem;
    color: rgba(255, 255, 255, 0.5);
    letter-spacing: 0.2em;
    margin-bottom: 1rem;
    border-bottom: 1px solid rgba(255, 255, 255, 0.2);
    padding-bottom: 0.5rem;
}

.metric-item {
    font-family: 'Rajdhani', sans-serif;
    list-style: none;
    padding: 0.75rem 1rem;
    margin-bottom: 0.5rem;
    background: rgba(0, 0, 0, 0.8);
    border: 1px solid rgba(255, 255, 255, 0.2);
    cursor: pointer;
    font-size: 1.1rem;
    border-radius: 4px;
    /* Square/Technical */
    transition: all 0.2s ease;
    text-transform: uppercase;
}

.metric-item:hover,
.metric-item.active {
    background: #fff;
    color: #000;
    border-color: #fff;
    font-weight: 600;
}

/* Detail Panel */
.detail-panel {
    position: fixed;
    top: 50%;
    right: -400px;
    transform: translateY(-50%);
    width: 350px;
    background: rgba(10, 10, 10, 0.95);
    border: 1px solid rgba(255, 255, 255, 0.2);
    padding: 2rem;
    z-index: 100;
    transition: right 0.4s cubic-bezier(0.16, 1, 0.3, 1);
    box-shadow: -10px 0 30px rgba(0, 0, 0, 0.5);
}

.detail-panel.visible {
    right: 2rem;
}

.panel-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 2rem;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    padding-bottom: 1rem;
}

.panel-header h2 {
    font-size: 2rem;
    font-weight: 600;
    text-transform: uppercase;
    margin: 0;
}

.close-btn {
    background: none;
    border: none;
    color: #fff;
    font-size: 2rem;
    cursor: pointer;
}

.stat-row {
    margin-bottom: 1.5rem;
}

.stat-label {
    display: block;
    font-size: 0.8rem;
    color: rgba(255, 255, 255, 0.5);
    text-transform: uppercase;
    letter-spacing: 0.1em;
    margin-bottom: 0.25rem;
}

.stat-values {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 1.2rem;
    font-family: 'Rajdhani', sans-serif;
}

.start-val {
    opacity: 0.6;
}

.end-val {
    font-weight: 700;
}

.content-right {
    margin-left: auto;
    width: 50%;
    padding-right: 5%;
    text-align: left;
}

.section-title {
    font-size: 1.5rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    color: rgba(255, 255, 255, 0.5);
    margin-bottom: 1rem;
}

.big-stat {
    font-size: 8rem;
    font-weight: 700;
    color: #fff;
    line-height: 1;
    margin-bottom: 2rem;
    letter-spacing: -0.02em;
}

.section-text {
    font-size: 1.5rem;
    font-weight: 300;
    line-height: 1.4;
    color: #fff;
    margin-bottom: 1.5rem;
    max-width: 600px;
}

.section-text strong {
    font-weight: 600;
    color: #fff;
    border-bottom: 1px solid rgba(255, 255, 255, 0.3);
}

.section-subtext {
    font-size: 1rem;
    color: rgba(255, 255, 255, 0.5);
    line-height: 1.6;
    max-width: 500px;
}

.stat-link {
    text-decoration: none;
    display: inline-block;
    transition: transform 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}

.stat-link:hover {
    transform: scale(1.05);
}

.stat-link:hover .big-stat {
    color: red;
    /* Green highlight on hover */
    text-shadow: 0 0 30px rgba(74, 222, 128, 0.3);
}

a {
    color: red;
    transition: 0.3s ease;
}

a:hover {
    opacity: 0.8;
    letter-spacing: -3px;
}