
/* v19 recurrence/editor/template refinements */
.entry-row{grid-template-columns:minmax(0,1fr) auto auto 44px!important;align-items:center}
.entry-schedule-btn{width:auto!important;min-width:150px!important;height:44px!important;padding:0 11px!important;gap:7px!important;font-size:11px!important;font-weight:850!important;white-space:nowrap}
.entry-schedule-btn svg{width:17px!important;height:17px!important;flex:0 0 auto}
@media(max-width:900px){.entry-row{grid-template-columns:minmax(0,1fr) 44px!important}.entry-schedule-btn{grid-column:span 1;min-width:0!important}.entry-schedule-btn span{display:none}.entry-schedule-btn{width:44px!important;padding:0!important}}

/* Keep the top/text tools and bottom actions visible. Only the lane/stage area scrolls. */
.recur-modal .modal-card{height:min(92vh,920px)!important;max-height:calc(100vh - 20px)!important}
.recur-manual-scroll{flex:1 1 0!important;min-height:110px!important;overflow-y:auto!important;overflow-x:hidden!important;scrollbar-gutter:stable;padding:2px 5px 2px 1px!important}
.recur-manual-rows{display:grid!important;grid-auto-rows:max-content!important;align-content:start!important;min-height:0!important}
.v18-recur-row,.seq-stage-row,.seq-group{height:auto!important;min-height:0!important;max-height:none!important;align-self:start!important}
.v18-recur-row{padding:8px!important}
.recur-row-head{margin-bottom:6px!important}.recur-row-head-actions{display:flex;align-items:center;gap:5px}
.recur-remove-row{height:27px!important;width:29px!important;color:#d34b4b!important;border-color:rgba(211,75,75,.48)!important}
.recur-row-grid-main{display:grid!important;grid-template-columns:minmax(120px,1.3fr) 72px 104px 108px minmax(118px,1fr) 92px 104px!important;gap:6px!important;align-items:end!important}
.recur-row-grid-end{display:grid!important;grid-template-columns:minmax(130px,1fr) 110px minmax(125px,1fr) 96px!important;gap:6px!important;align-items:end!important;margin-top:6px;padding-top:6px;border-top:1px solid color-mix(in srgb,var(--border) 72%,transparent)}
.recur-calendar-target-wrap.v19-calendar-disabled{opacity:.36;pointer-events:none}
.recur-template-tools{display:grid;grid-template-columns:minmax(130px,.35fr) minmax(220px,1fr);gap:8px;margin-top:7px;flex:0 0 auto}
.recur-templates-btn{background:rgba(126,83,220,.24)!important;border-color:rgba(146,103,238,.74)!important;color:inherit!important;font-weight:900!important;min-height:36px}
#recurLoopGroupBtn{border-color:rgba(130,94,220,.62);background:rgba(116,91,201,.12)}
#recurLoopGroupBtn:not(:disabled){background:rgba(116,91,201,.24);font-weight:850}
@media(max-width:1020px){.recur-row-grid-main{grid-template-columns:repeat(4,minmax(0,1fr))!important}.recur-row-grid-end{grid-template-columns:repeat(4,minmax(0,1fr))!important}}
@media(max-width:700px){.recur-row-grid-main,.recur-row-grid-end{grid-template-columns:repeat(2,minmax(0,1fr))!important}.recur-template-tools{grid-template-columns:1fr}}

/* ChatGPT control mirrors the tutorial resource styling rather than using a purple accent. */
.recur-gpt-btn{background:var(--surface-2)!important;border:1px solid var(--border-strong)!important;color:var(--text)!important;display:inline-flex!important;align-items:center!important;gap:7px!important;font-size:10px!important;font-weight:800!important;text-decoration:none!important}
.recur-gpt-btn:hover{background:var(--surface)!important;border-color:var(--focus)!important}.recur-gpt-btn .chatgpt-official-logo{width:20px!important;height:20px!important;border-radius:5px!important;flex:0 0 auto}
#simpleRecurrenceBuilderBtn:disabled{opacity:.38;cursor:not-allowed}

/* Schedule explainer: no dash delimiter, slightly larger relative type, scales with card/global font size. */
.recur-status-sep{display:none!important}.recur-status-box{font-size:.80em!important;line-height:1.3!important;margin-left:4px!important;padding:3px 7px!important}

/* Exact one-glyph state machine. These state-specific hides outrank all older modifier rules. */
.refresh-action>span{display:none!important}
body:not(.ctrl-held):not(.alt-held):not(.shift-held) .refresh-action.refresh-action>span{display:none!important}
body:not(.ctrl-held):not(.alt-held):not(.shift-held) .refresh-action.refresh-action>.refresh-normal-icon{display:inline-flex!important}
body.ctrl-held:not(.shift-held):not(.alt-held) .refresh-action.refresh-action>span{display:none!important}
body.ctrl-held:not(.shift-held):not(.alt-held) .refresh-action.refresh-action>.refresh-catchup-icon{display:inline-flex!important}
body.ctrl-held.shift-held:not(.alt-held) .refresh-action.refresh-action>span{display:none!important}
body.ctrl-held.shift-held:not(.alt-held) .refresh-action:not(.sequential-current)>.refresh-anchor-cyan{display:inline-flex!important}
body.ctrl-held.shift-held:not(.alt-held) .refresh-action.sequential-current>.refresh-normal-icon{display:inline-flex!important}
body.ctrl-held.alt-held:not(.shift-held) .refresh-action.refresh-action>span{display:none!important}
body.ctrl-held.alt-held:not(.shift-held) .refresh-action:not(.unanchored-current):not(.sequential-current)>.refresh-anchor-red{display:inline-flex!important}
body.ctrl-held.alt-held:not(.shift-held) .refresh-action.unanchored-current:not(.sequential-current)>.refresh-anchor-green{display:inline-flex!important}
body.ctrl-held.alt-held:not(.shift-held) .refresh-action.sequential-current>.refresh-normal-icon{display:inline-flex!important}
body.alt-held:not(.ctrl-held):not(.shift-held) .refresh-action.refresh-action>span{display:none!important}
body.alt-held:not(.ctrl-held):not(.shift-held) .refresh-action.refresh-action>.refresh-edit-icon{display:inline-flex!important}
body.shift-held:not(.ctrl-held):not(.alt-held) .refresh-action.refresh-action>span,body.ctrl-held.alt-held.shift-held .refresh-action.refresh-action>span{display:none!important}
body.shift-held:not(.ctrl-held):not(.alt-held) .refresh-action.refresh-action>.refresh-archive-icon,body.ctrl-held.alt-held.shift-held .refresh-action.refresh-action>.refresh-archive-icon{display:inline-flex!important}
body.alt-held.shift-held:not(.ctrl-held) .refresh-action.refresh-action>span{display:none!important}
body.alt-held.shift-held:not(.ctrl-held) .refresh-action.refresh-action>.refresh-normal-icon{display:inline-flex!important}

/* Sequential manual selection / looping. */
.seq-stage-row.seq-selected,.seq-group.seq-selected{outline:2px solid rgba(77,143,238,.92)!important;outline-offset:1px!important;background:color-mix(in srgb,var(--surface-2) 82%,rgba(77,143,238,.28))!important}
.seq-stage-row,.seq-group-head{cursor:default}.seq-stage-head,.seq-group-head{user-select:none}

/* Saved templates */
.schedule-templates-modal .modal-card{width:min(820px,calc(100vw - 30px));height:min(78vh,760px);display:flex;flex-direction:column;overflow:hidden}
.template-filter-row{display:grid;grid-template-columns:minmax(0,1fr) auto;gap:9px;align-items:center;margin-bottom:9px}.template-type-toggle{display:grid;grid-template-columns:1fr 1fr;border:1px solid var(--border-strong);border-radius:9px;overflow:hidden}.template-type-toggle .text-btn{border:0;border-radius:0;min-width:120px}.template-type-toggle .text-btn.active{background:rgba(72,139,230,.25);box-shadow:inset 0 0 0 1px rgba(72,139,230,.68)}
.template-list{flex:1;min-height:0;overflow-y:auto;display:grid;grid-template-columns:repeat(2,minmax(0,1fr));grid-auto-rows:max-content;gap:8px;padding:2px 4px 2px 1px;align-content:start}.schedule-template-card{border:1px solid var(--border);border-radius:10px;background:var(--surface-2);padding:10px;cursor:pointer;min-height:92px}.schedule-template-card.selected{outline:2px solid rgba(72,139,230,.86);outline-offset:1px}.schedule-template-card h4{margin:0 0 4px;font-size:12px}.schedule-template-type{font-size:9px;text-transform:uppercase;letter-spacing:.05em;color:var(--muted);font-weight:850}.schedule-template-preview{font-size:10px;color:var(--muted);margin-top:7px;overflow-wrap:anywhere;line-height:1.35}.schedule-template-builtin{font-size:9px;margin-left:5px;color:#b38a19}
@media(max-width:650px){.template-filter-row,.template-list{grid-template-columns:1fr}.template-type-toggle .text-btn{min-width:0}}

/* Simple recurrence builder */
.simple-recur-builder-modal .modal-card{width:min(620px,calc(100vw - 28px));max-height:88vh;overflow:hidden;display:flex;flex-direction:column}.simple-builder-body{overflow-y:auto;display:grid;gap:0;padding-right:4px}.simple-builder-section{padding:12px 0;border-bottom:1px solid var(--border);display:grid;gap:8px}.simple-builder-heading{font-weight:900;font-size:13px}.simple-radio{display:flex;align-items:center;gap:8px;font-size:12px}.simple-radio span{color:var(--muted);font-size:10px}.simple-builder-inline{display:grid;grid-template-columns:80px minmax(150px,1fr);gap:9px;max-width:300px}.compact-number{max-width:90px}.simple-weekday-grid{display:grid;grid-template-columns:repeat(7,1fr);gap:7px}.simple-weekday-grid label{display:flex;align-items:center;gap:4px;font-size:11px}.simple-builder-grid{display:grid;grid-template-columns:130px 1fr 1fr;gap:8px}.simple-builder-until{grid-template-columns:1fr 1fr;max-width:410px}.simple-builder-warning{font-size:10px;color:#c89022;background:rgba(212,168,45,.10);border:1px solid rgba(212,168,45,.35);border-radius:8px;padding:7px 8px;line-height:1.35}
@media(max-width:620px){.simple-weekday-grid{grid-template-columns:repeat(4,1fr)}.simple-builder-grid{grid-template-columns:1fr}.simple-builder-inline{grid-template-columns:80px 1fr}}

/* Filter Includes/Excludes are always peers in the same container. */
#filterModal .filter-text-pair{grid-template-columns:minmax(0,1fr) minmax(0,1fr)!important;gap:10px!important}#filterModal .filter-text-half{width:auto!important}
