/* ============================================================
   Protrona App — client-facing portal.

   Design tokens follow the approved concept mockup
   (bastion-client-portal-concept.html): Fitzrovia's brand accent over a
   dark-first ground, with RAG status colours kept deliberately separate
   from the accent so "needs attention" never reads as "branded".

   Calmer and lower-density than internal Bastion on purpose — this is
   read by a practice manager or an MD, not operated by an engineer.
   ============================================================ */

:root {
  /* Light theme is the baseline; dark is applied below. */
  --bg:            #f6f4f1;
  --panel:         #ffffff;
  --panel-2:       #faf8f5;
  --panel-3:       #f0ece5;
  --fg:            #1b1c20;
  --fg-muted:      #5d646d;
  --fg-dim:        #8f96a0;
  --border:        #e7e1d8;
  --border-strong: #d6cec2;

  --accent:        #FF9902;
  --accent-hover:  #f36c10;
  --accent-ink:    #b45605;   /* accent as text needs more depth on light ground */
  --accent-soft:   rgba(255, 153, 2, 0.12);

  --good:      #2f8f57;  --good-soft: rgba(47, 143, 87, 0.12);
  --warn:      #b7791f;  --warn-soft: rgba(183, 121, 31, 0.14);
  --bad:       #d1442b;  --bad-soft:  rgba(209, 68, 43, 0.12);
  --info:      #2f6fbf;  --info-soft: rgba(47, 111, 191, 0.12);

  --shadow-sm: 0 2px 8px rgba(30, 25, 15, 0.06);

  --font-sans: ui-sans-serif, -apple-system, BlinkMacSystemFont, "Segoe UI", system-ui, sans-serif;
  --font-mono: ui-monospace, "JetBrains Mono", "SF Mono", Menlo, Consolas, monospace;
}

@media (prefers-color-scheme: dark) {
  :root {
    --bg:            #0d0e10;
    --panel:         #15171a;
    --panel-2:       #1a1d22;
    --panel-3:       #232831;
    --fg:            #e7ebf0;
    --fg-muted:      #95a0aa;
    --fg-dim:        #6a727a;
    --border:        #2a2f37;
    --border-strong: #3a414b;

    --accent-ink:  #FF9902;
    --accent-soft: rgba(255, 153, 2, 0.14);

    --good:      #6cc28b;  --good-soft: rgba(108, 194, 139, 0.12);
    --warn:      #f5c252;  --warn-soft: rgba(245, 194, 82, 0.12);
    --bad:       #e8624a;  --bad-soft:  rgba(232, 98, 74, 0.12);
    --info:      #6caaeb;  --info-soft: rgba(108, 170, 232, 0.12);

    --shadow-sm: 0 2px 10px rgba(0, 0, 0, 0.30);
  }
}

* { box-sizing: border-box; }

html, body {
  margin: 0;
  padding: 0;
  background: var(--bg);
  color: var(--fg);
  font-family: var(--font-sans);
  font-size: 14px;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
}

.mono { font-family: var(--font-mono); font-variant-numeric: tabular-nums; }

/* ---------- Shell ---------- */
.shell { display: grid; grid-template-columns: 248px 1fr; min-height: 100vh; }

.side {
  background: var(--panel);
  border-right: 1px solid var(--border);
  display: flex; flex-direction: column;
  padding: 20px 0 14px;
  position: sticky; top: 0; height: 100vh;
}
.side-brand { display: flex; align-items: center; gap: 11px; padding: 0 20px 16px; }
.brand-mark {
  width: 30px; height: 30px; border-radius: 8px; flex: none;
  display: grid; place-items: center;
  background: linear-gradient(140deg, #FF9902, #f36c10);
  box-shadow: 0 4px 12px rgba(243, 108, 16, 0.35);
}
.brand-mark svg { width: 17px; height: 17px; color: #1a1300; }
.brand-text { display: flex; flex-direction: column; line-height: 1.15; }
.brand-name { font-weight: 700; font-size: 15px; letter-spacing: -0.01em; }
.brand-sub  { font-size: 10.5px; color: var(--fg-muted); letter-spacing: 0.04em; }

.side-client {
  margin: 4px 12px 8px; padding: 11px 12px;
  border: 1px solid var(--border); border-radius: 10px;
  background: var(--panel-2);
  display: flex; align-items: center; gap: 10px;
}
.client-badge {
  width: 30px; height: 30px; border-radius: 8px; flex: none;
  display: grid; place-items: center;
  font-weight: 700; font-size: 12px; color: #fff; background: #3b4b63;
}
.client-name { font-weight: 600; font-size: 13px; }
.client-dom  { font-size: 11px; color: var(--fg-muted); }

.side-label {
  font-size: 10px; text-transform: uppercase; letter-spacing: 0.1em;
  color: var(--fg-dim); padding: 10px 22px 4px; font-weight: 600;
}
.side-nav { display: flex; flex-direction: column; padding: 0 12px; gap: 2px; }
.nav-item {
  display: flex; align-items: center; gap: 11px;
  padding: 9px 12px; border-radius: 8px;
  color: var(--fg-muted); text-decoration: none;
  font-size: 13.5px;
  transition: background .12s, color .12s;
}
.nav-item svg { width: 17px; height: 17px; flex: none; }
.nav-item:hover { background: var(--panel-2); color: var(--fg); }
.nav-item.active { background: var(--accent-soft); color: var(--accent-ink); font-weight: 600; }
.nav-badge {
  margin-left: auto; font-size: 11px; font-weight: 600;
  min-width: 18px; height: 18px; padding: 0 5px; border-radius: 9px;
  display: inline-flex; align-items: center; justify-content: center;
  background: var(--bad-soft); color: var(--bad);
}

.side-foot {
  margin-top: auto; padding: 14px 20px 0;
  border-top: 1px solid var(--border);
  font-size: 11px; color: var(--fg-muted); line-height: 1.5;
}
.side-foot strong { color: var(--fg); font-weight: 600; }

.main { min-width: 0; display: flex; flex-direction: column; }
.topbar {
  display: flex; align-items: center; gap: 14px;
  padding: 20px 34px 18px;
  border-bottom: 1px solid var(--border);
}
.crumb {
  font-size: 11px; text-transform: uppercase; letter-spacing: 0.09em;
  color: var(--fg-muted); font-family: var(--font-mono); margin-bottom: 3px;
}
.topbar h1 { margin: 0; font-size: 21px; font-weight: 600; letter-spacing: -0.015em; text-wrap: balance; }
.topbar-right { margin-left: auto; display: flex; align-items: center; gap: 12px; }
.checked { font-size: 12px; color: var(--fg-muted); white-space: nowrap; }
.body { padding: 26px 34px 60px; }

/* Operator impersonation must never be quiet. */
.viewas-banner {
  display: flex; align-items: center; gap: 10px;
  padding: 10px 34px;
  background: var(--warn-soft);
  border-bottom: 1px solid var(--warn);
  color: var(--warn);
  font-size: 13px; font-weight: 600;
}
.viewas-banner svg { width: 16px; height: 16px; flex: none; }
.viewas-banner .reason { font-weight: 400; color: var(--fg-muted); }

/* ---------- Primitives ---------- */
.lede { font-size: 15.5px; color: var(--fg-muted); max-width: 68ch; margin: 0 0 22px; line-height: 1.55; }
.lede strong { color: var(--fg); font-weight: 600; }

.section-h {
  font-size: 11px; text-transform: uppercase; letter-spacing: 0.09em;
  color: var(--fg-muted); font-weight: 600; margin: 30px 0 12px;
  display: flex; align-items: center; gap: 10px;
}
.section-h:first-child { margin-top: 0; }
.section-h .rule { flex: 1; height: 1px; background: var(--border); }

.card { background: var(--panel); border: 1px solid var(--border); border-radius: 14px; padding: 20px 22px; }
.grid { display: grid; gap: 16px; }
.grid-2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }

.pill {
  display: inline-flex; align-items: center; gap: 6px;
  padding: 3px 10px; border-radius: 999px;
  font-size: 12px; font-weight: 600; white-space: nowrap;
}
.pill .dot { width: 7px; height: 7px; border-radius: 50%; }
.pill.ok   { background: var(--good-soft); color: var(--good); } .pill.ok .dot   { background: var(--good); }
.pill.warn { background: var(--warn-soft); color: var(--warn); } .pill.warn .dot { background: var(--warn); }
.pill.bad  { background: var(--bad-soft);  color: var(--bad);  } .pill.bad .dot  { background: var(--bad); }
.pill.info { background: var(--info-soft); color: var(--info); } .pill.info .dot { background: var(--info); }
.pill.neutral { background: var(--panel-3); color: var(--fg-muted); } .pill.neutral .dot { background: var(--fg-dim); }

/* ---------- Hero ---------- */
.hero {
  display: grid; grid-template-columns: auto 1fr; gap: 26px; align-items: center;
  background: var(--panel); border: 1px solid var(--border);
  border-radius: 16px; padding: 24px 26px; margin-bottom: 22px;
  position: relative; overflow: hidden;
}
.hero::after {
  content: ""; position: absolute; right: -60px; top: -60px;
  width: 240px; height: 240px; border-radius: 50%;
  background: radial-gradient(circle, rgba(255, 153, 2, 0.10), transparent 70%);
  pointer-events: none;
}
.gauge { position: relative; width: 132px; height: 132px; flex: none; }
.gauge svg { transform: rotate(-90deg); }
.gauge-center { position: absolute; inset: 0; display: flex; flex-direction: column; align-items: center; justify-content: center; }
.gauge-num { font-size: 34px; font-weight: 700; font-family: var(--font-mono); letter-spacing: -0.02em; }
.gauge-lab { font-size: 10.5px; text-transform: uppercase; letter-spacing: 0.08em; color: var(--fg-muted); margin-top: 1px; }
.hero-copy h2 { margin: 0 0 6px; font-size: 22px; font-weight: 700; letter-spacing: -0.02em; text-wrap: balance; }
.hero-copy p  { margin: 0 0 14px; color: var(--fg-muted); font-size: 14.5px; max-width: 60ch; }
.hero-tags { display: flex; flex-wrap: wrap; gap: 8px; }

/* ---------- Service tiles (entitlement-driven upsell) ---------- */
.svc-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 14px; }
.svc {
  background: var(--panel); border: 1px solid var(--border);
  border-radius: 14px; padding: 15px 16px 14px 18px;
  display: flex; flex-direction: column; gap: 8px;
  position: relative; overflow: hidden;
}
.svc::before { content: ""; position: absolute; left: 0; top: 0; bottom: 0; width: 3px; }
.svc[data-on="true"]::before  { background: var(--good); }
.svc[data-on="false"]::before { background: var(--bad); }
.svc-top { display: flex; align-items: center; justify-content: space-between; gap: 8px; }
.svc-ic { width: 32px; height: 32px; border-radius: 9px; display: grid; place-items: center; flex: none; }
.svc-ic svg { width: 17px; height: 17px; }
.svc[data-on="true"] .svc-ic  { background: var(--good-soft); color: var(--good); }
.svc[data-on="false"] .svc-ic { background: var(--bad-soft);  color: var(--bad); }
.svc-name { font-weight: 600; font-size: 13.5px; }
.svc-desc { font-size: 12px; color: var(--fg-muted); line-height: 1.45; }
.svc-foot { margin-top: auto; padding-top: 6px; }
.svc-detail { font-size: 12px; color: var(--fg-muted); line-height: 1.4; }
.svc-detail .mono { color: var(--fg); }

/* ---------- Summary tiles ---------- */
.tiles { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 16px; }
.tile {
  background: var(--panel); border: 1px solid var(--border);
  border-radius: 14px; padding: 16px 18px;
  display: flex; flex-direction: column; gap: 6px;
  text-decoration: none; color: inherit;
  transition: border-color .12s, transform .12s, box-shadow .12s;
}
.tile:hover { border-color: var(--border-strong); transform: translateY(-2px); box-shadow: var(--shadow-sm); }
.tile-ic { width: 30px; height: 30px; border-radius: 8px; display: grid; place-items: center; flex: none; }
.tile-ic svg { width: 16px; height: 16px; }
.tile-ic.ok { background: var(--good-soft); color: var(--good); }
.tile-ic.warn { background: var(--warn-soft); color: var(--warn); }
.tile-ic.bad { background: var(--bad-soft); color: var(--bad); }
.tile-ic.accent { background: var(--accent-soft); color: var(--accent-ink); }
.tile-num { font-size: 30px; font-weight: 700; font-family: var(--font-mono); letter-spacing: -0.02em; line-height: 1.05; }
.tile-num small { font-size: 15px; color: var(--fg-muted); font-weight: 500; }
.tile-lab { font-size: 12px; color: var(--fg-muted); font-weight: 500; }
.tile-sub { font-size: 12.5px; color: var(--fg-muted); margin-top: auto; }

/* ---------- Attention list ---------- */
.attn-row { display: flex; align-items: center; gap: 14px; padding: 14px 4px; border-bottom: 1px solid var(--border); }
.attn-row:last-child { border-bottom: 0; }
.sev { width: 4px; align-self: stretch; border-radius: 3px; flex: none; min-height: 34px; }
.sev.bad { background: var(--bad); } .sev.warn { background: var(--warn); } .sev.info { background: var(--info); }
.attn-main { flex: 1; min-width: 0; }
.attn-title { font-weight: 600; font-size: 14px; }
.attn-desc { font-size: 12.5px; color: var(--fg-muted); margin-top: 2px; }

/* ---------- Certification snapshot ---------- */
.comp-item + .comp-item { margin-top: 16px; }
.comp-item-top { display: flex; align-items: baseline; justify-content: space-between; margin-bottom: 8px; }
.comp-item-name { font-weight: 600; font-size: 13.5px; }
.comp-item-pct { font-family: var(--font-mono); font-weight: 700; font-size: 14px; }
.track { height: 8px; border-radius: 5px; background: var(--panel-3); overflow: hidden; }
.track > span { display: block; height: 100%; border-radius: 5px; }
.comp-item-foot { margin-top: 8px; font-size: 12px; color: var(--fg-muted); }

/* ---------- Empty / onboarding states ---------- */
.empty {
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  gap: 12px; padding: 56px 24px; text-align: center; color: var(--fg-muted);
}
.empty-icon { width: 40px; height: 40px; color: var(--fg-dim); }
.empty h2 { margin: 0; font-size: 18px; font-weight: 600; color: var(--fg); }
.empty p { margin: 0; max-width: 52ch; line-height: 1.55; }

@media (max-width: 1080px) {
  .tiles, .svc-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .grid-2 { grid-template-columns: 1fr; }
}
@media (max-width: 860px) {
  .shell { grid-template-columns: 1fr; }
  .side { position: static; height: auto; }
  .side-nav { display: grid; grid-template-columns: repeat(2, 1fr); }
  .hero { grid-template-columns: 1fr; text-align: center; }
  .gauge { margin: 0 auto; }
  .tiles, .svc-grid { grid-template-columns: 1fr; }
  .body, .topbar { padding-left: 20px; padding-right: 20px; }
}

/* ============================================================
   Components for the detail pages (Devices, Accounts, Email,
   Recommendations, Compliance, Settings). Shared so every page
   speaks the same visual language as the Overview.
   ============================================================ */

/* ---------- Three-state summary row (supported / soon / out of support) ---------- */
.statline { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; margin-bottom: 8px; }
.stat { background: var(--panel); border: 1px solid var(--border); border-radius: 14px; padding: 18px 20px; }
.stat.ok   { border-color: rgba(108,194,139,0.35); }
.stat.warn { border-color: rgba(245,194,82,0.35); }
.stat.bad  { border-color: rgba(232,98,74,0.35); }
.stat-num { font-size: 40px; font-weight: 700; font-family: var(--font-mono); line-height: 1; letter-spacing: -0.02em; }
.stat.ok .stat-num   { color: var(--good); }
.stat.warn .stat-num { color: var(--warn); }
.stat.bad .stat-num  { color: var(--bad); }
.stat-name { font-weight: 600; font-size: 13.5px; margin-top: 8px; }
.stat-desc { font-size: 12.5px; color: var(--fg-muted); margin-top: 3px; }
.stat-top { margin-bottom: 10px; }

/* ---------- Plain-language row list (devices needing action, etc.) ---------- */
.row-item { display: grid; grid-template-columns: 1fr auto; gap: 12px; align-items: center; padding: 13px 4px; border-bottom: 1px solid var(--border); }
.row-item:last-child { border-bottom: 0; }
.row-name { font-weight: 600; font-size: 13.5px; }
.row-meta { font-size: 12px; color: var(--fg-muted); margin-top: 2px; font-family: var(--font-mono); }
.row-guide { font-size: 12.5px; color: var(--fg-muted); margin-top: 3px; }
.row-guide b { color: var(--fg); font-weight: 600; }

/* ---------- Key/value list (sign-in protection, etc.) ---------- */
.kv-row { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 12px 2px; border-bottom: 1px solid var(--border); }
.kv-row:last-child { border-bottom: 0; }
.kv-label { font-size: 13.5px; }
.kv-label .sub { display: block; font-size: 12px; color: var(--fg-muted); margin-top: 2px; }

/* ---------- Donut (MFA coverage) ---------- */
.donutwrap { display: flex; align-items: center; gap: 22px; }
.donut { position: relative; width: 116px; height: 116px; flex: none; }
.donut svg { transform: rotate(-90deg); }
.donut-c { position: absolute; inset: 0; display: flex; flex-direction: column; align-items: center; justify-content: center; }
.donut-c .n { font-size: 26px; font-weight: 700; font-family: var(--font-mono); }
.donut-c .l { font-size: 10px; text-transform: uppercase; letter-spacing: 0.06em; color: var(--fg-muted); }
.legend { display: flex; flex-direction: column; gap: 10px; }
.legend-row { display: flex; align-items: center; gap: 9px; font-size: 13px; }
.legend-row .sw { width: 10px; height: 10px; border-radius: 3px; flex: none; }
.legend-row b { font-family: var(--font-mono); }

/* ---------- Person chips ---------- */
.userchip { display: inline-flex; align-items: center; gap: 8px; padding: 6px 10px 6px 6px; border-radius: 999px; background: var(--panel-2); border: 1px solid var(--border); font-size: 12.5px; margin: 0 8px 8px 0; }
.userchip .av { width: 22px; height: 22px; border-radius: 50%; background: var(--info-soft); color: var(--info); display: grid; place-items: center; font-size: 10px; font-weight: 700; }

/* ---------- Email domain checks ---------- */
.domain-head { display: flex; align-items: center; gap: 12px; margin-bottom: 14px; }
.domain-name { font-weight: 600; font-size: 15px; font-family: var(--font-mono); }
.checks { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; }
.check { border: 1px solid var(--border); border-radius: 10px; padding: 12px 14px; background: var(--panel-2); }
.check-top { display: flex; align-items: center; justify-content: space-between; gap: 8px; margin-bottom: 5px; }
.check-name { font-weight: 600; font-size: 12.5px; }
.check-desc { font-size: 11.5px; color: var(--fg-muted); line-height: 1.45; }
.cico { width: 20px; height: 20px; border-radius: 50%; display: grid; place-items: center; flex: none; }
.cico svg { width: 12px; height: 12px; }
.cico.ok { background: var(--good-soft); color: var(--good); }
.cico.warn { background: var(--warn-soft); color: var(--warn); }
.cico.bad { background: var(--bad-soft); color: var(--bad); }

/* ---------- Recommendations ---------- */
.rec { background: var(--panel); border: 1px solid var(--border); border-radius: 14px; padding: 16px 18px; margin-bottom: 12px; }
.rec-head { display: flex; align-items: flex-start; gap: 14px; }
.rec-ic { width: 36px; height: 36px; border-radius: 10px; display: grid; place-items: center; flex: none; }
.rec-ic svg { width: 18px; height: 18px; }
.rec-ic.quick { background: var(--good-soft); color: var(--good); }
.rec-ic.project { background: var(--info-soft); color: var(--info); }
.rec-main { flex: 1; min-width: 0; }
.rec-title { font-weight: 600; font-size: 14.5px; }
.rec-why { font-size: 13px; color: var(--fg-muted); margin-top: 4px; line-height: 1.5; max-width: 72ch; }
.rec-tags { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 11px; align-items: center; }
.tag { display: inline-flex; align-items: center; gap: 5px; font-size: 11.5px; font-weight: 600; padding: 3px 9px; border-radius: 6px; background: var(--panel-3); color: var(--fg-muted); }
.tag .lbl { color: var(--fg-dim); font-weight: 500; }
.tag.impact-high { background: var(--bad-soft); color: var(--bad); }
.tag.impact-med { background: var(--warn-soft); color: var(--warn); }
.rec-action { flex: none; align-self: center; }
.bucket-note { display: flex; align-items: flex-start; gap: 11px; background: var(--panel-2); border: 1px solid var(--border); border-radius: 12px; padding: 13px 15px; margin-bottom: 14px; font-size: 13px; color: var(--fg-muted); line-height: 1.5; }
.bucket-note svg { width: 17px; height: 17px; flex: none; margin-top: 1px; color: var(--accent-ink); }
.bucket-note b { color: var(--fg); font-weight: 600; }

/* ---------- Buttons ---------- */
.btn { display: inline-flex; align-items: center; gap: 7px; padding: 8px 14px; border-radius: 9px; cursor: pointer; font: inherit; font-size: 12.5px; font-weight: 600; white-space: nowrap; border: 1px solid var(--border); background: var(--panel-2); color: var(--fg); text-decoration: none; transition: background .12s, border-color .12s; }
.btn:hover { background: var(--panel-3); border-color: var(--border-strong); }
.btn svg { width: 14px; height: 14px; }
.btn.primary { background: var(--accent); border-color: var(--accent); color: #1a1300; }
.btn.primary:hover { background: var(--accent-hover); border-color: var(--accent-hover); color: #fff; }
.btn:disabled { opacity: 0.55; cursor: default; }

/* ---------- Compliance ---------- */
.subtabs { display: flex; gap: 4px; border-bottom: 1px solid var(--border); margin-bottom: 22px; }
.subtab { background: transparent; border: 0; border-bottom: 2px solid transparent; padding: 10px 14px 11px; margin-bottom: -1px; font: inherit; font-size: 13.5px; font-weight: 600; color: var(--fg-muted); text-decoration: none; display: inline-flex; align-items: center; gap: 8px; }
.subtab:hover { color: var(--fg); }
.subtab.active { color: var(--fg); border-bottom-color: var(--accent); }
.subtab .mini { font-size: 11px; font-weight: 700; padding: 1px 7px; border-radius: 999px; background: var(--panel-3); color: var(--fg-muted); }
.advisory { display: flex; align-items: flex-start; gap: 12px; background: var(--info-soft); border: 1px solid rgba(47,111,191,0.25); border-radius: 12px; padding: 14px 16px; margin: 18px 0 22px; font-size: 13px; line-height: 1.55; }
.advisory svg { width: 18px; height: 18px; flex: none; margin-top: 1px; color: var(--info); }
.advisory b { font-weight: 600; }
.soon-tag { font-size: 11px; font-weight: 600; color: var(--fg-muted); background: var(--panel-3); border-radius: 999px; padding: 3px 10px; }

/* ---------- Settings ---------- */
.set-row { display: flex; align-items: center; gap: 16px; padding: 15px 2px; border-bottom: 1px solid var(--border); }
.set-row:last-child { border-bottom: 0; }
.set-main { flex: 1; min-width: 0; }
.set-name { font-weight: 600; font-size: 13.5px; }
.set-desc { font-size: 12.5px; color: var(--fg-muted); margin-top: 2px; line-height: 1.45; }
.intg-grid { display: grid; grid-template-columns: repeat(2, minmax(0,1fr)); gap: 12px; }
.intg { display: flex; align-items: center; gap: 13px; background: var(--panel); border: 1px solid var(--border); border-radius: 12px; padding: 14px 16px; }
.intg-logo { width: 40px; height: 40px; border-radius: 10px; flex: none; display: grid; place-items: center; color: #fff; font-weight: 700; font-size: 12px; }
.intg-main { flex: 1; min-width: 0; }
.intg-name { font-weight: 600; font-size: 13.5px; }
.intg-cat { font-size: 12px; color: var(--fg-muted); margin-top: 1px; }

/* ---------- Confirmation banner (after an enquiry is raised) ---------- */
.confirm { display: flex; align-items: flex-start; gap: 12px; background: var(--good-soft); border: 1px solid rgba(108,194,139,0.35); border-radius: 12px; padding: 14px 16px; margin-bottom: 18px; font-size: 13px; line-height: 1.5; }
.confirm svg { width: 18px; height: 18px; flex: none; margin-top: 1px; color: var(--good); }
.confirm b { font-weight: 600; }

@media (max-width: 1080px) {
  .statline, .checks, .intg-grid { grid-template-columns: 1fr; }
}

/* ---------- Signed-out / bare pages ---------- */
.bare { min-height: 100vh; display: grid; place-items: center; padding: 32px 20px; background: var(--bg); }
.bare-panel { width: 100%; max-width: 420px; background: var(--panel); border: 1px solid var(--border); border-radius: 18px; padding: 34px 34px 28px; box-shadow: var(--shadow-sm); }
.bare-brand { display: flex; align-items: center; gap: 11px; margin-bottom: 26px; }
.bare-panel h1 { font-size: 22px; margin: 0 0 8px; letter-spacing: -0.3px; }
.bare-lede { font-size: 13.5px; color: var(--fg-muted); line-height: 1.55; margin: 0 0 22px; }
.bare-cta { width: 100%; justify-content: center; padding: 11px 14px; font-size: 13.5px; }
.bare-foot { font-size: 12px; color: var(--fg-dim); line-height: 1.5; margin: 22px 0 0; padding-top: 18px; border-top: 1px solid var(--border); }
.bare-foot strong { color: var(--fg-muted); font-weight: 600; }

.side-signout { color: var(--fg-dim); text-decoration: none; border-bottom: 1px solid var(--border-strong); }
.side-signout:hover { color: var(--fg); }

/* ---------- Operator back-office forms ---------- */
.admin-form { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px 16px; align-items: end; }
.field { display: flex; flex-direction: column; gap: 6px; min-width: 0; }
.field-label { font-size: 12px; font-weight: 600; color: var(--fg-muted); }
.field-label .opt { font-weight: 500; color: var(--fg-dim); }
.input { width: 100%; padding: 9px 12px; border-radius: 9px; border: 1px solid var(--border); background: var(--panel-2); color: var(--fg); font: inherit; font-size: 13px; }
.input:focus { outline: 2px solid var(--accent-soft); border-color: var(--accent); }
.field-actions { grid-column: 1 / -1; display: flex; justify-content: flex-end; }
.row-actions { display: flex; align-items: center; gap: 10px; flex: none; }
.pill.neutral { background: var(--panel-3); color: var(--fg-muted); }
.pill.neutral .dot { background: var(--fg-dim); }

/* ---------- Connecting a client's Microsoft 365 tenant ---------- */
/* Two side-by-side panels, because the operator is choosing between two ways to spend one link
   and a stacked list would read as a sequence of steps instead. */
.connect-panel { margin-top: 14px; padding: 16px 18px; border: 1px solid var(--border); border-radius: 12px; background: var(--panel-2); }
.connect-paths { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; }
.connect-path { display: flex; flex-direction: column; gap: 10px; min-width: 0; padding: 14px 16px; border: 1px solid var(--border); border-radius: 10px; background: var(--panel); }
.connect-path-h { display: flex; align-items: center; gap: 9px; font-size: 13px; font-weight: 600; }
.connect-path p { margin: 0; font-size: 12.5px; line-height: 1.55; color: var(--fg-muted); }
.connect-path p b { color: var(--fg); font-weight: 600; }
.connect-path > .btn { align-self: flex-start; margin-top: auto; }
.copy-row { display: flex; gap: 8px; align-items: center; margin-top: auto; }
.copy-row .input { font-size: 12px; }

@media (max-width: 860px) {
  .admin-form { grid-template-columns: 1fr; }
  .connect-paths { grid-template-columns: 1fr; }
}
