/* ═══════════════════════════════════════════
   FITNESS CHALLENGE — Glassmorphic Athletic
   ═══════════════════════════════════════════ */

:root {
    --bg-deep: var(--tg-theme-bg-color, #0a0a12);
    --bg-card: var(--tg-theme-secondary-bg-color, #14141f);
    --text-primary: var(--tg-theme-text-color, #f0f0f5);
    --text-muted: var(--tg-theme-hint-color, #6e6e82);
    --accent: var(--tg-theme-button-color, #6c5ce7);
    --accent-text: var(--tg-theme-button-text-color, #ffffff);

    --glass: rgba(255,255,255, 0.04);
    --glass-border: rgba(255,255,255, 0.06);
    --glass-hover: rgba(255,255,255, 0.07);

    --lime: #a8e06c;
    --amber: #ffb347;
    --coral: #ff6b6b;
    --cyan: #6cc4e0;

    --radius: 16px;
    --radius-sm: 10px;
    --nav-h: 72px;
    --safe-bottom: env(safe-area-inset-bottom, 0px);
}

/* ── Reset ── */
*, *::before, *::after { margin:0; padding:0; box-sizing:border-box; }
html { -webkit-text-size-adjust: 100%; }

body {
    font-family: 'DM Sans', system-ui, sans-serif;
    background: var(--bg-deep);
    color: var(--text-primary);
    min-height: 100dvh;
    overflow-x: hidden;
    -webkit-font-smoothing: antialiased;
}

#app {
    position: relative;
    max-width: 480px;
    margin: 0 auto;
    padding-bottom: calc(var(--nav-h) + var(--safe-bottom) + 12px);
}

.app-footer {
    position: relative;
    z-index: 1;
    margin: 22px auto 4px;
    padding: 0 18px;
    text-align: center;
    color: var(--text-muted);
    font-size: 11px;
    line-height: 1.4;
}

.app-footer a {
    color: var(--accent);
    text-decoration: none;
    font-weight: 700;
}

/* ── Ambient background glow ── */
#bg-glow {
    position: fixed;
    top: -120px;
    left: 50%;
    transform: translateX(-50%);
    width: 400px;
    height: 400px;
    background: radial-gradient(circle, rgba(108,92,231,.15) 0%, transparent 70%);
    pointer-events: none;
    z-index: 0;
    animation: glowPulse 8s ease-in-out infinite;
}
@keyframes glowPulse {
    0%,100% { opacity:.6; transform:translateX(-50%) scale(1); }
    50% { opacity:1; transform:translateX(-50%) scale(1.15); }
}

/* ── Bottom Navigation ── */
#nav {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    height: calc(var(--nav-h) + var(--safe-bottom));
    padding-bottom: var(--safe-bottom);
    display: flex;
    align-items: center;
    justify-content: stretch;
    background: linear-gradient(to top, var(--bg-deep) 60%, transparent);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    z-index: 100;
}

.nav-item {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 3px;
    text-decoration: none;
    color: var(--text-muted);
    transition: color .25s, transform .2s;
    -webkit-tap-highlight-color: transparent;
    padding: 6px 0;
}
.nav-item:active { transform: scale(.9); }
.nav-item.active { color: var(--accent); }

.nav-icon {
    width: 22px;
    height: 22px;
}

.nav-label {
    font-size: 9px;
    font-weight: 500;
    letter-spacing: .2px;
    max-width: 100%;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    text-transform: uppercase;
}

/* Center check-in button */
.nav-item--checkin { position: relative; }
.nav-checkin-ring {
    width: 46px;
    height: 46px;
    border-radius: 50%;
    background: var(--accent);
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 4px 20px rgba(108,92,231,.4);
    transition: transform .2s, box-shadow .2s;
}
.nav-checkin-ring .nav-icon { color: #fff; width: 20px; height: 20px; }
.nav-item--checkin:active .nav-checkin-ring { transform: scale(.88); }
.nav-item--checkin.active .nav-checkin-ring {
    box-shadow: 0 4px 28px rgba(108,92,231,.6);
}

/* ── Content area ── */
#content {
    position: relative;
    z-index: 1;
    padding: 20px 16px;
    animation: fadeUp .35s ease-out;
}
@keyframes fadeUp {
    from { opacity:0; transform:translateY(12px); }
    to { opacity:1; transform:translateY(0); }
}

/* ── Glass Card ── */
.card {
    background: var(--glass);
    border: 1px solid var(--glass-border);
    border-radius: var(--radius);
    padding: 18px;
    margin-bottom: 14px;
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    animation: cardIn .4s ease-out both;
}
.card:nth-child(2) { animation-delay: .06s; }
.card:nth-child(3) { animation-delay: .12s; }
.card:nth-child(4) { animation-delay: .18s; }
.card:nth-child(5) { animation-delay: .24s; }
@keyframes cardIn {
    from { opacity:0; transform:translateY(16px) scale(.97); }
    to { opacity:1; transform:translateY(0) scale(1); }
}

.card-label {
    font-family: 'Outfit', sans-serif;
    font-size: 11px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 1.2px;
    color: var(--text-muted);
    margin-bottom: 12px;
}

/* ── Page Heading ── */
.page-head {
    margin-bottom: 22px;
    animation: fadeUp .3s ease-out;
}
.page-head h1 {
    font-family: 'Outfit', sans-serif;
    font-weight: 900;
    font-size: 26px;
    letter-spacing: -.5px;
    line-height: 1.15;
}
.page-head p {
    color: var(--text-muted);
    font-size: 14px;
    margin-top: 4px;
}

/* ── Stats Row ── */
.stats-row {
    display: grid;
    grid-template-columns: 1fr 1fr 1fr;
    gap: 10px;
    margin-bottom: 14px;
}
.stat-tile {
    background: var(--glass);
    border: 1px solid var(--glass-border);
    border-radius: var(--radius);
    padding: 16px 10px;
    text-align: center;
    animation: cardIn .4s ease-out both;
}
.stat-tile:nth-child(1) { animation-delay:.04s; }
.stat-tile:nth-child(2) { animation-delay:.1s; }
.stat-tile:nth-child(3) { animation-delay:.16s; }

.stat-num {
    font-family: 'Outfit', sans-serif;
    font-weight: 800;
    font-size: 32px;
    line-height: 1;
}
.stat-num.lime  { color: var(--lime); }
.stat-num.amber { color: var(--amber); }
.stat-num.coral { color: var(--coral); }

.stat-tag {
    font-size: 11px;
    font-weight: 500;
    color: var(--text-muted);
    margin-top: 6px;
    text-transform: uppercase;
    letter-spacing: .6px;
}

/* ── Quick Check-in (Dashboard) ── */
.quick-checkin {
    width: 100%;
    padding: 18px;
    border: none;
    border-radius: var(--radius);
    font-family: 'Outfit', sans-serif;
    font-weight: 700;
    font-size: 17px;
    letter-spacing: .3px;
    cursor: pointer;
    position: relative;
    overflow: hidden;
    transition: transform .15s, box-shadow .25s;
    -webkit-tap-highlight-color: transparent;
}
.quick-checkin:active { transform: scale(.97); }

.quick-checkin--ready {
    background: linear-gradient(135deg, var(--accent), #8b5cf6);
    color: #fff;
    box-shadow: 0 6px 24px rgba(108,92,231,.35);
}
.quick-checkin--ready::before {
    content:'';
    position: absolute;
    inset: 0;
    background: linear-gradient(135deg, transparent 40%, rgba(255,255,255,.12) 100%);
}

.quick-checkin--done {
    background: var(--glass);
    border: 1px solid rgba(168,224,108,.25);
    color: var(--lime);
    box-shadow: none;
}
.quick-checkin:disabled { cursor: default; }


/* ── Today Dashboard ── */
.page-head--today { margin-bottom: 14px; }
.today-panel {
    padding: 20px;
    position: relative;
    overflow: hidden;
}
.today-panel::before {
    content: '';
    position: absolute;
    inset: 0;
    pointer-events: none;
    background: linear-gradient(135deg, rgba(108,92,231,.18), transparent 55%);
}
.today-panel--done::before { background: linear-gradient(135deg, rgba(168,224,108,.16), transparent 55%); }
.today-panel--risk::before { background: linear-gradient(135deg, rgba(255,179,71,.18), transparent 55%); }
.today-status-row {
    position: relative;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    margin-bottom: 16px;
}
.today-status-pill,
.today-rank {
    border-radius: 999px;
    padding: 6px 10px;
    font-size: 11px;
    font-weight: 800;
    letter-spacing: .6px;
    text-transform: uppercase;
}
.today-status-pill.is-open {
    color: var(--amber);
    border: 1px solid rgba(255,179,71,.35);
    background: rgba(255,179,71,.12);
}
.today-status-pill.is-done {
    color: var(--lime);
    border: 1px solid rgba(168,224,108,.35);
    background: rgba(168,224,108,.12);
}
.today-rank {
    color: var(--text-muted);
    border: 1px solid var(--glass-border);
    background: rgba(255,255,255,.03);
}
.today-panel h2 {
    position: relative;
    font-family: 'Outfit', sans-serif;
    font-weight: 900;
    font-size: 24px;
    line-height: 1.08;
    margin-bottom: 8px;
}
.today-panel p {
    position: relative;
    color: var(--text-muted);
    font-size: 14px;
    line-height: 1.45;
    margin-bottom: 16px;
}
.today-metrics {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 8px;
    margin-bottom: 12px;
}
.today-metric {
    min-height: 108px;
    border: 1px solid var(--glass-border);
    border-radius: var(--radius-sm);
    background: rgba(255,255,255,.035);
    padding: 12px 10px;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
}
.today-metric-label {
    font-size: 10px;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: .7px;
    font-weight: 700;
}
.today-metric strong {
    font-family: 'Outfit', sans-serif;
    font-size: 30px;
    line-height: 1;
}
.today-metric strong.lime { color: var(--lime); }
.today-metric strong.amber { color: var(--amber); }
.today-metric strong.cyan { color: var(--cyan); }
.today-metric small {
    color: var(--text-muted);
    font-size: 11px;
    line-height: 1.2;
}
.today-risk-strip {
    border-radius: var(--radius-sm);
    border: 1px solid var(--glass-border);
    padding: 12px 14px;
    margin-bottom: 14px;
    display: flex;
    flex-direction: column;
    gap: 3px;
    background: rgba(255,255,255,.03);
}
.today-risk-strip strong {
    font-size: 13px;
    font-weight: 800;
}
.today-risk-strip span {
    font-size: 12px;
    color: var(--text-muted);
}
.today-risk-strip.is-ok {
    border-color: rgba(168,224,108,.25);
    background: rgba(168,224,108,.08);
}
.today-risk-strip.is-warning {
    border-color: rgba(255,179,71,.3);
    background: rgba(255,179,71,.1);
}

/* ── Fasting Card ── */
.fasting-card {
    position: relative;
    overflow: hidden;
}
.fasting-card::before {
    content: '';
    position: absolute;
    inset: 0;
    pointer-events: none;
    background: linear-gradient(125deg, rgba(108,92,231,.12), transparent 40%);
}
.fasting-head {
    display: flex;
    justify-content: space-between;
    align-items: center;
}
.fasting-badge {
    font-size: 10px;
    letter-spacing: .8px;
    border-radius: 999px;
    padding: 4px 9px;
    font-weight: 700;
    border: 1px solid transparent;
}
.fasting-badge--off {
    color: var(--text-muted);
    border-color: var(--glass-border);
    background: rgba(255,255,255,.02);
}
.fasting-badge--on {
    color: var(--amber);
    border-color: rgba(255,179,71,.3);
    background: rgba(255,179,71,.12);
}
.fasting-badge--done {
    color: var(--lime);
    border-color: rgba(168,224,108,.4);
    background: rgba(168,224,108,.12);
}
.fasting-target-row {
    display: flex;
    flex-direction: column;
    gap: 8px;
    margin-bottom: 10px;
}
.fasting-target-label {
    font-size: 12px;
    color: var(--text-muted);
}
.fasting-target-options {
    display: flex;
    gap: 6px;
    flex-wrap: wrap;
}
.fasting-target-pill {
    border: 1px solid var(--glass-border);
    background: rgba(255,255,255,.02);
    color: var(--text-muted);
    border-radius: 999px;
    min-width: 44px;
    height: 32px;
    padding: 0 10px;
    font-size: 12px;
    font-weight: 700;
}
.fasting-target-pill.active {
    color: #fff;
    border-color: var(--accent);
    background: linear-gradient(135deg, var(--accent), #8b5cf6);
}
.fasting-hint {
    font-size: 12px;
    color: var(--text-muted);
    margin-bottom: 10px;
}
.fasting-time-row {
    display: flex;
    justify-content: space-between;
    align-items: flex-end;
    gap: 10px;
}
.fasting-elapsed {
    font-family: 'Outfit', sans-serif;
    font-weight: 900;
    font-size: 30px;
    letter-spacing: .2px;
}
.fasting-target-static {
    font-size: 12px;
    color: var(--text-muted);
}
.fasting-remaining {
    margin-top: 5px;
    font-size: 13px;
    color: var(--text-muted);
}
.fasting-progress-track {
    height: 8px;
    margin-top: 10px;
    border-radius: 999px;
    background: rgba(255,255,255,.06);
    overflow: hidden;
}
.fasting-progress-fill {
    height: 100%;
    border-radius: 999px;
    width: 0;
    background: linear-gradient(90deg, var(--accent), #8b5cf6, var(--lime));
    transition: width .7s cubic-bezier(.22,1,.36,1);
}
.fasting-feedback {
    margin-top: 10px;
    margin-bottom: 2px;
    border-radius: 10px;
    padding: 9px 10px;
    font-size: 12px;
    border: 1px solid var(--glass-border);
}
.fasting-feedback--success {
    color: var(--lime);
    border-color: rgba(168,224,108,.3);
    background: rgba(168,224,108,.08);
}
.fasting-feedback--error {
    color: var(--coral);
    border-color: rgba(255,107,107,.35);
    background: rgba(255,107,107,.08);
}
.fasting-feedback--info {
    color: var(--text-muted);
    background: rgba(255,255,255,.04);
}
.fasting-history {
    margin-top: 12px;
    border-top: 1px solid var(--glass-border);
    padding-top: 10px;
}
.fasting-history-title {
    font-size: 11px;
    text-transform: uppercase;
    letter-spacing: .7px;
    color: var(--text-muted);
    margin-bottom: 8px;
}
.fasting-history-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 6px 0;
    gap: 10px;
}
.fasting-history-left,
.fasting-history-right {
    display: flex;
    align-items: center;
    gap: 8px;
}
.fasting-history-day {
    font-size: 12px;
    color: var(--text-muted);
    min-width: 56px;
}
.fasting-history-target {
    font-size: 12px;
    font-weight: 700;
}
.fasting-history-duration {
    font-family: 'Outfit', sans-serif;
    font-weight: 700;
    font-size: 13px;
}
.fasting-history-status {
    font-size: 11px;
    border-radius: 999px;
    padding: 2px 8px;
    border: 1px solid var(--glass-border);
}
.fasting-history-status.ok {
    color: var(--lime);
    border-color: rgba(168,224,108,.3);
    background: rgba(168,224,108,.08);
}
.fasting-history-status.off {
    color: var(--text-muted);
    background: rgba(255,255,255,.03);
}

/* ── Progress Bar ── */
.progress-track {
    height: 6px;
    background: rgba(255,255,255,.06);
    border-radius: 3px;
    overflow: hidden;
    margin-top: 10px;
}
.progress-bar {
    height: 100%;
    border-radius: 3px;
    background: linear-gradient(90deg, var(--accent), #8b5cf6);
    transition: width .6s cubic-bezier(.22,1,.36,1);
}

/* ── Info Chips ── */
.info-row {
    display: flex;
    gap: 10px;
    margin-top: 4px;
}
.info-chip {
    flex: 1;
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 12px;
    background: var(--glass);
    border: 1px solid var(--glass-border);
    border-radius: var(--radius-sm);
    font-size: 13px;
}
.info-chip .ic-icon {
    width: 32px;
    height: 32px;
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 16px;
    flex-shrink: 0;
}
.info-chip .ic-icon.amber-bg { background: rgba(255,179,71,.12); }
.info-chip .ic-icon.cyan-bg  { background: rgba(108,196,224,.12); }
.info-chip .ic-val { font-weight: 700; font-size: 16px; }
.info-chip .ic-lbl { font-size: 11px; color: var(--text-muted); }

/* ════════════════════
   LEADERBOARD
   ════════════════════ */
.filter-row {
    display: flex;
    gap: 6px;
    margin-bottom: 16px;
    animation: fadeUp .3s ease-out .08s both;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
    flex-wrap: nowrap;
}
.filter-row::-webkit-scrollbar { display: none; }
.filter-pill {
    padding: 8px 18px;
    border: 1px solid var(--glass-border);
    border-radius: 24px;
    background: transparent;
    color: var(--text-muted);
    font-family: 'DM Sans', sans-serif;
    font-size: 13px;
    font-weight: 500;
    cursor: pointer;
    transition: all .2s;
    -webkit-tap-highlight-color: transparent;
    white-space: nowrap;
    flex-shrink: 0;
}
.filter-pill.active {
    background: var(--accent);
    border-color: var(--accent);
    color: #fff;
}

.lb-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 14px 0;
    border-bottom: 1px solid var(--glass-border);
    animation: fadeUp .3s ease-out both;
}
.lb-item:last-child { border-bottom: none; }

.lb-rank {
    width: 36px;
    height: 36px;
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-family: 'Outfit', sans-serif;
    font-weight: 800;
    font-size: 15px;
    flex-shrink: 0;
}
.lb-rank.gold   { background: rgba(255,215,0,.12);  color: #ffd700; }
.lb-rank.silver { background: rgba(192,192,192,.10); color: #c0c0c0; }
.lb-rank.bronze { background: rgba(205,127,50,.10);  color: #cd7f32; }
.lb-rank.normal { background: var(--glass); color: var(--text-muted); }

/* Leaderboard Avatars */
.lb-avatar-wrap {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    flex-shrink: 0;
    position: relative;
    overflow: hidden;
    background: linear-gradient(135deg, var(--accent), #8b5cf6);
    display: flex;
    align-items: center;
    justify-content: center;
}
.lb-avatar-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    border-radius: 50%;
    position: absolute;
    inset: 0;
}
.lb-avatar-initials {
    font-family: 'Outfit', sans-serif;
    font-weight: 800;
    font-size: 13px;
    color: #fff;
    line-height: 1;
}

.lb-info { flex:1; min-width:0; }
.lb-name {
    font-weight: 600;
    font-size: 15px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}
.lb-meta {
    font-size: 12px;
    color: var(--text-muted);
    margin-top: 2px;
    display: flex;
    gap: 10px;
}
.lb-val {
    font-family: 'Outfit', sans-serif;
    font-weight: 800;
    font-size: 18px;
    color: var(--lime);
    flex-shrink: 0;
}
.lb-right {
    min-width: 56px;
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    gap: 4px;
}
.lb-fast {
    font-size: 11px;
    color: var(--text-muted);
    padding: 2px 7px;
    border-radius: 999px;
    border: 1px solid var(--glass-border);
    background: rgba(255,255,255,.02);
}

/* ════════════════════
   CHECK-IN PAGE
   ════════════════════ */
.checkin-hero {
    text-align: center;
    padding: 28px 16px;
}
.checkin-quick-presets {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 8px;
    margin-bottom: 10px;
}
.checkin-preset {
    border: 1px solid var(--glass-border);
    background: rgba(255,255,255,.03);
    color: var(--text-primary);
    border-radius: var(--radius-sm);
    padding: 10px 8px;
    font-size: 12px;
    font-weight: 700;
    cursor: pointer;
}
.checkin-preset span {
    display: block;
    font-size: 10px;
    color: var(--text-muted);
    font-weight: 500;
    margin-top: 3px;
}
.checkin-preset.active {
    border-color: var(--accent);
    background: rgba(108,92,231,.18);
}
.checkin-summary {
    font-size: 12px;
    color: var(--text-muted);
    margin: 8px 0 12px;
}
.checkin-advanced-toggle {
    width: 100%;
    margin-bottom: 10px;
    border: 1px solid var(--glass-border);
    background: transparent;
    color: var(--text-muted);
    border-radius: var(--radius-sm);
    padding: 10px 12px;
    font-size: 12px;
    font-weight: 600;
    cursor: pointer;
}
.checkin-form.is-hidden {
    display: none;
}
.checkin-done-icon {
    width: 64px;
    height: 64px;
    border-radius: 50%;
    margin: 0 auto 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-family: 'Outfit', sans-serif;
    font-weight: 800;
    font-size: 28px;
    background: rgba(168,224,108,.15);
    color: var(--lime);
    border: 1px solid rgba(168,224,108,.3);
}
.checkin-ring {
    width: 140px;
    height: 140px;
    border-radius: 50%;
    margin: 0 auto 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    cursor: pointer;
    -webkit-tap-highlight-color: transparent;
    transition: transform .2s;
}
.checkin-ring:active { transform: scale(.93); }

.checkin-ring--ready {
    background: linear-gradient(135deg, var(--accent), #8b5cf6);
    box-shadow: 0 0 40px rgba(108,92,231,.3), 0 0 80px rgba(108,92,231,.1);
    animation: ringPulse 2.5s ease-in-out infinite;
}
@keyframes ringPulse {
    0%,100% { box-shadow: 0 0 40px rgba(108,92,231,.3), 0 0 80px rgba(108,92,231,.1); }
    50% { box-shadow: 0 0 50px rgba(108,92,231,.45), 0 0 100px rgba(108,92,231,.15); }
}

.checkin-ring--done {
    background: linear-gradient(135deg, rgba(168,224,108,.15), rgba(168,224,108,.05));
    border: 2px solid rgba(168,224,108,.3);
    box-shadow: none;
    animation: none;
}

.checkin-ring svg {
    width: 48px;
    height: 48px;
    color: #fff;
}
.checkin-ring--done svg { color: var(--lime); }

.checkin-ring .ring-ripple {
    position: absolute;
    inset: -8px;
    border-radius: 50%;
    border: 2px solid rgba(108,92,231,.3);
    animation: ripple 2.5s ease-out infinite;
}
@keyframes ripple {
    0% { transform:scale(1); opacity:.6; }
    100% { transform:scale(1.35); opacity:0; }
}

.checkin-label {
    font-family: 'Outfit', sans-serif;
    font-weight: 700;
    font-size: 18px;
    margin-top: 4px;
}
.checkin-sublabel {
    font-size: 13px;
    color: var(--text-muted);
    margin-top: 4px;
}


.modal-preset-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 8px;
    margin-bottom: 10px;
}
.checkin-presets-card { padding-bottom: 10px; }

/* ── Calendar ── */
.cal-grid {
    display: grid;
    grid-template-columns: repeat(7, 1fr);
    gap: 4px;
    margin-top: 10px;
}
.cal-hdr {
    text-align: center;
    font-size: 10px;
    font-weight: 600;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: .5px;
    padding: 6px 0;
}
.cal-day {
    aspect-ratio: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 8px;
    font-size: 12px;
    font-weight: 500;
    color: var(--text-muted);
    transition: background .2s;
}
.cal-day.checked  { background: rgba(168,224,108,.18); color: var(--lime); font-weight: 700; }
.cal-day.strike   { background: rgba(255,107,107,.15); color: var(--coral); }
.cal-day.rest     { background: rgba(255,255,255,.04); }
.cal-day.today    { border: 1.5px solid var(--accent); }

/* ════════════════════
   GOALS PAGE
   ════════════════════ */
.goal-current {
    text-align: center;
    padding: 8px 0;
}
.goal-big {
    font-family: 'Outfit', sans-serif;
    font-weight: 800;
    font-size: 42px;
    line-height: 1;
    background: linear-gradient(135deg, var(--accent), #8b5cf6, var(--lime));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}
.goal-of {
    font-size: 13px;
    color: var(--text-muted);
    margin-top: 6px;
}
.goal-text {
    font-size: 15px;
    font-weight: 600;
    margin-top: 14px;
}

/* ── Form ── */
.form-field {
    margin-bottom: 16px;
}
.form-field label {
    display: block;
    font-size: 12px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: .8px;
    color: var(--text-muted);
    margin-bottom: 8px;
}
.form-field input,
.form-field select {
    width: 100%;
    padding: 14px;
    border: 1px solid var(--glass-border);
    border-radius: var(--radius-sm);
    background: rgba(255,255,255,.03);
    color: var(--text-primary);
    font-family: 'DM Sans', sans-serif;
    font-size: 15px;
    transition: border-color .2s;
    -webkit-appearance: none;
}
.form-field input:focus,
.form-field select:focus {
    outline: none;
    border-color: var(--accent);
}
.form-field select {
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 24 24' fill='none' stroke='%236e6e82' stroke-width='2'%3E%3Cpolyline points='6 9 12 15 18 9'%3E%3C/polyline%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 14px center;
    padding-right: 36px;
}

.btn-primary {
    width: 100%;
    padding: 16px;
    border: none;
    border-radius: var(--radius);
    background: linear-gradient(135deg, var(--accent), #8b5cf6);
    color: #fff;
    font-family: 'Outfit', sans-serif;
    font-weight: 700;
    font-size: 16px;
    letter-spacing: .3px;
    cursor: pointer;
    transition: transform .15s, opacity .2s;
    -webkit-tap-highlight-color: transparent;
}
.btn-primary:active { transform: scale(.97); }
.btn-primary:disabled { opacity: .5; cursor: default; }
.btn-primary.success {
    background: rgba(168,224,108,.15);
    color: var(--lime);
}
.btn-orange {
    background: linear-gradient(135deg, #ff9f43, #ff7a00);
    box-shadow: 0 6px 22px rgba(255, 122, 0, .28);
}
.checkin-photo-actions {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 8px;
}
.checkin-photo-actions .btn-primary {
    font-size: 13px;
    padding: 12px 10px;
}

/* ── Utility ── */
.loading {
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 60px 0;
    color: var(--text-muted);
    font-size: 14px;
    gap: 10px;
}
.loading::before {
    content: '';
    width: 18px;
    height: 18px;
    border: 2px solid var(--glass-border);
    border-top-color: var(--accent);
    border-radius: 50%;
    animation: spin .7s linear infinite;
}
@keyframes spin { to { transform: rotate(360deg); } }

.empty-state {
    text-align: center;
    padding: 40px 20px;
    color: var(--text-muted);
    font-size: 14px;
}

/* ── Stagger helper ── */
[data-stagger] > * {
    animation: fadeUp .35s ease-out both;
}
[data-stagger] > *:nth-child(1) { animation-delay: .04s; }
[data-stagger] > *:nth-child(2) { animation-delay: .08s; }
[data-stagger] > *:nth-child(3) { animation-delay: .10s; }
[data-stagger] > *:nth-child(4) { animation-delay: .14s; }
[data-stagger] > *:nth-child(5) { animation-delay: .18s; }
[data-stagger] > *:nth-child(6) { animation-delay: .22s; }

/* ── Celebration burst ── */
@keyframes burst {
    0% { transform: scale(.5); opacity: 1; }
    100% { transform: scale(2.5); opacity: 0; }
}
.burst-ring {
    position: absolute;
    inset: 0;
    border-radius: 50%;
    border: 3px solid var(--lime);
    animation: burst .6s ease-out forwards;
    pointer-events: none;
}

/* ════════════════════
   WORKOUT TYPE PILLS
   ════════════════════ */
.workout-type-selector {
    display: flex;
    gap: 6px;
    justify-content: center;
    margin-bottom: 18px;
    flex-wrap: wrap;
}
.wt-pill {
    padding: 8px 14px;
    border: 1px solid var(--glass-border);
    border-radius: 24px;
    background: transparent;
    color: var(--text-muted);
    font-family: 'DM Sans', sans-serif;
    font-size: 12px;
    font-weight: 500;
    cursor: pointer;
    transition: all .2s;
    -webkit-tap-highlight-color: transparent;
    white-space: nowrap;
}
.wt-pill.active {
    background: var(--accent);
    border-color: var(--accent);
    color: #fff;
}
.wt-pill:active { transform: scale(.95); }

/* ════════════════════
   DISQUALIFICATION
   ════════════════════ */
.dq-banner {
    background: rgba(255,107,107,.12);
    border: 1px solid rgba(255,107,107,.25);
    border-radius: var(--radius);
    padding: 14px 18px;
    margin-bottom: 14px;
    font-size: 14px;
    color: var(--coral);
    text-align: center;
    animation: cardIn .4s ease-out both;
}
.dq-badge {
    display: inline-block;
    padding: 1px 6px;
    border-radius: 4px;
    background: rgba(255,107,107,.2);
    color: var(--coral);
    font-size: 10px;
    font-weight: 700;
    letter-spacing: .5px;
    margin-left: 4px;
    vertical-align: middle;
}
.lb-item--dq {
    opacity: .45;
}

/* ════════════════════
   PROFILE — Player Card
   ════════════════════ */
.profile-hero {
    text-align: center;
    padding: 8px 0 20px;
    animation: fadeUp .35s ease-out;
}
.profile-avatar-wrap {
    display: flex;
    justify-content: center;
    margin-bottom: 12px;
}
.profile-avatar {
    width: 80px;
    height: 80px;
    border-radius: 50%;
    object-fit: cover;
    border: 3px solid var(--accent);
    box-shadow: 0 0 24px rgba(108,92,231,.3);
}
.profile-avatar-initials {
    width: 80px;
    height: 80px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-family: 'Outfit', sans-serif;
    font-weight: 800;
    font-size: 28px;
    color: #fff;
    background: linear-gradient(135deg, var(--accent), #8b5cf6);
    border: 3px solid var(--accent);
    box-shadow: 0 0 24px rgba(108,92,231,.3);
}
.profile-hero-name {
    font-family: 'Outfit', sans-serif;
    font-weight: 800;
    font-size: 22px;
    letter-spacing: -.3px;
}
.profile-rank {
    display: inline-block;
    margin-top: 6px;
    padding: 4px 14px;
    border-radius: 20px;
    background: rgba(168,224,108,.1);
    border: 1px solid rgba(168,224,108,.2);
    color: var(--lime);
    font-size: 12px;
    font-weight: 700;
    letter-spacing: .3px;
}

/* Stats Grid 2x2 */
.profile-stats-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 10px;
    margin-bottom: 14px;
}
.profile-stat-tile {
    background: var(--glass);
    border: 1px solid var(--glass-border);
    border-radius: var(--radius);
    padding: 16px 12px;
    text-align: center;
    animation: cardIn .4s ease-out both;
}
.profile-stat-tile:nth-child(1) { animation-delay:.04s; }
.profile-stat-tile:nth-child(2) { animation-delay:.08s; }
.profile-stat-tile:nth-child(3) { animation-delay:.12s; }
.profile-stat-tile:nth-child(4) { animation-delay:.16s; }

/* Goal Progress */
.profile-goal-text {
    font-size: 14px;
    font-weight: 600;
    margin-bottom: 8px;
}
.profile-goal-bar {
    display: flex;
    align-items: center;
    gap: 10px;
}
.profile-goal-bar .progress-track {
    flex: 1;
    margin-top: 0;
}
.profile-goal-pct {
    font-family: 'Outfit', sans-serif;
    font-weight: 700;
    font-size: 14px;
    color: var(--accent);
    flex-shrink: 0;
}

/* Body Metrics Chips */
.profile-metrics-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 8px;
    margin-bottom: 12px;
}
.profile-metric-chip {
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 10px 8px;
    background: rgba(255,255,255,.03);
    border: 1px solid var(--glass-border);
    border-radius: var(--radius-sm);
}
.metric-val {
    font-family: 'Outfit', sans-serif;
    font-weight: 700;
    font-size: 16px;
}
.metric-lbl {
    font-size: 10px;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: .5px;
    margin-top: 2px;
}

/* Edit Toggle Button */
.edit-toggle-btn {
    width: 100%;
    padding: 10px;
    border: 1px solid var(--glass-border);
    border-radius: var(--radius-sm);
    background: transparent;
    color: var(--text-muted);
    font-family: 'DM Sans', sans-serif;
    font-size: 13px;
    font-weight: 600;
    cursor: pointer;
    transition: all .2s;
    -webkit-tap-highlight-color: transparent;
}
.edit-toggle-btn:active { transform: scale(.97); }
.edit-toggle-btn.active {
    border-color: var(--accent);
    color: var(--accent);
}

/* Sport Breakdown */
.sport-list {
    display: flex;
    flex-direction: column;
    gap: 8px;
}
.sport-item {
    display: flex;
    align-items: center;
    gap: 8px;
}
.sport-icon {
    font-size: 16px;
    width: 24px;
    text-align: center;
    flex-shrink: 0;
}
.sport-name {
    font-size: 13px;
    font-weight: 500;
    text-transform: capitalize;
    min-width: 70px;
    flex-shrink: 0;
}
.sport-bar-track {
    flex: 1;
    height: 6px;
    background: rgba(255,255,255,.06);
    border-radius: 3px;
    overflow: hidden;
}
.sport-bar-fill {
    height: 100%;
    border-radius: 3px;
    background: linear-gradient(90deg, var(--accent), #8b5cf6);
    transition: width .6s cubic-bezier(.22,1,.36,1);
}
.sport-count {
    font-family: 'Outfit', sans-serif;
    font-weight: 700;
    font-size: 14px;
    color: var(--text-muted);
    min-width: 24px;
    text-align: right;
    flex-shrink: 0;
}

/* Record Cards */
.record-card {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 10px 0;
    border-bottom: 1px solid var(--glass-border);
}
.record-card:last-child { border-bottom: none; }
.record-icon {
    font-size: 20px;
    flex-shrink: 0;
}
.record-info { flex: 1; min-width: 0; }
.record-exercise {
    font-weight: 600;
    font-size: 14px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}
.record-type {
    font-size: 11px;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: .3px;
}
.record-value {
    font-family: 'Outfit', sans-serif;
    font-weight: 800;
    font-size: 18px;
    color: var(--lime);
    flex-shrink: 0;
}

/* Profile Achievements */
.profile-achievement {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 10px 0;
    border-bottom: 1px solid var(--glass-border);
}
.profile-achievement:last-child { border-bottom: none; }
.profile-ach-icon {
    font-size: 24px;
    flex-shrink: 0;
}
.profile-ach-info { flex: 1; }
.profile-ach-name {
    font-weight: 700;
    font-size: 13px;
}
.profile-ach-desc {
    font-size: 11px;
    color: var(--text-muted);
    margin-top: 1px;
}

/* Edit Section */
.profile-edit-section {
    animation: cardIn .4s ease-out both;
}

/* ════════════════════
   EXERCISE LIBRARY
   ════════════════════ */
.muscle-group-pills {
    display: flex;
    gap: 6px;
    margin-bottom: 14px;
    overflow-x: auto;
    padding-bottom: 4px;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
}
.muscle-group-pills::-webkit-scrollbar { display: none; }

.exercise-item {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 14px 16px;
    background: var(--glass);
    border: 1px solid var(--glass-border);
    border-radius: var(--radius-sm);
    margin-bottom: 6px;
    animation: fadeUp .25s ease-out both;
}
.exercise-info { flex: 1; min-width: 0; }
.exercise-name {
    font-weight: 600;
    font-size: 14px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}
.exercise-meta {
    font-size: 11px;
    color: var(--text-muted);
    margin-top: 3px;
    display: flex;
    gap: 8px;
}
.equipment-badge {
    padding: 1px 6px;
    border-radius: 4px;
    background: rgba(108,196,224,.1);
    color: var(--cyan);
    font-size: 10px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: .3px;
}
.btn-add-exercise {
    width: 36px;
    height: 36px;
    border-radius: 10px;
    border: 1px solid var(--glass-border);
    background: var(--glass);
    color: var(--accent);
    font-size: 20px;
    font-weight: 700;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    transition: all .2s;
    -webkit-tap-highlight-color: transparent;
}
.btn-add-exercise:active { transform: scale(.9); background: var(--accent); color: #fff; }

/* ── Templates ── */
.template-list {
    display: flex;
    gap: 8px;
    overflow-x: auto;
    padding-bottom: 4px;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
}
.template-list::-webkit-scrollbar { display: none; }
.template-btn {
    flex-shrink: 0;
    padding: 12px 16px;
    border: 1px solid var(--glass-border);
    border-radius: var(--radius-sm);
    background: var(--glass);
    color: var(--text-primary);
    cursor: pointer;
    text-align: left;
    transition: all .2s;
    -webkit-tap-highlight-color: transparent;
    min-width: 120px;
}
.template-btn:active { transform: scale(.97); border-color: var(--accent); }
.template-name { display: block; font-weight: 600; font-size: 13px; }
.template-desc { display: block; font-size: 11px; color: var(--text-muted); margin-top: 2px; }

/* ── Set Logger Modal ── */
.modal-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0,0,0,.6);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    z-index: 200;
    display: flex;
    align-items: flex-end;
    justify-content: center;
    animation: fadeIn .2s ease-out;
}
@keyframes fadeIn { from { opacity:0; } to { opacity:1; } }

.modal-content {
    width: 100%;
    max-width: 480px;
    background: var(--bg-card);
    border-radius: var(--radius) var(--radius) 0 0;
    padding: 24px 20px calc(24px + var(--safe-bottom));
    animation: slideUp .3s ease-out;
    max-height: 85vh;
    overflow-y: auto;
}
@keyframes slideUp {
    from { transform: translateY(100%); }
    to { transform: translateY(0); }
}
.modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 16px;
}
.modal-header h3 {
    font-family: 'Outfit', sans-serif;
    font-weight: 700;
    font-size: 18px;
}
.modal-close {
    width: 32px;
    height: 32px;
    border: none;
    background: var(--glass);
    border-radius: 50%;
    color: var(--text-muted);
    font-size: 18px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
}

.set-row {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 8px;
}
.set-num {
    width: 24px;
    height: 24px;
    border-radius: 6px;
    background: var(--glass);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 11px;
    font-weight: 700;
    color: var(--text-muted);
    flex-shrink: 0;
}
.set-reps, .set-weight {
    flex: 1;
    padding: 10px;
    border: 1px solid var(--glass-border);
    border-radius: var(--radius-sm);
    background: rgba(255,255,255,.03);
    color: var(--text-primary);
    font-family: 'DM Sans', sans-serif;
    font-size: 14px;
    -webkit-appearance: none;
}
.set-reps:focus, .set-weight:focus { outline: none; border-color: var(--accent); }
.set-warmup-label {
    font-size: 11px;
    color: var(--text-muted);
    display: flex;
    align-items: center;
    gap: 3px;
    cursor: pointer;
    flex-shrink: 0;
}

.btn-add-set {
    width: 100%;
    padding: 10px;
    border: 1px dashed var(--glass-border);
    border-radius: var(--radius-sm);
    background: transparent;
    color: var(--text-muted);
    font-size: 13px;
    cursor: pointer;
    margin-bottom: 8px;
    transition: all .2s;
}
.btn-add-set:active { border-color: var(--accent); color: var(--accent); }

/* ── Logged Exercises ── */
.logged-exercise {
    padding: 10px 0;
    border-bottom: 1px solid var(--glass-border);
}
.logged-exercise:last-child { border-bottom: none; }
.logged-name { font-weight: 600; font-size: 13px; }
.logged-sets { display: flex; gap: 6px; flex-wrap: wrap; margin-top: 4px; }
.set-badge {
    padding: 2px 8px;
    border-radius: 4px;
    background: rgba(168,224,108,.1);
    color: var(--lime);
    font-size: 11px;
    font-weight: 600;
}

/* ── Template Exercise List (Modal) ── */
.tpl-exercise-item {
    padding: 10px 0;
    border-bottom: 1px solid var(--glass-border);
}
.tpl-exercise-item:last-child { border-bottom: none; }
.tpl-ex-name { font-weight: 600; font-size: 14px; }
.tpl-ex-meta { font-size: 12px; color: var(--text-muted); margin-top: 2px; }
.tpl-ex-notes { font-size: 11px; color: var(--amber); font-style: italic; margin-top: 2px; }

/* ════════════════════
   PROGRESS & CHARTS
   ════════════════════ */
.tab-row {
    display: flex;
    gap: 6px;
    margin-bottom: 16px;
    animation: fadeUp .3s ease-out .08s both;
}

.chart-container {
    position: relative;
    width: 100%;
    overflow: hidden;
}
.chart-container canvas {
    width: 100%;
    height: auto;
}

.chart-weight-input {
    flex: 1;
    padding: 12px;
    border: 1px solid var(--glass-border);
    border-radius: var(--radius-sm);
    background: rgba(255,255,255,.03);
    color: var(--text-primary);
    font-family: 'DM Sans', sans-serif;
    font-size: 15px;
    -webkit-appearance: none;
}
.chart-weight-input:focus { outline: none; border-color: var(--accent); }

.btn-small {
    padding: 12px 20px;
    border: none;
    border-radius: var(--radius-sm);
    background: var(--accent);
    color: #fff;
    font-family: 'Outfit', sans-serif;
    font-weight: 700;
    font-size: 14px;
    cursor: pointer;
    transition: transform .15s;
    -webkit-tap-highlight-color: transparent;
    white-space: nowrap;
}
.btn-small:active { transform: scale(.95); }
.btn-small:disabled { opacity: .5; }

/* ════════════════════
   PERSONAL RECORDS
   ════════════════════ */
.pr-entry {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 10px 0;
    border-bottom: 1px solid var(--glass-border);
}
.pr-entry:last-child { border-bottom: none; }
.pr-type {
    font-size: 12px;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: .5px;
    min-width: 70px;
}
.pr-value {
    font-family: 'Outfit', sans-serif;
    font-weight: 800;
    font-size: 18px;
    color: var(--lime);
    flex: 1;
}
.pr-date {
    font-size: 11px;
    color: var(--text-muted);
}
.pr-prev {
    font-size: 11px;
    color: var(--text-muted);
}

/* ════════════════════
   ACHIEVEMENTS
   ════════════════════ */
.badge-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(140px, 1fr));
    gap: 10px;
}
.badge-item {
    text-align: center;
    padding: 16px 10px;
    border-radius: var(--radius-sm);
    border: 1px solid var(--glass-border);
    transition: transform .2s;
}
.badge-item:active { transform: scale(.97); }
.badge-earned {
    background: rgba(168,224,108,.08);
    border-color: rgba(168,224,108,.2);
}
.badge-locked {
    opacity: .4;
    filter: grayscale(1);
}
.badge-icon {
    font-size: 28px;
    margin-bottom: 6px;
}
.badge-name {
    font-weight: 700;
    font-size: 13px;
    margin-bottom: 2px;
}
.badge-desc {
    font-size: 11px;
    color: var(--text-muted);
}

/* ════════════════════
   TOAST NOTIFICATIONS
   ════════════════════ */
.achievement-toast {
    position: fixed;
    top: 0;
    left: 50%;
    transform: translateX(-50%) translateY(-100%);
    z-index: 300;
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 14px 20px;
    background: var(--bg-card);
    border: 1px solid rgba(168,224,108,.3);
    border-radius: 0 0 var(--radius) var(--radius);
    box-shadow: 0 8px 32px rgba(0,0,0,.4);
    transition: transform .3s cubic-bezier(.22,1,.36,1);
    max-width: 360px;
    width: 90%;
}
.achievement-toast.toast-visible {
    transform: translateX(-50%) translateY(0);
}
.toast-icon {
    font-size: 28px;
    flex-shrink: 0;
}
.toast-content { flex: 1; }
.toast-title {
    font-family: 'Outfit', sans-serif;
    font-weight: 700;
    font-size: 14px;
    color: var(--lime);
}
.toast-desc {
    font-size: 12px;
    color: var(--text-muted);
    margin-top: 1px;
}

/* ════════════════════
   RULES PAGE
   ════════════════════ */
.rules-list {
    display: flex;
    flex-direction: column;
    gap: 2px;
}
.rule-item {
    display: flex;
    align-items: flex-start;
    gap: 12px;
    padding: 12px 0;
    border-bottom: 1px solid var(--glass-border);
    animation: fadeUp .3s ease-out both;
}
.rule-item:last-child { border-bottom: none; }
.rule-item:nth-child(1) { animation-delay: .02s; }
.rule-item:nth-child(2) { animation-delay: .04s; }
.rule-item:nth-child(3) { animation-delay: .06s; }
.rule-item:nth-child(4) { animation-delay: .08s; }
.rule-item:nth-child(5) { animation-delay: .10s; }
.rule-item:nth-child(6) { animation-delay: .12s; }
.rule-item:nth-child(7) { animation-delay: .14s; }
.rule-item:nth-child(8) { animation-delay: .16s; }
.rule-num {
    width: 28px;
    height: 28px;
    border-radius: 8px;
    background: var(--glass);
    display: flex;
    align-items: center;
    justify-content: center;
    font-family: 'Outfit', sans-serif;
    font-weight: 800;
    font-size: 13px;
    color: var(--accent);
    flex-shrink: 0;
}
.rule-text {
    font-size: 14px;
    line-height: 1.5;
    padding-top: 3px;
}
.rule-item--warn {
    background: rgba(255,107,107,.06);
    border-radius: var(--radius-sm);
    padding: 12px;
    margin: 4px 0;
}
.rule-item--warn .rule-num {
    background: rgba(255,107,107,.15);
    color: var(--coral);
}

/* ════════════════════
   STATS CARD BUTTON
   ════════════════════ */
.btn-stats-card {
    width: 100%;
    padding: 14px;
    border: 1px solid var(--glass-border);
    border-radius: var(--radius);
    background: var(--glass);
    color: var(--text-primary);
    font-family: 'Outfit', sans-serif;
    font-weight: 600;
    font-size: 15px;
    cursor: pointer;
    transition: all .2s;
    -webkit-tap-highlight-color: transparent;
    margin-top: 14px;
}
.btn-stats-card:active { transform: scale(.97); border-color: var(--accent); }
.btn-stats-card:disabled { opacity: .5; cursor: default; }

/* ════════════════════
   DASHBOARD LINKS
   ════════════════════ */
.dash-links {
    display: flex;
    justify-content: center;
    gap: 16px;
    margin-top: 16px;
    padding: 8px 0;
}
.dash-link {
    color: var(--text-muted);
    font-size: 13px;
    text-decoration: none;
    transition: color .2s;
}
.dash-link:active { color: var(--accent); }

/* ════════════════════
   PHOTO UPLOAD BUTTON
   ════════════════════ */
.btn-photo {
    background: var(--glass);
    border: 1px solid var(--glass-border);
    color: var(--text-primary);
}
.btn-photo.success {
    background: rgba(168,224,108,.15);
    color: var(--lime);
    border-color: rgba(168,224,108,.25);
}

/* ════════════════════
   BACK BUTTON
   ════════════════════ */
.back-btn {
    width: 36px;
    height: 36px;
    border-radius: 10px;
    border: 1px solid var(--glass-border);
    background: var(--glass);
    color: var(--text-primary);
    font-size: 18px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    transition: all .2s;
    -webkit-tap-highlight-color: transparent;
}
.back-btn:active { transform: scale(.9); border-color: var(--accent); }

/* ════════════════════
   GOAL TYPE PILLS (Profile)
   ════════════════════ */
.goal-type-pills {
    display: flex;
    gap: 6px;
    flex-wrap: wrap;
}

.steps-quick-row {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-top: 8px;
}

.alert-warn {
    border: 1px solid rgba(255, 165, 0, 0.35);
    background: rgba(255, 165, 0, 0.08);
    color: var(--text-primary);
}


.clan-pick-card { margin-bottom: 8px; }

.btn-secondary {
    width: 100%;
    padding: 14px;
    border-radius: var(--radius-sm);
    background: var(--glass);
    border: 1px solid var(--glass-border);
    color: var(--text-primary);
    font-family: 'DM Sans', sans-serif;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: all .2s;
    -webkit-tap-highlight-color: transparent;
}
.btn-secondary:active { transform: scale(.98); background: var(--glass-hover); }
