:root{--bg: #0b0f0e;--surface: #131a18;--surface-2: #0f1413;--surface-3: #1c2421;--border: #1f2926;--border-strong: #26302c;--text: #f3f5f4;--text-soft: #c9d1cd;--text-muted: #9aa5a0;--nav-idle: #8a9690;--accent: #10b981;--accent-hover: #34d399;--accent-text: #10b981;--accent-soft: #0f2a21;--accent-border: #165c44;--accent-soft-text: #a7c9bb;--on-accent: #04130d;--bar: #1e6b52;--goal-line: #4b5a54;--danger: #f87171;--danger-soft: #2a1515;--danger-border: #3a2626;--radius-lg: 24px;--radius-md: 20px;--radius-sm: 14px;color-scheme:dark}:root[data-theme=light]{--bg: #f4f7f6;--surface: #ffffff;--surface-2: #ffffff;--surface-3: #eef2f0;--border: #dde5e2;--border-strong: #cbd6d2;--text: #0b1512;--text-soft: #33413c;--text-muted: #5a6762;--nav-idle: #5a6762;--accent-hover: #059669;--accent-text: #047857;--accent-soft: #d1fae5;--accent-border: #a7f3d0;--accent-soft-text: #065f46;--bar: #a7e3cb;--goal-line: #8a9a94;--danger: #dc2626;--danger-soft: #fee2e2;--danger-border: #fecaca;color-scheme:light}*{box-sizing:border-box}body{margin:0;min-height:100vh;background:var(--bg);color:var(--text);font-family:Inter,system-ui,sans-serif;-webkit-font-smoothing:antialiased}h1,h2,h3,p{margin:0}button,input{font-family:inherit}a{color:var(--accent-text)}a:hover{color:var(--accent-hover)}:focus-visible{outline:2px solid var(--accent-hover);outline-offset:2px}.sr-only{position:absolute;width:1px;height:1px;padding:0;margin:-1px;overflow:hidden;clip:rect(0,0,0,0);white-space:nowrap;border:0}.page{display:flex;flex-direction:column;gap:16px}.page-header{display:flex;flex-direction:column;gap:4px}.eyebrow{font-size:13px;font-weight:500;color:var(--text-muted)}.page-title{font-size:28px;font-weight:700;letter-spacing:-.02em}.section-label{font-size:12px;font-weight:600;letter-spacing:.06em;text-transform:uppercase;color:var(--text-muted)}.card{background:var(--surface);border:1px solid var(--border);border-radius:var(--radius-md);padding:16px}.card-title{font-size:16px;font-weight:600}.empty-state{display:flex;flex-direction:column;align-items:center;gap:10px;padding:32px 20px;text-align:center;color:var(--text-muted);font-size:14px;line-height:1.5}.logo{display:inline-flex;align-items:center;gap:10px}.logo-mark{flex-shrink:0;border-radius:30%;background:var(--accent);color:var(--on-accent);display:flex;align-items:center;justify-content:center}.logo-name{font-size:20px;font-weight:700;letter-spacing:-.02em;color:var(--text)}.avatar{flex-shrink:0;border-radius:999px;border:2px solid var(--accent);background:var(--accent-soft);color:var(--accent-text);font-weight:700;display:flex;align-items:center;justify-content:center;object-fit:cover}.ring{position:relative;aspect-ratio:1}.ring>svg{display:block;width:100%;height:100%}.ring-progress{transition:stroke-dashoffset .6s ease}.ring-content{position:absolute;inset:0;display:flex;flex-direction:column;align-items:center;justify-content:center;gap:2px}.btn{display:inline-flex;align-items:center;justify-content:center;gap:8px;min-height:44px;padding:0 20px;border:1px solid transparent;border-radius:999px;font-weight:600;font-size:15px;line-height:1;text-decoration:none;white-space:nowrap;cursor:pointer;transition:background .15s,border-color .15s,color .15s}.btn:disabled{opacity:.6;cursor:not-allowed}.btn-primary,.btn-primary:hover{color:var(--on-accent)}.btn-primary{background:var(--accent)}.btn-primary:hover{background:var(--accent-hover)}.btn-secondary{background:var(--surface);border-color:var(--border-strong);color:var(--text)}.btn-secondary:hover{border-color:var(--accent);color:var(--text)}.btn-danger{border-radius:var(--radius-sm);background:transparent;border-color:var(--danger-border);color:var(--danger)}.btn-danger:hover{background:var(--danger-soft)}.btn-block{width:100%}.btn-lg{min-height:54px;font-size:16px}.btn-sm{min-height:40px;padding:0 18px;font-size:13px}.link-button{padding:0;border:0;background:none;color:var(--accent-text);font-weight:600;font-size:13px;line-height:1.4;cursor:pointer}.link-button:hover{color:var(--accent-hover)}.field{display:flex;flex-direction:column;gap:8px;min-width:0}.field-label-row{display:flex;justify-content:space-between;align-items:center;gap:8px}.field label{font-size:13px;font-weight:600;color:var(--text-soft)}.input{width:100%;height:52px;padding:0 16px;border:1px solid var(--border);border-radius:var(--radius-sm);background:var(--surface);color:var(--text);font-size:15px}.input::placeholder{color:var(--nav-idle)}.input:focus{outline:none;border-color:var(--accent);box-shadow:0 0 0 3px var(--accent-soft)}.input[aria-invalid=true]{border-color:var(--danger)}.field-error{font-size:13px;line-height:1.4;color:var(--danger)}.field-hint{font-size:12px;color:var(--text-muted)}.form-actions{display:flex;justify-content:flex-end;gap:10px}.password-wrap{position:relative}.password-wrap .input{padding-right:52px}.password-toggle{position:absolute;top:4px;right:4px;width:44px;height:44px;border:0;border-radius:10px;background:transparent;color:var(--text-muted);display:flex;align-items:center;justify-content:center;cursor:pointer}.password-toggle:hover{color:var(--text)}.switch{position:relative;display:inline-flex;flex-shrink:0;width:48px;height:28px}.switch input{position:absolute;inset:0;z-index:1;width:100%;height:100%;margin:0;opacity:0;cursor:pointer}.switch span{position:relative;width:48px;height:28px;border-radius:999px;background:var(--border-strong);transition:background .2s}.switch span:after{content:"";position:absolute;top:3px;left:3px;width:22px;height:22px;border-radius:50%;background:#fff;transition:transform .2s}.switch input:checked+span{background:var(--accent)}.switch input:checked+span:after{transform:translate(20px)}.switch input:focus-visible+span{outline:2px solid var(--accent-hover);outline-offset:2px}.alert{display:flex;align-items:flex-start;gap:10px;padding:12px 14px;border:1px solid;border-radius:var(--radius-sm);font-size:14px;line-height:1.45}.alert>svg{flex-shrink:0;margin-top:1px}.alert-text{flex-grow:1}.alert-success{background:var(--accent-soft);border-color:var(--accent-border);color:var(--text)}.alert-success>svg{color:var(--accent-text)}.alert-error{background:var(--danger-soft);border-color:var(--danger-border);color:var(--text)}.alert-error>svg{color:var(--danger)}.alert-info{background:var(--surface-3);border-color:var(--border-strong);color:var(--text)}.alert-info>svg{color:var(--text-muted)}.alert-close{flex-shrink:0;width:28px;height:28px;margin:-4px -6px -4px 0;border:0;border-radius:8px;background:transparent;color:var(--text-muted);display:flex;align-items:center;justify-content:center;cursor:pointer}.alert-close:hover{color:var(--text)}.not-found{min-height:100vh;padding:24px;display:flex;flex-direction:column;align-items:center;justify-content:center;gap:14px;text-align:center}.not-found h1{margin-top:12px;font-size:28px}.not-found p{color:var(--text-muted)}.app-shell{min-height:100vh}.app-main{max-width:520px;margin:0 auto;padding:32px 20px calc(104px + env(safe-area-inset-bottom))}.nav{position:fixed;left:0;right:0;bottom:0;z-index:10;background:var(--surface-2);border-top:1px solid var(--border);padding:8px 12px calc(8px + env(safe-area-inset-bottom))}.nav-brand{display:none}.nav-links{list-style:none;margin:0 auto;padding:0;max-width:520px;display:flex;justify-content:space-around}.nav-link{min-width:64px;min-height:52px;display:flex;flex-direction:column;align-items:center;justify-content:center;gap:4px;border-radius:12px;text-decoration:none;color:var(--nav-idle);font-size:11px;font-weight:500}.nav-link:hover{color:var(--text)}.nav-link.active{color:var(--accent-text);font-weight:600}@media(min-width:768px){.app-main{max-width:760px;padding:48px 32px calc(120px + env(safe-area-inset-bottom))}}@media(min-width:1024px){.app-shell{display:grid;grid-template-columns:240px minmax(0,1fr)}.nav{position:sticky;top:0;height:100vh;border-top:0;border-right:1px solid var(--border);padding:32px 16px;display:flex;flex-direction:column;gap:36px}.nav-brand{display:inline-flex;padding:0 12px}.nav-links{flex-direction:column;justify-content:flex-start;gap:4px;max-width:none;margin:0}.nav-link{flex-direction:row;justify-content:flex-start;gap:12px;min-height:48px;padding:0 14px;font-size:15px}.nav-link.active{background:var(--accent-soft)}.app-main{width:100%;max-width:1080px;padding:48px 48px 64px}}.auth-page{min-height:100vh;display:flex}.auth-brand{display:none}.auth-main{flex:1;display:flex;justify-content:center;padding:56px 24px 40px}.auth-card{width:100%;max-width:400px;display:flex;flex-direction:column;gap:28px}.auth-header{display:flex;flex-direction:column;gap:20px}.auth-header h1{font-size:30px;font-weight:800;letter-spacing:-.03em}.auth-header p{margin-top:8px;font-size:15px;line-height:1.5;color:var(--text-muted)}.auth-form{display:flex;flex-direction:column;gap:18px}.checkbox-row{display:flex;align-items:center;gap:10px;min-height:44px;font-size:14px;color:var(--text-soft);cursor:pointer}.checkbox-row input{width:20px;height:20px;margin:0;accent-color:var(--accent)}.divider{display:flex;align-items:center;gap:12px;font-size:13px;color:var(--text-muted)}.divider:before,.divider:after{content:"";flex:1;height:1px;background:var(--border)}.social-buttons{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:12px}.social-buttons .btn{min-height:52px;border-radius:var(--radius-sm)}.auth-switch{text-align:center;font-size:14px;color:var(--text-muted)}.auth-switch a{font-weight:600;text-decoration:none}.auth-brand-body h2{font-size:40px;font-weight:800;line-height:1.1;letter-spacing:-.03em;max-width:12ch}.auth-brand-body p{margin-top:16px;font-size:16px;line-height:1.5;color:var(--text-muted);max-width:36ch}.auth-features{list-style:none;margin:28px 0 0;padding:0;display:flex;flex-direction:column;gap:12px}.auth-features li{display:flex;align-items:center;gap:10px;font-size:15px;color:var(--text-soft)}.auth-features svg{color:var(--accent-text);flex-shrink:0}.auth-preview .ring{width:180px}.auth-preview-value{font-size:32px;font-weight:800;letter-spacing:-.03em}.auth-preview-label{font-size:13px;color:var(--text-muted)}@media(min-width:1024px){.auth-brand{display:flex;flex-direction:column;justify-content:space-between;gap:40px;width:44%;max-width:560px;padding:48px;background:var(--surface-2);border-right:1px solid var(--border)}.auth-main{align-items:center;padding:48px}.auth-logo{display:none}}.home-header{display:flex;justify-content:space-between;align-items:center;gap:12px}.home-title{font-size:24px;font-weight:700;letter-spacing:-.02em}.avatar-link{flex-shrink:0;border-radius:999px;text-decoration:none}.home-grid{display:grid;gap:16px}.home-side{display:flex;flex-direction:column;gap:16px}.steps-card{border-radius:var(--radius-lg);padding:20px;display:flex;flex-direction:column;align-items:center;gap:12px}.steps-card .ring{width:200px}.ring-icon{color:var(--accent)}.ring-value{font-size:40px;font-weight:800;letter-spacing:-.03em;line-height:1.1}.ring-label{font-size:13px;color:var(--text-muted)}.steps-summary{font-size:13px;color:var(--text-muted);text-align:center}.steps-summary strong{color:var(--accent-text);font-weight:600}.stat-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:12px}.stat-card{display:flex;flex-direction:column;gap:10px}.stat-icon{width:36px;height:36px;border-radius:10px;background:var(--accent-soft);color:var(--accent);display:flex;align-items:center;justify-content:center}.stat-label{font-size:13px;font-weight:500;color:var(--text-muted)}.stat-value{display:flex;align-items:baseline;gap:4px}.stat-number{font-size:26px;font-weight:700;letter-spacing:-.02em}.stat-unit,.stat-goal{font-size:13px;color:var(--text-muted)}.stat-goal{font-size:12px}.stat-track{height:6px;border-radius:999px;background:var(--border);overflow:hidden}.stat-fill{height:100%;border-radius:999px;background:var(--accent);transition:width .4s ease}.activity-form{display:flex;flex-direction:column;gap:14px}.activity-form-fields{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:10px}.activity-form-fields .input{padding:0 12px}.up-next{display:flex;align-items:center;gap:12px}.up-next-info{flex-grow:1;display:flex;flex-direction:column;gap:4px;min-width:0}.up-next-title{font-size:17px;font-weight:600}.up-next-meta{font-size:13px;color:var(--text-muted)}@media(min-width:768px){.home-title{font-size:28px}.home-grid{grid-template-columns:repeat(2,minmax(0,1fr));align-items:start}.steps-card{padding:32px 20px}.steps-card .ring{width:240px}}@media(min-width:1024px){.home-grid{grid-template-columns:minmax(0,1.1fr) minmax(0,1fr)}.steps-card .ring{width:280px}.ring-value{font-size:48px}}.workouts-layout{display:grid;gap:16px;align-items:start}.workout-list-panel,.workout-detail{display:flex;flex-direction:column;gap:14px}.chips{display:flex;gap:8px;overflow-x:auto;scrollbar-width:none}.chip{min-height:36px;padding:0 16px;border-radius:999px;border:1px solid var(--border-strong);background:var(--surface);color:var(--text-soft);font-weight:500;font-size:13px;line-height:1;white-space:nowrap;cursor:pointer}.chip:hover{border-color:var(--accent)}.chip[aria-pressed=true]{background:var(--accent);border-color:var(--accent);color:var(--on-accent);font-weight:600}.workout-list{list-style:none;margin:0;padding:0;display:flex;flex-direction:column;gap:10px}.workout-card{display:flex;align-items:center;gap:12px;padding:14px 16px}.workout-card.is-selected{border-color:var(--accent)}.workout-card-info{flex-grow:1;min-width:0;display:flex;flex-direction:column;gap:4px}.workout-card-top{display:flex;align-items:center;gap:8px;flex-wrap:wrap}.workout-name{font-size:17px;font-weight:600}.tag{padding:3px 8px;border-radius:999px;background:var(--surface-3);color:var(--text-soft);font-size:11px;font-weight:600}.workout-meta{font-size:13px;color:var(--text-muted)}.workout-status{font-size:12px;color:var(--text-muted)}.workout-status.is-active{color:var(--accent-text);font-weight:600}.back-button{align-self:flex-start;display:inline-flex;align-items:center;gap:4px;min-height:44px;padding:0 8px 0 0;border:0;background:none;color:var(--text-soft);font-weight:600;font-size:14px;line-height:1;cursor:pointer}.active-workout{background:var(--accent-soft);border:1px solid var(--accent-border);border-radius:var(--radius-md);padding:14px 16px;display:flex;align-items:center;gap:12px;flex-wrap:wrap}.active-workout-info{flex:1 1 160px;display:flex;flex-direction:column;gap:4px}.active-workout-name{font-size:17px;font-weight:600}.active-workout-meta{font-size:13px;color:var(--accent-soft-text)}.exercise-list{list-style:none;margin:0;padding:0;display:flex;flex-direction:column;gap:6px}.exercise{width:100%;min-height:60px;padding:12px;border-radius:16px;border:1px solid var(--border);background:var(--surface);color:var(--text);font:inherit;text-align:left;display:flex;align-items:center;gap:12px;cursor:pointer}.exercise:hover:not(:disabled){border-color:var(--border-strong)}.exercise:disabled{cursor:default}.exercise.is-current{border:1.5px solid var(--accent)}.exercise-badge{width:36px;height:36px;flex-shrink:0;border-radius:12px;background:var(--surface-3);color:var(--text-soft);font-size:14px;font-weight:700;display:flex;align-items:center;justify-content:center}.is-current .exercise-badge{background:var(--accent-soft);color:var(--accent-text)}.is-done .exercise-badge{background:var(--accent);color:var(--on-accent)}.exercise-info{flex-grow:1;min-width:0;display:flex;flex-direction:column;gap:2px}.exercise-name{font-size:15px;font-weight:600}.is-done .exercise-name{color:var(--text-muted);text-decoration:line-through}.exercise-detail{font-size:13px;color:var(--text-muted)}.exercise-time{font-size:14px;font-weight:600;white-space:nowrap}.is-current .exercise-time{color:var(--accent-text)}.is-done .exercise-time{color:var(--text-muted)}@media(max-width:899px){.workouts-layout.has-selection .workout-list-panel{display:none}.workouts-layout:not(.has-selection) .workout-detail-panel{display:none}}@media(min-width:900px){.workouts-layout{grid-template-columns:minmax(0,360px) minmax(0,1fr);gap:24px}.back-button{display:none}.workout-detail-panel{position:sticky;top:24px}}.segmented{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:4px;padding:4px;border-radius:var(--radius-sm);background:var(--surface);border:1px solid var(--border)}.segmented button{min-height:36px;border:0;border-radius:10px;background:transparent;color:var(--text-muted);font-weight:500;font-size:13px;line-height:1;cursor:pointer}.segmented button:hover{color:var(--text)}.segmented button[aria-pressed=true]{background:var(--border);color:var(--text);font-weight:600}.progress-grid{display:flex;flex-direction:column;gap:16px}.chart-card{border-radius:var(--radius-lg);padding:20px;display:flex;flex-direction:column;gap:16px}.chart-head{display:flex;justify-content:space-between;align-items:flex-start;gap:12px}.chart-total-wrap{display:flex;flex-direction:column;gap:2px}.chart-total{font-size:32px;font-weight:800;letter-spacing:-.03em}.chart-caption{font-size:13px;color:var(--text-muted)}.change-badge{padding:6px 10px;border-radius:999px;background:var(--accent-soft);color:var(--accent-hover);font-size:12px;font-weight:600;white-space:nowrap}.change-badge.is-down{background:var(--danger-soft);color:var(--danger)}.chart{position:relative;height:180px;display:flex;align-items:flex-end;gap:12px;border-bottom:1px solid var(--border-strong)}.chart-column{position:relative;flex:1;height:100%;display:flex;align-items:flex-end}.chart-bar{width:100%;min-height:3px;border-radius:8px 8px 3px 3px;background:var(--bar);transition:height .3s ease}.is-today .chart-bar{background:var(--accent)}.chart-bubble{position:absolute;left:50%;transform:translate(-50%);z-index:2;padding:3px 6px;border-radius:6px;background:var(--text);color:var(--bg);font-size:11px;font-weight:700;white-space:nowrap}.chart-goal{position:absolute;left:0;right:0;z-index:1;border-top:1.5px dashed var(--goal-line);pointer-events:none}.chart-goal span{position:absolute;right:0;bottom:4px;font-size:11px;font-weight:500;color:var(--text-muted)}.chart-labels{display:flex;gap:12px;margin-top:-8px}.chart-labels span{flex:1 1 0;text-align:center;font-size:12px;color:var(--text-muted)}.chart-labels .is-today{color:var(--accent-text);font-weight:700}.chart-empty{min-height:180px;justify-content:center}.summary-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:12px}.summary-card{padding:14px 16px;border-radius:18px;display:flex;flex-direction:column;gap:6px}.summary-label{font-size:13px;color:var(--text-muted)}.summary-value{font-size:22px;font-weight:700}.summary-value small{font-size:13px;font-weight:500;color:var(--text-muted)}@media(min-width:768px){.chart{height:240px}.segmented{max-width:420px}}@media(min-width:1024px){.progress-grid{display:grid;grid-template-columns:minmax(0,2fr) minmax(0,1fr);align-items:start}.summary-grid{grid-template-columns:minmax(0,1fr)}.chart{height:280px}}.profile-grid,.profile-side,.profile-main{display:flex;flex-direction:column;gap:16px}.profile-header{display:flex;flex-direction:column;align-items:center;gap:10px;text-align:center}.profile-name{font-size:22px;font-weight:700;letter-spacing:-.02em}.profile-email{margin-top:2px;font-size:13px;color:var(--text-muted);overflow-wrap:anywhere}.body-stats{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));padding:14px 0;border-radius:18px}.body-stats>div{display:flex;flex-direction:column;align-items:center;gap:4px}.body-stats>div+div{border-left:1px solid var(--border)}.body-stat-value{font-size:18px;font-weight:700}.body-stat-value small{font-size:12px;font-weight:500;color:var(--text-muted)}.body-stat-label{font-size:12px;color:var(--text-muted)}.profile-form{display:flex;flex-direction:column;gap:14px}.profile-form-numbers{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:10px}.profile-form-numbers .input{padding:0 12px}.settings{display:flex;flex-direction:column;gap:8px}.settings .section-label{margin:0 4px}.settings-list{padding:0;border-radius:18px;overflow:hidden;display:flex;flex-direction:column}.setting-row{width:100%;min-height:52px;padding:0 16px;border:0;border-bottom:1px solid var(--border);background:transparent;color:var(--text);font-weight:500;font-size:15px;line-height:1.2;text-align:left;display:flex;align-items:center;gap:12px;cursor:pointer}.setting-row:last-child{border-bottom:0}.setting-row:hover{background:var(--surface-3)}.setting-row-label{flex-grow:1}.setting-row-value{font-size:14px;color:var(--text-muted)}.setting-row-chevron{color:var(--text-muted);flex-shrink:0}.setting-edit{padding:14px 16px;border-bottom:1px solid var(--border);display:flex;flex-direction:column;gap:8px}.setting-edit label{font-size:13px;font-weight:600;color:var(--text-soft)}.setting-edit-row{display:flex;gap:8px}.setting-edit-row .input{flex:1;min-width:0;height:44px}.setting-edit-row .btn{padding:0 14px}@media(min-width:1024px){.profile-grid{display:grid;grid-template-columns:minmax(0,360px) minmax(0,1fr);align-items:start;gap:24px}.profile-side{background:var(--surface);border:1px solid var(--border);border-radius:var(--radius-lg);padding:28px 20px 20px}.profile-side .body-stats{background:var(--bg)}.profile-main .btn-danger{align-self:flex-start;width:auto;padding:0 28px}}
