﻿.month-dashboard {
    width: 100%;
    min-height: calc(100vh - 70px);
    background: #f8fbff;
    color: #0f172a;
    font-family: 'Inter', 'Segoe UI', sans-serif;
}

.dashboard-shell {
    width: 100%;
    max-width: 1320px;
    margin: 0 auto;
    padding: 26px;
}

.dashboard-card {
    width: 100%;
    background: #ffffff;
    border: 1px solid #e5eaf3;
    border-radius: 22px;
    padding: 34px;
    box-shadow: 0 18px 45px rgba(15, 23, 42, .06);
    overflow: hidden;
}

.month-main,
.content {
    width: 100%;
}

.content-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 24px;
    margin-bottom: 34px;
}

.eyebrow {
    font-size: 14px;
    color: #0057ff;
    font-weight: 800;
}

.content-header h1 {
    margin: 12px 0 8px;
    font-size: 34px;
    line-height: 1.2;
    font-weight: 900;
}

.content-header p {
    margin: 0;
    color: #475569;
    font-size: 16px;
}

.filter-area {
    display: flex;
    align-items: center;
    gap: 14px;
    flex-shrink: 0;
}

.period-btn,
.refresh-btn {
    height: 52px;
    border-radius: 13px;
    padding: 0 22px;
    font-weight: 700;
    font-size: 15px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    white-space: nowrap;
}

.period-btn {
    background: #fff;
    border: 1px solid #dbe3ef;
    color: #0f172a;
}

.refresh-btn {
    border: none;
    background: #155dfc;
    color: #fff;
    box-shadow: 0 10px 24px rgba(21, 93, 252, .28);
}

.winner-grid,
.ranking-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 26px;
}

.winner-grid {
    margin-bottom: 26px;
}

.winner-card {
    position: relative;
    overflow: hidden;
    border-radius: 20px;
    padding: 24px;
    min-height: 320px;
    border: 1px solid #dbeafe;
    box-shadow: 0 18px 38px rgba(15, 23, 42, .05);
}

.sales-card {
    background: linear-gradient(135deg, #ffffff 0%, #edf5ff 100%);
}

.employee-card {
    background: linear-gradient(135deg, #ffffff 0%, #fff1df 100%);
    border-color: #fed7aa;
}

.card-pattern {
    position: absolute;
    right: 34px;
    top: 30px;
    font-size: 100px;
    color: rgba(21, 93, 252, .08);
    pointer-events: none;
}

.orange-pattern {
    color: rgba(249, 115, 22, .12);
}

.winner-label {
    position: relative;
    z-index: 1;
    display: inline-flex;
    align-items: center;
    gap: 10px;
    height: 40px;
    padding: 0 20px;
    border-radius: 11px;
    color: #fff;
    font-weight: 800;
    margin-bottom: 30px;
}

    .winner-label.blue {
        background: linear-gradient(135deg, #155dfc, #006bff);
    }

    .winner-label.orange {
        background: linear-gradient(135deg, #ff7a1a, #fb5607);
    }

.winner-body {
    position: relative;
    z-index: 1;
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 24px;
    margin-bottom: 30px;
}

.profile-area {
    display: flex;
    align-items: center;
    gap: 20px;
    min-width: 0;
}

.profile-avatar {
    width: 82px;
    height: 82px;
    border-radius: 50%;
    display: grid;
    place-items: center;
    font-size: 32px;
    flex-shrink: 0;
}

.blue-soft {
    background: #eaf2ff;
    color: #155dfc;
}

.orange-soft {
    background: #fff0dc;
    color: #fb6b14;
}

.profile-area h3 {
    margin: 0 0 8px;
    font-size: 24px;
    line-height: 1.2;
    font-weight: 900;
}

.profile-area p {
    margin: 0;
    color: #334155;
    font-size: 15px;
}

.score-box {
    width: 140px;
    min-height: 118px;
    background: rgba(255, 255, 255, .72);
    border: 1px solid #dce8f7;
    border-radius: 14px;
    padding: 18px;
    flex-shrink: 0;
}

    .score-box span {
        display: block;
        font-size: 14px;
        font-weight: 700;
    }

    .score-box strong {
        display: block;
        font-size: 42px;
        line-height: 1;
        font-weight: 900;
        margin-top: 12px;
    }

    .score-box small {
        font-size: 16px;
        font-weight: 800;
    }

.blue-score strong,
.blue-score small {
    color: #155dfc;
}

.orange-score strong,
.orange-score small {
    color: #fb6b14;
}

.stats-grid {
    position: relative;
    z-index: 1;
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 14px;
}

.stat-box {
    min-width: 0;
    min-height: 92px;
    background: rgba(255, 255, 255, .76);
    border: 1px solid #dbe7f6;
    border-radius: 14px;
    display: flex;
    align-items: center;
    gap: 14px;
    padding: 16px;
}

.orange-border {
    border-color: #fed7aa;
}

.stat-icon {
    width: 46px;
    height: 46px;
    border-radius: 14px;
    display: grid;
    place-items: center;
    font-size: 20px;
    flex-shrink: 0;
}

.stat-box span {
    display: block;
    font-size: 13px;
    color: #334155;
    margin-bottom: 6px;
}

.stat-box strong {
    font-size: 21px;
    font-weight: 900;
}

.ranking-card {
    min-width: 0;
    background: #fff;
    border: 1px solid #e2e8f0;
    border-radius: 18px;
    overflow: hidden;
    box-shadow: 0 18px 38px rgba(15, 23, 42, .05);
}

.ranking-header {
    height: 64px;
    padding: 0 24px;
    border-bottom: 1px solid #e2e8f0;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

    .ranking-header h3 {
        margin: 0;
        font-size: 20px;
        font-weight: 900;
    }

.tag {
    padding: 7px 13px;
    border-radius: 999px;
    font-weight: 800;
    font-size: 13px;
}

.blue-tag {
    color: #155dfc;
    background: #edf5ff;
}

.orange-tag {
    color: #fb6b14;
    background: #fff1e6;
}

.ranking-card table {
    width: 100%;
    border-collapse: collapse;
}

.ranking-card th {
    height: 44px;
    padding: 0 24px;
    text-align: left;
    font-size: 13px;
    color: #334155;
    font-weight: 700;
    border-bottom: 1px solid #e2e8f0;
}

.ranking-card td {
    height: 56px;
    padding: 0 24px;
    font-size: 15px;
    font-weight: 600;
    border-bottom: 1px solid #edf2f7;
}

.ranking-card tr:last-child td {
    border-bottom: none;
}

.text-end {
    text-align: right !important;
}

.blue-text {
    color: #155dfc;
    font-weight: 900 !important;
}

.orange-text {
    color: #fb6b14;
    font-weight: 900 !important;
}

.rank-number {
    width: 30px;
    height: 30px;
    display: inline-grid;
    place-items: center;
    border-radius: 50%;
    background: #e2e8f0;
    color: #334155;
    font-weight: 900;
}

.rank-1 {
    background: #ffc107;
    color: #fff;
}

.rank-2 {
    background: #cbd5e1;
    color: #334155;
}

.rank-3 {
    background: #fb923c;
    color: #fff;
}

@media (max-width: 1200px) {
    .dashboard-shell {
        max-width: 100%;
        padding: 22px;
    }

    .winner-grid,
    .ranking-grid {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 768px) {
    .dashboard-shell {
        padding: 12px;
    }

    .dashboard-card {
        padding: 18px;
        border-radius: 18px;
    }

    .content-header {
        flex-direction: column;
    }

        .content-header h1 {
            font-size: 26px;
        }

    .filter-area {
        width: 100%;
        display: grid;
        grid-template-columns: 1fr;
    }

    .period-btn,
    .refresh-btn {
        width: 100%;
    }

    .winner-body {
        flex-direction: column;
        align-items: flex-start;
    }

    .score-box {
        width: 100%;
    }

    .stats-grid {
        grid-template-columns: 1fr;
    }

    .ranking-card {
        overflow-x: auto;
    }

        .ranking-card table {
            min-width: 520px;
        }
}

@media (max-width: 480px) {
    .winner-label {
        width: 100%;
        justify-content: center;
        font-size: 14px;
        padding: 0 12px;
    }

    .profile-area {
        flex-direction: column;
        align-items: flex-start;
    }

        .profile-area h3 {
            font-size: 22px;
        }

    .card-pattern {
        font-size: 76px;
        right: 18px;
        top: 50px;
    }
}

.month-picker {
    height: 52px;
    min-width: 180px;
    padding: 0 18px;
    border: 1px solid #dbe3ef;
    border-radius: 12px;
    background: #fff;
    font-weight: 600;
    color: #1f2937;
    outline: none;
    transition: .25s;
}

    .month-picker:hover {
        border-color: #2563eb;
    }

    .month-picker:focus {
        border-color: #2563eb;
        box-shadow: 0 0 0 4px rgba(37,99,235,.12);
    }