/* ============================================
   MARATHON TRAINING APP - COMPLETE STYLES
   ============================================ */

/* Reset và thiết lập cơ bản */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    -webkit-tap-highlight-color: transparent;
}

:root {
    --primary: #5b5fde;
    --primary-dark: #4549b8;
    --success: #22c55e;
    --warning: #fb923c;
    --danger: #f87171;
    --bg: #0a0e27;
    --bg-card: #151935;
    --bg-card-hover: #1d2247;
    --text: #ffffff;
    --text-secondary: #94a3b8;
    --border: #2a3050;
    --safe-area-inset-top: env(safe-area-inset-top, 0px);
    --safe-area-inset-bottom: env(safe-area-inset-bottom, 0px);
    --weather-hot: #f87171;
    --weather-warm: #fb923c;
    --weather-cool: #60a5fa;
    --weather-cold: #a78bfa;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, sans-serif;
    background: linear-gradient(180deg, #0a0e27 0%, #151935 100%);
    color: var(--text);
    min-height: 100vh;
    min-height: -webkit-fill-available;
    padding-top: var(--safe-area-inset-top);
    padding-bottom: var(--safe-area-inset-bottom);
    overflow-x: hidden;
}

html {
    scroll-behavior: smooth;
}

/* ============================================
   CONTAINER & HEADER
   ============================================ */

.container {
    width: 100%;
    max-width: 100%;
    padding: 0;
}

.header {
    background: linear-gradient(135deg, var(--bg-card) 0%, var(--bg-card-hover) 100%);
    padding: 20px 16px;
    text-align: center;
    position: sticky;
    top: 0;
    z-index: 100;
    backdrop-filter: blur(10px);
    border-bottom: 1px solid var(--border);
}

.header h1 {
    font-size: 1.5rem;
    font-weight: 700;
    background: linear-gradient(135deg, var(--primary) 0%, var(--warning) 100%);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    margin-bottom: 4px;
}

.header p {
    font-size: 0.875rem;
    color: var(--text-secondary);
}

.location-info {
    font-size: 0.75rem;
    color: var(--text-secondary);
    margin-top: 4px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 4px;
}

.header-actions {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-top: 8px;
    justify-content: center;
}

.edit-indicator {
    background: rgba(251, 146, 60, 0.2);
    color: var(--warning);
    padding: 4px 8px;
    border-radius: 6px;
    font-size: 0.7rem;
    font-weight: 600;
    display: inline-flex;
    align-items: center;
    gap: 4px;
}

.reset-btn {
    background: rgba(248, 113, 113, 0.2);
    color: var(--danger);
    border: 1px solid rgba(248, 113, 113, 0.3);
    padding: 6px 12px;
    border-radius: 6px;
    font-size: 0.75rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s ease;
}

.reset-btn:hover {
    background: rgba(248, 113, 113, 0.3);
    transform: translateY(-1px);
}

/* ============================================
   TAB NAVIGATION
   ============================================ */

.tab-navigation {
    display: flex;
    background: var(--bg-card);
    border-radius: 12px;
    padding: 4px;
    margin: 16px;
    border: 1px solid var(--border);
}

.tab-btn {
    flex: 1;
    background: none;
    border: none;
    color: var(--text-secondary);
    padding: 12px 16px;
    border-radius: 8px;
    font-size: 0.875rem;
    font-weight: 600;
    transition: all 0.2s ease;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
}

.tab-btn:hover {
    color: var(--text);
    background: rgba(91, 95, 222, 0.1);
}

.tab-btn.active {
    background: linear-gradient(135deg, var(--primary) 0%, var(--primary-dark) 100%);
    color: white;
    box-shadow: 0 2px 8px rgba(91, 95, 222, 0.3);
}

.tab-icon {
    font-size: 1.2rem;
}

.tab-label {
    font-weight: 600;
}

.tab-content {
    display: none;
}

.tab-content.active {
    display: block;
}

/* ============================================
   MODAL/POPUP STYLES
   ============================================ */

.modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(10, 14, 39, 0.95);
    backdrop-filter: blur(10px);
    z-index: 1000;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.3s ease, visibility 0.3s ease;
}

.modal-overlay.active {
    opacity: 1;
    visibility: visible;
}

.modal-content {
    background: linear-gradient(135deg, var(--bg-card) 0%, var(--bg-card-hover) 100%);
    border-radius: 20px;
    max-width: 500px;
    width: 100%;
    max-height: 85vh;
    overflow-y: auto;
    position: relative;
    border: 1px solid var(--border);
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.5);
    transform: scale(0.9);
    transition: transform 0.3s ease;
}

.modal-overlay.active .modal-content {
    transform: scale(1);
}

.modal-header {
    position: sticky;
    top: 0;
    background: linear-gradient(135deg, var(--primary) 0%, var(--primary-dark) 100%);
    padding: 20px;
    border-radius: 20px 20px 0 0;
    display: flex;
    justify-content: space-between;
    align-items: center;
    z-index: 10;
}

.modal-title {
    font-size: 1.5rem;
    font-weight: 700;
    color: white;
}

.modal-date {
    font-size: 0.875rem;
    color: rgba(255, 255, 255, 0.8);
    margin-top: 4px;
}

.modal-close {
    background: rgba(255, 255, 255, 0.2);
    border: none;
    color: white;
    width: 36px;
    height: 36px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    font-size: 1.5rem;
    transition: background 0.2s ease;
    flex-shrink: 0;
}

.modal-close:hover {
    background: rgba(255, 255, 255, 0.3);
}

.modal-edit-btn {
    background: linear-gradient(135deg, var(--warning) 0%, #f59e0b 100%);
    border: none;
    color: white;
    width: 36px;
    height: 36px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    font-size: 1.2rem;
    transition: all 0.2s ease;
    flex-shrink: 0;
}

.modal-edit-btn:hover {
    transform: scale(1.1);
    box-shadow: 0 4px 12px rgba(251, 146, 60, 0.4);
}

.modal-body {
    padding: 24px;
}

.modal-workout-main {
    text-align: center;
    margin-bottom: 24px;
    padding: 20px;
    background: rgba(10, 14, 39, 0.3);
    border-radius: 12px;
}

.modal-workout-type {
    display: inline-block;
    padding: 8px 16px;
    border-radius: 20px;
    font-size: 0.875rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 12px;
}

.modal-workout-distance {
    font-size: 3rem;
    font-weight: 800;
    color: var(--warning);
    margin-bottom: 8px;
}

.modal-workout-description {
    font-size: 1.125rem;
    color: var(--text-secondary);
    line-height: 1.5;
}

.modal-section {
    margin-bottom: 24px;
}

.modal-section-title {
    font-size: 1rem;
    font-weight: 600;
    color: var(--text);
    margin-bottom: 12px;
    display: flex;
    align-items: center;
    gap: 8px;
}

.modal-section-content {
    background: rgba(10, 14, 39, 0.3);
    border-radius: 12px;
    padding: 16px;
    line-height: 1.6;
    color: var(--text-secondary);
}

/* ============================================
   EDIT FORM STYLES
   ============================================ */

.edit-form-group {
    margin-bottom: 20px;
}

.edit-label {
    display: block;
    font-size: 0.875rem;
    font-weight: 600;
    color: var(--text);
    margin-bottom: 8px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.edit-input {
    width: 100%;
    padding: 12px 16px;
    background: rgba(10, 14, 39, 0.5);
    border: 1px solid var(--border);
    border-radius: 8px;
    color: var(--text);
    font-size: 1rem;
    font-family: inherit;
    transition: all 0.2s ease;
}

.edit-input:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 0 3px rgba(91, 95, 222, 0.1);
}

.edit-textarea {
    resize: vertical;
    min-height: 80px;
    line-height: 1.5;
}

.edit-input::placeholder {
    color: var(--text-secondary);
}

.edit-form-actions {
    display: flex;
    gap: 12px;
    margin-top: 24px;
}

.edit-btn {
    flex: 1;
    padding: 12px 20px;
    border: none;
    border-radius: 8px;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s ease;
}

.edit-btn-cancel {
    background: rgba(148, 163, 184, 0.2);
    color: var(--text-secondary);
}

.edit-btn-cancel:hover {
    background: rgba(148, 163, 184, 0.3);
}

.edit-btn-save {
    background: linear-gradient(135deg, var(--success) 0%, #16a34a 100%);
    color: white;
}

.edit-btn-save:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(34, 197, 94, 0.3);
}

/* ============================================
   TODAY SECTION
   ============================================ */

.today-section {
    padding: 16px;
    background: var(--bg);
}

.today-card {
    background: linear-gradient(135deg, var(--bg-card) 0%, var(--bg-card-hover) 100%);
    border-radius: 16px;
    padding: 20px;
    position: relative;
    overflow: hidden;
    box-shadow: 0 4px 20px rgba(0,0,0,0.3);
}

.today-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 3px;
    background: linear-gradient(90deg, var(--primary) 0%, var(--warning) 50%, var(--primary) 100%);
}

.today-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 16px;
    flex-wrap: wrap;
    gap: 8px;
}

.today-badge {
    background: linear-gradient(135deg, var(--primary) 0%, var(--primary-dark) 100%);
    color: white;
    padding: 6px 12px;
    border-radius: 20px;
    font-size: 0.75rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.today-date {
    font-size: 0.875rem;
    color: var(--text-secondary);
}

.workout-main {
    margin: 20px 0;
}

.workout-title {
    font-size: 1.75rem;
    font-weight: 700;
    margin-bottom: 8px;
    color: var(--text);
}

.workout-distance {
    font-size: 2.5rem;
    font-weight: 800;
    color: var(--warning);
    margin-bottom: 16px;
}

.workout-details {
    background: rgba(10, 14, 39, 0.5);
    border-radius: 12px;
    padding: 16px;
    margin-top: 16px;
}

.detail-row {
    display: flex;
    flex-direction: column;
    margin-bottom: 12px;
}

.detail-row:last-child {
    margin-bottom: 0;
}

.detail-label {
    font-size: 0.75rem;
    color: var(--text-secondary);
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 4px;
}

.detail-value {
    font-size: 1rem;
    color: var(--text);
    line-height: 1.4;
}

.workout-type {
    display: inline-block;
    padding: 4px 10px;
    border-radius: 6px;
    font-size: 0.875rem;
    font-weight: 600;
    margin-top: 8px;
}

.type-easy { background: rgba(34, 197, 94, 0.2); color: #22c55e; }
.type-interval { background: rgba(248, 113, 113, 0.2); color: #f87171; }
.type-tempo { background: rgba(251, 146, 60, 0.2); color: #fb923c; }
.type-long { background: rgba(91, 95, 222, 0.2); color: #5b5fde; }
.type-core { background: rgba(168, 85, 247, 0.2); color: #a855f7; }
.type-rest { background: rgba(148, 163, 184, 0.2); color: #94a3b8; }

/* ============================================
   STATS SECTION
   ============================================ */

.stats-section {
    padding: 0 16px 16px;
}

.stats-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 12px;
}

.stat-card {
    background: var(--bg-card);
    border-radius: 12px;
    padding: 16px;
    text-align: center;
    border: 1px solid var(--border);
}

.stat-icon {
    font-size: 1.5rem;
    margin-bottom: 8px;
}

.stat-value {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--text);
    margin-bottom: 4px;
}

.stat-label {
    font-size: 0.75rem;
    color: var(--text-secondary);
    text-transform: uppercase;
}

/* ============================================
   WEEK VIEW
   ============================================ */

.week-section {
    padding: 16px 0;
    background: var(--bg);
}

.section-title {
    padding: 0 16px;
    font-size: 1.125rem;
    font-weight: 600;
    margin-bottom: 12px;
    color: var(--text);
}

.week-scroll {
    overflow-x: auto;
    padding: 0 16px 16px;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
}

.week-scroll::-webkit-scrollbar {
    display: none;
}

.week-container {
    display: flex;
    gap: 12px;
    width: max-content;
}

.day-card {
    background: var(--bg-card);
    border-radius: 12px;
    padding: 16px;
    min-width: 140px;
    border: 1px solid var(--border);
    transition: transform 0.2s, background 0.2s;
    cursor: pointer;
}

.day-card:active {
    transform: scale(0.98);
    background: var(--bg-card-hover);
}

.day-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(91, 95, 222, 0.2);
}

.day-card.is-today {
    background: linear-gradient(135deg, rgba(91, 95, 222, 0.2) 0%, rgba(91, 95, 222, 0.1) 100%);
    border: 2px solid var(--primary);
}

.day-name {
    font-size: 0.875rem;
    font-weight: 600;
    color: var(--text);
    margin-bottom: 4px;
}

.day-date {
    font-size: 0.75rem;
    color: var(--text-secondary);
    margin-bottom: 12px;
}

.day-workout {
    font-size: 0.875rem;
    font-weight: 500;
    color: var(--text);
    margin-bottom: 8px;
}

.day-distance {
    font-size: 1.125rem;
    font-weight: 700;
    color: var(--warning);
    margin-bottom: 12px;
}

/* ============================================
   MANAGE TAB STYLES
   ============================================ */

.manage-section {
    padding: 16px;
    background: var(--bg);
}

.manage-header {
    text-align: center;
    margin-bottom: 20px;
    padding: 20px;
    background: linear-gradient(135deg, var(--bg-card) 0%, var(--bg-card-hover) 100%);
    border-radius: 16px;
    border: 1px solid var(--border);
}

.manage-header h2 {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--text);
    margin-bottom: 8px;
}

.manage-header p {
    font-size: 0.875rem;
    color: var(--text-secondary);
}

.manage-filter {
    display: flex;
    gap: 8px;
    margin-bottom: 16px;
    padding: 0 4px;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
}

.filter-btn {
    flex: 1;
    min-width: 100px;
    padding: 10px 16px;
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: 8px;
    color: var(--text-secondary);
    font-size: 0.875rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s ease;
    white-space: nowrap;
}

.filter-btn:hover {
    background: var(--bg-card-hover);
    color: var(--text);
}

.filter-btn.active {
    background: linear-gradient(135deg, var(--primary) 0%, var(--primary-dark) 100%);
    color: white;
    border-color: var(--primary);
}

.manage-table-wrapper {
    background: var(--bg-card);
    border-radius: 12px;
    border: 1px solid var(--border);
    overflow: hidden;
}

.manage-table {
    width: 100%;
    border-collapse: collapse;
}

.manage-table thead {
    background: linear-gradient(135deg, var(--primary) 0%, var(--primary-dark) 100%);
    position: sticky;
    top: 0;
    z-index: 10;
}

.manage-table th {
    padding: 14px 12px;
    text-align: left;
    font-size: 0.75rem;
    font-weight: 700;
    color: white;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    white-space: nowrap;
}

.manage-table tbody tr {
    border-bottom: 1px solid var(--border);
    transition: background 0.2s ease;
    cursor: pointer;
}

.manage-table tbody tr:hover {
    background: var(--bg-card-hover);
}

.manage-table tbody tr.today-row {
    background: rgba(91, 95, 222, 0.1);
}

.manage-table tbody tr.today-row:hover {
    background: rgba(91, 95, 222, 0.15);
}

.manage-table tbody tr.past-row {
    opacity: 0.6;
}

.manage-table td {
    padding: 14px 12px;
    font-size: 0.875rem;
    color: var(--text);
    vertical-align: middle;
}

.manage-date-cell {
    font-weight: 600;
    white-space: nowrap;
    min-width: 80px;
}

.manage-day-cell {
    color: var(--text-secondary);
    font-size: 0.8rem;
    white-space: nowrap;
    min-width: 50px;
}

.manage-workout-cell {
    display: flex;
    align-items: center;
    gap: 8px;
    min-width: 120px;
}

.manage-workout-type {
    padding: 4px 8px;
    border-radius: 6px;
    font-size: 0.75rem;
    font-weight: 600;
    white-space: nowrap;
}

.manage-distance-cell {
    font-weight: 700;
    color: var(--warning);
    white-space: nowrap;
    min-width: 70px;
}

.manage-description-cell {
    max-width: 250px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    color: var(--text-secondary);
}

.manage-action-cell {
    text-align: center;
    min-width: 80px;
}

.manage-edit-btn {
    background: linear-gradient(135deg, var(--warning) 0%, #f59e0b 100%);
    color: white;
    border: none;
    padding: 6px 12px;
    border-radius: 6px;
    font-size: 0.75rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s ease;
    white-space: nowrap;
}

.manage-edit-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(251, 146, 60, 0.3);
}

.race-badge {
    display: inline-block;
    background: linear-gradient(135deg, var(--danger) 0%, #dc2626 100%);
    color: white;
    padding: 2px 8px;
    border-radius: 4px;
    font-size: 0.65rem;
    font-weight: 700;
    margin-left: 4px;
    text-transform: uppercase;
}

.week-separator {
    background: linear-gradient(135deg, rgba(91, 95, 222, 0.1) 0%, rgba(91, 95, 222, 0.05) 100%);
    font-weight: 600;
    color: var(--primary);
}

.week-separator td {
    padding: 12px;
    font-size: 0.875rem;
    border-top: 2px solid var(--primary);
    border-bottom: 2px solid var(--primary);
}

.manage-stats {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
    gap: 12px;
    margin-bottom: 16px;
}

.manage-stat-card {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: 12px;
    padding: 16px;
    text-align: center;
}

.manage-stat-value {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--warning);
    margin-bottom: 4px;
}

.manage-stat-label {
    font-size: 0.75rem;
    color: var(--text-secondary);
    text-transform: uppercase;
}

.manage-empty {
    text-align: center;
    padding: 60px 20px;
    color: var(--text-secondary);
}

.manage-empty-icon {
    font-size: 4rem;
    margin-bottom: 16px;
    opacity: 0.5;
}

.manage-empty h3 {
    font-size: 1.25rem;
    margin-bottom: 8px;
    color: var(--text);
}

.manage-empty p {
    font-size: 0.875rem;
}

/* ============================================
   SWIMMING SECTION
   ============================================ */

.swimming-section {
    padding: 16px;
    background: var(--bg);
}

.swimming-card {
    background: linear-gradient(135deg, var(--bg-card) 0%, var(--bg-card-hover) 100%);
    border-radius: 16px;
    padding: 20px;
    margin-bottom: 16px;
    border: 1px solid var(--border);
    position: relative;
    overflow: hidden;
}

.swimming-header {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 16px;
}

.swimming-title {
    font-size: 1.25rem;
    font-weight: 700;
    color: var(--text);
}

.swimming-time {
    font-size: 0.875rem;
    color: var(--text-secondary);
    background: rgba(10, 14, 39, 0.5);
    padding: 4px 12px;
    border-radius: 8px;
}

.swimming-recommendation {
    background: rgba(10, 14, 39, 0.5);
    border-radius: 12px;
    padding: 16px;
}

.recommendation-text {
    font-size: 0.875rem;
    line-height: 1.5;
    color: var(--text-secondary);
}

/* ============================================
   LOADING & EMPTY STATES
   ============================================ */

.loading {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    min-height: 50vh;
    padding: 20px;
}

.spinner {
    width: 48px;
    height: 48px;
    border: 3px solid var(--border);
    border-top-color: var(--primary);
    border-radius: 50%;
    animation: spin 1s linear infinite;
    margin-bottom: 16px;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

.mini-spinner {
    width: 16px;
    height: 16px;
    border: 2px solid var(--border);
    border-top-color: var(--primary);
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

.no-workout {
    text-align: center;
    padding: 40px 20px;
}

.no-workout h2 {
    font-size: 1.5rem;
    margin-bottom: 8px;
}

.no-workout p {
    color: var(--text-secondary);
    font-size: 0.875rem;
}

/* ============================================
   FOOTER
   ============================================ */

.copyright-footer {
    background: var(--bg-card);
    border-top: 1px solid var(--border);
    padding: 20px 16px;
    margin-top: 20px;
    text-align: center;
}

.copyright-text {
    font-size: 0.75rem;
    color: var(--text-secondary);
    line-height: 1.5;
    margin-bottom: 8px;
}

.copyright-logo {
    font-size: 0.875rem;
    font-weight: 600;
    color: var(--primary);
    margin-bottom: 4px;
}

.footer-logo-img {
    max-width: 150px;
    height: auto;
    margin-bottom: 8px;
}

.internal-use {
    font-size: 0.7rem;
    color: rgba(148, 163, 184, 0.7);
    font-style: italic;
    margin-top: 8px;
}

/* ============================================
   RESPONSIVE
   ============================================ */

@media (max-width: 480px) {
    .tab-label {
        display: none;
    }
    
    .tab-icon {
        font-size: 1.4rem;
    }
    
    .modal-content {
        max-height: 90vh;
        margin: 10px;
    }

    .modal-workout-distance {
        font-size: 2.5rem;
    }
}

@media (max-width: 768px) {
    .manage-table-wrapper {
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
    }
    
    .manage-table {
        min-width: 800px;
    }
    
    .manage-table th,
    .manage-table td {
        padding: 10px 8px;
        font-size: 0.8rem;
    }
    
    .manage-description-cell {
        max-width: 120px;
    }
    
    .today-badge,
    .race-badge {
        font-size: 0.55rem;
        padding: 2px 4px;
    }
    
    .manage-edit-btn {
        padding: 4px 8px;
        font-size: 0.7rem;
    }
}

@media (min-width: 768px) {
    .container {
        max-width: 768px;
        margin: 0 auto;
        padding: 20px;
    }

    .header {
        border-radius: 16px;
        margin-bottom: 20px;
    }

    .header h1 {
        font-size: 2rem;
    }

    .stats-grid {
        grid-template-columns: repeat(4, 1fr);
    }

    .week-container {
        display: grid;
        grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
        width: 100%;
    }

    .day-card {
        min-width: unset;
    }

    .modal-content {
        max-width: 600px;
    }
}

/* iOS specific */
@supports (-webkit-touch-callout: none) {
    body {
        -webkit-user-select: none;
        user-select: none;
        -webkit-touch-callout: none;
    }

    .day-card:active {
        -webkit-tap-highlight-color: rgba(91, 95, 222, 0.2);
    }
}