:root{
  /* Slightly brighter dark theme for better contrast */
  --bg:#0e1421;
  --panel:#151c2b;
  --card:#141c2a;
  --border:#20304a;

  --text:#f5f8ff;
  --text-strong:#ffffff;
  --muted:#a9b4cc;

  --accent:#4f8cff;
  --accent-2:#66e3c4;
  --ring:rgba(79,140,255,0.35);
  --shadow:0 10px 25px rgba(0,0,0,.35);
  --radius:16px;

  --input-bg:#10192a;
  --chip-bg:rgba(255,255,255,.06);
}

/* ===== 2-column layout with right sidebar ===== */
.layout-hm{
  display:grid;
  grid-template-columns: 1fr 320px;
  gap: 16px;
  padding: 0 8px;
}
@media (max-width: 1200px){
  .layout-hm{ grid-template-columns: 1fr; }
  .sidebar-col{ order: -1; } /* show sidebar first on small screens if you prefer */
}

*{box-sizing:border-box}
html,body{height:100%}
body{
  margin:0;
  font-family: ui-sans-serif, system-ui, -apple-system, Segoe UI, Roboto, Arial, "Apple Color Emoji","Segoe UI Emoji";
  background: radial-gradient(1200px 800px at 10% 0%, #121a2a, #0e1421);
  color:var(--text);
}
a{color:inherit;text-decoration:none}
/* .container{width:min(1100px,92vw);margin:0 auto} */

/* Header / Nav */
.site-header{position:sticky;top:0;z-index:10;background:linear-gradient(180deg, rgba(255,255,255,.04), rgba(255,255,255,0));border-bottom:1px solid var(--border);backdrop-filter:blur(6px); padding: 0 8px;}
.navbar{display:flex;align-items:center;justify-content:space-between;padding:14px 0}
.logo{font-weight:800;letter-spacing:.4px}
.nav{display:flex;gap:12px;align-items:center}
.nav-link{padding:8px 12px;border-radius:10px;color:var(--muted);border:1px solid transparent}
.nav-link.active,.nav-link:hover{color:var(--text);border-color:var(--border);background:rgba(255,255,255,.03)}

/* Footer */
.site-footer{border-top:1px solid var(--border);padding:18px 0 32px;margin-top:40px;color:var(--muted)}

/* Basics */
.page-title{margin:18px 0 6px;font-size:28px}
.page-subtitle{margin:0 0 18px;color:var(--muted)}

.card{
  background: linear-gradient(180deg, rgba(255,255,255,.06), rgba(255,255,255,.03));
  border:1px solid rgba(255,255,255,.08);
  border-radius:var(--radius);
  box-shadow:var(--shadow);
  padding:18px;
  margin:14px 0;
}
.card-title{margin:0 0 10px;font-size:20px}
.grid-cards{display:grid;gap:14px;grid-template-columns:repeat(auto-fill, minmax(220px,1fr))}
.grid-cards2{display:grid;gap:14px;grid-template-columns:repeat(auto-fill, minmax(500px,1fr))}
.stat-card{display:grid;gap:6px;padding:20px;background:var(--card);border:1px solid #1b2332;border-radius:12px}
.stat-value{font-size:28px;font-weight:800}
.stat-label{color:var(--muted)}

/* Auth */
.auth-wrap{display:grid;place-items:center;padding:40px 0}
.card-auth{max-width:420px;width:100%}
.input{
  width:100%;padding:12px 14px;margin:8px 0;border-radius:12px;background:#0e1422;color:var(--text);
  border:1px solid #1c2535;outline:none;transition:.15s;
}
.input:focus{border-color:var(--accent);box-shadow:0 0 0 6px var(--ring)}
.btn{border:none;border-radius:12px;padding:10px 14px;font-weight:700;cursor:pointer;transition:transform .05s,opacity .15s,box-shadow .15s}
.btn:active{transform:translateY(1px)}
.btn-primary{background:linear-gradient(180deg, var(--accent), #3c6fe0);color:white;box-shadow:0 6px 20px rgba(79,140,255,.35)}
.btn-ghost{background:transparent;color:var(--text);border:1px solid var(--border)}
.alert{padding:10px 12px;border-radius:10px;margin:8px 0}
.alert-error{background:#211419;border:1px solid #4a1f2b}
.muted{color:var(--muted)}
.hint{color:var(--muted);font-size:14px;margin-top:8px}

/* ===== Heatmap toolbar layout ===== */

.heatmap-toolbar{ display:flex; flex-direction:column; gap:14px; }

.toolbar-row.top{
  display:flex; align-items:center; justify-content:space-between; gap:12px;
}
.toolbar-actions{ display:flex; align-items:center; gap:12px; }

.toolbar-row.filters{
  display:grid; gap:14px 16px;
  grid-template-columns: repeat(4, minmax(210px, 1fr));
}
@media (max-width: 1200px){ .toolbar-row.filters{ grid-template-columns: repeat(3, minmax(210px, 1fr)); } }
@media (max-width: 820px){ .toolbar-row.filters{ grid-template-columns: repeat(2, minmax(210px, 1fr)); } }
@media (max-width: 560px){ .toolbar-row.filters{ grid-template-columns: 1fr; } }

.control{ display:flex; flex-direction:column; gap:6px; }
.control.checkbox{ flex-direction:row; align-items:center; gap:8px; min-width:auto; }
.control-label{ font-size:12px; color:var(--muted); }

select,
.heatmap-toolbar input[type="text"],
.heatmap-toolbar .checkbox,
.heatmap-toolbar input[type="number"]{
  background: var(--input-bg);
  color: var(--text);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 10px 12px;
  outline: none;
  transition: border-color .15s, box-shadow .15s;
}
select:focus,
.heatmap-toolbar input[type="text"]:focus,
.heatmap-toolbar input[type="number"]:focus{
  border-color: var(--accent);
  box-shadow: 0 0 0 6px var(--ring);
}

.last-updated{
  color: var(--muted);
  font-size: 12px;
  min-width: max-content;
}

/* Env switch */
.env-toggle { display: flex; align-items: center; gap: 8px;border: 2px dotted gray;border-radius: 20px; }
.env-pill{
  font-size:12px; padding:4px 10px; border-radius:999px;
  border:1px solid var(--border); background: var(--chip-bg);
  display: inline-block;
}
.switch { position: relative; display: inline-block; width: 52px; height: 28px; }
.switch input { opacity: 0; width: 0; height: 0; }
.switch .slider {
  position: absolute; inset: 0; cursor: pointer;
  background: #243048; border: 1px solid var(--border);
  border-radius: 999px; transition: .2s;
}
.switch .slider:before {
  content: ""; position: absolute; height: 22px; width: 22px; left: 3px; top: 2px;
  background: #fff; border-radius: 50%; transition: .2s;
}
.switch input:checked + .slider { background: #2c8550; border-color: #2c8550; }
.switch input:checked + .slider:before { transform: translateX(24px); }

/* ===== Heatmap grid & tiles ===== */

.heatmap-grid{
  display:grid;
  gap:12px;
  grid-template-columns:repeat(auto-fill, minmax(220px,1fr));
  margin-top:8px;
}

button.heatmap-tile{ appearance:none; -webkit-appearance:none; }

.heatmap-tile{
  display:grid;
  gap:8px;
  border:1px solid var(--border);
  border-radius:12px;
  background: var(--card);
  padding:14px;
  text-align:left;
  cursor:pointer;
  transition:transform .06s ease, box-shadow .15s ease, border-color .15s ease;
  box-shadow:var(--shadow);
  position:relative;
  isolation:isolate;
  color: var(--text);
}
.heatmap-tile::before{
  content:"";
  position:absolute; inset:0;
  background: linear-gradient(180deg, var(--tile-bg), transparent 130%);
  opacity:.28;               /* lighter tint so text remains readable */
  border-radius:12px;
  z-index:-1;
}
.heatmap-tile::after{
  content:""; position:absolute; inset:0; border-radius:12px; pointer-events:none;
  background: linear-gradient(180deg, rgba(255,255,255,.08), transparent 55%);
}
.heatmap-tile:hover{ transform: translateY(-1px); border-color: rgba(102,227,196,.35); }

.tile-title{ font-weight:800; letter-spacing:.2px; color: var(--text-strong); text-shadow: 0 1px 2px rgba(0,0,0,.55); }
.tile-metric{ display:flex; align-items:baseline; gap:8px; }
.tile-count{ font-size:28px; font-weight:900; color: var(--text-strong); text-shadow: 0 1px 2px rgba(0,0,0,.55); }
.tile-cap{ color:var(--muted); }
.tile-sub{ color:var(--muted); font-size:12px; }

/* In hot states increase contrast a bit more */
.heatmap-tile.hot .tile-title,
.heatmap-tile.hot .tile-count{ text-shadow: 0 1px 3px rgba(0,0,0,.75); }

/* Legend */
.legend{ display:flex; align-items:center; gap:10px; margin-top:10px; color:var(--muted); }
.legend-bar{ display:flex; gap:2px; align-items:center; }
.legend-stop{ width:28px; height:10px; border-radius:3px; background: var(--c); border:1px solid rgba(0,0,0,.25); }
.legend-label{ font-size:12px; }

/* ===== Modal ===== */

.modal{ position:fixed; inset:0; display:none; z-index:1000; }
.modal.open{ display:block; }
.modal-backdrop{ position:absolute; inset:0; background:rgba(0,0,0,.55); backdrop-filter: blur(2px); }
.modal-dialog{
  position:relative; width:min(960px, 92vw); max-height:85vh; overflow:auto; margin:6vh auto;
  background:var(--panel); border:1px solid var(--border); border-radius:16px; box-shadow:var(--shadow);
  padding:16px 16px 18px;
}
.modal-header{ display:flex; justify-content:space-between; align-items:center; gap:12px; }
.modal-body{ margin-top:8px; }

/* Proxy grid */
.proxy-grid{ display:grid; gap:12px; grid-template-columns:repeat(auto-fill, minmax(300px, 1fr)); }
.proxy-card{ border:3px solid #1b2332; border-radius:12px; padding:12px; background:var(--card); }
.proxy-card.ok{ border-color: rgba(102,227,196,.35); }
.proxy-card.down{ border-color: rgba(229,57,53,.35); }
.proxy-title{ font-weight:700; }
.proxy-sub{ color:var(--muted); font-size:12px; }
.badge{ display:inline-block; padding:2px 8px; margin: 2px 0px; border-radius:999px; font-size:11px; border:1px solid var(--border);}
.badge.ok{ background: rgba(102,227,196,.15); }
.badge.down{ background: rgba(229,57,53,.15); }

.proxy-toolbar{ display:flex; gap:12px; align-items:center; margin: 8px 0 12px; }





/* Sidebar cards */
.sidebar-card{ padding:14px 16px; }
.sidebar-title{ margin:4px 0 10px; font-size:16px; font-weight:800; }

/* Progress group */
.progress-group{ display:grid; gap:12px; }
.progress-item{ display:grid; gap:6px; }
.progress-row{ display:flex; justify-content:space-between; align-items:center; }
.progress-label{ color:var(--muted); font-size:12px; }
.progress-value{ color:var(--text); font-size:12px; font-weight:700; }

.progress{
  height:10px; border-radius:999px; background: rgba(255,255,255,.07);
  border:1px solid var(--border); overflow:hidden;
}
.progress-bar{
  height:100%; width:0%;
  background: linear-gradient(90deg, var(--accent), #3c6fe0);
  transition: width .25s ease;
}

/* Activity list */
.activity-list{ list-style:none; padding:0; margin:0; display:grid; gap:8px; }
.activity-list li{
  padding:8px 10px; border:1px solid var(--border); border-radius:10px; background: var(--card);
  font-size:13px; color:var(--text);
}
.activity-list li .when{ color:var(--muted); font-size:12px; margin-left:6px; }

/* migrations-list list */
.migrations-list{ list-style:none; padding:0; margin:0; display:grid; gap:8px; }
.migrations-list li{
  padding:8px 10px; border:1px solid var(--border); border-radius:10px; background: var(--card);
  font-size:13px; color:var(--text);
}
.migrations-list li .when{ color:var(--muted); font-size:12px; margin-left:6px; }






/* ===== Proxy card actions (kebab menu) ===== */
.proxy-card{ position:relative; }
.proxy-actions{ position:absolute; top:8px; right:8px; }
.icon-btn{
  border:1px solid var(--border); background:var(--chip-bg); color:var(--text);
  border-radius:10px; padding:4px 8px; cursor:pointer; font-weight:700;
}
.icon-btn:hover{ border-color: var(--accent); }

/* menu (absolute, within modal dialog) */
.menu{
  position:absolute;
  display:none;
  z-index:1002;
  min-width:160px;
  background:var(--panel);
  border:1px solid var(--border);
  border-radius:12px;
  box-shadow: var(--shadow);
  padding:6px;
}
.menu.open{ display:block; }
.menu-item{
  display:block; width:100%; text-align:left;
  background:transparent; border:none; color:var(--text);
  padding:8px 10px; border-radius:8px; cursor:pointer; font-size:14px;
}
.menu-item:hover{ background:rgba(255,255,255,.06); }

/* small modal width */
.modal-dialog.modal-sm{ width:min(420px, 92vw); }

/* toast */
.toast{
  position:fixed; right:18px; top:18px; z-index:1200;padding: 12px 18px;font-weight: 600;opacity: 0;transform: translateY(-20px);transition: opacity 0.3s ease, transform 0.3s ease;
  background:var(--panel); border:1px solid var(--border);
  color:var(--text); border-radius:12px; padding:10px 14px; box-shadow:var(--shadow);
}
.toast.show {
  opacity: 1;
  transform: translateY(0);
  animation: blink 0.5s ease-in-out 2;
}
.toast.ok{ border-color: rgba(102,227,196,.35); }
.toast.err{ border-color: rgba(229,57,53,.35); }
@keyframes blink {
  0%, 100% { box-shadow: 0 0 0px transparent; }
  50% { box-shadow: 0 0 12px 4px rgba(255,255,255,0.8); }
}
#fromPMSName {
  margin-bottom: 10px;
}



.side-scroll-sections {
  max-height: 300px;
  overflow: scroll;
}


.pageWrapper {
  padding: 0px 20px;
}

.keep-breaks {
  white-space: pre-wrap;   /* keeps \n and wraps long lines */
  word-break: break-word;
}
.hidden {
  display: none;
}

/* ===== Offline Timeline Styles ===== */
.page-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 24px;
  padding: 0 8px;
}

.page-header h1 {
  margin: 0;
  color: var(--text-strong);
}

.filters {
  display: flex;
  gap: 12px;
  align-items: center;
}

.time-range {
  font-size: 14px;
  color: var(--muted);
  padding: 8px 12px;
  background: var(--input-bg);
  border: 1px solid var(--border);
  border-radius: 8px;
}

.timeline-container {
  background: var(--panel);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
}

.loading-spinner {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 60px 20px;
  gap: 16px;
}

.spinner {
  width: 32px;
  height: 32px;
  border: 3px solid var(--border);
  border-top: 3px solid var(--accent);
  border-radius: 50%;
  animation: spin 1s linear infinite;
}

@keyframes spin {
  0% { transform: rotate(0deg); }
  100% { transform: rotate(360deg); }
}

.timeline-header {
  padding: 16px 20px;
  border-bottom: 1px solid var(--border);
  background: var(--card);
}

.timeline-labels {
  display: grid;
  grid-template-columns: 200px 1fr 80px;
  gap: 16px;
}

.header-timeline {
  display: grid;
  grid-template-columns: repeat(8, 1fr);
  gap: 0;
  text-align: center;
  font-size: 12px;
  color: var(--muted);
}

.header-label {
  font-size: 14px;
  font-weight: 600;
  color: var(--text-strong);
  text-align: center;
}

.timeline-content {
  max-height: 500px;
  overflow-y: auto;
}

.timeline-row {
  display: grid;
  grid-template-columns: 200px 1fr 80px;
  gap: 16px;
  padding: 12px 20px;
  border-bottom: 1px solid var(--border);
  cursor: pointer;
  transition: background-color 0.2s ease;
}

.timeline-row:hover {
  background: rgba(255, 255, 255, 0.02);
}

.modem-info {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.modem-name {
  font-weight: 600;
  color: var(--text-strong);
  font-size: 14px;
}

.modem-id {
  font-size: 12px;
  color: var(--muted);
}

.pms-name {
  font-size: 12px;
  color: var(--accent-2);
}

.timeline-track {
  position: relative;
  height: 24px;
  background: var(--input-bg);
  border-radius: 12px;
  border: 1px solid var(--border);
  margin: auto 0;
}

.offline-indicator {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  width: 12px;
  height: 12px;
  background: #ff4444;
  border-radius: 50%;
  border: 2px solid var(--panel);
  box-shadow: 0 0 8px rgba(255, 68, 68, 0.4);
  cursor: pointer;
}

.offline-indicator:hover {
  transform: translateY(-50%) scale(1.2);
  box-shadow: 0 0 12px rgba(255, 68, 68, 0.6);
}

.duration {
  display: flex;
  align-items: center;
  font-size: 13px;
  color: var(--muted);
  text-align: right;
}

.stats-panel {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 16px;
  margin: 24px 8px;
}

.stat-card {
  background: var(--panel);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 20px;
  text-align: center;
}

.stat-value {
  font-size: 32px;
  font-weight: 700;
  color: var(--accent);
  margin-bottom: 8px;
}

.stat-label {
  font-size: 14px;
  color: var(--muted);
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.modem-details {
  position: fixed;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  background: var(--panel);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  width: 90%;
  max-width: 500px;
  z-index: 1000;
}

.details-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 20px;
  border-bottom: 1px solid var(--border);
}

.details-header h3 {
  margin: 0;
  color: var(--text-strong);
}

.close-btn {
  background: none;
  border: none;
  color: var(--muted);
  font-size: 24px;
  cursor: pointer;
  padding: 0;
  width: 32px;
  height: 32px;
  border-radius: 8px;
  transition: background-color 0.2s ease;
}

.close-btn:hover {
  background: rgba(255, 255, 255, 0.1);
  color: var(--text-strong);
}

.details-content {
  padding: 20px;
}

.detail-row {
  display: flex;
  justify-content: space-between;
  padding: 8px 0;
  border-bottom: 1px solid var(--border);
}

.detail-row:last-child {
  border-bottom: none;
}

.detail-row .label {
  font-weight: 600;
  color: var(--text);
}

.detail-row .value {
  color: var(--text-strong);
  font-family: monospace;
}

.error {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 16px;
  color: #ff4444;
}

.error .btn {
  background: var(--accent);
  color: white;
  border: none;
  padding: 8px 16px;
  border-radius: 8px;
  cursor: pointer;
}

/* Responsive adjustments */
@media (max-width: 768px) {
  .timeline-row {
    grid-template-columns: 1fr;
    gap: 8px;
  }
  
  .timeline-labels {
    grid-template-columns: 1fr;
  }
  
  .page-header {
    flex-direction: column;
    gap: 16px;
    align-items: stretch;
  }
  
  .filters {
    justify-content: center;
  }
  
  .stats-panel {
    grid-template-columns: repeat(2, 1fr);
  }
}

/* ===== Report Page Styles ===== */
.reports-container {
  padding: 0 8px;
}

.report-section {
  background: var(--panel);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 24px;
  margin-bottom: 24px;
}

.report-section h2 {
  margin: 0 0 20px 0;
  color: var(--text-strong);
  font-size: 18px;
}

.report-buttons {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 16px;
}

.report-buttons .btn {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 16px 20px;
  font-size: 15px;
  justify-content: center;
  transition: all 0.2s ease;
}

.report-buttons .btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 16px rgba(0, 0, 0, 0.3);
}

.btn-icon {
  font-size: 20px;
}

/* Report Modal styles */
.report-modal {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: 2000;
  display: flex;
  align-items: center;
  justify-content: center;
}

.report-modal-overlay {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.7);
  backdrop-filter: blur(4px);
}

.report-modal-dialog {
  position: relative;
  background: var(--panel);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.5);
  width: 90%;
  max-width: 800px;
  max-height: 90vh;
  display: flex;
  flex-direction: column;
  z-index: 2001;
}

.report-modal-dialog.report-modal-lg {
  max-width: 1200px;
}

.report-modal-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 20px 24px;
  border-bottom: 1px solid var(--border);
}

.report-modal-header h3 {
  margin: 0;
  color: var(--text-strong);
  font-size: 20px;
}

.report-close-btn {
  background: none;
  border: none;
  color: var(--muted);
  font-size: 24px;
  cursor: pointer;
  padding: 0;
  width: 32px;
  height: 32px;
  border-radius: 8px;
  transition: background-color 0.2s ease;
}

.report-close-btn:hover {
  background: rgba(255, 255, 255, 0.1);
  color: var(--text-strong);
}

.report-modal-body {
  padding: 24px;
  overflow-y: auto;
  flex: 1;
}

.report-info {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 16px;
  margin-bottom: 24px;
  padding: 16px;
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: 12px;
}

.report-info-item {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.report-info-item .report-info-label {
  font-size: 12px;
  color: var(--muted);
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.report-info-item .report-info-value {
  font-size: 16px;
  color: var(--text-strong);
  font-weight: 600;
}

.report-criteria-info {
  margin-bottom: 24px;
  padding: 16px;
  background: var(--input-bg);
  border: 1px solid var(--border);
  border-radius: 12px;
}

.report-criteria-header {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 12px;
  padding-bottom: 8px;
  border-bottom: 1px solid var(--border);
}

.report-criteria-icon {
  font-size: 18px;
}

.report-criteria-title {
  font-size: 14px;
  font-weight: 600;
  color: var(--text-strong);
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.report-criteria-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.report-criteria-item {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 8px 12px;
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: 8px;
}

.report-criteria-item-icon {
  font-size: 16px;
  flex-shrink: 0;
}

.report-criteria-item-content {
  display: flex;
  flex-direction: column;
  gap: 2px;
  flex: 1;
}

.report-criteria-item-label {
  font-size: 11px;
  color: var(--muted);
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.report-criteria-item-value {
  font-size: 13px;
  color: var(--text);
  font-weight: 500;
}

.report-loading-spinner {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 60px 20px;
  gap: 16px;
}

.report-spinner {
  width: 32px;
  height: 32px;
  border: 3px solid var(--border);
  border-top: 3px solid var(--accent);
  border-radius: 50%;
  animation: spin 1s linear infinite;
}

.report-table-container {
  overflow-x: auto;
  border: 1px solid var(--border);
  border-radius: 12px;
}

.report-results-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 14px;
}

.report-results-table thead {
  background: var(--card);
  position: sticky;
  top: 0;
}

.report-results-table th {
  padding: 12px 16px;
  text-align: left;
  font-weight: 600;
  color: var(--text-strong);
  border-bottom: 2px solid var(--border);
  white-space: nowrap;
}

.report-results-table td {
  padding: 12px 16px;
  border-bottom: 1px solid var(--border);
  color: var(--text);
}

.report-results-table tbody tr:hover {
  background: rgba(255, 255, 255, 0.02);
}

.report-results-table tbody tr:last-child td {
  border-bottom: none;
}

.report-results-table code {
  background: var(--input-bg);
  padding: 2px 6px;
  border-radius: 4px;
  font-size: 13px;
  color: var(--accent-2);
}

.report-results-table .user-email {
  color: var(--accent);
  text-decoration: none;
  transition: color 0.2s ease;
}

.report-results-table .user-email:hover {
  color: var(--accent-2);
  text-decoration: underline;
}

.report-results-table .user-id {
  background: rgba(79, 140, 255, 0.1);
  color: var(--accent);
  border: 1px solid rgba(79, 140, 255, 0.2);
}

.report-results-table .no-data {
  text-align: center !important;
  color: var(--muted) !important;
  padding: 40px 16px !important;
  font-style: italic;
}

.report-error-message {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 16px;
  padding: 40px 20px;
  color: #ff6b6b;
  text-align: center;
}

.report-error-icon {
  font-size: 48px;
}

.subscription-badge {
  display: inline-block;
  padding: 4px 10px;
  background: var(--chip-bg);
  border: 1px solid var(--border);
  border-radius: 6px;
  font-size: 12px;
  font-weight: 500;
}

.status-badge {
  display: inline-block;
  padding: 4px 10px;
  border-radius: 6px;
  font-size: 12px;
  font-weight: 500;
}

.status-success {
  background: rgba(102, 227, 196, 0.15);
  color: var(--accent-2);
  border: 1px solid rgba(102, 227, 196, 0.3);
}

.status-error {
  background: rgba(229, 57, 53, 0.15);
  color: #ff6b6b;
  border: 1px solid rgba(229, 57, 53, 0.3);
}

.status-warning {
  background: rgba(255, 193, 7, 0.15);
  color: #ffc107;
  border: 1px solid rgba(255, 193, 7, 0.3);
}

.status-default {
  background: var(--chip-bg);
  color: var(--muted);
  border: 1px solid var(--border);
}

.recommendation-cell {
  font-size: 13px;
  color: var(--text);
  max-width: 300px;
  line-height: 1.4;
}

.revenue-impact {
  font-weight: 700;
  color: var(--accent-2);
  font-size: 14px;
}

@media (max-width: 768px) {
  .report-modal-dialog {
    width: 95%;
    max-height: 95vh;
  }
  
  .report-buttons {
    grid-template-columns: 1fr;
  }
  
  .report-info {
    grid-template-columns: 1fr;
  }
  
  .report-table-container {
    font-size: 12px;
  }
  
  .report-results-table th,
  .report-results-table td {
    padding: 8px 12px;
  }
}
