/* screens.css — part 3 of 6 of the app stylesheet.
   Holds: the security indicator and its popover, the AI triage panel, planning,
   iterations, SOC 2, notifications, sign-in.

   ORDER MATTERS. These files were cut out of a single app.css at line boundaries with the
   sequence preserved, so concatenating them in the order index.html links them reproduces the
   original byte for byte — which is what makes the cascade provably unchanged. Equal-specificity
   rules still resolve by source order, so reordering the <link> tags can change rendering.

   The names describe what ended up in each part, not a design: the original file interleaved
   the top bar, layout and per-feature rules, and moving rules to where they belong is a separate
   pass that this split exists to make possible. Palette is in theme.css, linked first. */
    /* Security indicator (CrowdStrike) */
    .cl-indicator { position: relative; }
    .cl-btn { display: inline-flex; align-items: center; gap: 7px; background: transparent; border: 1px solid var(--line);
      border-radius: 999px; padding: 5px 11px; cursor: pointer; font-family: inherit; color: var(--text); font-size: 13px; }
    .cl-btn:hover { border-color: var(--muted); }
    .cl-btn svg { color: var(--brand); }
    .cl-popover { position: absolute; top: calc(100% + 8px); right: 0; width: 300px; max-width: 90vw; max-height: 62vh;
      overflow: auto; background: var(--panel); border: 1px solid var(--line); border-radius: 12px; box-shadow: var(--shadow);
      padding: 8px; z-index: var(--z-header-pop); }
    .cl-empty { color: var(--muted); font-size: 13px; text-align: center; padding: 16px 8px; line-height: 1.6; }
    .cl-menu { display: flex; flex-direction: column; gap: 2px; }
    .cl-client { display: flex; align-items: center; justify-content: space-between; width: 100%; text-align: left;
      background: transparent; border: 0; border-radius: 8px; padding: 8px 10px; cursor: pointer; font: inherit;
      font-weight: 600; color: var(--text); }
    .cl-client:hover { background: var(--panel-2); }
    .cl-caret { color: var(--muted); transition: transform .15s ease; }
    .cl-client.open .cl-caret { transform: rotate(90deg); }
    .cl-services { display: flex; flex-direction: column; padding: 2px 0 6px 10px; }
    .cl-services[hidden] { display: none; }   /* [hidden] is otherwise overridden by display:flex */
    .cl-svc { display: block; padding: 6px 10px; border-radius: 6px; color: var(--link); text-decoration: none;
      font-size: 13px; overflow-wrap: anywhere; }
    .cl-svc:hover { background: var(--panel-2); text-decoration: underline; }
    /* Project/Milestone state picker in the card panel. Explicit background/color — a bare select
       renders white and ignores the dark theme (the same trap the modal inputs hit in 4.4.0). */
    .cd-state {
      font: inherit; font-size: 13px; padding: 3px 8px; border-radius: 999px;
      background: var(--panel-2); color: var(--text); border: 1px solid var(--line); cursor: pointer;
    }
    .cd-state:hover { border-color: var(--muted); }
    /* The Client dropdown (6.93.0) borrows `.cd-state`'s shape — same control, same panel, and the
       explicit background/color it carries for dark mode applies for the same reason. Only the width
       cap and the saving message are its own; a long client name shouldn't stretch the details grid. */
    .cd-client { max-width: 260px; }
    .cd-client-msg { margin-left: 8px; font-size: 12px; color: var(--muted); }
    /* Project Planning board. Columns scroll horizontally on narrow screens rather than squeezing to
       unreadable widths (the same overflow lesson as the main layout). */
    .ver.ver-plain { cursor: default; text-decoration: none; }
    /* Board vocabulary check (Settings > Connections) */
    .vc-note { font-size: 13px; margin: 0 0 10px; line-height: 1.5; }
    .vc-note.vc-good { color: var(--ok); }
    .vc-note.vc-warn { color: var(--warn); }
    table.vc-table { border-collapse: collapse; width: 100%; font-size: 13px; }
    table.vc-table th, table.vc-table td { text-align: left; padding: 7px 10px;
      border-bottom: 1px solid var(--line); vertical-align: middle; }
    table.vc-table thead th { color: var(--muted); font-size: 11px; text-transform: uppercase;
      letter-spacing: .04em; }
    table.vc-table tr.vc-bad td { background: var(--panel-2); }
    table.vc-table code { font-family: ui-monospace, SFMono-Regular, Menlo, monospace; font-size: .92em;
      background: var(--panel-2); padding: .05em .35em; border-radius: 4px; }
    .vc-none { color: var(--muted); font-style: italic; }
    .pill.vc-ok { background: var(--ok); color: #fff; }
    .pill.vc-err { background: var(--err); color: #fff; }
    .vc-avail { margin-top: 10px; }
    .vc-avail code { margin-right: 2px; }
    /* NinjaOne ticket actions on a card */
    .cd-mgmt-public { display: flex; align-items: center; gap: 8px; margin: 6px 0 2px;
      font-size: 12px; color: var(--muted); }
    /* Toggled by the hidden attribute; flex would otherwise override it (the recurring gotcha). */
    .cd-mgmt-public[hidden] { display: none; }
    .cd-mgmt-public input[type="checkbox"] { accent-color: var(--warn); flex: none; margin: 0; }
    .cd-mgmt-public b { color: var(--warn); font-weight: 600; }
    .cd-escalate.confirm { background: var(--warn); border-color: var(--warn); color: #fff; }
    .cd-escalate.escalated { background: var(--err); border-color: var(--err); color: #fff;
      opacity: 1; }
    /* Backlog review */
    .bl-note { font-size: 13px; color: var(--muted); margin: 0 0 12px; line-height: 1.5; }
    .bl-note strong { color: var(--text); }
    .bl-wrap { overflow-x: auto; }
    .bl-iter { white-space: nowrap; }
    .bl-age { color: var(--warn); font-size: 12px; font-variant-numeric: tabular-nums; margin-left: 6px; }
    .bl-orphan { color: var(--err); font-size: 12px; margin-left: 6px; }
    .bl-act { text-align: right; white-space: nowrap; }
    .bl-replan-row > td { background: var(--panel-2); }
    /* Toggled via the hidden attribute, so the row's own display must yield to it (§10 gotcha). */
    .bl-replan-row[hidden] { display: none; }
    .bl-replan { display: flex; flex-wrap: wrap; gap: 10px; align-items: center; padding: 4px 0; }
    .bl-replan label { display: flex; align-items: center; gap: 8px; font-size: 12px;
      font-weight: 600; color: var(--muted); }
    .bl-replan select, .bl-replan input[type="text"] { padding: 6px 8px; border: 1px solid var(--line);
      border-radius: 8px; background: var(--panel); color: var(--text); font-family: inherit;
      font-size: 13px; font-weight: 500; }
    .bl-replan .bl-reason-other { min-width: 220px; }
    .bl-replan .bl-replan-note { flex: 1; min-width: 200px; }
    .bl-replan .bl-reason-other[hidden] { display: none; }
    .bl-table tbody tr { cursor: pointer; }
    /* Iteration management */
    .it-warn { font-size: 13px; line-height: 1.5; margin: 0 0 12px; padding: 10px 12px;
      border: 1px solid var(--warn); border-radius: 10px; background: var(--panel); color: var(--text); }
    .it-note { font-size: 13px; color: var(--text); margin: 0 0 14px; line-height: 1.5; }
    .it-hint { display: block; color: var(--muted); font-size: 12px; margin-top: 3px; }
    .it-wrap { overflow-x: auto; border: 1px solid var(--line); border-radius: 12px; }
    table.it { border-collapse: collapse; width: 100%; font-size: 13px; }
    table.it th, table.it td { text-align: left; padding: 9px 12px; border-bottom: 1px solid var(--line);
      white-space: nowrap; vertical-align: middle; }
    table.it thead th { background: var(--panel-2); color: var(--muted); font-size: 11px;
      text-transform: uppercase; letter-spacing: .04em; }
    table.it tbody tr:last-child td { border-bottom: none; }
    table.it tr.it-is-cur { background: var(--panel-2); }
    .it-dates { font-variant-numeric: tabular-nums; color: var(--muted); }
    .it-undated { color: var(--warn); }
    .it-group { color: var(--muted); font-size: 11px; text-transform: uppercase; letter-spacing: .04em; }
    .pill.it-cur { background: var(--accent); color: #fff; }
    .pill.it-active { background: var(--ok); color: #fff; }
    .pill.it-past { color: var(--muted); }
    .pill.it-upcoming { color: var(--link); }
    .pill.it-undated { color: var(--warn); }
    .it-acts { display: flex; gap: 6px; align-items: center; }
    .it-acts input[type="date"] { padding: 5px 7px; border: 1px solid var(--line); border-radius: 7px;
      background: var(--panel-2); color: var(--text); font-family: inherit; font-size: 12px; }
    html[data-theme="dark"] .it-acts input[type="date"],
    html[data-theme="dark"] .it-new input[type="date"] { color-scheme: dark; }
    .it-new { margin: 18px 0 0; padding: 14px 16px; border: 1px solid var(--line); border-radius: 12px;
      background: var(--panel); }
    .it-new h3 { margin: 0 0 10px; font-size: 14px; font-weight: 700; color: var(--brand); }
    .it-new-grid { display: flex; flex-wrap: wrap; gap: 12px; }
    .it-new-grid label { display: flex; flex-direction: column; gap: 4px; font-size: 12px;
      font-weight: 600; color: var(--muted); }
    .it-new-grid input, .it-new-grid select { padding: 6px 8px; border: 1px solid var(--line);
      border-radius: 8px; background: var(--panel-2); color: var(--text); font-family: inherit;
      font-size: 13px; font-weight: 500; }
    .it-parent-note { font-size: 12px; color: var(--warn); margin: 10px 0 0; line-height: 1.45; }
    /* Toggled via the hidden attribute; the layout rules above would otherwise override it. */
    .it-parent-note[hidden] { display: none; }
    .it-new-acts { display: flex; align-items: center; gap: 12px; margin-top: 12px; }
    .it-msg { font-size: 12px; color: var(--muted); }
    .it-msg.err { color: var(--err); }
    .pl-bar { display: flex; gap: 16px; flex-wrap: wrap; align-items: center; margin-bottom: 16px; }
    .pl-f { display: flex; align-items: center; gap: 8px; color: var(--muted); font-size: 13px; }
    .pl-board { display: flex; gap: 14px; align-items: flex-start; overflow-x: auto; padding-bottom: 8px; }
    .pl-col { flex: 1 1 240px; min-width: 240px; background: var(--panel-2); border: 1px solid var(--line);
      border-radius: 12px; padding: 10px; }
    .pl-colhead { font-weight: 700; font-size: 13px; text-transform: uppercase; letter-spacing: .04em;
      color: var(--muted); display: flex; justify-content: space-between; margin-bottom: 8px; }
    .pl-count { background: var(--line); color: var(--text); border-radius: 999px; padding: 0 8px; font-weight: 600; }
    .pl-cards { display: flex; flex-direction: column; gap: 8px; }
    .pl-card { background: var(--panel); border: 1px solid var(--line); border-radius: 10px; padding: 10px;
      cursor: pointer; }
    .pl-card:hover { border-color: var(--accent); }
    .pl-title { font-size: 13px; font-weight: 600; margin-bottom: 6px; }
    .pl-meta { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; font-size: 12px; color: var(--muted); }
    .pl-hrs { margin-left: auto; font-variant-numeric: tabular-nums; }
    .pl-table { width: 100%; border-collapse: collapse; margin-top: 22px; font-size: 13px; }
    .pl-table th { text-align: left; font-size: 11px; text-transform: uppercase; letter-spacing: .05em;
      color: var(--muted); border-bottom: 1px solid var(--line); padding: 8px 10px; white-space: nowrap; }
    .pl-table td { border-bottom: 1px solid var(--line); padding: 8px 10px; vertical-align: top; }
    .pl-table tbody tr { cursor: pointer; }
    .pl-table tbody tr:hover { background: var(--panel-2); }
    .pl-link { color: var(--link); }
    .pl-notes { color: var(--muted); min-width: 120px; }
    /* Status shrinks to its pill instead of being squeezed by the Task column; the pill itself
       has no left margin here because it is the whole cell. */
    .pl-table th:first-child, .pl-table td:first-child { width: 1%; white-space: nowrap; }
    .pl-table td:first-child .pill { margin-left: 0; }
    /* SOC 2 audit discovery. Reuses the planning table shell; only the status/evidence bits differ. */
    .s2-head { display: flex; flex-wrap: wrap; gap: 6px 20px; justify-content: space-between;
      align-items: baseline; margin-bottom: 6px; font-size: 13px; }
    .s2-summary { color: var(--muted); font-size: 13px; }
    .s2-muted { color: var(--muted); }
    .s2-warn { color: var(--warn); }
    .s2-table td { vertical-align: top; }
    .s2-table .pill { margin-left: 0; }
    .pill.s2-done { color: var(--ok); border-color: var(--ok); }
    .pill.s2-todo { color: var(--muted); }
    .pill.s2-annual { color: var(--accent); border-color: var(--accent); }
    .s2-evilist { margin: 0; padding-left: 16px; color: var(--muted); }
    .s2-evilist li { margin: 0 0 2px; }
    /* Folder paths are long and shouldn't force the table wide — wrap them mid-path instead.
       The cell drops its own padding so the anchor inside can supply it and fill the whole box
       (.pl-table td out-specifies a bare class, hence the two-class selector rather than !important). */
    .s2-folder { max-width: 280px; overflow-wrap: anywhere; }
    .s2-table td.s2-folder { padding: 0; }
    /* The anchor fills the cell so the whole box is clickable, not just the text. */
    .s2-folderlink { display: block; padding: 8px 10px; color: var(--link); text-decoration: none;
      border-radius: 6px; }
    .s2-folderlink:hover { background: var(--panel-2); text-decoration: underline; }
    .s2-folderlink.s2-inline { display: inline; padding: 0; border-radius: 0; }
    .s2-ext { font-size: 11px; opacity: .75; }
    .s2-nofolder { display: block; padding: 8px 10px; cursor: help; }
    .s2-note { margin: 12px 0; padding: 10px 12px; border-radius: 10px; font-size: 13px;
      background: var(--panel-2); border: 1px solid var(--ok); color: var(--text); }
    .s2-note-warn { border-color: var(--warn); }
    .s2-errs { margin-top: 6px; color: var(--warn); }
    .s2-h { font-family: 'Quicksand', system-ui, sans-serif; color: var(--brand); font-size: 15px;
      margin: 26px 0 10px; padding-top: 16px; border-top: 1px solid var(--line); }
    .s2-setup { color: var(--muted); font-size: 14px; line-height: 1.6; max-width: 62ch; }
    .s2-setup b { color: var(--text); }
    /* Open audits: one collapsible block per quarter, open ones expanded. */
    .s2-audit { border: 1px solid var(--line); border-radius: 12px; padding: 8px 12px; margin-bottom: 8px;
      background: var(--panel-2); }
    .s2-audit > summary { cursor: pointer; display: flex; align-items: center; gap: 10px;
      flex-wrap: wrap; font-size: 14px; }
    .s2-audit > summary::-webkit-details-marker { display: none; }
    .s2-audit > summary::before { content: '\25b8'; font-size: 11px; color: var(--muted); }
    .s2-audit[open] > summary::before { content: '\25be'; }
    .s2-tasktable { margin-top: 8px; }
    .s2-del-audit { margin-left: auto; padding: 3px 9px; font-size: 12px; }
    .s2-tasktable tr { cursor: pointer; }
    .s2-tasktable tr:hover { background: var(--panel); }
    .s2-rowdone { opacity: .55; }
    .pill.s2-open { color: var(--warn); border-color: var(--warn); }
    .pill.s2-openct { color: var(--warn); border-color: var(--warn); }
    /* Catalog editor */
    .soc2cat-modal { width: min(920px, 100%); max-height: 88vh; }
    .s2-cat-bar { display: flex; align-items: center; justify-content: space-between; gap: 12px;
      flex-wrap: wrap; margin: 14px 0 10px; font-size: 13px; }
    .s2-cat-btns { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; }
    .s2-cat-actions { display: flex; gap: 8px; flex-wrap: wrap; margin-top: 16px;
      padding-top: 14px; border-top: 1px solid var(--line); }
    .s2-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 10px 14px; }
    .s2-f { display: flex; flex-direction: column; gap: 4px; font-size: 12px; color: var(--muted); }
    .s2-f.s2-wide { margin-top: 10px; }
    /* Inputs need explicit background/color or they render white and ignore the dark theme. */
    .s2-in { font: inherit; font-size: 13px; padding: 6px 9px; border-radius: 8px;
      background: var(--panel-2); color: var(--text); border: 1px solid var(--line); box-sizing: border-box;
      width: 100%; }
    .s2-in:focus { outline: none; border-color: var(--accent); }
    .s2-ta { resize: vertical; line-height: 1.45; }
    .s2-json { font-family: ui-monospace, SFMono-Regular, Menlo, monospace; font-size: 12px; }
    .s2-own { max-width: 220px; }
    .s2-ctl { border: 1px solid var(--line); border-radius: 10px; margin-bottom: 6px; background: var(--panel-2); }
    .s2-ctl > summary { cursor: pointer; padding: 8px 12px; display: flex; align-items: center;
      gap: 8px; flex-wrap: wrap; font-size: 13px; }
    .s2-ctl > summary::-webkit-details-marker { display: none; }
    .s2-ctl-n { color: var(--muted); font-variant-numeric: tabular-nums; min-width: 18px; }
    .s2-ctl-body { padding: 4px 12px 14px; }
    .s2-ctl-actions { display: flex; gap: 8px; margin-top: 12px; flex-wrap: wrap; }
    .btn-sm.danger { color: var(--err); border-color: var(--err); }
    .btn-sm.danger:hover { background: rgba(192,57,43,.10); }
    .cll-linkrow { display: flex; gap: 8px; margin-bottom: 6px; align-items: center; }
    .cll-linkrow .cll-label { flex: 0 0 38%; }
    .cll-linkrow .cll-url { flex: 1 1 auto; }
    .cll-rm { flex: 0 0 auto; border: none; background: transparent; color: var(--muted); font-size: 18px;
      line-height: 1; cursor: pointer; padding: 4px 8px; border-radius: 6px; }
    .cll-rm:hover { background: var(--line); color: var(--text); }
    #cll-rows { margin: 8px 0; }
    .cll-count { color: var(--muted); font-weight: 400; }
    #cll-saved .env-actions { display: flex; gap: 6px; }
    .cs-indicator { position: relative; }
    .cs-dot { display: inline-flex; align-items: center; gap: 7px; background: transparent; border: 1px solid var(--line); border-radius: 999px; padding: 5px 11px; cursor: pointer; font-family: inherit; }
    .cs-dot:hover { border-color: var(--muted); }
    .cs-light { width: 10px; height: 10px; border-radius: 50%; background: var(--muted); flex: 0 0 auto; }
    .cs-count { font-size: 12px; color: var(--text); font-weight: 600; }
    /* Through the tokens as of 6.70.1, not hardcoded. These were one colour for both themes, chosen for
       a dark ground: the amber measured 2.04:1 on white, which misses even the 3:1 a non-text indicator
       needs, on the light that means "a detection needs attention". The tokens give each theme a tone
       picked for its own background — deep on light, bright on dark. */
    .cs-indicator.tier-green .cs-light { background: var(--ok); }
    .cs-indicator.tier-amber .cs-light { background: var(--warn); }
    .cs-indicator.tier-red .cs-light { background: var(--err); animation: cs-pulse 1.6s ease-in-out infinite; }
    @keyframes cs-pulse {
      0%,100% { box-shadow: 0 0 0 0 color-mix(in srgb, var(--err) 55%, transparent); }
      50% { box-shadow: 0 0 0 5px color-mix(in srgb, var(--err) 0%, transparent); }
    }
    .cs-popover { position: absolute; top: calc(100% + 8px); right: 0; width: 420px; max-width: 92vw; max-height: 62vh; overflow: auto; background: var(--panel); border: 1px solid var(--line); border-radius: 12px; box-shadow: var(--shadow); padding: 16px; z-index: var(--z-header-pop); }
    .cs-pop-h { font-size: 14px; font-weight: 600; margin: 0 0 4px; }
    .cs-pop-sub { font-size: 12px; color: var(--muted); line-height: 1.5; margin: 0 0 14px; }
    /* The row STACKS: detection info on its own full-width line, actions on a line beneath it.
       It used to be one horizontal flex line, which worked while there was a single action button —
       a second one (Analyse) left the info column about 170px wide in a 380px popover, so the tier
       pill, hostname, severity, tenant and timestamp all wrapped. Giving the info the full width
       fixes that and keeps working if a third action is ever added.
       (A <button> still can't be nested inside an <a>, which is why the link isn't the whole row.) */
    .cs-det { display: flex; flex-direction: column; gap: 7px; color: inherit; border: 1px solid var(--line); border-radius: 9px; padding: 11px 13px; margin-bottom: 9px; }
    .cs-det:hover { border-color: var(--muted); background: var(--panel-2); }
    .cs-det-main { min-width: 0; text-decoration: none; color: inherit; display: block; }
    .cs-det-actions { display: flex; gap: 7px; justify-content: flex-end; }
    .cs-det-promote, .cs-det-go, .cs-det-analyse {
      flex: 0 0 auto; font: inherit; font-size: 12px; font-weight: 600; cursor: pointer;
      padding: 6px 12px; border-radius: 7px; border: 1px solid var(--line);
      background: var(--panel-2); color: var(--text); white-space: nowrap;
    }
    .cs-det-analyse:hover:not(:disabled) { border-color: var(--muted); }
    .cs-det-analyse:disabled { opacity: .6; cursor: default; }
    .cs-det-promote { border-color: var(--accent); color: var(--accent); }
    .cs-det-promote:hover:not(:disabled) { background: var(--accent); color: #fff; }
    .cs-det-promote:disabled { opacity: .6; cursor: default; }
    .cs-det-go:hover { border-color: var(--muted); }
    /* AI triage review panel: takes over the popover body while a judgement is awaiting review. */
    /* Verdict and confidence sit on one baseline but are allowed to wrap as a pair rather than the
       confidence being dragged onto its own line mid-phrase. */
    .cs-an-verdict { display: flex; align-items: baseline; flex-wrap: wrap; gap: 4px 8px; font-size: 14px; font-weight: 700; text-transform: capitalize; margin: 2px 0 10px; line-height: 1.35; }
    .cs-an-verdict.false_positive { color: var(--ok, #3fa34d); }
    .cs-an-verdict.inconclusive { color: var(--warn, #c98a1b); }
    .cs-an-verdict.true_positive { color: var(--err, #d24b4b); }
    /* The colour answers "must I act?", the label answers "what was it?". A benign true positive
       needs no action, so it reads green like a false positive; the "(benign)" in the text is what
       distinguishes them. Without a rule here it would inherit body colour and look unstyled. */
    .cs-an-verdict.true_positive_benign { color: var(--ok, #3fa34d); }
    .cs-an-conf { font-weight: 500; font-size: 12px; color: var(--muted); text-transform: none; white-space: nowrap; }
    /* The draft comment, editable. Monospaced because it is posted verbatim and the byte budget is
       tight — proportional text makes it hard to judge how close a line is to the limit. Explicit
       background/color, or it renders as a white native control in dark mode. */
    .cs-an-edit {
      width: 100%; box-sizing: border-box; resize: vertical; min-height: 150px;
      font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; font-size: 12px;
      line-height: 1.5; padding: 9px 10px; border-radius: 8px; border: 1px solid var(--line);
      background: var(--panel-2); color: var(--text);
    }
    .cs-an-edit:focus { outline: none; border-color: var(--accent); }
    .cs-an-count { font-size: 11px; color: var(--muted); text-align: right; margin-top: 4px; }
    .cs-an-count.over { color: var(--err, #c0392b); font-weight: 700; }
    .cs-an-resolve-row {
      display: flex; align-items: center; gap: 8px; margin-top: 10px;
      font-size: 12.5px; color: var(--text); cursor: pointer;
    }
    .cs-an-resolve-row input { accent-color: var(--accent); cursor: pointer; }
    /* Two columns, so "True positive" and "True positive (benign)" don't wrap into each other and read
       as one option. accent-color is what keeps the radio from rendering as a white native control on
       dark — the same rule the checkbox above needs. */
    .cs-an-disp { display: grid; grid-template-columns: 1fr 1fr; gap: 4px 10px; }
    .cs-an-disp-opt {
      display: flex; align-items: center; gap: 7px;
      font-size: 12.5px; color: var(--text); cursor: pointer;
    }
    .cs-an-disp-in { accent-color: var(--accent); cursor: pointer; }
    .cs-an-lbl { font-size: 11px; font-weight: 700; letter-spacing: .04em; text-transform: uppercase; color: var(--muted); margin: 14px 0 5px; }
    /* The disclosed payload is inspectable rather than merely promised — collapsed so it doesn't
       bury the judgement, but present so a technician can check what left the platform. */
    .cs-an-sent { margin-top: 12px; font-size: 12px; color: var(--muted); }
    .cs-an-sent summary { cursor: pointer; }
    .cs-an-sent pre { max-height: 200px; overflow: auto; background: var(--panel-2); border: 1px solid var(--line); border-radius: 7px; padding: 8px; margin: 6px 0 0; font-size: 11px; white-space: pre-wrap; word-break: break-word; }
    .cs-an-actions { display: flex; gap: 8px; margin-top: 14px; }
    .cs-an-post, .cs-an-back {
      font: inherit; font-size: 12px; font-weight: 600; cursor: pointer;
      padding: 6px 12px; border-radius: 7px; border: 1px solid var(--line);
      background: var(--panel-2); color: var(--text);
    }
    .cs-an-post { border-color: var(--accent); color: var(--accent); }
    .cs-an-post:hover:not(:disabled) { background: var(--accent); color: #fff; }
    .cs-an-post:disabled { opacity: .6; cursor: default; }
    .cs-an-back:hover { border-color: var(--muted); }
    .cs-det-top { display: flex; align-items: center; gap: 8px; margin-bottom: 5px; min-width: 0; }
    /* An over-long hostname truncates rather than pushing the tier pill onto its own line. */
    .cs-det-host { font-weight: 600; font-size: 13px; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
    .cs-det-meta { font-size: 12px; color: var(--muted); display: flex; gap: 5px 10px; flex-wrap: wrap; align-items: center; line-height: 1.5; }
    /* These are labels, not prose: a pill that breaks across two lines reads as two pills. */
    .cs-tier, .cs-sev, .cs-det-meta > span { white-space: nowrap; }
    .cs-tier { font-size: 10.5px; text-transform: uppercase; letter-spacing: .04em; border-radius: 999px; padding: 2px 8px; font-weight: 700; flex: 0 0 auto; }
    /* Tint derived from the token rather than a frozen rgba() copy of it, or the two drift apart the
       moment the token moves — and the tint stays a light-theme tint in dark mode. */
    .cs-tier.new { background: color-mix(in srgb, var(--err) 16%, transparent); color: var(--err); }
    .cs-tier.in_progress { background: color-mix(in srgb, var(--warn) 16%, transparent); color: var(--warn); }
    .cs-sev { font-size: 11px; color: var(--muted); }
    /* Severity beside the Falcon link on a promoted card's detail row. */
    .cd-det-sev { font-size: 11px; color: var(--muted); }
    /* A real banner rather than a cramped line of coloured text: it carries a full sentence (an
       unreachable tenant, or an already-analysed warning), so it gets padding and a tint and is
       allowed to wrap onto a second line without looking like an accident. */
    .cs-pop-warn {
      font-size: 12px; line-height: 1.5; color: var(--warn, #c98a2b);
      background: color-mix(in srgb, var(--warn) 10%, transparent);
      border: 1px solid color-mix(in srgb, var(--warn) 28%, transparent);
      border-radius: 8px; padding: 8px 10px; margin: 10px 0 2px;
    }
    .cs-pop-empty { color: var(--muted); font-size: 13px; padding: 10px 0; line-height: 1.5; }
    /* Header notifications bell */
    .notif-indicator { position: relative; }
    .notif-bell { position: relative; display: inline-flex; align-items: center; justify-content: center; width: 36px; height: 36px; border-radius: 50%; padding: 0; background: transparent; color: var(--muted); border: 1px solid var(--line); cursor: pointer; }
    .notif-bell:hover { color: var(--brand); border-color: var(--brand-bright); }
    .notif-count { position: absolute; top: -5px; right: -5px; min-width: 17px; height: 17px; padding: 0 4px; border-radius: 999px; background: var(--err); color: #fff; font-size: 10px; font-weight: 700; line-height: 17px; text-align: center; }
    .notif-popover { position: absolute; top: calc(100% + 8px); right: 0; width: 360px; max-width: 90vw; max-height: 62vh; overflow: auto; background: var(--panel); border: 1px solid var(--line); border-radius: 12px; box-shadow: var(--shadow); padding: 10px; z-index: var(--z-header-pop); }
    .notif-h { font-size: 14px; font-weight: 600; margin: 2px 4px 8px; }
    .notif-empty { color: var(--muted); font-size: 13px; padding: 10px 4px; }
    .notif-item { display: block; width: 100%; text-align: left; background: transparent; border: 1px solid var(--line); border-radius: 9px; padding: 9px 11px; margin-bottom: 7px; cursor: pointer; font-family: inherit; color: inherit; }
    .notif-item:hover { border-color: var(--muted); background: var(--panel-2); }
    .notif-item.unread { border-left: 3px solid var(--brand-bright); background: var(--panel-2); }
    /* Locally-logged problems. The left edge keeps its severity colour whether read or not — unlike a
       server notification, the point of one of these is that something broke, not that it is new. */
    .notif-item.local.warn { border-left: 3px solid var(--warn, #b5790a); }
    .notif-item.local.error { border-left: 3px solid var(--err, #c0392b); }
    /* A raw rejection body is reference text, not the headline: muted and monospaced so a long JSON
       payload wraps predictably and doesn't out-shout the title saying what actually failed. */
    .notif-item.local .notif-body {
      white-space: pre-wrap; word-break: break-word; color: var(--muted);
      font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; font-size: 11.5px;
      max-height: 8.5em; overflow: auto;
    }
    .notif-title { font-weight: 600; font-size: 13px; }
    .notif-sub { font-size: 12px; color: var(--muted); margin-top: 2px; }
    .notif-body { font-size: 12.5px; margin-top: 4px; line-height: 1.4; }
    .notif-when { font-size: 11px; color: var(--muted); margin-top: 4px; }
    .theme-toggle {
      width: 36px; height: 36px; border-radius: 50%; padding: 0;
      display: inline-flex; align-items: center; justify-content: center;
      background: transparent; color: var(--muted); border: 1px solid var(--line); cursor: pointer;
    }
    .theme-toggle:hover { background: var(--panel-2); color: var(--brand); border-color: var(--brand-bright); }
    .theme-toggle svg { width: 18px; height: 18px; }
    .signout {
      display: none; font-size: 13px; font-weight: 600; color: var(--brand);
      text-decoration: none; background: var(--panel-2); cursor: pointer;
      border: 1px solid var(--line); border-radius: 8px; padding: 7px 14px;
      transition: background .15s ease, color .15s ease, border-color .15s ease;
    }
    .signout:hover { background: var(--brand); color: #fff; border-color: var(--brand); }
    .signin-wrap { min-height: calc(100vh - 120px); display: grid; place-items: center; }
    .signin {
      max-width: 420px; margin: 0 auto; text-align: center;
      background: var(--panel); border: 1px solid var(--line); border-radius: 14px;
      padding: 34px 28px; box-shadow: var(--shadow);
    }
    .signin-icon { width: 64px; height: 64px; border-radius: 50%; }
    .signin h2 { font-family: 'Quicksand', system-ui, sans-serif; color: var(--brand); margin: 14px 0 6px; }
    .signin p { color: var(--muted); margin: 0 0 22px; }
    .signin-btn {
      display: inline-block; background: var(--accent); color: #fff; text-decoration: none;
      font-weight: 600; padding: 11px 22px; border-radius: 8px;
    }
    .signin-btn:hover { background: var(--accent-press); }
/* Completed-work view controls (6.97.0). Sits above the tree toolbar and borrows the Tickets bar's shape, so
   the two "pick a subset then filter" screens look like siblings. Explicit background/color on the select for
   the usual reason — a bare one renders white and ignores the dark theme. */
.closed-bar { display: flex; align-items: center; gap: 14px; flex-wrap: wrap; margin-bottom: 10px; }
.closed-window { font-size: 13px; color: var(--muted); display: flex; align-items: center; gap: 6px; }
.closed-days { font: inherit; font-size: 13px; padding: 3px 8px; border-radius: 6px;
  background: var(--panel-2); color: var(--text); border: 1px solid var(--line); cursor: pointer; }
.closed-days:hover { border-color: var(--muted); }
.closed-count { font-size: 12px; color: var(--muted); }

/* "21 of 150 in the catalog — 129 annual controls fall in other quarters" (6.98.0). Quiet but reachable: the
   number it explains is the one people came to the screen to read. */
.s2-scope { color: var(--muted); cursor: help; border-bottom: 1px dotted var(--line); }

/* SOC 2 evidence query, in the catalog editor (6.101.0). Boxed and tinted when active, because a control that
   pulls its own evidence behaves differently from one a technician collects by hand, and that should be
   visible at a glance while scrolling a 150-control catalog. */
.s2-ev { margin-top: 12px; padding: 10px 12px; border: 1px solid var(--line); border-radius: 8px; }
.s2-ev.on { border-color: var(--accent); background: var(--panel-2); }
.s2-ev-toggle { display: flex; align-items: center; gap: 8px; font-size: 13px; cursor: pointer; }
.s2-ev-toggle input { accent-color: var(--accent); }
html[data-theme="dark"] .s2-ev-toggle input { color-scheme: dark; }
.s2-ev-body { margin-top: 10px; }
.s2-ev-body[hidden] { display: none; }
.s2-in-wide { width: 100%; box-sizing: border-box; font: inherit; font-size: 13px; padding: 6px 8px;
  border: 1px solid var(--line); border-radius: 6px; background: var(--panel); color: var(--text); }
.s2-ev-note { font-size: 12px; color: var(--muted); margin: 6px 0; }
.s2-ev-note code { font-size: 11px; }
.s2-ev-msg { font-size: 12px; color: var(--muted); }
.s2-ev-q-ran { font-size: 11px; color: var(--muted); margin-top: 8px; overflow-wrap: anywhere; }
.s2-ev-csv { margin: 6px 0 0; padding: 8px; max-height: 220px; overflow: auto; font-size: 11px;
  line-height: 1.5; background: var(--panel); border: 1px solid var(--line); border-radius: 6px; }

/* One row per evidence file (6.102.0). A control routinely needs several exports, so the rows are visually
   separated — three unlabelled query boxes in a stack would be unreadable at a 150-control scale. */
.s2-ev-rows { display: flex; flex-direction: column; gap: 10px; }
.s2-ev-row { padding: 8px 10px; border: 1px solid var(--line); border-radius: 6px; background: var(--panel); }
.s2-ev-row-top { display: flex; align-items: flex-end; gap: 10px; flex-wrap: wrap; }
.s2-ev-row-top .s2-f { flex: 1 1 200px; }
.s2-ev-name { font: inherit; font-size: 13px; padding: 6px 8px; border: 1px solid var(--line);
  border-radius: 6px; background: var(--panel-2); color: var(--text); width: 100%; box-sizing: border-box; }
.s2-ev-del { flex: 0 0 auto; }
