/* Termux Dashboard Styles */
:root {
    --primary: #00d2ff;
    --secondary: #3a0ca3;
    --dark: #0d1117;
    --surface: #161b22;
    --text: #f0f6fc;
    --success: #56d364;
    --warning: #d29922;
    --error: #f85149;
}

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

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    background: var(--dark);
    color: var(--text);
    line-height: 1.6;
}

.header {
    background: var(--surface);
    padding: 1rem 2rem;
    border-bottom: 1px solid #30363d;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo {
    font-size: 1.5rem;
    font-weight: bold;
    color: var(--primary);
}

.status {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    background: var(--dark);
    padding: 0.5rem 1rem;
    border-radius: 20px;
}

.status-dot {
    width: 8px;
    height: 8px;
    background: var(--success);
    border-radius: 50%;
    animation: pulse 2s infinite;
}

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

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

.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 1.5rem;
    margin-bottom: 2rem;
}

.stat-card {
    background: var(--surface);
    padding: 1.5rem;
    border-radius: 12px;
    text-align: center;
    border: 1px solid #30363d;
}

.stat-value {
    font-size: 2.5rem;
    font-weight: bold;
    color: var(--primary);
    margin-bottom: 0.5rem;
}

.stat-label {
    color: #8b949e;
    font-size: 0.9rem;
}

.chart-section {
    background: var(--surface);
    padding: 2rem;
    border-radius: 12px;
    border: 1px solid #30363d;
    margin: 2rem 0;
}

.chart-title {
    font-size: 1.5rem;
    margin-bottom: 1rem;
    color: var(--primary);
}

.chart-placeholder {
    height: 300px;
    background: var(--dark);
    border: 2px dashed #30363d;
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #8b949e;
    font-size: 1.1rem;
}

.table {
    width: 100%;
    background: var(--surface);
    border-radius: 12px;
    overflow: hidden;
    border: 1px solid #30363d;
}

.table th,
.table td {
    padding: 1rem;
    text-align: left;
    border-bottom: 1px solid #30363d;
}

.table th {
    background: var(--dark);
    font-weight: 600;
}

.alert {
    padding: 1rem;
    border-radius: 8px;
    margin: 1rem 0;
    border-left: 4px solid;
}

.alert-success {
    background: rgba(86, 211, 100, 0.1);
    border-left-color: var(--success);
    color: var(--success);
}

.alert-warning {
    background: rgba(210, 153, 34, 0.1);
    border-left-color: var(--warning);
    color: var(--warning);
}

@media (max-width: 768px) {
    .container { padding: 1rem; }
    .stats-grid { grid-template-columns: 1fr; }
    .stat-value { font-size: 2rem; }
}

/* Enhanced Progress Bars for Milestone 3.2 */
.progress-fill.excellent {
    background: linear-gradient(90deg, #56d364, #238636);
}

.progress-fill.perfect {
    background: linear-gradient(90deg, #00d2ff, #3a0ca3);
}

.progress-fill.good {
    background: linear-gradient(90deg, #d29922, #b08800);
}

.progress-fill.warning {
    background: linear-gradient(90deg, #fb8500, #d63384);
}

/* Chart containers */
.chart-grid {
    display: grid;
    grid-template-columns: 2fr 1fr;
    gap: 2rem;
    margin: 2rem 0;
}

.chart-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 2rem;
    margin: 2rem 0;
}

.chart-container {
    position: relative;
    height: 400px;
    padding: 1rem;
}

.chart-container canvas {
    max-height: 100% !important;
}

/* Real-time indicator */
.real-time-indicator {
    position: absolute;
    top: 10px;
    right: 10px;
    background: rgba(86, 211, 100, 0.2);
    color: #56d364;
    padding: 0.25rem 0.5rem;
    border-radius: 12px;
    font-size: 0.75rem;
    border: 1px solid #56d364;
}

.real-time-indicator::before {
    content: '🔴 ';
    animation: blink 1s infinite;
}

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

/* Mobile responsiveness for charts */
@media (max-width: 768px) {
    .chart-grid,
    .chart-row {
        grid-template-columns: 1fr;
    }
    
    .chart-container {
        height: 300px;
    }
}
