:root {
  --bg: #f4f6f4;
  --panel: #ffffff;
  --panel-soft: #eef3f5;
  --ink: #15211f;
  --muted: #60706c;
  --line: #dce4e1;
  --green: #1f8a5b;
  --green-soft: #dff3ea;
  --amber: #b46c00;
  --amber-soft: #fff0d6;
  --red: #a3130b;
  --red-soft: #ffd4cf;
  --red-strong: #c1121f;
  --blue: #246b91;
  --blue-soft: #dff0f7;
  --shadow: 0 16px 40px rgba(32, 45, 43, 0.08);
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  min-height: 100vh;
  background: var(--bg);
  color: var(--ink);
  font-family: "Segoe UI", Arial, sans-serif;
}

body.is-busy,
body.is-busy * {
  cursor: wait !important;
}

button,
input,
select {
  font: inherit;
}

.app-shell {
  display: grid;
  grid-template-columns: 250px minmax(0, 1fr);
  min-height: 100vh;
}

body.session-locked .app-shell {
  display: block;
}

body.session-locked .sidebar,
body.session-locked .topbar,
body.session-locked .page-view {
  display: none !important;
}

body.session-locked:not(.session-refreshing) #refreshProgress {
  display: none !important;
}

body.session-locked main {
  display: grid;
  min-height: 100vh;
  place-items: center;
  padding: 28px;
}

body.session-refreshing main {
  align-content: center;
  gap: 16px;
}

.sidebar {
  position: sticky;
  top: 0;
  height: 100vh;
  background: #17211f;
  color: #fff;
  padding: 24px 18px;
  overflow-y: auto;
}

.brand {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 34px;
}

.brand-logo-wrap {
  display: grid;
  width: 58px;
  height: 42px;
  place-items: center;
  border-radius: 8px;
  background: #fff;
  padding: 5px;
}

.brand-logo {
  display: block;
  max-width: 100%;
  max-height: 100%;
  object-fit: contain;
}

.brand strong,
.brand > div span {
  display: block;
}

.brand > div span {
  color: #b8c6c2;
  font-size: 13px;
  margin-top: 2px;
}

.main-nav {
  display: grid;
  gap: 18px;
}

.nav-section {
  display: grid;
  gap: 6px;
}

.nav-section-label {
  color: #7f928c;
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 0;
  padding: 0 12px 2px;
  text-transform: uppercase;
}

.nav-section-bottom {
  border-top: 1px solid rgba(255, 255, 255, 0.12);
  margin-top: 4px;
  padding-top: 12px;
}

.main-nav a {
  display: grid;
  grid-template-columns: 24px minmax(0, 1fr);
  gap: 10px;
  align-items: center;
  color: #d8e4e0;
  text-decoration: none;
  padding: 11px 12px;
  border-radius: 8px;
  font-size: 14px;
  font-weight: 700;
}

.main-nav a:hover,
.main-nav a.active {
  background: rgba(255, 255, 255, 0.1);
  color: #fff;
}

.nav-tree-children { display: grid; gap: 3px; margin: -2px 0 4px 34px; padding-left: 10px; border-left: 1px solid rgba(255, 255, 255, .18); }
.main-nav .nav-tree-children a { display: block; padding: 7px 9px; color: #afc0bb; font-size: 12px; font-weight: 600; }
.main-nav .nav-tree-children a.active { color: #fff; background: rgba(255, 255, 255, .1); }

.nav-icon {
  position: relative;
  display: grid;
  width: 24px;
  height: 24px;
  place-items: center;
  border-radius: 7px;
  background: rgba(255, 255, 255, 0.08);
}

.main-nav a.active .nav-icon,
.main-nav a:hover .nav-icon {
  background: rgba(255, 255, 255, 0.16);
}

.nav-icon::before,
.nav-icon::after {
  content: "";
  position: absolute;
  box-sizing: border-box;
}

.nav-overview::before {
  width: 13px;
  height: 13px;
  border: 2px solid currentColor;
  border-radius: 4px;
  box-shadow: -5px -5px 0 -3px currentColor, 5px 5px 0 -3px currentColor;
}

.nav-servers::before {
  width: 14px;
  height: 16px;
  border: 2px solid currentColor;
  border-radius: 3px;
}

.nav-servers::after {
  width: 6px;
  height: 2px;
  background: currentColor;
  box-shadow: 0 5px 0 currentColor;
}

.nav-backup::before {
  width: 15px;
  height: 15px;
  border: 2px solid currentColor;
  border-radius: 999px;
}

.nav-backup::after {
  width: 7px;
  height: 7px;
  border-left: 2px solid currentColor;
  border-bottom: 2px solid currentColor;
  transform: rotate(-45deg);
}

.nav-devices::before {
  width: 15px;
  height: 10px;
  border: 2px solid currentColor;
  border-radius: 3px;
  top: 5px;
}

.nav-devices::after {
  width: 11px;
  height: 2px;
  background: currentColor;
  bottom: 5px;
}

.nav-microsoft::before {
  width: 13px;
  height: 13px;
  background: currentColor;
  clip-path: polygon(0 0, 45% 0, 45% 45%, 0 45%, 0 55%, 45% 55%, 45% 100%, 55% 100%, 55% 55%, 100% 55%, 100% 45%, 55% 45%, 55% 0, 100% 0, 100% 100%, 0 100%);
}

.nav-services::before {
  width: 15px;
  height: 10px;
  border: 2px solid currentColor;
  border-radius: 8px;
  box-shadow: 5px -5px 0 -2px var(--sidebar-bg, #fff);
}

.nav-logbook::before {
  width: 13px;
  height: 15px;
  border: 2px solid currentColor;
  border-radius: 2px;
}

.nav-logbook::after {
  width: 7px;
  height: 1px;
  background: currentColor;
  box-shadow: 0 4px 0 currentColor;
}

.nav-security::before {
  width: 14px;
  height: 16px;
  border: 2px solid currentColor;
  border-radius: 8px 8px 10px 10px;
  clip-path: polygon(50% 0, 100% 20%, 92% 78%, 50% 100%, 8% 78%, 0 20%);
}

.nav-azure::before {
  width: 16px;
  height: 11px;
  border: 2px solid currentColor;
  border-radius: 999px;
  border-top-color: transparent;
}

.nav-inventory::before {
  width: 14px;
  height: 14px;
  border: 2px solid currentColor;
  border-radius: 3px;
}

.nav-inventory::after {
  width: 10px;
  height: 2px;
  background: currentColor;
  box-shadow: 0 -4px 0 currentColor, 0 4px 0 currentColor;
}

.nav-checks::before {
  width: 14px;
  height: 8px;
  border-left: 3px solid currentColor;
  border-bottom: 3px solid currentColor;
  transform: rotate(-45deg);
}

.nav-live::before {
  width: 14px;
  height: 14px;
  border: 2px solid currentColor;
  border-radius: 999px;
}

.nav-live::after {
  width: 4px;
  height: 4px;
  background: currentColor;
  border-radius: 999px;
  box-shadow: -6px 0 0 currentColor, 6px 0 0 currentColor;
}

.nav-settings::before {
  width: 14px;
  height: 14px;
  border: 2px solid currentColor;
  border-radius: 999px;
  box-shadow: 0 -5px 0 -3px currentColor, 0 5px 0 -3px currentColor, -5px 0 0 -3px currentColor, 5px 0 0 -3px currentColor;
}

.nav-settings::after {
  width: 5px;
  height: 5px;
  border: 2px solid currentColor;
  border-radius: 999px;
}

.nav-reports::before {
  width: 12px;
  height: 15px;
  border: 2px solid currentColor;
  border-radius: 2px;
}

.nav-reports::after {
  width: 7px;
  height: 2px;
  background: currentColor;
  box-shadow: 0 4px 0 currentColor;
}

.nav-users::before {
  width: 8px;
  height: 8px;
  border: 2px solid currentColor;
  border-radius: 999px;
  top: 4px;
}

.nav-users::after {
  width: 15px;
  height: 7px;
  border: 2px solid currentColor;
  border-radius: 999px 999px 4px 4px;
  bottom: 4px;
}

main {
  padding: 28px;
  min-width: 0;
}

.topbar {
  display: flex;
  justify-content: space-between;
  gap: 20px;
  align-items: flex-start;
  margin-bottom: 22px;
}

.page-brand {
  display: flex;
  gap: 14px;
  align-items: center;
  min-width: 0;
}

.page-logo-wrap {
  display: grid;
  flex: 0 0 auto;
  width: 68px;
  height: 48px;
  place-items: center;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
  padding: 6px;
}

.page-logo {
  display: block;
  max-width: 100%;
  max-height: 100%;
  object-fit: contain;
}

.eyebrow {
  color: var(--blue);
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 0;
  margin: 0 0 7px;
  text-transform: uppercase;
}

h1,
h2,
p {
  margin-top: 0;
}

h1 {
  font-size: 34px;
  line-height: 1.12;
  margin-bottom: 0;
}

h2 {
  font-size: 20px;
  margin-bottom: 0;
}

.topbar-actions {
  display: flex;
  gap: 10px;
  align-items: center;
  color: var(--muted);
  white-space: nowrap;
}

.refresh-progress {
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: 8px;
  box-shadow: var(--shadow);
  display: grid;
  gap: 9px;
  margin: -8px 0 16px;
  padding: 13px 15px;
}

.session-gate {
  background: var(--panel);
  border: 1px solid var(--line);
  border-left: 5px solid var(--blue);
  border-radius: 8px;
  box-shadow: var(--shadow);
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 16px;
  align-items: center;
  margin: -8px 0 16px;
  padding: 18px;
}

body.session-locked .session-gate {
  width: min(760px, 100%);
  margin: 0;
  grid-template-columns: minmax(0, 1fr);
}

body.session-refreshing .session-gate {
  align-self: end;
}

body.session-refreshing #refreshProgress {
  align-self: start;
  width: min(760px, 100%);
  margin: 0;
}

body.session-locked .session-gate-main {
  align-items: flex-start;
}

.session-gate[hidden] {
  display: none;
}

.session-gate-main {
  display: flex;
  gap: 16px;
  align-items: center;
  min-width: 0;
}

.session-logo {
  display: block;
  width: 110px;
  max-width: 28vw;
  height: auto;
  object-fit: contain;
}

.session-gate p {
  color: var(--muted);
  margin: 8px 0 0;
}

.session-actions {
  display: flex;
  gap: 10px;
  align-items: center;
}

.device-login-panel {
  border: 1px solid var(--line);
  border-left: 5px solid var(--blue);
  border-radius: 8px;
  background: #f7fbfc;
  display: grid;
  gap: 8px;
  padding: 14px 16px;
}

.device-login-panel[hidden] {
  display: none;
}

.device-login-panel strong {
  color: var(--ink);
  font-size: 28px;
  line-height: 1;
  letter-spacing: 0;
}

.device-login-panel a {
  color: var(--blue);
  font-weight: 800;
  text-decoration: none;
}

.credential-guide-button { background: transparent; border: 0; padding: 3px; cursor: pointer; }
.credential-guide-button:hover { background: var(--line); }
.credential-guide-button:focus-visible { outline: 2px solid var(--blue); outline-offset: 3px; }
#credentialGuideBody { overflow-wrap: anywhere; }

.session-badge {
  border-radius: 999px;
  font-size: 12px;
  font-weight: 800;
  padding: 6px 10px;
}

.session-badge.healthy {
  background: var(--green-soft);
  color: var(--green);
}

.session-badge.warning {
  background: var(--amber-soft);
  color: var(--amber);
}

.session-admin-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
  margin-bottom: 18px;
}

.refresh-progress[hidden] {
  display: none;
}

.refresh-progress-top,
.refresh-progress-bottom {
  display: flex;
  justify-content: space-between;
  gap: 14px;
  align-items: center;
}

.refresh-progress-top span,
.refresh-progress-bottom {
  color: var(--muted);
  font-size: 13px;
}

.refresh-progress-bar {
  height: 9px;
  overflow: hidden;
  border-radius: 999px;
  background: #e5ece9;
}

.refresh-progress-bar span {
  display: block;
  width: 0%;
  height: 100%;
  border-radius: inherit;
  background: var(--blue);
  transition: width 220ms ease;
}

button {
  border: 1px solid var(--line);
  background: var(--panel);
  color: var(--ink);
  border-radius: 8px;
  padding: 9px 13px;
  cursor: pointer;
}

button:hover {
  border-color: #9fb2ad;
}

button:disabled {
  cursor: wait;
  opacity: 0.7;
}

.danger-button {
  border-color: #e69a93;
  background: #fff1ef;
  color: var(--red);
  font-weight: 800;
  padding: 6px 10px;
  white-space: nowrap;
}

.danger-button:hover {
  border-color: var(--red-strong);
}

.overview-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 10px;
  margin-bottom: 10px;
}

.overview-status-panel[hidden],
.phase-section[hidden],
.domain-grid[hidden] {
  display: none;
}

.status-panel,
.actions-panel,
.content-section,
.domain-card {
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: 8px;
  box-shadow: var(--shadow);
}

.status-panel,
.actions-panel {
  padding: 20px;
}

.panel-label {
  color: var(--muted);
  font-size: 13px;
  font-weight: 700;
  text-transform: uppercase;
}

.overall {
  display: flex;
  align-items: center;
  gap: 10px;
  margin: 15px 0 10px;
  font-size: 25px;
}

.status-dot {
  width: 13px;
  height: 13px;
  border-radius: 50%;
  flex: 0 0 auto;
}

.healthy {
  background: var(--green);
}

.warning {
  background: var(--amber);
}

.critical {
  background: var(--red);
}

.planned {
  background: var(--blue);
}

.reserve {
  background: var(--blue);
}

.summary-strip {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 8px;
  margin-top: 20px;
}

.summary-strip span {
  background: var(--panel-soft);
  border-radius: 8px;
  padding: 10px;
  color: var(--muted);
  min-width: 0;
}

.summary-strip strong {
  display: block;
  color: var(--ink);
  font-size: 22px;
}

.domain-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 16px;
  margin-bottom: 16px;
}

.domain-card {
  padding: 17px;
}

.domain-top {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  align-items: center;
  margin-bottom: 12px;
}

.score-ring {
  display: grid;
  place-items: center;
  width: 50px;
  height: 50px;
  border-radius: 50%;
  background: conic-gradient(var(--green) var(--progress), #e7eeeb 0);
  color: var(--ink);
  font-size: 13px;
  font-weight: 800;
  position: relative;
}

.score-ring::before {
  content: "";
  position: absolute;
  inset: 5px;
  border-radius: 50%;
  background: #fff;
}

.score-ring span {
  position: relative;
}

.domain-card p {
  color: var(--muted);
  line-height: 1.4;
  min-height: 42px;
}

.metrics {
  display: grid;
  gap: 8px;
}

.metric {
  display: flex;
  justify-content: space-between;
  gap: 10px;
  border-top: 1px solid var(--line);
  padding-top: 8px;
  color: var(--muted);
  font-size: 14px;
}

.metric strong {
  color: var(--ink);
}

.section-heading {
  display: flex;
  justify-content: space-between;
  gap: 14px;
  align-items: center;
  margin-bottom: 15px;
}

.section-heading span {
  color: var(--muted);
  font-size: 14px;
}

.section-heading.compact {
  margin-bottom: 11px;
}

.section-heading.compact strong {
  display: grid;
  place-items: center;
  min-width: 34px;
  height: 30px;
  border-radius: 8px;
  background: var(--red-soft);
  color: var(--red);
}

.content-section {
  padding: 20px;
  margin-bottom: 16px;
}

.page-view {
  display: none;
}

.page-view:not(.is-active) {
  display: none !important;
}

.page-view.is-active {
  display: block;
}

.server-layout.page-view.is-active {
  display: grid;
}

.split-layout.page-view.is-active {
  display: grid;
}

.readonly-badge {
  display: inline-flex;
  align-items: center;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: var(--panel-soft);
  color: var(--muted);
  font-size: 13px;
  font-weight: 700;
  padding: 6px 10px;
}

.phase-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
}

.server-summary-card {
  display: block;
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: 8px;
  box-shadow: var(--shadow);
  color: var(--ink);
  padding: 13px;
  text-decoration: none;
}

.server-summary-card:hover {
  border-color: #9fb2ad;
}

.server-summary-hero {
  display: grid;
  grid-template-columns: auto 1fr auto;
  gap: 9px;
  align-items: center;
  padding-bottom: 9px;
  border-bottom: 1px solid var(--line);
}

.summary-icon {
  display: grid;
  place-items: center;
  width: 34px;
  height: 34px;
  border-radius: 8px;
  background: var(--blue-soft);
  color: var(--blue);
  font-weight: 900;
  position: relative;
}

.server-stack-icon::before,
.server-stack-icon::after {
  content: "";
  position: absolute;
  left: 12px;
  right: 12px;
  height: 10px;
  border: 2px solid currentColor;
  border-radius: 3px;
  background: #fff;
}

.server-stack-icon::before {
  top: 12px;
}

.server-stack-icon::after {
  bottom: 12px;
}

.server-stack-icon {
  box-shadow: inset 0 -12px 0 rgba(49, 130, 206, 0.08);
}

.server-summary-hero span:not(.summary-icon):not(.check-pill) {
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
}

.server-summary-hero strong {
  display: block;
  font-size: 23px;
  line-height: 1;
  margin-top: 4px;
}

.server-summary-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 5px;
  margin: 9px 0 0;
}

.server-summary-grid span {
  display: grid;
  grid-template-columns: auto 1fr;
  grid-template-areas:
    "icon value"
    "icon label";
  align-items: center;
  column-gap: 5px;
  background: var(--panel-soft);
  border-radius: 8px;
  color: var(--muted);
  padding: 6px;
  font-size: 10px;
}

.server-summary-grid strong {
  grid-area: value;
  display: block;
  color: var(--ink);
  font-size: 17px;
  line-height: 1;
}

.cost-summary-list { display: grid; gap: 5px; margin-top: 10px; }
.cost-summary-list > span { display: flex; justify-content: space-between; gap: 10px; padding: 5px 7px; border-radius: 6px; background: #f7f8ee; }
.cost-summary-list i { color: var(--muted); font-size: 11px; font-style: normal; }
.cost-summary-list strong { font-size: 12px; }
.azure-cost-summary-card { border-color: #d7d8bd; }
.subscription-total-row { border: 1px solid #c9d9d2; background: var(--green-soft); }
.subscription-cost-history { margin-top: 18px; padding-top: 16px; border-top: 1px solid var(--line); }
.subscription-history-heading { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.subscription-history-heading > div { display: grid; gap: 3px; }
.subscription-history-heading span { color: var(--muted); font-size: 12px; }
.subscription-history-chart { display: flex; align-items: end; gap: 12px; min-height: 190px; margin-top: 14px; padding: 12px; overflow-x: auto; border-radius: 9px; background: var(--panel-soft); }
.history-bar-column { display: grid; grid-template-rows: auto 120px auto; gap: 6px; align-items: end; min-width: 92px; text-align: center; }
.history-bar-column > strong { font-size: 11px; }
.history-bar-column small { color: var(--muted); font-size: 10px; text-transform: capitalize; }
.history-bar-track { position: relative; height: 120px; overflow: hidden; border-radius: 6px 6px 3px 3px; background: #e3ebe7; }
.history-bar-track span { position: absolute; right: 0; bottom: 0; left: 0; border-radius: inherit; background: var(--green); }
.contract-renewals-detail { margin-top: 16px; }
.contract-renewal-value { display: grid; justify-items: end; gap: 6px; white-space: nowrap; }
.website-history-section, .website-outages-section { margin-top: 16px; }
.website-response-chart { display: flex; align-items: end; gap: 3px; min-height: 190px; height: 190px; padding: 14px; overflow-x: auto; border-radius: 9px; background: var(--panel-soft); }
.response-chart-bar { flex: 1 0 5px; min-width: 5px; max-width: 14px; border-radius: 3px 3px 0 0; background: var(--green); }
.response-chart-bar.critical { background: var(--red); }
.network-clients-section { margin-top: 16px; }
.network-clients-section .section-heading input { width: min(320px, 100%); }
.network-client-groups { display: grid; gap: 14px; margin-top: 14px; }
.network-client-group { border: 1px solid var(--line); border-radius: 9px; overflow: hidden; background: var(--panel); }
.network-client-group-heading { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 10px 12px; background: var(--panel-soft); }
.network-client-group-heading span { color: var(--muted); font-size: 12px; }
.network-client-group .table-wrap { margin: 0; border: 0; border-radius: 0; }
.warning-text { color: #a95700 !important; font-weight: 700; }
.license-efficiency-overview { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 10px; margin: 14px 0; }
.license-efficiency-overview article { display: grid; gap: 5px; padding: 12px; border-radius: 9px; background: var(--panel-soft); }
.license-efficiency-overview span { color: var(--muted); font-size: 11px; }
.license-efficiency-overview strong { font-size: 18px; }
@media (max-width: 760px) { .license-efficiency-overview { grid-template-columns: 1fr; } }

.azure-budget-detail { margin: 14px 0; }
.budget-panel { border: 1px solid var(--line); border-left: 4px solid var(--green); border-radius: 10px; padding: 14px; background: var(--panel); }
.budget-panel.warning { border-left-color: var(--orange); }
.budget-panel.critical { border-left-color: var(--red); }
.budget-panel-heading, .budget-values, .budget-values > span { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.budget-panel-heading div { display: grid; gap: 3px; }
.budget-panel-heading span, .budget-values i { color: var(--muted); font-size: 12px; font-style: normal; }
.budget-panel-heading strong { font-size: 22px; }
.budget-meter { height: 12px; margin: 12px 0; overflow: hidden; border-radius: 999px; background: var(--panel-soft); }
.budget-meter span { display: block; height: 100%; background: var(--green); border-radius: inherit; }
.budget-meter span.warning { background: var(--orange); }
.budget-meter span.critical { background: var(--red); }
.budget-values { align-items: stretch; }
.budget-values > span { flex: 1; padding: 8px; border-radius: 7px; background: var(--panel-soft); }
@media (max-width: 760px) { .budget-values { display: grid; } }

.summary-metric-icon {
  grid-area: icon;
  display: inline-grid;
  place-items: center;
  width: 32px;
  height: 32px;
  border-radius: 8px;
  position: relative;
}

.running-icon {
  background: var(--green-soft);
  color: var(--green);
}

.running-icon::before {
  content: "";
  width: 12px;
  height: 12px;
  border-radius: 50%;
  background: currentColor;
  box-shadow: 0 0 0 5px rgba(35, 153, 99, 0.14);
}

.reserve-icon {
  background: var(--blue-soft);
  color: var(--blue);
}

.reserve-icon::before {
  content: "";
  width: 14px;
  height: 14px;
  border: 2px solid currentColor;
  border-radius: 50%;
}

.reserve-icon::after {
  content: "";
  position: absolute;
  width: 8px;
  height: 2px;
  background: currentColor;
}

.stopped-icon,
.critical-icon {
  background: var(--red-soft);
  color: var(--red);
}

.stopped-icon::before {
  content: "";
  width: 13px;
  height: 13px;
  border-radius: 3px;
  background: currentColor;
}

.attention-icon {
  background: var(--amber-soft);
  color: var(--amber);
}

.attention-icon::before {
  content: "";
  width: 0;
  height: 0;
  border-left: 8px solid transparent;
  border-right: 8px solid transparent;
  border-bottom: 15px solid currentColor;
}

.attention-icon::after {
  content: "";
  position: absolute;
  bottom: 9px;
  width: 3px;
  height: 3px;
  border-radius: 50%;
  background: #fff;
  box-shadow: 0 -5px 0 #fff;
}

.critical-icon::before,
.critical-icon::after {
  content: "";
  position: absolute;
  width: 16px;
  height: 3px;
  border-radius: 2px;
  background: currentColor;
}

.critical-icon::before {
  transform: rotate(45deg);
}

.critical-icon::after {
  transform: rotate(-45deg);
}

.backup-vault-icon::before {
  content: "";
  width: 22px;
  height: 18px;
  border: 2px solid currentColor;
  border-radius: 4px;
  background: #fff;
}

.backup-vault-icon::after {
  content: "";
  position: absolute;
  width: 13px;
  height: 8px;
  border: 2px solid currentColor;
  border-bottom: 0;
  border-radius: 8px 8px 0 0;
  top: 9px;
}

.protected-icon {
  background: var(--green-soft);
  color: var(--green);
}

.protected-icon::before {
  content: "";
  width: 15px;
  height: 11px;
  border-left: 3px solid currentColor;
  border-bottom: 3px solid currentColor;
  transform: rotate(-45deg);
  margin-top: -3px;
}

.protected-large-icon {
  background: var(--green-soft);
  color: var(--green);
}

.protected-large-icon::before {
  content: "";
  width: 24px;
  height: 28px;
  border-radius: 12px 12px 8px 8px;
  background: currentColor;
  clip-path: polygon(50% 0, 92% 17%, 92% 58%, 50% 100%, 8% 58%, 8% 17%);
}

.protected-large-icon::after {
  content: "";
  position: absolute;
  width: 12px;
  height: 7px;
  border-left: 3px solid #fff;
  border-bottom: 3px solid #fff;
  transform: rotate(-45deg);
  margin-top: -2px;
}

.planned-icon {
  background: var(--blue-soft);
  color: var(--blue);
}

.planned-icon::before {
  content: "";
  width: 16px;
  height: 16px;
  border: 2px solid currentColor;
  border-radius: 4px;
}

.planned-icon::after {
  content: "";
  position: absolute;
  width: 8px;
  height: 2px;
  background: currentColor;
}

.cloud-signal-icon::before {
  content: "";
  width: 24px;
  height: 15px;
  border-radius: 999px;
  background: currentColor;
  box-shadow:
    -8px 4px 0 -1px currentColor,
    8px 4px 0 -1px currentColor;
}

.cloud-signal-icon::after {
  content: "";
  position: absolute;
  bottom: 10px;
  width: 20px;
  height: 3px;
  border-radius: 999px;
  background: #fff;
}

.endpoint-device-icon::before {
  content: "";
  position: absolute;
  width: 24px;
  height: 16px;
  border: 2px solid currentColor;
  border-radius: 4px;
  background: #fff;
  top: 11px;
}

.endpoint-device-icon::after {
  content: "";
  position: absolute;
  width: 18px;
  height: 3px;
  border-radius: 999px;
  background: currentColor;
  bottom: 11px;
  box-shadow: 0 -5px 0 -7px transparent;
}

.cloud-small-icon {
  background: var(--blue-soft);
  color: var(--blue);
}

.cloud-small-icon::before {
  content: "";
  width: 18px;
  height: 11px;
  border-radius: 999px;
  background: currentColor;
  box-shadow:
    -6px 3px 0 -1px currentColor,
    6px 3px 0 -1px currentColor;
}

.endpoint-small-icon {
  background: var(--blue-soft);
  color: var(--blue);
}

.endpoint-small-icon::before {
  content: "";
  width: 18px;
  height: 13px;
  border: 2px solid currentColor;
  border-radius: 3px;
  background: #fff;
}

.endpoint-small-icon::after {
  content: "";
  position: absolute;
  bottom: 7px;
  width: 13px;
  height: 2px;
  border-radius: 999px;
  background: currentColor;
}

.azure-subscription-icon::before {
  content: "";
  position: absolute;
  width: 25px;
  height: 25px;
  border: 3px solid currentColor;
  border-radius: 50%;
  background: #fff;
}

.azure-subscription-icon::after {
  content: "";
  position: absolute;
  width: 16px;
  height: 7px;
  border-left: 3px solid currentColor;
  border-bottom: 3px solid currentColor;
  transform: rotate(-45deg);
  margin-top: -2px;
}

.cost-icon {
  background: var(--green-soft);
  color: var(--green);
}

.cost-icon::before {
  content: "€";
  font-size: 18px;
  font-weight: 900;
  line-height: 1;
}

.security-score-icon {
  background: var(--blue-soft);
  color: var(--blue);
}

.security-score-icon::before {
  content: "";
  width: 18px;
  height: 22px;
  border-radius: 10px 10px 8px 8px;
  background: currentColor;
  clip-path: polygon(50% 0, 90% 16%, 90% 56%, 50% 100%, 10% 56%, 10% 16%);
}

.security-score-icon::after {
  content: "";
  position: absolute;
  width: 8px;
  height: 4px;
  border-left: 2px solid #fff;
  border-bottom: 2px solid #fff;
  transform: rotate(-45deg);
  margin-top: -1px;
}

.identity-icon {
  background: var(--amber-soft);
  color: var(--amber);
}

.identity-icon::before {
  content: "";
  position: absolute;
  top: 7px;
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: currentColor;
}

.identity-icon::after {
  content: "";
  position: absolute;
  bottom: 7px;
  width: 18px;
  height: 9px;
  border-radius: 999px 999px 4px 4px;
  background: currentColor;
}

.license-icon {
  background: var(--green-soft);
  color: var(--green);
}

.license-icon::before {
  content: "";
  width: 17px;
  height: 13px;
  border: 2px solid currentColor;
  border-radius: 3px;
}

.license-icon::after {
  content: "";
  position: absolute;
  right: 8px;
  bottom: 8px;
  width: 8px;
  height: 5px;
  border-left: 2px solid currentColor;
  border-bottom: 2px solid currentColor;
  transform: rotate(-45deg);
}

.backup-overview-grid {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 10px;
  margin-bottom: 16px;
}

.backup-stat-card {
  display: grid;
  grid-template-columns: auto 1fr;
  grid-template-areas:
    "icon label"
    "icon value";
  column-gap: 10px;
  align-items: center;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
  padding: 12px;
  border-left: 5px solid var(--line);
}

.backup-stat-card .summary-metric-icon {
  grid-area: icon;
}

.backup-stat-card span {
  grid-area: label;
  color: var(--muted);
  font-size: 13px;
  font-weight: 800;
}

.backup-stat-card strong {
  grid-area: value;
  font-size: 24px;
  line-height: 1;
}

.backup-stat-card.healthy {
  border-left-color: var(--green);
}

.backup-stat-card.warning {
  border-left-color: var(--amber);
}

.backup-stat-card.critical {
  border-left-color: var(--red);
}

.backup-stat-card[data-critical-issue] {
  cursor: pointer;
}

.backup-stat-card[data-critical-issue]:hover,
.backup-stat-card[data-critical-issue]:focus {
  border-color: var(--red);
  box-shadow: 0 0 0 3px rgba(193, 18, 31, 0.12);
  outline: none;
}

.backup-stat-card.planned {
  border-left-color: var(--blue);
}

.backup-stat-card.neutral {
  border-left-color: var(--muted);
}

.backup-golden-section {
  margin-bottom: 16px;
}

.endpoint-intune-panel {
  margin-bottom: 16px;
}

.endpoint-intune-summary {
  margin-bottom: 0;
}

.endpoint-intune-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
}

.endpoint-intune-grid article {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--panel-soft);
  padding: 12px;
}

.endpoint-intune-grid span {
  display: block;
  color: var(--muted);
  font-size: 13px;
  font-weight: 800;
}

.endpoint-intune-grid strong {
  display: block;
  margin-top: 4px;
  font-size: 20px;
}

.endpoint-candidate-link {
  color: var(--ink);
  text-decoration: none;
}

.endpoint-candidate-link:hover {
  border-color: #9fb2ad;
}

.server-summary-card p {
  color: var(--muted);
  margin-bottom: 0;
}

#overview .server-summary-card > p {
  display: none;
}

#overview .summary-metric-icon {
  display: none;
}

#overview .server-summary-grid span {
  display: block;
}

#overview .server-summary-card.critical { border-left: 4px solid var(--red); }
#overview .server-summary-card.warning { border-left: 4px solid var(--amber); }
#overview .server-summary-card.healthy { border-left: 4px solid var(--green); }
#overview .server-summary-card.planned { border-left: 4px solid var(--blue); }

.azure-subscription-detail-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 16px;
  margin-top: 16px;
}

.security-detail-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 16px;
  align-items: start;
  margin-top: 16px;
}

.stack-list {
  display: grid;
  gap: 10px;
}

.stack-list-heading {
  display: block;
  margin: 10px 0 2px;
  color: var(--ink);
  font-size: 13px;
  text-transform: uppercase;
}

.stack-list-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--panel-soft);
  padding: 12px;
}

.stack-list-item span {
  display: block;
  color: var(--muted);
  font-size: 12px;
  margin-top: 3px;
  word-break: break-word;
}

.web-health-compact {
  display: grid;
  gap: 6px;
  margin-top: 12px;
}

.web-health-row {
  display: grid;
  grid-template-columns: minmax(160px, 1.2fr) auto minmax(90px, .6fr) 70px minmax(190px, 1.2fr) minmax(140px, .8fr) auto;
  align-items: center;
  gap: 12px;
  padding: 9px 12px;
  border: 1px solid var(--line);
  border-left: 4px solid var(--green);
  border-radius: 8px;
  background: #fff;
  font-size: 13px;
}

.web-health-row:has(.status-pill.critical) { border-left-color: var(--red); }
.web-health-row:has(.status-pill.warning) { border-left-color: var(--orange); }

@media (max-width: 900px) {
  .web-health-row {
    grid-template-columns: 1fr auto;
  }
}

.security-recommendation {
  align-items: flex-start;
}

.phase-card {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
  padding: 14px;
}

.phase-card.active {
  background: var(--green-soft);
  border-color: #a8d9c1;
}

.phase-card strong,
.phase-card span {
  display: block;
}

.phase-card span {
  color: var(--muted);
  margin-top: 6px;
  line-height: 1.4;
}

.split-layout {
  display: grid;
  grid-template-columns: minmax(0, 1.1fr) minmax(320px, 0.9fr);
  gap: 16px;
}

.deferred-section,
.split-layout.deferred-section,
.content-section.deferred-section {
  display: none;
}

.server-layout {
  display: none;
  grid-template-columns: minmax(0, 1fr);
  gap: 16px;
}

#servers {
  width: 100%;
}

#servers table {
  min-width: 980px;
}

#servers th,
#servers td {
  white-space: normal;
}

#servers th:first-child,
#servers td:first-child {
  min-width: 150px;
}

#servers th:nth-child(2),
#servers td:nth-child(2) {
  min-width: 170px;
}

#servers th:nth-child(3),
#servers td:nth-child(3) {
  min-width: 120px;
}

#servers th:nth-child(4),
#servers td:nth-child(4),
#servers th:nth-child(5),
#servers td:nth-child(5),
#servers th:nth-child(6),
#servers td:nth-child(6),
#servers th:nth-child(7),
#servers td:nth-child(7),
#servers th:nth-child(8),
#servers td:nth-child(8) {
  min-width: 125px;
}

.top-actions,
.action-list,
.compact-list,
.connector-list {
  display: grid;
  gap: 10px;
}

.action-item,
.list-item,
.connector-item,
.check-card,
.runbook-card,
.empty-state {
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 12px;
  background: #fff;
}

.update-manager-summary {
  border-left: 4px solid var(--blue);
}

.update-manager-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
}

.update-vm-card {
  display: grid;
  gap: 8px;
  min-width: 0;
  border: 1px solid var(--line);
  border-left: 4px solid var(--blue);
  border-radius: 8px;
  padding: 12px;
  background: #f9fbfa;
}

.update-vm-card.warning {
  border-left-color: var(--amber);
  background: var(--amber-soft);
}

.update-vm-card.critical {
  border-left-color: var(--red);
  background: var(--red-soft);
}

.update-vm-card.healthy {
  border-left-color: var(--green);
  background: var(--green-soft);
}

.update-vm-top {
  display: flex;
  justify-content: space-between;
  gap: 10px;
  align-items: center;
  min-width: 0;
}

.update-vm-top strong {
  overflow-wrap: anywhere;
}

.monitor-backup-section {
  margin: 16px 0;
}

.monitor-backup-panel {
  display: grid;
}

.monitor-backup-card {
  display: grid;
  gap: 12px;
  border: 1px solid var(--line);
  border-left: 4px solid var(--blue);
  border-radius: 8px;
  padding: 14px;
  background: #f9fbfa;
}

.monitor-backup-card.healthy {
  border-left-color: var(--green);
  background: var(--green-soft);
}

.monitor-backup-card.warning {
  border-left-color: var(--amber);
  background: var(--amber-soft);
}

.monitor-backup-card.critical {
  border-left-color: var(--red);
  background: var(--red-soft);
}

.monitor-backup-title {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  align-items: flex-start;
}

.monitor-backup-title div {
  display: grid;
  gap: 3px;
  min-width: 0;
}

.monitor-backup-title span,
.monitor-backup-card p {
  overflow-wrap: anywhere;
}

.monitor-backup-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
}

.monitor-backup-grid article {
  display: grid;
  gap: 4px;
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 10px;
  background: rgba(255, 255, 255, 0.72);
  min-width: 0;
}

.monitor-backup-grid span {
  color: var(--muted);
  font-size: 12px;
}

.monitor-backup-grid strong {
  overflow-wrap: anywhere;
}

.settings-form {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
  margin-top: 12px;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
}

.settings-form label {
  display: grid;
  gap: 6px;
  color: var(--muted);
  font-size: 13px;
  font-weight: 700;
}

.settings-form input[type="text"],
.settings-form input[type="time"],
.settings-form input[type="number"],
.settings-form input[type="email"],
.settings-form select,
.settings-form textarea {
  width: 100%;
  min-width: 0;
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 9px 10px;
  color: var(--ink);
  font: inherit;
  background: #fff;
}

.settings-form textarea {
  resize: vertical;
}

.network-device-form {
  margin-bottom: 16px;
  background: #f8fbfa;
}

.network-device-form-heading {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.network-device-form-heading > div {
  display: grid;
  gap: 3px;
}

.network-device-form-heading span:not(.readonly-badge),
.network-client-detail {
  display: block;
  color: var(--muted);
  font-size: 12px;
  font-weight: 400;
  margin-top: 3px;
}

.unknown-device-name {
  color: var(--red);
}

.insight-confidence {
  width: fit-content;
  padding: 2px 6px;
  border-radius: 999px;
  background: #edf2f1;
}

.insight-confidence.high { color: #08663f; background: #e4f6ed; }
.insight-confidence.medium { color: #8b5900; background: #fff3d6; }
.insight-confidence.low { color: #6b4ca0; background: #f0eafb; }

.network-device-edit-button {
  white-space: nowrap;
}

.network-registry-panel {
  margin: 0 0 16px;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
}

.network-registered-devices {
  display: grid;
  gap: 8px;
  margin-top: 8px;
}

.network-registry-actions {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 8px;
  flex-wrap: wrap;
}

.network-client-filters {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 8px;
  flex-wrap: wrap;
}

.network-client-filters select,
.network-client-filters input {
  min-height: 38px;
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 8px 10px;
  background: #fff;
  color: var(--ink);
  font: inherit;
}

.network-page-links {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(210px, 1fr));
  gap: 12px;
  margin: 14px 0;
}

.network-equipment-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 12px;
}

.network-equipment-card {
  padding: 14px;
  border: 1px solid var(--line);
  border-left: 4px solid var(--green);
  border-radius: 9px;
  background: #fff;
}

.network-equipment-card.critical { border-left-color: var(--red); }
.network-equipment-card.planned { border-left-color: #7c8c88; }

.network-equipment-card-heading {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 10px;
}

.network-equipment-card-heading > div { display: grid; gap: 3px; }
.network-equipment-card-heading span { color: var(--muted); font-size: 12px; }

.network-equipment-meta {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
  margin-top: 12px;
}

.network-equipment-meta span {
  display: grid;
  gap: 2px;
  color: var(--muted);
  font-size: 11px;
}

.network-equipment-meta strong { color: var(--ink); font-size: 13px; overflow-wrap: anywhere; }

.network-page-links a {
  display: grid;
  gap: 5px;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 9px;
  background: #fff;
  color: var(--ink);
  text-decoration: none;
}

.network-page-links a:hover {
  border-color: var(--brand);
  background: #f6fbf8;
}

.network-page-links span {
  color: var(--muted);
  font-size: 12px;
  line-height: 1.4;
}

.internet-latency-chart {
  display: flex;
  align-items: end;
  gap: 2px;
  min-height: 210px;
  height: 210px;
  padding: 14px;
  overflow-x: auto;
  border-radius: 9px;
  background: var(--panel-soft);
}

.internet-latency-bar {
  flex: 1 0 4px;
  min-width: 4px;
  max-width: 12px;
  border-radius: 3px 3px 0 0;
  background: var(--green);
}

.internet-latency-bar.warning { background: #e59a18; }
.internet-latency-bar.critical { background: var(--red); }
.internet-latency-bar.failover { outline: 2px solid #6f42c1; outline-offset: -1px; }

.network-history-chart {
  display: grid;
  grid-template-columns: repeat(14, minmax(46px, 1fr));
  gap: 8px;
  min-height: 230px;
  padding: 14px;
  overflow-x: auto;
  border-radius: 9px;
  background: var(--panel-soft);
}

.network-history-day { display: grid; grid-template-rows: 145px auto auto auto; gap: 3px; min-width: 46px; text-align: center; font-size: 11px; color: var(--muted); }
.network-history-day strong { color: var(--ink); font-size: 13px; }
.network-history-day small { color: var(--red); font-weight: 700; white-space: nowrap; }
.network-history-bar-wrap { display: flex; align-items: end; justify-content: center; height: 145px; }
.network-history-bar { width: min(28px, 72%); min-height: 5px; border-radius: 5px 5px 2px 2px; background: var(--green); }

.folder-access-list { display: grid; gap: 12px; }
.folder-server-status { display: grid; grid-template-columns: repeat(auto-fit, minmax(210px, 1fr)); gap: 10px; margin: 12px 0; }
.folder-server-status article { display: flex; justify-content: space-between; align-items: start; gap: 10px; padding: 12px; border: 1px solid var(--line); border-radius: 9px; background: var(--panel); }
.folder-server-status article > div { display: grid; gap: 3px; }
.folder-server-status article span { color: var(--muted); font-size: 12px; }
.access-region-actions { display: flex; flex-wrap: wrap; justify-content: end; gap: 8px; }
.avd-session-policy-section { margin: 14px 0; }
.avd-session-policy-section > summary { display: flex; justify-content: space-between; align-items: center; gap: 12px; cursor: pointer; list-style: none; }
.avd-session-policy-section > summary::-webkit-details-marker { display: none; }
.avd-session-policy-section > summary h3 { margin: 0 0 3px; }
.avd-session-policy-section > summary span { color: var(--muted); font-size: 12px; }
.avd-policy-actions { margin: 8px 0 12px; }
.azure-alert-capacity { display: grid; grid-template-columns: repeat(auto-fit,minmax(130px,1fr)); gap: 8px; margin: 12px 0 8px; }
.azure-alert-capacity > div { display: grid; gap: 3px; padding: 10px; border-radius: 8px; background: var(--panel-soft); }
.azure-alert-capacity span { color: var(--muted); font-size: 11px; }
.azure-alert-capacity strong { font-size: 14px; }
.azure-capacity-track { position: relative; height: 12px; margin: 8px 0 14px; border-radius: 8px; background: var(--line); overflow: visible; }
.azure-capacity-track span { display: block; height: 100%; border-radius: inherit; background: #e59a18; }
.azure-capacity-track i { position: absolute; top: -4px; bottom: -4px; width: 2px; background: var(--red); }
.azure-alert-guidance { display: grid; grid-template-columns: repeat(3,1fr); gap: 10px; margin-top: 12px; }
.azure-alert-guidance > div { display: grid; gap: 4px; padding: 11px; border: 1px solid var(--line); border-radius: 8px; }
.azure-alert-guidance span { color: var(--muted); font-size: 12px; line-height: 1.45; }
@media (max-width: 850px) { .azure-alert-guidance { grid-template-columns: 1fr; } }

.panel-annotatable { position: relative; padding-bottom: 43px !important; }
.panel-utility-tools { position: absolute; right: 9px; bottom: 8px; z-index: 3; display: flex; gap: 5px; }
.panel-utility-tools button { min-height: 26px; padding: 4px 8px; border: 1px solid var(--line); border-radius: 7px; background: var(--panel); color: var(--muted); font-size: 11px; font-weight: 700; line-height: 1; box-shadow: none; }
.panel-utility-tools button:hover { color: var(--ink); border-color: var(--green); }
.panel-utility-tools .panel-note-control.has-note { color: #8a5a00; border-color: #e59a18; background: #fff8e8; }
.panel-note-modal textarea { width: 100%; resize: vertical; min-height: 180px; padding: 12px; border: 1px solid var(--line); border-radius: 8px; font: inherit; }
.panel-note-modal .form-message:empty { display: none; }

.critical-overview-section { margin: 16px 0; border-left: 4px solid var(--green); }
.critical-overview-section.has-critical { border-left-color: var(--red); }
.critical-overview-list { display: grid; gap: 8px; }
.critical-overview-item { display: grid; grid-template-columns: auto minmax(0,1fr) auto; align-items: center; gap: 11px; padding: 11px 12px; border: 1px solid var(--line); border-radius: 9px; color: inherit; text-decoration: none; background: var(--panel); }
.critical-overview-item:hover { border-color: var(--red); background: #fff7f6; }
.critical-overview-item > div { display: grid; gap: 2px; min-width: 0; }
.critical-overview-item > div > span { color: var(--muted); font-size: 11px; font-weight: 700; text-transform: uppercase; }
.critical-overview-item p { margin: 1px 0; color: var(--muted); font-size: 12px; overflow-wrap: anywhere; }
.critical-overview-item small { color: var(--red); font-size: 11px; }
.critical-overview-open { color: var(--red); font-size: 12px; font-weight: 700; white-space: nowrap; }
@media (max-width: 700px) { .critical-overview-item { grid-template-columns: auto 1fr; } .critical-overview-open { grid-column: 2; } }
.folder-access-card { padding: 15px; border: 1px solid var(--line); border-left: 4px solid var(--green); border-radius: 10px; background: var(--panel); }
.folder-access-card.warning { border-left-color: #e59a18; }
.folder-access-heading { display: flex; justify-content: space-between; gap: 14px; align-items: start; }
.folder-access-heading, .folder-connect-help > summary { cursor: pointer; list-style: none; }
.folder-access-heading::-webkit-details-marker, .folder-connect-help > summary::-webkit-details-marker { display: none; }
.folder-access-summary-status { display: flex; align-items: center; gap: 10px; }
.folder-toggle-label::after { content: "Openklappen ▾"; color: var(--muted); font-size: 12px; font-weight: 700; white-space: nowrap; }
details[open] > summary .folder-toggle-label::after { content: "Dichtklappen ▴"; }
.folder-collapsible-content { padding-top: 4px; }
.folder-connect-help > summary { display: flex; justify-content: space-between; align-items: center; gap: 12px; }
.folder-connect-help > summary h2 { margin: 0; }
.folder-connect-help > summary span { color: var(--muted); font-size: 12px; }
.folder-access-heading > div { display: grid; gap: 4px; }
.folder-access-heading span, .folder-access-entry span { color: var(--muted); font-size: 12px; overflow-wrap: anywhere; }
.folder-access-columns { display: grid; grid-template-columns: 1fr 1fr; gap: 18px; margin-top: 14px; }
.folder-access-columns h3 { margin: 0 0 8px; font-size: 13px; }
.folder-access-entry { display: grid; gap: 2px; padding: 7px 0; border-top: 1px solid var(--line); }
.folder-access-entry strong { font-size: 13px; overflow-wrap: anywhere; }
.folder-connect-help ol { margin: 4px 0 12px 22px; padding: 0; }
.folder-connect-help li { margin: 7px 0; line-height: 1.45; }
.folder-access-connect { display: flex; justify-content: space-between; align-items: end; gap: 12px; margin-top: 13px; padding: 11px; border-radius: 8px; background: var(--panel-soft); }
.folder-access-connect > div { display: grid; gap: 4px; }
.folder-access-connect span { color: var(--muted); font-size: 12px; }
.folder-access-connect code { color: var(--ink); font-size: 14px; font-weight: 700; overflow-wrap: anywhere; }
@media (max-width: 800px) { .folder-access-columns { grid-template-columns: 1fr; } }

@media (max-width: 900px) {
  .network-page-links { grid-template-columns: 1fr; }
}

.form-message {
  color: var(--danger);
  font-size: 13px;
  font-weight: 700;
}

.toggle-row {
  display: flex !important;
  grid-template-columns: none;
  align-items: center;
  gap: 9px !important;
  color: var(--ink) !important;
}

.toggle-row input {
  width: 18px;
  height: 18px;
}

.settings-actions {
  grid-column: 1 / -1;
  display: flex;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
}

.settings-full,
.users-management-panel {
  grid-column: 1 / -1;
}

.top-actions .action-item {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 10px;
  align-items: start;
}

.priority {
  border-radius: 999px;
  padding: 4px 8px;
  font-size: 12px;
  font-weight: 800;
  width: fit-content;
}

.priority.critical {
  background: var(--red-soft);
  color: var(--red);
}

.priority.high {
  background: var(--amber-soft);
  color: var(--amber);
}

.priority.medium {
  background: var(--blue-soft);
  color: var(--blue);
}

.action-title {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  align-items: baseline;
  margin-bottom: 6px;
}

.action-title strong {
  font-size: 15px;
}

.action-title span,
.muted {
  color: var(--muted);
  font-size: 13px;
}

.action-item p,
.list-item p {
  color: var(--muted);
  line-height: 1.4;
  margin-bottom: 0;
}

.filter-group {
  display: flex;
  gap: 6px;
}

.filter {
  padding: 7px 10px;
}

.filter.active {
  background: #17211f;
  color: #fff;
  border-color: #17211f;
}

.table-wrap {
  overflow-x: auto;
}

.avd-session-overview {
  margin-bottom: 18px;
  padding: 16px;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: #f8fbfa;
}

.avd-session-toolbar,
.avd-session-group header {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  align-items: center;
}

.avd-session-toolbar h3 {
  margin: 0 0 3px;
}

.avd-session-toolbar > div > span,
.avd-session-search > span,
.avd-session-group header span,
.avd-session-user div span,
.avd-no-sessions {
  color: var(--muted);
  font-size: 12px;
}

.avd-session-user .avd-client-detail {
  color: #52635d;
  font-size: 11px;
}

.avd-session-user-heading { display: flex !important; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 6px; }
.experience-badge { padding: 2px 6px; border-radius: 999px; font-size: 10px !important; font-weight: 800; white-space: nowrap; }
.experience-badge.healthy { color: #176b45 !important; background: #e6f5ed; }
.experience-badge.warning { color: #92500b !important; background: #fff0d9; }
.experience-badge.critical { color: #9d2727 !important; background: #fde5e5; }
.experience-badge.neutral { color: #52635d !important; background: #eaf0ed; }
.avd-network-detail { color: #345166 !important; font-size: 11px !important; font-weight: 700; }
.avd-network-history { margin-top: 2px; padding: 5px 7px; border-left: 3px solid #6f8fa3; border-radius: 3px; color: #345166 !important; background: #f1f6f8; font-size: 10px !important; line-height: 1.35; }

#avdSessionFreshness.stale {
  color: #a5520b;
  font-weight: 800;
}

.avd-collector-health { display: inline-block; margin-top: 6px; padding: 4px 8px; border-radius: 6px; color: #fff; font-size: 12px; font-weight: 800; text-shadow: 0 1px 1px rgba(0, 0, 0, .3); }
.avd-collector-health.healthy { color: #fff; background: #17824f; }
.avd-collector-health.warning { color: #fff; background: #b9680e; }

.avd-session-search {
  display: grid;
  gap: 5px;
  min-width: min(320px, 100%);
}

.avd-session-search input {
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 8px 10px;
  background: #fff;
}

.avd-session-totals {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
  gap: 10px;
  margin: 14px 0;
}

.avd-session-totals article {
  display: grid;
  gap: 2px;
  padding: 10px 12px;
  border-radius: 9px;
  background: #fff;
  border: 1px solid var(--line);
}

.avd-session-totals strong { font-size: 20px; }
.avd-session-totals span { color: var(--muted); font-size: 12px; }

.avd-login-health { display: grid; gap: 8px; margin-bottom: 14px; padding: 11px 12px; border-radius: 9px; border: 1px solid var(--line); font-size: 13px; }
.avd-login-health.healthy { color: #176b45; background: #eef9f3; border-color: #bfe3d0; }
.avd-login-health.warning { color: #75400b; background: #fff8ed; border-color: #efcf9f; }
.avd-login-health > strong, .avd-login-health > span, .avd-login-health > div > strong, .avd-login-health > div > span { display: block; }
.avd-login-health > span, .avd-login-health > div > span { margin-top: 2px; font-size: 12px; }
.avd-login-health summary { cursor: pointer; font-weight: 800; }
.avd-login-failures { display: grid; gap: 8px; margin-top: 9px; }
.avd-login-failures article { padding: 9px; border-radius: 7px; background: #fff; border: 1px solid #efcf9f; }
.avd-login-failures article > strong, .avd-login-failures article > span, .avd-login-failures article > code { display: block; margin-bottom: 3px; }
.avd-login-failures article > span { color: var(--muted); font-size: 11px; }
.avd-login-failures p { margin: 5px 0 0; color: var(--ink); }

.avd-planning-health { display: grid; gap: 8px; margin-bottom: 14px; padding: 11px 12px; border: 1px solid #c9dce7; border-radius: 9px; background: #f1f7fa; color: #294b5e; font-size: 13px; }
.avd-planning-health > div:first-child { display: flex; justify-content: space-between; gap: 12px; }
.avd-planning-health > div:first-child span { color: var(--muted); }
.avd-planning-facts { display: flex; flex-wrap: wrap; gap: 7px; }
.avd-planning-facts > span { padding: 4px 7px; border-radius: 6px; background: #fff; border: 1px solid #d8e5eb; }
.avd-planning-health p { margin: 0; color: #52635d; font-size: 12px; }
.planning-conformance { padding: 4px 7px; border-radius: 999px; color: #fff !important; font-size: 11px; font-weight: 800; }
.planning-conformance.healthy { background: #17824f; }
.planning-conformance.critical { background: #b83232; }

.avd-cost-overview { display: grid; gap: 9px; margin-bottom: 14px; padding: 12px; border: 1px solid #d7d8bd; border-radius: 9px; background: #fbfbf1; color: #404226; font-size: 13px; }
.avd-cost-heading { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.avd-cost-heading > div { display: grid; gap: 2px; }
.avd-cost-heading > div span { color: var(--muted); font-size: 11px; }
.avd-cost-heading > strong { font-size: 20px; }
.avd-cost-totals, .avd-cost-hosts { display: flex; flex-wrap: wrap; gap: 7px; }
.avd-cost-totals > span, .avd-cost-hosts > span { padding: 5px 8px; border: 1px solid #e1e2c9; border-radius: 6px; background: #fff; }
.avd-cost-overview p { margin: 0; padding: 6px 8px; border-radius: 6px; font-size: 12px; font-weight: 700; }
.avd-cost-ok { color: #176b45; background: #eaf6ef; }
.avd-cost-warning { color: #92500b; background: #fff0d9; }

.avd-session-alerts {
  margin-bottom: 14px;
  padding: 10px 12px;
  border-radius: 9px;
  background: #fff8ed;
  border: 1px solid #efcf9f;
  color: #75400b;
  font-size: 13px;
}

.avd-session-alerts ul { margin: 7px 0 0; padding-left: 20px; }
.avd-session-alerts li + li { margin-top: 4px; }
.avd-session-ok { color: #176b45; font-weight: 700; }

.avd-session-groups {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(330px, 1fr));
  gap: 10px;
}

.avd-session-group {
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 9px;
  background: #fff;
}

.avd-session-group header a { color: var(--ink); font-weight: 800; }
.avd-host-badges { display: flex; flex-wrap: wrap; justify-content: flex-end; gap: 6px; }
.avd-host-badges span { padding: 4px 7px; border-radius: 999px; font-weight: 700; white-space: nowrap; }
.avd-host-status { background: #e8f5ee; color: #176b45 !important; }
.avd-host-sessions { background: #edf3f8; color: #345166 !important; }
.avd-drain-status.accepting { background: #e6f5ed; color: #176b45 !important; }
.avd-drain-status.drain { background: #fff0d9; color: #92500b !important; }
.avd-fslogix-status.healthy { background: #e6f5ed; color: #176b45 !important; }
.avd-fslogix-status.warning { background: #fff0d9; color: #92500b !important; }
.avd-fslogix-status.critical { background: #fde5e5; color: #9d2727 !important; }
.avd-fslogix-status.neutral { background: #eaf0ed; color: #52635d !important; }
.avd-profile-detail { font-size: 11px !important; font-weight: 800; }
.avd-profile-detail.healthy { color: #176b45 !important; }
.avd-profile-detail.warning { color: #92500b !important; }
.avd-profile-detail.critical { color: #9d2727 !important; }
.avd-profile-detail.neutral { color: #52635d !important; }

.avd-host-load {
  display: grid;
  grid-template-columns: 1fr;
  gap: 10px;
  margin-top: 11px;
  padding: 10px;
  border-radius: 8px;
  background: #f6f9f8;
}

.avd-load-metric {
  display: grid;
}

.avd-load-track { position: relative; height: 28px; border-radius: 7px; background: #27865a; overflow: hidden; }
.avd-load-fill { position: absolute; inset: 0 auto 0 0; display: block; background: #126d43; }
.avd-load-text { position: absolute; inset: 0; z-index: 1; display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 0 10px; color: #fff; text-shadow: 0 1px 1px rgba(0, 0, 0, .35); }
.avd-load-text span { color: #fff !important; font-size: 12px; font-weight: 800; }
.avd-load-text strong { color: #fff; font-size: 13px; }
.avd-load-metric.warning .avd-load-track { background: #d98218; }
.avd-load-metric.warning .avd-load-fill { background: #ad5e08; }
.avd-load-metric.critical .avd-load-track { background: #ca4545; }
.avd-load-metric.critical .avd-load-fill { background: #982929; }
.avd-load-metric.unknown .avd-load-track { background: #78847f; }
.avd-load-metric.unknown .avd-load-fill { background: #5c6662; }
.avd-session-list { display: grid; gap: 9px; margin-top: 11px; }
.avd-session-user { display: grid; grid-template-columns: 9px 1fr; gap: 8px; align-items: start; }
.avd-session-user div { display: grid; gap: 2px; min-width: 0; }
.avd-session-user strong { font-size: 13px; overflow-wrap: anywhere; }

.session-state-dot {
  width: 8px;
  height: 8px;
  margin-top: 4px;
  border-radius: 50%;
  background: #8a9692;
}
.session-state-dot.active { background: #159455; }
.session-state-dot.disconnected { background: #d68116; }
.avd-no-sessions { display: block; margin-top: 11px; }

@media (max-width: 760px) {
  .avd-session-toolbar { align-items: stretch; flex-direction: column; }
  .avd-session-totals { grid-template-columns: repeat(2, 1fr); }
  .avd-session-groups { grid-template-columns: 1fr; }
  .avd-session-group header { align-items: flex-start; flex-direction: column; }
  .avd-host-badges { justify-content: flex-start; }
}

.report-toolbar {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  align-items: end;
  margin-bottom: 16px;
}

.report-toolbar label {
  display: grid;
  gap: 6px;
  color: var(--muted);
  font-size: 13px;
  font-weight: 700;
}

.report-toolbar select {
  min-width: 240px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
  color: var(--ink);
  padding: 9px 10px;
}

.report-download-action {
  display: flex;
  gap: 10px;
  align-items: center;
  flex-wrap: wrap;
}

.report-download-action span {
  color: var(--muted);
  font-size: 13px;
}

.report-output {
  display: grid;
  gap: 16px;
}

.report-document {
  display: grid;
  gap: 16px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
  padding: 18px;
}

.report-header {
  display: flex;
  gap: 16px;
  align-items: center;
  padding-bottom: 14px;
  border-bottom: 1px solid var(--line);
}

.report-header img {
  width: 132px;
  max-width: 28vw;
  max-height: 74px;
  object-fit: contain;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
  padding: 7px;
}

.report-header h2 {
  font-size: 26px;
  margin: 4px 0 5px;
}

.report-header p {
  color: var(--muted);
  margin: 0;
}

.report-meta-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 10px;
}

.report-meta-grid article {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #f8fbfa;
  padding: 12px;
}

.report-meta-grid span {
  display: block;
  color: var(--muted);
  font-size: 12px;
  margin-bottom: 5px;
}

.report-section {
  display: grid;
  gap: 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  overflow: hidden;
  background: #fff;
}

.report-section-title {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  align-items: center;
  background: var(--green);
  color: #fff;
  padding: 12px 14px;
}

.report-section-title h2 {
  margin: 0;
}

.report-section-title strong {
  display: grid;
  min-width: 34px;
  height: 30px;
  place-items: center;
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.18);
  color: #fff;
}

.report-component {
  display: grid;
  gap: 10px;
  padding: 0 14px 14px;
}

.report-component h3 {
  margin: 0;
  padding: 10px 0 6px;
  border-bottom: 1px solid var(--line);
  color: var(--ink);
  font-size: 17px;
}

.report-table {
  min-width: 980px;
}

.report-table td {
  vertical-align: top;
}

.report-empty {
  border: 1px dashed var(--line);
  border-radius: 8px;
  background: #f8fbfa;
  padding: 18px;
}

table {
  border-collapse: collapse;
  width: 100%;
  min-width: 860px;
}

th,
td {
  border-bottom: 1px solid var(--line);
  padding: 11px 9px;
  text-align: left;
  vertical-align: middle;
  font-size: 14px;
}

th {
  color: var(--muted);
  font-size: 12px;
  text-transform: uppercase;
}

.clickable-row {
  cursor: pointer;
}

.clickable-row:hover {
  background: var(--panel-soft);
}

.critical-detail-row {
  cursor: pointer;
}

.critical-detail-row:hover {
  background: #fff1ef;
}

.detail-focus {
  animation: detail-focus-pulse 2.4s ease-out;
  outline: 3px solid rgba(193, 18, 31, .35);
  outline-offset: 3px;
}

@keyframes detail-focus-pulse {
  0%, 35% { box-shadow: 0 0 0 7px rgba(193, 18, 31, .16); }
  100% { box-shadow: 0 0 0 0 rgba(193, 18, 31, 0); }
}

.microsoft-detail {
  margin-top: 18px;
}

.clickable-row:hover {
  background: #f7faf8;
}

.clickable-row:focus {
  outline: 2px solid var(--blue);
  outline-offset: -2px;
}

.server-cell strong,
.server-cell span {
  display: block;
}

.server-cell span {
  color: var(--muted);
  font-size: 12px;
  margin-top: 3px;
}

.session-users {
  display: grid;
  gap: 3px;
  min-width: 190px;
}

.session-users span {
  color: var(--ink);
  font-size: 12px;
  overflow-wrap: anywhere;
}

.session-users-empty,
.session-users-na {
  color: var(--muted);
  font-size: 12px;
  white-space: nowrap;
}

.status-pill {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  border-radius: 999px;
  padding: 5px 9px;
  font-size: 13px;
  font-weight: 700;
}

.status-pill.healthy {
  background: var(--green-soft);
  color: var(--green);
}

.status-pill.warning {
  background: var(--amber-soft);
  color: var(--amber);
}

.status-pill.critical {
  background: var(--red-strong);
  color: #fff;
}

.status-pill.planned {
  background: var(--blue-soft);
  color: var(--blue);
}

.status-pill.reserve {
  background: var(--blue-soft);
  color: var(--blue);
}

.check-pill {
  display: inline-grid;
  place-items: center;
  min-width: 78px;
  min-height: 30px;
  border-radius: 999px;
  border: 1px solid transparent;
  padding: 6px 10px;
  font-size: 12px;
  font-weight: 800;
  line-height: 1;
  white-space: nowrap;
  text-decoration: none;
}

#devicesPage table {
  min-width: 1180px;
}

#devicesPage th:first-child,
#devicesPage td:first-child {
  width: 280px;
}

#devicesPage th:nth-child(4),
#devicesPage td:nth-child(4) {
  width: 220px;
}

#devicesPage td:nth-child(4) .check-pill {
  max-width: 220px;
  white-space: normal;
  line-height: 1.25;
  text-align: center;
  padding-block: 7px;
}

.logbook-controls {
  display: grid;
  grid-template-columns: minmax(260px, 2fr) minmax(180px, 1fr) minmax(160px, 1fr);
  gap: 14px;
  margin: 18px 0;
}

.logbook-coverage {
  margin: 10px 0 14px;
  padding: 10px 12px;
  border-radius: 8px;
  background: #f3f7f5;
  color: #52625e;
  font-size: 13px;
}

.logbook-controls label {
  display: grid;
  gap: 6px;
}

.logbook-controls label > span {
  color: var(--muted);
  font-size: 0.82rem;
  font-weight: 700;
}

.logbook-controls input,
.logbook-controls select {
  width: 100%;
}

#endpointEntraPanel {
  margin-top: 18px;
}

#endpointEntraPanel .table-wrap {
  max-height: 520px;
  overflow: auto;
}

@media (max-width: 900px) {
  .logbook-controls {
    grid-template-columns: 1fr;
  }
}

.device-name-cell strong,
.device-name-cell .muted {
  display: block;
}

.device-inline-status {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-top: 9px;
  max-width: 260px;
}

.device-inline-status > span {
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
}

.device-inline-status .check-pill {
  min-width: 0;
  max-width: 180px;
  white-space: normal;
  line-height: 1.2;
  text-align: center;
}

.check-pill.healthy {
  background: var(--green-soft);
  color: var(--green);
}

.check-pill.warning {
  background: var(--amber-soft);
  color: var(--amber);
}

.check-pill.critical {
  background: var(--red-strong);
  border-color: #8f0d08;
  color: #fff;
  box-shadow: 0 0 0 2px rgba(193, 18, 31, 0.14);
}

.check-pill.reserve,
.check-pill.planned {
  background: var(--blue-soft);
  color: var(--blue);
}

.check-pill.neutral {
  background: #edf1ef;
  color: var(--muted);
}

.bar {
  width: 94px;
  height: 8px;
  border-radius: 999px;
  background: #e5ece9;
  overflow: hidden;
}

.bar span {
  display: block;
  height: 100%;
  border-radius: inherit;
  background: var(--green);
}

.bar.warning span {
  background: var(--amber);
}

.bar.critical span {
  background: var(--red);
}

.secure-score-panel {
  display: grid;
  grid-template-columns: minmax(180px, 0.8fr) minmax(260px, 1.4fr);
  gap: 18px;
  padding: 18px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
}

.secure-score-main span,
.secure-score-main small {
  display: block;
  color: var(--muted);
}

.secure-score-main strong {
  display: block;
  margin: 8px 0 3px;
  font-size: 32px;
  line-height: 1;
}

.secure-score-main .text-link {
  display: inline-block;
  margin: 10px 0 6px;
}

.secure-score-actions {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
}

.secure-score-actions div {
  border-left: 4px solid var(--blue);
  padding: 6px 10px;
  background: #f8fbfa;
}

.secure-score-actions span {
  display: block;
  color: var(--muted);
  font-size: 12px;
}

.secure-score-actions strong {
  display: block;
  margin-top: 4px;
  font-size: 22px;
}

.secure-score-categories {
  grid-column: 1 / -1;
  display: grid;
  gap: 9px;
}

.secure-score-category {
  display: grid;
  grid-template-columns: 110px minmax(120px, 1fr) 64px;
  gap: 12px;
  align-items: center;
}

.secure-score-category span {
  font-weight: 700;
}

.secure-score-category .bar {
  width: 100%;
}

.secure-score-category strong {
  text-align: right;
}

.list-item {
  display: flex;
  justify-content: space-between;
  gap: 14px;
  align-items: center;
}

.list-main strong,
.list-main span {
  display: block;
}

.list-main span {
  margin-top: 4px;
}

.connector-item {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 8px;
  align-items: center;
}

.connector-item span {
  display: block;
  color: var(--muted);
  font-size: 13px;
  margin-top: 3px;
}

.detail-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
}

.detail-stack {
  display: grid;
  gap: 18px;
}

.detail-section {
  display: grid;
  gap: 14px;
  margin-bottom: 22px;
  padding: 18px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
}

.detail-section > .section-heading {
  margin-bottom: 2px;
  padding-bottom: 12px;
  border-bottom: 1px solid var(--line);
}

.detail-item {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
  padding: 14px;
  border-left: 5px solid var(--line);
}

.detail-item.healthy {
  border-left-color: var(--green);
  background: #f5fbf8;
}

.detail-item.warning {
  border-left-color: var(--amber);
  background: #fffaf0;
}

.detail-item.critical {
  border-left-color: var(--red);
  background: #fff1ef;
}

.detail-item.reserve {
  border-left-color: var(--blue);
  background: #f5fbfe;
}

.detail-item.neutral {
  border-left-color: var(--line);
}

.endpoint-guidance {
  display: grid;
  gap: 10px;
}

.endpoint-guidance article {
  display: grid;
  grid-template-columns: 34px minmax(0, 1fr);
  gap: 10px;
  align-items: center;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--panel-soft);
  padding: 10px 12px;
}

.endpoint-guidance span {
  display: grid;
  width: 28px;
  height: 28px;
  place-items: center;
  border-radius: 999px;
  background: var(--blue-soft);
  color: var(--blue);
  font-weight: 900;
}

.endpoint-guidance strong {
  font-size: 14px;
}

.detail-item span,
.detail-item strong {
  display: block;
}

.detail-item span {
  color: var(--muted);
  font-size: 13px;
  margin-bottom: 6px;
}

.detail-item strong {
  overflow-wrap: anywhere;
}

.text-link {
  color: var(--blue);
  font-weight: 700;
  text-decoration: none;
}

.text-link:hover {
  text-decoration: underline;
}

.users-panel {
  border-top: 1px solid var(--line);
  padding-top: 14px;
}

.issue-list {
  display: grid;
  gap: 10px;
}

.issue-card {
  border: 1px solid var(--line);
  border-left: 5px solid var(--line);
  border-radius: 8px;
  background: #fff;
  padding: 13px 14px;
}

.issue-card.healthy {
  border-left-color: var(--green);
  background: #f5fbf8;
}

.issue-card.warning {
  border-left-color: var(--amber);
  background: #fffaf0;
}

.issue-card.critical {
  border-color: #f0aaa3;
  border-left-color: var(--red-strong);
  background: #fff1ef;
}

.issue-card.reserve {
  border-left-color: var(--blue);
  background: #f5fbfe;
}

.issue-card span,
.issue-card strong,
.issue-card p {
  display: block;
}

.issue-card span {
  color: var(--muted);
  font-size: 13px;
  margin-bottom: 4px;
}

.issue-card p {
  color: var(--muted);
  margin: 7px 0 0;
  line-height: 1.45;
}

.issue-card-header {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  align-items: flex-start;
}

.service-health-panel {
  display: grid;
  gap: 14px;
}

.service-health-table {
  min-width: 640px;
}

.service-health-issue p strong {
  color: var(--ink);
  display: inline;
}

.issue-meta-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 8px;
  margin-top: 12px;
  color: var(--muted);
  font-size: 13px;
}

.issue-meta-grid strong {
  color: var(--ink);
  display: inline;
}

.issue-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-start;
  gap: 8px;
  margin-top: 12px;
}

.small-action {
  border: 1px solid var(--line);
  border-radius: 6px;
  background: #fff;
  color: var(--ink);
  cursor: pointer;
  font-weight: 800;
  padding: 8px 11px;
}

.small-action:hover {
  border-color: var(--blue);
  color: var(--blue);
}

.original-message-box {
  display: inline-block;
}

.original-message-box summary {
  list-style: none;
}

.original-message-box summary::-webkit-details-marker {
  display: none;
}

.original-message-box[open] {
  display: block;
  flex-basis: 100%;
}

.original-message-box pre {
  max-height: 320px;
  overflow: auto;
  white-space: pre-wrap;
  word-break: break-word;
  margin: 10px 0 0;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
  color: var(--ink);
  padding: 12px;
  font: 13px/1.45 Consolas, "Courier New", monospace;
}

.modal-backdrop {
  position: fixed;
  inset: 0;
  z-index: 40;
  display: grid;
  place-items: center;
  padding: 24px;
  background: rgba(13, 29, 37, 0.42);
}

.modal-backdrop[hidden] {
  display: none;
}

.modal-panel {
  width: min(860px, 100%);
  max-height: calc(100vh - 48px);
  overflow: auto;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
  box-shadow: 0 24px 80px rgba(13, 29, 37, 0.25);
}

.modal-heading {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  align-items: flex-start;
  padding: 20px 22px 14px;
  border-bottom: 1px solid var(--line);
}

.modal-heading h2 {
  margin: 4px 0 0;
}

.modal-kicker {
  color: var(--muted);
  font-size: 13px;
  font-weight: 800;
  text-transform: uppercase;
}

.icon-button {
  width: 34px;
  height: 34px;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: #fff;
  cursor: pointer;
  font-weight: 900;
}

.ai-info-body {
  display: grid;
  gap: 12px;
  padding: 18px 22px;
}

.ai-info-section {
  border: 1px solid var(--line);
  border-left: 5px solid var(--blue);
  border-radius: 8px;
  padding: 13px 14px;
  background: #f5fbfe;
}

.ai-info-section h3 {
  margin-bottom: 7px;
}

.ai-info-section p {
  color: var(--muted);
  line-height: 1.5;
}

.ai-prompt-box {
  margin: 0 22px 18px;
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 12px;
}

.ai-prompt-box summary {
  cursor: pointer;
  font-weight: 800;
}

.ai-prompt-box textarea {
  width: 100%;
  min-height: 170px;
  margin-top: 10px;
  border: 1px solid var(--line);
  border-radius: 6px;
  padding: 10px;
  resize: vertical;
  font: inherit;
}

.modal-actions {
  display: flex;
  justify-content: flex-end;
  gap: 10px;
  padding: 14px 22px 20px;
  border-top: 1px solid var(--line);
}

.modal-actions button {
  border: 1px solid var(--line);
  border-radius: 6px;
  background: #fff;
  cursor: pointer;
  font-weight: 800;
  padding: 10px 13px;
}

.modal-actions button:nth-child(2) {
  border-color: var(--blue);
  background: var(--blue);
  color: #fff;
}

body.modal-open {
  overflow: hidden;
}

.compact-table {
  min-width: 760px;
}

.checks-grid,
.runbook-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}

.check-card {
  display: grid;
  gap: 10px;
}

.check-title,
.runbook-title {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  align-items: center;
}

.check-card p {
  color: var(--muted);
  margin-bottom: 0;
}

.runbook-card ol {
  margin: 12px 0 0;
  padding-left: 21px;
  color: var(--muted);
}

.runbook-card li {
  margin: 7px 0;
}

.runbook-title span,
.empty-state span {
  color: var(--muted);
  font-size: 13px;
}

.config-grid,
.inventory-summary {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
}

.inventory-summary {
  grid-template-columns: repeat(5, minmax(0, 1fr));
  margin-bottom: 14px;
}

.inventory-lists {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}

.inventory-card {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
  padding: 13px;
}

.inventory-card ul {
  margin: 10px 0 0;
  padding-left: 18px;
  color: var(--muted);
}

.inventory-card li {
  margin: 6px 0;
}

.config-item {
  background: var(--panel-soft);
  border-radius: 8px;
  padding: 13px;
}

.config-item strong,
.config-item span,
.empty-state strong,
.empty-state span {
  display: block;
}

.config-item strong {
  font-size: 24px;
}

.config-item span {
  color: var(--muted);
  font-size: 13px;
  margin-top: 3px;
}

@media (max-width: 1100px) {
  .domain-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .split-layout,
  .azure-subscription-detail-grid,
  .update-manager-grid,
  .monitor-backup-grid,
  .settings-form {
    grid-template-columns: 1fr;
  }

  .overview-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .detail-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 760px) {
  .app-shell {
    grid-template-columns: 1fr;
  }

  .sidebar {
    position: static;
    height: auto;
    padding: 16px;
  }

  .main-nav {
    gap: 12px;
  }

  .nav-section {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .nav-section-label {
    grid-column: 1 / -1;
    padding-left: 4px;
  }

  .nav-section-bottom {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .main-nav a {
    padding: 10px 6px;
    font-size: 13px;
  }

  main {
    padding: 18px;
  }

  .topbar,
  .page-brand,
  .session-gate,
  .session-gate-main,
  .report-header,
  .section-heading,
  .action-title,
  .list-item,
  .connector-item {
    align-items: flex-start;
    flex-direction: column;
  }

  .topbar-actions,
  .filter-group {
    width: 100%;
    flex-wrap: wrap;
  }

  .domain-grid {
    grid-template-columns: 1fr;
  }

  .overview-grid {
    grid-template-columns: 1fr;
  }

  h1 {
    font-size: 28px;
  }

  .page-logo-wrap {
    width: 58px;
    height: 42px;
  }

  .report-header img {
    width: 110px;
    max-width: 40vw;
  }

  .summary-strip {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .server-summary-grid,
  .detail-grid,
  .report-meta-grid,
  .session-admin-grid {
    grid-template-columns: 1fr;
  }

  .issue-meta-grid {
    grid-template-columns: 1fr;
  }

  .checks-grid,
  .runbook-grid,
  .inventory-lists {
    grid-template-columns: 1fr;
  }

  .phase-grid {
    grid-template-columns: 1fr;
  }

  .inventory-summary {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@page {
  size: A4 landscape;
  margin: 10mm;
}

@media print {
  body * {
    visibility: hidden;
  }

  html,
  body {
    width: 297mm;
    min-height: 210mm;
    background: #fff;
  }

  body.report-printing #reportsPage,
  body.report-printing #reportsPage * {
    visibility: visible;
  }

  body.report-printing #reportsPage {
    display: block !important;
    position: static;
    padding: 0;
    margin: 0;
    width: 100%;
  }

  body.report-printing .report-toolbar,
  body.report-printing #reportsPage > .section-heading {
    display: none;
  }

  body.report-printing .report-document {
    border: 0;
    box-shadow: none;
    padding: 0;
    gap: 10px;
    width: 100%;
  }

  body.report-printing .report-header {
    align-items: center;
    flex-direction: row;
    gap: 12px;
    padding-bottom: 8px;
  }

  body.report-printing .report-header img {
    width: 95px;
    max-height: 52px;
  }

  body.report-printing .report-header h2 {
    font-size: 20px;
    margin: 2px 0;
  }

  body.report-printing .report-header p,
  body.report-printing .panel-label {
    font-size: 10px;
  }

  body.report-printing .report-meta-grid {
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 6px;
  }

  body.report-printing .report-meta-grid article {
    padding: 7px;
  }

  body.report-printing .report-section {
    gap: 8px;
  }

  body.report-printing .report-section-title {
    padding: 7px 10px;
  }

  body.report-printing .report-section-title h2 {
    font-size: 15px;
  }

  body.report-printing .report-section-title strong {
    min-width: 28px;
    height: 24px;
    font-size: 12px;
  }

  body.report-printing .report-component {
    gap: 6px;
    padding: 0 10px 10px;
  }

  body.report-printing .report-component h3 {
    font-size: 13px;
    padding: 6px 0 4px;
  }

  body.report-printing table {
    min-width: 0;
    page-break-inside: auto;
  }

  body.report-printing th,
  body.report-printing td {
    padding: 5px 6px;
    font-size: 10px;
    line-height: 1.25;
  }

  body.report-printing th {
    font-size: 9px;
  }

  body.report-printing .status-pill {
    font-size: 9px;
    padding: 4px 6px;
    white-space: nowrap;
  }

  body.report-printing tr,
  body.report-printing .report-section {
    page-break-inside: avoid;
  }

  #aiInfoModal,
  #aiInfoModal * {
    visibility: visible;
  }

  #aiInfoModal {
    position: static;
    display: block;
    padding: 0;
    background: #fff;
  }

  .modal-panel {
    width: 100%;
    max-height: none;
    overflow: visible;
    border: 0;
    box-shadow: none;
  }

  .modal-actions,
  .icon-button,
  .ai-prompt-box {
    display: none;
  }
}
