/*
 * ============================================================
 * InfraBit Shield — Brand Theme CSS  v3.0
 * Industry-grade light theme. No gradients, no glass.
 * Clean, structured, polished — Linear/Vercel aesthetic.
 * infrabit.co | info@infrabit.co
 * ============================================================
 */

@import url('https://fonts.googleapis.com/css2?family=Plus+Jakarta+Sans:ital,wght@0,300;0,400;0,500;0,600;0,700;0,800;1,400&family=Inter:wght@400;500;600;700&family=DM+Sans:wght@400;500;600;700&family=Nunito:wght@400;500;600;700;800&family=Outfit:wght@400;500;600;700;800&family=Sora:wght@400;500;600;700&family=Figtree:wght@400;500;600;700;800&family=JetBrains+Mono:wght@400;500&display=swap');

/* ─────────────────────────────────────────────────────────────
   DESIGN TOKENS
   ───────────────────────────────────────────────────────────── */
:root {
  /* Brand (overridden by settings.php) */
  --brand-primary:   #2563eb;
  --brand-accent:    #059669;
  --brand-sidebar:   #0f1f3d;
  --brand-font:      'Plus Jakarta Sans', -apple-system, BlinkMacSystemFont, sans-serif;
  --btn-radius:      8px;

  /* Derived from brand */
  --ib-blue:         var(--brand-primary);
  --ib-blue-dk:      color-mix(in srgb, var(--brand-primary) 80%, #000);
  --ib-blue-lt:      color-mix(in srgb, var(--brand-primary) 55%, #fff);
  --ib-blue-bg:      color-mix(in srgb, var(--brand-primary) 7%, #fff);
  --ib-blue-bg2:     color-mix(in srgb, var(--brand-primary) 12%, #fff);
  --ib-blue-border:  color-mix(in srgb, var(--brand-primary) 22%, #fff);

  /* Semantic colors */
  --ib-teal:         #059669;
  --ib-teal-dk:      #047857;
  --ib-teal-lt:      #34d399;
  --ib-teal-bg:      #f0fdf9;
  --ib-teal-border:  #6ee7b7;

  --ib-amber:        #d97706;
  --ib-amber-dk:     #92400e;
  --ib-amber-bg:     #fffbeb;
  --ib-amber-border: #fcd34d;

  --ib-red:          #dc2626;
  --ib-red-dk:       #991b1b;
  --ib-red-bg:       #fff5f5;
  --ib-red-border:   #fca5a5;

  --ib-purple:       #7c3aed;
  --ib-purple-bg:    #f5f3ff;
  --ib-purple-border:#c4b5fd;

  --ib-orange:       #ea580c;
  --ib-orange-bg:    #fff7ed;
  --ib-orange-border:#fdba74;

  /* Navy / Sidebar */
  --ib-navy:         var(--brand-sidebar);
  --ib-navy-lt:      color-mix(in srgb, var(--brand-sidebar) 85%, #fff);
  --ib-navy-2:       color-mix(in srgb, var(--brand-sidebar) 92%, #fff);

  /* Neutral scale */
  --ib-white:        #ffffff;
  --ib-gray-25:      #fcfcfd;
  --ib-gray-50:      #f8fafc;
  --ib-gray-100:     #f1f5f9;
  --ib-gray-150:     #e8eef4;
  --ib-gray-200:     #e2e8f0;
  --ib-gray-300:     #cbd5e1;
  --ib-gray-400:     #94a3b8;
  --ib-gray-500:     #64748b;
  --ib-gray-600:     #475569;
  --ib-gray-700:     #334155;
  --ib-gray-800:     #1e293b;
  --ib-gray-900:     #0f172a;

  /* Typography */
  --ib-font:         var(--brand-font);
  --ib-font-mono:    'JetBrains Mono', 'Fira Code', ui-monospace, monospace;

  /* Refined shadow system */
  --ib-shadow-xs:    0 1px 2px rgba(15,23,42,.04);
  --ib-shadow-sm:    0 1px 3px rgba(15,23,42,.07), 0 1px 2px rgba(15,23,42,.04);
  --ib-shadow:       0 2px 8px rgba(15,23,42,.08), 0 1px 3px rgba(15,23,42,.05);
  --ib-shadow-md:    0 4px 16px rgba(15,23,42,.09), 0 2px 6px rgba(15,23,42,.05);
  --ib-shadow-lg:    0 8px 32px rgba(15,23,42,.10), 0 4px 12px rgba(15,23,42,.06);
  --ib-shadow-xl:    0 20px 48px rgba(15,23,42,.12), 0 8px 20px rgba(15,23,42,.07);
  --ib-shadow-focus: 0 0 0 3px color-mix(in srgb, var(--brand-primary) 20%, transparent);

  /* Border radius */
  --ib-radius-xs:    4px;
  --ib-radius-sm:    6px;
  --ib-radius:       10px;
  --ib-radius-lg:    14px;
  --ib-radius-xl:    20px;

  /* Sidebar */
  --ib-sidebar-w:    248px;

  /* Transitions */
  --ib-ease:         cubic-bezier(0.16, 1, 0.3, 1);
  --ib-ease-out:     cubic-bezier(0, 0, 0.2, 1);
}

/* ─────────────────────────────────────────────────────────────
   RESET
   ───────────────────────────────────────────────────────────── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body {
  font-family: var(--ib-font);
  background: var(--ib-gray-50);
  color: var(--ib-gray-800);
  line-height: 1.6;
  font-size: 14px;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
}
a { color: var(--ib-blue); text-decoration: none; }
a:hover { text-decoration: underline; color: var(--ib-blue-dk); }
img { display: block; max-width: 100%; }
button, input, select, textarea { font-family: var(--ib-font); }

/* ─────────────────────────────────────────────────────────────
   TYPOGRAPHY
   ───────────────────────────────────────────────────────────── */
.ib-display { font-size: clamp(32px,5vw,56px); font-weight: 800; line-height: 1.08; letter-spacing:-.03em; color: var(--ib-gray-900); }
.ib-h1     { font-size: clamp(22px,3vw,32px); font-weight: 700; letter-spacing:-.025em; line-height: 1.2; color: var(--ib-gray-900); }
.ib-h2     { font-size: clamp(18px,2.5vw,24px); font-weight: 700; letter-spacing:-.02em; color: var(--ib-gray-900); }
.ib-h3     { font-size: 16px; font-weight: 600; letter-spacing:-.012em; color: var(--ib-gray-800); }
.ib-h4     { font-size: 14px; font-weight: 600; color: var(--ib-gray-700); }
.ib-lead   { font-size: 15px; color: var(--ib-gray-500); line-height: 1.65; }
.ib-caption { font-size: 12px; color: var(--ib-gray-400); letter-spacing:.01em; }
.ib-label-upper { font-size: 11px; font-weight: 700; letter-spacing:.07em; text-transform: uppercase; color: var(--ib-gray-500); }
.ib-mono   { font-family: var(--ib-font-mono); }

/* ─────────────────────────────────────────────────────────────
   LAYOUT
   ───────────────────────────────────────────────────────────── */
.ib-container { max-width: 1160px; margin: 0 auto; padding: 0 28px; }
.ib-app { display: flex; min-height: 100vh; }
.ib-main { margin-left: var(--ib-sidebar-w); flex: 1; display: flex; flex-direction: column; min-width: 0; }

/* ─────────────────────────────────────────────────────────────
   BUTTONS
   ───────────────────────────────────────────────────────────── */
.ib-btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 6px;
  padding: 9px 20px; border-radius: var(--btn-radius);
  font-size: 13.5px; font-weight: 600; font-family: var(--ib-font);
  letter-spacing: -.01em; border: none; cursor: pointer;
  transition: box-shadow .15s var(--ib-ease), transform .12s var(--ib-ease), filter .12s;
  white-space: nowrap; text-decoration: none; line-height: 1;
  position: relative; user-select: none;
}
.ib-btn:hover { text-decoration: none; }
.ib-btn:active { transform: translateY(0) !important; filter: brightness(.96) !important; }
.ib-btn:focus-visible { outline: none; box-shadow: var(--ib-shadow-focus); }

.ib-btn-primary {
  background: var(--ib-blue); color: #fff;
  box-shadow: 0 1px 3px rgba(15,23,42,.15), inset 0 1px 0 rgba(255,255,255,.15);
}
.ib-btn-primary:hover {
  filter: brightness(1.06);
  box-shadow: 0 3px 10px color-mix(in srgb, var(--brand-primary) 35%, transparent), inset 0 1px 0 rgba(255,255,255,.15);
  transform: translateY(-1px);
}
.ib-btn-navy {
  background: var(--ib-navy); color: #fff;
  box-shadow: 0 1px 3px rgba(15,23,42,.2), inset 0 1px 0 rgba(255,255,255,.08);
}
.ib-btn-navy:hover { filter: brightness(1.12); transform: translateY(-1px); }
.ib-btn-outline {
  background: #fff; color: var(--ib-blue);
  border: 1.5px solid var(--ib-blue-border); box-shadow: var(--ib-shadow-xs);
}
.ib-btn-outline:hover { background: var(--ib-blue-bg); border-color: var(--ib-blue); box-shadow: var(--ib-shadow-sm); }
.ib-btn-ghost {
  background: #fff; color: var(--ib-gray-700);
  border: 1.5px solid var(--ib-gray-200); box-shadow: var(--ib-shadow-xs);
}
.ib-btn-ghost:hover { border-color: var(--ib-gray-300); color: var(--ib-gray-900); box-shadow: var(--ib-shadow-sm); }
.ib-btn-white {
  background: #fff; color: var(--ib-navy);
  box-shadow: var(--ib-shadow-sm); border: 1.5px solid var(--ib-gray-150);
}
.ib-btn-white:hover { box-shadow: var(--ib-shadow-md); transform: translateY(-1px); }
.ib-btn-danger {
  background: var(--ib-red-bg); color: var(--ib-red-dk);
  border: 1.5px solid var(--ib-red-border);
}
.ib-btn-danger:hover { background: var(--ib-red); color: #fff; border-color: var(--ib-red); }
.ib-btn-success {
  background: var(--ib-teal-bg); color: var(--ib-teal-dk);
  border: 1.5px solid var(--ib-teal-border);
}
.ib-btn-success:hover { background: var(--ib-teal); color: #fff; border-color: var(--ib-teal); }

.ib-btn-xs { padding: 5px 10px; font-size: 11.5px; }
.ib-btn-sm { padding: 7px 14px; font-size: 12.5px; }
.ib-btn-lg { padding: 12px 28px; font-size: 15px; }
.ib-btn-xl { padding: 14px 36px; font-size: 16px; font-weight: 700; }
.ib-btn-icon { padding: 8px; width: 34px; height: 34px; border-radius: var(--ib-radius-sm); }
.ib-btn-icon.ib-btn-sm { width: 28px; height: 28px; padding: 5px; }

/* ─────────────────────────────────────────────────────────────
   BADGES
   ───────────────────────────────────────────────────────────── */
.ib-badge {
  display: inline-flex; align-items: center; gap: 4px;
  font-size: 11px; font-weight: 600; padding: 2px 8px;
  border-radius: 5px; letter-spacing: .03em;
  border: 1px solid transparent; line-height: 1.6;
}
.ib-badge-pill { border-radius: 100px; }
.ib-badge-blue   { background: var(--ib-blue-bg);    color: var(--ib-blue-dk);  border-color: var(--ib-blue-border); }
.ib-badge-teal   { background: var(--ib-teal-bg);    color: var(--ib-teal-dk);  border-color: var(--ib-teal-border); }
.ib-badge-amber  { background: var(--ib-amber-bg);   color: var(--ib-amber-dk); border-color: var(--ib-amber-border); }
.ib-badge-red    { background: var(--ib-red-bg);     color: var(--ib-red-dk);   border-color: var(--ib-red-border); }
.ib-badge-purple { background: var(--ib-purple-bg);  color: var(--ib-purple);   border-color: var(--ib-purple-border); }
.ib-badge-orange { background: var(--ib-orange-bg);  color: var(--ib-orange);   border-color: var(--ib-orange-border); }
.ib-badge-navy   { background: var(--ib-navy); color: #fff; }
.ib-badge-gray   { background: var(--ib-gray-100); color: var(--ib-gray-600); border-color: var(--ib-gray-200); }

/* ─────────────────────────────────────────────────────────────
   CARDS
   ───────────────────────────────────────────────────────────── */
.ib-card {
  background: var(--ib-white); border: 1px solid var(--ib-gray-200);
  border-radius: var(--ib-radius-lg); box-shadow: var(--ib-shadow-sm);
}
.ib-card-elevated { box-shadow: var(--ib-shadow-md); }
.ib-card-flat     { box-shadow: none; border-color: var(--ib-gray-150); }

.ib-card-head {
  display: flex; align-items: center; justify-content: space-between;
  padding: 16px 20px 14px; border-bottom: 1px solid var(--ib-gray-100);
}
.ib-card-title {
  font-size: 14px; font-weight: 700; color: var(--ib-gray-900);
  letter-spacing: -.01em; display: flex; align-items: center; gap: 8px;
}
.ib-card-title-icon {
  width: 28px; height: 28px; border-radius: 7px;
  background: var(--ib-blue-bg); display: grid;
  place-items: center; font-size: 14px; flex-shrink: 0;
}
.ib-card-meta { font-size: 12px; color: var(--ib-gray-400); }
.ib-card-body    { padding: 20px; }
.ib-card-body-sm { padding: 14px 20px; }
.ib-card-footer {
  padding: 12px 20px; border-top: 1px solid var(--ib-gray-100);
  background: var(--ib-gray-25);
  border-radius: 0 0 var(--ib-radius-lg) var(--ib-radius-lg);
  display: flex; align-items: center; justify-content: space-between;
}
.ib-card-accent-blue  { border-top: 3px solid var(--ib-blue); }
.ib-card-accent-teal  { border-top: 3px solid var(--ib-teal); }
.ib-card-accent-amber { border-top: 3px solid var(--ib-amber); }
.ib-card-accent-red   { border-top: 3px solid var(--ib-red); }
.ib-card-accent-brand { border-top: 3px solid var(--brand-primary); }

/* ─────────────────────────────────────────────────────────────
   FORMS
   ───────────────────────────────────────────────────────────── */
.ib-field { margin-bottom: 18px; }
.ib-field:last-child { margin-bottom: 0; }
.ib-label {
  display: block; font-size: 12px; font-weight: 600;
  color: var(--ib-gray-700); letter-spacing: .01em; margin-bottom: 6px;
}
.ib-label-hint { font-size: 11px; color: var(--ib-gray-400); margin-top: 4px; line-height: 1.5; }

.ib-input, .ib-select, .ib-textarea {
  width: 100%; padding: 9px 13px;
  border: 1.5px solid var(--ib-gray-200); border-radius: var(--ib-radius-sm);
  font-family: var(--ib-font); font-size: 13.5px; color: var(--ib-gray-900);
  background: #fff; transition: border-color .15s, box-shadow .15s;
  outline: none; appearance: none;
}
.ib-input:hover, .ib-select:hover { border-color: var(--ib-gray-300); }
.ib-input:focus, .ib-select:focus, .ib-textarea:focus {
  border-color: var(--ib-blue); box-shadow: var(--ib-shadow-focus);
}
.ib-input::placeholder, .ib-textarea::placeholder { color: var(--ib-gray-400); }
.ib-input-error { border-color: var(--ib-red) !important; }
.ib-input-error:focus { box-shadow: 0 0 0 3px rgba(220,38,38,.15) !important; }
.ib-select {
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' fill='none'%3E%3Cpath d='M1 1l5 5 5-5' stroke='%2364748b' stroke-width='1.5' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
  background-repeat: no-repeat; background-position: right 12px center;
  padding-right: 36px; cursor: pointer;
}
.ib-textarea { resize: vertical; min-height: 88px; line-height: 1.6; }

.ib-input-group { position: relative; display: flex; align-items: center; }
.ib-input-group .ib-input { flex: 1; }
.ib-input-prefix { position: absolute; left: 12px; color: var(--ib-gray-400); font-size: 13px; pointer-events: none; z-index: 1; }
.ib-input-prefix + .ib-input { padding-left: 32px; }

.ib-color-wrap { display: flex; align-items: center; gap: 10px; }
.ib-color-swatch {
  width: 38px; height: 38px; border-radius: var(--ib-radius-sm);
  border: 2px solid var(--ib-gray-200); cursor: pointer; flex-shrink: 0;
  overflow: hidden; padding: 0; background: none; transition: border-color .15s;
}
.ib-color-swatch:hover { border-color: var(--ib-gray-400); }
.ib-color-swatch input[type=color] { width: 100%; height: 100%; padding: 0; border: none; cursor: pointer; background: none; outline: none; transform: scale(1.3); }

.ib-toggle { position: relative; display: inline-flex; align-items: center; gap: 10px; cursor: pointer; user-select: none; }
.ib-toggle input { position: absolute; opacity: 0; width: 0; height: 0; }
.ib-toggle-track { width: 38px; height: 22px; border-radius: 100px; background: var(--ib-gray-200); transition: background .2s; position: relative; flex-shrink: 0; }
.ib-toggle-track::after { content: ''; position: absolute; top: 3px; left: 3px; width: 16px; height: 16px; border-radius: 50%; background: #fff; box-shadow: 0 1px 3px rgba(0,0,0,.2); transition: transform .2s var(--ib-ease); }
.ib-toggle input:checked + .ib-toggle-track { background: var(--ib-blue); }
.ib-toggle input:checked + .ib-toggle-track::after { transform: translateX(16px); }
.ib-toggle-label { font-size: 13px; font-weight: 500; color: var(--ib-gray-700); }

/* ─────────────────────────────────────────────────────────────
   ALERTS
   ───────────────────────────────────────────────────────────── */
.ib-alert {
  display: flex; align-items: flex-start; gap: 12px;
  padding: 12px 16px; border-radius: var(--ib-radius);
  font-size: 13.5px; line-height: 1.55;
  border: 1px solid transparent; border-left-width: 4px;
}
.ib-alert-icon { font-size: 16px; margin-top: 1px; flex-shrink: 0; }
.ib-alert-success { background: var(--ib-teal-bg); color: var(--ib-teal-dk); border-color: var(--ib-teal-border); border-left-color: var(--ib-teal); }
.ib-alert-error   { background: var(--ib-red-bg); color: var(--ib-red-dk); border-color: var(--ib-red-border); border-left-color: var(--ib-red); }
.ib-alert-info    { background: var(--ib-blue-bg); color: var(--ib-blue-dk); border-color: var(--ib-blue-border); border-left-color: var(--ib-blue); }
.ib-alert-warning { background: var(--ib-amber-bg); color: var(--ib-amber-dk); border-color: var(--ib-amber-border); border-left-color: var(--ib-amber); }

/* ─────────────────────────────────────────────────────────────
   SIDEBAR
   ───────────────────────────────────────────────────────────── */
.ib-sidebar {
  width: var(--ib-sidebar-w); flex-shrink: 0;
  background: var(--brand-sidebar); display: flex; flex-direction: column;
  position: fixed; top: 0; left: 0; bottom: 0;
  z-index: 200; overflow-y: auto; overflow-x: hidden;
  border-right: 1px solid rgba(0,0,0,.12);
}
.ib-sidebar::-webkit-scrollbar { width: 4px; }
.ib-sidebar::-webkit-scrollbar-track { background: transparent; }
.ib-sidebar::-webkit-scrollbar-thumb { background: rgba(255,255,255,.12); border-radius: 4px; }

.ib-sidebar-brand {
  padding: 18px 16px 16px;
  display: flex; align-items: center; gap: 10px;
  border-bottom: 1px solid rgba(255,255,255,.06);
}
.ib-sidebar-logo {
  width: 34px; height: 34px; border-radius: 9px;
  background: var(--brand-primary); display: grid; place-items: center;
  flex-shrink: 0; font-size: 17px; box-shadow: 0 2px 8px rgba(0,0,0,.25);
}
.ib-sidebar-name { font-size: 14px; font-weight: 800; color: #fff; letter-spacing: -.015em; line-height: 1.2; }
.ib-sidebar-tagline { font-size: 10px; color: rgba(255,255,255,.3); margin-top: 1px; font-weight: 500; letter-spacing: .04em; text-transform: uppercase; }

.ib-nav-section {
  padding: 18px 16px 5px;
  font-size: 9.5px; font-weight: 700;
  letter-spacing: .12em; text-transform: uppercase;
  color: rgba(255,255,255,.2);
}
.ib-nav-group { padding: 4px 8px; }

.ib-nav-item {
  display: flex; align-items: center; gap: 8px;
  padding: 8px 10px; border-radius: 7px;
  font-size: 13px; font-weight: 500;
  color: rgba(255,255,255,.55); cursor: pointer;
  transition: background .12s, color .12s;
  text-decoration: none; position: relative;
}
.ib-nav-item:hover { background: rgba(255,255,255,.07); color: rgba(255,255,255,.9); text-decoration: none; }
.ib-nav-item.active { background: rgba(255,255,255,.1); color: #fff; font-weight: 600; }
.ib-nav-item.active::before {
  content: ''; position: absolute; left: -8px; top: 50%;
  transform: translateY(-50%); width: 3px; height: 16px;
  background: var(--brand-primary); border-radius: 0 2px 2px 0;
}
.ib-nav-icon { font-size: 14px; width: 18px; text-align: center; flex-shrink: 0; opacity: .8; }
.ib-nav-item.active .ib-nav-icon { opacity: 1; }
.ib-nav-badge { margin-left: auto; background: var(--ib-red); color: #fff; font-size: 10px; font-weight: 700; padding: 1px 6px; border-radius: 100px; min-width: 18px; text-align: center; }

.ib-sidebar-bottom {
  margin-top: auto; padding: 10px;
  border-top: 1px solid rgba(255,255,255,.06);
}
.ib-user-row {
  display: flex; align-items: center; gap: 10px;
  padding: 10px; border-radius: 8px; cursor: default;
  transition: background .12s;
}
.ib-user-row:hover { background: rgba(255,255,255,.05); }
.ib-user-avatar {
  width: 32px; height: 32px; border-radius: 50%;
  background: rgba(255,255,255,.12); display: grid; place-items: center;
  font-size: 13px; font-weight: 700; color: #fff; flex-shrink: 0;
  border: 1.5px solid rgba(255,255,255,.15);
}
.ib-user-name  { font-size: 13px; font-weight: 600; color: #fff; line-height: 1.25; }
.ib-user-email { font-size: 11px; color: rgba(255,255,255,.35); }

/* ─────────────────────────────────────────────────────────────
   TOPBAR
   ───────────────────────────────────────────────────────────── */
.ib-topbar {
  background: #fff; border-bottom: 1px solid var(--ib-gray-150);
  height: 56px; padding: 0 28px;
  display: flex; align-items: center; justify-content: space-between;
  position: sticky; top: 0; z-index: 100;
}
.ib-topbar-left  { display: flex; align-items: center; gap: 14px; }
.ib-topbar-right { display: flex; align-items: center; gap: 8px; }
.ib-topbar-title { font-size: 16px; font-weight: 700; color: var(--ib-gray-900); letter-spacing: -.018em; }
.ib-breadcrumb   { display: flex; align-items: center; gap: 6px; font-size: 13px; }
.ib-breadcrumb-item { color: var(--ib-gray-500); font-weight: 500; }
.ib-breadcrumb-item a { color: inherit; }
.ib-breadcrumb-item a:hover { color: var(--ib-blue); text-decoration: none; }
.ib-breadcrumb-sep { color: var(--ib-gray-300); font-size: 12px; }
.ib-breadcrumb-item.current { color: var(--ib-gray-900); font-weight: 600; }

.ib-topbar-avatar {
  width: 32px; height: 32px; border-radius: 50%;
  background: var(--ib-blue-bg); display: grid; place-items: center;
  font-size: 12px; font-weight: 700; color: var(--ib-blue);
  cursor: pointer; border: 1.5px solid var(--ib-blue-border);
  transition: box-shadow .15s;
}
.ib-topbar-avatar:hover { box-shadow: var(--ib-shadow-sm); }

/* ─────────────────────────────────────────────────────────────
   TABLES
   ───────────────────────────────────────────────────────────── */
.ib-table { width: 100%; border-collapse: collapse; font-size: 13px; }
.ib-table thead th {
  text-align: left; font-size: 11px; font-weight: 700;
  text-transform: uppercase; letter-spacing: .07em; color: var(--ib-gray-500);
  padding: 0 12px 10px; border-bottom: 1px solid var(--ib-gray-150);
  white-space: nowrap;
}
.ib-table thead th:first-child { padding-left: 20px; }
.ib-table thead th:last-child  { padding-right: 20px; }
.ib-table tbody td {
  padding: 12px; border-bottom: 1px solid var(--ib-gray-100);
  vertical-align: middle; color: var(--ib-gray-700);
}
.ib-table tbody td:first-child { padding-left: 20px; }
.ib-table tbody td:last-child  { padding-right: 20px; }
.ib-table tbody tr:last-child td { border-bottom: none; }
.ib-table-hover tbody tr { transition: background .1s; }
.ib-table-hover tbody tr:hover { background: var(--ib-gray-25); }

/* ─────────────────────────────────────────────────────────────
   STAT CARDS
   ───────────────────────────────────────────────────────────── */
.ib-stat-grid { display: grid; grid-template-columns: repeat(4,1fr); gap: 16px; }
.ib-stat-card {
  background: #fff; border: 1px solid var(--ib-gray-200);
  border-radius: var(--ib-radius-lg); padding: 20px 20px 18px;
  position: relative; box-shadow: var(--ib-shadow-sm);
  transition: box-shadow .18s, transform .18s;
}
.ib-stat-card:hover { box-shadow: var(--ib-shadow-md); transform: translateY(-1px); }
.ib-stat-card-top { display: flex; align-items: flex-start; justify-content: space-between; margin-bottom: 14px; }
.ib-stat-icon { width: 40px; height: 40px; border-radius: 10px; display: grid; place-items: center; font-size: 18px; flex-shrink: 0; }
.ib-stat-icon-blue   { background: var(--ib-blue-bg);   }
.ib-stat-icon-teal   { background: var(--ib-teal-bg);   }
.ib-stat-icon-amber  { background: var(--ib-amber-bg);  }
.ib-stat-icon-red    { background: var(--ib-red-bg);    }
.ib-stat-icon-purple { background: var(--ib-purple-bg); }
.ib-stat-trend { font-size: 12px; font-weight: 600; display: flex; align-items: center; gap: 3px; }
.ib-stat-trend-up   { color: var(--ib-teal); }
.ib-stat-trend-down { color: var(--ib-red); }
.ib-stat-label { font-size: 11.5px; font-weight: 600; color: var(--ib-gray-500); text-transform: uppercase; letter-spacing: .06em; margin-bottom: 4px; }
.ib-stat-value { font-size: 28px; font-weight: 800; color: var(--ib-gray-900); letter-spacing: -.025em; line-height: 1; font-variant-numeric: tabular-nums; }
.ib-stat-sub   { font-size: 11.5px; color: var(--ib-gray-400); margin-top: 5px; font-weight: 500; }
.ib-stat-bar   { margin-top: 14px; height: 3px; background: var(--ib-gray-100); border-radius: 100px; overflow: hidden; }
.ib-stat-bar-fill { height: 100%; border-radius: 100px; background: var(--brand-primary); transition: width .5s var(--ib-ease); }

/* ─────────────────────────────────────────────────────────────
   SCORE — security score displays
   ───────────────────────────────────────────────────────────── */
.score-safe   { color: var(--ib-teal);  }
.score-low    { color: var(--ib-blue);  }
.score-medium { color: var(--ib-amber); }
.score-high   { color: var(--ib-red);   }

.ib-score-ring {
  width: 56px; height: 56px; border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  font-size: 15px; font-weight: 800; letter-spacing: -.03em; border: 3px solid;
}
.score-safe.ib-score-ring   { border-color: var(--ib-teal-border);  }
.score-low.ib-score-ring    { border-color: var(--ib-blue-border);  }
.score-medium.ib-score-ring { border-color: var(--ib-amber-border); }
.score-high.ib-score-ring   { border-color: var(--ib-red-border);   }

/* ─────────────────────────────────────────────────────────────
   PROGRESS BAR
   ───────────────────────────────────────────────────────────── */
.ib-bar-wrap { height: 6px; background: var(--ib-gray-100); border-radius: 100px; overflow: hidden; }
.ib-bar-fill { height: 100%; border-radius: 100px; transition: width .5s var(--ib-ease); background: var(--brand-primary); }
.ib-bar-fill-safe   { background: var(--ib-teal); }
.ib-bar-fill-medium { background: var(--ib-amber); }
.ib-bar-fill-high   { background: var(--ib-red); }
.ib-bar-wrap-sm     { height: 4px; }
.ib-bar-wrap-lg     { height: 8px; }

/* ─────────────────────────────────────────────────────────────
   SEVERITY / STATUS INDICATORS
   ───────────────────────────────────────────────────────────── */
.ib-sev {
  display: inline-flex; align-items: center; gap: 5px;
  font-size: 11px; font-weight: 700; padding: 3px 8px;
  border-radius: 5px; letter-spacing: .04em; text-transform: uppercase;
}
.ib-sev::before { content: ''; width: 5px; height: 5px; border-radius: 50%; background: currentColor; }
.ib-sev-critical { background: #fdf2f8; color: #9d174d; }
.ib-sev-high     { background: var(--ib-red-bg); color: var(--ib-red-dk); }
.ib-sev-medium   { background: var(--ib-amber-bg); color: var(--ib-amber-dk); }
.ib-sev-low      { background: var(--ib-blue-bg); color: var(--ib-blue-dk); }
.ib-sev-info     { background: var(--ib-gray-100); color: var(--ib-gray-600); }

.ib-status {
  display: inline-flex; align-items: center; gap: 5px;
  font-size: 12px; font-weight: 600; padding: 3px 10px;
  border-radius: 100px; border: 1px solid;
}
.ib-status::before { content: ''; width: 6px; height: 6px; border-radius: 50%; background: currentColor; }
.ib-status-done    { background: var(--ib-teal-bg);  color: var(--ib-teal-dk);  border-color: var(--ib-teal-border); }
.ib-status-pending { background: var(--ib-amber-bg); color: var(--ib-amber-dk); border-color: var(--ib-amber-border); }
.ib-status-running { background: var(--ib-blue-bg);  color: var(--ib-blue-dk);  border-color: var(--ib-blue-border); }
.ib-status-failed  { background: var(--ib-red-bg);   color: var(--ib-red-dk);   border-color: var(--ib-red-border); }

/* ─────────────────────────────────────────────────────────────
   EMPTY STATES
   ───────────────────────────────────────────────────────────── */
.ib-empty { display: flex; flex-direction: column; align-items: center; justify-content: center; padding: 48px 24px; text-align: center; }
.ib-empty-icon { width: 64px; height: 64px; border-radius: 18px; background: var(--ib-gray-100); display: grid; place-items: center; font-size: 28px; margin-bottom: 16px; }
.ib-empty-title { font-size: 15px; font-weight: 700; color: var(--ib-gray-900); margin-bottom: 6px; letter-spacing: -.01em; }
.ib-empty-desc  { font-size: 13px; color: var(--ib-gray-500); line-height: 1.6; max-width: 300px; margin-bottom: 20px; }

/* ─────────────────────────────────────────────────────────────
   PAGE HEADER
   ───────────────────────────────────────────────────────────── */
.ib-page-header { margin-bottom: 24px; display: flex; align-items: flex-start; justify-content: space-between; gap: 16px; }
.ib-page-title  { font-size: 22px; font-weight: 800; color: var(--ib-gray-900); letter-spacing: -.025em; line-height: 1.2; }
.ib-page-desc   { font-size: 13.5px; color: var(--ib-gray-500); margin-top: 4px; }
.ib-page-actions { display: flex; align-items: center; gap: 8px; flex-shrink: 0; }

/* ─────────────────────────────────────────────────────────────
   DIVIDERS
   ───────────────────────────────────────────────────────────── */
.ib-divider { border: none; border-top: 1px solid var(--ib-gray-150); margin: 20px 0; }
.ib-divider-text { display: flex; align-items: center; gap: 12px; font-size: 11px; color: var(--ib-gray-400); font-weight: 600; letter-spacing: .04em; text-transform: uppercase; margin: 20px 0; }
.ib-divider-text::before, .ib-divider-text::after { content: ''; flex: 1; height: 1px; background: var(--ib-gray-150); }

/* ─────────────────────────────────────────────────────────────
   UTILITIES
   ───────────────────────────────────────────────────────────── */
.ib-text-muted    { color: var(--ib-gray-400); }
.ib-text-subtle   { color: var(--ib-gray-500); }
.ib-text-body     { color: var(--ib-gray-700); }
.ib-text-strong   { color: var(--ib-gray-900); }
.ib-text-navy     { color: var(--ib-navy); }
.ib-text-blue     { color: var(--ib-blue); }
.ib-text-teal     { color: var(--ib-teal); }
.ib-text-red      { color: var(--ib-red); }
.ib-text-amber    { color: var(--ib-amber); }
.ib-fw-bold       { font-weight: 700; }
.ib-fw-semibold   { font-weight: 600; }
.ib-fw-medium     { font-weight: 500; }
.ib-text-sm       { font-size: 12px; }
.ib-text-xs       { font-size: 11px; }
.ib-text-base     { font-size: 14px; }
.ib-text-right    { text-align: right; }
.ib-text-center   { text-align: center; }
.ib-truncate      { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.ib-mt-auto       { margin-top: auto; }
.ib-flex          { display: flex; }
.ib-flex-col      { display: flex; flex-direction: column; }
.ib-items-center  { align-items: center; }
.ib-justify-between { justify-content: space-between; }
.ib-gap-4         { gap: 4px; }
.ib-gap-8         { gap: 8px; }
.ib-gap-12        { gap: 12px; }
.ib-gap-16        { gap: 16px; }
.ib-surface        { background: #fff; }
.ib-surface-subtle { background: var(--ib-gray-25); }
.ib-surface-muted  { background: var(--ib-gray-100); }

/* ─────────────────────────────────────────────────────────────
   RESPONSIVE
   ───────────────────────────────────────────────────────────── */
@media (max-width: 1280px) { .ib-stat-grid { grid-template-columns: repeat(2,1fr); } }
@media (max-width: 768px) {
  .ib-sidebar { transform: translateX(-100%); transition: transform .25s var(--ib-ease); }
  .ib-sidebar.open { transform: translateX(0); box-shadow: var(--ib-shadow-xl); }
  .ib-main { margin-left: 0; }
  .ib-stat-grid { grid-template-columns: 1fr 1fr; }
  .ib-topbar { padding: 0 16px; }
}
@media (max-width: 480px) {
  .ib-stat-grid { grid-template-columns: 1fr; }
  .ib-page-header { flex-direction: column; }
  .ib-page-actions { width: 100%; }
}