/*
 * Blessit pages: only Blessit's own rules, under the .bl root class. The look (fonts, tokens, light and dark,
 * Bootstrap's components) comes from the idp-theme webjar's theme.css, loaded before this file.
 */
.bl {
  display: flex;
  flex-direction: column;
  gap: var(--space-4);
}
/* .btn and the flex helpers set display, which beats the user-agent [hidden] rule */
.bl [hidden] { display: none !important; }
.bl h2 { font-size: var(--text-lg); font-weight: 600; margin: 0; }
/* Blessit's tables sit flush in their cards; Bootstrap's .table keeps a bottom margin for running text */
.bl .table { margin-bottom: 0; }
/* The page column beside the side nav may shrink below its widest table, which then scrolls in its own frame. */
.keel-page { min-width: 0; }
/* keel-theme.css keeps the 15rem side nav and 2.5rem gutters at any width. On a phone the nav is rows of links above
   the page, wrapping so every link shows; an administration section starts its own row under its heading. */
@media (max-width: 767.98px) {
  .bl-frame { flex-direction: column; }
  .bl-frame > .keel-nav {
    display: flex; flex-wrap: wrap; align-items: center; gap: 2px;
    width: auto; padding: var(--space-2) var(--space-3);
    border-right: 0; border-bottom: 1px solid var(--color-divider);
  }
  .bl-frame > .keel-nav .keel-nav__list { display: contents; }
  .bl-frame > .keel-nav .keel-nav__link { min-height: 2.25rem; white-space: nowrap; }
  .bl-frame > .keel-nav .keel-nav__section { flex-basis: 100%; min-height: 1.75rem; margin: var(--space-2) 0 0; }
  .bl-frame > .keel-page { padding-left: var(--space-4); padding-right: var(--space-4); }
  /* History's status tabs scroll in their own frame rather than widening the page. */
  .bl .segmented { max-width: 100%; overflow-x: auto; scrollbar-width: none; }
}
/* keel-theme.css frames a bare .table; in the webjar's .table-frame the frame is already there, as in a card. */
.table-frame .table { background: transparent; border: 0; border-radius: 0; }
.table-frame .table :is(th, td) { border-radius: 0; }
/* a button that shows a spinner while its htmx request runs */
.bl .btn--busy { display: inline-flex; align-items: center; gap: var(--space-2); }
.bl .btn--busy > .spinner-border.spinner-border-sm,
.bl .btn--busy > [data-busy-label] { display: none; }
.bl .btn--busy.htmx-request > .spinner-border.spinner-border-sm { display: inline-block; }
.bl .btn--busy.htmx-request > [data-busy-label] { display: inline; }
.bl .btn--busy.htmx-request > [data-busy-idle] { display: none; }

/* Blessit's own rules: zone page, folder trees, dialogs, settings. */
.bl .resource-link {color: var(--color-fg); font-weight: 600; text-decoration: none;}
.bl .resource-link:hover {text-decoration: underline;}
.bl .mono,
.bl time,
.bl code {font-family: var(--font-mono);}
/* its dropdowns open over the list below, whose folder header is sticky at z-index 10 */
.bl .toolbar {position: relative; z-index: 11; align-items: center; margin-bottom: 0;}
/* Beside a field a toolbar's filter and buttons take the field's height, as KEEL's search actions do. */
.bl .toolbar .segmented {height: 2.75rem;}
.bl .toolbar .btn {min-height: 2.75rem;}
.bl .tbl-wrap {overflow-x: auto;}
.bl .tbl-wrap .table th,
.bl .tbl-wrap .table td {white-space: nowrap;}
.bl .detail-grid {display: grid; grid-template-columns: minmax(0, 1.4fr) minmax(18rem, .7fr); gap: var(--space-5); align-items: start;}
.bl .card--compact {padding: 0;}
.bl .card--compact > .card-header {margin: 0; display: flex; align-items: center; justify-content: space-between; gap: var(--space-3); padding: var(--space-4) var(--space-5); border-bottom: 1px solid var(--color-border);}
.bl .switch-row {display: flex; align-items: flex-start; justify-content: space-between; gap: var(--space-4); padding: var(--space-3) 0; border-bottom: 1px solid var(--color-border);}
.bl .switch-row input {margin-top: .25rem;}
/* Dialogs are the webjar's native <dialog class="modal">; it spaces the header, body and footer as the dialog's own
   children, and Blessit's sit in the dialog's form. */
.bl .modal:where(dialog) > form > .modal-header {padding: 0; margin-bottom: var(--space-3);}
.bl .modal:where(dialog) > form > .modal-body {padding: 0; margin-bottom: var(--space-4);}
.bl .modal:where(dialog) > form > .modal-footer {display: flex; padding: 0;}
/* an open picker reaches past the dialog instead of scrolling inside it, as the webjar does for card bodies and tables */
.bl .modal:where(dialog):has(.ts-wrapper.dropdown-active) {overflow: visible;}
.bl .modal-body p {margin: 0;}
.bl .modal-body p + p {margin-top: var(--space-2);}
.bl .activity {display: flex; flex-direction: column;}
.bl .activity__row {display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: var(--space-3); align-items: center; padding: var(--space-3) 0; border-bottom: 1px solid var(--color-border); font-size: var(--text-sm);}
.bl .activity__row:last-child {border-bottom: 0;}
.bl .activity__row time {color: var(--color-fg-subtle); font-size: var(--text-xs); white-space: nowrap;}
.bl .cmd__body {margin: 0; padding: var(--space-3); border: 1px solid var(--color-border); background: var(--color-surface-subtle); overflow-x: auto; font: var(--text-xs)/1.6 var(--font-mono); white-space: pre;}
.bl .actions--start {justify-content: flex-start;}
@media (max-width: 1024px) {
.bl .detail-grid {grid-template-columns: 1fr;}
}
.bl .input--secret:not(.input--shown) {-webkit-text-security: disc;}
.bl .btn--busy.is-busy-now > .spinner-border.spinner-border-sm {display: inline-block;}
.bl .btn--busy.is-busy-now > [data-busy-label] {display: inline;}
.bl .btn--busy.is-busy-now > [data-busy-idle] {display: none;}
.bl .btn--busy.is-busy-now {pointer-events: none; opacity: .8;}
.bl .rtype {display: inline-block; min-width: 3.4rem; font: 600 var(--text-xs)/1 var(--font-mono);}
.bl .val {font-family: var(--font-mono); font-size: var(--text-xs); max-width: 34rem; overflow: hidden; text-overflow: ellipsis; display: inline-block; vertical-align: middle;}
.bl tr.is-added {background: color-mix(in srgb, var(--color-success-fg, #047857) 8%, transparent);}
.bl tr.is-changed {background: color-mix(in srgb, var(--color-warn-fg, #92400e) 8%, transparent);}
.bl tr.is-deleted {background: color-mix(in srgb, var(--color-danger-fg, #dc2626) 7%, transparent);}
.bl tr.is-deleted td:not(.text-end.text-nowrap) .val,
.bl tr.is-deleted td:not(.text-end.text-nowrap) code {text-decoration: line-through;}
.bl tr.is-locked td {color: var(--color-fg-muted);}
.bl .old {text-decoration: line-through; color: var(--color-fg-subtle);}
.bl .arrow {color: var(--color-fg-subtle); padding: 0 4px;}
.bl .mark {display: inline-block; width: 1.1rem; text-align: center; font: 700 var(--text-sm)/1 var(--font-mono);}
.bl .mark--add {color: var(--color-success-fg, #047857);}
.bl .mark--del {color: var(--color-danger-fg, #dc2626);}
.bl .mark--mod {color: var(--color-warn-fg, #92400e);}
.bl .draft-bar {position: sticky; bottom: 0; z-index: 10; display: flex; align-items: center; justify-content: space-between; gap: var(--space-3); padding: var(--space-3) var(--space-4); border: 1px solid var(--color-surface-inverse); background: var(--color-surface-inverse); color: var(--color-fg-inverse); font-size: var(--text-sm);}
.bl .draft-bar .btn {background: var(--color-surface); color: var(--color-fg);}
.bl .draft-bar__note {opacity: .7;}
.bl .approvers {display: flex; flex-direction: column; gap: var(--space-2);}
.bl .approver {display: grid; grid-template-columns: 1fr auto; gap: var(--space-2); align-items: center; font-size: var(--text-sm);}
.bl .log {margin: 0; padding: var(--space-3); border: 1px solid var(--color-border); background: var(--color-surface-subtle); font: var(--text-xs)/1.7 var(--font-mono); white-space: pre-wrap;}
.bl .log .ok {color: var(--color-success-fg, #047857);}
.bl .form-col {display: flex; flex-direction: column; gap: var(--space-3);}
/* A long value to copy (the Claude Code command) wraps: its box grows with it instead of the field's fixed height. */
.bl .copyable__value {height: auto; min-height: 2.75rem;}
/* KEEL's copyable field brings its own bottom margin; the column's gap spaces it here. */
.bl .form-col > .mb-3 {margin-bottom: 0 !important;}
.bl .field__err {margin-top: 4px; font-size: var(--text-xs); color: var(--color-danger-fg);}
.bl .split-grid {display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: var(--space-4);}
@media (max-width: 900px) {
.bl .split-grid,
.bl .detail-grid {grid-template-columns: 1fr;}
}
.bl .loc {flex: none; min-width: 6.5rem; padding: 0 5px; border: 1px solid var(--color-border); color: var(--color-fg-muted); background: var(--color-surface-subtle); font: 500 10px/16px var(--font-mono);}
.bl .v {display: inline-flex; align-items: center; gap: 2px;}
.bl .tbl--dns th:nth-child(1) {width: 5.5rem;}
.bl .tbl--dns th:nth-child(2) {width: 24%;}
.bl .tbl--dns th:last-child {width: 10rem;}
.bl .tbl--dns .rtype {min-width: 0; font-size: var(--text-xs);}
.bl .tbl--dns .rname {font-family: var(--font-mono);}
.bl .tbl--dns .rcontent {max-width: 0; overflow: hidden; text-overflow: ellipsis;}
.bl .tbl--dns .rcontent .val {max-width: 100%;}
.bl .tbl--dns .loc {min-width: 0;}
/* The list clips sideways (for its sticky header), so beside the side nav it has to fit: a long name, a record-count
   badge and the badges of a drafted row wrap instead of pushing the actions out of view. */
.bl .tbl-wrap .tbl--dns > tbody > tr > td:is(:nth-child(3), :last-child) {white-space: normal !important; overflow-wrap: anywhere;}
.bl .link-btn {border: 0; background: none; padding: 0; cursor: pointer; color: var(--color-accent); font: 500 var(--text-xs)/1 inherit;}
.bl .link-btn:hover {text-decoration: underline;}
/* Add and Edit show an open editor the same way: underlined, as on hover. */
.bl .link-btn[aria-expanded="true"] {text-decoration: underline;}
.bl tr.rec.is-open td {background: var(--color-surface-subtle); border-bottom-color: transparent;}
.bl tr.editor > td {padding: 0 !important; background: var(--color-surface-subtle); white-space: normal !important;}
/* The editor lines up with its row: content under the TYPE column (past the chevron cell, less the 2px edge), the buttons
   ending where the row actions end. */
.bl .ed {padding: var(--space-3) var(--space-5) var(--space-4) calc(1.6rem + var(--space-4) - 2px); display: flex; flex-direction: column; gap: var(--space-2); border-left: 2px solid var(--color-accent);}
.bl .ed[data-mode="change"] {border-left-color: var(--color-info-fg);}
.bl tr.rec.is-open > td:first-child {box-shadow: inset 2px 0 0 var(--color-info-fg);}
/* the record a save just touched: a short accent flash, then a mark that stays until the next page */
.bl tr.rec.is-saved > td {animation: saved-flash 2.4s ease-out; box-shadow: inset 0 0 0 9999px color-mix(in srgb, var(--color-accent) 6%, transparent);}
.bl tr.rec.is-saved > td:first-child {box-shadow: inset 2px 0 0 var(--color-accent), inset 0 0 0 9999px color-mix(in srgb, var(--color-accent) 6%, transparent);}
@keyframes saved-flash {from {background: color-mix(in srgb, var(--color-accent) 22%, transparent);}}
.bl [data-zone-page] > .alert a {margin-left: var(--space-2);}
.bl .ed__head {display: flex; align-items: center; gap: var(--space-2); min-width: 0;}
.bl .ed__what {overflow: hidden; color: var(--color-fg-muted); font: var(--text-xs)/1.4 var(--font-mono); text-overflow: ellipsis; white-space: nowrap;}
.bl .btn[data-ed-trigger] {box-shadow: inset 0 0 0 1px var(--color-accent-line);}
.bl .ed__grid {display: grid; grid-template-columns: 7rem minmax(8rem, 1fr) minmax(12rem, 2fr) 7rem; gap: var(--space-2); align-items: end;}
.bl .ed__grid--geo {grid-template-columns: 7rem minmax(8rem, 1fr) minmax(12rem, 2fr) 10rem 7rem;}
.bl .ed__comment .form-control {max-width: 40rem;}
/* The editor's own width decides, not the window's: the side nav and gutters take a varying share of it. One row needs
   the tracks' minimums (34rem, 44rem with Location) plus gaps and the editor's padding. */
/* A size container gets no width from its content, so it is told to fill its cell (a flex row on phones). */
.bl .ed {container-type: inline-size; width: 100%;}
@container (max-width: 40rem) {
.bl .ed__grid {grid-template-columns: 1fr 1fr;}
.bl .ed__grid .ed__content {grid-column: 1 / -1;}
}
@container (max-width: 51rem) {
.bl .ed__grid--geo {grid-template-columns: 1fr 1fr;}
.bl .ed__grid--geo .ed__content {grid-column: 1 / -1;}
}
/* A name with several records: its group row opens to them. Open, the row and its records are one block: an accent
   edge down the block, the records indented under the name. */
.bl tr.grp {cursor: pointer;}
.bl tr.grp.is-open td {border-bottom-color: transparent;}
.bl tr.grp.is-open > td:first-child,
.bl tr.rec--child > td:first-child {box-shadow: inset 3px 0 0 var(--color-accent);}
.bl tr.grp.is-open .rname {font-weight: 600;}
.bl .grp__chev {display: inline-block; color: var(--color-fg-subtle); transition: transform .15s;}
.bl tr.grp.is-open .grp__chev {transform: rotate(90deg); color: var(--color-accent);}
.bl tr.rec--child.rec--last td {border-bottom-color: var(--color-border-strong);}
.bl tr.rec--child td.ctype {padding-left: 2rem !important;}
.bl tr.rec--child .rname {color: var(--color-fg-subtle);}
.bl .grp__preview {color: var(--color-fg-muted); font: var(--text-xs)/1.3 var(--font-mono); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; display: block;}
.bl .grp__locs {font-size: var(--text-xs);}
.bl .tbl--dns th:nth-child(1),
.bl .tbl--dns td.cchev {width: 1.6rem; padding-left: var(--space-2) !important; padding-right: 0 !important; text-align: center;}
.bl .tbl--dns th:nth-child(2) {width: 5rem;}
.bl .tbl--dns th:nth-child(3) {width: 24%;}
.bl .tbl--dns td {vertical-align: middle;}
.bl .tbl--dns td > *,
.bl .tbl--dns .text-end.text-nowrap > * {vertical-align: middle;}
.bl .tbl--dns .text-end.text-nowrap {display: table-cell;}
.bl .tbl--dns .text-end.text-nowrap .link-btn + .link-btn {margin-left: 10px;}
.bl .tbl--dns {width: 100%;}
.bl .tbl--folders th:nth-child(1),
.bl .tbl--folders td.cchev {width: 1.6rem; padding-left: var(--space-2) !important; padding-right: 0 !important; text-align: center;}
.bl tr.folder {cursor: pointer;}
.bl tr.folder td {background: transparent;}
/* Open, a folder row and its body are one block, like a record group on the zone page: one accent edge,
   the zones and their changes indented under the title. Only the + ~ - mark says what a change does; the folder
   page and the draft on My requests show their tree the same way. */
.bl tr.folder.is-open td {border-bottom-color: transparent;}
.bl tr.folder.is-open > td:first-child,
.bl tr.fbody > td {box-shadow: inset 3px 0 0 var(--color-accent);}
/* The webjar's row hover is an inset shadow, which the accent edge on the first cell would replace: open, the row
   takes the same hover colour as a background so every cell, the edge one too, lights up. */
.bl :is(tr.grp, tr.folder).is-open:hover > td {--bs-table-bg-state: transparent; background: var(--color-row-hover);}
/* A long folder title, the sent time or "direct, no approval" wraps, so the list fits its frame on a laptop screen. */
.bl .tbl--folders > tbody > tr.folder > td:nth-child(2) {white-space: normal; min-width: 12rem;}
.bl .tbl--folders > tbody > tr.folder > td:is(:nth-child(7), :last-child) .text-muted {white-space: normal;}
.bl tr.fbody > td {padding: 0 !important; border-bottom: 1px solid var(--color-border-strong);}
/* The open body spans every column; zero width with a full minimum keeps its content out of the column sizing, so
   opening a folder does not move the columns. */
.bl tr.fbody > td > * {width: 0; min-width: 100%;}
.bl tr.fbody .reason--row {padding: 0 var(--space-3) var(--space-2) 2.2rem;}
.bl tr.fbody .tree {margin: 0; padding: 0 var(--space-3) var(--space-3) 2.2rem;}
.bl .tree-wrap .tree {margin: 0; padding: 0;}
.bl :is(tr.fbody, .tree-wrap) .tree__zone {padding-left: 0;}
.bl :is(tr.fbody, .tree-wrap) .tree__zone::before,
.bl :is(tr.fbody, .tree-wrap) .tree__zone::after,
.bl :is(tr.fbody, .tree-wrap) .tree__recs .tbl--inner > thead th:first-child::after,
.bl :is(tr.fbody, .tree-wrap) .tree__recs .tbl--inner tr.crow td:first-child::before,
.bl :is(tr.fbody, .tree-wrap) .tree__recs .tbl--inner tr.crow td:first-child::after {display: none;}
.bl :is(tr.fbody, .tree-wrap) .tree__head {padding: var(--space-3) 0;}
.bl :is(tr.fbody, .tree-wrap) .tree__zone + .tree__zone {margin-top: var(--space-2);}
.bl :is(tr.fbody, .tree-wrap) .tree__recs {margin-left: 0; padding-left: 0;}
.bl :is(tr.fbody, .tree-wrap) .tree__recs .tbl--inner > thead th {border-bottom-color: color-mix(in srgb, var(--color-accent) 25%, var(--color-border));}
.bl :is(tr.fbody, .tree-wrap) .tree__recs .tbl--inner tr.crow td {border-bottom-color: color-mix(in srgb, var(--color-accent) 12%, var(--color-border));}
.bl :is(tr.fbody, .tree-wrap) .tree tr:is(.is-added, .is-changed, .is-deleted) {background: transparent;}
.bl tr.folder.is-open .grp__chev {transform: rotate(90deg); color: var(--color-accent);}
.bl .folder__icon {display: inline-block; width: 14px; height: 10px; margin-right: 6px; vertical-align: -1px; border: 1.5px solid var(--color-fg-subtle); border-radius: 1px; position: relative;}
.bl .folder__icon::before {content: ""; position: absolute; left: -1.5px; top: -4px; width: 6px; height: 3px; border: 1.5px solid var(--color-fg-subtle); border-bottom: 0; border-radius: 1px 1px 0 0;}
.bl .tbl--inner {width: 100%;}
.bl .tbl--inner th,
.bl .tbl--inner td {border-top: 0;}
.bl .tbl--inner td.cchev {width: 1.6rem; text-align: center;}
.bl .tbl--inner th:nth-child(2),
.bl .tbl--inner td:nth-child(2) {width: 5rem;}
.bl .tbl--inner th:nth-child(3),
.bl .tbl--inner td:nth-child(3) {width: 24%;}
.bl .tbl--inner tr.crow td {background: transparent;}
.bl .tree {margin: 2px 0 6px 0.8rem; padding-left: 0; border-left: 1px solid color-mix(in srgb, var(--color-accent) 45%, var(--color-border));}
.bl .tree__zone {position: relative; padding-left: 1.4rem;}
.bl .tree__zone::before {content: ""; position: absolute; left: 0; top: 0.95rem; width: 1.1rem; border-top: 1px solid color-mix(in srgb, var(--color-accent) 45%, var(--color-border));}
.bl .tree__head {display: flex; align-items: center; gap: 6px; padding: 6px 0 4px; font-size: var(--text-xs);}
.bl .tree__globe {width: 10px; height: 10px; border: 1.5px solid var(--color-fg-subtle); border-radius: 50%; flex: none;}
.bl .tree__recs {position: relative; margin-left: 0.3rem; padding-left: 1.4rem; border-left: 1px dashed var(--color-border-strong); margin-bottom: 4px;}
.bl .tree__recs .tbl--inner tr.crow td {border-bottom: 1px solid var(--color-border);}
.bl .tree__recs .tbl--inner tr.crow:last-child td {border-bottom: 0;}
/* a change the sender took out of a pending folder, still shown with Restore until the page reloads */
.bl .tbl--inner tr.crow.is-removed td:not(.text-end.text-nowrap) {opacity: 0.45;}
.bl .tbl--inner tr.crow.is-removed .val {text-decoration: line-through;}
.bl .tree__recs .tbl--inner tr.crow td:first-child {position: relative;}
.bl .tree__recs .tbl--inner tr.crow td:first-child::before {content: ""; position: absolute; left: -1.4rem; top: 50%; width: 1.1rem; border-top: 1px dashed var(--color-border-strong);}
.bl .tbl--inner tr.crow td.cchev {padding-left: 1.6rem !important;}
.bl .tbl--inner tr.crow td:nth-child(2) {padding-left: 0.6rem;}
.bl .tree .tbl--inner {table-layout: fixed;}
.bl .tree .tbl--inner td:nth-child(1) {width: 1.6rem;}
.bl .tree .tbl--inner td:nth-child(2) {width: 5rem;}
.bl .tree .tbl--inner td:nth-child(3) {width: 26%;}
.bl .tree .tbl--inner td:nth-child(5) {width: 8rem;}
.bl .tree .tbl--inner td:nth-child(6) {width: 5rem;}
.bl .tree .tbl--inner td:nth-child(7) {width: 1rem;}
.bl .tree:not(.tree--edit) .tbl--inner :is(th, td):nth-child(7) {width: 11rem;}
.bl .tree:not(.tree--edit) .tbl--inner td.text-end.text-nowrap {white-space: normal; overflow-wrap: anywhere;}
.bl .tree .tbl--inner td.rcontent {overflow: hidden; text-overflow: ellipsis;}
.bl .tree .tbl--inner td:nth-child(1) {width: 1.8rem;}
.bl .tree .tbl--inner tr.crow td.cchev {padding-left: 0.4rem !important; padding-right: 0 !important;}
.bl .tree .tbl--inner td.rcontent {white-space: normal !important; overflow-wrap: anywhere;}
.bl .tree .tbl--inner td.rcontent .val {display: inline; white-space: normal; max-width: none;}
.bl .tree-wrap {padding: var(--space-2) var(--space-5) var(--space-5);}
.bl .tree-wrap .tbl--inner td:nth-child(3) {width: 16%;}
.bl .tree-wrap .tbl--inner td:nth-child(5) {width: 5.5rem;}
.bl .tree-wrap .tbl--inner td:nth-child(6) {width: 4rem;}
.bl .tbl-wrap:has(.tbl--dns),
.bl .tbl-wrap:has(.tbl--folders) {overflow-x: clip;}
/* In a card (My requests) the list takes the card as its frame: no second border inside the first. */
.bl .card > .table-frame {border: 0; border-radius: 0; background: transparent;}
.bl .tbl--dns > thead th,
.bl .tbl--folders > thead th {position: sticky; top: 2.75rem; z-index: 10; background: var(--color-surface-subtle);}
.bl tr.grp td.ctype .rtype {white-space: nowrap;}
.bl .tree .tbl--inner > thead th {height: auto; padding: 2px var(--space-2) 3px !important; border: 0; border-bottom: 1px solid var(--color-border); background: transparent; color: var(--color-fg-subtle); font: 500 9px/1.2 var(--font-mono); letter-spacing: .06em; text-transform: uppercase; position: static;}
.bl .tree .tbl--inner > thead th:first-child {width: 1.8rem;}
.bl .th-note {text-transform: none; letter-spacing: 0; opacity: .8; margin-left: 4px;}
.bl .tree .tbl--inner > thead th:nth-child(2) {width: 5rem;}
.bl .tree .tbl--inner > thead th:nth-child(3) {width: 26%;}
.bl .tree .tbl--inner > thead th:nth-child(5) {width: 8rem;}
.bl .tree .tbl--inner > thead th:nth-child(6) {width: 5rem;}
.bl .tree .tbl--inner > thead th:nth-child(7) {width: 1rem;}
.bl .tree-wrap .tbl--inner > thead th:nth-child(3) {width: 16%;}
.bl .tree-wrap .tbl--inner > thead th:nth-child(5) {width: 4.5rem;}
.bl .tree-wrap .tbl--inner > thead th:nth-child(6) {width: 4rem;}
.bl .tree {border-left: 0 !important;}
.bl .tree__zone::after {content: ""; position: absolute; left: 0; top: 0; bottom: 0; border-left: 1px solid color-mix(in srgb, var(--color-accent) 45%, var(--color-border));}
.bl .tree__zone:last-child::after {bottom: auto; height: 0.95rem;}
.bl .tree__recs {border-left: 0 !important;}
.bl .tree__recs .tbl--inner > thead th:first-child {position: relative;}
.bl .tree__recs .tbl--inner > thead th:first-child::after,
.bl .tree__recs .tbl--inner tr.crow td:first-child::after {content: ""; position: absolute; left: -1.4rem; top: 0; bottom: 0; border-left: 1px dashed var(--color-border-strong);}
.bl .tree__recs .tbl--inner tr.crow:last-child td:first-child::after {bottom: 50%;}
.bl tr.rec.is-locked td:not(.text-end.text-nowrap) > * {opacity: .5;}
.bl tr.rec.is-locked td {background: repeating-linear-gradient(135deg, transparent 0 6px, color-mix(in srgb, var(--color-fg) 3%, transparent) 6px 7px);}
.bl tr.rec.is-locked:hover td:not(.text-end.text-nowrap) > * {opacity: .8;}
.bl .agent {display: inline-flex; padding: 0 7px; border-radius: 999px; border: 1px solid color-mix(in srgb, #8b5cf6 45%, transparent); color: #7c3aed; background: color-mix(in srgb, #8b5cf6 10%, transparent); font: 500 10px/16px var(--font-mono); white-space: nowrap;}
.bl .modal-wide {--bs-modal-width: 52rem;}
.bl .key-steps {margin: 0; padding-left: 1.25rem; font-size: var(--text-sm);}
.bl .key-steps li + li {margin-top: var(--space-1);}
.bl .inline-form {display: inline; margin: 0;}
.bl .tree--edit .tbl--inner > thead th:nth-child(7),
.bl .tree--edit .tree .tbl--inner td:nth-child(7),
.bl .tree.tree--edit .tbl--inner td:nth-child(7) {width: 5.5rem;}
.bl .tree.tree--edit .tbl--inner > thead th:nth-child(7) {width: 5.5rem;}
.bl .col-check {width: 2rem;}
.bl .row-hidden > td {color: var(--color-fg-muted);}
.bl .btn[aria-disabled="true"] {opacity: .4; pointer-events: none;}
.bl .reason {margin: 0; white-space: pre-line; font-size: var(--text-sm);}
.bl .reason--row {padding: var(--space-2) var(--space-3) 0; color: var(--color-fg-muted); font-size: var(--text-xs);}
.bl .table-sub {display: block; color: var(--color-fg-subtle); font-size: var(--text-xs); white-space: normal;}
.bl .crow__why {font-style: italic;}

/* Under the KEEL sidebar the folder card is narrower than in the old app: fixed columns leave content room. */
.bl .tree-wrap .tree:not(.tree--edit) .tbl--inner :is(th, td):nth-child(7) {width: 8.5rem;}
.bl .tree-wrap {overflow-x: auto;}
.bl .tree-wrap .tbl--inner {min-width: 34rem;}
/* Beats .tbl-wrap's one-line cells: a table of descriptions wraps them. */
.bl .tbl-wrap .table.tbl--wrap td {white-space: normal;}
.bl .tbl-wrap .table.tbl--wrap td:first-child {white-space: nowrap;}
.bl .detail-grid > * {min-width: 0;}
/* The type and location filters keep their own width so search, filters and buttons share one row. */
.bl .toolbar > .form-select {width: auto; flex: 0 0 auto;}
/* A TTL ("5 min", "1 hr") stays on one line at the webjar's cell padding. */
.bl .tree .tbl--inner td:nth-child(6) {white-space: nowrap;}

/* On a phone a table's rows are cards; the fixed column widths and cell heights above are for the table layout only.
   A plain table (Zones, Settings, API) shows each cell as a line with its column's heading (data-label, set by
   blessit.js); a cell with no heading (actions) runs the full width. Folders, DNS records and changes have their own
   card below. */
@media (max-width: 767.98px) {
  .bl .table,
  .bl .table > tbody,
  .bl .table > tbody > tr,
  .bl .table > tbody > tr > td {display: block; width: auto !important; min-width: 0 !important; max-width: none; height: auto !important;}
  .bl .table {table-layout: auto;}
  .bl .table > thead {display: none;}
  .bl .tree-wrap .tbl--inner, .bl .tree-wrap {min-width: 0; overflow-x: visible;}
  .bl .table > tbody > tr {padding: var(--space-3) var(--space-4); border-bottom: 1px solid var(--color-border);}
  .bl .table > tbody > tr:last-child {border-bottom: 0;}
  .bl .table > tbody > tr > td {padding: 2px 0 !important; border: 0 !important; white-space: normal !important; overflow-wrap: anywhere; text-align: left !important;}
  .bl .table > tbody > tr > td[data-label] {display: flex; justify-content: space-between; align-items: baseline; gap: var(--space-3); text-align: right !important;}
  .bl .table > tbody > tr > td[data-label]::before {content: attr(data-label); flex: none; color: var(--color-fg-subtle); font: 500 10px/1.8 var(--font-mono); letter-spacing: .06em; text-transform: uppercase;}
  .bl .table > tbody > tr > td:last-child[data-empty] {display: none;}
  .bl .table > tbody > tr > td:last-child:has(.btn, form) {display: flex; flex-wrap: wrap; justify-content: flex-end; gap: var(--space-2); padding-top: var(--space-2) !important;}
  /* A row that holds a whole panel (an open folder, the record editor, an empty state) is not a card of its own. */
  .bl .table > tbody > tr:has(> td[colspan]) {padding: 0;}
  .bl .table > tbody > tr > td[colspan] {padding: 0 !important;}

  /* A folder: title; who sent it and its zones; changes, status and when; the buttons. */
  .bl .tbl--folders > tbody > tr.folder {display: grid; grid-template-columns: auto auto minmax(0, 1fr); align-items: center; gap: var(--space-1) var(--space-3);}
  .bl .tbl--folders > tbody > tr.folder > td {display: block; text-align: left !important;}
  .bl .tbl--folders > tbody > tr.folder > td::before {content: none;}
  .bl .tbl--folders > tbody > tr.folder > td.cchev {display: none;}
  .bl .tbl--folders > tbody > tr.folder > td:nth-child(2) {grid-column: 1 / -1;}
  .bl .tbl--folders > tbody > tr.folder > td:nth-child(3) {grid-column: 1 / 3; color: var(--color-fg-muted); font-size: var(--text-xs);}
  .bl .tbl--folders > tbody > tr.folder > td:nth-child(4) {grid-column: 3; color: var(--color-fg-muted); text-align: right !important;}
  .bl .tbl--folders > tbody > tr.folder > td:nth-child(7) {text-align: right !important;}
  .bl .tbl--folders > tbody > tr.folder > td:nth-child(8) {grid-column: 1 / -1; justify-content: flex-end;}
  /* without buttons the last cell says who approved (History, with its heading) or why you cannot (Pending) */
  .bl .tbl--folders > tbody > tr.folder > td:nth-child(8)[data-empty] {display: none;}
  .bl .tbl--folders > tbody > tr.folder > td:nth-child(8):not(:has(.btn), [data-empty]) {display: flex; justify-content: flex-end; align-items: baseline; gap: var(--space-3);}
  .bl .table.tbl--folders > tbody > tr.folder > td:nth-child(8):not(:has(.btn))[data-label]:not([data-label=""]) {justify-content: space-between;}
  .bl .table.tbl--folders > tbody > tr.folder > td:nth-child(8):not(:has(.btn))[data-label]:not([data-label=""])::before {content: attr(data-label);}

  /* A record, a record group or a change: mark, type, name and TTL on top, the value under them, then a GeoDNS
     location and the buttons. */
  .bl :is(.tbl--dns, .tbl--inner) > tbody > tr:not(:has(> td[colspan])) {display: grid; grid-template-columns: auto auto minmax(0, 1fr) auto; align-items: baseline; gap: 2px var(--space-3);}
  .bl :is(.tbl--dns, .tbl--inner) > tbody > tr:not(:has(> td[colspan])) > td {display: block; text-align: left !important;}
  .bl .table:is(.tbl--dns, .tbl--inner) > tbody > tr:not(:has(> td[colspan])) > td[data-label]::before {content: none;}
  .bl :is(.tbl--dns, .tbl--inner) > tbody > tr:not(:has(> td[colspan])) > td:nth-child(1) {grid-column: 1; grid-row: 1;}
  .bl :is(.tbl--dns, .tbl--inner) > tbody > tr:not(:has(> td[colspan])) > td:nth-child(1):not(:has(.mark)) {display: none;}
  .bl :is(.tbl--dns, .tbl--inner) > tbody > tr:not(:has(> td[colspan])) > td:nth-child(2) {grid-column: 2; grid-row: 1;}
  .bl :is(.tbl--dns, .tbl--inner) > tbody > tr:not(:has(> td[colspan])) > td:nth-child(3) {grid-column: 3; grid-row: 1;}
  .bl :is(.tbl--dns, .tbl--inner) > tbody > tr:not(:has(> td[colspan])) > td:nth-last-child(2) {grid-column: 4; grid-row: 1; text-align: right !important; white-space: nowrap !important;}
  .bl :is(.tbl--dns, .tbl--inner) > tbody > tr:not(:has(> td[colspan])) > td.rcontent {grid-column: 2 / -1; grid-row: 2; max-width: none; color: var(--color-fg-muted);}
  .bl :is(.tbl--dns, .tbl--inner) > tbody > tr:not(:has(> td[colspan])) > td:nth-child(5):not(:nth-last-child(2)) {grid-column: 2 / -1; grid-row: 3; font-size: var(--text-xs);}
  .bl :is(.tbl--dns, .tbl--inner) > tbody > tr:not(:has(> td[colspan])) > td:nth-child(5):not(:nth-last-child(2)):empty {display: none;}
  .bl :is(.tbl--dns, .tbl--inner) > tbody > tr:not(:has(> td[colspan])) > td:last-child {grid-column: 1 / -1; grid-row: 4; justify-content: flex-end;}
  .bl :is(.tbl--dns, .tbl--inner) > tbody > tr:not(:has(> td[colspan])) > td:last-child[data-empty] {display: none;}
  .bl :is(.tbl--dns, .tbl--inner) > tbody > tr:not(:has(> td[colspan])) > td:last-child:not([data-empty]) {display: flex; flex-wrap: wrap; gap: var(--space-2);}
  /* The record being edited is shaded as one card, and its editor needs no indent to line up with a TYPE column. */
  .bl .tbl--dns > tbody > tr.is-open {background: var(--color-surface-subtle);}
  .bl .tbl--dns > tbody > tr.is-open > td {background: transparent !important;}
  .bl .ed {padding: var(--space-3) var(--space-4) var(--space-4);}
  /* A group's records sit under it, indented, without the tree lines of the wide table. */
  .bl .tbl--dns > tbody > tr.rec--child {padding-left: var(--space-6, 2rem);}
  .bl .tree__recs .tbl--inner tr.crow td:first-child::after,
  .bl .tree__recs .tbl--inner > thead th:first-child::after,
  .bl .tree__zone::after {display: none;}
}
