html [hidden] { display: none !important; }

.login-page {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
  background: linear-gradient(135deg,#0f172a,#1e293b);
}
.login-box {
  width: 100%;
  max-width: 400px;
  padding: 40px;
  border-radius: 16px;
  background: #fff;
  box-shadow: 0 25px 60px rgba(0,0,0,.3);
}
.login-box h1 { margin: 0 0 8px; color: #0f172a; font-size: 24px; }
.login-sub { color: #64748b; margin-bottom: 28px; font-size: 14px; }
.login-field { margin-bottom: 16px; }
.login-box label { display: block; margin: 0 0 6px; font-size: 13px; color: #475569; font-weight: 500; }
.login-box input { width: 100%; padding: 12px 14px; border: 1px solid #cbd5e1; border-radius: 8px; font-size: 14px; }
.login-box input:focus { outline: none; border-color: #3b82f6; box-shadow: 0 0 0 3px rgba(59,130,246,.1); }
.login-box button { width: 100%; padding: 13px; margin-top: 8px; border: 0; border-radius: 8px; background: #3b82f6; color: #fff; font-size: 15px; cursor: pointer; font-weight: 600; }
.login-box button:hover { background: #2563eb; transform: translateY(-1px); }
.login-error { padding: 12px; margin-bottom: 16px; border-radius: 8px; border-left: 4px solid #dc2626; background: #fee2e2; color: #b91c1c; font-size: 13px; }
.login-footer { margin-top: 24px; text-align: center; font-size: 12px; color: #94a3b8; }

.node-mode-banner { padding: 12px 16px; margin-bottom: 16px; border-radius: 6px; font-size: 13px; }
.node-mode-banner.grace,.node-mode-banner.read_only { display: block; border-left: 4px solid #f59e0b; background: #fef3c7; color: #92400e; }
.node-mode-banner.revoked { display: block; border-left: 4px solid #ef4444; background: #fee2e2; color: #991b1b; }
.node-mode-banner.online { display: none; }
.node-empty { padding: 28px; color: #64748b; text-align: center; }
.node-actions { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; }
.node-muted { color: #64748b; font-size: 12px; }
.node-danger { color: #b91c1c; }
.node-toolbar-select { min-width: 260px; }
.node-card-gap { margin-top: 20px; }
.node-check-grid { display: grid; grid-template-columns: repeat(auto-fit,minmax(260px,1fr)); gap: 8px 16px; max-height: 300px; overflow: auto; padding: 12px; border: 1px solid #e4e9f1; border-radius: 8px; }
.node-subcard { margin: 12px 0; padding: 16px; border: 1px solid #e2e8f0; border-radius: 9px; background: #f8fafc; }
.node-subcard .node-check-grid { margin: 10px 0; background: #fff; }
.node-log { max-width: 900px; max-height: 320px; overflow: auto; white-space: pre-wrap; word-break: break-word; background: #101827; color: #dce7ff; padding: 12px; border-radius: 8px; }
button:disabled,input:disabled,select:disabled,textarea:disabled { opacity: .55; cursor: not-allowed; }

/* Node-backed page components use the original CMS visual language. */
.metrics { display: grid; grid-template-columns: repeat(auto-fit,minmax(180px,1fr)); gap: 16px; margin-bottom: 20px; }
.metric { background: #fff; padding: 20px; border-radius: 10px; border-left: 4px solid #3b82f6; transition: .2s; }
.metric:hover { transform: translateY(-2px); box-shadow: 0 4px 12px rgba(0,0,0,.08); }
.metric strong { display: block; font-size: 26px; font-weight: 700; color: #1e293b; line-height: 1.1; }
.metric small { display: block; font-size: 12px; color: #64748b; margin-top: 6px; }
.panel { background: #fff; border-radius: 10px; padding: 20px; box-shadow: 0 1px 3px rgba(0,0,0,.05); margin-bottom: 20px; }
.panel h2 { margin: 0 0 16px; font-size: 16px; font-weight: 600; }
.panel-head,.actions,.row { display: flex; align-items: center; gap: 10px; }
.panel-head { justify-content: space-between; margin-bottom: 16px; }
.panel-head h2 { margin-bottom: 0; }
.grow { flex: 1; }
.fields-2,.fields-3 { display: grid; gap: 16px; }
.fields-2 { grid-template-columns: 1fr 1fr; }
.fields-3 { grid-template-columns: repeat(3,1fr); }
.split { display: grid; grid-template-columns: 320px 1fr; gap: 16px; }
.list { border-right: 1px solid #e2e8f0; padding-right: 16px; }
.list-item { border: 1px solid #e2e8f0; padding: 12px; border-radius: 8px; margin-bottom: 8px; cursor: pointer; }
.list-item:hover,.list-item.active { border-color: #3b82f6; background: #eff6ff; }
.list-item strong,.list-item small { display: block; }
.list-item small { color: #64748b; margin-top: 4px; }
.table-wrap { overflow: auto; }
.empty { padding: 26px; text-align: center; color: #64748b; }
.hint { color: #64748b; font-size: 13px; line-height: 1.7; }
.policy { padding: 16px; border: 1px solid #e2e8f0; border-radius: 9px; margin: 10px 0; }
.policy strong,.policy span { display: block; }
.policy strong { margin-bottom: 6px; }
.badge { display: inline-block; border-radius: 999px; padding: 4px 9px; font-size: 12px; font-weight: 700; }
.badge.online,.badge.installed { background: #dcfce7; color: #087653; }
.badge.grace,.badge.pending,.badge.ready,.badge.building { background: #fef3c7; color: #92400e; }
.badge.revoked,.badge.failed,.badge.read_only { background: #fee2e2; color: #991b1b; }
.primary,.secondary,.success,.danger,.ghost { display: inline-block; padding: 8px 16px; border: 0; border-radius: 6px; cursor: pointer; font-weight: 500; }
.primary { background: #3b82f6; color: #fff; }
.secondary { background: #64748b; color: #fff; }
.success { background: #10b981; color: #fff; }
.danger { background: #ef4444; color: #fff; }
.ghost { background: #fff; color: #475569; border: 1px solid #cbd5e1; }
.wide { width: 100%; }
@media(max-width:1000px){.split{grid-template-columns:1fr}.list{border-right:0;border-bottom:1px solid #e2e8f0;padding:0 0 12px}}
@media(max-width:720px){.fields-2,.fields-3{grid-template-columns:1fr}}
