.target-toolbar{display:flex;align-items:center;justify-content:space-between;gap:12px;margin:0 0 14px}.target-toolbar span{font-size:12px;max-width:60%}.target-comparisons:empty{display:none}.target-comparisons{margin:12px auto 0;max-width:340px;display:grid;gap:8px;text-align:left}.target-compare{display:grid;grid-template-columns:45px 1fr;align-items:baseline;column-gap:8px;border-top:1px solid var(--line,#536173);padding-top:8px;font-size:13px;line-height:1.3}.target-compare strong{font-size:clamp(17px,3.5vw,23px);font-variant-numeric:tabular-nums}.target-delta{grid-column:2;font-size:12px;color:var(--muted,#aab5c7)}html[data-design=refresh][data-race-mode=on] .target-compare strong{font-size:26px}#targetsDialog{width:min(900px,100vw);max-width:100vw;max-height:100dvh;padding:24px;box-sizing:border-box;border-radius:18px;background:var(--surface,#142035);color:var(--text,#eef3ff)}#targetsDialog::backdrop{background:#101722b8}#targetsDialog h2{margin-top:0}.targets-heading{display:flex;justify-content:space-between;align-items:start;gap:12px}.targets-grid{display:grid;grid-template-columns:1fr 1fr;gap:12px}.target-block{padding:16px;background:var(--well,#0e1728);border:1px solid var(--line,#536173);border-radius:12px;margin:16px 0}.target-block h3{margin:0 0 12px;font-size:16px}.target-row{display:grid;grid-template-columns:1fr 120px 120px;gap:12px;align-items:center;padding:14px 0;border-top:1px solid var(--line,#536173)}.target-row label{font-size:12px}.target-row input{width:100%;box-sizing:border-box;font-variant-numeric:tabular-nums}.target-row strong{font-size:14px}.targets-total{display:flex;justify-content:space-between;gap:12px;padding:16px 0;font-weight:800}.targets-actions{position:sticky;bottom:-24px;background:var(--surface,#142035);padding:12px 0 calc(12px + env(safe-area-inset-bottom));display:flex;justify-content:flex-end;gap:12px}#targetsError{min-height:1.5em;color:var(--accent,#ffb183)}#targetsDialog button{min-height:48px}#targetsDialog label{display:block}#targetsDialog select,#targetsDialog input{width:100%;box-sizing:border-box;font-size:16px}@media(max-width:600px){#targetsDialog{height:100dvh;width:100vw;margin:0;padding:18px;border-radius:0;border:0}.targets-grid{grid-template-columns:1fr}.target-row{grid-template-columns:1fr 1fr;gap:8px}.target-row>strong{grid-column:1/-1}.targets-actions{bottom:-18px}.target-toolbar{align-items:start}.target-compare{grid-template-columns:34px 1fr;font-size:12px}.target-comparisons{margin-top:8px}.target-block{padding:12px}}@media(prefers-reduced-motion:reduce){#targetsDialog{scroll-behavior:auto}}
html[data-design=refresh]{--target-below:#176B40;--target-over:#B42318}html[data-design=refresh][data-theme=dark]{--target-below:#63E6A4;--target-over:#FF8C82}@media(prefers-color-scheme:dark){html[data-design=refresh][data-theme=auto]{--target-below:#63E6A4;--target-over:#FF8C82}}.target-compare[data-state=below] strong{color:var(--target-below)}.target-compare[data-state=over] strong{color:var(--target-over)}
.race-setup-toggle{display:none;margin-left:auto}html[data-race-mode=on] .race-setup-toggle{display:inline-flex;align-items:center;justify-content:center;font-size:13px;padding:8px 14px;min-height:44px}
#setupPanel #setupBody{display:grid;grid-template-columns:minmax(0,1fr) auto;gap:12px;align-items:end}#setupPanel .setup-title{grid-column:1/-1;margin:0;font-size:14px;text-transform:uppercase;letter-spacing:.08em;color:var(--muted)}#setupPanel .setup{grid-column:1}#setupPanel .buttons{grid-column:1;margin:0;flex-wrap:wrap}#setupPanel #raceControls{grid-column:2;grid-row:2/4;align-self:center;flex-direction:column;align-items:stretch;margin:0}#setupPanel .target-toolbar span{max-width:100%;font-size:11px}#setupPanel #editor{grid-column:1/-1}#setupPanel .timer-view-actions{flex-wrap:nowrap}#setupPanel #raceMode{background:var(--orange);color:#101722}#setupPanel .buttons button{font-size:12px;padding:8px 10px}html[data-design=refresh][data-race-mode=on] #setupPanel{display:none}
@media(max-width:600px){#setupPanel #setupBody{grid-template-columns:1fr}#setupPanel .setup{grid-template-columns:1fr 1fr;gap:8px}#setupPanel #raceControls{grid-column:1;grid-row:auto}#setupPanel .timer-view-actions>button{flex:1}#setupPanel .target-toolbar{gap:8px}html[data-race-mode=on] .brandbar .brand-icon{display:block;width:32px;height:32px}html[data-race-mode=on] .brandbar .brand-lockup>div{display:none}html[data-race-mode=on] .brandbar .race-setup-toggle{font-size:12px;width:auto;min-width:44px;min-height:44px;padding:8px 10px}html[data-race-mode=on] .brandbar .race-setup-toggle::after{content:none}}
/* Align desktop setup controls with the fields, and secondary content below. */
@media(min-width:601px){#setupPanel #setupBody{column-gap:16px;row-gap:12px}#setupPanel .setup{grid-row:2;min-width:0;align-items:start}#setupPanel .setup label{font-size:13px;line-height:18px;margin-bottom:6px}#setupPanel .setup :is(input,select){height:48px;min-width:0}#setupPanel .buttons{grid-row:3;align-self:start}#setupPanel #raceControls{display:contents}#setupPanel .timer-view-actions{grid-column:2;grid-row:2;align-self:start;margin-top:24px;gap:8px}#setupPanel #targetsSummary{grid-column:2;grid-row:3;align-self:center;font-size:12px;line-height:1.4}#setupPanel .buttons button{font-size:14px}#setupPanel .setup-title{font-size:15px}}
/* Approved named icon header, consistent controls at every size. */
html[data-design=refresh] .brandbar{gap:8px;min-height:44px;flex-wrap:nowrap}html[data-design=refresh] .brandbar .brand-lockup{gap:7px}html[data-design=refresh] .brandbar .brand-icon{display:block;width:32px;height:32px}html[data-design=refresh] .brandbar .brand-lockup>div{display:block}html[data-design=refresh] .brandbar .brand-lockup .muted{display:none}html[data-design=refresh] .brandbar .brand{font-size:23px;white-space:nowrap}html[data-design=refresh] .brandbar .header-status{gap:4px}html[data-design=refresh] .brandbar #status{display:flex;align-items:center;gap:6px;padding:0 6px;border:0;background:transparent;font-size:11px;min-height:44px}html[data-design=refresh] .brandbar #status::before{content:'';width:6px;height:6px;border-radius:50%;background:var(--muted)}html[data-design=refresh] .brandbar #status[data-phase=live]::before{background:var(--orange)}html[data-design=refresh] .brandbar #status[data-phase=finished]::before{background:var(--target-below)}html[data-design=refresh] .brandbar .account-menu summary,html[data-design=refresh] .brandbar .race-setup-toggle,html[data-design=refresh] .brandbar .theme-menu-toggle{position:relative;display:flex;justify-content:center;align-items:center;min-height:44px;height:44px;min-width:44px;width:44px;padding:10px;border:0;border-radius:10px;background:transparent;color:var(--text);box-sizing:border-box}html[data-design=refresh] .brandbar .race-setup-toggle{display:none}html[data-design=refresh][data-race-mode=on] .brandbar .race-setup-toggle{display:flex}html[data-design=refresh] .brandbar .race-setup-toggle::after{content:none}html[data-design=refresh] .brandbar .account-menu summary::before{position:absolute;right:7px;bottom:8px;width:7px;height:7px;border:2px solid var(--bg);box-sizing:content-box}html[data-design=refresh] .brandbar :is(.account-menu summary,.race-setup-toggle,.theme-menu-toggle) svg{width:22px;height:22px;fill:none;stroke:currentColor;stroke-width:1.8;stroke-linecap:round;stroke-linejoin:round;flex:none}html[data-design=refresh] .brandbar :is(.account-menu summary,.race-setup-toggle,.theme-menu-toggle):hover{background:var(--well)}html[data-design=refresh] .brandbar .theme-switch{display:none;position:absolute;right:0;top:calc(100% + 8px);width:168px;z-index:21;box-shadow:0 8px 24px #0003}html[data-design=refresh] .brandbar .theme-control.is-open .theme-switch{display:grid}.theme-menu-toggle .theme-glyph{display:none}.theme-menu-toggle[data-selected=light] .theme-light,.theme-menu-toggle[data-selected=dark] .theme-dark,.theme-menu-toggle[data-selected=auto] .theme-auto{display:block}html[data-design=refresh] .brandbar .account-menu-panel{left:auto;right:-48px}html[data-design=refresh] .top{margin-bottom:0}
@media(max-width:600px){html[data-design=refresh] main{padding-top:8px}html[data-design=refresh] .brandbar{gap:2px}html[data-design=refresh] .brandbar .brand{font-size:14px}html[data-design=refresh] .brandbar .brand-icon{width:24px;height:24px}html[data-design=refresh] .brandbar .brand-lockup{gap:4px}html[data-design=refresh] .brandbar #status{font-size:9px;padding:0 3px;gap:4px}html[data-design=refresh] .brandbar .header-status{gap:0}html[data-design=refresh] .brandbar .theme-control{margin:0}}
@media(max-width:360px){html[data-design=refresh] .brandbar .brand{font-size:12px}html[data-design=refresh] .brandbar .brand-icon{width:20px;height:20px}html[data-design=refresh] .brandbar #status{font-size:8px;padding:0 2px;gap:3px}}

/* Profile management stays off the timing page. */
html[data-design=refresh] dialog.profile-dialog{width:min(480px,calc(100vw - 24px));max-height:calc(100dvh - 32px);padding:20px;overflow:auto;background:var(--surface);color:var(--text);border:1px solid var(--line);border-radius:20px}
.profile-heading{display:flex;justify-content:space-between;align-items:center;gap:12px}.profile-heading h2{margin:0}.profile-heading button{min-height:44px;min-width:44px;padding:8px;background:transparent;color:var(--text)}
.profile-section{padding:16px 0;border-bottom:1px solid var(--line)}.profile-section h3{font-size:15px;margin:0 0 8px}.profile-section p{margin:8px 0}.profile-section summary{cursor:pointer;font-weight:700;min-height:44px;display:flex;align-items:center}
.profile-sync-status{font-size:13px;color:var(--muted);margin:8px 0 0}.profile-dialog #cloudEmail{overflow-wrap:anywhere;font-size:14px}.profile-dialog button{min-height:44px;font-size:14px}.athlete-row{display:flex;align-items:center;justify-content:space-between;gap:12px;padding:4px 0}.athlete-row span{overflow-wrap:anywhere;min-width:0}.athlete-row button{width:44px;flex:none;padding:8px;font-size:22px}.profile-dialog #showAddProfile{margin-top:8px}.profile-dialog #profileEditor{margin-top:12px;padding:12px;border-radius:12px;background:var(--well)}.profile-footer{padding-top:20px}.profile-footer button{background:transparent;color:var(--muted);border:1px solid var(--line)}.profile-dialog .toggle input{width:auto}.profile-dialog .buttons{margin-top:8px}.profile-dialog .hint{font-size:13px;line-height:1.5}html[data-design=refresh] .account-menu[data-sync=pending] summary::before{background:var(--orange)}html[data-design=refresh] .account-menu[data-sync=offline] summary::before{background:var(--muted)}

#undoBtn{display:inline-flex;align-items:center;justify-content:center;gap:8px}#undoBtn svg{width:20px;height:20px;flex:none;fill:none;stroke:currentColor;stroke-width:2;stroke-linecap:round;stroke-linejoin:round}

html[data-input-mode=pointer] #accountSummary:focus-visible{outline:none}html[data-input-mode=keyboard] #accountSummary:focus-visible{outline:3px solid var(--accent);outline-offset:3px}

.time-entry{display:grid;grid-template-columns:minmax(0,1fr) 44px;align-items:stretch;gap:4px}.time-entry input{min-width:0;height:100%;font-variant-numeric:tabular-nums}.time-stepper{display:grid;grid-template-rows:1fr 1fr;gap:2px}#targetsDialog .time-stepper button{display:flex;align-items:center;justify-content:center;min-width:44px;min-height:44px;padding:4px;border-radius:8px}.time-stepper svg{flex:none}.target-row{grid-template-columns:minmax(0,1fr) 160px 160px}@media(max-width:600px){.target-row{grid-template-columns:minmax(0,1fr) minmax(0,1fr)}.time-entry{gap:3px}.target-row .time-entry input{padding:8px 6px;font-size:16px}}

/* Keep split and cumulative times on one baseline with shared column headings. */
.split-columns,html[data-design=refresh] #splits .split{grid-template-columns:minmax(0,1fr) 5.5rem 5.5rem 44px;gap:8px;font-variant-numeric:tabular-nums}.split-columns{display:grid;align-items:center;padding:8px 0 4px;color:var(--muted);font-size:14px}.split-columns span:nth-child(2),.split-columns span:nth-child(3){text-align:right}#splits .time{white-space:nowrap;line-height:1.3}#splits .split>div:first-child{min-width:0;overflow-wrap:anywhere}#splits .split small{margin-top:3px}@media(max-width:500px){.split-columns,html[data-design=refresh] #splits .split{grid-template-columns:minmax(0,1fr) 4.7rem 4.7rem 44px;font-size:13px;gap:6px}}


/* Saved athletes need only one control; explicit Add prevents accidental profiles. */
.selected-athlete{display:flex;align-items:center;justify-content:space-between;gap:8px;min-height:48px;padding:4px 6px 4px 12px;border:1px solid var(--line);border-radius:10px;background:var(--well)}.selected-athlete strong{min-width:0;overflow-wrap:anywhere;font-size:16px}.selected-athlete button{flex:none;min-height:44px;padding:8px 10px;font-size:13px}.setup-athlete-editor input{width:100%;min-width:0}.setup-athlete-actions{display:flex;gap:8px;margin-top:8px}.setup-athlete-actions button{flex:1;min-height:44px;padding:8px 10px;font-size:13px}.setup-athlete-editor+p{margin:8px 0 0;line-height:1.4}#setupPanel .setup>div{min-width:0}
.duplicate-athlete-choice{margin-top:12px;padding:12px;border:1px solid var(--line);border-radius:12px;background:var(--well)}.duplicate-athlete-choice p{margin:0 0 10px;line-height:1.4;font-size:14px}.duplicate-athlete-choice .setup-athlete-actions{flex-wrap:wrap}.duplicate-athlete-choice button{white-space:normal;overflow-wrap:anywhere;min-width:100px}.duplicate-athlete-choice select{margin-bottom:8px}
/* Custom names remain separate from the signed-in athlete selector. */
#profileSelect:not([hidden]) + #athlete:not([hidden]){margin-top:8px}
