/* Planning controls and a compact phone layout. */
.focus-icon{display:block;width:22px;height:22px;flex:none}
#nav .nav-icon{display:grid;place-items:center;width:24px;height:24px;flex:none}
.tools-navigation a{display:inline-flex;align-items:center;justify-content:center;gap:8px;min-height:44px}
.tools-navigation .focus-icon{width:19px;height:19px}
.workouts-view .search-box{display:none}
#note-view{max-width:720px}
#note-view .dialog-top>div{min-width:0}
#note-view h2{overflow-wrap:anywhere;line-height:1.3;margin:8px 0 0}
.note-view-kind{color:var(--muted);font-size:13px}
.note-reading{padding:6px 0 14px;overflow-wrap:anywhere}
.note-reading-text{white-space:pre-wrap;line-height:1.7;font-size:17px;color:var(--ink)}
.note-reading-source{white-space:pre-wrap;margin:24px 0 0;border-left:3px solid #d7cbea;padding:5px 14px;font-size:14px;line-height:1.6;color:var(--muted)}
.note-reading-source>span{display:block;font-size:12px;margin-bottom:5px}
.note-reading-media{display:grid;gap:22px;margin-top:24px}
.note-reading-file{margin:0;min-width:0}
.note-reading-file img{display:block;width:100%;max-height:65vh;object-fit:contain;background:#f7f5fc;border-radius:12px}
.note-reading-file audio{display:block;width:100%;max-width:100%}
.note-reading-file figcaption{display:flex;justify-content:space-between;align-items:baseline;gap:14px;margin-top:9px;font-size:12px;line-height:1.5;color:var(--muted)}
.note-reading-file figcaption span{min-width:0}
.note-reading-file figcaption a{flex-shrink:0;color:#7257ad}
#note-view .dialog-actions{justify-content:flex-start}
#new-task{max-width:660px}
.composer-subtitle{font-size:14px;color:var(--muted);margin:0 0 10px}
#task-composer-form .field textarea{min-height:78px}
#task-composer-form .field{margin:14px 0}
.task-planning{background:#f7f5fc;border:1px solid #e8e0f4;border-radius:14px;padding:16px;margin:20px 0}
.task-planning h3{font-size:15px;margin:0 0 12px}
.plan-shortcuts{display:flex;flex-wrap:wrap;gap:8px}
.plan-shortcuts button{min-height:40px;padding:8px 12px;border:1px solid #ddd5ea;border-radius:9px;background:#fff;color:#65527d;font-size:14px}
.plan-shortcuts button[aria-pressed=true]{background:#eae3ff;border-color:#b8a5e9;color:#5840a4}
.planning-dates{display:grid;grid-template-columns:minmax(0,1fr) minmax(0,1fr);gap:12px}
.planning-dates .field{min-width:0}
.planning-dates input{min-width:0;max-width:100%;display:block;min-height:44px}
.focus-choice{display:flex;align-items:center;gap:10px;font-size:15px;color:#403251;cursor:pointer}
.focus-choice input{width:22px;height:22px;accent-color:#7257d2;flex-shrink:0}
.focus-choice small{display:block;font-size:12px;color:#82728f;line-height:1.5;margin-top:2px}
#task-plan-hint{margin:10px 0 0}
.date-warning{font-size:13px;color:#996128;margin:10px 0 0;line-height:1.5}
.date-warning:empty,#task-save-error:empty,#task-draft-state:empty{display:none}
.task-options{border-top:1px solid var(--line);margin-top:18px;padding-top:8px}
.task-options>summary{cursor:pointer;font-size:15px;padding:10px 0;color:#4c3f5c;font-weight:600}
.task-options>summary span{font-size:12px;color:#877995;font-weight:400;margin-left:7px}
.draft-switch{display:flex;align-items:center;gap:12px;margin:6px 0 15px}
.draft-switch select{min-width:0;flex:1;font-size:14px;border:1px solid var(--line);border-radius:8px;padding:9px;color:#695779;background:#faf9fc}
.draft-switch button{white-space:nowrap}
.tool-options{display:grid;gap:10px;margin-top:18px}
.tool-option{text-align:left;width:100%;border:1px solid var(--line);border-radius:12px;background:#faf9fc;padding:16px;color:var(--ink)}
.tool-option strong{display:block;font-size:16px;margin-bottom:6px}
.tool-option span{display:block;font-size:13px;line-height:1.55;color:#81748c}
.row-title{min-width:0}
.done .row-title{text-decoration:none;color:#6f687a}
.done .row-title small{color:#8a8394}
.attention-clear{font-size:14px;color:#758677;margin:2px 0;line-height:1.6}
.attention-panel.is-empty .section-head{margin-bottom:10px}
.week-picker{display:none}
.day-header{display:flex;align-items:center;justify-content:space-between;gap:8px;margin-bottom:8px}
.day-header .day-label{margin:0;font-size:13px}
.day-add{border:1px solid var(--line);border-radius:9px;background:white;color:#71569e;min-width:40px;min-height:40px;font-size:20px}
.week-empty{color:#8b8296;font-size:14px;padding:18px 0 6px}
.week-empty .text-button{display:block;font-size:13px;margin-top:8px}
.day-task .check{flex-shrink:0}
.day-task button:last-child{min-width:0}
.daily-main .panel-overline{margin:0}
.daily-outcome{margin-bottom:14px}
.daily-intro{margin:0 0 18px}
.project-card{padding:21px}
.project-card h3{margin:8px 0;font-size:19px}
.project-card p{margin:5px 0;font-size:14px}
.project-card .progress-track{margin-top:16px}
dialog{overscroll-behavior:contain}
@media(max-width:700px){
 body{overflow-wrap:break-word}
 /* Keep scrolled content out of the transparent iPhone status area. */
 body::before{content:"";position:fixed;inset:0 0 auto;height:env(safe-area-inset-top,0px);background:#f5f5f9;z-index:50;pointer-events:none}
 .workouts-view .topbar{padding-bottom:0}
 .tools-navigation{flex-wrap:wrap}
 .tools-navigation a{flex:1;padding:10px 8px;font-size:14px}
 .sidebar{padding:calc(13px + env(safe-area-inset-top)) 16px 13px}
 .brand{padding:0;font-size:23px;gap:7px;min-height:40px}
 .brand-mark{width:29px;height:29px}
 .top-actions{top:calc(12px + env(safe-area-inset-top));right:16px;gap:8px}
 .top-actions .button{padding:10px 13px;min-height:40px;font-size:14px}
 .top-actions .icon-button{width:38px;min-height:40px;font-size:25px}
 .topbar{padding:0 16px 8px}
 .search-box{border-radius:11px}
 .search-box input{padding:10px 0}
 .content{padding:18px 16px}
 main{padding-bottom:calc(92px + env(safe-area-inset-bottom))}
 .page-title{font-size:27px;margin-bottom:12px}
 .eyebrow{font-size:12px;margin-bottom:7px}
 .subtitle{font-size:14px;line-height:1.5;margin-bottom:18px}
 .toolbar{margin:15px 0;gap:8px}
 .panel{padding:17px;border-radius:15px}
 .daily-goal{padding:11px 13px;margin-bottom:15px;gap:6px}
 .daily-goal strong{font-size:13px}
 .daily-goal small{font-size:11px}
 .daily-main{padding:17px}
 .daily-main .section-head{margin-bottom:12px}
 .daily-outcome{font-size:21px;line-height:1.3;margin:0 0 12px}
 .daily-intro{font-size:14px;margin-bottom:15px;line-height:1.5}
 .daily-suggestions{margin-top:16px;padding-top:13px}
 .daily-suggestions summary{font-size:13px}
 .attention-panel.is-empty{padding:13px 16px;background:#f3f6f3}
 .attention-panel.is-empty .section-head{display:none}
 .attention-clear{font-size:13px}
 .task-row{padding:14px;align-items:flex-start;gap:11px}
 .task-row .check{width:32px;height:32px;margin-top:2px}
 .row-title{font-size:15px;line-height:1.45}
 .row-title small{font-size:12px;line-height:1.55;margin-top:5px}
 .project-grid{gap:10px}
 .project-card{padding:15px 16px;display:grid;grid-template-columns:12px minmax(0,1fr);column-gap:10px;align-items:center;border-radius:14px}
 .project-card>.project-dot{grid-row:1;margin:0}
 .project-card h3{grid-column:2;margin:0;font-size:17px}
 .project-card p{grid-column:2;margin:5px 0 0;font-size:13px}
 .project-card .progress-track{grid-column:2;margin-top:10px;height:3px}
 .week-toolbar{justify-content:space-between}
 .week-toolbar .filter{min-width:44px}
 .week-picker{display:grid;grid-template-columns:repeat(7,minmax(0,1fr));gap:4px;margin:17px 0}
 .week-picker button{border:1px solid transparent;border-radius:12px;background:transparent;padding:7px 1px;color:#796e87;min-width:0}
 .week-picker span,.week-picker strong,.week-picker small{display:block}
 .week-picker span{font-size:11px;margin-bottom:7px}
 .week-picker strong{font-size:18px;font-weight:600;color:#3c3050}
 .week-picker small{font-size:10px;height:13px;margin-top:5px}
 .week-picker [aria-pressed=true]{background:#ece5ff;border-color:#d9c9fa;color:#7252b1}
 .week-picker [aria-pressed=true] strong{color:#6442b3}
 .week-grid{display:block}
 .week-grid .day-column{display:none;padding:16px;border-radius:14px}
 .week-grid .day-column.is-selected{display:block}
 .day-header .day-label strong{font-size:23px}
 .day-task{padding:14px 0;gap:11px}
 .day-task button:last-child{font-size:15px;line-height:1.5}
 .day-task small{font-size:12px;line-height:1.5;margin-top:5px}
 .week-empty{padding:18px 0 6px}
 .notes-empty{padding:23px 17px}
 .notes-empty>span{font-size:28px}
 .notes-empty h2{font-size:20px;line-height:1.35;margin:12px 0}
 .notes-empty p{font-size:14px}
 .note-toolbar{flex-wrap:nowrap;overflow-x:auto;padding:2px 0 5px;scrollbar-width:none}
 .note-toolbar .filter{flex-shrink:0;min-height:40px;padding:8px 10px;font-size:12px}
 .goal-workspace h2{font-size:23px;margin:13px 0;line-height:1.35}
 .goal-description{font-size:14px;margin:12px 0}
 .goal-measure{font-size:21px;margin:19px 0 10px}
 .goal-workspace .section-head{gap:10px}
 .goal-workspace .button{font-size:12px;padding:10px}
 .goal-actions .toolbar{display:grid;grid-template-columns:1fr 1fr}
 .goal-actions .toolbar .button{font-size:12px;padding:10px 8px}
 dialog[open]{position:fixed;inset:auto;top:calc(var(--visual-top,0px) + max(8px,env(safe-area-inset-top)));left:8px;right:8px;margin:0 auto;width:calc(100% - 16px);max-height:calc(var(--visual-height,100dvh) - max(8px,env(safe-area-inset-top)) - 8px);padding:18px;border-radius:18px;scroll-padding:74px 0 90px}
 dialog .dialog-top{position:sticky;top:-18px;background:#fff;z-index:3;padding:15px 0 10px;margin-top:-15px;align-items:flex-start}
 dialog .dialog-top h2{font-size:21px;line-height:1.25;margin:3px 0 6px}
 dialog .dialog-top .icon-button{flex:0 0 40px;width:40px;height:40px;min-height:40px}
 dialog .dialog-actions{bottom:-18px;margin-bottom:-18px;padding:12px 0 calc(12px + env(safe-area-inset-bottom));z-index:2;gap:8px}
 dialog .dialog-actions .button{flex:1;min-height:44px}
 dialog .field input,dialog .field select,dialog .field textarea{min-width:0;max-width:100%;font-size:16px}
 dialog .field input[type=date]{width:100%;min-height:44px;appearance:none;-webkit-appearance:none}
 dialog .field{margin:12px 0;font-size:13px}
 #task-composer-form .field{margin:12px 0}
 #task-composer-form .field textarea{min-height:74px;line-height:1.5;padding:10px 12px}
 .task-planning{padding:13px;margin:16px 0}
 .planning-dates{gap:10px}
 .planning-dates .field{font-size:12px}
 .planning-dates input{padding:10px 6px}
 .plan-shortcuts{gap:6px}
 .plan-shortcuts button{font-size:13px;flex:1;padding:8px 6px}
 .task-options>summary span{display:block;margin:6px 0 0 16px}
 .composer-subtitle{font-size:12px;margin-bottom:5px}
 #capture-form textarea{min-height:130px}
 #capture-form .form-hint{font-size:12px}
 #capture-form .dialog-actions{flex-direction:column-reverse;align-items:stretch}
 #capture-form .dialog-actions .text-button{text-align:center}
 #nav a{min-height:51px;font-size:10px;padding:7px 1px;gap:4px}
 #nav{padding-top:6px;padding-bottom:calc(6px + env(safe-area-inset-bottom))}
 #toast{bottom:calc(78px + env(safe-area-inset-bottom));width:calc(100vw - 28px);max-width:480px;box-sizing:border-box;font-size:13px;padding:12px 16px}
.media-actions{gap:7px}.media-actions .button{font-size:12px;padding:9px}
}
@media(max-width:360px){.planning-dates{grid-template-columns:minmax(0,1fr);gap:0}}
