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

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    min-height: 100vh;
    padding: 20px;
    color: #333;
}

.container {
    max-width: 800px;
    margin: 0 auto;
    background: white;
    border-radius: 16px;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.2);
    padding: 20px;
}

header {
    text-align: center;
    margin-bottom: 30px;
    padding-bottom: 20px;
    border-bottom: 2px solid #f0f0f0;
}

h1 {
    font-size: 24px;
    color: #667eea;
    margin-bottom: 15px;
}

nav {
    display: flex;
    gap: 10px;
    justify-content: center;
}

.btn {
    padding: 10px 20px;
    background: #f5f5f5;
    border: none;
    border-radius: 8px;
    cursor: pointer;
    text-decoration: none;
    color: #333;
    font-size: 14px;
    transition: all 0.3s;
    display: inline-block;
}

.btn:hover {
    background: #e0e0e0;
}

.btn.active {
    background: #667eea;
    color: white;
}

.date-selector {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 20px;
    justify-content: center;
}

.date-selector label {
    font-weight: 600;
    color: #555;
}

.date-selector input {
    padding: 10px;
    border: 2px solid #e0e0e0;
    border-radius: 8px;
    font-size: 14px;
    min-width: 150px;
}

.program-selector {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 20px;
    justify-content: center;
}

.program-selector label {
    font-weight: 600;
    color: #555;
}

.program-selector select {
    padding: 10px;
    border: 2px solid #e0e0e0;
    border-radius: 8px;
    font-size: 14px;
    min-width: 200px;
    background: white;
    cursor: pointer;
}

.progress-section {
    margin-bottom: 25px;
    background: #f8f9fa;
    padding: 20px;
    border-radius: 12px;
}

.progress-text {
    text-align: center;
    margin-bottom: 12px;
    font-size: 16px;
    font-weight: 600;
    color: #555;
}

.progress-bar {
    width: 100%;
    height: 30px;
    background: #e0e0e0;
    border-radius: 15px;
    overflow: hidden;
}

.progress-fill {
    height: 100%;
    background: linear-gradient(90deg, #667eea 0%, #764ba2 100%);
    width: 0%;
    transition: width 0.5s ease;
    display: flex;
    align-items: center;
    justify-content: flex-end;
    padding-right: 10px;
    color: white;
    font-weight: bold;
    font-size: 14px;
}

.stats-summary {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 15px;
    margin-bottom: 25px;
}

.stat-card {
    background: #f8f9fa;
    padding: 15px;
    border-radius: 10px;
    text-align: center;
}

.stat-label {
    font-size: 13px;
    color: #777;
    margin-bottom: 5px;
}

.stat-value {
    font-size: 24px;
    font-weight: bold;
    color: #667eea;
}

.group-card {
    margin-bottom: 20px;
    border: 2px solid #e0e0e0;
    border-radius: 12px;
    overflow: hidden;
}

.group-header {
    background: #667eea;
    color: white;
    padding: 12px 15px;
    font-weight: 600;
    font-size: 15px;
}

.checklist-items {
    padding: 10px;
}

.checklist-item {
    display: flex;
    align-items: center;
    padding: 12px 8px;
    border-bottom: 1px solid #f0f0f0;
    transition: background 0.2s;
}

.checklist-item:last-child {
    border-bottom: none;
}

.checklist-item:hover {
    background: #f8f9fa;
}

.checklist-item input[type="checkbox"] {
    width: 24px;
    height: 24px;
    margin-right: 12px;
    cursor: pointer;
    flex-shrink: 0;
}

.checklist-item label {
    cursor: pointer;
    user-select: none;
    flex-grow: 1;
    font-size: 14px;
    line-height: 1.4;
}

.checklist-item input[type="checkbox"]:checked + label {
    text-decoration: line-through;
    color: #999;
}

.loading {
    text-align: center;
    padding: 40px;
    color: #999;
}

.month-selector {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 25px;
    gap: 10px;
}

.month-display {
    display: flex;
    gap: 10px;
}

.month-display select {
    padding: 10px;
    border: 2px solid #e0e0e0;
    border-radius: 8px;
    font-size: 14px;
    background: white;
}

.day-card {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 15px;
    margin-bottom: 10px;
    border: 2px solid #e0e0e0;
    border-radius: 10px;
    transition: all 0.3s;
}

.day-card:hover {
    border-color: #667eea;
    transform: translateX(5px);
}

.day-date {
    font-weight: 600;
    color: #333;
}

.day-percentage {
    font-size: 20px;
    font-weight: bold;
    padding: 8px 15px;
    border-radius: 8px;
}

.percentage-high {
    background: #d4edda;
    color: #155724;
}

.percentage-medium {
    background: #fff3cd;
    color: #856404;
}

.percentage-low {
    background: #f8d7da;
    color: #721c24;
}

.percentage-none {
    background: #f0f0f0;
    color: #999;
}

.empty-state {
    text-align: center;
    padding: 60px 20px;
    color: #999;
}

.empty-state p {
    font-size: 16px;
    margin-bottom: 10px;
}

.training-day-info {
    margin-bottom: 20px;
    text-align: center;
}

.training-day-info h2 {
    color: #667eea;
    font-size: 22px;
    margin-bottom: 10px;
}

.training-day-note {
    font-size: 13px;
    color: #666;
    font-style: italic;
    line-height: 1.6;
    padding: 10px;
    background: #f8f9fa;
    border-radius: 8px;
}

.training-exercises {
    padding: 10px;
}

.training-exercise-item {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    padding: 15px 8px;
    border-bottom: 1px solid #f0f0f0;
    gap: 15px;
}

.training-exercise-item:last-child {
    border-bottom: none;
}

.exercise-left {
    display: flex;
    align-items: flex-start;
    gap: 12px;
    flex: 1;
}

.exercise-left input[type="checkbox"] {
    width: 24px;
    height: 24px;
    margin-top: 2px;
    cursor: pointer;
    flex-shrink: 0;
}

.exercise-info {
    display: flex;
    flex-direction: column;
    gap: 4px;
    flex: 1;
}

.exercise-name {
    cursor: pointer;
    user-select: none;
    font-size: 15px;
    font-weight: 500;
    color: #333;
}

.exercise-sets {
    font-size: 13px;
    color: #667eea;
    font-weight: 600;
}

.exercise-notes {
    font-size: 12px;
    color: #999;
    font-style: italic;
}

.training-exercise-item input[type="checkbox"]:checked + .exercise-info .exercise-name {
    text-decoration: line-through;
    color: #999;
}

.exercise-right {
    display: flex;
    flex-direction: column;
    gap: 8px;
    min-width: 120px;
}

.weight-input {
    padding: 8px 10px;
    border: 2px solid #e0e0e0;
    border-radius: 6px;
    font-size: 13px;
    width: 100%;
}

.weight-input:focus {
    outline: none;
    border-color: #667eea;
}

@media (max-width: 600px) {
    .container {
        padding: 15px;
    }
    
    h1 {
        font-size: 20px;
    }
    
    nav {
        flex-wrap: wrap;
    }
    
    .month-selector {
        flex-direction: column;
    }
    
    .month-display {
        width: 100%;
    }
    
    .month-display select {
        flex: 1;
    }
    
    .btn {
        flex: 1;
        min-width: 90px;
    }
    
    .stats-summary {
        grid-template-columns: 1fr;
    }
    
    .training-exercise-item {
        flex-direction: column;
        align-items: stretch;
        gap: 10px;
    }
    
    .exercise-right {
        margin-left: 36px;
        min-width: auto;
    }
}
