/* Shared Omnivia surfaces and navigation. Page CSS may still define feature-specific layout. */
html[data-theme="midnight-compass"],html:not([data-theme]){
    --page:#eceef6;--surface:#f8f9fd;--surface-soft:#f0edf7;--ink:#20243b;--muted:#5b6078;
    --line:#d4d8e6;--nav:#152744;--nav-ink:#f6f5fb;--nav-selected:#392b60;
    --action:#493477;--action-ink:#fff;--secondary:#d6cde9;--secondary-ink:#352753;
    --accent:#b9a0ef;--summary:#e8e5f3;--focus:#8b55bc;--danger:#a43935;
    --success-bg:#e4eee8;--success-ink:#245441;--warning-bg:#f4ebd7;--warning-ink:#765215;
    --radius:5px;--heading-font:-apple-system,BlinkMacSystemFont,"Segoe UI",sans-serif;
}
html[data-theme="quiet-compass"]{
    --page:#f3f2ec;--surface:#fffefa;--surface-soft:#ecefe7;--ink:#203a3b;--muted:#526564;
    --line:#d8dfd9;--nav:#183c3b;--nav-ink:#f8f8f2;--nav-selected:#315450;
    --action:#176b62;--action-ink:#fff;--secondary:#cadfd5;--secondary-ink:#205b4e;
    --accent:#d6ae62;--summary:#e4eeea;--focus:#94630b;--danger:#a43935;
    --success-bg:#e4eeea;--success-ink:#205b4e;--warning-bg:#f4ebd7;--warning-ink:#805b16;
    --radius:6px;--heading-font:-apple-system,BlinkMacSystemFont,"Segoe UI",sans-serif;
}
html[data-theme="gilded-daydream"]{
    --page:#f5eee4;--surface:#fffbf3;--surface-soft:#f8efdf;--ink:#493747;--muted:#705d66;
    --line:#dfcfb5;--nav:#f1e4ce;--nav-ink:#493747;--nav-selected:#e7d5bc;
    --action:#e6c574;--action-ink:#423020;--link-ink:#72475f;--secondary:#e9d1c3;--secondary-ink:#60384f;
    --accent:#c39a45;--summary:#f8edd2;--focus:#805a36;--danger:#a43935;
    --success-bg:#e4eee8;--success-ink:#245441;--warning-bg:#f6e7c4;--warning-ink:#765215;
    --radius:8px;--heading-font:Georgia,"Times New Roman",serif;
}
*,*::before,*::after{box-sizing:border-box}
html{color-scheme:light;background:var(--page)}
html body{background:var(--page);color:var(--ink);font-family:-apple-system,BlinkMacSystemFont,"Segoe UI",sans-serif;font-size:15px;line-height:1.45}
html body.app-layout{display:block;place-items:normal;min-height:100vh;margin:0;padding:0 0 0 174px}
html body.app-layout>main{width:min(calc(100% - 36px),70rem);max-width:70rem;margin:20px auto 40px;padding:0 0 32px;background:transparent;border:0;border-radius:0;box-shadow:none;min-height:0}
html body.app-layout>main:has(>form:first-child){max-width:44rem}
html body.app-layout.form-page>main{max-width:44rem;padding:18px 20px 24px;background:var(--surface);border:1px solid var(--line);border-radius:var(--radius)}
html body.app-layout.utility-page>main{max-width:52rem;padding:18px 20px 24px;background:var(--surface);border:1px solid var(--line);border-radius:var(--radius)}
html body.app-layout>header{display:none}
html h1,html h2,html h3{color:var(--ink);font-family:var(--heading-font);line-height:1.2;letter-spacing:-.015em}
html h1{font-size:clamp(1.65rem,2vw,2rem);margin:.25rem 0 .35rem}
html h2{font-size:1.08rem;margin:.1rem 0 .45rem}
html h3{font-size:1rem}
html[data-theme="gilded-daydream"] h1{font-weight:400;font-size:clamp(1.85rem,2.2vw,2.2rem)}
html[data-theme="gilded-daydream"] h2{font-weight:600}
html a{color:var(--link-ink,var(--action));text-underline-offset:.2em}
html .meta,html .muted,html .empty,html .help,html .date,html small{color:var(--muted)}
html .card,html .day,html .optional-section,html .note,html fieldset{background:var(--surface);color:var(--ink);border:1px solid var(--line);border-radius:var(--radius);box-shadow:none}
html .card{padding:14px 16px;margin:0 0 12px}
html .day{overflow:hidden}
html .task,html .item,html .row:not(.topbar):not(.weekbar){border-color:var(--line)}
html .task,html .item,html .activity,html .row:not(.topbar):not(.weekbar){padding-top:8px;padding-bottom:8px}
html .task a,html .task-title,html .title,html .item-title,html .day .task{color:var(--ink)}
html .task-note,html .note,html .pwa-card{background:var(--surface-soft);color:var(--ink);border-color:var(--line)}
html .section-title{border-bottom:1px solid var(--line);padding-bottom:6px;margin-bottom:2px}
html .count,html .badge{background:var(--secondary);color:var(--secondary-ink);border-radius:4px}
html .badge.inactive{background:#f8e7e3;color:#a43935}
html .overdue,html .error,html .late{color:var(--danger)}
html .status,html .flash,html .notice:not(.warning){background:var(--success-bg);color:var(--success-ink);border-radius:var(--radius)}
html .form-page .status{background:transparent;color:var(--muted);padding:0}
html .warning{background:var(--warning-bg);color:var(--warning-ink)}
html input:not([type=checkbox]):not([type=radio]),html select,html textarea{font-family:inherit;font-size:16px;background:var(--surface);color:var(--ink);border:1px solid #9197af;border-radius:var(--radius);min-height:44px}
html input[type=checkbox],html input[type=radio]{accent-color:var(--action)}
html a:focus-visible,html button:focus-visible,html input:focus-visible,html select:focus-visible,html textarea:focus-visible,html summary:focus-visible{outline:3px solid var(--focus);outline-offset:3px}
html .topbar{margin-bottom:14px}
html .topbar h1{margin-top:0}
html .topbar p{margin:.2rem 0}
html .grid{gap:12px}
html .nav:not(.app-links){gap:6px}
html .toolbar{position:static;background:var(--surface);border:1px solid var(--line);padding:8px 10px;gap:6px;margin:12px 0;border-radius:var(--radius)}
html .toolbar a{display:inline-flex;align-items:center;min-height:44px;padding:6px 9px;text-decoration:none;border-radius:var(--radius)}
html .toolbar a:first-child{background:var(--action);color:var(--action-ink)}
html details:not(.app-mobile-menu){border-color:var(--line)}
html .pwa-status{color:var(--muted)}
html .budget-nav{display:flex;flex-wrap:wrap;gap:4px 16px;border-bottom:1px solid var(--line);margin:0 0 16px}
html .budget-nav a{display:inline-flex;align-items:center;min-height:44px;color:var(--muted);text-decoration:none;padding:5px 0}
html .budget-nav a[aria-current=page]{color:var(--link-ink,var(--action));font-weight:700;box-shadow:inset 0 -2px var(--action)}
html .tabs a{background:var(--surface);border-color:var(--line);border-radius:var(--radius)}
html .tabs a[aria-current=page]{background:var(--action);color:var(--action-ink)}
html .metrics{gap:12px}
html .metrics strong{color:var(--ink);font-variant-numeric:tabular-nums}
html .metrics .hero{color:var(--ink);font-size:2.3rem}
html .available-card{background:var(--summary);border-color:var(--accent)}
html .activity,html .item,html .task,.table-wrap td{border-color:var(--line)}
html .table-wrap{overflow-x:auto}
html table{width:100%;border-collapse:collapse}
html th,html td{border-color:var(--line);padding:9px 10px}
html th{color:var(--muted)}
html .calendar-grid{gap:10px}
html .day-header{border-color:var(--line);background:var(--surface-soft)}
html .today .day-header{background:var(--nav);color:var(--nav-ink)}
html .today .day-header strong,html .today .date{color:var(--nav-ink)}
html .day .tasks{padding:4px 10px 8px}
html .day .task{padding:8px 2px}
html[data-theme="gilded-daydream"] .card,html[data-theme="gilded-daydream"] .day{border-radius:8px 3px 8px 3px}
html[data-theme="gilded-daydream"] .available-card{box-shadow:inset 0 0 0 3px var(--surface),inset 0 0 0 4px #e4cea2}
html[data-theme="gilded-daydream"] .section-title{border-bottom:3px double var(--accent)}

/* One navigation component across authenticated pages. */
.skip-link{position:absolute;top:-80px;left:10px;z-index:1000;background:var(--surface);padding:8px 12px}
.skip-link:focus{top:10px}
.app-sidebar{position:fixed;inset:0 auto 0 0;width:174px;background:var(--nav);color:var(--nav-ink);padding:18px 12px;display:flex;flex-direction:column;gap:20px;z-index:30;overflow-y:auto;border-right:1px solid var(--line)}
.app-brand{display:flex;align-items:center;gap:8px;font-family:var(--heading-font);font-size:21px;line-height:1.1;letter-spacing:-.04em;color:inherit;text-decoration:none;white-space:nowrap}
.app-brand small{font-family:-apple-system,BlinkMacSystemFont,"Segoe UI",sans-serif;font-size:10px;letter-spacing:.08em;color:inherit}
.brand-compass{position:relative;width:28px;height:28px;border:2px solid currentColor;border-radius:50%;display:inline-block;flex:none}
.brand-compass::before{content:"";position:absolute;inset:3px;background:currentColor;opacity:.7;clip-path:polygon(50% 0,60% 37%,100% 50%,60% 63%,50% 100%,40% 63%,0 50%,40% 37%)}
.brand-compass::after{content:"";position:absolute;inset:1px;transform:rotate(28deg);background:linear-gradient(to bottom,var(--accent) 0 50%,currentColor 50%);clip-path:polygon(50% 0,69% 50%,50% 100%,31% 50%)}
html[data-theme="quiet-compass"] .brand-compass{border:3px solid currentColor;border-right-color:var(--accent);transform:rotate(-35deg)}
html[data-theme="quiet-compass"] .brand-compass::before{display:none}
html[data-theme="quiet-compass"] .brand-compass::after{inset:8px;width:6px;height:6px;border-radius:50%;background:currentColor;clip-path:none;transform:none}
.app-links{display:grid;gap:3px}
.app-links a,.app-sidebar-foot a,.app-sidebar-foot button{display:flex;align-items:center;width:100%;min-height:40px;padding:7px 10px;text-align:left;color:var(--nav-ink);text-decoration:none;background:transparent;border:0;border-radius:var(--radius);font-size:14px;font-weight:500}
.app-links a[aria-current=page],.app-sidebar-foot a[aria-current=page]{background:var(--nav-selected);box-shadow:inset 3px 0 var(--accent)}
.app-links a:hover,.app-sidebar-foot a:hover,.app-sidebar-foot button:hover{background:var(--nav-selected)}
.app-sidebar-foot{margin-top:auto;border-top:1px solid var(--accent);padding-top:10px;color:var(--nav-ink)}
.app-sidebar-foot .app-user-name{display:block;padding:0 10px 6px;font-size:13px;overflow-wrap:anywhere}
.app-sidebar-foot form{margin:0}
.app-sidebar-foot button{cursor:pointer}
.app-mobile-header{display:none}
.app-mobile-menu{border:0;padding:0;margin:0}
html[data-theme="gilded-daydream"] .brand-compass{border:3px double currentColor;box-shadow:0 0 0 2px #c39a4533}
html[data-theme="gilded-daydream"] .app-brand{font-family:Georgia,"Times New Roman",serif;font-size:24px}
html[data-theme="gilded-daydream"] .app-links a[aria-current=page]{border-radius:4px 14px 14px 4px}

/* Appearance controls are native radios, with visual previews. */
.appearance-page .page-heading{margin-bottom:18px}
.appearance-page .page-heading p{color:var(--muted);margin:.25rem 0}
.appearance-page .eyebrow{text-transform:uppercase;letter-spacing:.12em;font-size:12px;color:var(--muted);font-weight:600}
.appearance-page .theme-choices{border:0;background:transparent;padding:0;margin:0 0 16px;display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:12px}
.appearance-page .theme-choices legend{font-weight:650;margin-bottom:8px}
.theme-choice{display:flex;flex-direction:column;gap:5px;margin:0!important;padding:10px;border:2px solid var(--line);background:var(--surface);border-radius:var(--radius);cursor:pointer;min-width:0}
.theme-choice:has(input:checked){border-color:var(--action);box-shadow:0 0 0 2px var(--accent)}
.theme-choice input{align-self:flex-start;width:20px;height:20px;margin:0 0 3px}
.theme-choice strong,.theme-choice small{display:block}
.theme-choice small{font-size:13px}
.choice-picture{display:flex;min-height:115px;border-radius:4px;overflow:hidden;border:1px solid #b7b7b7;background:#f3f2ec;color:#203a3b}
.choice-top{width:46%;display:flex;align-items:flex-start;gap:5px;padding:8px 5px;font-family:Georgia,serif;font-size:11px;background:#183c3b;color:#fffefa}
.choice-top .brand-compass{width:18px;height:18px}
.choice-lines{flex:1;padding:13px 8px;display:grid;align-content:start;gap:8px}
.choice-lines i{display:block;height:12px;background:#fffefa;border:1px solid #d8dfd9;border-radius:3px}
.choice-lines i:first-child{height:22px;background:#e4eeea}
.theme-midnight .choice-picture{background:#eceef6;color:#20243b}
.theme-midnight .choice-top{background:#152744;color:#f8f9fd}
.theme-midnight .choice-lines i{background:#f8f9fd;border-color:#d4d8e6}
.theme-midnight .choice-lines i:first-child{background:#e9e5f3}
.theme-gilded .choice-picture{background:#f5eee4;color:#493747}
.theme-gilded .choice-top{background:#f1e4ce;color:#493747}
.theme-gilded .choice-lines i{background:#fffbf3;border-color:#dfcfb5}
.theme-gilded .choice-lines i:first-child{background:#f8edd2}
.appearance-page form>button{padding:11px 16px;border:0}

/* Public and authentication pages use the same theme surfaces without account navigation. */
html body:not(.app-layout)>main{background:var(--surface);color:var(--ink);border:1px solid var(--line);border-radius:var(--radius);box-shadow:none}
html body:not(.app-layout) h1{color:var(--ink)}
html body:not(.app-layout) p{color:var(--muted)}
html body:not(.app-layout) a.secondary{background:var(--secondary);color:var(--secondary-ink);border-color:var(--line)}
.public-brand{display:inline-flex;align-items:center;gap:10px;margin-bottom:12px;padding:0;background:transparent;color:var(--ink);border:0;border-radius:0;font-family:var(--heading-font);font-size:24px;line-height:1.1;text-decoration:none}
.public-brand small{font-family:-apple-system,BlinkMacSystemFont,"Segoe UI",sans-serif;font-size:11px;letter-spacing:.08em}
.public-brand .brand-compass{color:var(--action)}

@media(max-width:760px){
    html body.app-layout{padding-left:0}
    .app-sidebar{display:none}
    .app-mobile-header{position:relative;display:flex;align-items:center;justify-content:space-between;gap:10px;min-height:62px;padding:8px max(12px,env(safe-area-inset-right)) 8px max(12px,env(safe-area-inset-left));background:var(--nav);color:var(--nav-ink);border-bottom:1px solid var(--line);z-index:30}
    .app-mobile-header .app-brand{font-size:22px}
    .app-mobile-menu>summary{display:flex;align-items:center;justify-content:center;min-width:60px;min-height:44px;list-style:none;border:1px solid currentColor;border-radius:var(--radius);padding:5px 10px;cursor:pointer}
    .app-mobile-menu>summary::-webkit-details-marker{display:none}
    .app-mobile-menu nav{position:absolute;right:8px;top:calc(100% - 1px);width:min(280px,calc(100vw - 16px));max-height:calc(100vh - 70px);max-height:calc(100dvh - 70px);overflow:auto;padding:8px;background:var(--nav);border:1px solid var(--line);border-radius:0 0 var(--radius) var(--radius);box-shadow:0 12px 24px #20243b30;display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:2px}
    .app-mobile-menu nav a,.app-mobile-menu nav button{display:flex;align-items:center;min-height:44px;padding:8px;color:var(--nav-ink);background:transparent;text-decoration:none;border:0;font-size:14px;text-align:left}
    .app-mobile-menu nav a[aria-current=page]{background:var(--nav-selected);box-shadow:inset 3px 0 var(--accent)}
    .app-mobile-menu nav form{margin:0}
    .app-mobile-menu nav button{margin:0}
    html body.app-layout>main{width:calc(100% - 24px);margin:14px auto 28px;padding:0 0 max(24px,env(safe-area-inset-bottom))}
    html body.app-layout.form-page>main,html body.app-layout.utility-page>main{padding:14px 12px max(24px,env(safe-area-inset-bottom))}
    html .card{padding:10px 12px}
    html .topbar{gap:8px}
    html .task,html .item,html .activity{padding-top:8px;padding-bottom:8px}
    html .metrics .hero{font-size:2rem}
    .appearance-page .theme-choices{grid-template-columns:1fr}
    .theme-choice{display:grid;grid-template-columns:20px 112px 1fr;align-items:center;gap:4px 10px}
    .theme-choice input{grid-row:1/3}
    .theme-choice .choice-picture{grid-row:1/3;min-height:72px}
    .theme-choice strong{align-self:end}
    .theme-choice small{align-self:start}
    html .table-wrap:has(table) {overflow-x:visible}
    html .table-wrap:has(table) table,html .table-wrap:has(table) tbody{display:block;width:100%}
    html .table-wrap:has(table) thead{position:absolute;width:1px;height:1px;overflow:hidden;clip:rect(0,0,0,0);white-space:nowrap}
    html .table-wrap:has(table) tr{display:block;border-bottom:1px solid var(--line);padding:8px 0}
    html .table-wrap:has(table) td{display:grid;grid-template-columns:minmax(88px,35%) 1fr;gap:8px;align-items:start;border:0;padding:5px 0;overflow-wrap:anywhere}
    html .table-wrap:has(table) td::before{content:attr(data-label);color:var(--muted);font-size:13px}
}
@media(max-width:430px){
    html .grid{grid-template-columns:1fr}
    html .metrics>div{min-width:0}
    html .toolbar{font-size:14px}
    html .toolbar a{min-height:44px}
    html .actions{flex-wrap:wrap}
    html .table-wrap{overflow-x:auto}
}

/* Shared controls: semantic roles, comfortable targets and equal related actions. */
html{--complete-button:#70cda3;--danger-button:#f17874;--status-button-ink:#152020}
html button,html button[class],html a.button,html button.compact,html a.button.compact{
    display:inline-flex;align-items:center;justify-content:center;gap:6px;
    font-family:inherit;border-radius:var(--radius);cursor:pointer;text-decoration:none;
    min-height:44px;min-width:44px;height:auto;padding:10px 13px;
    font-size:15px;font-weight:600;line-height:1.2;text-align:center;
    white-space:normal;overflow-wrap:anywhere;box-sizing:border-box;
}
html button:not(.secondary):not(.danger):not(.complete-button):not(.link-button):not(.defer-button):not(.drag-handle):not(.order-button):not(.note-toggle):not(.app-signout),
html a.button:not(.secondary):not(.danger):not(.complete-button){background:var(--action);color:var(--action-ink);border:1px solid transparent}
html button.secondary,html a.button.secondary,html button.defer-button,html button.drag-handle,html button.order-button,html button.note-toggle,html a.map-button{
    background:var(--secondary);color:var(--secondary-ink);border:1px solid var(--secondary-ink);
}
html button.complete-button,html a.button.complete-button{background:var(--complete-button);color:var(--status-button-ink);border:1px solid transparent}
html button.danger,html a.button.danger{background:var(--danger-button);color:var(--status-button-ink);border:1px solid transparent}
html .control-group{
    display:grid;grid-auto-flow:column;grid-auto-columns:minmax(0,1fr);
    align-items:stretch;gap:8px;width:100%;min-width:0;
}
html .control-group>form{margin:0;min-width:0;display:flex;flex-direction:column;justify-content:flex-end}
html .control-group>form>button,html .control-group>a,html .control-group>button{width:100%;margin:0}
html .control-group>form>button{flex:none}
html .control-group>form:has(label)>button{flex:none}
html .control-group :is(button,a.button){padding:10px 13px;font-size:15px;font-weight:600;white-space:normal}
html .control-group.row-actions{width:21rem;max-width:100%;flex-shrink:0}
html .control-group.pair-actions{width:14rem;max-width:100%}
html .control-group.form-actions{max-width:32rem}
html .pwa-actions{display:flex;flex-wrap:wrap;gap:8px}
html .pwa-actions>button,html .pwa-actions>a{flex:1 1 9rem}
html .pwa-actions>[hidden]{display:none!important}
html .task-row,.item-row{min-width:0}
html button:disabled,html [aria-disabled=true]{opacity:.6;cursor:wait}
html [data-pending]{box-shadow:inset 0 0 0 2px currentColor;cursor:wait}
html button:disabled,html a[aria-disabled=true]{-webkit-tap-highlight-color:transparent}
html a[aria-disabled=true]:not([data-pending-recovery]){pointer-events:none}
html .control-problem{margin:12px 0;padding:10px 12px;background:var(--warning-bg);color:var(--warning-ink);border:1px solid var(--warning-ink);border-radius:var(--radius)}
html .control-problem p{margin:0 0 6px}
html .control-spinner{display:inline-block;width:14px;height:14px;flex:none;border:2px solid currentColor;border-right-color:transparent;border-radius:50%;animation:control-spin .8s linear infinite}
html .control-feedback{font-size:14px;color:var(--muted);grid-column:1/-1;grid-row:2;margin:8px 0 0}
@keyframes control-spin{to{transform:rotate(360deg)}}
@media(prefers-reduced-motion:reduce){html .control-spinner{animation:none;border-style:dotted}}
@media(max-width:680px){
    html .control-group.row-actions{width:100%}
    html .task-row:has(.control-group),html .item-row:has(.control-group),html .task:has(>.control-group){flex-direction:column;align-items:stretch}
}
@media(max-width:520px){
    html .control-group.form-actions{grid-auto-flow:row;grid-template-columns:minmax(0,1fr);max-width:none}
    html .control-group.form-actions .control-feedback{grid-row:auto}
}

/* Shared explanations: native details fallback, compact popover or modal dialog. */
.help-label { display:flex; align-items:center; gap:4px; flex-wrap:wrap; }
.help-label h2 { margin:0; }
.app-help { display:inline-block; vertical-align:middle; }
.help-trigger { display:flex; align-items:center; justify-content:center; width:44px; min-height:44px; cursor:pointer; list-style:none; color:var(--ink); border-radius:var(--radius); }
.help-trigger::-webkit-details-marker { display:none; }
.help-trigger span { display:flex; align-items:center; justify-content:center; width:18px; height:18px; border:1.5px solid currentColor; border-radius:50%; font:600 13px/1 sans-serif; }
.help-trigger:focus-visible { outline:3px solid var(--focus); outline-offset:2px; }
.app-help[open] { display:block; }
.app-help[open] .help-content { padding:12px; background:var(--surface); border:1px solid var(--line); border-radius:var(--radius); }
.help-panel { box-sizing:border-box; position:fixed; z-index:1000; padding:18px; background:var(--surface); color:var(--ink); border:1px solid var(--line); border-radius:var(--radius); overflow:auto; box-shadow:0 8px 28px #0003; font-size:1rem; line-height:1.5; }
.help-panel h2 { margin:0 0 12px; font-family:var(--heading-font); font-size:1.2rem; }
.help-panel p { margin:0 0 12px; }
.help-panel .secondary { margin-top:4px; }
.help-modal { width:min(520px,calc(100% - 24px)); max-height:calc(100dvh - 24px); margin:auto; }
.help-modal::backdrop { background:#0006; }

/* Thin, noninteractive status headers for Project/Goal and associated item cards. */
html body.app-layout .status-header{background:var(--secondary);color:var(--secondary-ink);padding:5px 10px;font-size:12px;font-weight:700;line-height:1.4;letter-spacing:.02em;text-align:left;overflow-wrap:anywhere}
html body.app-layout .status-header-completed{background:var(--complete-button);color:var(--status-button-ink)}
html body.app-layout .plan-status-card{padding:0;overflow:hidden;border:1px solid var(--line);border-radius:var(--radius);margin:0 0 .8rem}
html body.app-layout .plan-status-card>.row{padding:.8rem;border:0}
html body.app-layout .plan-status-card .item-row{padding:.8rem}
html body.app-layout .plan-detail-header{margin-bottom:.6rem;border-radius:4px}
html body.app-layout .card>h2+.control-group{margin-bottom:.8rem}

html .recovery-details{font:inherit;font-size:13px;white-space:pre-wrap;overflow-wrap:anywhere;margin:8px 0}
html .control-problem textarea[data-recovery-copy]{width:100%;box-sizing:border-box;font:inherit;white-space:pre-wrap}

/* Administration uses the shared status header and global action groups. */
html body.app-layout .status-header-active{background:var(--complete-button);color:var(--status-button-ink)}
html body.app-layout .status-header-inactive{background:var(--danger-button);color:var(--status-button-ink)}
html .administration-page .admin-user-list{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:12px}
html .administration-page .admin-user-card{padding:0;margin:0 0 12px;overflow:hidden;min-width:0}
html .administration-page .admin-user-list .admin-user-card{margin:0;display:flex;flex-direction:column}
html .administration-page .admin-user-content{padding:14px 16px;overflow-wrap:anywhere}
html .administration-page .admin-user-list .admin-user-content{display:flex;flex-direction:column;flex:1}
html .administration-page .admin-user-content p{margin:.25rem 0 .8rem}
html .administration-page .admin-user-info{grid-template-columns:6rem minmax(0,1fr);gap:6px 12px;margin:0 0 14px}
html .administration-page .admin-user-info dt{font-weight:400;color:var(--muted)}
html .administration-page .admin-user-info dd{margin:0}
html .administration-page .admin-user-list .control-group{margin-top:auto}
html .administration-page .card{min-width:0;overflow-wrap:anywhere}
html .administration-page .card input,html .administration-page .card select{min-width:0;max-width:100%}
@media(max-width:760px){html .administration-page .admin-user-list{grid-template-columns:minmax(0,1fr)}}

/* Budget activity states share the approved labeled header pattern. */
html body.app-layout .status-header-part-recorded{background:#f3d69a;color:#513c16}
html body.app-layout .status-header-skipped{background:#c9c5bf;color:var(--status-button-ink)}

/* Profile settings and compact mobile navigation. */
.app-profile-menu summary{display:flex;align-items:center;gap:8px;cursor:pointer;list-style:none;min-height:44px}
.app-profile-menu summary::-webkit-details-marker,.app-mobile-menu summary::-webkit-details-marker{display:none}
.app-profile-menu summary::marker,.app-mobile-menu summary::marker{content:""}
.app-profile-menu svg{flex:none}
.app-profile-menu nav{display:flex;flex-direction:column;gap:4px;padding:8px 0}
.app-profile-menu nav a,.app-profile-menu nav button{display:flex;align-items:center;min-height:44px;padding:8px 10px;text-decoration:none}
.app-mobile-actions{display:flex;align-items:center;gap:6px}
.app-mobile-header .profile-label{display:none}
.app-mobile-header .app-profile-menu summary,.app-mobile-header .app-mobile-menu summary{display:flex;align-items:center;justify-content:center;min-width:44px;min-height:44px;width:44px;height:44px;padding:0;border:0;background:transparent;color:var(--nav-ink)}
.app-mobile-header .app-profile-menu nav{position:absolute;right:8px;top:calc(100% - 4px);width:min(280px,calc(100vw - 16px));max-height:calc(100dvh - 90px);overflow:auto;padding:10px;background:var(--surface);border:1px solid var(--line);border-radius:var(--radius);box-shadow:0 8px 20px #0002;z-index:50}
.app-mobile-header .app-profile-menu nav a,.app-mobile-header .app-profile-menu nav button{color:var(--ink);background:var(--surface-soft);border:0;border-radius:var(--radius);width:100%;font:inherit;text-align:left}
.app-mobile-header .app-profile-menu .app-user-name{padding:4px 10px;overflow-wrap:anywhere;color:var(--muted)}

/* Shared compact list-card controls. Page forms, navigation and pagination keep their larger size. */
html body.app-layout :is(.task,.item-row,.plan-status-card,.admin-user-card,.budget-activity-card,[data-record-id],[data-budget-entry-id]) :is(button,a.button,a.map-button){
    display:inline-flex;align-items:center;justify-content:center;
    min-height:32px;height:auto;padding:5px 12px;font-size:15px;line-height:1.2;
}
/* Icon-only Today arrows retain their icon width within the compact control. */
html body.app-layout .task button.order-button{padding:5px 0}
