/* HotelBox Admin UI (TailAdmin-inspired, no build step required) */
:root{
  --bg:#f5f6fa;
  --surface:#ffffff;
  --surface-2:#f2f4f7;
  --text:#0f172a;
  --muted:#64748b;
  --border:#e5e7eb;
  --primary:#4f46e5;     /* indigo-600 */
  --primary-2:#4338ca;   /* indigo-700 */
  --ok:#10b981;          /* emerald */
  --warn:#f59e0b;        /* amber */
  --bad:#e11d48;         /* rose */
  --shadow: 0 18px 45px rgba(15,23,42,.12);
  --shadow-sm: 0 10px 24px rgba(15,23,42,.10);
  --radius: 18px;
  --radius-sm: 14px;
}

html[data-theme="dark"]{
  --bg:#070a12;
  --surface:#0b1220;
  --surface-2:#0f172a;
  --text:#e5e7eb;
  --muted:#94a3b8;
  --border: rgba(148,163,184,.18);
  --shadow: 0 14px 40px rgba(0,0,0,.55);
  --shadow-sm: 0 8px 18px rgba(0,0,0,.45);
}

*{ box-sizing:border-box; }
body{
  margin:0;
  font-family: ui-sans-serif, system-ui, -apple-system, Segoe UI, Roboto, Ubuntu;
  background:
    radial-gradient(900px 520px at 8% 8%, rgba(79,70,229,.16), transparent 55%),
    radial-gradient(900px 520px at 92% 12%, rgba(16,185,129,.11), transparent 55%),
    radial-gradient(700px 400px at 50% -10%, rgba(14,165,233,.08), transparent 60%),
    var(--bg);
  color:var(--text);
  min-height:100vh;
}
a{ color:inherit; }

.hb-app{ display:flex; min-height:100vh; width:100%; }

/* Sidebar */
.hb-sidebar{
  width:280px;
  flex: 0 0 280px;
  background: rgba(255,255,255,.86);
  backdrop-filter: blur(12px);
  border-right: 1px solid var(--border);
  padding: 16px 14px;
}
html[data-theme="dark"] .hb-sidebar{ background: rgba(11,18,32,.74); }

.hb-brand{
  display:flex; align-items:center; gap:12px;
  padding: 8px 10px 14px;
}
.hb-logo{
  width:44px; height:44px; border-radius: 16px;
  background: linear-gradient(135deg, var(--primary), #22c55e);
  box-shadow: 0 14px 30px rgba(79,70,229,.25);
}
.hb-logo.has-img{ background: transparent; box-shadow:none; }
.hb-logo img{ width:100%; height:100%; object-fit:contain; border-radius:16px; display:block; }

.hb-brand-title{ font-weight: 900; letter-spacing: .2px; font-size: 14px; }
.hb-brand-sub{ font-size: 12px; color: var(--muted); margin-top: 2px; }

.hb-nav{ display:flex; flex-direction:column; gap:14px; padding: 6px 8px; }
.hb-nav-group{ display:grid; gap:6px; }
.hb-nav-heading{
  padding: 4px 12px 2px;
  font-size: 11px;
  font-weight: 900;
  letter-spacing: .08em;
  text-transform: uppercase;
  color: var(--muted);
}
.hb-navlink{
  display:flex; align-items:center; gap:10px;
  padding: 10px 12px;
  border-radius: 14px;
  color: var(--muted);
  text-decoration:none;
  border: 1px solid transparent;
  transition: .15s ease;
  font-weight: 800;
  font-size: 13px;
}
.hb-navlink:hover{
  color: var(--text);
  background: rgba(15,23,42,.06);
}
html[data-theme="dark"] .hb-navlink:hover{
  background: rgba(148,163,184,.10);
}
.hb-navlink.active{
  color: var(--text);
  background: rgba(79,70,229,.10);
  border-color: rgba(79,70,229,.18);
}
.hb-ico svg{ width:18px; height:18px; opacity:.9; }

.hb-sidebar-tip{
  margin-top: 16px;
  padding: 12px;
  border-radius: var(--radius);
  border: 1px solid var(--border);
  background: rgba(243,244,246,.72);
  color: var(--muted);
  font-size: 12px;
}
html[data-theme="dark"] .hb-sidebar-tip{ background: rgba(2,6,23,.30); }

/* Main */
.hb-main{ flex: 1 1 auto; min-width: 0; display:flex; flex-direction:column; }

.hb-topbar{
  position: sticky;
  top: 0;
  z-index: 30;
  border-bottom: 1px solid var(--border);
  background: rgba(255,255,255,.78);
  backdrop-filter: blur(12px);
}
html[data-theme="dark"] .hb-topbar{ background: rgba(11,18,32,.55); }
.hb-topbar-inner{
  max-width: 1240px;
  margin: 0 auto;
  padding: 14px 16px;
  display:flex; align-items:center; justify-content:space-between; gap:12px;
}
.hb-topbar-title{
  font-size: 14px;
  font-weight: 900;
}
.hb-topbar-sub{
  font-size: 12px;
  color: var(--muted);
  margin-top: 2px;
}
.hb-topbar-left{ display:flex; align-items:center; gap:10px; min-width: 0; }
.hb-topbar-right{ display:flex; align-items:center; gap:10px; flex-wrap:wrap; justify-content:flex-end; }

.hb-content{
  width: 100%;
  max-width: 1240px;
  margin: 0 auto;
  padding: 18px 16px 30px;
}

/* Buttons / inputs */
.hb-iconbtn{
  width: 40px; height: 40px;
  display:inline-flex; align-items:center; justify-content:center;
  border-radius: 14px;
  border: 1px solid var(--border);
  background: rgba(255,255,255,.85);
  box-shadow: var(--shadow-sm);
  cursor:pointer;
  transition:.15s ease;
}
html[data-theme="dark"] .hb-iconbtn{ background: rgba(11,18,32,.65); }
.hb-iconbtn:hover{ transform: translateY(-1px); }
.hb-iconbtn svg{ width: 18px; height: 18px; }

.hb-btn{
  display:inline-flex; align-items:center; gap:8px;
  padding: 10px 12px;
  border-radius: 14px;
  border: 1px solid var(--border);
  background: rgba(255,255,255,.85);
  box-shadow: var(--shadow-sm);
  cursor:pointer;
  font-weight: 900;
  font-size: 13px;
  transition:.15s ease;
}
html[data-theme="dark"] .hb-btn{ background: rgba(11,18,32,.65); }
.hb-btn:hover{ transform: translateY(-1px); }

.hb-select{
  padding: 10px 12px;
  border-radius: 14px;
  border: 1px solid var(--border);
  background: rgba(255,255,255,.85);
  box-shadow: var(--shadow-sm);
  font-weight: 800;
  font-size: 13px;
  color: var(--text);
}
html[data-theme="dark"] .hb-select{ background: rgba(11,18,32,.65); color: var(--text); }
.hb-select:focus, .hb-btn:focus, .hb-iconbtn:focus{ outline: none; box-shadow: 0 0 0 4px rgba(79,70,229,.18), var(--shadow-sm); }

/* Theme icon swap */
.hb-theme-sun{ display:none; }
html[data-theme="dark"] .hb-theme-sun{ display:inline; }
html[data-theme="dark"] .hb-theme-moon{ display:none; }

/* Alerts */
.msg{
  padding: 12px 14px;
  border-radius: var(--radius);
  border: 1px solid var(--border);
  box-shadow: var(--shadow-sm);
  margin-bottom: 12px;
  font-weight: 800;
  font-size: 13px;
}
.msg.ok{ background: rgba(16,185,129,.12); border-color: rgba(16,185,129,.22); color: #065f46; }
html[data-theme="dark"] .msg.ok{ color: #a7f3d0; }
.msg.err{ background: rgba(225,29,72,.10); border-color: rgba(225,29,72,.20); color: #9f1239; }
html[data-theme="dark"] .msg.err{ color: #fecdd3; }

/* Legacy page helpers */
.page-title{ display:flex; align-items:flex-end; justify-content:space-between; gap: 14px; margin-bottom: 12px; }
.page-title h2{ margin:0; font-size: 18px; font-weight: 950; letter-spacing: .2px; }
.page-title p{ margin:6px 0 0; color: var(--muted); font-size: 13px; }

.kpis{ display:grid; gap: 12px; grid-template-columns: repeat(4, minmax(0,1fr)); }
@media (max-width: 1100px){ .kpis{ grid-template-columns: repeat(2, minmax(0,1fr)); } }
@media (max-width: 520px){ .kpis{ grid-template-columns: 1fr; } }

/* KPI cards (prevents label/number clipping on rounded cards) */
.kpi{
  padding: 14px 16px;
  display:flex;
  flex-direction:column;
  gap: 2px;
  min-height: 78px;
}
.kpi .val{
  font-size: 22px;
  font-weight: 950;
  line-height: 1.15;
  letter-spacing: .2px;
}
.kpi .lbl{
  font-size: 12px;
  color: var(--muted);
  font-weight: 900;
  line-height: 1.2;
}

.card{
  background: rgba(255,255,255,.90);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  overflow:hidden;
}
html[data-theme="dark"] .card{ background: rgba(11,18,32,.62); }

.card-hd{
  display:flex; align-items:center; justify-content:space-between; gap:12px;
  padding: 12px 14px;
  border-bottom: 1px solid var(--border);
}
.card-hd h3{ margin:0; font-size: 13px; font-weight: 950; letter-spacing:.2px; }
.card-bd{ padding: 14px; }

.muted{ color: var(--muted); }
.row{ display:flex; flex-wrap:wrap; align-items:center; gap: 10px; }

/* Better table action layout (prevents odd stacking on wide screens) */
.actions{ display:flex; align-items:center; justify-content:flex-end; gap:10px; flex-wrap:wrap; }
.actions form{ margin:0; }
.actions form, .actions .row{ display:inline-flex; align-items:center; gap:8px; flex-wrap:wrap; }
.actions select{ width:auto !important; }

/* Form-like tables (used in settings/appearance screens) */
.card-bd > table:not(.data){ width:100%; border-collapse: separate; border-spacing: 0; }
.card-bd > table:not(.data) tr + tr th,
.card-bd > table:not(.data) tr + tr td{ border-top: 1px solid rgba(229,231,235,.75); }
html[data-theme="dark"] .card-bd > table:not(.data) tr + tr th,
html[data-theme="dark"] .card-bd > table:not(.data) tr + tr td{ border-top-color: rgba(148,163,184,.15); }
.card-bd > table:not(.data) th{
  padding: 12px 14px;
  text-align:left;
  color: var(--muted);
  font-size: 12px;
  font-weight: 950;
  letter-spacing: .01em;
  vertical-align: top;
}
.card-bd > table:not(.data) td{ padding: 12px 14px; }
.card-bd > table:not(.data) td > .row{ gap:12px; }

/* Action buttons inside tables */
.btn{
  display:inline-flex; align-items:center; justify-content:center;
  padding: 9px 12px;
  border-radius: 14px;
  border: 1px solid var(--border);
  background: rgba(255,255,255,.86);
  box-shadow: var(--shadow-sm);
  cursor:pointer;
  font-weight: 900;
  font-size: 13px;
  transition:.15s ease;
  text-decoration:none;
}
html[data-theme="dark"] .btn{ background: rgba(11,18,32,.60); }
.btn:hover{ transform: translateY(-1px); }
.btn.primary{ background: var(--primary); border-color: rgba(79,70,229,.25); color: #fff; }
.btn.primary:hover{ background: var(--primary-2); }
.btn.danger{ background: var(--bad); border-color: rgba(225,29,72,.25); color: #fff; }
.btn.danger:hover{ filter: brightness(.95); }
.btn.link{ background: transparent; box-shadow:none; }

.pill{
  display:inline-flex; align-items:center;
  padding: 6px 10px;
  border-radius: 999px;
  border: 1px solid var(--border);
  background: rgba(243,244,246,.72);
  color: var(--text);
  font-weight: 900;
  font-size: 12px;
}
html[data-theme="dark"] .pill{ background: rgba(2,6,23,.30); }
.pill.ok{ border-color: rgba(16,185,129,.22); background: rgba(16,185,129,.12); color: #065f46; }
html[data-theme="dark"] .pill.ok{ color:#a7f3d0; }
.pill.warn{ border-color: rgba(245,158,11,.25); background: rgba(245,158,11,.12); color:#92400e; }
html[data-theme="dark"] .pill.warn{ color:#fde68a; }
.pill.bad{ border-color: rgba(225,29,72,.25); background: rgba(225,29,72,.10); color:#9f1239; }
html[data-theme="dark"] .pill.bad{ color:#fecdd3; }

.grid{ display:grid; gap: 12px; }

/* Tables */
table{ width:100%; border-collapse: collapse; }
thead th{
  text-align:left;
  padding: 12px 14px;
  font-size: 11px;
  letter-spacing: .10em;
  text-transform: uppercase;
  color: var(--muted);
  background: rgba(243,244,246,.60);
  border-bottom: 1px solid var(--border);
}
html[data-theme="dark"] thead th{ background: rgba(2,6,23,.22); }
tbody td{
  padding: 12px 14px;
  border-bottom: 1px solid rgba(229,231,235,.75);
  vertical-align: top;
}
html[data-theme="dark"] tbody td{ border-bottom-color: rgba(148,163,184,.15); }
tbody tr:hover td{ background: rgba(243,244,246,.30); }
html[data-theme="dark"] tbody tr:hover td{ background: rgba(2,6,23,.20); }

input, select, textarea{
  width:auto;
  color: var(--text);
}
.card input, .card select, .card textarea{
  width: 100%;
  padding: 10px 12px;
  border-radius: 14px;
  border: 1px solid var(--border);
  background: rgba(255,255,255,.86);
  box-shadow: var(--shadow-sm);
  font-weight: 700;
  font-size: 13px;
}
html[data-theme="dark"] .card input,
html[data-theme="dark"] .card select,
html[data-theme="dark"] .card textarea{ background: rgba(11,18,32,.60); }

.card input:focus, .card select:focus, .card textarea:focus{
  outline:none;
  box-shadow: 0 0 0 4px rgba(79,70,229,.18), var(--shadow-sm);
}

.pagination{ padding: 14px; }

/* Mobile sidebar */
.hb-overlay{
  position:fixed; inset:0; z-index: 45;
  background: rgba(0,0,0,.45);
  display:none;
}
.hb-sidebar-mobile-close{ display:none; }

@media (max-width: 1023px){
  .hb-sidebar{
    position: fixed;
    left: 0; top: 0; bottom: 0;
    transform: translateX(-110%);
    transition: transform .18s ease;
    z-index: 50;
    box-shadow: var(--shadow);
  }
  .hb-sidebar.is-open{ transform: translateX(0); }
  .hb-overlay.is-open{ display:block; }
  .hb-sidebar-mobile-close{
    display:inline-flex;
    margin-left:auto;
  }
  .hb-topbar-titlewrap{ display:none; }
}
@media (min-width: 1024px){
  .hb-mobile-only{ display:none !important; }
}

/* Footer */
.hb-footer{
  border-top: 1px solid var(--border);
  padding: 14px 16px;
  color: var(--muted);
  font-size: 12px;
  text-align:center;
}


/* KPI compact single-row (March 2, 2026)
   - Keeps KPI cards on a single horizontal line
   - Smaller cards, no overlap/clipping
*/
.kpis{
  display:flex;
  gap: 10px;
  overflow-x:auto;
  padding-bottom: 4px;
  -webkit-overflow-scrolling: touch;
  scroll-snap-type: x proximity;
}
.kpis .card{
  flex: 0 0 auto;
  min-width: 160px;
  max-width: 220px;
  scroll-snap-align: start;
}
@media (max-width: 520px){
  .kpis .card{ min-width: 150px; }
}
.kpi{
  padding: 10px 12px;
  min-height: 64px;
}
.kpi .val{ font-size: 18px; }
.kpi .lbl{ font-size: 11px; }


/* Responsive helpers (added 2026-03-03) */
@media (max-width: 980px){
  .grid{ grid-template-columns: 1fr !important; }
  .hb-topbar-inner{ flex-wrap: wrap; gap: 10px; }
  .page-title{ flex-wrap: wrap; gap: 10px; }
  table{ display:block; overflow-x:auto; }
}
@media (max-width: 520px){
  .card-bd{ padding: 12px 12px !important; }
  .hb-brand-title{ font-size: 16px; }
}


.hb-top-alert{
  position:relative;
  text-decoration:none;
  color:inherit;
}
.hb-top-alert-count{
  position:absolute;
  top:-6px;
  right:-6px;
  min-width:20px;
  height:20px;
  padding:0 6px;
  display:inline-flex;
  align-items:center;
  justify-content:center;
  border-radius:999px;
  background:var(--bad);
  color:#fff;
  font-size:11px;
  font-weight:900;
  box-shadow:0 6px 14px rgba(225,29,72,.35);
}
.hb-top-alert-count.is-hidden{ display:none; }
.hb-service-desk-pill.is-hidden{ display:none; }
.pulse{ animation: hbPulse 1.4s ease-in-out infinite; }
@keyframes hbPulse{
  0%,100%{ transform:scale(1); box-shadow:0 0 0 0 rgba(225,29,72,.24); }
  50%{ transform:scale(1.06); box-shadow:0 0 0 8px rgba(225,29,72,0); }
}


/* Visual refinement pack */
.hb-sidebar{
  box-shadow: inset -1px 0 0 rgba(255,255,255,.18);
}
.hb-topbar{
  box-shadow: 0 10px 30px rgba(15,23,42,.06);
}
.hb-topbar-inner,
.hb-content{
  max-width: 1320px;
}
.hb-context-shell{
  display:flex;
  align-items:center;
  gap:10px;
  flex-wrap:wrap;
}
.hb-context-card{
  min-width: 320px;
  padding: 10px 12px;
  border-radius: 18px;
  border: 1px solid rgba(79,70,229,.14);
  background: linear-gradient(180deg, rgba(255,255,255,.92), rgba(248,250,252,.88));
  box-shadow: var(--shadow-sm);
}
html[data-theme="dark"] .hb-context-card{
  background: linear-gradient(180deg, rgba(15,23,42,.82), rgba(11,18,32,.72));
  border-color: rgba(129,140,248,.18);
}
.hb-context-card-label{
  font-size: 11px;
  color: var(--muted);
  font-weight: 900;
  letter-spacing: .05em;
  text-transform: uppercase;
  margin-bottom: 6px;
}
.hb-context-card-value{
  display:flex;
  align-items:center;
  gap:10px;
  font-size: 14px;
  font-weight: 950;
}
.hb-context-card-value strong{
  color: var(--text);
}
.hb-mini-stat{
  display:flex;
  align-items:center;
  gap:8px;
  padding: 8px 12px;
  border-radius: 999px;
  border: 1px solid rgba(148,163,184,.22);
  background: rgba(255,255,255,.80);
  box-shadow: var(--shadow-sm);
  font-size: 12px;
  font-weight: 900;
}
html[data-theme="dark"] .hb-mini-stat{
  background: rgba(15,23,42,.72);
}
.hb-user-pill{
  display:flex;
  align-items:center;
  gap:10px;
  padding: 7px 12px 7px 8px;
  border-radius: 999px;
  background: rgba(255,255,255,.88);
  border: 1px solid rgba(148,163,184,.22);
  box-shadow: var(--shadow-sm);
}
html[data-theme="dark"] .hb-user-pill{
  background: rgba(15,23,42,.72);
}
.hb-user-avatar{
  width: 34px;
  height: 34px;
  border-radius: 999px;
  display:inline-flex;
  align-items:center;
  justify-content:center;
  background: linear-gradient(135deg, var(--primary), #06b6d4);
  color: #fff;
  font-weight: 950;
  box-shadow: 0 10px 22px rgba(79,70,229,.24);
}
.hb-user-copy{
  display:flex;
  flex-direction:column;
  line-height:1.05;
}
.hb-user-copy strong{ font-size: 13px; }
.hb-user-copy span{ font-size: 11px; color: var(--muted); font-weight: 800; margin-top: 2px; }
.hb-hero-panel{
  padding: 18px 20px;
  border-radius: 24px;
  border: 1px solid rgba(79,70,229,.12);
  background: linear-gradient(180deg, rgba(255,255,255,.92), rgba(248,250,252,.88));
  box-shadow: var(--shadow);
}
html[data-theme="dark"] .hb-hero-panel{
  background: linear-gradient(180deg, rgba(15,23,42,.82), rgba(11,18,32,.72));
  border-color: rgba(129,140,248,.16);
}
.hb-hero-grid{
  display:grid;
  grid-template-columns: minmax(0,1.3fr) minmax(320px,.9fr);
  gap:14px;
}
.hb-hero-title{
  margin:0;
  font-size: 24px;
  line-height: 1.05;
  font-weight: 950;
  letter-spacing: -.02em;
}
.hb-hero-sub{
  margin-top:8px;
  color: var(--muted);
  font-size: 13px;
  max-width: 720px;
}
.hb-stat-grid{
  display:grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap:10px;
}
.hb-stat-card{
  padding: 14px 16px;
  border-radius: 20px;
  border: 1px solid rgba(148,163,184,.18);
  background: rgba(255,255,255,.76);
}
html[data-theme="dark"] .hb-stat-card{
  background: rgba(15,23,42,.70);
}
.hb-stat-card .num{
  font-size: 24px;
  font-weight: 950;
  letter-spacing: -.02em;
}
.hb-stat-card .lbl{
  margin-top:4px;
  color: var(--muted);
  font-size: 12px;
  font-weight: 900;
}
.hb-chip-list{ display:flex; flex-wrap:wrap; gap:8px; margin-top:12px; }
.hb-soft-chip{
  display:inline-flex;
  align-items:center;
  gap:8px;
  padding: 8px 12px;
  border-radius: 999px;
  border: 1px solid rgba(148,163,184,.18);
  background: rgba(255,255,255,.72);
  font-size: 12px;
  font-weight: 900;
}
html[data-theme="dark"] .hb-soft-chip{ background: rgba(15,23,42,.68); }
.hb-soft-chip strong{ color: var(--text); }
.hb-context-banner{
  display:flex;
  justify-content:space-between;
  gap:14px;
  flex-wrap:wrap;
  align-items:flex-start;
  padding: 16px 18px;
  margin-bottom: 14px;
  border-radius: 22px;
  border: 1px solid rgba(79,70,229,.12);
  background: linear-gradient(180deg, rgba(255,255,255,.92), rgba(248,250,252,.84));
  box-shadow: var(--shadow);
}
html[data-theme="dark"] .hb-context-banner{ background: linear-gradient(180deg, rgba(15,23,42,.84), rgba(11,18,32,.72)); }
.hb-context-banner h3{ margin:0; font-size: 18px; font-weight: 950; }
.hb-context-banner p{ margin:6px 0 0; color:var(--muted); font-size: 13px; }
.hb-shortcuts{ display:flex; flex-wrap:wrap; gap:8px; }
.hb-shortcuts .btn{ padding: 8px 12px; }
.card{ backdrop-filter: blur(12px); }
.card-hd{
  background: linear-gradient(180deg, rgba(255,255,255,.72), rgba(248,250,252,.54));
}
html[data-theme="dark"] .card-hd{
  background: linear-gradient(180deg, rgba(15,23,42,.58), rgba(11,18,32,.34));
}
thead th{
  background: linear-gradient(180deg, rgba(243,244,246,.86), rgba(248,250,252,.72));
}
html[data-theme="dark"] thead th{
  background: linear-gradient(180deg, rgba(2,6,23,.36), rgba(15,23,42,.18));
}
tbody tr:hover td{
  background: rgba(99,102,241,.05);
}
html[data-theme="dark"] tbody tr:hover td{
  background: rgba(79,70,229,.12);
}
@media (max-width: 1100px){
  .hb-hero-grid{ grid-template-columns: 1fr; }
}
@media (max-width: 900px){
  .hb-context-card{ min-width: 100%; }
  .hb-topbar-right{ justify-content:flex-start; }
}


/* Final UX micro-refinement */
html{ scroll-behavior:smooth; }
:focus-visible{
  outline:none;
}
.hb-navlink:focus-visible,
.hb-btn:focus-visible,
.hb-iconbtn:focus-visible,
.hb-select:focus-visible,
.btn:focus-visible,
.card input:focus-visible,
.card select:focus-visible,
.card textarea:focus-visible{
  box-shadow: 0 0 0 4px rgba(79,70,229,.20), var(--shadow-sm);
}
input::placeholder, textarea::placeholder{ color: color-mix(in srgb, var(--muted) 78%, transparent); }
.hb-empty-state{
  border:1px dashed rgba(148,163,184,.34);
  border-radius:18px;
  padding:18px;
  background:rgba(148,163,184,.08);
  display:grid;
  gap:6px;
}
html[data-theme="dark"] .hb-empty-state{
  background:rgba(15,23,42,.48);
  border-color:rgba(148,163,184,.22);
}
.hb-table-actions{
  display:flex;
  justify-content:flex-end;
  gap:8px;
  flex-wrap:wrap;
}
.hb-table-actions form{ margin:0; }
tbody tr td:first-child{ white-space:nowrap; }
::-webkit-scrollbar{ width:10px; height:10px; }
::-webkit-scrollbar-thumb{ background:rgba(100,116,139,.35); border-radius:999px; }
::-webkit-scrollbar-track{ background:transparent; }
@media (prefers-reduced-motion: reduce){
  *, *::before, *::after{ animation:none !important; transition:none !important; scroll-behavior:auto !important; }
}


/* --- Dashboard premium / stacked admin pages --- */
.hb-page-stack{ display:grid; gap:14px; }
.hb-form-grid{ display:grid; gap:14px; }
.hb-form-grid-2{ grid-template-columns: repeat(2, minmax(0,1fr)); }
.hb-form-grid-3{ grid-template-columns: minmax(0,1fr) minmax(0,1fr) auto; }
.hb-form-grid-4{ grid-template-columns: repeat(4, minmax(0,1fr)); }
.hb-field-label{ display:block; margin-bottom:6px; font-size:12px; }
.hb-dashboard-grid{ grid-template-columns: 1.05fr .95fr; }
.hb-dashboard-hero{
  background:
    radial-gradient(520px 220px at 0% 0%, rgba(79,70,229,.18), transparent 60%),
    radial-gradient(420px 220px at 100% 0%, rgba(16,185,129,.12), transparent 60%),
    linear-gradient(180deg, rgba(255,255,255,.94), rgba(248,250,252,.92));
}
html[data-theme="dark"] .hb-dashboard-hero{
  background:
    radial-gradient(520px 220px at 0% 0%, rgba(79,70,229,.20), transparent 60%),
    radial-gradient(420px 220px at 100% 0%, rgba(16,185,129,.16), transparent 60%),
    linear-gradient(180deg, rgba(15,23,42,.90), rgba(11,18,32,.82));
}
.hb-priority-grid{ display:grid; gap:12px; grid-template-columns: repeat(4, minmax(0,1fr)); }
.hb-priority-card{
  position:relative;
  overflow:hidden;
  padding:16px;
  border-radius:22px;
  color:#fff;
  box-shadow: var(--shadow);
  border:1px solid rgba(255,255,255,.12);
}
.hb-priority-card::after{
  content:"";
  position:absolute;
  inset:auto -20% -30% auto;
  width:150px;
  height:150px;
  border-radius:999px;
  background:rgba(255,255,255,.12);
  filter: blur(8px);
}
.hb-priority-card.is-good{ background:linear-gradient(135deg, #059669, #10b981); }
.hb-priority-card.is-warn{ background:linear-gradient(135deg, #d97706, #f59e0b); }
.hb-priority-card.is-danger{ background:linear-gradient(135deg, #be123c, #f43f5e); }
.hb-priority-card.is-info{ background:linear-gradient(135deg, #4f46e5, #06b6d4); }
.hb-priority-top{ display:flex; align-items:center; justify-content:space-between; gap:12px; }
.hb-priority-kicker{ font-size:11px; font-weight:900; text-transform:uppercase; letter-spacing:.12em; opacity:.92; }
.hb-priority-badge{
  display:inline-flex;
  align-items:center;
  justify-content:center;
  min-width:56px;
  padding:6px 10px;
  border-radius:999px;
  background:rgba(255,255,255,.18);
  font-size:12px;
  font-weight:950;
}
.hb-priority-title{ margin-top:18px; font-size:22px; font-weight:950; line-height:1.05; letter-spacing:-.02em; }
.hb-priority-meta{ margin-top:8px; font-size:12px; line-height:1.45; opacity:.94; max-width:34ch; }
.hb-meter-list{ display:grid; gap:14px; }
.hb-meter-row{ display:grid; gap:7px; }
.hb-meter-head{ display:flex; align-items:center; justify-content:space-between; gap:12px; font-weight:900; }
.hb-meter-head span{ font-size:13px; }
.hb-meter-head strong{ font-size:13px; }
.hb-meter-track{
  width:100%;
  height:12px;
  border-radius:999px;
  overflow:hidden;
  background: rgba(148,163,184,.16);
  border:1px solid rgba(148,163,184,.12);
}
.hb-meter-fill{ height:100%; border-radius:999px; }
.hb-meter-fill.is-primary{ background:linear-gradient(90deg, #4f46e5, #6366f1); }
.hb-meter-fill.is-good{ background:linear-gradient(90deg, #059669, #10b981); }
.hb-meter-fill.is-info{ background:linear-gradient(90deg, #0ea5e9, #06b6d4); }
.hb-meter-fill.is-violet{ background:linear-gradient(90deg, #7c3aed, #a855f7); }
.hb-meter-fill.is-warn{ background:linear-gradient(90deg, #d97706, #f59e0b); }
.hb-meter-fill.is-danger{ background:linear-gradient(90deg, #be123c, #f43f5e); }
.hb-meter-note{ font-size:12px; color:var(--muted); }
.hb-segment-card{
  display:grid;
  gap:10px;
  padding:14px;
  border-radius:18px;
  border:1px solid var(--border);
  background: rgba(148,163,184,.06);
}
html[data-theme="dark"] .hb-segment-card{ background: rgba(2,6,23,.32); }
.hb-segment-row{ display:flex; justify-content:space-between; gap:12px; font-size:13px; }
.hb-segment-row strong{ font-size:15px; }
.hb-focus-list{ display:grid; gap:10px; }
.hb-focus-item{
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:12px;
  padding:12px 14px;
  border-radius:18px;
  border:1px solid rgba(148,163,184,.18);
  background: rgba(148,163,184,.08);
}
.hb-focus-item strong{ font-size:18px; font-weight:950; }
.hb-focus-label{ font-weight:900; font-size:13px; }
.hb-focus-item.is-good{ border-color: rgba(16,185,129,.20); background: rgba(16,185,129,.10); }
.hb-focus-item.is-warn{ border-color: rgba(245,158,11,.24); background: rgba(245,158,11,.12); }
.hb-focus-item.is-danger{ border-color: rgba(244,63,94,.24); background: rgba(244,63,94,.12); }
.hb-focus-item.is-info{ border-color: rgba(79,70,229,.22); background: rgba(79,70,229,.10); }
.hb-premium-kpis{
  display:grid;
  gap:10px;
  overflow:visible;
  grid-template-columns: repeat(6, minmax(0,1fr));
}
.hb-premium-kpis .card{
  position:relative;
  overflow:hidden;
  min-width:0;
  max-width:none;
}
.hb-premium-kpis .kpi{
  min-height:76px;
  padding:12px 12px 12px 16px;
}
.hb-premium-kpis .kpi .lbl{
  display:-webkit-box;
  -webkit-line-clamp:2;
  -webkit-box-orient:vertical;
  overflow:hidden;
  line-height:1.25;
  min-height:28px;
}
@media (max-width: 1500px){
  .hb-premium-kpis{ grid-template-columns: repeat(4, minmax(0,1fr)); }
}
@media (max-width: 1100px){
  .hb-premium-kpis{ grid-template-columns: repeat(3, minmax(0,1fr)); }
}
@media (max-width: 780px){
  .hb-premium-kpis{ grid-template-columns: repeat(2, minmax(0,1fr)); }
}
@media (max-width: 520px){
  .hb-premium-kpis{ grid-template-columns: 1fr; }
}
.hb-kpi-tone::before{
  content:"";
  position:absolute;
  inset:0 auto 0 0;
  width:5px;
  background: var(--primary);
}
.hb-kpi-tone.is-neutral::before{ background: linear-gradient(180deg, #64748b, #cbd5e1); }
.hb-kpi-tone.is-good::before{ background: linear-gradient(180deg, #059669, #34d399); }
.hb-kpi-tone.is-warn::before{ background: linear-gradient(180deg, #d97706, #fbbf24); }
.hb-kpi-tone.is-danger::before{ background: linear-gradient(180deg, #be123c, #fb7185); }
.hb-kpi-tone.is-info::before{ background: linear-gradient(180deg, #0ea5e9, #67e8f9); }
.hb-kpi-tone.is-violet::before{ background: linear-gradient(180deg, #7c3aed, #c084fc); }
.hb-kpi-tone.is-primary::before{ background: linear-gradient(180deg, #4338ca, #818cf8); }
.hb-status-card{
  display:grid;
  gap:4px;
  min-width:220px;
  padding:10px 12px;
  border-radius:14px;
  border:1px solid var(--border);
}
.hb-status-card.is-good{ border-color:#bbf7d0; background:#f0fdf4; }
.hb-status-card.is-warn{ border-color:#fed7aa; background:#fff7ed; }
.hb-status-card.is-soft-warn{ border-color:#fde68a; background:#fffbeb; color:#92400e; }
@media (max-width: 1200px){
  .hb-priority-grid{ grid-template-columns: repeat(2, minmax(0,1fr)); }
  .hb-dashboard-grid{ grid-template-columns: 1fr; }
  .hb-form-grid-4{ grid-template-columns: repeat(2, minmax(0,1fr)); }
}
@media (max-width: 900px){
  .hb-form-grid-3,
  .hb-form-grid-4,
  .hb-form-grid-2,
  .hb-priority-grid{ grid-template-columns: 1fr; }
}
