:root{color-scheme:light dark;--paper:light-dark(#fff,#202731);--ink:light-dark(#273446,#edf2f8);--quiet:light-dark(#637185,#b3bece);--line:light-dark(#d5dce6,#455164);--cell:light-dark(#eff1f6,#2c3544);--nav:light-dark(#2d425e,#23354e);--teal:#5f8388;font:14px/1.5 system-ui,sans-serif;background:var(--paper);color:var(--ink)}*{box-sizing:border-box}body{margin:0}button,input,select,textarea{font:inherit}button,.button,.icon-button{display:inline-flex;align-items:center;justify-content:center;gap:8px;color:var(--ink);background:var(--cell);border:1px solid var(--line);border-radius:6px;padding:9px 13px;text-decoration:none;cursor:pointer;min-height:42px}button:disabled{opacity:.5;cursor:default}button:focus-visible,a:focus-visible,input:focus-visible,select:focus-visible{outline:2px solid var(--teal);outline-offset:3px}.primary{background:var(--teal);color:#fff;border-color:var(--teal)}a{color:inherit}h1{font-size:22px;font-weight:600}h2{font-size:18px;font-weight:600}.quiet{font-size:12px;color:var(--quiet)}.error{color:light-dark(#b42318,#ffaba4)}.app-shell{max-width:1100px;margin:0 auto}.auth-page{max-width:500px;margin:40px auto;padding:24px}.auth-page label{display:block;margin:16px 0 6px}.auth-page input{display:block;width:100%;padding:11px;margin-top:7px;border:1px solid var(--line);border-radius:5px;color:var(--ink);background:var(--cell);font-size:16px}.back-link{display:inline-block;margin-bottom:20px;color:var(--quiet);text-decoration:none}.auth-page form{margin:24px 0}.account-links{display:flex;flex-direction:column;gap:8px;margin:20px 0}.auth-page details{border-top:1px solid var(--line);padding-top:16px}svg{width:18px;height:18px;flex:none}.public-programme{min-height:100dvh;display:flex;flex-direction:column}.programme-top{position:relative;text-align:center;padding:18px 58px;border-bottom:1px solid var(--line)}.programme-top h1{margin:0}.desktop-account{position:absolute;right:16px;top:12px}.week-top{display:flex;align-items:center;justify-content:space-between;text-align:center;gap:12px;background:var(--nav);color:#fff;padding:18px}.week-top p,.week-top h2{margin:3px 0}.week-top .quiet{color:inherit;opacity:.8}.week-top>div{flex:1}#public-content{display:grid;grid-template-columns:1fr 1fr;gap:20px;padding:20px;flex:1;align-content:start}.public-meeting{min-width:0}.public-meeting>header{text-align:center;padding:10px 0 20px}.public-meeting>header h3{margin:0 0 7px;font-size:18px}.public-meeting>header p{margin:3px 0}.programme-part{margin:0 0 10px;border-bottom:0}.programme-part>h4,.public-messages>h4{position:sticky;top:calc(var(--programme-top-height,145px) + var(--programme-meeting-height,0px));z-index:20}.programme-part h4,.public-messages h4{margin:0;padding:9px 12px;background:var(--part-color,var(--teal));color:#fff;font-size:13px;font-weight:500}.programme-part dl{display:grid;grid-template-columns:42% minmax(0,1fr);margin:0;padding:9px 12px;gap:7px 12px}.programme-part dt{font-size:12px;color:var(--quiet)}.programme-part dd{margin:0;overflow-wrap:anywhere}.programme-part h5{margin:0;padding:10px 12px 0;font-size:13px;font-weight:500}.programme-assignment{border-top:1px solid var(--line)}.programme-part>p{padding:9px 12px;color:var(--quiet);margin:0}.public-messages h4{background:light-dark(#496a86,#38556d)}.public-messages{margin-top:16px}.public-messages button{width:100%;justify-content:space-between;text-align:left;margin-top:8px}.public-messages textarea{width:100%;min-height:180px;background:var(--cell);color:var(--ink);border:1px solid var(--line);padding:10px}.public-service{grid-column:1/-1}.service-meeting{margin-bottom:18px}.public-dock{border-top:1px solid var(--line);background:var(--paper);padding:10px 16px}.section-tabs{display:none}.week-buttons{display:flex;justify-content:center;gap:8px}.week-buttons [data-step]{display:none}.week-buttons>button,.week-buttons>a{min-height:44px}.week-buttons>button:not(#this-week){width:44px}.week-buttons .account-entry{display:none}.section-tabs button[aria-selected=true]{background:var(--nav);color:#fff}.empty-programme{grid-column:1/-1;text-align:center;padding:50px 12px;color:var(--quiet)}dialog{max-width:calc(100vw - 24px);width:390px;max-height:85dvh;overflow:auto;padding:20px;background:var(--paper);color:var(--ink);border:1px solid var(--line);border-radius:12px}dialog::backdrop{background:#0006}.calendar-fields{display:flex;gap:12px}.calendar-fields label{flex:1}.calendar-fields select{display:block;width:100%;margin:5px 0 14px;min-height:44px;background:var(--cell);color:var(--ink);border:1px solid var(--line);font-size:16px}#calendar-weeks button{width:100%;justify-content:space-between;margin-bottom:8px;font-size:13px}#calendar-weeks small{color:var(--quiet)}.editor-page{background:var(--paper)}.editor-page #programme-device-preview .preview-controls{display:none}.editor-page #programme-device-preview .preview-stage{width:100%;max-width:none}.editor-page #service-week-grid{border:0;border-radius:0}.editor-page.app-booting #service-week-grid{visibility:hidden}.editor-page #app-loading{padding:24px}.editor-page:not(.app-booting) #app-loading{display:none}#persistence-status{position:sticky;top:0;z-index:100;padding:8px 14px;background:var(--paper);color:var(--quiet);border-bottom:1px solid var(--line);font:12px system-ui}#persistence-status[data-error=true]{color:light-dark(#b42318,#ffaba4);background:light-dark(#fff0ee,#412c2b)}.editor-page .preview-size{display:none}.editor-page .preview-stage{container-type:inline-size}.editor-page #programme-device-preview{height:100dvh;min-height:0}.editor-page .server-account-button{min-height:40px}.invitation-link{display:block;overflow-wrap:anywhere;font-size:13px;padding:8px 0}.editor-page #service-week-grid .users-preview-note{display:none}
/* Programme keeps the mobile layout at every screen width. */
body:has(.public-programme){min-height:100dvh;overflow-x:clip;background:light-dark(#eef1f5,#171d25)}.app-shell:has(>.public-programme){width:100%;max-width:760px;margin-inline:auto;min-height:100dvh;box-shadow:-6px 0 16px -8px light-dark(#26354a24,#00000055),6px 0 16px -8px light-dark(#26354a24,#00000055)}.public-programme{min-height:100dvh;background:var(--paper);padding-top:var(--programme-top-height,145px);padding-bottom:var(--programme-bottom-height,111px)}.public-topbar{position:fixed;top:0;inset-inline:0;z-index:30;background:var(--paper);box-shadow:0 4px 12px light-dark(#26354a12,#00000030)}.public-topbar .week-top>div{max-width:736px;margin-inline:auto}.programme-top{padding:7px 12px}.programme-top h1{font-size:18px}.desktop-account,.desktop-week{display:none}.week-top{padding:7px 12px;flex:none}.week-top h2{font-size:17px}.week-top p,.week-top h2{margin:2px 0}#public-content{display:block;flex:1;min-height:0;overflow:visible;padding:0 0 16px}.public-meeting{display:none}.public-meeting.active{display:block}.public-meeting>header{padding:16px 0}.public-meeting>header h3{font-size:17px}.public-dock{position:fixed;bottom:0;inset-inline:0;z-index:30;width:100%;padding:8px 12px max(8px,env(safe-area-inset-bottom));box-shadow:0 -4px 12px light-dark(#26354a12,#00000030)}.public-dock-inner{width:100%;max-width:736px;margin-inline:auto}.section-tabs{display:flex;gap:6px;margin-bottom:8px}.section-tabs button{flex:1;font-size:12px;padding:7px;min-height:42px}.week-buttons{display:grid;grid-template-columns:44px minmax(0,1fr) repeat(4,44px)}.week-buttons [data-step],.week-buttons .account-entry{display:flex}.week-buttons [data-step]{font-size:22px;line-height:1}.week-buttons>button,.week-buttons>a{padding:9px;background:var(--nav);color:#fff;border:0}#this-week{width:100%;white-space:nowrap}
@media(max-width:640px){.auth-page{margin:0 auto;padding:24px 18px}.auth-page h1{font-size:22px}#persistence-status{position:relative;flex:none}.editor-page #programme-device-preview{height:calc(100dvh - 32px)}.editor-page #service-week-grid{--viewer-screen-height:100%}}

.editor-page #programme-device-preview .preview-stage{width:100%!important;max-width:none!important}.editor-page #programme-device-preview.mobile-editor-preview{height:calc(100dvh - 33px)!important}.editor-page #service-week-grid.mobile-editor-navigation .header-actions .server-account-button{display:none}

/* Shared meeting header colours for light and dark mode. */
.public-midweek>header>h3,.public-weekend>header>h3,.public-service>header>h3{background:light-dark(#b95b12,#a94f0a);color:#fff;padding:10px 12px;margin:0 0 12px}

.public-midweek>header,.public-weekend>header,.public-service>header{position:sticky;top:var(--programme-top-height,145px);z-index:25;padding-top:0;background:light-dark(#b95b12,#a94f0a);color:#fff}

.appearance-setting{display:flex;flex-direction:column;gap:8px;max-width:360px;margin:20px 0;font-size:13px}.appearance-setting select{width:100%;min-height:44px;padding:9px 12px;background:var(--cell);color:var(--ink);border:1px solid var(--line);border-radius:6px;font-size:16px}

.public-appearance{position:relative;flex:none}.public-appearance summary{display:flex;align-items:center;justify-content:center;list-style:none;width:44px;height:44px;border:1px solid var(--line);border-radius:6px;background:var(--cell);cursor:pointer}.public-appearance summary::-webkit-details-marker{display:none}.public-appearance summary:focus-visible{outline:2px solid var(--teal);outline-offset:3px}.public-appearance-menu{position:absolute;bottom:calc(100% + 10px);right:0;width:200px;padding:12px;background:var(--paper);border:1px solid var(--line);border-radius:9px;box-shadow:0 4px 20px light-dark(#26354a24,#0006)}.public-appearance-menu p{margin:0 0 8px;font-size:13px;font-weight:600}.public-appearance-menu button{display:flex;width:100%;justify-content:flex-start;margin-top:5px}.public-appearance-menu button[aria-pressed=true]{background:var(--nav);color:#fff}

.week-buttons .public-appearance summary{background:var(--nav);color:#fff;border:0}
@media(max-width:380px){.week-buttons{grid-template-columns:40px minmax(0,1fr) repeat(4,40px);gap:4px}.week-buttons>button:not(#this-week),.week-buttons>.account-entry,.week-buttons .public-appearance summary{width:40px}}

.public-midweek>header,.public-weekend>header,.public-service>header{padding:8px 12px}.public-midweek>header>h3,.public-weekend>header>h3,.public-service>header>h3{font-size:16px;line-height:1.3;padding:0;margin:0 0 4px}.public-service>header>h3{margin-bottom:0}.public-midweek>header>.meeting-meta,.public-weekend>header>.meeting-meta{font-size:12px;line-height:1.4;margin:0;overflow-wrap:anywhere}

/* Compact message rows, matching the original programme's sharing controls. */
.public-messages{margin-top:16px}
.public-messages>h4{background:#3B4A5C}
.public-messages .message-rows{display:grid;grid-template-columns:42% minmax(0,1fr);margin:0}
.message-rows>dt,.programme-part dt{display:flex;align-items:center;justify-content:flex-end;text-align:right;padding:10px 12px;background:light-dark(#243342,#18232d);color:#fff;font-size:13px;font-weight:600;line-height:1.4}
.message-rows>dd,.programme-part dd{margin:0;background:light-dark(#f1f3f8,#252e3a)}
.message-rows>dd{display:flex;align-items:center;padding:6px 12px}
.programme-part dl{padding:0;gap:0;grid-template-columns:42% minmax(0,1fr)}
.programme-part dt,.programme-part dd{padding:8px 12px;min-width:0;overflow-wrap:anywhere}
.programme-part dd{align-content:center}
.programme-assignment>h5{padding:8px 12px}
.public-messages .message-copy{width:44px;min-width:44px;height:44px;min-height:44px;justify-content:center;margin:0;padding:9px;border:0;border-radius:3px;background:light-dark(#243342,#18232d);color:#fff;transition:background-color .15s}
.public-messages .message-copy:hover{background:#d5632a}
.public-messages .message-copy svg{width:24px;height:24px}
.public-messages .message-copy.copied{background:#356b53;font-size:23px}
.public-messages .message-feedback{margin:0;padding:8px 12px}
.public-messages .message-feedback:empty{display:none}
.public-messages textarea{display:block;width:calc(100% - 24px);margin:8px 12px}
.public-messages textarea[hidden]{display:none}

@media(max-width:640px){
 .public-programme .programme-part dl,.public-programme .public-messages .message-rows{grid-template-columns:36% minmax(0,1fr)}
 .public-programme .programme-part dt,.public-programme .message-rows>dt{padding-inline:8px}
}

/* Assignment titles form the third sticky heading level within their part. */
.public-programme .programme-assignment{border-top:0}
.public-programme .programme-assignment>h5{
 position:sticky;
 top:calc(var(--programme-top-height,145px) + var(--programme-meeting-height,0px) + var(--programme-part-heading-height,38px));
 z-index:15;
 padding:8px 12px;
 background:#42536b;
 color:#fff;
 font-weight:600;
}
.public-programme .programme-part.has-assignments{margin-bottom:0}

/* Keep successive programme sections flush, including service meetings and messages. */
.public-programme .programme-part,.public-programme .service-meeting{margin-bottom:0}
.public-programme .public-messages{margin-top:0}

/* Each service meeting owns its sticky title and message subsection. */
.public-programme .service-meeting>h4{position:sticky;top:calc(var(--programme-top-height,145px) + var(--programme-meeting-height,0px));z-index:20}
.public-programme .service-meeting>.public-messages>h5{margin:0;padding:9px 12px;background:#495678;color:#fff;font-size:13px;font-weight:500}

/* Consistent Field Service meeting and subsection heading treatment in both modes. */
.public-programme .service-meeting>h4,
.public-programme .service-meeting>.service-subsection>h5,
.public-programme .service-meeting>.public-messages>h5{
 margin:0;
 padding:9px 12px;
 background:#4c607d;
 color:#fff;
 font-size:13px;
 font-weight:500;
 line-height:1.5;
}

.public-programme .service-meeting>.service-subsection>h5,
.public-programme .service-meeting>.public-messages>h5{background:#3B4A5C;font-size:13px;padding:9px 12px}

/* A subsection stays below its meeting title and yields at its own boundary. */
.public-programme .service-meeting>.service-subsection>h5{
 position:sticky;
 top:calc(var(--programme-top-height,145px) + var(--programme-meeting-height,0px) + var(--programme-part-heading-height,38px));
 z-index:15;
}

/* Navy meeting dates tie in with the week header. */
.public-programme .service-meeting>h4{
 background:#2D425E;
 color:#fff;
 font-size:14px;
 font-weight:650;
 line-height:1.45;
 padding:10px 12px;
}

/* Softer secondary headings in light mode, retaining the dark-mode palette. */
.public-programme .remote-connection-part>h4,
.public-programme .public-messages>h4,
.public-programme .service-meeting>.service-subsection>h5{
 background:light-dark(#536B85,#3B4A5C);
 color:#fff;
}

/* Fit the editor to the window: only the active view scrolls vertically. */
body.editor-page{height:100dvh;min-height:0;overflow:hidden;display:flex;flex-direction:column}
.editor-page #persistence-status{position:relative;flex:none}
.editor-page #programme-device-preview,
.editor-page #programme-device-preview.mobile-editor-preview{flex:1;min-height:0;height:auto!important;overflow:hidden}
.editor-page #programme-device-preview .preview-stage{height:100%;min-height:0}
.editor-page #service-week-grid,
.editor-page #service-week-grid.mobile-editor-navigation{display:flex;flex-direction:column;height:100%;min-height:0;overflow:hidden}
.editor-page #service-week-grid>:is(.toolbar,.view-switch,.viewer-publish-bar,.footer,.mobile-editor-dock){flex:none}
.editor-page #service-week-grid>:is(#combined-programme,#combined-talks,#combined-watchtower,#combined-school,#combined-settings){flex:1;min-height:0;max-height:none;overflow:auto!important}
.editor-page #service-week-grid>:is(#combined-people,#combined-privileges){flex:1;min-height:0;overflow:hidden;display:flex;flex-direction:column}
.editor-page #service-week-grid>:is(#combined-people,#combined-privileges)[hidden]{display:none}
.editor-page #service-week-grid #combined-people>.eligibility-grid,
.editor-page #service-week-grid #combined-privileges>.eligibility-matrix-sections{flex:1;min-height:0;max-height:none}

/* Publishing is anchored to each week instead of the scrolling selection. */
.editor-page #service-week-grid .viewer-publish-bar{display:none!important}
.editor-page #service-week-grid .week-cell-actions{display:flex;flex-direction:column;gap:5px;margin-top:8px;text-align:left;font:12px/1.35 system-ui;color:var(--ink)}
.editor-page #service-week-grid thead .week-cell-actions{color:#fff}
.editor-page #service-week-grid #combined-programme .editor-week-actions-row>td{padding:8px 10px;background:var(--cell);vertical-align:top}
.editor-page #service-week-grid #combined-programme .editor-week-actions-row .week-cell-actions{margin:0;color:var(--ink)}
.editor-page #service-week-grid.mobile-editor-navigation #combined-programme .editor-week-actions-row>td:not(.mobile-week-active){display:none}
.editor-page #service-week-grid .week-action-status{font-size:11px;font-weight:500;white-space:nowrap}
.editor-page #service-week-grid .week-action-status{align-self:flex-start;padding:2px 7px;border-radius:4px}
.editor-page #service-week-grid :is(.week-last-published,.week-last-edited){font-size:10px;line-height:1.4;color:var(--quiet);font-weight:400;overflow-wrap:anywhere}
.editor-page #service-week-grid .week-publishing-info[data-publication="draft"] .week-action-status{background:light-dark(#e2e8f0,#344155);color:light-dark(#41536c,#d3deed)}
.editor-page #service-week-grid .week-publishing-info[data-publication="published"] .week-action-status{background:light-dark(#dcefe3,#234936);color:light-dark(#24613c,#b9e6c9)}
.editor-page #service-week-grid .week-publishing-info[data-publication="changed"] .week-action-status{background:light-dark(#fff0ce,#55401f);color:light-dark(#805000,#f6d28e)}
.editor-page #service-week-grid .week-action-buttons{display:flex;gap:6px;flex-wrap:wrap}
.editor-page #service-week-grid .week-action-buttons button{padding:5px 8px;min-height:30px;min-width:0;font-size:11px;font-weight:500;white-space:nowrap;border:1px solid var(--line);border-radius:4px;background:var(--paper);color:var(--ink)}
.editor-page #service-week-grid .week-action-buttons button[hidden]{display:none}
.editor-page #service-week-grid .week-action-buttons button[aria-pressed="true"]{background:var(--nav);color:#fff;outline:1px solid #b7cbea}
.editor-page #service-week-grid [data-week-actions-heading],.editor-page #service-week-grid [data-week-actions-cell]{width:165px;min-width:165px;vertical-align:middle}
.editor-page #service-week-grid [data-week-actions-cell]{padding:8px}
.editor-page #service-week-grid [data-week-actions-cell]>.week-cell-actions{margin:0}
.editor-page #service-week-grid #combined-school .school-day-row .week-cell-actions{margin:6px 0 0;color:var(--ink)}
.editor-page #service-week-grid .week-focus-dimmed{position:relative}
.editor-page #service-week-grid .week-focus-dimmed::after{content:'';position:absolute;inset:0;background:light-dark(#00000029,#00000070);z-index:5;pointer-events:none}
.editor-page #service-week-grid .week-focus-selected{box-shadow:inset 2px 0 0 var(--teal),inset -2px 0 0 var(--teal)}
.editor-page #service-week-grid thead .week-focus-selected{box-shadow:inset 2px 0 0 var(--teal),inset -2px 0 0 var(--teal),inset 0 3px 0 #b7cbea}
@media(max-width:640px){.editor-page #service-week-grid [data-week-actions-cell]{width:auto;min-width:0}.editor-page #service-week-grid [data-week-actions-cell]::before{content:none}.editor-page #service-week-grid #combined-school .school-day-row .week-cell-actions{padding:0 8px 8px}}

.editor-page #service-week-grid #combined-school .school-day-toolbar{display:flex;align-items:center;justify-content:space-between;gap:12px;padding:8px 10px}
.editor-page #service-week-grid #combined-school .school-day-toolbar>.school-day-toggle{flex:1;min-width:0;width:auto;padding:0}
.editor-page #service-week-grid #combined-school .school-day-toolbar>.week-cell-actions{flex:none;margin:0;color:inherit}
@media(max-width:640px){.editor-page #service-week-grid #combined-school .school-day-toolbar{flex-wrap:wrap}.editor-page #service-week-grid #combined-school .school-day-toolbar>.week-cell-actions{padding:0}}

/* Centre coordination actions when weeks are displayed as rows. */
.editor-page #service-week-grid:not(.mobile-editor-navigation) :is(#combined-talks,#combined-watchtower,#combined-school) .week-cell-actions{align-items:center;text-align:center}
.editor-page #service-week-grid:not(.mobile-editor-navigation) :is(#combined-talks,#combined-watchtower,#combined-school) .week-action-buttons{justify-content:center}
.editor-page #service-week-grid:not(.mobile-editor-navigation) :is(#combined-talks,#combined-watchtower,#combined-school) .week-action-status{align-self:center}
.editor-page #service-week-grid:not(.mobile-editor-navigation) :is(#combined-talks,#combined-watchtower) [data-week-actions-heading]{text-align:center}

/* Week columns pair publication details with a compact vertical action stack. */
.editor-page #service-week-grid .week-publishing-info{display:flex;flex-direction:column;gap:5px;min-width:0;font:12px/1.35 system-ui;color:var(--ink)}
.editor-page #service-week-grid #combined-programme .week-cell-actions,
.editor-page #service-week-grid.mobile-editor-navigation .week-cell-actions{display:grid;grid-template-columns:minmax(0,1fr) auto;align-items:start;gap:12px;text-align:left}
.editor-page #service-week-grid #combined-programme .week-publishing-info,
.editor-page #service-week-grid.mobile-editor-navigation .week-publishing-info{grid-column:1;grid-row:1;align-items:flex-start;text-align:left}
.editor-page #service-week-grid #combined-programme .week-action-buttons,
.editor-page #service-week-grid.mobile-editor-navigation .week-action-buttons{grid-column:2;grid-row:1;flex-direction:column;align-items:stretch;min-width:76px}
.editor-page #service-week-grid.mobile-editor-navigation [data-week-publication-cell]{display:none!important}

/* Row views separate horizontal actions from their publication details. */
.editor-page #service-week-grid:not(.mobile-editor-navigation) :is(#combined-talks,#combined-watchtower) [data-week-publication-cell]{padding:12px;vertical-align:middle}
.editor-page #service-week-grid:not(.mobile-editor-navigation) :is(#combined-talks,#combined-watchtower,#combined-school) .week-publishing-info{align-items:center;text-align:center}
.editor-page #service-week-grid:not(.mobile-editor-navigation) :is(#combined-talks,#combined-watchtower) .week-action-buttons{flex-wrap:nowrap}
.editor-page #service-week-grid:not(.mobile-editor-navigation) #combined-talks .talk-rows{min-width:1950px}
.editor-page #service-week-grid:not(.mobile-editor-navigation) #combined-watchtower .watchtower-rows{min-width:1250px}
.editor-page #service-week-grid:not(.mobile-editor-navigation) :is(#combined-talks,#combined-watchtower) :is(.talk-rows,.watchtower-rows) thead th:nth-child(n){width:160px}
.editor-page #service-week-grid:not(.mobile-editor-navigation) #combined-talks .talk-rows thead th:nth-child(5){width:240px}
.editor-page #service-week-grid:not(.mobile-editor-navigation) :is(#combined-talks,#combined-watchtower) :is(.talk-rows,.watchtower-rows) thead th[data-coordination-notes-heading]{width:300px}
.editor-page #service-week-grid:not(.mobile-editor-navigation) :is(#combined-talks,#combined-watchtower) :is(.talk-rows,.watchtower-rows) thead th[data-week-publication-heading]{width:260px;text-align:center}
.editor-page #service-week-grid:not(.mobile-editor-navigation) #combined-school table{min-width:1100px}
.editor-page #service-week-grid:not(.mobile-editor-navigation) #combined-school thead th:nth-child(1){width:24%}
.editor-page #service-week-grid:not(.mobile-editor-navigation) #combined-school thead th:nth-child(2),
.editor-page #service-week-grid:not(.mobile-editor-navigation) #combined-school thead th:nth-child(3){width:18%}
.editor-page #service-week-grid:not(.mobile-editor-navigation) #combined-school thead th:nth-child(4){width:12%}
.editor-page #service-week-grid:not(.mobile-editor-navigation) #combined-school thead th:nth-child(5){width:28%}
.editor-page #service-week-grid:not(.mobile-editor-navigation) #combined-school .school-day-toolbar{display:grid;grid-template-columns:minmax(220px,1fr) 160px 260px;align-items:center}
.editor-page #service-week-grid:not(.mobile-editor-navigation) #combined-school .school-day-toolbar>.week-cell-actions{display:contents}
.editor-page #service-week-grid:not(.mobile-editor-navigation) #combined-school .week-action-buttons{justify-content:center;flex-wrap:nowrap}
.editor-page #service-week-grid.mobile-editor-navigation #combined-school .school-day-toolbar>.week-cell-actions{width:100%}
.editor-page #service-week-grid #combined-school .school-day-toolbar .week-publishing-info{color:inherit}
.editor-page #service-week-grid #combined-school .school-day-toolbar :is(.week-last-published,.week-last-edited){color:inherit;opacity:.85}

/* Field activity and the week edit-history inspector. */
.editor-page #service-week-grid .week-edit-details{display:flex;align-items:center;gap:5px;min-width:0}
.editor-page #service-week-grid .week-edit-details[hidden]{display:none}
.editor-page #service-week-grid .week-history-eye{display:inline-flex;flex:none;align-items:center;justify-content:center;width:26px;height:26px;min-height:26px;padding:3px;border:0;background:transparent;color:inherit;border-radius:4px;cursor:pointer}
.editor-page #service-week-grid .week-history-eye:hover{background:light-dark(#304c7817,#b5d1ff20)}
.editor-page #service-week-grid .collaboration-banner{position:fixed;bottom:14px;left:14px;z-index:90;max-width:min(420px,calc(100vw - 28px));padding:9px 12px;background:var(--paper);color:var(--ink);font-size:11px;line-height:1.4;border:1px solid var(--line);border-radius:6px;box-shadow:0 3px 16px #0003;overflow-wrap:anywhere}
.editor-page #service-week-grid .field-presence-anchor{display:grid;position:relative;min-width:0;width:100%;z-index:6;user-select:none;-webkit-user-select:none}
.editor-page #service-week-grid .field-presence-compact{display:inline-grid;width:auto;vertical-align:middle}
.editor-page #service-week-grid .field-editor-presence{position:absolute;right:0;bottom:100%;z-index:3;max-width:240px;padding:2px 6px;font:600 10px/1.4 system-ui;color:#fff;background:var(--editor-colour);border-radius:3px 3px 0 0;white-space:nowrap;overflow:hidden;text-overflow:ellipsis;pointer-events:none;user-select:none;-webkit-user-select:none}
.editor-page #service-week-grid .field-lock-shield{position:absolute;inset:0;z-index:2;cursor:not-allowed;user-select:none;-webkit-user-select:none;background:color-mix(in srgb,var(--editor-colour) 7%,transparent);touch-action:pan-x pan-y}
.editor-page #service-week-grid [data-collaboration-locked]{outline:2px solid var(--editor-colour);outline-offset:-2px;opacity:1;user-select:none;-webkit-user-select:none;cursor:not-allowed}
.editor-page #service-week-grid .week-edit-history{width:min(780px,calc(100vw - 24px));max-height:85dvh;padding:18px;background:var(--paper);color:var(--ink);border:1px solid var(--line);border-radius:10px;overflow:auto;box-shadow:0 12px 60px #0006}
.editor-page #service-week-grid .week-edit-history::backdrop{background:#0008}
.editor-page #service-week-grid .edit-history-header{display:flex;align-items:center;justify-content:space-between;gap:12px;position:sticky;top:-18px;padding-block:12px;background:var(--paper);z-index:1}
.editor-page #service-week-grid .edit-history-header h3{margin:0;font-size:16px}
.editor-page #service-week-grid .edit-history-hint{font-size:11px;color:var(--quiet)}
.editor-page #service-week-grid .edit-history-entry{padding:14px 0;border-bottom:1px solid var(--line)}
.editor-page #service-week-grid .edit-history-entry>p{font-size:11px;color:var(--quiet);margin:3px 0 8px}
.editor-page #service-week-grid .edit-history-entry summary{padding:7px 0;cursor:pointer;font-size:12px}
.editor-page #service-week-grid .edit-history-values{display:grid;grid-template-columns:1fr 1fr;gap:10px}
.editor-page #service-week-grid .edit-history-values>div{min-width:0;background:var(--cell);padding:9px;border-radius:4px}
.editor-page #service-week-grid .edit-history-values span{font-size:10px;color:var(--quiet)}
.editor-page #service-week-grid .edit-history-values pre{font:12px/1.5 system-ui;white-space:pre-wrap;overflow-wrap:anywhere;margin:5px 0}
@media(max-width:640px){.editor-page #service-week-grid .edit-history-values{grid-template-columns:1fr}.editor-page #service-week-grid .week-history-eye{width:30px;height:30px}}

/* Keep the status with row actions; column layouts retain details on the left. */
.editor-page #service-week-grid .week-action-controls{display:flex;flex-direction:column;align-items:center;gap:6px;min-width:0}
.editor-page #service-week-grid #combined-programme .week-action-controls,
.editor-page #service-week-grid.mobile-editor-navigation .week-action-controls{grid-column:2;grid-row:1;align-items:stretch}
.editor-page #service-week-grid .week-cell-actions[data-publication="draft"] .week-action-status{background:light-dark(#e2e8f0,#344155);color:light-dark(#41536c,#d3deed)}
.editor-page #service-week-grid .week-cell-actions[data-publication="published"] .week-action-status{background:light-dark(#dcefe3,#234936);color:light-dark(#24613c,#b9e6c9)}
.editor-page #service-week-grid .week-cell-actions[data-publication="changed"] .week-action-status{background:light-dark(#fff0ce,#55401f);color:light-dark(#805000,#f6d28e)}
.editor-page #service-week-grid:not(.mobile-editor-navigation) :is(#combined-talks,#combined-watchtower) :is([data-week-actions-heading],[data-week-actions-cell]){width:230px;min-width:230px}
.editor-page #service-week-grid:not(.mobile-editor-navigation) #combined-talks .talk-rows{min-width:2000px}
.editor-page #service-week-grid:not(.mobile-editor-navigation) #combined-watchtower .watchtower-rows{min-width:1300px}

/* Spreadsheet controls cover the complete cell, including taller metadata rows. */
.editor-page #service-week-grid:not(.mobile-editor-navigation) :is(#combined-talks,#combined-watchtower,#combined-school) tbody td:has(>label input:not([type=checkbox]),>label select,>label textarea){position:relative;height:1px;padding:0;vertical-align:middle}
.editor-page #service-week-grid:not(.mobile-editor-navigation) :is(#combined-talks,#combined-watchtower,#combined-school) tbody td>label:has(input:not([type=checkbox]),select,textarea){display:block;height:100%;min-height:58px;margin:0;padding:0}
.editor-page #service-week-grid:not(.mobile-editor-navigation) :is(#combined-talks,#combined-watchtower,#combined-school) tbody td>label :is(input:not([type=checkbox]),select,textarea){height:100%;min-height:58px;box-sizing:border-box}
.editor-page #service-week-grid:not(.mobile-editor-navigation) :is(#combined-talks,#combined-watchtower,#combined-school) tbody td>label .field-presence-anchor:not(.field-presence-compact){height:100%}
.editor-page #service-week-grid:not(.mobile-editor-navigation) :is(#combined-talks,#combined-watchtower,#combined-school) tbody td:has(>label input:not([type=checkbox]),>label select,>label textarea):focus-within{outline:2px solid light-dark(#4877b2,#9fbfe9);outline-offset:-2px}
.editor-page #service-week-grid:not(.mobile-editor-navigation) :is(#combined-talks,#combined-watchtower) :is(.talk-rows,.watchtower-rows) thead th[data-week-actions-heading]{width:230px;min-width:230px}
.editor-page #service-week-grid:not(.mobile-editor-navigation) :is(#combined-talks,#combined-watchtower) [data-week-actions-cell]{min-width:230px;padding:12px}
.editor-page #service-week-grid:not(.mobile-editor-navigation) #combined-school .school-day-toolbar{grid-template-columns:minmax(220px,1fr) 230px 260px}
/* Each pinned school-day bar belongs to its own group. */
.editor-page #service-week-grid:not(.mobile-editor-navigation) #combined-school .school-day-group{position:relative}

/* Match the breathing room in the school day action and publication areas. */
.editor-page #service-week-grid:not(.mobile-editor-navigation) #combined-school .school-day-toolbar :is(.week-action-controls,.week-publishing-info){padding:4px 12px;box-sizing:border-box}
.editor-page #service-week-grid:not(.mobile-editor-navigation) :is(#combined-talks,#combined-watchtower) :is(.talk-rows,.watchtower-rows) tbody td:is([data-week-actions-cell],[data-week-publication-cell]){padding:12px;vertical-align:middle}

/* Outline the complete labelled field in the Full programme editor. */
.editor-page #service-week-grid #combined-programme .templatepart label:has(input:not([type=checkbox]):not([type=radio]),select,textarea):focus-within{outline:2px solid light-dark(#4877b2,#9fbfe9);outline-offset:-2px;border-radius:3px}
.editor-page #service-week-grid #combined-programme .templatepart label :is(input:not([type=checkbox]):not([type=radio]),select,textarea):focus{outline:none;box-shadow:none}
.editor-page #service-week-grid #combined-programme .templatepart label.field-presence-label{position:relative;outline:2px solid var(--editor-colour);outline-offset:-2px;border-radius:3px}
.editor-page #service-week-grid #combined-programme .templatepart label.field-presence-label .field-presence-anchor{position:static}
.editor-page #service-week-grid #combined-programme .templatepart label.field-presence-label [data-collaboration-locked]{outline:none}
/* Leave a little breathing room above labels inside the field highlight. */
.editor-page #service-week-grid #combined-programme .templatepart label:has(input:not([type=checkbox]):not([type=radio]),select,textarea){padding-top:4px}
/* Meeting metadata and other fields outside parts keep a field-only outline. */
.editor-page #service-week-grid #combined-programme label:not(.templatepart label) :is(input,select,textarea):focus{outline:2px solid light-dark(#4877b2,#9fbfe9);outline-offset:-2px}
/* Let nested assignment labels reach their card edges, retaining text padding. */
.editor-page #service-week-grid #combined-programme .templatepart .typed-part>div:not(.typed-toolbar)>label{width:calc(100% + 18px);margin-left:-9px;margin-right:-9px;padding-left:9px;padding-right:9px;box-sizing:border-box}
/* Basic choices share the searchable dropdowns' menu treatment. */
select:not([multiple]):not([size]){appearance:none!important;background-image:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 24 24' fill='none' stroke='%238697ad' stroke-width='2'%3E%3Cpath d='m6 9 6 6 6-6'/%3E%3C/svg%3E")!important;background-repeat:no-repeat!important;background-position:right 8px center!important;padding-right:27px!important}
.simple-select-menu{position:fixed;inset:auto;margin:0;z-index:1100;padding:5px;border:1px solid var(--line);border-radius:7px;background:var(--paper);color:var(--ink);box-shadow:0 8px 24px light-dark(#24334726,#00000066);overflow-y:auto;overscroll-behavior:contain;font:12px/1.4 system-ui;box-sizing:border-box}
.simple-select-menu[hidden]{display:none}
.simple-select-menu button[role=option]{display:flex;justify-content:space-between;width:100%;min-height:34px;text-align:left;font:inherit;padding:8px;border:0;border-radius:4px;background:var(--paper);color:var(--ink);white-space:normal}
.simple-select-menu button[role=option][aria-selected=true]{background:light-dark(#e4edf8,#344c6b)}
.simple-select-menu button[data-current=true]::after{content:'✓';flex:none;margin-left:12px;color:var(--quiet)}
.simple-select-group{padding:7px 8px 4px;font-size:11px;font-weight:600;color:var(--quiet)}
@media(pointer:coarse){.simple-select-menu button[role=option]{min-height:42px}}

/* Confirmation toggles retain the compact focus ring used in coordination rows. */
.editor-page #service-week-grid #combined-programme input[type=checkbox]:focus-visible{outline:2px solid var(--teal);outline-offset:3px}
/* Toggle badges grow rightward from the control instead of clipping at the left edge. */
.editor-page #service-week-grid .field-presence-compact>.field-editor-presence{left:0;right:auto}

/* Keep dates and week actions visible at opposite edges of coordination tables. */
.editor-page #service-week-grid:not(.mobile-editor-navigation) :is(#combined-talks,#combined-watchtower) :is(.talk-rows,.watchtower-rows) tbody tr>th:first-child{position:sticky;left:0;z-index:12;background:var(--status-fill,var(--cell));box-shadow:3px 0 7px #0002}
.editor-page #service-week-grid:not(.mobile-editor-navigation) :is(#combined-talks,#combined-watchtower) :is(.talk-rows,.watchtower-rows) tbody [data-week-actions-cell]{position:sticky;right:0;z-index:12;background:var(--status-fill,var(--paper));box-shadow:-3px 0 7px #0002}
.editor-page #service-week-grid:not(.mobile-editor-navigation) :is(#combined-talks,#combined-watchtower) :is(.talk-rows,.watchtower-rows) thead th:first-child{position:sticky;left:0;z-index:2;background:var(--nav)}
.editor-page #service-week-grid:not(.mobile-editor-navigation) :is(#combined-talks,#combined-watchtower) :is(.talk-rows,.watchtower-rows) thead [data-week-actions-heading]{position:sticky;right:0;z-index:2;background:var(--nav)}
/* Keep the pinned Actions divider visible with collapsed table borders. */
.editor-page #service-week-grid:not(.mobile-editor-navigation) :is(#combined-talks,#combined-watchtower) :is(.talk-rows,.watchtower-rows) :is([data-week-actions-heading],[data-week-actions-cell]){border-left:1px solid var(--line);box-shadow:inset 1px 0 0 var(--line),-3px 0 7px #0002}
/* The Actions heading needs only a thin divider, without the body-cell shadow. */
.editor-page #service-week-grid:not(.mobile-editor-navigation) :is(#combined-talks,#combined-watchtower) :is(.talk-rows,.watchtower-rows) thead [data-week-actions-heading]{border-left:0;box-shadow:inset 1px 0 0 var(--line)}

/* Each day's assignment headings follow its conductor, then pin below its day bar. */
.editor-page #service-week-grid #combined-school thead[hidden]{display:none}
.editor-page #service-week-grid:not(.mobile-editor-navigation) #combined-school .school-assignment-headings{position:sticky;top:var(--school-day-heading-height,78px);z-index:19}
.editor-page #service-week-grid #combined-school .school-assignment-headings>th{padding:9px;background:light-dark(#34465d,#26364a);color:#edf2f8;font-size:12px;font-weight:500;box-shadow:inset 0 -1px 0 var(--line)}
.editor-page #service-week-grid #combined-school .school-assignment-headings[hidden]{display:none}
.editor-page #service-week-grid.mobile-editor-navigation #combined-school :is(colgroup,.school-assignment-headings){display:none!important}

/* Desktop navigation shares the mobile dock's button sizing and placement. */
.editor-page #service-week-grid>footer{display:none!important}
.editor-page #service-week-grid>.desktop-editor-dock{display:flex;flex-direction:column;align-items:center;justify-content:center;gap:4px;flex:none;padding:8px 12px max(8px,env(safe-area-inset-bottom,0px));background:var(--paper);border-top:1px solid var(--line);box-shadow:0 -3px 12px light-dark(#26354a12,#0003);z-index:60}
.editor-page #service-week-grid>.desktop-editor-dock[hidden]{display:none}
.editor-page #service-week-grid .desktop-editor-dock #persistence-status{position:static;flex:none;width:100%;min-width:0;padding:4px 0;border:0;text-align:center;overflow-wrap:anywhere}
.editor-page #service-week-grid .desktop-editor-dock .header-actions{display:flex;align-items:center;gap:8px;flex-wrap:nowrap}
.editor-page #service-week-grid .desktop-editor-dock .month-navigation{display:flex;align-items:center;gap:8px}
.editor-page #service-week-grid .desktop-editor-dock button{display:inline-flex;align-items:center;justify-content:center;min-height:44px;min-width:44px;padding:10px;border:1px solid var(--line);border-radius:8px;background:var(--cell);color:var(--ink)}
.editor-page #service-week-grid .desktop-editor-dock .month-navigation button{background:var(--nav);color:#fff;border-color:transparent}
.editor-page #service-week-grid .desktop-editor-dock button[hidden]{display:none}
.editor-page #service-week-grid .desktop-editor-dock svg{width:18px;height:18px}

.editor-page #service-week-grid:not(.mobile-editor-navigation) .programme-chrome .toolbar{justify-content:center}
.editor-page #service-week-grid:not(.mobile-editor-navigation) .programme-title{justify-content:center}
.editor-page #service-week-grid:not(.mobile-editor-navigation) .view-switch{justify-content:center}

.editor-page #service-week-grid>.editor-title-bar{flex:none;background:var(--paper);color:var(--ink);line-height:1.5}
.editor-page #service-week-grid>.editor-title-bar h1{margin:0;font-size:18px;font-weight:600}

/* Keep view navigation beside the title, using a selector before buttons wrap. */
.editor-page #service-week-grid>.editor-title-bar{display:flex;align-items:center;justify-content:space-between;gap:16px;text-align:left}
.editor-page #service-week-grid>.editor-title-bar h1{flex:none}
.editor-page #service-week-grid .editor-view-navigation{position:relative;display:flex;justify-content:flex-end;align-items:center;flex:1;min-width:0}
.editor-page #service-week-grid .editor-view-navigation .view-switch{width:max-content;flex:none;flex-wrap:nowrap;gap:7px;padding:0;justify-content:flex-end}
.editor-page #service-week-grid .editor-view-navigation .view-switch button{flex:none;white-space:nowrap}
.editor-page #service-week-grid .editor-views-compact .view-switch{position:absolute;right:0;visibility:hidden;pointer-events:none}
.editor-page #service-week-grid .editor-title-view-selector{width:auto;max-width:100%;min-width:0;min-height:40px;margin:0;padding:7px 30px 7px 10px;font-size:13px;background:var(--cell);border:1px solid var(--line);border-radius:6px}
.editor-page #service-week-grid.mobile-editor-navigation .editor-view-navigation{display:none}

/* Use the mobile navigation dock at every editor width. */
.editor-page #service-week-grid .programme-chrome :is(.view-switch,.header-actions){display:none!important}
.editor-page #service-week-grid>.mobile-editor-view-dock{flex:none}
.editor-page #service-week-grid.editor-dock-navigation .mobile-editor-view-dock{position:static}
.editor-page #service-week-grid .mobile-editor-view-dock #persistence-status{position:static;padding:4px 12px 8px;border:0;text-align:center;overflow-wrap:anywhere}
.editor-page #service-week-grid>.editor-title-bar{justify-content:center;text-align:center}

/* Compact desktop header and centred footer contents, matching Programme width. */
.editor-page #service-week-grid .programme-chrome .toolbar{display:none}
.editor-page #service-week-grid:not(.mobile-editor-navigation)>.editor-title-bar{justify-content:space-between;text-align:left}
.editor-page #service-week-grid:not(.mobile-editor-navigation)>.editor-title-bar .programme-title{justify-content:flex-end}
.editor-page #service-week-grid.mobile-editor-navigation>.editor-title-bar .programme-title{display:none}
.editor-page #service-week-grid:not(.mobile-editor-navigation) .mobile-editor-view-dock>:is(.mobile-editor-view-label,.mobile-week-nav,#persistence-status){width:100%;max-width:760px;margin-inline:auto;box-sizing:border-box}

.editor-page #service-week-grid>.editor-title-bar{padding-inline:0}
.editor-page #service-week-grid .editor-title-inner{display:flex;align-items:center;justify-content:space-between;gap:16px;width:100%;max-width:760px;margin-inline:auto;padding-inline:12px;box-sizing:border-box}
.editor-page #service-week-grid.mobile-editor-navigation .editor-title-inner{justify-content:center}

/* Brief, animated status messages above the two navigation rows. */
.editor-page #persistence-status,
.editor-page #service-week-grid .mobile-editor-view-dock #persistence-status{max-height:0;min-height:0;overflow:hidden;padding-block:0;opacity:0;transform:translateY(-8px);transition:max-height .25s ease,padding .25s ease,opacity .2s ease,transform .25s ease}
.editor-page #persistence-status.status-visible,
.editor-page #service-week-grid .mobile-editor-view-dock #persistence-status.status-visible{max-height:180px;padding-block:6px;opacity:1;transform:translateY(0)}
@media(prefers-reduced-motion:reduce){.editor-page #service-week-grid .mobile-editor-view-dock #persistence-status{transition:none;transform:none}}

/* Use view buttons when they fit alongside the footer actions. */
.editor-page #service-week-grid .dock-view-switch-host{position:relative;display:flex;align-items:center;flex:1;min-width:0}
.editor-page #service-week-grid .dock-view-switch-host .view-switch{display:flex;width:max-content;flex:none;flex-wrap:nowrap;justify-content:flex-start;gap:6px;padding:0}
.editor-page #service-week-grid .dock-view-switch-host .view-switch button{flex:none;white-space:nowrap;min-height:44px}
.editor-page #service-week-grid .dock-views-compact .view-switch{position:absolute;right:0;visibility:hidden;pointer-events:none}
.editor-page #service-week-grid .dock-view-switch-host select[data-programme-view-selector]{width:100%;margin:0}

/* Desktop footer refinements. Keep the preview caption available to legacy view hooks. */
.editor-page #service-week-grid:not(.mobile-editor-navigation) .view-switch>.quiet{display:none!important}
.editor-page #service-week-grid:not(.mobile-editor-navigation) .dock-view-switch-host:not(.dock-views-compact) .view-switch{width:100%}
.editor-page #service-week-grid:not(.mobile-editor-navigation) .dock-view-switch-host:not(.dock-views-compact) .view-switch button{flex:1}
.editor-page #service-week-grid .dock-view-switch-host.measuring-dock-views .view-switch{width:max-content!important;flex:none!important}
.editor-page #service-week-grid .dock-view-switch-host.measuring-dock-views .view-switch button{flex:none!important}
.editor-page #service-week-grid:not(.mobile-editor-navigation) .mobile-editor-view-dock .mobile-week-nav{border-top:0}
.editor-page #service-week-grid:not(.mobile-editor-navigation) .mobile-editor-view-dock .mobile-editor-view-label{border-top:1px solid var(--line)}
.editor-page #service-week-grid:not(.mobile-editor-navigation) #sw-month{text-align:right;text-align-last:right}

/* Message colours communicate the outcome independently of light/dark appearance. */
.editor-page #service-week-grid #persistence-status[data-tone="positive"]{background:light-dark(#dcefe3,#234936);color:light-dark(#24613c,#b9e6c9)}
.editor-page #service-week-grid #persistence-status[data-tone="negative"]{background:light-dark(#fde5e3,#532d31);color:light-dark(#a52324,#ffc3c2)}
.editor-page #service-week-grid #persistence-status[data-tone="neutral"]{background:light-dark(#e7e9ed,#353c47);color:light-dark(#4c5765,#d4dae3)}
.editor-page #service-week-grid #persistence-status[data-tone="warning"]{background:light-dark(#fff0c2,#594719);color:light-dark(#765600,#ffe09a)}
.editor-page #service-week-grid .publishing-info-toggle{font-size:11px;min-height:30px;padding:4px 8px;flex:none}
.editor-page #service-week-grid .publishing-info-toggle[hidden]{display:none!important}
.editor-page #service-week-grid.publishing-info-hidden #combined-programme .week-publishing-info,
.editor-page #service-week-grid.publishing-info-hidden.mobile-editor-navigation .week-publishing-info{display:none}
.editor-page #service-week-grid.publishing-info-hidden #combined-programme .week-cell-actions,
.editor-page #service-week-grid.publishing-info-hidden.mobile-editor-navigation .week-cell-actions{display:flex;justify-content:center}
.editor-page #service-week-grid.publishing-info-hidden #combined-programme .week-action-controls,
.editor-page #service-week-grid.publishing-info-hidden.mobile-editor-navigation .week-action-controls{width:100%;align-items:stretch}
.editor-page #service-week-grid.publishing-info-hidden #combined-programme .week-action-buttons,
.editor-page #service-week-grid.publishing-info-hidden.mobile-editor-navigation .week-action-buttons{display:flex;flex-direction:row;justify-content:center;flex-wrap:wrap;min-width:0}

/* Full-width footer surfaces with Programme-width controls. */
.editor-page #service-week-grid.editor-dock-navigation .mobile-editor-view-dock>:is(.mobile-week-nav,.mobile-editor-view-label,#persistence-status){width:100%;max-width:none;margin-inline:0;box-sizing:border-box}
.editor-page #service-week-grid.editor-dock-navigation .mobile-editor-view-dock>.mobile-week-nav,
.editor-page #service-week-grid.editor-dock-navigation .mobile-editor-view-dock>.mobile-editor-view-label{display:block;padding:0}
.editor-page #service-week-grid .editor-dock-row-inner{width:100%;max-width:760px;margin-inline:auto;padding:8px 12px;box-sizing:border-box}
.editor-page #service-week-grid .mobile-week-nav>.editor-dock-row-inner{display:grid;grid-template-columns:44px minmax(0,1fr) 44px 44px 44px;gap:8px}
.editor-page #service-week-grid .mobile-editor-view-label>.editor-dock-row-inner{display:flex;align-items:center;gap:6px;min-width:0}
.editor-page #service-week-grid .mobile-editor-view-label>.editor-dock-row-inner>button{display:flex;align-items:center;justify-content:center;flex:0 0 44px;width:44px;min-height:44px;padding:10px;border:1px solid var(--line);border-radius:8px;background:var(--cell);color:var(--ink)}
.editor-page #service-week-grid .mobile-editor-view-label>.editor-dock-row-inner>button:disabled{opacity:.4}
.editor-page #service-week-grid .mobile-editor-view-label>.editor-dock-row-inner>button[hidden]{display:none!important}
.editor-page #service-week-grid .mobile-week-nav.mobile-editor-view-only>.editor-dock-row-inner>button:not(.mobile-editor-programme-button){display:none}
.editor-page #service-week-grid .mobile-week-nav.mobile-editor-view-only>.editor-dock-row-inner>.mobile-editor-programme-button{grid-column:4}

/* Icon controls share the date-navigation row at every width. */
.editor-page #service-week-grid .mobile-week-nav>.editor-dock-row-inner{display:flex;align-items:center}
.editor-page #service-week-grid .mobile-week-nav>.editor-dock-row-inner>button{flex:none;width:44px;min-width:0}
.editor-page #service-week-grid .mobile-week-nav>.editor-dock-row-inner>.mobile-editor-this-week{flex:1;width:auto;min-width:0;white-space:nowrap}
.editor-page #service-week-grid .mobile-week-nav>.editor-dock-row-inner>.publishing-info-toggle{padding:10px;min-height:44px}
.editor-page #service-week-grid .mobile-week-nav .publishing-info-toggle[aria-pressed="false"]{opacity:.65}
.editor-page #service-week-grid .mobile-week-nav .editor-appearance summary{background:var(--nav);color:#fff;border:0;border-radius:5px}
.editor-page #service-week-grid .editor-appearance .public-appearance-menu{z-index:80;text-align:left}
.editor-page #service-week-grid .editor-appearance .public-appearance-menu button{width:100%;justify-content:flex-start;padding:8px 10px;background:var(--cell);color:var(--ink)}
.editor-page #service-week-grid .editor-appearance .public-appearance-menu button[aria-pressed="true"]{background:var(--nav);color:#fff}
.editor-page #service-week-grid .mobile-week-nav.mobile-editor-view-only>.editor-dock-row-inner{justify-content:flex-end}
@media(max-width:640px){
 .editor-page #service-week-grid .mobile-week-nav>.editor-dock-row-inner{gap:6px}
 .editor-page #service-week-grid .mobile-week-nav>.editor-dock-row-inner>button:not(.mobile-editor-this-week),
 .editor-page #service-week-grid .mobile-week-nav .editor-appearance summary{width:40px;height:40px;min-height:40px;padding:8px}
}

/* Programme is a compact icon in the button navigator; its dropdown label stays text. */
.editor-page #service-week-grid .dock-view-switch-host .view-switch button[data-view="viewer"]{flex:0 0 44px!important;width:44px;min-width:44px;padding:10px}
.editor-page #service-week-grid.editor-dock-navigation .mobile-editor-view-dock>.mobile-editor-view-label{border-top:1px solid color-mix(in srgb,var(--line) 45%,transparent)}

/* Appearance and publishing controls sit alongside the view selector. */
.editor-page #service-week-grid .mobile-editor-view-label .editor-appearance summary{background:var(--cell);color:var(--ink);border:1px solid var(--line);border-radius:8px}
.editor-page #service-week-grid .mobile-editor-view-label .publishing-info-toggle[aria-pressed="false"]{opacity:.65}
@media(max-width:640px){
 .editor-page #service-week-grid .mobile-editor-view-label>.editor-dock-row-inner{gap:4px}
 .editor-page #service-week-grid .mobile-editor-view-label>.editor-dock-row-inner>button{flex-basis:36px;width:36px;min-height:40px;padding:8px}
 .editor-page #service-week-grid .mobile-editor-view-label .editor-appearance summary{width:36px;height:40px}
}

/* People availability shares one person list and one detail workspace. */
.editor-page #service-week-grid>#combined-availability{flex:1;min-height:0;display:grid;grid-template-columns:260px minmax(0,1fr);overflow:hidden;background:var(--paper)}
.editor-page #service-week-grid>#combined-availability[hidden]{display:none}
.editor-page #service-week-grid .availability-people{min-height:0;display:flex;flex-direction:column;border-right:1px solid var(--line);padding:16px 12px;gap:12px}
.editor-page #service-week-grid .availability-people h2,.editor-page #service-week-grid .availability-detail h2{font-size:18px;margin:0}
.editor-page #service-week-grid .availability-person-list{flex:1;min-height:0;overflow:auto;display:flex;flex-direction:column;gap:4px}
.editor-page #service-week-grid .availability-person-list button{flex:none;text-align:left;justify-content:flex-start;padding:10px 12px;min-height:42px}
.editor-page #service-week-grid .availability-person-list button[aria-pressed="true"]{background:var(--nav);color:#fff;border-color:var(--nav)}
.editor-page #service-week-grid .availability-person-select{display:none}
.editor-page #service-week-grid .availability-detail{min-width:0;overflow:auto;padding:20px}
.editor-page #service-week-grid .availability-empty{padding:32px 12px;text-align:center;color:var(--quiet)}
.editor-page #service-week-grid .availability-filters{display:flex;align-items:flex-end;gap:12px;flex-wrap:wrap;margin:20px 0}
.editor-page #service-week-grid .availability-filters label{margin:0;min-width:120px}
.editor-page #service-week-grid .availability-filters .availability-past{display:flex;align-items:center;gap:8px;min-height:40px}
.editor-page #service-week-grid .availability-past input{width:32px;min-width:32px;margin:0;appearance:auto;accent-color:var(--teal)}
.editor-page #service-week-grid .availability-records{min-width:0;width:100%;table-layout:auto}
.editor-page #service-week-grid .availability-records :is(th,td){padding:12px;text-align:left;border-bottom:1px solid var(--line);vertical-align:top}
.editor-page #service-week-grid .availability-records th{background:var(--nav);color:white;font-size:12px}
.editor-page #service-week-grid .availability-records td:nth-child(-n+2){white-space:nowrap}
.editor-page #service-week-grid .availability-records td:last-child{white-space:nowrap}
.editor-page #service-week-grid .availability-records td:last-child button+button{margin-left:6px}
.editor-page #service-week-grid .availability-past-record{opacity:.6}
.availability-record-dialog label{display:block;margin:14px 0;color:var(--quiet);font-size:13px}
.availability-record-dialog :is(input,textarea){display:block;width:100%;min-height:42px;margin-top:6px;padding:9px 10px;border:1px solid var(--line);border-radius:5px;background:var(--cell);color:var(--ink)}
.availability-record-dialog textarea{min-height:85px;resize:vertical}
.availability-form-actions{display:flex;justify-content:flex-end;gap:8px;margin-top:20px}
.availability-confirm ul{padding-left:20px;max-height:35dvh;overflow:auto}
.away-chip{display:inline-flex;align-items:center;flex:none;padding:2px 7px;border-radius:10px;background:light-dark(#fff0c2,#594719);color:light-dark(#765600,#ffe09a);font:500 10px/1.5 system-ui;white-space:nowrap}
.editor-page #service-week-grid .person-dropdown-list button .away-chip{margin-left:auto}
.editor-page #service-week-grid .availability-field{display:flex;align-items:center;gap:6px;min-width:0;width:100%}
.editor-page #service-week-grid .availability-field>input,.editor-page #service-week-grid .availability-field>.field-presence-anchor{flex:1;min-width:0}
.editor-page #service-week-grid .availability-field>.away-chip{margin-right:6px}
@media(max-width:640px){
 .editor-page #service-week-grid>#combined-availability{display:flex;flex-direction:column}
 .editor-page #service-week-grid .availability-people{display:none}
 .editor-page #service-week-grid .availability-person-select{display:block;flex:none;width:calc(100% - 24px);margin:12px;min-height:42px;font-size:16px}
 .editor-page #service-week-grid .availability-detail{flex:1;min-height:0;padding:12px}
 .editor-page #service-week-grid .availability-filters{gap:8px}
 .editor-page #service-week-grid .availability-records{display:block;overflow-x:auto}
 .editor-page #service-week-grid .availability-records :is(th,td){padding:10px 8px}
}

.editor-page #service-week-grid .availability-past input[role="switch"]{appearance:none;width:34px;height:20px;padding:0;border:0;border-radius:12px;background:var(--line);position:relative;cursor:pointer}
.editor-page #service-week-grid .availability-past input[role="switch"]::before{content:"";position:absolute;left:3px;top:3px;width:14px;height:14px;border-radius:50%;background:var(--paper);transition:transform .15s}
.editor-page #service-week-grid .availability-past input[role="switch"]:checked{background:var(--teal)}
.editor-page #service-week-grid .availability-past input[role="switch"]:checked::before{transform:translateX(14px)}
.editor-page #service-week-grid .mobile-week-nav.mobile-editor-view-only{display:none!important}

/* Inline away records with date chips and spreadsheet-style comments. */
.editor-page #service-week-grid .person-dropdown-list button .away-chip{margin-left:8px}
.editor-page #service-week-grid .availability-records{display:table;table-layout:fixed;overflow:visible}
.editor-page #service-week-grid .availability-records th:first-child{width:46%}
.editor-page #service-week-grid .availability-records th:last-child{width:66px;text-align:center}
.editor-page #service-week-grid .availability-records td{white-space:normal;padding:0;vertical-align:top;border-right:1px solid var(--line)}
.editor-page #service-week-grid .availability-records .availability-date-summary{display:block;min-height:64px;width:100%;padding:12px;text-align:left;border:0;border-radius:0;background:transparent;color:var(--ink);line-height:2.2;white-space:normal}
.availability-date-chip{display:inline-block;padding:2px 7px;margin:2px 0;border-radius:6px;background:light-dark(#e4eaf3,#34465f);color:light-dark(#304c78,#e6eefc);font-size:12px;line-height:1.6;white-space:nowrap}
.availability-date-caret{margin-left:7px;color:var(--quiet)}
.editor-page #service-week-grid .availability-comment-cell textarea{display:block;width:100%;min-height:64px;max-height:360px;resize:vertical;white-space:pre-wrap;overflow-wrap:anywhere;padding:12px;border:0;border-radius:0;background:transparent;color:var(--ink);font:13px/1.5 system-ui;margin:0;box-sizing:border-box}
.editor-page #service-week-grid .availability-records :is(.availability-date-summary,.availability-comment-cell textarea):focus-visible{outline:2px solid var(--teal);outline-offset:-2px}
.editor-page #service-week-grid .availability-records .availability-delete-cell{text-align:center;padding:8px 4px}
.editor-page #service-week-grid .availability-delete-cell button{min-height:32px;width:32px;padding:0;font-size:21px;background:transparent;border:0}
.availability-range-picker{position:fixed;inset:auto;margin:0;max-height:calc(100dvh - 24px);overflow:auto;padding:16px;border:1px solid var(--line);border-radius:12px;background:var(--paper);color:var(--ink);box-shadow:0 12px 40px #0004;font:13px/1.5 system-ui;box-sizing:border-box}
.availability-range-picker h2{font-size:18px;margin:0 0 12px}
.availability-range-picker .quiet{font-size:12px;color:var(--quiet);margin:0;text-align:center}
.availability-range-fields{display:flex;gap:12px}
.availability-range-fields label{flex:1;min-width:0;color:var(--quiet);font-size:12px}
.availability-range-fields input{display:block;width:100%;min-width:0;margin:5px 0 10px;padding:9px;border:1px solid var(--line);border-radius:7px;background:var(--cell);color:var(--ink)}
.availability-calendar-controls{display:flex;justify-content:space-between;align-items:center;gap:8px;margin:8px 0 12px}
.availability-calendar-controls button{width:36px;min-height:36px;padding:0;font-size:22px;flex:none}
.availability-calendars{display:grid;grid-template-columns:1fr 1fr;gap:24px}
.availability-calendar-month h3{font-size:14px;text-align:center;margin:0 0 12px}
.availability-calendar-grid{display:grid;grid-template-columns:repeat(7,minmax(0,1fr));gap:3px}
.availability-calendar-grid .availability-weekday{text-align:center;color:var(--quiet);font-size:11px;padding-bottom:4px}
.availability-calendar-grid button{min-width:0;min-height:34px;padding:0;border:0;border-radius:50%;background:transparent;color:var(--ink);font-size:12px}
.availability-calendar-grid button:hover{box-shadow:inset 0 0 0 1px var(--ink)}
.availability-calendar-grid .in-range{background:var(--cell);border-radius:5px}
.availability-calendar-grid :is(.range-start,.range-end){background:var(--nav);color:#fff}
.availability-range-picker .availability-form-actions{justify-content:space-between;gap:8px}
@media(max-width:640px){
 .editor-page #service-week-grid .availability-records th:first-child{width:48%}
 .editor-page #service-week-grid .availability-records th:last-child{width:45px;padding-inline:2px;font-size:10px}
 .editor-page #service-week-grid .availability-records .availability-date-summary{padding:8px;font-size:12px}
 .editor-page #service-week-grid .availability-comment-cell textarea{padding:8px}
 .availability-date-chip{font-size:11px;padding:2px 5px}
 .availability-range-picker{padding:12px}
 .availability-calendars{grid-template-columns:1fr}
 .availability-calendar-month+ .availability-calendar-month{display:none}
 .availability-calendar-grid button{min-height:38px}
 .availability-range-picker .availability-form-actions button{padding:8px;font-size:12px}
}

/* A slim left-side thumb keeps the people list visually quiet. */
.editor-page #service-week-grid .availability-person-list{direction:rtl;scrollbar-width:thin;scrollbar-color:color-mix(in srgb,var(--quiet) 45%,transparent) transparent;padding-left:6px}
.editor-page #service-week-grid .availability-person-list>*{direction:ltr;flex-shrink:0}
.editor-page #service-week-grid .availability-person-list::-webkit-scrollbar{width:6px;background:transparent}
.editor-page #service-week-grid .availability-person-list::-webkit-scrollbar-track{background:transparent}
.editor-page #service-week-grid .availability-person-list::-webkit-scrollbar-thumb{background:color-mix(in srgb,var(--quiet) 45%,transparent);border-radius:6px}
.editor-page #service-week-grid .availability-person-list .availability-old-person{color:var(--quiet);opacity:.7}
.editor-page #service-week-grid .availability-people-filters{display:flex;flex-direction:column;gap:10px;flex:none}
.editor-page #service-week-grid .availability-people-filters[hidden]{display:none}
.editor-page #service-week-grid .availability-people-filters label{margin:0}
.editor-page #service-week-grid .availability-old-toggle{display:flex;align-items:center;gap:8px}
.editor-page #service-week-grid .availability-old-toggle input[role="switch"]{appearance:none;position:relative;flex:none;width:34px;min-width:34px;height:20px;padding:0;margin:0;border:0;border-radius:12px;background:var(--line);cursor:pointer}
.editor-page #service-week-grid .availability-old-toggle input::before{content:"";position:absolute;left:3px;top:3px;width:14px;height:14px;border-radius:50%;background:var(--paper);transition:transform .15s}
.editor-page #service-week-grid .availability-old-toggle input:checked{background:var(--teal)}
.editor-page #service-week-grid .availability-old-toggle input:checked::before{transform:translateX(14px)}
@media(max-width:640px){
 .editor-page #service-week-grid .availability-people{display:flex;flex:none;border:0;padding:12px 12px 0}
 .editor-page #service-week-grid .availability-people>:is(h2,input,.availability-person-list){display:none}
 .editor-page #service-week-grid .availability-people-filters{flex-direction:row;align-items:center;justify-content:space-between;gap:8px}
 .editor-page #service-week-grid .availability-people-filters label{flex:1;min-width:0}
}

.editor-page #service-week-grid .availability-records tr>:first-child{border-left:1px solid var(--line)}

.account-identity{margin:22px 0}
.account-identity .account-name{font-size:18px;font-weight:600;margin:0 0 4px}
.account-identity .quiet{margin:0;overflow-wrap:anywhere}
.account-availability{margin:24px 0;padding-top:18px;border-top:1px solid var(--line)}
.account-availability h2{margin:0 0 12px}

/* One footer bar: equal outer padding and spacing between navigation rows. */
.editor-page #service-week-grid.editor-dock-navigation .mobile-editor-view-dock>.mobile-editor-view-label{border-top:0}
.editor-page #service-week-grid .mobile-editor-view-dock>.mobile-week-nav>.editor-dock-row-inner{padding-bottom:0}

/* Personal assignments are available only to a signed-in linked person. */
.public-assignments-active #calendar-open{display:none}
.public-assignments-active .week-buttons{grid-template-columns:44px minmax(0,1fr) repeat(3,44px)}
.section-tabs button{min-width:0}
.personal-assignments-toolbar{padding:12px;border-bottom:1px solid var(--line)}
.personal-assignments-toolbar label{display:flex;align-items:center;gap:9px;font-size:13px;cursor:pointer}
.personal-assignments-toolbar input{appearance:none;position:relative;flex:none;width:34px;height:20px;margin:0;border:0;border-radius:12px;background:var(--line);cursor:pointer}
.personal-assignments-toolbar input::before{content:"";position:absolute;left:3px;top:3px;width:14px;height:14px;border-radius:50%;background:var(--paper);transition:transform .15s}
.personal-assignments-toolbar input:checked{background:var(--teal)}
.personal-assignments-toolbar input:checked::before{transform:translateX(14px)}
.personal-assignment-meeting>header{position:sticky;top:var(--programme-top-height,110px);z-index:20;background:var(--theme-secondary,#3B4A5C);color:#fff;padding:10px 12px}
.personal-assignment-meeting>header h3{font-size:14px;margin:0 0 3px;font-weight:600}
.personal-assignment-meeting>header p{margin:0;font-size:12px;opacity:.9}
.personal-assignment-meeting>header p{overflow-wrap:anywhere}
.personal-assignment.programme-part{margin:0;padding:0;border:0}
.past-assignment .personal-assignment{opacity:.65}
@media(max-width:400px){.section-tabs:has([data-section="Assignments"]) button{font-size:11px;padding-inline:4px}}

.personal-assignment dd>strong{font-weight:600}
.personal-assignment-part,.personal-assignment-detail{margin:3px 0 0;font-size:12px}

.programme-part dt.personal-assignment-meeting-cell{flex-direction:column;align-items:flex-end;justify-content:center;gap:2px}
.personal-assignment-meeting-meta{font-size:12px;font-weight:400;line-height:1.4}

.personal-assignment-meeting>header h3{display:flex;align-items:center;justify-content:space-between;gap:8px;margin-bottom:0}
.assignment-this-week{flex:none;border-radius:12px;padding:2px 8px;background:#fff;color:#284b77;font-size:11px;font-weight:600}
.personal-assignment-meeting>header.current-assignment-week{box-shadow:inset 4px 0 #8db9ef}
.assignment-week-empty{padding:16px 12px;color:var(--quiet);margin:0}
.assignment-scroll-space{height:max(0px,calc(100dvh - var(--programme-top-height,110px) - var(--programme-bottom-height,110px) - 70px))}
@media(max-width:380px){.public-assignments-active .week-buttons{grid-template-columns:40px minmax(0,1fr) repeat(3,40px)}}

.personal-assignment-meeting>header.current-assignment-week{background:light-dark(#315e94,#284f7d)}
.personal-assignment-meeting>header.upcoming-assignment-week{background:light-dark(#586e8b,#3c4f69)}

.editor-page #service-week-grid .editor-programme-eye{flex:0 0 40px;width:40px;min-width:40px;min-height:40px;padding:8px}
.editor-page #service-week-grid.mobile-editor-navigation .editor-programme-eye{flex-basis:36px;width:36px;min-width:36px}

/* The editor stays hidden until its initial saved data and layout are ready. */
.editor-page #app-loading{position:fixed;inset:0;z-index:10000;display:grid;place-items:center;padding:28px;background:var(--paper);color:var(--ink)}
.editor-page:not(.app-booting) #app-loading{display:none}
.editor-loading-inner{width:min(100%,360px);text-align:center}
.editor-loading-mark{display:grid;place-items:center;width:64px;height:64px;border-radius:14px;margin:0 auto 22px;background:var(--nav);color:#fff;font-size:19px;font-weight:700;letter-spacing:2px}
.editor-loading-inner h1{margin:0 0 12px;font-size:22px}
.editor-loading-inner p{min-height:42px;margin:0 0 12px;font-size:13px;color:var(--quiet)}
.editor-loading-progress{display:flex;align-items:center;gap:12px}
.editor-loading-progress progress{appearance:none;width:100%;height:7px;border:0;border-radius:8px;overflow:hidden;background:var(--cell);accent-color:var(--teal)}
.editor-loading-progress progress::-webkit-progress-bar{background:var(--cell);border-radius:8px}
.editor-loading-progress progress::-webkit-progress-value{background:var(--teal);border-radius:8px;transition:width .2s ease}
.editor-loading-progress progress::-moz-progress-bar{background:var(--teal);border-radius:8px}
.editor-loading-progress span{min-width:34px;font-size:12px;font-variant-numeric:tabular-nums;color:var(--quiet)}
.editor-loading-inner button{margin-top:20px}
.loading-failed .editor-loading-progress{display:none}
@media(prefers-reduced-motion:reduce){.editor-loading-progress progress::-webkit-progress-value{transition:none}}

.editor-loading-inner button[hidden]{display:none}

/* Programme uses the same initial loading screen as the editor. */
#app-loading[data-loading-kind="programme"]{position:fixed;inset:0;z-index:10000;display:grid;place-items:center;padding:28px;background:var(--paper);color:var(--ink)}
body:not(.app-booting) #app-loading[data-loading-kind="programme"]{display:none}
body.app-booting #public-programme{visibility:hidden}
.public-loading-progress{width:min(100%,320px);margin:40px auto;padding:12px;text-align:center;color:var(--quiet)}
.public-loading-progress progress{width:100%;accent-color:var(--teal);height:7px}
.public-loading-progress p{font-size:13px}

/* Programme headings align consistently without changing the detail labels. */
.public-programme :is(h3,h4,h5){text-align:center}
.personal-assignment-meeting>header h3{justify-content:center;flex-wrap:wrap}

/* Share sits alongside the other Programme navigation tools. */
.public-programme .week-buttons{grid-template-columns:44px minmax(0,1fr) repeat(5,44px)}
.public-assignments-active .week-buttons{grid-template-columns:44px minmax(0,1fr) repeat(4,44px)}
.programme-share-feedback{text-align:center;margin:0 0 8px;font-size:12px;color:light-dark(#256541,#a3d6b7)}
.programme-share-feedback:empty{display:none}
@media(max-width:480px){
 .public-programme .week-buttons{grid-template-columns:36px minmax(0,1fr) repeat(5,36px);gap:4px}
 .public-assignments-active .week-buttons{grid-template-columns:36px minmax(0,1fr) repeat(4,36px)}
 .public-programme .week-buttons>button:not(#this-week),.public-programme .week-buttons>.account-entry,.public-programme .week-buttons .public-appearance summary{width:36px;padding:6px}
 .public-programme .week-buttons #this-week{padding-inline:4px;font-size:12px}
}

/* A calm, centred sign-in card, with room to scroll on short screens. */
.login-page{background:var(--theme-outside,var(--cell))}
.login-page .app-shell{display:grid;place-items:center;min-height:100dvh;max-width:none;padding:24px 16px}
.login-page .login-card{width:100%;max-width:420px;margin:0;padding:32px;background:var(--paper);border:1px solid var(--line);border-radius:16px;box-shadow:0 12px 40px light-dark(#26354a12,#0005)}
.login-card-heading{text-align:center}
.login-brand{display:grid;place-items:center;width:54px;height:54px;margin:0 auto 14px;border-radius:13px;background:var(--nav);color:#fff;font-size:17px;font-weight:700;letter-spacing:2px}
.login-app-name{margin:0 0 4px;color:var(--quiet);font-size:12px;font-weight:600;letter-spacing:.6px}
.login-card h1{margin:0 0 8px;font-size:26px;line-height:1.3}
.login-card-heading>.quiet{margin:0;line-height:1.6}
.login-page .login-card form{margin:26px 0 20px}
.login-page .login-card label{margin:0 0 16px;font-size:13px;font-weight:500}
.login-page .login-card input{margin-top:6px;padding:12px;border-radius:7px;font-weight:400;background:var(--paper)}
.login-card input::placeholder{color:var(--quiet);opacity:.75}
.login-card form>.primary{width:100%;margin-top:4px;min-height:46px;border-radius:7px;font-weight:600}
.login-card .login-error{padding:10px 12px;border-radius:7px;background:light-dark(#fce9e7,#422926);font-size:13px}
.login-help{text-align:center;line-height:1.7;margin:0 0 20px}
.login-page .login-card .back-link{display:block;text-align:center;margin:0;padding-top:18px;border-top:1px solid var(--line);font-size:13px}
@media(max-width:420px){.login-page .login-card{padding:28px 22px;border-radius:12px}}

/* Editors can open their account without leaving Programme through the editor. */
.public-programme.has-programme-account .week-buttons{grid-template-columns:44px minmax(0,1fr) repeat(6,44px)}
.public-programme.has-programme-account.public-assignments-active .week-buttons{grid-template-columns:44px minmax(0,1fr) repeat(5,44px)}
@media(max-width:480px){
 .public-programme.has-programme-account .week-buttons{grid-template-columns:36px minmax(0,1fr) repeat(6,36px)}
 .public-programme.has-programme-account.public-assignments-active .week-buttons{grid-template-columns:36px minmax(0,1fr) repeat(5,36px)}
}
@media(max-width:360px){
 .public-programme.has-programme-account .week-buttons{grid-template-columns:32px minmax(0,1fr) repeat(6,32px);gap:3px}
 .public-programme.has-programme-account.public-assignments-active .week-buttons{grid-template-columns:32px minmax(0,1fr) repeat(5,32px)}
 .public-programme.has-programme-account .week-buttons>button:not(#this-week),.public-programme.has-programme-account .week-buttons>.account-entry,.public-programme.has-programme-account .week-buttons .public-appearance summary{width:32px;padding:5px}
 .public-programme.has-programme-account .week-buttons #this-week{white-space:normal;font-size:11px;line-height:1.2;padding-inline:2px}
}

/* Account follows the same card and form language as Sign in. */
.account-page .account-card{max-width:460px}
.account-card .account-identity{text-align:center;margin:22px 0 24px;padding:16px 12px;background:var(--cell);border-radius:9px}
.account-card .account-name{font-size:17px;overflow-wrap:anywhere}
.account-card .account-availability{margin:0;padding:20px 0;border-top:1px solid var(--line)}
.account-card .account-availability h2{font-size:14px;margin-bottom:12px}
.account-availability-button{display:flex;width:100%;justify-content:space-between;font-size:13px;border-radius:7px;padding:11px 12px}
.account-card .account-password{padding:0;border-block:1px solid var(--line)}
.account-password summary{display:flex;align-items:center;justify-content:space-between;padding:18px 0;font-size:14px;font-weight:600;cursor:pointer;list-style:none}
.account-password summary::-webkit-details-marker{display:none}
.account-password summary span{transition:transform .15s ease}
.account-password[open] summary span{transform:rotate(180deg)}
.account-password summary:focus-visible{outline:2px solid var(--teal);outline-offset:4px;border-radius:3px}
.account-page .account-card #change-password{margin:0 0 18px}
.account-card #password-status{font-size:12px;margin:12px 0 0;color:var(--quiet);overflow-wrap:anywhere}
.account-card #password-status:empty{display:none}
.account-page .account-card .account-sign-out{margin:20px 0}
.account-sign-out button{width:100%;min-height:44px;background:transparent;border-radius:7px;color:light-dark(#a53635,#edaaa6)}
.account-sign-out button:hover{background:light-dark(#fcefee,#382828)}
@media(prefers-reduced-motion:reduce){.account-password summary span{transition:none}}

/* Password setup and loading share the same centred card as the account pages. */
.password-setup-sign-in{display:flex;width:100%;min-height:46px;margin:24px 0 20px;border-radius:7px;font-weight:600}
.password-setup-card .password-setup-back{margin-top:22px}
.editor-page #app-loading,#app-loading[data-loading-kind="programme"]{background:var(--theme-outside,var(--cell));padding:24px 16px}
#app-loading .editor-loading-inner{box-sizing:border-box;width:min(100%,420px);padding:32px;text-align:center;background:var(--paper);border:1px solid var(--line);border-radius:16px;box-shadow:0 12px 40px light-dark(#26354a12,#0005)}
#app-loading .editor-loading-mark{width:54px;height:54px;margin:0 auto 18px;border-radius:13px;font-size:17px}
@media(max-width:420px){#app-loading .editor-loading-inner{padding:28px 22px;border-radius:12px}}
.account-card .account-password.is-resizing{overflow:hidden;will-change:height}

/* Account is a top-layer screen; the live Programme/editor remains mounted beneath it. */
dialog.account-overlay{position:fixed;inset:0;width:100%;max-width:none;height:100dvh;max-height:none;margin:0;padding:0;border:0;border-radius:0;overflow:auto;background:var(--theme-outside,var(--cell));color:var(--ink)}
dialog.account-overlay .app-shell{min-height:100%;padding:24px 16px}
.account-overlay::backdrop{background:var(--theme-outside,var(--cell))}
html:has(.account-overlay[open]){overflow:hidden;scrollbar-gutter:stable}
.account-overlay-cancel{width:100%;margin-top:22px}
