/* ==========================================================================
   ATLAS — AI & Data-Driven Asset Tracking, Lifecycle & Analytics System
   Shared design system. Every class is prefixed `atlas-` so it never collides
   with Bootstrap or page-specific styles.

   Performance notes: no animated GIFs, no full-screen blur filters, no infinite
   animations. The page background is a static gradient on a fixed layer, which
   the browser composites once.
   ========================================================================== */

:root{
  /* Surfaces */
  --atlas-bg:        #060d1c;
  --atlas-bg-2:      #0a1630;
  --atlas-surface:   #0e1b36;
  --atlas-surface-2: #13244a;
  --atlas-raised:    #172b57;
  --atlas-border:    rgba(148,163,184,.16);
  --atlas-border-strong: rgba(148,163,184,.28);

  /* Text */
  --atlas-text:      #e7eefb;
  --atlas-text-2:    #b6c3dc;
  --atlas-muted:     #8193b2;

  /* Brand */
  --atlas-primary:   #3b82f6;
  --atlas-primary-2: #2563eb;
  --atlas-sky:       #38bdf8;
  --atlas-accent:    #2dd4bf;   /* teal */

  /* Risk scale (used consistently across ATLAS) */
  --atlas-low:   #10b981;
  --atlas-med:   #3b82f6;
  --atlas-high:  #f59e0b;
  --atlas-crit:  #ef4444;

  /* Light cards (forms, tables) */
  --atlas-paper:      #ffffff;
  --atlas-paper-2:    #f5f8fd;
  --atlas-paper-line: #e2e8f2;
  --atlas-ink:        #0f1b33;
  --atlas-ink-2:      #475569;

  --atlas-radius:    16px;
  --atlas-radius-sm: 10px;
  --atlas-shadow:    0 1px 0 rgba(255,255,255,.04) inset, 0 12px 32px rgba(2,8,23,.38);
  --atlas-shadow-sm: 0 6px 16px rgba(2,8,23,.28);
  --atlas-font: "Inter", ui-sans-serif, system-ui, -apple-system, "Segoe UI", Roboto, Arial, sans-serif;
  --atlas-maxw: 1320px;
}

/* --------------------------------------------------------------- base --- */
body.atlas{
  margin:0;
  min-height:100vh;
  font-family:var(--atlas-font);
  color:var(--atlas-text);
  background:var(--atlas-bg);
  -webkit-font-smoothing:antialiased;
}
body.atlas::before{
  content:""; position:fixed; inset:0; z-index:-1; pointer-events:none;
  background:
    radial-gradient(1100px 520px at 12% -8%, rgba(59,130,246,.20), transparent 60%),
    radial-gradient(900px 480px at 100% 10%, rgba(45,212,191,.10), transparent 60%),
    linear-gradient(180deg, var(--atlas-bg-2) 0%, var(--atlas-bg) 55%);
}
body.atlas > main, body.atlas > .atlas-main{ min-height:calc(100vh - 64px - 120px); }
.atlas-container{ max-width:var(--atlas-maxw); margin:0 auto; padding:0 20px; }
.atlas-sr{ position:absolute!important; width:1px; height:1px; overflow:hidden; clip:rect(0 0 0 0); }

/* ------------------------------------------------------------- topbar --- */
.atlas-topbar{
  position:sticky; top:0; z-index:1000;
  background:rgba(7,15,32,.92);
  border-bottom:1px solid var(--atlas-border);
  backdrop-filter:saturate(140%) blur(8px);   /* small area only — cheap */
}
.atlas-topbar__inner{
  max-width:var(--atlas-maxw); margin:0 auto; padding:0 20px;
  height:64px; display:flex; align-items:center; gap:18px;
}
.atlas-brand{ display:flex; align-items:center; gap:12px; text-decoration:none; color:var(--atlas-text); flex:0 0 auto; }
.atlas-brand img{ width:44px; height:44px; display:block; }
.atlas-brand__name{ font-weight:800; font-size:20px; letter-spacing:.14em; line-height:1; }
.atlas-brand__tag{ display:block; font-size:10.5px; font-weight:500; letter-spacing:.02em; color:var(--atlas-muted); margin-top:4px; white-space:nowrap; }
.atlas-moh{ height:30px; width:auto; opacity:.9; padding-left:14px; border-left:1px solid var(--atlas-border); }

.atlas-nav{ display:flex; align-items:center; gap:2px; margin-left:auto; }
.atlas-nav__item{ position:relative; }
.atlas-nav__link{
  display:inline-flex; align-items:center; gap:8px;
  height:38px; padding:0 12px; border-radius:10px;
  color:var(--atlas-text-2); text-decoration:none; font-size:13.5px; font-weight:600;
  background:none; border:0; cursor:pointer; font-family:inherit; white-space:nowrap;
  transition:background .15s ease, color .15s ease;
}
.atlas-nav__link i{ font-size:13px; opacity:.85; }
.atlas-nav__link .fa-chevron-down{ font-size:9px; opacity:.6; }
.atlas-nav__link:hover, .atlas-nav__item:focus-within > .atlas-nav__link{ background:rgba(148,163,184,.10); color:#fff; }
.atlas-nav__link.is-active{ color:#fff; background:rgba(59,130,246,.16); box-shadow:inset 0 -2px 0 var(--atlas-primary); }
.atlas-nav__link:focus-visible{ outline:2px solid var(--atlas-sky); outline-offset:2px; }

.atlas-menu{
  position:absolute; top:calc(100% + 8px); left:0; min-width:260px;
  background:#0d1a35; border:1px solid var(--atlas-border-strong); border-radius:14px;
  box-shadow:0 22px 48px rgba(2,8,23,.55); padding:8px;
  opacity:0; visibility:hidden; transform:translateY(-4px);
  transition:opacity .14s ease, transform .14s ease, visibility 0s linear .14s;
}
.atlas-menu--right{ left:auto; right:0; }
.atlas-menu--wide{ min-width:520px; display:grid; grid-template-columns:1fr 1fr; gap:4px 8px; }
.atlas-nav__item:hover > .atlas-menu,
.atlas-nav__item:focus-within > .atlas-menu{
  opacity:1; visibility:visible; transform:none; transition:opacity .14s ease, transform .14s ease;
}
.atlas-menu::before{ content:""; position:absolute; left:0; right:0; top:-10px; height:10px; } /* hover bridge */
.atlas-menu__group{ padding:4px 0; }
.atlas-menu__label{
  display:block; padding:8px 10px 4px; font-size:10.5px; font-weight:700; letter-spacing:.09em;
  text-transform:uppercase; color:var(--atlas-muted);
}
.atlas-menu a{
  display:flex; align-items:flex-start; gap:10px; padding:9px 10px; border-radius:9px;
  color:var(--atlas-text); text-decoration:none; font-size:13.5px; font-weight:500; line-height:1.3;
}
.atlas-menu a i{ width:16px; margin-top:2px; color:var(--atlas-sky); text-align:center; }
.atlas-menu a small{ display:block; color:var(--atlas-muted); font-size:11.5px; font-weight:400; margin-top:2px; }
.atlas-menu a:hover, .atlas-menu a:focus-visible{ background:rgba(59,130,246,.14); outline:none; }
.atlas-menu__empty{ display:block; padding:6px 10px 8px; color:var(--atlas-muted); font-size:12.5px; font-style:italic; }

.atlas-user{ display:flex; align-items:center; gap:10px; margin-left:8px; padding-left:14px; border-left:1px solid var(--atlas-border); }
.atlas-avatar{ width:34px; height:34px; border-radius:50%; object-fit:cover; border:2px solid rgba(56,189,248,.6); }
.atlas-btn-signin{
  display:inline-flex; align-items:center; gap:8px; height:34px; padding:0 14px; border-radius:999px;
  background:var(--atlas-primary); color:#fff !important; text-decoration:none; font-size:13px; font-weight:700; border:0; cursor:pointer;
  white-space:nowrap;
}
.atlas-btn-signin:hover{ background:var(--atlas-primary-2); }
.atlas-iconbtn{
  width:34px; height:34px; display:inline-grid; place-items:center; border-radius:10px;
  background:rgba(148,163,184,.08); border:1px solid var(--atlas-border); color:var(--atlas-text-2); cursor:pointer;
}
.atlas-iconbtn:hover{ background:rgba(148,163,184,.16); color:#fff; }
.atlas-burger{ display:none; margin-left:auto; }

@media (max-width:1180px){
  .atlas-brand__tag, .atlas-moh{ display:none; }
}
@media (max-width:980px){
  .atlas-burger{ display:inline-grid; }
  .atlas-nav{
    position:absolute; top:64px; left:0; right:0; margin:0;
    flex-direction:column; align-items:stretch; gap:0;
    background:#081226; border-bottom:1px solid var(--atlas-border);
    padding:8px 16px 16px; max-height:calc(100vh - 64px); overflow:auto;
    display:none;
  }
  .atlas-topbar.is-open .atlas-nav{ display:flex; }
  .atlas-nav__link{ width:100%; justify-content:flex-start; height:44px; }
  .atlas-menu, .atlas-menu--wide{
    position:static; opacity:1; visibility:visible; transform:none; box-shadow:none;
    min-width:0; display:block; border:0; background:transparent; padding:0 0 6px 18px;
  }
  .atlas-user{ border-left:0; padding:10px 0 0; margin:0; }
}

/* ------------------------------------------------------- page header --- */
.atlas-pagehead{ padding:28px 0 8px; }
.atlas-eyebrow{
  display:inline-flex; align-items:center; gap:8px; font-size:11.5px; font-weight:700;
  letter-spacing:.12em; text-transform:uppercase; color:var(--atlas-accent);
}
.atlas-eyebrow::before{ content:""; width:18px; height:2px; background:var(--atlas-accent); border-radius:2px; }
.atlas-h1{ margin:8px 0 6px; font-size:clamp(24px, 2.6vw, 32px); font-weight:800; letter-spacing:-.01em; color:#fff; }
.atlas-lead{ margin:0; color:var(--atlas-text-2); font-size:15px; max-width:760px; }

/* --------------------------------------------------------------- cards --- */
.atlas-card{
  background:linear-gradient(180deg, rgba(19,36,74,.72), rgba(14,27,54,.72));
  border:1px solid var(--atlas-border);
  border-radius:var(--atlas-radius);
  box-shadow:var(--atlas-shadow);
  padding:18px 20px;
}
.atlas-card__head{ display:flex; align-items:center; justify-content:space-between; gap:12px; margin-bottom:12px; }
.atlas-card__title{ margin:0; font-size:14px; font-weight:700; letter-spacing:.02em; color:#fff; display:flex; align-items:center; gap:10px; }
.atlas-card__title i{ color:var(--atlas-sky); font-size:13px; }
.atlas-card__sub{ margin:2px 0 0; font-size:12px; color:var(--atlas-muted); }
.atlas-card--paper{
  background:var(--atlas-paper); color:var(--atlas-ink);
  border-color:var(--atlas-paper-line); box-shadow:0 12px 32px rgba(2,8,23,.30);
}
.atlas-card--paper .atlas-card__title{ color:var(--atlas-ink); }

/* ---------------------------------------------------------- KPI tiles --- */
.atlas-kpis{ display:grid; grid-template-columns:repeat(4, minmax(0,1fr)); gap:14px; }
.atlas-kpi{
  position:relative; overflow:hidden;
  background:linear-gradient(180deg, rgba(23,43,87,.85), rgba(14,27,54,.85));
  border:1px solid var(--atlas-border); border-radius:var(--atlas-radius); padding:16px 18px;
  box-shadow:var(--atlas-shadow-sm);
}
.atlas-kpi::after{
  content:""; position:absolute; right:-30px; top:-30px; width:120px; height:120px; border-radius:50%;
  background:radial-gradient(closest-side, var(--kpi-glow, rgba(59,130,246,.25)), transparent);
}
.atlas-kpi__icon{
  width:38px; height:38px; border-radius:11px; display:grid; place-items:center;
  background:var(--kpi-tint, rgba(59,130,246,.16)); color:var(--kpi-color, var(--atlas-sky)); font-size:15px;
}
.atlas-kpi__label{ margin-top:12px; font-size:12px; font-weight:600; color:var(--atlas-muted); letter-spacing:.02em; }
.atlas-kpi__value{ margin-top:2px; font-size:26px; font-weight:800; color:#fff; font-variant-numeric:tabular-nums; letter-spacing:-.01em; }
.atlas-kpi__foot{ margin-top:4px; font-size:12px; color:var(--atlas-text-2); }
.atlas-kpi--teal{ --kpi-color:#2dd4bf; --kpi-tint:rgba(45,212,191,.14); --kpi-glow:rgba(45,212,191,.20); }
.atlas-kpi--amber{ --kpi-color:#fbbf24; --kpi-tint:rgba(251,191,36,.14); --kpi-glow:rgba(251,191,36,.18); }
.atlas-kpi--rose{ --kpi-color:#fb7185; --kpi-tint:rgba(251,113,133,.14); --kpi-glow:rgba(251,113,133,.18); }
@media (max-width:1000px){ .atlas-kpis{ grid-template-columns:repeat(2, minmax(0,1fr)); } }
@media (max-width:520px){ .atlas-kpis{ grid-template-columns:1fr; } }

/* ------------------------------------------------------------- buttons --- */
.atlas-btn{
  display:inline-flex; align-items:center; justify-content:center; gap:8px;
  height:40px; padding:0 16px; border-radius:11px; border:1px solid transparent;
  font-family:inherit; font-size:14px; font-weight:700; text-decoration:none; cursor:pointer;
  background:var(--atlas-primary); color:#fff;
  transition:background .15s ease, border-color .15s ease, transform .1s ease;
}
.atlas-btn:hover{ background:var(--atlas-primary-2); color:#fff; }
.atlas-btn:active{ transform:translateY(1px); }
.atlas-btn:focus-visible{ outline:2px solid var(--atlas-sky); outline-offset:2px; }
.atlas-btn[disabled]{ opacity:.6; cursor:progress; }
.atlas-btn--ghost{ background:rgba(148,163,184,.08); border-color:var(--atlas-border-strong); color:var(--atlas-text); }
.atlas-btn--ghost:hover{ background:rgba(148,163,184,.16); color:#fff; }
.atlas-btn--teal{ background:#0d9488; }
.atlas-btn--teal:hover{ background:#0f766e; }
.atlas-btn--sm{ height:32px; padding:0 12px; font-size:12.5px; border-radius:9px; }
.atlas-btn--lg{ height:48px; padding:0 22px; font-size:15px; border-radius:13px; }

.atlas-chip{
  display:inline-flex; align-items:center; gap:6px; padding:4px 10px; border-radius:999px;
  font-size:12px; font-weight:600; background:rgba(148,163,184,.12); color:var(--atlas-text-2);
  border:1px solid var(--atlas-border); cursor:default;
}
button.atlas-chip{ cursor:pointer; font-family:inherit; }
button.atlas-chip:hover{ background:rgba(59,130,246,.18); color:#fff; }

.atlas-dot{ width:8px; height:8px; border-radius:50%; display:inline-block; }
.atlas-dot--low{ background:var(--atlas-low); } .atlas-dot--med{ background:var(--atlas-med); }
.atlas-dot--high{ background:var(--atlas-high); } .atlas-dot--crit{ background:var(--atlas-crit); }

/* ---------------------------------------------------------------- footer --- */
.atlas-footer{
  margin-top:40px; border-top:1px solid var(--atlas-border);
  background:rgba(5,11,24,.85); color:var(--atlas-text-2); font-size:13px;
}
.atlas-footer__inner{
  max-width:var(--atlas-maxw); margin:0 auto; padding:22px 20px;
  display:grid; grid-template-columns:1.3fr 1fr auto; gap:18px; align-items:center;
}
.atlas-footer strong{ color:var(--atlas-text); }
.atlas-footer__brand{ display:flex; align-items:center; gap:12px; }
.atlas-footer__brand img{ width:36px; height:36px; }
.atlas-footer__links{ display:flex; flex-wrap:wrap; gap:8px; }
.atlas-footer__links a, .atlas-footer__links button{
  display:inline-flex; align-items:center; gap:6px; padding:6px 11px; border-radius:999px;
  background:rgba(148,163,184,.08); border:1px solid var(--atlas-border); color:var(--atlas-text-2);
  text-decoration:none; font:inherit; font-size:12.5px; cursor:pointer;
}
.atlas-footer__links a:hover, .atlas-footer__links button:hover{ background:rgba(148,163,184,.16); color:#fff; }
@media (max-width:860px){ .atlas-footer__inner{ grid-template-columns:1fr; text-align:center; } .atlas-footer__brand, .atlas-footer__links{ justify-content:center; } }

/* --------------------------------------------------------------- dialog --- */
dialog.atlas-dialog{
  border:1px solid var(--atlas-paper-line); border-radius:18px; padding:22px 24px; width:min(440px, calc(100% - 32px));
  color:var(--atlas-ink); box-shadow:0 30px 80px rgba(2,8,23,.6); font-family:var(--atlas-font);
}
dialog.atlas-dialog::backdrop{ background:rgba(3,8,20,.62); }
dialog.atlas-dialog h3{ margin:0 0 6px; font-size:18px; }
dialog.atlas-dialog p{ color:var(--atlas-ink-2); margin:0 0 12px; font-size:14px; }
dialog.atlas-dialog a{ color:var(--atlas-primary-2); }

/* ------------------------------------------------------------------ forms --- */
.atlas-field{ display:flex; flex-direction:column; gap:6px; margin-bottom:12px; }
.atlas-field label{ font-size:12.5px; font-weight:700; color:var(--atlas-ink-2); }
.atlas-input{
  height:42px; padding:0 12px; border-radius:11px; border:1px solid #cbd5e1; background:#fff;
  font:inherit; font-size:14px; color:var(--atlas-ink);
}
.atlas-input:focus{ outline:none; border-color:var(--atlas-primary); box-shadow:0 0 0 3px rgba(59,130,246,.2); }

/* ------------------------------------------------- secondary-page adapter --- */
/* Pages that still use Bootstrap get readable, solid cards on the ATLAS shell. */
body.atlas-page .card,
body.atlas-page .glass{ background:rgba(255,255,255,.97) !important; border:1px solid var(--atlas-paper-line); border-radius:14px; }
body.atlas-page .title, body.atlas-page h2.title{ color:#fff; text-shadow:none; font-weight:800; letter-spacing:-.01em; }
body.atlas-page .subtext{ color:var(--atlas-text-2); text-shadow:none; }

@media (prefers-reduced-motion: reduce){
  *{ transition:none !important; animation:none !important; scroll-behavior:auto !important; }
}
@media print{
  body.atlas::before, .atlas-topbar, .atlas-footer{ display:none !important; }
  body.atlas{ background:#fff !important; color:#000; }
}


/* ===== Service framework ===== */
.atlas-nav__service{
  padding:1px 6px; border-radius:6px; font-size:10.5px; font-weight:700; letter-spacing:.03em;
  color:#fff; background:rgba(59,130,246,.32);
}
.atlas-nav__link--planned{ color:var(--atlas-muted); opacity:.65; cursor:default; }
.atlas-menu--services{ min-width:420px; }
.atlas-menu--services a[aria-current]{ background:rgba(59,130,246,.14); }

.hub-head{ display:flex; justify-content:space-between; gap:16px; align-items:flex-end; flex-wrap:wrap; margin:24px 0 18px; }
.hub-section{ margin:26px 0; }
.hub-section > h2{ margin:0 0 12px; font-size:17px; font-weight:700; color:#fff; }
.hub-grid{ display:grid; grid-template-columns:repeat(3, minmax(0,1fr)); gap:14px; }
.hub-grid--2{ grid-template-columns:repeat(2, minmax(0,1fr)); }
.hub-grid--4{ grid-template-columns:repeat(4, minmax(0,1fr)); }
.hub-grid--home{ grid-template-columns:repeat(7, minmax(0,1fr)); margin-bottom:14px; }
.hub-card{ display:block; padding:18px; color:var(--atlas-text); text-decoration:none; border-top:3px solid var(--svc, var(--atlas-primary)); }
a.hub-card:hover{ transform:translateY(-2px); }
.hub-card__icon{ font-size:20px; color:var(--svc, var(--atlas-sky)); margin-bottom:8px; }
.hub-card h3{ margin:0 0 4px; font-size:16px; font-weight:700; color:#fff; }
.hub-card p{ margin:0; font-size:13px; line-height:1.45; color:var(--atlas-text-2); }
.hub-stats{ display:flex; gap:22px; margin-top:12px; }
.hub-stat strong{ display:block; font-size:20px; color:#fff; }
.hub-stat span{ font-size:11.5px; color:var(--atlas-muted); }
.hub-status{ display:inline-block; margin-top:10px; padding:2px 8px; border-radius:999px; font-size:11px; font-weight:600; color:var(--atlas-muted); background:rgba(148,163,184,.14); }
.hub-status--live{ color:#6ee7b7; background:rgba(16,185,129,.16); }
.hub-note{ display:flex; gap:10px; padding:12px 14px; margin:14px 0; border-radius:var(--atlas-radius-sm); font-size:13.5px; line-height:1.5; color:#fde68a; background:rgba(245,158,11,.10); border:1px solid rgba(245,158,11,.32); }
.hub-empty{ padding:34px 18px; text-align:center; color:var(--atlas-text-2); }
.hub-toolbar{ display:flex; gap:8px; flex-wrap:wrap; align-items:center; margin:0 0 14px; }
.hub-toolbar .atlas-input{ width:auto; min-width:230px; }
.hub-table{ width:100%; border-collapse:collapse; font-size:13.5px; }
.hub-table th{ padding:9px 12px; text-align:left; font-size:11.5px; text-transform:uppercase; letter-spacing:.04em; color:var(--atlas-muted); border-bottom:1px solid var(--atlas-border-strong); }
.hub-table td{ padding:10px 12px; color:var(--atlas-text-2); border-bottom:1px solid var(--atlas-border); }
.hub-table a{ color:var(--atlas-sky); }
.hub-form{ display:grid; grid-template-columns:repeat(2, minmax(0,1fr)); gap:14px; }
.hub-form label{ display:block; font-size:13px; font-weight:600; color:var(--atlas-text); }
.hub-form .atlas-input{ width:100%; box-sizing:border-box; margin-top:5px; }
.hub-form small{ display:block; margin-top:4px; font-size:11.5px; font-weight:400; color:var(--atlas-muted); }
.hub-form small.is-error{ color:#fca5a5; }
.hub-form__wide{ grid-column:1 / -1; }
.hub-risk{ display:inline-block; padding:3px 10px; border-radius:999px; font-size:12px; font-weight:700; text-transform:capitalize; color:#fff; }
.hub-risk--low{ background:var(--atlas-low); }
.hub-risk--medium{ background:var(--atlas-med); }
.hub-risk--high{ background:#b45309; }
.hub-risk--critical{ background:#b91c1c; }
.hub-score{ font-size:36px; font-weight:800; color:#fff; }
@media (max-width:1180px){ .hub-grid--home{ grid-template-columns:repeat(4, minmax(0,1fr)); } }
@media (max-width:980px){
  .hub-grid, .hub-grid--4{ grid-template-columns:repeat(2, minmax(0,1fr)); }
  .atlas-menu--services{ min-width:0; }
}
@media (max-width:620px){
  .hub-grid, .hub-grid--2, .hub-grid--4, .hub-grid--home, .hub-form{ grid-template-columns:1fr; }
}

/* Healthcare Facilities Map */
.fac-cluster span{ display:block; box-sizing:border-box; width:36px; height:36px; border:2px solid #fff; border-radius:50%; box-shadow:0 1px 4px rgba(0,0,0,.35); line-height:32px; text-align:center; color:#fff; font-size:11.5px; font-weight:700; }
.fac-popup{ min-width:210px; font-size:12.5px; color:#0f1b33; }
.fac-popup strong{ display:block; font-size:14px; }
.fac-popup small{ display:block; margin-bottom:6px; color:#475569; }
.fac-popup table{ width:100%; border-collapse:collapse; }
.fac-popup td{ padding:3px 0; border-top:1px solid #e2e8f2; vertical-align:top; }
.fac-popup td:first-child{ width:42%; padding-right:8px; color:#475569; }
.fac-popup td:last-child{ font-weight:600; overflow-wrap:anywhere; }
.fac-popup a{ display:inline-block; margin-top:6px; }
.fac-popup em{ display:block; margin-top:6px; color:#64748b; font-size:11px; }

/* Services with long menus: the tagline gives way so the sign-in control stays on screen. */
.atlas-topbar--dense .atlas-brand__tag{ display:none; }

/* Simulation scenarios on the screening forms */
.hub-sim-bar{ display:flex; flex-wrap:wrap; align-items:center; gap:8px 12px; padding-bottom:16px; margin-bottom:16px; border-bottom:1px solid var(--atlas-border); }
.hub-sim-bar__label{ font-size:13px; font-weight:700; color:var(--atlas-text); }
.hub-sim-bar__buttons{ display:flex; flex-wrap:wrap; gap:8px; }
.hub-sim-bar small{ flex-basis:100%; font-size:12px; color:var(--atlas-muted); }
.hub-sim-btn[aria-pressed="true"]{ background:#7c3aed; border-color:#7c3aed; color:#fff; }
.hub-sim{ display:inline-block; padding:3px 10px; border-radius:999px; font-size:11px; font-weight:700; color:#ddd6fe; background:rgba(124,58,237,.28); }

/* Result analysis: score scale, severity and points bars, explanation */
.hub-analysis{ margin-top:18px; padding-top:4px; border-top:1px solid var(--atlas-border); }
.hub-analysis h3{ margin:20px 0 6px; font-size:15px; font-weight:700; color:var(--atlas-text); }
.hub-analysis__sub{ margin:0 0 10px; font-size:13px; line-height:1.55; color:var(--atlas-muted); }
.hub-analysis code{ font-size:12.5px; color:var(--atlas-text); white-space:normal; }
.hub-note--sim{ margin-top:14px; }
.hub-note--sim i{ color:#c4b5fd; }
.hub-scale{ position:relative; padding-top:24px; max-width:640px; }
.hub-scale__marker{ position:absolute; top:0; transform:translateX(-50%); font-size:12px; font-weight:700; color:var(--atlas-text); white-space:nowrap; }
.hub-scale__track{ display:grid; grid-template-columns:repeat(4, 1fr); gap:2px; height:10px; }
.hub-scale__track div:first-child{ border-radius:4px 0 0 4px; }
.hub-scale__track div:last-child{ border-radius:0 4px 4px 0; }
.hub-scale__labels{ display:grid; grid-template-columns:repeat(4, 1fr); gap:2px; margin-top:6px; font-size:11.5px; line-height:1.35; color:var(--atlas-muted); }
.hub-bars{ display:grid; gap:2px; }
.hub-bars__row{ display:grid; grid-template-columns:minmax(0,1.5fr) minmax(0,1.4fr) minmax(0,1fr); gap:16px; align-items:center; padding:6px 0; font-size:13px; color:var(--atlas-text); }
.hub-bars__row--head{ font-size:11.5px; font-weight:700; letter-spacing:.04em; text-transform:uppercase; color:var(--atlas-muted); }
.hub-bars__cell{ display:flex; align-items:center; gap:10px; }
.hub-bars__track{ flex:1; height:10px; border-radius:0 4px 4px 0; background:rgba(148,163,184,.12); overflow:hidden; }
.hub-bars__bar{ display:block; height:100%; border-radius:0 4px 4px 0; background:#0a93d4; }
.hub-bars__value{ flex:0 0 42px; text-align:right; font-variant-numeric:tabular-nums; color:var(--atlas-muted); }
.hub-steps{ margin:0; padding-left:20px; font-size:13px; line-height:1.6; color:var(--atlas-muted); }
.hub-steps li{ margin-bottom:8px; }
.hub-steps strong, .hub-why dt{ color:var(--atlas-text); }
.hub-why{ margin:0; display:grid; grid-template-columns:minmax(0,1fr) minmax(0,2.4fr); gap:8px 16px; font-size:13px; line-height:1.55; }
.hub-why dt{ font-weight:600; }
.hub-why dd{ margin:0; color:var(--atlas-muted); }
@media (max-width:720px){
  .hub-bars__row{ grid-template-columns:1fr; gap:4px; padding:8px 0; }
  .hub-bars__row--head{ display:none; }
  .hub-why{ grid-template-columns:1fr; gap:2px 0; }
  .hub-why dd{ margin-bottom:8px; }
}

.hub-section[id]{ scroll-margin-top:84px; }

/* Machine learning result */
.hub-sim-bar__label--break{ flex-basis:100%; margin-top:4px; }
.hub-ml__badge{ display:inline-block; margin-left:8px; padding:2px 9px; border-radius:999px; font-size:11px; font-weight:700; color:#ddd6fe; background:rgba(124,58,237,.28); vertical-align:middle; }
.hub-ml__stats{ display:grid; grid-template-columns:repeat(2, minmax(0,1fr)); gap:12px; margin-bottom:12px; }
.hub-ml__stat{ padding:12px 14px; border:1px solid var(--atlas-border); border-radius:var(--atlas-radius-sm); }
.hub-ml__stat span{ display:block; font-size:12px; color:var(--atlas-muted); }
.hub-ml__stat strong{ display:block; margin:2px 0; font-size:22px; font-weight:800; color:var(--atlas-text); }
.hub-bars--two .hub-bars__row{ grid-template-columns:minmax(0,1fr) minmax(0,1.6fr); }
@media (max-width:720px){ .hub-ml__stats{ grid-template-columns:1fr; } }

/* Equipment schematics and measuring points */
.hub-points{ padding:20px; margin-bottom:18px; }
.hub-points h2{ margin:0 0 6px; font-size:17px; font-weight:700; color:var(--atlas-text); }
.hub-points__grid{ display:grid; grid-template-columns:minmax(0,1.5fr) minmax(0,1fr); gap:20px; align-items:start; }
.hub-points__list{ list-style:none; margin:0; padding:0; display:grid; gap:2px; font-size:12.5px; line-height:1.4; }
.hub-points__list li{ display:flex; gap:9px; padding:6px; border-radius:6px; }
.hub-points__list li.is-active{ background:rgba(148,163,184,.14); }
.hub-points__list strong{ display:block; color:var(--atlas-text); }
.hub-points__list span:not(.hub-pt){ display:block; color:var(--atlas-muted); }
.hub-points__list .hub-points__status{ color:var(--atlas-text); font-weight:600; }
.hub-pt{ flex:none; display:inline-grid; place-items:center; width:21px; height:21px; border-radius:50%; font-size:11px; font-weight:700; color:#fff; background:#2563eb; }
.hub-pt.is-watch{ background:#b45309; }
.hub-pt.is-alarm{ background:#b91c1c; }
.hub-form label.is-active{ outline:2px solid #7c3aed; outline-offset:4px; border-radius:6px; }
.sch{ display:block; width:100%; height:auto; border-radius:var(--atlas-radius-sm); background:#0a1630; }
.sch--card{ margin-bottom:10px; pointer-events:none; }
.sch--card text{ display:none; }
.sch-b{ fill:#13244a; stroke:#8193b2; stroke-width:2; }
.sch-p{ fill:#1d3461; stroke:#b6c3dc; stroke-width:1.5; }
.sch-f{ fill:#1d3461; stroke:#8193b2; stroke-width:1.5; stroke-dasharray:4 4; }
.sch-panel{ fill:none; stroke:#8193b2; stroke-width:1.5; stroke-dasharray:6 4; }
.sch-c{ fill:none; stroke:#38bdf8; stroke-width:6; }
.sch-w{ fill:none; stroke:#fb923c; stroke-width:6; }
.sch-a{ fill:none; stroke:#5eead4; stroke-width:4; stroke-dasharray:12 8; }
.sch-a2{ fill:none; stroke:#5eead4; stroke-width:6; }
.sch-l{ fill:none; stroke:#8193b2; stroke-width:2; }
.sch-l2{ fill:none; stroke:#fbbf24; stroke-width:4; }
.sch-d{ fill:none; stroke:#8193b2; stroke-width:3; }
.sch-ce{ fill:none; stroke:#8193b2; stroke-width:2; stroke-dasharray:3 5; }
.sch-m{ fill:#3f6212; stroke:#a3e635; stroke-width:1.5; }
.sch-t{ fill:#b6c3dc; font-size:13px; text-anchor:middle; }
.sch-pt{ cursor:help; }
.sch-pt circle{ fill:#2563eb; stroke:#e7eefb; stroke-width:2; }
.sch-pt text{ fill:#fff; font-size:13px; font-weight:700; text-anchor:middle; dominant-baseline:central; }
.sch-pt.is-watch circle{ fill:#b45309; }
.sch-pt.is-alarm circle{ fill:#b91c1c; }
.sch-pt.is-active circle{ fill:#7c3aed; stroke-width:3; }
@media (max-width:980px){ .hub-points__grid{ grid-template-columns:1fr; } }

/* 3D equipment models */
.hub-3d{ position:relative; min-width:0; }
.hub-3d canvas{ display:none; }
.hub-3d__overlay, .hub-3d__reset, .hub-3d__hint{ display:none; }
.hub-3d--ready{ aspect-ratio:1.8; overflow:hidden; border-radius:var(--atlas-radius-sm); background:radial-gradient(ellipse at 50% 45%, #1d3461 0%, #0a1630 72%); }
.hub-3d--ready canvas{ display:block; width:100%; height:100%; cursor:grab; touch-action:none; }
.hub-3d--ready canvas:active{ cursor:grabbing; }
.hub-3d--ready .sch{ display:none; }
.hub-3d--ready .hub-3d__overlay{ display:block; position:absolute; inset:0; overflow:hidden; pointer-events:none; }
.hub-3d--ready .hub-3d__reset{ display:inline-flex; position:absolute; right:10px; top:10px; padding:5px 10px; font-size:12px; }
.hub-3d--ready .hub-3d__hint{ display:block; position:absolute; left:12px; bottom:8px; margin:0; font-size:11.5px; color:var(--atlas-muted); pointer-events:none; }
.hub-3d__pt{ position:absolute; left:0; top:0; z-index:1; display:grid; place-items:center; width:24px; height:24px; padding:0; border:2px solid #e7eefb; border-radius:50%; font:700 12px/1 inherit; color:#fff; background:#2563eb; cursor:help; pointer-events:auto; box-shadow:0 1px 4px rgba(0,0,0,.6); }
.hub-3d__pt.is-watch{ background:#b45309; }
.hub-3d__pt.is-alarm{ background:#b91c1c; }
.hub-3d__pt.is-behind{ opacity:.4; }
.hub-3d__pt.is-active{ background:#7c3aed; opacity:1; z-index:2; }
.hub-3d__label{ position:absolute; left:0; top:0; z-index:0; padding:1px 6px; border-radius:4px; font-size:11px; color:#e7eefb; background:rgba(6,13,28,.68); white-space:nowrap; }
.hub-3d__holder{ margin-bottom:10px; }
.hub-3d__thumb{ display:block; width:100%; aspect-ratio:2; border-radius:var(--atlas-radius-sm); background:radial-gradient(ellipse at 50% 45%, #1d3461 0%, #0a1630 72%); }

/* End-to-end walk-through (AI Prediction pages) */
.sf{ --sf-progress:0%; display:grid; gap:16px; }
.sf-title{ margin:0; font-size:20px; }
.sf-sub{ margin:-8px 0 0; max-width:780px; font-size:14px; color:var(--atlas-text-2); }
.sf-bar{ display:flex; flex-wrap:wrap; justify-content:space-between; align-items:center; gap:10px; }
.sf-examples, .sf-controls{ display:flex; flex-wrap:wrap; gap:8px; }
.sf-example, .sf-btn{ min-height:36px; padding:6px 13px; border:1px solid var(--atlas-border); border-radius:8px; font:inherit; font-size:13px; font-weight:600; color:var(--atlas-text); background:rgba(255,255,255,.04); cursor:pointer; }
.sf-example[aria-pressed="true"], .sf-btn--main{ border-color:#2563eb; color:#fff; background:#2563eb; }
.sf-controls, .sf-track-wrap, .sf-loop{ display:none; }
.sf--ready .sf-controls{ display:flex; }
.sf--ready .sf-track-wrap{ display:block; }
.sf--ready .sf-loop{ display:block; }
.sf-track{ position:relative; display:grid; grid-template-columns:repeat(9, minmax(0, 1fr)); margin:0; padding:0; list-style:none; }
.sf-line{ position:absolute; top:22px; left:5.55%; right:5.55%; height:4px; border-radius:2px; background:rgba(148,163,184,.3); }
.sf-fill{ position:absolute; inset:0 auto 0 0; width:var(--sf-progress); border-radius:2px; background:#60a5fa; transition:width .9s ease; }
.sf-packet{ position:absolute; top:50%; left:var(--sf-progress); width:14px; height:14px; margin:-7px 0 0 -7px; border-radius:50%; background:#fff; box-shadow:0 0 0 4px rgba(96,165,250,.45); transition:left .9s ease; animation:sf-pulse 1.6s ease-in-out infinite; z-index:2; }
@keyframes sf-pulse{ 50%{ box-shadow:0 0 0 9px rgba(96,165,250,.12); } }
.sf-stop-item{ position:relative; min-width:0; }
.sf-stop{ display:grid; justify-items:center; gap:7px; width:100%; padding:0 3px; border:0; font:inherit; text-align:center; color:var(--atlas-text-2); background:none; cursor:pointer; }
.sf-stop__icon{ position:relative; display:grid; place-items:center; width:48px; height:48px; border:2px solid rgba(148,163,184,.45); border-radius:50%; font-size:17px; color:var(--atlas-text-2); background:#0e1b36; transition:background .4s, border-color .4s, color .4s; }
.sf-stop__title{ font-size:12px; line-height:1.3; }
.sf-stop.is-done .sf-stop__icon{ border-color:#60a5fa; color:#60a5fa; }
.sf-stop.is-active .sf-stop__icon{ border-color:#fff; color:#fff; background:#2563eb; }
.sf-stop.is-active .sf-stop__title{ color:#fff; font-weight:700; }
.sf-panels{ display:grid; gap:12px; }
.sf--ready .sf-panel{ display:none; }
.sf--ready .sf-panel.is-active{ display:grid; animation:sf-in .35s ease; }
@keyframes sf-in{ from{ opacity:0; transform:translateY(5px); } }
.sf-panel{ display:grid; grid-template-columns:minmax(0, 1fr) minmax(0, 1.25fr); gap:18px; padding:16px; min-height:238px; border:1px solid var(--atlas-border); border-radius:var(--atlas-radius-sm); }
.sf-panel h3{ margin:0 0 7px; font-size:19px; }
.sf-panel h4{ margin:0 0 9px; font-size:12px; letter-spacing:.04em; text-transform:uppercase; color:var(--atlas-muted); }
.sf-panel p{ margin:0 0 8px; font-size:14px; line-height:1.5; color:var(--atlas-text-2); }
.sf-panel .sf-panel__step{ margin-bottom:3px; font-size:12px; color:var(--atlas-muted); }
.sf-panel .sf-big{ font-size:17px; font-weight:700; color:#fff; }
.sf-panel .sf-muted{ font-size:12.5px; color:var(--atlas-muted); }
.sf-today{ margin-top:12px !important; font-size:13px !important; }
.sf-avail{ display:inline-block; margin-right:5px; padding:1px 8px; border:1px solid #60a5fa; border-radius:999px; font-size:11.5px; font-weight:700; color:#fff; }
.sf-avail.is-working{ background:#2563eb; }
.sf-avail.is-planned{ border-color:var(--atlas-muted); border-style:dashed; color:var(--atlas-text-2); }
.sf-panel__live{ min-width:0; padding-left:18px; border-left:1px solid var(--atlas-border); }
.sf-readings{ display:grid; grid-template-columns:repeat(2, minmax(0, 1fr)); gap:6px 16px; margin:0; padding:0; list-style:none; }
.sf-readings li{ display:grid; grid-template-columns:minmax(0, 1fr) auto; gap:0 8px; padding-left:8px; border-left:3px solid rgba(148,163,184,.3); font-size:12.5px; color:var(--atlas-text-2); }
.sf-readings li.is-off{ border-left-color:#f59e0b; }
.sf-readings b{ color:#fff; white-space:nowrap; }
.sf-readings small{ grid-column:1 / -1; font-size:11px; color:var(--atlas-muted); }
.sf-panel .sf-risk{ display:inline-block; padding:7px 18px; border-radius:8px; font-size:20px; font-weight:800; text-transform:capitalize; color:#fff; background:#15803d; }
.sf-panel .sf-risk.is-medium{ background:#b45309; }
.sf-panel .sf-risk.is-high{ background:#c2410c; }
.sf-panel .sf-risk.is-critical{ background:#b91c1c; }
.sf-loop{ margin:0; font-size:13px; color:var(--atlas-text-2); }
.sf-loop i{ color:#60a5fa; }
@media (max-width:860px){
  .sf-track{ grid-template-columns:repeat(3, minmax(0, 1fr)); gap:12px 0; }
  .sf-line{ display:none; }
  .sf-panel{ grid-template-columns:minmax(0, 1fr); }
  .sf-panel__live{ padding:14px 0 0; border-left:0; border-top:1px solid var(--atlas-border); }
}
@media (max-width:520px){ .sf-readings{ grid-template-columns:minmax(0, 1fr); } }
@media (prefers-reduced-motion:reduce){
  .sf-fill, .sf-packet, .sf-stop__icon{ transition:none; }
  .sf-packet, .sf--ready .sf-panel.is-active{ animation:none; }
}
.sf{ margin-top:18px; scroll-margin-top:80px; }

/* Top-bar links shown as an icon on wide screens (the bar is full); the burger menu shows their label. */
.atlas-nav__link--icon .atlas-nav__label{ display:none; }
@media (max-width:980px){ .atlas-nav__link--icon .atlas-nav__label{ display:inline; } }
