:root{--page:#18191c;--surface:#23252a;--sidebar:#1d1f23;--field:#1b1d21;--soft:#2c2f35;--line:#454952;--text:#e5e7eb;--muted:#b0b5bf;--accent:#a8c78e;--on-accent:#172211;--note:#2c2f35;--note-alt:#292c32;--danger:#ffad99;--base:15px;color-scheme:dark}
:root[data-theme=light]{--page:#f7f8f3;--surface:#fff;--sidebar:#eff1e9;--field:#fafbf7;--soft:#e9efdf;--line:#cdd6c5;--text:#29372e;--muted:#58664f;--accent:#486747;--on-accent:#fff;--note:#f5f1df;--note-alt:#eaf0e3;--danger:#a43d29;color-scheme:light}
:root[data-accent=blue]{--accent:#9bbff5;--on-accent:#102440}:root[data-accent=purple]{--accent:#c6a5ed;--on-accent:#2c173f}:root[data-accent=orange]{--accent:#eac18f;--on-accent:#35220e}
:root[data-theme=light][data-accent=blue]{--accent:#285da5;--on-accent:#fff}:root[data-theme=light][data-accent=purple]{--accent:#7842a5;--on-accent:#fff}:root[data-theme=light][data-accent=orange]{--accent:#875019;--on-accent:#fff}
:root[data-text=large]{--base:17px}:root[data-text=larger]{--base:19px}
body{background:var(--page);color:var(--text);font-size:var(--base)}aside{background:var(--sidebar);border-color:var(--line)}nav button{color:var(--muted)}nav button.active,.status,.btn.secondary{background:var(--soft);color:var(--text)}.brand span,.icon{color:var(--accent)}.top,.empty,.weekday,label,.bottom,.note small{color:var(--muted)}.panel,dialog{background:var(--surface);border-color:var(--line);color:var(--text)}.panel[style]{background:var(--soft)!important}.panel p,dialog p{color:var(--muted)!important}input,textarea,select{background:var(--field);border-color:var(--line);color:var(--text)}input::placeholder,textarea::placeholder{color:var(--muted)}.btn{background:var(--accent);color:var(--on-accent)}.task,.event,fieldset{border-color:var(--line)!important}.task input{accent-color:var(--accent)}.task.done span{color:var(--muted)}.note{background:var(--note)}.note:nth-child(even){background:var(--note-alt)}.note p{color:var(--muted)}.day{color:var(--text)}.day:hover{background:var(--soft)}.day.today{box-shadow:inset 0 0 0 1px var(--accent)}.day.selected{background:var(--accent);color:var(--on-accent)}.day.has:after,.progress div{background:var(--accent)}.progress,.event{background:var(--soft)}.event small{color:var(--muted)}#calendar+div{border-color:var(--line)!important}#notice,#eventerror{color:var(--danger)!important}#schoolinfo a{color:var(--accent)!important}:focus-visible{outline-color:var(--accent)!important}
#appearance-button{margin-top:25px;width:100%}#appearance-dialog select{width:100%}#appearance-dialog label{margin-top:18px}.settings-preview{padding:18px;background:var(--soft);border:1px solid var(--line);border-radius:9px;margin-top:20px;color:var(--text)}:root[data-density=compact] .panel{padding:17px;margin-bottom:16px}:root[data-density=compact] .task{padding:9px 0}:root[data-density=compact] .grid{gap:16px}
@media(max-width:600px){#appearance-button{width:auto;margin-top:12px}nav{flex-wrap:wrap}}

label,.empty,.note p,.event,.panel p{font-size:.9em}.note h3{font-size:1em}.note small,.event small{font-size:.8em}.weekday{font-size:.72em}.day{font-size:1em}

:root[data-theme=dark] .panel p,:root[data-theme=dark] dialog p{color:var(--muted)!important}

#export{display:block;width:100%;margin-top:10px;font-size:.85em}@media(max-width:600px){#export{width:auto}}

.grid[data-view="calendar"]>section:first-child{display:none}.grid[data-view="calendar"]>section:last-child{grid-column:1 / -1;width:100%;max-width:760px}.grid[data-view="notes"]>section:last-child,.grid[data-view="tasks"]>section:last-child{display:none}.grid[data-view="notes"]>section:first-child,.grid[data-view="tasks"]>section:first-child{grid-column:1 / -1;width:100%;max-width:760px}

.grid[data-view="workouts"] [data-section="workouts"]>.heading>h2,.grid[data-view="apps"] [data-section="apps"]>.heading>h2,.grid[data-view="notes"] [data-section="notes"]>.heading>h2,.grid[data-view="calendar"] [data-section="calendar"]>.heading h2,.grid[data-view="tasks"] [data-section="tasks"]>.heading h2{display:none}
.grid[data-view="workouts"] [data-section="workouts"]>.heading,.grid[data-view="apps"] [data-section="apps"]>.heading,.grid[data-view="notes"] [data-section="notes"]>.heading{justify-content:flex-end}
#workout-complete-all{margin-bottom:16px}
/* Dedicated tabs use compact toolbars instead of empty section headings. */
.grid[data-view="tasks"] [data-section="tasks"]>.heading{justify-content:flex-end;margin:0 0 12px;min-height:0}
.grid[data-view="tasks"] [data-section="tasks"]>.heading>div:has(h2){display:none}
.grid[data-view="calendar"] [data-section="calendar"]>.heading:first-child>div:has(h2){display:none}
.grid[data-view="calendar"] [data-section="calendar"]{display:grid;grid-template-columns:minmax(0,1fr) auto;column-gap:12px}
.grid[data-view="calendar"] [data-section="calendar"]>.heading:first-child{grid-column:2;grid-row:1;margin:0 0 14px;align-self:start}
.grid[data-view="calendar"] [data-section="calendar"]>.calendar-switch{grid-column:1;grid-row:1;margin:0 0 14px;align-self:start;max-width:480px}
.grid[data-view="calendar"] [data-section="calendar"]>.holidays-toggle,.grid[data-view="calendar"] [data-section="calendar"]>.heading:not(:first-child),.grid[data-view="calendar"] [data-section="calendar"]>#calendar,.grid[data-view="calendar"] [data-section="calendar"]>#calendar+div{grid-column:1 / -1}
.grid[data-view="notes"] [data-section="notes"]>.heading,.grid[data-view="apps"] [data-section="apps"]>.heading,.grid[data-view="workouts"] [data-section="workouts"]>.heading{margin:0 0 16px;min-height:0;justify-content:flex-start}
.grid[data-view="notes"] [data-section="notes"]>.heading>.row{flex-wrap:wrap}
.grid[data-view="workouts"] [data-section="workouts"]{display:grid;grid-template-columns:minmax(0,1fr) auto;column-gap:12px}
.grid[data-view="workouts"] [data-section="workouts"]>.heading{grid-column:2;grid-row:1;justify-content:flex-end;align-self:start;margin-bottom:18px}
.grid[data-view="workouts"] [data-section="workouts"]>#workout-complete-all{grid-column:1;grid-row:1;justify-self:start;align-self:start;margin:0 0 18px}
.grid[data-view="workouts"] [data-section="workouts"]>.workout-days,.grid[data-view="workouts"] [data-section="workouts"]>.workout-summary,.grid[data-view="workouts"] [data-section="workouts"]>#workout-list{grid-column:1 / -1}
@media(max-width:480px){.grid[data-view="workouts"] [data-section="workouts"]{grid-template-columns:1fr}.grid[data-view="workouts"] [data-section="workouts"]>.heading{grid-column:1;grid-row:1;justify-content:flex-start;margin-bottom:10px}.grid[data-view="workouts"] [data-section="workouts"]>#workout-complete-all{grid-column:1;grid-row:2}.grid[data-view="calendar"] [data-section="calendar"]>.calendar-switch{gap:4px}.grid[data-view="calendar"] [data-section="calendar"]>.calendar-switch .btn{padding:9px 6px;font-size:.8em}}

.task-priority{font-size:.8em;padding:6px;width:105px;flex-shrink:0}.task-priority[data-level=high]{border-color:#c47c7c}.task-priority[data-level=low]{border-color:#7c94be}#taskpriority{flex:0 1 120px}@media(max-width:480px){.task{flex-wrap:wrap}.task span{min-width:130px}.task-priority{margin-left:30px}.task .icon{margin-left:auto}}
