html, body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif, 'Apple Color Emoji', 'Segoe UI Emoji', 'Segoe UI Symbol';
    margin: 0;
    padding: 0;
}

body {
    background-color: #f5f5f5;
}

a, .btn-link {
    color: #0071c3;
}

a:hover, .btn-link:hover {
    color: #0056b3;
}

.btn-primary {
    color: #fff;
    background-color: #1b6ec2;
    border-color: #1861ac;
}

.btn-primary:hover {
    color: #fff;
    background-color: #1861ac;
    border-color: #1861ac;
}

.btn:focus, .btn:active:focus, .btn-link.nav-link:focus, .form-control:focus, .form-check-input:focus {
    outline: 0;
    box-shadow: 0 0 0 0.1rem white, 0 0 0 0.25rem #258cfb;
}

.page {
    display: flex;
    flex-direction: column;
    height: 100vh;
}

main {
    flex: 1;
}

.sidebar {
    background: linear-gradient(180deg, rgb(5, 39, 103) 0%, #3a0647 70%);
}

.top-row {
    background-color: #f7f7f7;
    padding: 0 1rem;
    height: 3.5rem;
    display: flex;
    align-items: center;
}

.top-row a {
    margin-left: 1rem;
}

.content {
    padding: 1.5rem;
}

.valid.modified:not([type=checkbox]) {
    outline: 1px solid #26c485;
}

.invalid {
    outline: 1px solid red;
}

.validation-message {
    color: red;
}

#blazor-error-ui {
    background: lightyellow;
    bottom: 0;
    box-shadow: 0 -1px 2px rgba(0, 0, 0, 0.2);
    display: none;
    left: 0;
    padding: 0.6rem 1.25rem 0.7rem 1.25rem;
    position: fixed;
    right: 0;
    z-index: 1000;
}

#blazor-error-ui .dismiss {
    cursor: pointer;
    position: absolute;
    right: 0.75rem;
    top: 0.5rem;
}

/* Chart Styles */
.chart-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1rem;
}

.today-usage-pill {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    background: linear-gradient(135deg, rgba(59, 130, 246, 0.15), rgba(139, 92, 246, 0.15));
    border: 1px solid rgba(99, 102, 241, 0.3);
    padding: 0.5rem 1rem;
    border-radius: 9999px;
}

.today-usage-pill .pill-label {
    font-size: 0.7rem;
    color: #9ca3af;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.today-usage-pill .pill-value {
    font-size: 0.9rem;
    font-weight: 700;
    color: #818cf8;
}

.usage-chart-card {
    padding: 1.5rem;
}

/* Stats Grid */
.usage-stats-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1rem;
    margin-bottom: 2rem;
}

.usage-stat-item {
    display: flex;
    align-items: center;
    gap: 1rem;
    padding: 1rem;
    background: rgba(0, 0, 0, 0.2);
    border-radius: 12px;
    border: 1px solid rgba(55, 65, 81, 0.3);
}

.stat-icon {
    width: 40px;
    height: 40px;
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.stat-icon.blue {
    background: rgba(59, 130, 246, 0.2);
    color: #3b82f6;
}

.stat-icon.purple {
    background: rgba(139, 92, 246, 0.2);
    color: #8b5cf6;
}

.stat-icon.green {
    background: rgba(16, 185, 129, 0.2);
    color: #10b981;
}

.stat-info .stat-value {
    font-size: 1.5rem;
    font-weight: 700;
    color: #fff;
}

.stat-info .stat-label {
    font-size: 0.75rem;
    color: #9ca3af;
}

/* Chart Area */
.chart-wrapper {
    display: flex;
    gap: 1rem;
    height: 220px;
}

.chart-y-axis {
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    padding: 0 0.5rem;
    font-size: 0.7rem;
    color: #6b7280;
    text-align: right;
    min-width: 30px;
}

.chart-area {
    flex: 1;
    position: relative;
}

.chart-grid-lines {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 30px;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    pointer-events: none;
}

.grid-line {
    border-bottom: 1px dashed rgba(75, 85, 99, 0.3);
}

.chart-bars {
    display: flex;
    align-items: flex-end;
    justify-content: space-around;
    height: calc(100% - 30px);
    padding: 0 0.5rem;
    position: relative;
}

.bar-column {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    height: 100%;
    position: relative;
    max-width: 60px;
}

.bar-tooltip {
    display: none;
    position: absolute;
    bottom: calc(100% + 10px);
    left: 50%;
    transform: translateX(-50%);
    background: rgba(17, 24, 39, 0.95);
    border: 1px solid rgba(75, 85, 99, 0.5);
    border-radius: 8px;
    padding: 0.75rem 1rem;
    font-size: 0.75rem;
    color: #e5e7eb;
    white-space: nowrap;
    z-index: 100;
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.3);
}

.bar-column:hover .bar-tooltip {
    display: block;
}

.bar-tooltip strong {
    color: #fff;
    display: block;
    margin-bottom: 0.25rem;
}

.bar-wrapper {
    flex: 1;
    width: 100%;
    position: relative;
}

.bar {
    position: absolute;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 100%;
    max-width: 40px;
    background: linear-gradient(to top, #1e40af 0%, #3b82f6 100%);
    border-radius: 6px 6px 0 0;
    transition: height 0.3s ease, filter 0.3s ease;
    cursor: pointer;
}

.bar:hover {
    filter: brightness(1.2);
}

.bar.today {
    background: linear-gradient(180deg, #a78bfa 0%, #7c3aed 100%);
    box-shadow: 0 0 20px rgba(139, 92, 246, 0.4);
}

.bar.empty {
    background: rgba(75, 85, 99, 0.3);
    min-height: 4px;
}

.bar-label {
    padding-top: 0.5rem;
    font-size: 0.7rem;
    color: #9ca3af;
    text-align: center;
    white-space: nowrap;
    flex-shrink: 0;
}

.bar-label.today {
    color: #a78bfa;
    font-weight: 600;
}

/* Empty State */
.chart-empty-state {
    text-align: center;
    padding: 3rem 2rem;
}

.chart-empty-state .empty-icon {
    width: 80px;
    height: 80px;
    margin: 0 auto 1.5rem;
    background: linear-gradient(135deg, rgba(59, 130, 246, 0.1), rgba(139, 92, 246, 0.1));
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #6b7280;
}

.chart-empty-state h3 {
    margin: 0 0 0.5rem;
    font-size: 1.125rem;
    color: #e5e7eb;
}

.chart-empty-state p {
    color: #9ca3af;
    margin: 0 0 1.5rem;
    font-size: 0.875rem;
}

/* Responsive */
@media (max-width: 768px) {
    .usage-stats-grid {
        grid-template-columns: 1fr;
    }
    
    .chart-wrapper {
        height: 180px;
    }
    
    .bar-label {
        font-size: 0.6rem;
    }
}

/* Simple Today Chart Fallback */
.simple-today-chart {
    padding: 1.5rem;
}

.today-bar-container {
    margin-bottom: 1rem;
}

.today-bar-label {
    font-size: 0.875rem;
    font-weight: 600;
    color: #e5e7eb;
    margin-bottom: 0.75rem;
}

.today-bar-wrapper {
    height: 24px;
    background: rgba(55, 65, 81, 0.5);
    border-radius: 12px;
    overflow: hidden;
    margin-bottom: 0.5rem;
}

.today-bar-fill {
    height: 100%;
    background: linear-gradient(90deg, #3b82f6, #8b5cf6);
    border-radius: 12px;
    transition: width 0.5s ease;
    min-width: 4px;
}

.today-bar-stats {
    display: flex;
    justify-content: space-between;
    font-size: 0.75rem;
}

.today-bar-stats .used {
    color: #818cf8;
}

.today-bar-stats .remaining {
    color: #10b981;
}/* Improved Empty State */
.chart-empty-state {
    text-align: center;
    padding: 3rem 2rem;
}

.chart-empty-icon {
    width: 100px;
    height: 100px;
    margin: 0 auto 1.5rem;
    background: linear-gradient(135deg, rgba(59, 130, 246, 0.1), rgba(139, 92, 246, 0.1));
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #3b82f6;
}

.chart-empty-state h3 {
    margin: 0 0 0.5rem;
    font-size: 1.25rem;
    color: #fff;
}

.chart-empty-state p {
    color: #9ca3af;
    margin: 0 0 2rem;
    font-size: 0.875rem;
}

.chart-empty-steps {
    display: flex;
    justify-content: center;
    gap: 2rem;
    flex-wrap: wrap;
}

.empty-step {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    color: #9ca3af;
    font-size: 0.875rem;
}

.step-number {
    width: 28px;
    height: 28px;
    background: rgba(59, 130, 246, 0.2);
    border: 1px solid rgba(59, 130, 246, 0.4);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 600;
    font-size: 0.75rem;
    color: #3b82f6;
}

