/* ============================================================
   Cloverleaf Throws — site.css
   Design language matched to cloverleaftrack.com
   ============================================================ */

:root {
    --navy: #1a2332;
    --navy-light: #1F4E79;
    --navy-mid: #2a3a50;
    --green: #2d8a4e;
    --green-light: #e8f5ee;
    --green-dark: #1e6b38;
    --white: #ffffff;
    --off-white: #f8f9fa;
    --gray-50: #f9fafb;
    --gray-100: #f3f4f6;
    --gray-200: #e5e7eb;
    --gray-300: #d1d5db;
    --gray-400: #9ca3af;
    --gray-500: #6b7280;
    --gray-600: #4b5563;
    --gray-700: #374151;
    --gray-800: #1f2937;
    --text: #1a1a1a;
    --text-muted: #6b7280;
    --text-light: #9ca3af;
    --border: #e5e7eb;
    --shadow-sm: 0 1px 2px rgba(0,0,0,0.05);
    --shadow-md: 0 4px 6px -1px rgba(0,0,0,0.07), 0 2px 4px -2px rgba(0,0,0,0.05);
    --shadow-lg: 0 10px 15px -3px rgba(0,0,0,0.08), 0 4px 6px -4px rgba(0,0,0,0.03);
    --radius: 10px;
    --radius-sm: 6px;
    --radius-lg: 14px;
    /* Day type colors */
    --oly-bg: #D6E4F0; --oly-text: #1F4E79; --oly-border: #a8c4de;
    --upper-bg: #E2EFDA; --upper-text: #375623; --upper-border: #b8d4a4;
    --throw-bg: #FCE4D6; --throw-text: #C55A11; --throw-border: #f0c4a8;
    --jump-bg: #FFF2CC; --jump-text: #7F6000; --jump-border: #e8d89c;
    --full-bg: #D9D2E9; --full-text: #4A3670; --full-border: #b8adce;
    --sp-bg: #FCE4D6; --sp-text: #C55A11;
    --dt-bg: #D6E4F0; --dt-text: #1F4E79;
}

/* ---- Reset & Base ---- */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

html { font-size: 16px; -webkit-font-smoothing: antialiased; }

body {
    font-family: 'DM Sans', -apple-system, BlinkMacSystemFont, sans-serif;
    color: var(--text);
    background: var(--off-white);
    line-height: 1.6;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

/* ---- Navigation ---- */
.site-nav {
    background: var(--navy);
    padding: 0 2rem;
    position: sticky;
    top: 0;
    z-index: 100;
}

.nav-inner {
    max-width: 1200px;
    margin: 0 auto;
    display: flex;
    align-items: center;
    justify-content: space-between;
    height: 60px;
}

.nav-brand {
    font-size: 1.25rem;
    font-weight: 700;
    color: var(--white);
    text-decoration: none;
    letter-spacing: -0.02em;
}

.nav-links { display: flex; gap: 0.25rem; }

.nav-link {
    color: rgba(255,255,255,0.7);
    text-decoration: none;
    font-size: 0.875rem;
    font-weight: 500;
    padding: 0.5rem 1rem;
    border-radius: var(--radius-sm);
    transition: all 0.15s ease;
}
.nav-link:hover { color: var(--white); background: rgba(255,255,255,0.08); }
.nav-link.active { color: var(--white); background: rgba(255,255,255,0.12); }

/* ---- Main Content ---- */
.site-content {
    flex: 1;
    max-width: 1200px;
    margin: 0 auto;
    padding: 2rem;
    width: 100%;
}

/* ---- Footer ---- */
.site-footer {
    text-align: center;
    padding: 1.5rem 2rem;
    color: var(--text-muted);
    font-size: 0.8125rem;
    border-top: 1px solid var(--border);
    background: var(--white);
}
.site-footer a { color: var(--green); text-decoration: none; }
.site-footer a:hover { text-decoration: underline; }
.footer-dot { margin: 0 0.5rem; }

/* ---- Page Headers ---- */
.page-header {
    margin-bottom: 2rem;
}
.page-header h1 {
    font-size: 1.75rem;
    font-weight: 700;
    color: var(--text);
    letter-spacing: -0.03em;
}
.page-header p {
    color: var(--text-muted);
    margin-top: 0.25rem;
    font-size: 0.9375rem;
}

/* ---- Cards ---- */
.card {
    background: var(--white);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    overflow: hidden;
}
.card-padded { padding: 1.25rem 1.5rem; }

/* ---- Tags / Badges ---- */
.tag {
    display: inline-flex;
    align-items: center;
    padding: 0.2rem 0.65rem;
    border-radius: 999px;
    font-size: 0.6875rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.04em;
    white-space: nowrap;
}

/* ============================================================
   CALENDAR VIEW
   ============================================================ */

.calendar-week {
    margin-bottom: 1.5rem;
}
.calendar-week-label {
    font-size: 0.8125rem;
    font-weight: 600;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 0.06em;
    margin-bottom: 0.75rem;
}
.calendar-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
    gap: 0.75rem;
}

.cal-day {
    display: flex;
    flex-direction: column;
    text-decoration: none;
    color: inherit;
    border-radius: var(--radius);
    background: var(--white);
    border: 1px solid var(--border);
    overflow: hidden;
    transition: all 0.15s ease;
}
.cal-day:hover {
    box-shadow: var(--shadow-md);
    border-color: var(--gray-300);
    transform: translateY(-1px);
}

.cal-day-header {
    padding: 0.625rem 0.875rem 0.5rem;
    border-bottom: 1px solid var(--gray-100);
    display: flex;
    align-items: center;
    justify-content: space-between;
}
.cal-day-date {
    font-size: 0.8125rem;
    font-weight: 600;
    color: var(--text);
}
.cal-day-num {
    font-size: 0.6875rem;
    color: var(--text-light);
}

.cal-day-body {
    padding: 0.75rem 0.875rem;
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.cal-day-type {
    font-size: 0.8125rem;
    font-weight: 600;
}

.cal-day-tags { display: flex; gap: 0.375rem; flex-wrap: wrap; }

.cal-day-focus {
    font-size: 0.75rem;
    color: var(--text-muted);
    margin-top: auto;
}

.cal-day.is-today {
    border-color: var(--green);
    box-shadow: 0 0 0 1px var(--green);
}
.cal-day.is-today .cal-day-header {
    background: var(--green-light);
}
.cal-day.is-today .cal-day-date {
    color: var(--green-dark);
}

/* ============================================================
   WORKOUT DETAIL VIEW
   ============================================================ */

.workout-hero {
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 1rem;
    margin-bottom: 2rem;
}
.workout-hero-left h1 {
    font-size: 2rem;
    font-weight: 700;
    letter-spacing: -0.03em;
    display: flex;
    align-items: baseline;
    gap: 0.75rem;
}
.workout-hero-left h1 .day-num {
    color: var(--navy-light);
}
.workout-hero-left .workout-date {
    color: var(--text-muted);
    font-size: 1rem;
    margin-top: 0.125rem;
}
.workout-hero-tags {
    display: flex;
    gap: 0.5rem;
    margin-top: 0.5rem;
}
.workout-hero-right {
    display: flex;
    gap: 0.5rem;
}

.btn {
    display: inline-flex;
    align-items: center;
    gap: 0.375rem;
    padding: 0.5rem 1rem;
    font-size: 0.8125rem;
    font-weight: 600;
    border-radius: var(--radius-sm);
    text-decoration: none;
    cursor: pointer;
    border: 1px solid var(--border);
    background: var(--white);
    color: var(--text);
    transition: all 0.15s ease;
    font-family: inherit;
}
.btn:hover { background: var(--gray-50); border-color: var(--gray-300); }
.btn-primary {
    background: var(--navy);
    color: var(--white);
    border-color: var(--navy);
}
.btn-primary:hover { background: var(--navy-mid); }
.btn-danger { background: #b91c1c; color: #fff; border-color: #b91c1c; }
.btn-danger:hover { background: #991b1b; border-color: #991b1b; }

.btn svg { width: 16px; height: 16px; }

/* Section grid */
.workout-sections {
    display: grid;
    grid-template-columns: 1fr 1.3fr 1fr;
    gap: 1.25rem;
    align-items: start;
}

.workout-sections--two-col {
    grid-template-columns: 1fr 1fr;
}

@media (max-width: 900px) {
    .workout-sections {
        grid-template-columns: 1fr;
    }
}

.workout-section { margin-bottom: 0; }

.section-card {
    background: var(--white);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    overflow: hidden;
}

.section-header {
    padding: 0.625rem 1rem;
    font-size: 0.75rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    border-bottom: 1px solid rgba(0,0,0,0.06);
}

.section-body { padding: 0; }

/* Exercise rows */
.exercise-group-label {
    padding: 0.375rem 1rem;
    font-size: 0.6875rem;
    font-weight: 600;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 0.05em;
    background: var(--gray-50);
    border-bottom: 1px solid var(--gray-100);
}

.exercise-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0.5rem 1rem;
    border-bottom: 1px solid var(--gray-100);
    gap: 0.75rem;
}
.exercise-row:last-child { border-bottom: none; }

.exercise-left {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    flex: 1;
    min-width: 0;
}
.exercise-num {
    font-size: 0.6875rem;
    font-weight: 700;
    color: var(--navy-light);
    min-width: 1.5rem;
}
.exercise-name {
    font-size: 0.875rem;
    color: var(--text);
}
.exercise-reps {
    font-size: 0.8125rem;
    color: var(--text-muted);
    white-space: nowrap;
    font-variant-numeric: tabular-nums;
}

/* Coach notes */
.coach-notes {
    background: var(--gray-50);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 1rem 1.25rem;
    margin-top: 1.5rem;
}
.coach-notes-label {
    font-size: 0.6875rem;
    font-weight: 700;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 0.06em;
    margin-bottom: 0.375rem;
}
.coach-notes p {
    font-size: 0.875rem;
    color: var(--text-muted);
    line-height: 1.5;
}

/* No workout state */
.no-workout {
    text-align: center;
    padding: 4rem 2rem;
}
.no-workout h2 {
    font-size: 1.25rem;
    color: var(--text);
    margin-bottom: 0.5rem;
}
.no-workout p {
    color: var(--text-muted);
    margin-bottom: 1.5rem;
}

/* ============================================================
   PRINT VIEW
   ============================================================ */

.print-layout {
    max-width: 1100px;
    margin: 0 auto;
    padding: 2rem;
}

@media print {
    .site-nav, .site-footer, .no-print { display: none !important; }
    body { background: white; }
    .site-content { padding: 0; max-width: none; }
    .print-layout { padding: 0; max-width: none; }

    .workout-sections {
        grid-template-columns: 1fr 1.3fr 1fr;
        gap: 1rem;
    }
    .section-card { break-inside: avoid; }

    .workout-hero { margin-bottom: 1.5rem; }

    @page {
        size: landscape;
        margin: 0.5in;
    }
}

/* ============================================================
   RESPONSIVE
   ============================================================ */

@media (max-width: 768px) {
    .site-content { padding: 1.25rem; }
    .calendar-grid { grid-template-columns: 1fr 1fr; }
    .workout-hero h1 { font-size: 1.5rem; }
    .nav-inner { padding: 0; }
    .site-nav { padding: 0 1rem; }
}

@media (max-width: 480px) {
    .calendar-grid { grid-template-columns: 1fr; }
}
