.week-display {
    border: 1px solid #dee2e6;
    border-radius: 0.375rem;
    padding: 1rem;
    background-color: #f8f9fa;
}

.week-days {
    gap: 5px;
}

.day-item {
    border-radius: 0.25rem;
    transition: all 0.2s ease;
}

.day-item:hover {
    background-color: #e9ecef !important;
}

.day-name {
    font-weight: bold;
    font-size: 0.8rem;
}

.day-date {
    font-size: 1.1rem;
}

#chartContainer {
    background-color: #fff;
    border: 1px solid #dee2e6;
    border-radius: 0.375rem;
    padding: 1rem;
    overflow-x: auto;
    width: 100%;
    max-width: 100vw;
    box-sizing: border-box;
}

.bar {
    opacity: 0.8;
}

.bar:hover {
    opacity: 1;
}

.value-label {
    font-weight: bold;
}

.streak-square.hit {
    fill: #22c55e;
}

.streak-square.miss {
    fill: #ef4444;
}

.streak-square.pending {
    fill: #adb5bd;
}

.streak-square {
    cursor: pointer;
}

.streak-square:hover {
    stroke: #333;
    stroke-width: 1.5px;
}

.chart-tooltip {
    display: none;
    position: fixed;
    z-index: 1000;
    pointer-events: none;
    padding: 0.4rem 0.6rem;
    border-radius: 0.375rem;
    background-color: rgba(33, 37, 41, 0.92);
    color: #fff;
    font-size: 0.85rem;
    line-height: 1.4;
}

.streak-label {
    font-weight: bold;
    fill: #333;
}

#currentWeek {
    color: #0d6efd;
    font-weight: bold;
}

.form-range {
    vertical-align: middle;
}

/* Streaks */
.streak-banner {
    display: flex;
    align-items: baseline;
    gap: 0.5rem;
    flex-wrap: wrap;
    border-radius: 0.375rem;
    padding: 0.75rem 1rem;
    border: 1px solid #dee2e6;
    background-color: #f8f9fa;
}

.streak-banner.safe {
    border-color: #badbcc;
    background-color: #d1e7dd;
}

.streak-banner.at-risk {
    border-color: #ffe69c;
    background-color: #fff3cd;
}

.streak-flame {
    font-size: 1.25rem;
}

.streak-count {
    font-weight: bold;
    font-size: 1.1rem;
}

.streak-note {
    color: #6c757d;
    font-size: 0.9rem;
}

@media (max-width: 768px) {
    .week-days {
        flex-wrap: wrap;
    }

    .day-item {
        min-width: 60px !important;
        margin-bottom: 5px;
    }

    #chart {
        width: 100% !important;
        max-width: 100%;
        min-width: 320px;
    }

    #chartContainer {
        padding: 0.25rem !important;
        margin: 0 !important;
        max-width: calc(100vw - 2rem) !important;
        overflow-x: auto !important;
        overflow-y: hidden !important;
    }

    .card-body {
        padding: 0.5rem !important;
    }

    .card {
        margin: 0 !important;
    }

    .container {
        padding-left: 0.5rem !important;
        padding-right: 0.5rem !important;
    }

    /* Make controls stack on mobile */
    .d-flex.justify-content-between {
        flex-direction: column !important;
        gap: 1rem;
    }

    #currentWeek {
        text-align: center;
        order: -1;
    }
}