/* THE SHARED DROPDOWN (.tpl-switcher; template-switcher.js) and the one menu typography (.tpl-menu), on the menu CONTAINER so
   items inherit. Linked after base.css and before every page stylesheet, so a page's rules override it. A dropdown is a field:
   --surface-field and its --field-ink, never the page's --color-text-primary. The long-list arm (13+ entries) is at the foot. */
.tpl-menu{font-family:var(--font-label);font-size:var(--caption-size-rail);text-transform:none;letter-spacing:var(--tracking-0);}
.tpl-menu{color:var(--field-ink);background:var(--surface-menu);z-index:var(--layer-menu);}
/* Form-control menu items (<button>, <a>) do not inherit font or colour by UA default, so inheritance is repaired FULLY here
   and they take .tpl-menu; not a specificity bump. Active/current-state rules (two classes) still win over this (one class
   + element). */
.tpl-menu button,
.tpl-menu a{font:inherit;text-transform:inherit;letter-spacing:inherit;color:inherit;}
/* A menu's labels read the menu's own ink: .tpl-mono's and a caption's are the page's, light on a dark ground and unreadable
   on the menu's surface. */
.tpl-menu :is(.tpl-mono, .c-caption){color:inherit;}
/* A value dropdown whose entries are data (data-mirror): only the checked entry, marked .is-current, is shown, so the trigger is
   as wide as the value it shows and its chevron follows it (THE CHEVRON, below). */
[data-mirror] .tpl-switcher-trigger-label > [data-v]:not(.is-current){display:none;}
/* A COLUMN DROPDOWN (.tpl-switcher--column): every entry holds the value's one cell and only the chosen one is drawn, so it is
   as wide as its widest entry whichever is chosen, and a column of them is one width. */
.tpl-switcher--column .tpl-switcher-trigger-label{display:grid;justify-items:start;}
.tpl-switcher--column .tpl-switcher-trigger-label > [data-v]{grid-area:1 / 1;}
.tpl-switcher--column .tpl-switcher-trigger-label > [data-v]:not(.is-current){display:block;visibility:hidden;}
/* A language's entry keeps its flag on the line of its name. */
:where(.tpl-switcher[data-mirror] .tpl-switcher-trigger-label) > .lang-choice-entry.is-current{display:flex;}
/* A FIT DROPDOWN (.tpl-switcher--fit): inline, outside the rail, where a box is not the column's width; a host may set
   --switcher-fit-w (My Sessions' wave Results fills its column on a phone). */
.tpl-switcher--fit{display:inline-flex;width:var(--switcher-fit-w, auto);max-width:100%;vertical-align:middle;}
/* In the Respondent Data field rows (.tpl-segment-fields) the trigger fills its column, as in .p-view-switchers. */
.tpl-segment-fields .tpl-switcher--fit > .tpl-switcher-trigger{flex:1 1 auto;min-width:0;}
/* A SWITCHER ON A PHONE: the participant preview's Design and Language take one width,
   --switcher-w-phone (tokens.css), whatever their entries; the trigger fills it. (The results toolbar's are grid cells, results-chrome.css.) */
@media(max-width:640px){
    :where(.p-view-switchers) .tpl-switcher--fit{--switcher-w-phone:100%;width:var(--switcher-w-phone);}
    :where(.p-view-switchers) .tpl-switcher--fit > .tpl-switcher-trigger{flex:1 1 auto;min-width:0;}
}
/* An entry that is a button (data-mirror-active): the caller marks the chosen one .active / aria-pressed. */
button.tpl-switcher-item{display:block;width:100%;background:none;border:0;font:inherit;color:inherit;text-align:left;cursor:pointer;}
button.tpl-switcher-item:hover{background:color-mix(in srgb, var(--field-ink) 5%, transparent);}
.tpl-switcher-item.active,
.tpl-switcher-item[aria-pressed="true"]{background:rgba(var(--red-rgb),0.06);}
/* A radio item: the radio is focusable but not drawn (the whole row is the target), the
   checked row reads as the picker's .is-current, and keyboard focus shows on the row. */
label.tpl-switcher-item{position:relative;cursor:pointer;}
label.tpl-switcher-item:hover{background:color-mix(in srgb, var(--field-ink) 5%, transparent);}
.tpl-switcher-item > input[type="radio"]{position:absolute;width:var(--edge-1);height:var(--edge-1);opacity:0;margin:0;pointer-events:none;}
/* An entry offered self-paced only (data-self-paced-only, QuestionType::selfPacedWays) leaves the list on a live set-up page, unless chosen. */
:where(.tpl-start.workshop-mode) .tpl-switcher-item:where(:has(> input[data-self-paced-only]:not(:checked))){display:none !important;}
/* The entry in use. */
.tpl-switcher-item:has(> input[type="radio"]:checked){background:rgba(var(--red-rgb),0.06);}
.tpl-switcher-item:has(> input[type="radio"]:focus-visible){outline:var(--edge-2) solid var(--ink);outline-offset:calc(-1 * var(--edge-2));}
.tpl-start .tpl-switcher-item:has(> input[type="radio"]:focus-visible){outline-color:var(--focus-ring);}
/* THE CHOICES SIDE BY SIDE (_method-dropdown $mdSeg): the same radios with no closed box, every choice one width, the
   widest's; `--seg-row` in one line, `--seg-stack` one under another, under its field (below). The checked one is filled in the kicker ink. */
.tpl-switcher--seg{text-align:start;}
.tpl-switcher--seg > .tpl-switcher-menu{position:static;display:inline-grid;gap:var(--space-2);padding:var(--space-2);overflow:visible;
    border:var(--edge-1_5) solid var(--line-strong);border-radius:var(--radius-pill);box-shadow:none;background:var(--surface-field);}
.tpl-switcher--seg-row > .tpl-switcher-menu{grid-auto-flow:column;grid-auto-columns:1fr;}
.tpl-switcher--seg :is(.tpl-switcher-group, .tpl-switcher-group-body){display:contents;}
.tpl-switcher--seg .tpl-switcher-item{display:flex;align-items:center;justify-content:center;min-height:var(--size-32);padding:0 var(--space-12);
    border-radius:var(--radius-pill);text-align:center;white-space:nowrap;}
.tpl-switcher--seg-stack .tpl-switcher-item{justify-content:flex-start;border-radius:var(--radius-entry);white-space:normal;}
.tpl-switcher--seg .tpl-switcher-item:has(> input:checked){background:var(--kicker-ink);color:var(--on-accent);}
.tpl-switcher--seg .tpl-switcher-item:has(> input:disabled){cursor:default;}
/* A --seg-stack is a field (_method-dropdown draws its trigger): pressed, its list opens under it in the flow, at the field's
   corner (template-switcher.js leaves it in place). */
.tpl-switcher--seg-stack > .tpl-switcher-trigger{display:flex;box-sizing:border-box;width:100%;justify-content:space-between;}
.tpl-switcher--seg-stack > .tpl-switcher-menu{display:grid;grid-template-columns:minmax(0,1fr);margin-top:var(--gap-tight);border-radius:var(--radius-control);}
.tpl-switcher--seg-stack:not([data-open="1"]) > .tpl-switcher-menu{display:none;}
/* THE CHOICES AS CARDS (`--seg-cards`): each its drawing over its name, in a row that wraps; outlined, the checked one filled.
   A locked or read-only one keeps its look and takes no hover. `--drawings` holds the Method's wider drawings. */
.tpl-switcher--seg-cards > .tpl-switcher-menu{display:flex;flex-wrap:wrap;gap:var(--space-8);padding:0;border:0;border-radius:0;background:none;}
.tpl-switcher--seg-cards .tpl-switcher-item{flex:none;flex-direction:column;gap:var(--space-6);width:var(--size-104);min-height:var(--size-96);box-sizing:border-box;
    padding:var(--space-10) var(--space-6) var(--space-8);border:var(--edge-1_5) solid var(--line-strong);border-radius:var(--radius-14);
    font-size:var(--type-12);line-height:var(--leading-13);white-space:normal;}
.tpl-switcher--seg-cards .tpl-switcher-item:where(:not(:has(> input:checked))):hover{background:none;}
.tpl-switcher--seg-cards .tpl-switcher-item:has(> input:checked){border-color:var(--kicker-ink);}
.tpl-switcher--seg-cards .tpl-switcher-item-icon{flex:none;width:var(--size-24);height:var(--size-24);}
.tpl-switcher--drawings .tpl-switcher-item{width:var(--size-96);}
.tpl-switcher--drawings .tpl-switcher-item-icon{width:var(--size-56);height:var(--size-36);}
/* On a phone every card one size, its name on one line, cut with an ellipsis, the Method's drawing smaller. */
@media (max-width: 640px){
    .tpl-switcher--seg-cards .tpl-switcher-item{width:var(--size-84);height:var(--size-64);min-height:0;gap:var(--space-4);padding:var(--space-8) var(--space-4);
        font-size:var(--type-10);white-space:nowrap;}
    .tpl-switcher--seg-cards .tpl-switcher-item-name{max-width:100%;overflow:hidden;text-overflow:ellipsis;}
    .tpl-switcher--drawings .tpl-switcher-item-icon{width:var(--size-32);height:var(--size-20);}
}
/* On the set-up band: the band's ink, a light outline, the checked one filled in the band's ink. */
.tpl-start :where(.tpl-setup-band) .tpl-switcher--seg-cards > .tpl-switcher-menu{color:inherit;}
.tpl-start :where(.tpl-setup-band) .tpl-switcher--seg-cards .tpl-switcher-item{border-color:var(--setup-band-line);color:inherit;}
.tpl-start :where(.tpl-setup-band) .tpl-switcher--seg-cards .tpl-switcher-item:has(> input:checked){background:var(--setup-band-ink, var(--on-accent));border-color:var(--setup-band-ink, var(--on-accent));color:var(--setup-band-fill, var(--accent));}
.tpl-start :where(.tpl-setup-band) .tpl-switcher--seg-cards .tpl-switcher-item:has(> input:focus-visible){outline-color:currentColor;outline-offset:var(--edge-2);}
/* An open card's hover, after the band's outline so it wins there too. */
.tpl-switcher--seg-cards .tpl-switcher-item:where(:has(> input:enabled:not(:checked))):where(:not(.plan-locked *)):hover{border-color:currentColor;}
/* THE CHOICE CARDS, SMALL (.tpl-switcher--small, QuestionTypes.choiceCards): the band's cards (dropdown.css) at the type
   card's size in one row that scrolls, the checked one in the accent; a kind with ways its way on a second line, a live kind
   on a session that is not live greyed with its tag. */
.tpl-start .tpl-switcher--small{width:100%;min-width:0;}
.tpl-start .tpl-switcher--small > .tpl-switcher-menu{flex-wrap:nowrap;overflow-x:auto;scrollbar-width:none;padding-bottom:var(--space-2);}
.tpl-start .tpl-switcher--small .tpl-switcher-item{position:relative;width:var(--size-96);min-height:var(--size-80);background:var(--surface-field);color:var(--ink);}
.tpl-start .tpl-switcher--small .tpl-switcher-item:has(> .tpl-switcher-item-sub){min-height:var(--size-84);}
.tpl-start .tpl-switcher--small .tpl-switcher-item:has(> input:checked){background:var(--surface-field);color:var(--kicker-ink);box-shadow:inset 0 0 0 var(--edge-1) var(--kicker-ink);}
.tpl-start :where(.tpl-switcher--small) .tpl-switcher-item:has(> input:disabled:not(:checked)){opacity:.45;cursor:not-allowed;}
.tpl-start .tpl-switcher--small .tpl-switcher-item-sub{display:inline-flex;align-items:center;gap:var(--space-2);font-size:var(--type-10);color:var(--muted);}
.tpl-start :where(.tpl-switcher--small .tpl-switcher-item:has(> input:checked)) > .tpl-switcher-item-sub{color:var(--kicker-ink);}
.tpl-start .tpl-switcher--small .tpl-switcher-item-tag{position:absolute;top:var(--space-4);right:var(--space-6);font-size:var(--type-9);letter-spacing:var(--tracking-6);text-transform:uppercase;color:var(--muted);}
.tpl-start .tpl-switcher--small.tpl-switcher--drawings .tpl-switcher-item-icon{width:var(--size-30);height:var(--size-22);}
@media(max-width:640px){
    .tpl-start .tpl-switcher--small .tpl-switcher-item{width:var(--size-84);min-height:var(--size-64);}
    .tpl-start .tpl-switcher--small .tpl-switcher-item:has(> .tpl-switcher-item-sub){min-height:var(--size-72);}
}
/* ── Template switcher (templates/start.blade.php): a subtle utility control listing every public template by session shape,
   a hairline border on the trigger only and a pure CSS chevron. The menu is absolute inside the relative .tpl-switcher;
   data-open="1" opens it, and the JS flips aria-expanded and the menu's hidden attribute so readers and CSS agree. */
.tpl-switcher{
    /* Shared switcher component, inline in the button stacks (home, method, the hero) and standalone on the setup page: only
       what applies in EVERY context is here (position:relative anchors the menu; text-align:right seats the trigger). The setup
       page's own placement is scoped to .tpl-start in start.blade.php, so it cannot leak into the inline stacks. */
    position:relative;
    text-align:right;
    font-family:var(--font-body);
    /* Single font-size source for the trigger and the menu items, so they never diverge: the trigger inherits it (font-size:inherit
       below breaks the UA <button> size) and .tpl-menu reads the same token, --caption-size-rail (tokens.css). */
    font-size:var(--caption-size-rail);
    row-gap:var(--switcher-row-gap, normal);   /* a host that lays the switcher out as a column sets the step */
}
/* AN OPEN MENU IS IN THE TOP LAYER (template-switcher.js, tplMenuOverlay.raise): above every page element whatever stacking
   context its switcher sits in, so no switcher, card or rail ranks itself to clear one. Its layer token stands for a
   browser without the top layer. */
.tpl-switcher-trigger,.file-field{
    display:inline-flex;
    align-items:center;
    /* THE CHEVRON: directly after the value, --gap-tight from it, in every dropdown; nothing grows the label or spreads the two. */
    gap:var(--gap-tight);
    background:var(--switcher-fill, var(--surface-field));
    border:var(--switcher-edge-w, var(--edge-1)) solid var(--switcher-edge, var(--line-strong));
    border-radius:var(--radius-control);
    padding:var(--gap-tight) var(--inset-box);
    /* A design's dropdown face first; else a host's field text role (account.css); else the label face. */
    font-family:var(--font-switcher, var(--field-text-font, var(--font-label)));
    /* Inherit the switcher root's font-size, so the selected name matches the menu items. font-size:inherit is REQUIRED: the UA
       gives <button> its own size (.tpl-menu button{font:inherit} does the same for the items). */
    font-size:inherit;
    color:var(--switcher-label-ink, var(--switcher-ink, var(--field-ink)));
    cursor:pointer;
    /* A host whose fields share one text role and one control height sets these (account.css). */
    line-height:var(--switcher-line, var(--leading-12));
    min-height:var(--switcher-min-h, auto);
    max-width:100%;
}
/* The file field (account/index, events/branding): a field like the page's dropdowns, whose trigger rule above it reads,
   holding the chosen file's name and its pick word at the end. Text that does not fit wraps and the field grows. */
.file-field{display:flex;width:100%;min-width:0;max-width:none;gap:var(--inset-control);overflow:hidden;text-align:left;font-size:var(--caption-size-rail);}
.file-field-name{flex:1;min-width:0;overflow-wrap:anywhere;color:var(--muted);}
.file-field-pick{flex:none;text-transform:uppercase;letter-spacing:var(--tracking-8);font-size:var(--type-10);}
.tpl-switcher-trigger:hover{border-color:var(--line-strong);}
.tpl-switcher[data-open="1"] .tpl-switcher-trigger{border-color:var(--line-strong);}
/* ── A DISABLED SWITCHER LOOKS DISABLED: faded, and not-allowed. A LOCKED one (a structural or a fixed field's
   [data-read-only], a plan lock's [data-plan-inert]) is not: it is THE LOCKED LOOK's (below, and shared-controls.css). */
.tpl-switcher-trigger:disabled:where(:not([data-read-only], [data-plan-inert])),.file-field:disabled{opacity:0.55;cursor:not-allowed;}
/* LOCKED (THE LOCKED LOOK, shared-controls.css): the chosen value, in its ink, with no edge, no fill and no chevron; read-only,
   nothing to press, and a plan lock's still pressed for its upgrade offer. */
.tpl-switcher .tpl-switcher-trigger:is([data-read-only], [data-plan-inert]){opacity:1;border-color:transparent;background:transparent;cursor:default;}
.tpl-switcher .tpl-switcher-trigger[data-read-only]{pointer-events:none;}
.tpl-switcher-trigger:is([data-read-only], [data-plan-inert]) .tpl-switcher-trigger-chev{display:none;}
/* THE VALUE IS ONE LINE, in every dropdown: it never wraps; only where its host is narrower than it does it end in an ellipsis. */
.tpl-switcher-trigger-label{min-width:0;white-space:nowrap;overflow-x:clip;text-overflow:ellipsis;}
.tpl-switcher-trigger-chev{
    display:inline-block;
    width:var(--size-8);
    height:var(--size-8);
    border-right:var(--field-edge-width) solid currentColor;
    border-bottom:var(--field-edge-width) solid currentColor;
    border-color:var(--chevron-ink, currentColor);
    transform:translateY(-2px) rotate(45deg);
    transition:transform var(--motion-fast);
    flex-shrink:0;
}
/* On the setup page this reads its roles; the rule above serves the participant and results pages too. */
.tpl-start .tpl-switcher-trigger-chev{border-right-color:var(--switcher-chev-ink, var(--muted-mark));border-bottom-color:var(--switcher-chev-ink, var(--muted-mark));}
.tpl-switcher[data-open="1"] .tpl-switcher-trigger-chev,
.tpl-card-fold[aria-expanded="true"] .tpl-switcher-trigger-chev,
.as-drawer[aria-expanded="true"] > .tpl-switcher-trigger-chev,
.as-fold-btn[aria-expanded="true"] > .tpl-switcher-trigger-chev,
.tpl-pd-optcount[aria-expanded="true"] > .tpl-switcher-trigger-chev{
    transform:translateY(1px) rotate(225deg);
}
/* A QUIET DROPDOWN (.tpl-switcher--quiet; a question's type): its value reads as a field label, .c-caption's own face, weight,
   tracking, case and ink, at the badge's height, no fill, edge or radius, the chevron in the text's ink; hover and open add an
   underline, disabled and locked stay muted. A long value wraps left-aligned (the UA centres a <button>). */
.tpl-switcher--quiet{min-width:0;text-align:left;}
/* Before the sentence's rule, which keeps its ink when disabled too. */
.tpl-switcher--quiet > .tpl-switcher-trigger:disabled{color:var(--muted);}
/* In a setting's sentence (.qt-rule-field, question-types.css): its value reads as the sentence's other values do, its words one
   weight heavier, in the sentence's face and case (a poll's time zone, Closes, Reminders, New answers, Send from). */
.qt-rule-field > .tpl-switcher--quiet > .tpl-switcher-trigger{font-family:inherit;font-size:inherit;font-weight:var(--weight-semibold);letter-spacing:normal;text-transform:none;color:var(--ink);}
.tpl-switcher--quiet > .tpl-switcher-trigger{
    min-height:var(--switcher-min-h, var(--tpl-badge-size));max-width:100%;padding:0;text-align:left;
    background:none;border:0;border-bottom:var(--edge-1) solid transparent;border-radius:0;
    font-family:var(--capt-font, var(--field-caption-font, var(--font-heading)));font-size:var(--caption-size);
    font-weight:var(--capt-weight, var(--field-caption-weight, inherit));letter-spacing:var(--capt-tracking, var(--field-caption-tracking, var(--tracking-8)));
    text-transform:var(--capt-case, var(--label-case));line-height:var(--capt-leading, var(--leading-1));color:var(--capt-ink, var(--kicker-ink));
}
.tpl-switcher--quiet > .tpl-switcher-trigger:not(:disabled):hover,
.tpl-switcher--quiet[data-open="1"] > .tpl-switcher-trigger{color:var(--ink);border-bottom-color:var(--ink);}
/* THE BOXED VALUE (.tpl-switcher--boxed; a poll's time zone in its sentence, a Budget's currency in its soft panel): the panel's
   one control height, the value and its chevron in a box; the box keeps its edge when hovered or open. */
.tpl-switcher--boxed{--switcher-min-h:var(--size-36);}
.tpl-switcher--boxed > .tpl-switcher-trigger,
.tpl-switcher--boxed > .tpl-switcher-trigger:not(:disabled):hover,
.tpl-switcher--boxed[data-open="1"] > .tpl-switcher-trigger{box-sizing:border-box;padding:0 var(--inset-box);
    border:var(--edge-1) solid var(--card-border);border-radius:var(--radius-control);background:var(--surface-field);}
/* THE STRIP'S MENUS (.tpl-switcher--strip; a card's type strip, question-types.js typeStrip): the highlight follows the
   pointer and the entry in use is bold, not shaded.
   Its value is the strip's line. */
.tpl-switcher--strip{--switcher-min-h:var(--size-18);}
.tpl-switcher--strip .tpl-switcher-item.active{background:none;font-weight:var(--weight-semibold);}
.tpl-switcher--strip .tpl-switcher-item:not(:disabled):hover,.tpl-switcher--strip .tpl-switcher-item:focus-visible{background:color-mix(in srgb, var(--field-ink) 5%, transparent);}
.tpl-start .tpl-switcher--quiet .tpl-switcher-trigger-chev{border-right-color:currentColor;border-bottom-color:currentColor;}
.tpl-switcher-menu{
    position:absolute;
    top:calc(100% + var(--gap-tight));
    right:0;
    /* Left-align the menu contents: the .tpl-switcher block is text-align:right
       (to right-align the trigger), which would otherwise cascade to the items. */
    text-align:left;
    overflow-y:auto;
}
/* The menu's box, and a submenu's beside it (THE SUBMENU, below). */
.tpl-switcher-menu,.tpl-switcher-submenu{
    --shadow-popover-offset:var(--shadow-popover);
    background:var(--surface-menu);
    border:var(--edge-1) solid var(--line-strong);
    border-radius:var(--radius-entry);
    box-shadow:var(--shadow-popover-offset) rgba(var(--ink-rgb),0.08);
    padding:var(--gap-tight) 0;
}
/* An open menu is a popover in the top layer (template-switcher.js), placed by inline left/top and its
   box's width: the UA's popover centring (inset:0; margin:auto) is undone so those are what apply. */
:is(.tpl-switcher-menu, .tpl-menu, .tpl-switcher-submenu)[popover]{inset:auto;margin:0;}
/* THE SUBMENU (.tpl-switcher-sub, template-switcher.js wireSubs; a strip's Type menu): a heading whose entries open beside the
   menu as the pointer reaches it, its chevron pointing at them, the heading shaded while the pointer is in them; on a phone
   they open under it, set in at the menu's inset behind a hairline. */
.tpl-switcher .tpl-switcher-sub > .tpl-switcher-fold[aria-expanded] .tpl-switcher-trigger-chev{transform:rotate(-45deg);}
.tpl-switcher--strip .tpl-switcher-sub:hover > .tpl-switcher-fold{background:color-mix(in srgb, var(--field-ink) 5%, transparent);}
.tpl-switcher-submenu{min-width:max-content;overflow-y:auto;}
@media(max-width:640px){
    .tpl-switcher .tpl-switcher-sub > .tpl-switcher-fold[aria-expanded="true"] .tpl-switcher-trigger-chev{transform:translateY(-2px) rotate(45deg);}
    .tpl-switcher-submenu{background:none;border:0;border-left:var(--edge-2) solid var(--line);border-radius:0;box-shadow:none;padding:0;margin-inline-start:var(--inset-panel);}
}
.tpl-switcher-group + .tpl-switcher-group{
    border-top:var(--edge-1) solid rgba(var(--ink-rgb),0.08);
    margin-top:var(--gap-tight);
    padding-top:var(--gap-tight);
}
.tpl-switcher-group-label{
    font-family:var(--font-label);
    font-size:inherit;   /* the entries' size, which the menu's .tpl-menu sets */
    font-weight:var(--weight-bold);
    letter-spacing:var(--tracking-18);
    text-transform:uppercase;
    color:var(--field-ink);
    padding:var(--gap-tight) var(--inset-panel) var(--inset-tag);
}
/* A heading that folds its entries ($mdFold, templates/_method-dropdown-group; a set-up rail group's header,
   components/rail-group, unless it is the shared button): the heading's own face, reset as button.tpl-switcher-item is, with the trigger's chevron
   pointing at the entries while open and away while folded. */
button.tpl-switcher-fold:where(:not(.c-btn)){display:flex;align-items:center;justify-content:space-between;gap:var(--gap-row);width:100%;margin:0;background:none;border:0;text-align:start;cursor:pointer;}
button.tpl-switcher-fold:where(:not(.c-btn)):hover{background:color-mix(in srgb, var(--field-ink) 5%, transparent);}
button.tpl-switcher-fold:where(:not(.c-btn)):focus-visible{outline:var(--edge-2) solid var(--focus-ring);outline-offset:calc(-1 * var(--edge-2));}
/* On the band's fill a ring draws in the band's ink, which the band holds at a text contrast against its fill. */
.tpl-start .tpl-setup-band :is(.tpl-switcher-fold, .tpl-switcher-trigger):focus-visible{outline-color:currentColor;}
:is(.tpl-switcher, .tpl-rail-group) .tpl-switcher-fold .tpl-switcher-trigger-chev{transform:rotate(-45deg);}
:is(.tpl-switcher, .tpl-rail-group) .tpl-switcher-fold[aria-expanded="true"] .tpl-switcher-trigger-chev{transform:translateY(-2px) rotate(45deg);}
.tpl-start .tpl-rail-group-icon {
    display: grid;
    place-items: center;
    flex: none;
    width: calc(var(--space-16) + 2 * var(--space-8));
    height: calc(var(--space-16) + 2 * var(--space-8));
    border-radius: 50%;
    background: var(--surface-panel);
    color: var(--accent-ink);
}
.tpl-start .tpl-rail-group-icon .rail-icon { color: inherit; }
.tpl-start .tpl-rail-group-text { flex: 1; min-width: 0; display: flex; flex-direction: column; }
/* A set-up rail tab (setup-sidebar.css, THE TABS) opens a panel beside it: no chevron. */
.tpl-start.setup-sidebar :where(.tpl-sidebar .tpl-rail-tab) > .tpl-switcher-trigger-chev{ display: none; }

.tpl-switcher-item{
    display:block;
    padding:var(--gap-tight) var(--inset-box);
    color:var(--field-ink);
    text-decoration:none;
    line-height:var(--leading-13);
    /* The menu is as wide as its widest line (template-switcher.js anchorMenu); a name wraps only in a window narrower. */
    white-space:normal;
    overflow-wrap:break-word;
    /* font-family / size / case come from the canonical .tpl-menu on the menu container; re-declaring them here would
       re-diverge. */
}
a.tpl-switcher-item:hover{background:color-mix(in srgb, var(--field-ink) 5%, transparent);}
.tpl-switcher-item.is-current{
    color:var(--field-ink);
    cursor:default;
    background:rgba(var(--red-rgb),0.06);
}
/* A MENU OF ACTIONS (a row's overflow menu, public/js/row-menu.js: its ⋯ opens it): entries that do something rather than
   choose, a rule between groups of them (<hr>), one that has to POST wearing a form that is not the entry, and one that
   deletes (.is-danger) in the destructive red. */
.tpl-switcher-menu > hr{border:0;border-top:var(--edge-1) solid rgba(var(--ink-rgb),0.08);margin:var(--gap-tight) 0;}
.tpl-switcher-menu > form{margin:0;}
.tpl-switcher-item.is-danger{color:var(--destructive-ink);}
:is(a, button).tpl-switcher-item.is-danger:hover{background:color-mix(in srgb, var(--destructive) 8%, transparent);}
/* A language choice's entry — its flags, then its name — in the trigger and in the list (templates/_method-dropdown with
   $mdFlags), and the root of a choice that does not navigate (partials/_language-choice). */
.lang-choice{position:relative;display:inline-block;}
.lang-choice-entry{display:inline-flex;align-items:center;gap:var(--gap-row);}
/* An event's Language menu: the language's own name, its English name under it ($mdAltShown). */
.lang-choice-names{display:inline-flex;flex-direction:column;}
.lang-choice-alt{font-size:var(--type-12);}
/* THE FIELD DROPDOWN (.tpl-switcher--field, partials/_participant-field-input; participant-select.js): a respondent's list
   field — the switcher's open state, chevron and menu box, with the participant field (.pf-field, blocks.css) for its
   trigger, a value on its underline with the chevron at its end. */
.tpl-switcher--field{text-align:left;}
.tpl-switcher--field > .pf-select-trigger{display:flex;align-items:center;justify-content:space-between;gap:var(--gap-row);cursor:pointer;text-align:left;}
/* The off-list state ("Not listed — enter your own"): the trigger goes, and a status line that is not a control takes its slot,
   so the field carries one rule, on the input. The same data attribute Blade writes server-side for a stored off-list value. */
.tpl-switcher--field[data-other="1"] > .pf-select-trigger{display:none;}
/* The value wraps onto further lines rather than being cut (base.css's body overflow-wrap). */
.pf-select-label{min-width:0;}
.tpl-switcher--field .tpl-switcher-trigger-chev{border-color:var(--field-chevron-ink, var(--color-text-primary, var(--ink)));}
.tpl-switcher--field > .tpl-switcher-menu--field{left:0;right:auto;}
/* Its option rows carry neither .tpl-switcher-item nor .tpl-menu, so they own their look: plain participant field values (the
   UA <button> border and ground reset), not the switcher's boxed mono. Hover and keyboard focus share one subtle ground;
   scoped to .pf-select-item, so the other menus are untouched. */
.pf-select-item{
    display:block;
    width:100%;
    box-sizing:border-box;
    margin:0;
    padding:var(--inset-control) var(--inset-box);
    border:none;
    background:none;
    text-align:left;
    font-family:var(--font-body);
    font-size:var(--type-16);
    color:var(--color-text-primary, var(--ink));
    line-height:var(--leading-14);
    cursor:pointer;
}
.pf-select-item:hover,
.pf-select-item:focus{background:var(--menu-hover);outline:none;}
/* An option row: its label on one flex line. */
.pf-select-item{display:flex;align-items:baseline;gap:var(--gap-row);}
.pf-select-item-lab{min-width:0;}
/* Filter row, rendered only above ParticipantField::FILTER_THRESHOLD options: the menu's head, STICKY, so a long list keeps its
   filter in reach. The head carries the menu's top inset, so it seats flush, its ground opaque as rows scroll under it. Face
   and ink are .pf-select-item's, so it reads as part of the list. */
.tpl-switcher-menu:has(> .pf-select-filterrow){padding-top:0;}
.pf-select-filterrow{
    --rule-base:rgba(var(--app-ground-ink-rgb), 0.12);
    position:sticky;
    top:0;
    z-index:var(--layer-raised);
    background:var(--surface-menu);
    border-bottom:var(--edge-1) solid var(--rule-base);
    padding:var(--inset-control) var(--inset-box);
}
/* 16px: iOS Safari zooms on focusing an input below 16px. */
.pf-select-filter{
    display:block;
    width:100%;
    box-sizing:border-box;
    margin:0;
    padding:var(--inset-tag) 0;
    border:none;
    border-bottom:var(--edge-2) solid var(--line-strong);
    border-radius:0;
    background:transparent;
    font-family:var(--font-body);
    font-size:var(--type-16);
    color:var(--color-text-primary, var(--ink));
    outline:none;
}
.pf-select-filter::placeholder{color:var(--muted);opacity:1;}
:where(.p-flow) .pf-select-filter::placeholder{color:var(--flow-placeholder-ink, var(--muted));}
/* Shown in place of the options when nothing matches. Same box as an option row so
   the menu does not change shape, but plainly not selectable: grey, not a button. */
.pf-select-nomatch{
    padding:var(--inset-control) var(--inset-box);
    font-family:var(--font-body);
    font-size:var(--type-16);
    line-height:var(--leading-14);
    color:var(--muted);
}
/* A link in everything but the element: a <button>, which acts on this page and never navigates or submits its form. The UA
   button reset plus the link's colour and underline; its type is .block-body-text's, so this states no size. display:block
   takes the hidden trigger's slot (inline-block would sit on the label's baseline). */
.pf-other-change{display:none;}
.tpl-switcher--field[data-other="1"] > .pf-other-change{
    display:block;
    padding:0;
    border:none;
    background:none;
    text-align:left;
    color:var(--accent-ink);
    text-decoration:underline;
    cursor:pointer;
}
.pf-other-change:hover{color:var(--accent-hover);}

/* ── A LONG LIST: 13 OR MORE ENTRIES (template-switcher.js, setupLong): a filter over up to three columns reading down in list
   order (grid-auto-flow:column), each as wide as its longest entry, the menu at least its box's width. On a phone, a
   full-height sheet: filter and close on top, one scrolling column. A list of 12 or fewer gets none of this. */
.tpl-switcher[data-open="1"] > .tpl-switcher-menu--long{
    display:flex;
    flex-direction:column;
    padding:0;
    overflow:hidden;
}
.tpl-switcher-head{
    flex:none;
    display:flex;
    align-items:center;
    gap:var(--gap-row);
    padding:var(--inset-control) var(--inset-box);
    border-bottom:var(--edge-1) solid var(--line);
}
.tpl-switcher-filter{
    flex:1 1 auto;
    min-width:0;
    box-sizing:border-box;
    padding:var(--inset-tag) var(--gap-row);
    border:var(--edge-1) solid var(--line-strong);
    border-radius:var(--radius-control);
    background:var(--surface-field);
    color:var(--field-ink);
    font:inherit;
    text-transform:none;
    letter-spacing:normal;
}
.tpl-switcher-filter::placeholder{color:var(--placeholder-ink, var(--field-ink));}
.tpl-switcher-head .tpl-switcher-close{
    display:none;
    flex:none;
    width:auto;
    appearance:none;
    background:none;
    border:0;
    padding:0 var(--inset-control);
    font:inherit;
    font-size:var(--type-20);   /* the panel-close glyph */
    line-height:var(--leading-1);
    color:var(--field-ink);
    cursor:pointer;
}
.tpl-switcher-list{
    flex:1 1 auto;
    min-height:0;
    overflow:auto;
    display:grid;
    grid-auto-flow:column;
    grid-template-columns:repeat(var(--cols, 1), max-content);
    grid-template-rows:repeat(var(--rows, 1), auto);
    padding:var(--gap-tight) 0;
}
.tpl-switcher-list .tpl-switcher-group{display:contents;}
/* A folding list reads as a tree, one column, each group a box of its own (template-switcher.js keeps it to one). */
.tpl-switcher--fold .tpl-switcher-list{display:block;}
.tpl-switcher--fold .tpl-switcher-list .tpl-switcher-group{display:block;}
.tpl-switcher-list [hidden]{display:none !important;}
.tpl-switcher-list .tpl-switcher-item{white-space:nowrap;}
.tpl-switcher-item.is-active{background:color-mix(in srgb, var(--field-ink) 6%, transparent);}
.tpl-switcher-nomatch{margin:0;padding:var(--inset-box);color:var(--field-ink);}
.tpl-switcher-menu--long[popover]{inset:auto;margin:0;}
@media(max-width:640px){
    .tpl-switcher[data-open="1"] > .tpl-switcher-menu--long{
        position:fixed;
        inset:0;
        width:100%;
        max-width:none;
        height:100%;
        max-height:none;
        border:0;
        border-radius:0;
        box-shadow:none;
    }
    .tpl-switcher-menu--long[popover]{inset:0;}
    .tpl-switcher-head .tpl-switcher-close{display:block;}
    .tpl-switcher-filter{font-size:var(--type-16);}   /* iOS zooms the page on focusing a field smaller than 16px */
    .tpl-switcher-list{grid-template-columns:minmax(0,1fr);grid-template-rows:none;grid-auto-flow:row;}
    .tpl-switcher-menu--flags .tpl-switcher-list{grid-template-columns:max-content max-content;}
    .tpl-switcher-list .tpl-switcher-item{white-space:normal;}
}

/* ═══ A language's flag (partials/_flag.blade.php): the label's cap height (DM Mono's 0.7em) in a 3:2 box, centred on the
   name; the hairline keeps a white band visible on any ground. Here because every language choice is the dropdown, the
   site nav's included, which the admin panel carries without base.css. */
.nav-flag{
  flex:none;
  height:0.7em; /* literal: measure-text, the label's cap height, in its own type (above) */
  width:1.05em; /* literal: measure-text, 3:2 of that height */
  box-shadow:var(--ring-1) var(--site-nav-shade);
}
/* A language's flags side by side (partials/_flag). */
.lang-flags{
  --lang-flag-gap:var(--space-4);
  flex:none;
  display:inline-flex;
  align-items:center;
  gap:var(--lang-flag-gap);
}
/* THE OPEN LIST OF LANGUAGES: names then flags, every entry a row of one grid shared by the list (subgrid), so names and flags
   each start at one edge whatever the script or direction. text-align:start, so a right-to-left page mirrors as a whole. A
   short menu is a grid of its own; a long one's list (setupLong) repeats the pair per column. */
.tpl-switcher-menu--flags:not(.tpl-switcher-menu--long) .tpl-switcher-group{display:grid;grid-template-columns:max-content max-content;}
.tpl-switcher-menu--flags .tpl-switcher-item{display:grid;grid-column:span 2;grid-template-columns:subgrid;column-gap:var(--gap-row);align-items:center;text-align:start;}
.tpl-switcher-menu--flags .lang-choice-entry{display:contents;}
.tpl-switcher-menu--flags .tpl-switcher-list{grid-template-columns:repeat(var(--cols, 1), max-content max-content);}
/* A choice with no flags (Manage Account's "Same as the site") keeps its empty area in a menu, for the alignment,
   and drops it in the closed box, where it would only be a gap before the name. */
.tpl-switcher-trigger .lang-flags:empty{display:none;}

/* A DROPDOWN DRAWN AS A TILE: My Sessions' new-session card (home.blade.php; its card and words are home.css's). The control is as
   tall as its own text, centred in the card, and its whole area clicks through to the control (::after). */
.new-session-card .tpl-switcher-trigger{max-width:none;background:transparent;border:0;color:var(--ink);
    text-align:left;padding:var(--inset-panel) var(--gap-block) var(--inset-panel);display:flex;flex-direction:column;justify-content:center;gap:var(--gap-tight);cursor:pointer;}
.new-session-card .tpl-switcher-trigger::after{content:"";position:absolute;inset:0;}


/* A RAIL ROW (setup-sidebar.css, THE RAIL'S ROWS ARE ONE LINE EACH), at every width: the trigger unboxed, its value at the
   row's end and the whole row its hit area (::after); a boxed one (.tpl-switcher--boxed) is the field it draws. */
.tpl-start.setup-sidebar :where(.tpl-sidebar, .tpl-card-gear) .tpl-rail-dropdown > :where(.tpl-switcher:not(.tpl-switcher--boxed)) > .tpl-switcher-trigger {
    width: auto;
    padding: 0;
    border: 0;
    background: none;
    text-align: end;
}
.tpl-start.setup-sidebar :where(.tpl-sidebar, .tpl-card-gear) .tpl-rail-dropdown > :where(.tpl-switcher:not(.tpl-switcher--boxed) > .tpl-switcher-trigger) > .tpl-switcher-trigger-label { text-align: end; }
.tpl-start.setup-sidebar :where(.tpl-sidebar, .tpl-card-gear) .tpl-rail-dropdown > :where(.tpl-switcher:not(.tpl-switcher--boxed)) > .tpl-switcher-trigger::after { content: ""; position: absolute; inset: 0; }

/* ── THE MARKETING DROPDOWN (.tpl-switcher--hv2), drawn here and nowhere else. Start from A Template
   (partials/_template-cta-stack): a trigger with no dropdown, opening the New session chooser, a pill beside the primary
   button. Its page sets its ground through --switcher-hv2-* (home-v2.css, method.css); the stack places and sizes it. */
button.tpl-switcher--hv2{
    display:flex;
    align-self:stretch;
    align-items:center;
    justify-content:center;
    width:100%;
    max-width:none;
    padding:var(--inset-panel) var(--switcher-hv2-pad-x, var(--space-24));
    background:var(--switcher-hv2-fill, var(--hv2-card));
    border:var(--switcher-hv2-border, var(--edge-1_5) solid var(--hv2-line));
    border-radius:var(--radius-pill);
    box-shadow:var(--switcher-hv2-shadow, none);
    backdrop-filter:var(--switcher-hv2-blur, none);
    -webkit-backdrop-filter:var(--switcher-hv2-blur, none);
    color:var(--switcher-hv2-ink, var(--hv2-slate));
    font-family:var(--hv2-text);
    font-size:var(--switcher-hv2-size, var(--type-14));
    font-weight:var(--weight-semibold);
    letter-spacing:0;
    text-transform:none;
    line-height:normal;
}
button.tpl-switcher--hv2:hover{
    background:var(--switcher-hv2-fill-hover, var(--hv2-tint));
    border:var(--switcher-hv2-border, var(--edge-1_5) solid var(--hv2-line));
}
/* The nav's language menu (partials/_nav-languages): the trigger is a nav item with the nav's caret, the open list in the
   nav's skin, reading only the nav's tokens whatever the theme (ThemeMechanismTest). Two classes: a page's `.hv2 button`
   and the collapsed nav's `.nav-collapse button` would otherwise reset its face and padding. */
.tpl-switcher--hv2 > .tpl-switcher-trigger{
    display:flex;
    align-items:center;
    gap:var(--site-nav-gap-tight);
    max-width:none;
    color:var(--site-nav-fg);
    background:none;
    border:0;
    border-radius:0;
    padding:var(--site-nav-gap) 0;
    cursor:pointer;
    text-decoration:none;
    transition:color .2s;
    font-family:var(--brand-font-mono);
    font-size:var(--site-nav-size-small);
    font-weight:var(--site-nav-weight);
    letter-spacing:var(--site-nav-tracking);
    text-transform:uppercase;
    line-height:normal;
}
.tpl-switcher--hv2 > .tpl-switcher-trigger:hover{color:var(--site-nav-fg-strong);}
.tpl-switcher--hv2 > .tpl-switcher-trigger > .tpl-switcher-trigger-chev{
    flex:0 0 auto;
    width:0;height:0;
    border-bottom:0;
    border-left:var(--edge-4) solid transparent;
    border-right:var(--edge-4) solid transparent;
    border-top:var(--edge-4) solid currentColor;
    transform:none;
    transition:transform .2s ease;
}
.tpl-switcher--hv2[data-open="1"] > .tpl-switcher-trigger > .tpl-switcher-trigger-chev{transform:rotate(180deg);}
.tpl-switcher--hv2 .tpl-switcher-menu{
    background:var(--site-nav-ground);
    border:var(--site-nav-edge-w) solid var(--site-nav-edge);
    border-radius:0;
    box-shadow:var(--site-nav-menu-shadow);
    color:var(--site-nav-fg);
    font-family:var(--site-nav-menu-face);
    font-size:var(--site-nav-menu-size);
    letter-spacing:var(--site-nav-tracking);
    text-transform:var(--site-nav-menu-case);
}
.tpl-switcher--hv2 .tpl-switcher-head{border-bottom:var(--edge-1) solid var(--site-nav-edge);}
.tpl-switcher--hv2 .tpl-switcher-filter{
    background:var(--site-nav-ground);
    border:var(--edge-1) solid var(--site-nav-edge);
    border-radius:0;
    color:var(--site-nav-fg-strong);
}
.tpl-switcher--hv2 .tpl-switcher-item{color:var(--site-nav-fg);}
.tpl-switcher--hv2 .tpl-switcher-item:hover,
.tpl-switcher--hv2 .tpl-switcher-item.is-active{background:var(--site-nav-hover-bg);color:var(--site-nav-fg-strong);}
.tpl-switcher--hv2 .tpl-switcher-item:has(> input[type="radio"]:checked){background:var(--site-nav-mark-bg);color:var(--site-nav-mark-fg);}
.tpl-switcher--hv2 .tpl-switcher-nomatch{color:var(--site-nav-fg);}
.tpl-switcher--hv2 .tpl-switcher-close{color:var(--site-nav-fg-strong);}

/* The switcher's measuring box (template-switcher.js): off the page, never drawn. */
.tpl-switcher-measure{position:absolute;visibility:hidden;white-space:nowrap;left:-9999px;}
.tpl-start.setup-sidebar .tpl-switcher-trigger-label{
    text-box: trim-both cap alphabetic;
}
/* A RAIL DROPDOWN (templates._rail-dropdown): its label, then the dropdown at the full width of the column it
   sits in, --step-tight apart. Every rail dropdown is this one wrapper; nothing sizes one by where it sits.
   Manage Account's Language is the same dropdown in an account field, at that field's width. */
.tpl-rail-dropdown{display:flex;flex-direction:column;row-gap:var(--step-tight);text-align:left;}
/* A rail dropdown's label with its action after it ($rdAction, the Respondent Theme's preview eye): one line, the label
   wrapping between its words beside the action, never the action under the label. */
.tpl-rail-dropdown-head{display:flex;align-items:center;gap:var(--gap-row);}
.tpl-rail-dropdown-head > :not(label){flex:none;}
:is(.row:not(.row-aligned) > .field, .c-fields > .c-field) > .tpl-switcher{display:flex;flex:1 1 auto;}
/* In an aligned row, a line ending in its button and a --fill field, the dropdown is as wide as its field: its chevron at its end. */
:is(.c-fields--aligned, .c-fields--action) > .c-field > .tpl-switcher > .tpl-switcher-trigger,
.c-field--fill > .tpl-switcher > .tpl-switcher-trigger{flex:1 1 auto;justify-content:space-between;}
/* A Manage dialog's dropdown field (.dlm-field, a row's field: shared-controls.css) fills it, its value at the start. */
:is(.dlm-field, .dlm-row--field) > .tpl-switcher{display:flex;text-align:left;}
:is(.dlm-field, .dlm-row--field) > .tpl-switcher > .tpl-switcher-trigger{flex:1 1 auto;justify-content:space-between;}
.date-pick:not(.is-filled) .tpl-switcher-trigger-label{color:var(--tpl-ph-color, var(--muted));}
.tpl-start .date-pick:not(.is-filled) .tpl-switcher-trigger-label{color:var(--setup-ph-color);}
@media(max-width:480px){
        /* On a phone the switcher is full-width and centred, in flow. `:not(.tpl-switcher--field)` is the rule's whole scope:
           the participant's field dropdown keeps its anchor, since nothing re-places its menu (participant-select.js). */
    .tpl-switcher:not(.tpl-switcher--field){
            position:static;
            top:auto;
            right:auto;
            text-align:center;
        }
}
/* A rail's dropdown, the template picker's included, is a column at --step-tight, the bands' step: its trigger fills the row
   and its menu is placed at the box's left edge and width (template-switcher.js). */
.tpl-start.setup-sidebar :is(.tpl-sidebar, .tpl-card-gear) .tpl-switcher:where(.tpl-rail-dropdown > .tpl-switcher){
    text-align: left;
    display: flex;
    flex-direction: column;
    --switcher-row-gap: var(--step-tight);
}
/* Two rail rows inside one band (setup-sidebar.css, EVERY ROW IS ONE ROW TALL AND RULED): the hairline between them. */
.tpl-start.setup-sidebar :where(.tpl-sidebar, .tpl-card-gear) .tpl-rail-band :where(.tpl-rail-dropdown ~ *, .tpl-rail-dropdown ~ * *):is(.tpl-rail-dropdown) {
    border-top: var(--card-border-width) solid var(--line);
}
/* THE RAIL'S ROWS ARE ONE LINE EACH: the label at the left, the value at the right in its own case, the trigger unboxed and the
   row its hit area; what a row shows under its line spans it. Label and value each one line, cut with … (the label's: shared-controls.css);
   a segmented list (Respondent Privacy, Respondent Notifications) is under its label, at the row's width. */
.tpl-start.setup-sidebar :is(.tpl-sidebar, .tpl-card-gear) .tpl-rail-dropdown{
    position: relative;
    display: grid;
    grid-template-columns: minmax(0, max-content) minmax(0, 1fr);
    align-items: center;
    column-gap: var(--gap-row);
    row-gap: 0;
    min-height: var(--size-48);
}
.tpl-start.setup-sidebar :is(.tpl-sidebar, .tpl-card-gear) :is(.tpl-rail-dropdown, .tpl-rail-dropdown-head) > label{ margin: 0; }
.tpl-start.setup-sidebar :where(:is(.tpl-sidebar, .tpl-card-gear)) .tpl-rail-dropdown > :not(label, .tpl-rail-dropdown-head, .tpl-switcher, .tpl-tags){
    grid-column: 1 / -1;
    position: relative;
    z-index: var(--layer-raised);
}
.tpl-start.setup-sidebar :is(.tpl-sidebar, .tpl-card-gear) .tpl-rail-dropdown-head > :not(label){ position: relative; z-index: var(--layer-raised); }
.tpl-start.setup-sidebar :where(:is(.tpl-sidebar, .tpl-card-gear)) .tpl-rail-dropdown > .tpl-switcher{ position: static; display: block; min-width: 0; justify-self: end; }
.tpl-start.setup-sidebar :where(.tpl-sidebar, .tpl-card-gear) .tpl-rail-dropdown .tpl-switcher-trigger-label{ text-transform: none; }
.tpl-start.setup-sidebar :where(.tpl-sidebar, .tpl-card-gear) .tpl-rail-dropdown:has(> .tpl-switcher--seg){ grid-template-columns: minmax(0, 1fr); row-gap: var(--step-tight); padding-block: var(--inset-box); }
.tpl-start.setup-sidebar :where(.tpl-sidebar, .tpl-card-gear) .tpl-rail-dropdown > .tpl-switcher--seg{ justify-self: stretch; }
.tpl-start.setup-sidebar :where(.tpl-sidebar, .tpl-card-gear) .tpl-switcher--seg-row > .tpl-switcher-menu{ display: grid; }
/* A dropdown's value reads at the tier of the label it answers, in the rails and beside a heading. Not a button's (.c-btn:
   it takes the button's type) nor a quiet dropdown's (it reads as a field label). */
.tpl-start.setup-sidebar :where(.tpl-switcher-trigger:not(.c-btn, .tpl-switcher--quiet > *)) .tpl-switcher-trigger-label{
    font-family: var(--font-heading);
    font-size: var(--caption-size-rail);
    letter-spacing: var(--tracking-2, var(--tracking-2));
    text-transform: var(--tpl-cardname-case, uppercase);
}
:where(:root[data-workspace] :is(.tpl-start, .tpl-segment-fields)) .tpl-switcher-trigger:not(.hv2-nav-acct-trigger, .c-btn, .tpl-switcher--quiet > *, .tpl-answer-cells *){min-height:var(--size-40);}
.tpl-start .tpl-type-tab--templates[aria-expanded="true"] > .tpl-switcher-trigger-chev{transform:rotate(-135deg);}
.tpl-start .tpl-templates-chooser .tpl-switcher-nomatch{padding:var(--space-24) 0;text-align:center;color:var(--muted);}
.tpl-start .tpl-setup-strip:where(#tpl-setup-strip) .tpl-strip-cell .tpl-rail-dropdown{display:flex;flex-direction:column;align-items:flex-start;gap:var(--space-8);width:100%;margin:0;padding:0;border:0;}
.tpl-start .tpl-setup-strip:where(#tpl-setup-strip) .tpl-strip-cell .tpl-switcher{width:auto;max-width:100%;}
@media (max-width: 640px){
    .tpl-start .tpl-type-tab--templates > .tpl-switcher-trigger-chev{display:none;}
    /* A phone's strip cell (setup-page.css): its caption over its cards, one row the band's width that scrolls sideways. */
    .tpl-start .tpl-setup-strip:where(#tpl-setup-strip) .tpl-strip-cell .tpl-switcher--seg-cards{width:100%;}
    .tpl-start :where(.tpl-strip-cell) .tpl-switcher--seg-cards > .tpl-switcher-menu{flex-wrap:nowrap;overflow-x:auto;scrollbar-width:none;}
}
.people-suggest > .tpl-switcher-item{display:flex;align-items:baseline;gap:var(--gap-tight);width:100%;text-align:start;}

/* THE DATE PICKER (date-picker.js): a Monday-first month in a dropdown's box (the menu's edge, corner and shadow), with
   the poll's month and year selects and arrows. template-switcher.js's overlay places it, so the rail never clips it. */
.date-pick{position:relative;min-width:0;}
.date-pick[data-anchor]{display:contents;}   /* a field-less picker: its box is its anchor, it takes no space itself */
.date-pick .date-pick-field{display:flex;width:100%;max-width:none;justify-content:space-between;}
.date-pick-panel{--shadow-popover-offset:var(--shadow-popover);width:var(--measure-280);padding:var(--inset-control);text-transform:none;letter-spacing:normal;border:var(--edge-1) solid var(--line-strong);border-radius:var(--radius-entry);box-shadow:var(--shadow-popover-offset) rgba(var(--ink-rgb),0.08);}
/* THE CALENDAR (the date picker's): the base its --pick modifiers refine, scoped to its panel too, which My Sessions shows
   outside .tpl-start. */
:is(.tpl-start, .date-pick-panel) .tpl-timedate-calnav-tools{display:flex;align-items:center;gap:var(--gap-tight);}
:is(.tpl-start, .date-pick-panel) .tpl-timedate-calsel{appearance:none;border:var(--edge-1) solid var(--line-strong);border-radius:var(--radius-control);background-color:var(--surface-field);height:var(--size-30);padding:0 var(--inset-control);cursor:pointer;}
:is(.tpl-start, .date-pick-panel) .tpl-timedate-calsel:disabled{opacity:0.4;cursor:default;}
:is(.tpl-start, .date-pick-panel) .tpl-timedate-calnav-arrow{appearance:none;border:var(--edge-1) solid var(--line-strong);background:var(--surface-field);border-radius:var(--radius-control);width:var(--size-30);height:var(--size-30);cursor:pointer;font-size:var(--type-16);line-height:var(--leading-1);color:var(--ink);display:inline-flex;align-items:center;justify-content:center;flex:0 0 auto;}
:is(.tpl-start, .date-pick-panel) .tpl-timedate-calnav-arrow:hover{background:var(--selected-ink-mode);color:var(--on-ink);}
:is(.tpl-start, .date-pick-panel) .tpl-timedate-calnav-arrow:disabled{opacity:0.3;cursor:default;}
:is(.tpl-start, .date-pick-panel) .tpl-timedate-monthdow{display:grid;grid-template-columns:repeat(7,minmax(0,1fr));gap:0;border:var(--edge-1) solid var(--line-strong);border-bottom:none;}
:is(.tpl-start, .date-pick-panel) .tpl-timedate-dow{padding:var(--space-6) var(--inset-tag);text-align:center;font-family:var(--font-mono);font-size:var(--type-10);letter-spacing:var(--tracking-8);text-transform:uppercase;color:var(--muted);background:var(--surface-warm-hover);border-right:var(--edge-1) solid var(--line);white-space:nowrap;overflow:hidden;text-overflow:ellipsis;}
:is(.tpl-start, .date-pick-panel) .tpl-timedate-dow:last-child{border-right:none;}
:is(.tpl-start, .date-pick-panel) .tpl-timedate-monthgrid{display:grid;grid-template-columns:repeat(7,minmax(0,1fr));gap:0;border:var(--edge-1) solid var(--line-strong);border-top:var(--edge-1) solid var(--line);}
:is(.tpl-start, .date-pick-panel) .tpl-timedate-mcell{display:flex;flex-direction:column;gap:var(--inset-tag);min-width:0;min-height:var(--size-104);padding:var(--space-4) var(--space-4) var(--space-6);border-right:var(--edge-1) solid var(--line);border-bottom:var(--edge-1) solid var(--line);background:var(--surface-panel);cursor:pointer;}
:is(.tpl-start, .date-pick-panel) .tpl-timedate-mcell:nth-child(7n){border-right:none;}
:is(.tpl-start, .date-pick-panel) .tpl-timedate-mcell:hover{background:var(--surface-warm-hover);}
:is(.tpl-start, .date-pick-panel) .tpl-timedate-mcell.is-out{background:var(--surface-warm-hover);cursor:pointer;}
:is(.tpl-start, .date-pick-panel) .tpl-timedate-mcell.is-out .tpl-timedate-mnum{color:var(--muted);}
:is(.tpl-start, .date-pick-panel) .tpl-timedate-mcell.is-today .tpl-timedate-mnum{background:var(--action-ink);color:var(--on-ink);}
:is(.tpl-start, .date-pick-panel) .tpl-timedate-mnum{align-self:flex-start;min-width:var(--size-22);text-align:center;font-family:var(--font-heading);font-size:var(--type-16);line-height:var(--leading-12);color:var(--ink);}
:is(.tpl-start, .date-pick-panel) .tpl-timedate-chip-time{
    width:5ch; /* literal: measure-text, a time's five characters, HH:MM, in its own face */
    max-width:none;
    min-width:0;
    border:none;border-radius:var(--radius-chip);
    background:var(--surface-field);
    font-family:var(--font-numeral);
    font-size:inherit;
    padding:var(--nudge) 0;
    text-align:center;
    color:var(--ink);
}
/* The picker: a compact month in a 280px panel — centred day numbers on 32px cells, today outlined and the
   chosen day filled, in the panel's own face; the weekday initials untracked; never the poll's phone floor
   (setup-page.css). */
:is(.tpl-start, .date-pick-panel) .tpl-timedate-calnav-tools.tpl-timedate-calnav-tools--pick{gap:var(--gap-tight);margin-bottom:var(--inset-control);}
:is(.tpl-start, .date-pick-panel) .tpl-timedate-calsel.tpl-timedate-calsel--pick{flex:1 1 auto;min-width:0;color:var(--ink);font:inherit;}
:is(.tpl-start, .date-pick-panel) :is(.tpl-timedate-monthdow, .tpl-timedate-monthgrid).tpl-timedate-cal--pick{grid-template-columns:repeat(7,minmax(0,1fr));min-width:0;}
:is(.tpl-start, .date-pick-panel) .tpl-timedate-dow.tpl-timedate-dow--pick{padding:var(--inset-tag) 0;letter-spacing:normal;border-right:none;}
:is(.tpl-start, .date-pick-panel) .tpl-timedate-mcell.tpl-timedate-mcell--pick{appearance:none;align-items:center;justify-content:center;min-height:0;height:var(--size-32);padding:0;border-top:0;border-left:0;font:inherit;}
:is(.tpl-start, .date-pick-panel) .tpl-timedate-mcell--pick .tpl-timedate-mnum{align-self:center;min-width:0;font:inherit;line-height:normal;}
:is(.tpl-start, .date-pick-panel) .tpl-timedate-calnav-arrow.tpl-timedate-calnav-arrow--pick{font-size:inherit;}
:is(.tpl-start, .date-pick-panel) .tpl-timedate-chip-time.tpl-timedate-chip-time--pick{width:var(--size-84);min-width:var(--size-84);height:var(--size-36);
    border:var(--ufield-box-edge-w, var(--control-edge-width, var(--edge-1))) solid var(--ufield-box-edge, var(--line));border-radius:var(--ufield-box-radius, var(--radius-control));}
:is(.tpl-start, .date-pick-panel) .tpl-timedate-mcell--pick.is-today .tpl-timedate-mnum{background:none;color:var(--ink);}
:is(.tpl-start, .date-pick-panel) .tpl-timedate-mcell.tpl-timedate-mcell--pick.is-today{box-shadow:inset var(--ring-1) var(--action-ink);}
:is(.tpl-start, .date-pick-panel) .tpl-timedate-mcell.tpl-timedate-mcell--pick.is-selected{background:var(--action-ink);}
:is(.tpl-start, .date-pick-panel) .tpl-timedate-mcell--pick.is-selected .tpl-timedate-mnum{color:var(--on-ink);}
:where(.tpl-start, .date-pick-panel) .tpl-timedate-mcell--pick.is-today.is-out .tpl-timedate-mnum{color:var(--muted);}
/* A day before today (date-picker.js disables it) reads as unavailable: muted on a wash, no hover, no press. */
:is(.tpl-start, .date-pick-panel) .tpl-timedate-mcell.tpl-timedate-mcell--pick:disabled{background:var(--wash);cursor:not-allowed;}
:is(.tpl-start, .date-pick-panel) .tpl-timedate-mcell--pick:disabled .tpl-timedate-mnum{color:var(--muted);}
/* The time row heads the panel, its caption at the start and its boxed field at the end; Clear alone at the foot. */
.date-pick-top{display:flex;margin-bottom:var(--inset-control);}
.date-pick-top > .date-pick-time{flex:1 1 auto;justify-content:space-between;}
.date-pick-foot{display:flex;align-items:center;justify-content:flex-end;gap:var(--gap-row);margin-top:var(--inset-control);}
.date-pick-time{display:flex;align-items:center;gap:var(--gap-tight);font-size:var(--type-12);text-transform:uppercase;color:var(--muted);}
.date-pick-clear{appearance:none;border:0;background:none;padding:0;font:inherit;font-size:var(--type-10);text-transform:uppercase;text-decoration:underline;color:var(--ink);cursor:pointer;}

/* THE EVENT SET-UP's dropdowns (event-setup.js): a contributor's Role beside their name, as wide as its value; a Questions
   dropdown in the Feedback table at --measure-160. */
.ev-dlm-head > .tpl-switcher, .ev-dlm-head .tpl-switcher-trigger{width:auto;min-width:0;}
.ev-dlm-head .tpl-switcher-trigger{gap:var(--space-4);justify-content:flex-start;}
.ev-fb-qs > .tpl-switcher{flex:none;width:var(--measure-160);}
