/* tanso.markets - Cyberpunk data-surveillance dashboard */
/* Palette: #050508 #0A0E17 #1E3A5F #7B8BA3 #8899AA #E0E0E0 #00D4FF #00FF88 #FF4757 #FFD93D */

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

html {
    overflow-x: hidden;
}

body {
    font-family: 'Inter', sans-serif;
    background-color: #050508;
    color: #E0E0E0;
    overflow-x: hidden;
    line-height: 1.5;
}

/* === CRT Scan Lines === */
#scanlines {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: 9999;
    background: repeating-linear-gradient(
        transparent 0%,
        transparent 50%,
        rgba(0, 255, 136, 0.03) 50%,
        rgba(0, 255, 136, 0.03) 100%
    );
    background-size: 100% 4px;
}

/* === Boot Screen === */
.section-full {
    min-height: 100vh;
    display: flex;
    align-items: flex-start;
    justify-content: flex-start;
    padding: 2rem;
    position: relative;
}

#boot-screen {
    background: #0A0E17;
    z-index: 100;
    transition: opacity 0.5s ease;
}

#boot-screen.fade-out {
    opacity: 0;
    pointer-events: none;
}

.terminal {
    font-family: 'Share Tech Mono', monospace;
    font-size: 1rem;
    color: #00FF88;
    line-height: 1.8;
    max-width: 700px;
}

.terminal-line {
    display: block;
    opacity: 0;
    animation: line-appear 0.1s ease forwards;
}

@keyframes line-appear {
    to { opacity: 1; }
}

.cursor {
    animation: blink-cursor 0.6s step-end infinite;
}

@keyframes blink-cursor {
    0%, 100% { opacity: 1; }
    50% { opacity: 0; }
}

.terminal-title {
    font-family: 'Share Tech Mono', monospace;
    font-size: clamp(2rem, 5vw, 3.5rem);
    color: #E0E0E0;
    margin-top: 1rem;
    display: block;
}

/* === Dashboard === */
.dashboard-hidden {
    display: none;
}

.dashboard-visible {
    display: block;
}

/* === Status Bar === */
#status-bar {
    position: sticky;
    top: 0;
    z-index: 100;
    background: #050508;
    border-bottom: 1px solid #1E3A5F;
    padding: 0.5rem 1.5rem;
    display: flex;
    gap: 1.5rem;
    align-items: center;
    flex-wrap: wrap;
}

.status-item {
    font-family: 'Rajdhani', sans-serif;
    font-weight: 500;
    font-size: 0.8rem;
    letter-spacing: 0.08em;
    color: #8899AA;
    display: flex;
    align-items: center;
    gap: 0.4rem;
}

.status-dot {
    width: 6px;
    height: 6px;
    border-radius: 50%;
}

.dot-green {
    background: #00FF88;
    box-shadow: 0 0 4px #00FF88;
}

.dot-cyan {
    background: #00D4FF;
    box-shadow: 0 0 4px #00D4FF;
}

.status-time {
    margin-left: auto;
    font-family: 'Share Tech Mono', monospace;
    color: #7B8BA3;
}

/* === Dashboard Grid === */
.dashboard-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    grid-template-rows: auto auto;
    gap: 1px;
    padding: 1px;
    background: #1E3A5F;
    min-height: calc(100vh - 80px);
}

/* === Panels === */
.panel {
    background: #050508;
    display: flex;
    flex-direction: column;
}

.panel-main {
    grid-column: span 1;
    grid-row: span 1;
}

.panel-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0.6rem 1rem;
    border-bottom: 1px solid #1E3A5F;
    background: rgba(30, 58, 95, 0.15);
}

.panel-title {
    font-family: 'Rajdhani', sans-serif;
    font-weight: 600;
    font-size: 0.75rem;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    color: #8899AA;
}

.panel-indicator {
    font-family: 'Share Tech Mono', monospace;
    font-size: 0.65rem;
    letter-spacing: 0.1em;
    padding: 0.15rem 0.5rem;
    border: 1px solid;
}

.indicator-live {
    color: #FF4757;
    border-color: #FF4757;
    animation: pulse-indicator 2s ease infinite;
}

@keyframes pulse-indicator {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.5; }
}

.indicator-active {
    color: #00FF88;
    border-color: #00FF88;
}

.indicator-warning {
    color: #FFD93D;
    border-color: #FFD93D;
}

.panel-body {
    padding: 1rem;
    flex: 1;
}

/* === Chart === */
.chart-svg {
    width: 100%;
    height: auto;
}

.chart-stats {
    display: flex;
    gap: 2rem;
    margin-top: 0.75rem;
}

.stat {
    display: flex;
    flex-direction: column;
}

.stat-label {
    font-family: 'Rajdhani', sans-serif;
    font-weight: 400;
    font-size: 0.65rem;
    letter-spacing: 0.1em;
    color: #7B8BA3;
}

.stat-value {
    font-family: 'Space Grotesk', monospace;
    font-weight: 700;
    font-size: 1.1rem;
    color: #00FF88;
}

/* === Feed Rows === */
.feed-row {
    display: flex;
    align-items: center;
    padding: 0.6rem 0;
    border-bottom: 1px solid rgba(30, 58, 95, 0.3);
}

.feed-name {
    font-family: 'Rajdhani', sans-serif;
    font-weight: 600;
    font-size: 0.85rem;
    letter-spacing: 0.08em;
    color: #E0E0E0;
    width: 80px;
}

.feed-price {
    font-family: 'Space Grotesk', monospace;
    font-weight: 500;
    font-size: 1rem;
    color: #E0E0E0;
    flex: 1;
    text-align: right;
    padding-right: 1rem;
}

.feed-change {
    font-family: 'Share Tech Mono', monospace;
    font-size: 0.8rem;
    width: 70px;
    text-align: right;
}

.feed-up {
    color: #00FF88;
}

.feed-down {
    color: #FF4757;
}

/* === Emissions === */
.emissions-body {
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    text-align: center;
    gap: 1.5rem;
}

.emission-value {
    font-family: 'Space Grotesk', monospace;
    font-weight: 700;
    font-size: clamp(2rem, 4vw, 3rem);
    color: #FF4757;
    display: block;
}

.emission-unit {
    font-family: 'Rajdhani', sans-serif;
    font-weight: 400;
    font-size: 0.75rem;
    color: #7B8BA3;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    display: block;
}

.rate-value {
    font-family: 'Share Tech Mono', monospace;
    font-size: 0.9rem;
    color: #00D4FF;
    display: block;
}

.rate-label {
    font-family: 'Rajdhani', sans-serif;
    font-weight: 400;
    font-size: 0.65rem;
    color: #7B8BA3;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    display: block;
}

/* === Log === */
.log-body {
    font-family: 'Share Tech Mono', monospace;
    font-size: 0.75rem;
    color: #7B8BA3;
    overflow-y: auto;
    max-height: 200px;
}

.log-entry {
    padding: 0.25rem 0;
    border-bottom: 1px solid rgba(30, 58, 95, 0.15);
}

/* === Footer Bar === */
#footer-bar {
    display: flex;
    gap: 2rem;
    padding: 0.5rem 1.5rem;
    border-top: 1px solid #1E3A5F;
    background: #050508;
    flex-wrap: wrap;
}

.footer-item {
    font-family: 'Rajdhani', sans-serif;
    font-weight: 600;
    font-size: 0.75rem;
    letter-spacing: 0.1em;
    color: #8899AA;
    text-transform: uppercase;
}

.footer-dim {
    color: #7B8BA3;
    font-weight: 400;
}

/* === Responsive === */
@media (max-width: 768px) {
    .dashboard-grid {
        grid-template-columns: 1fr;
    }

    .panel-main {
        grid-column: span 1;
    }

    #status-bar {
        padding: 0.5rem 1rem;
        gap: 1rem;
    }

    .chart-stats {
        gap: 1rem;
    }
}
