/* ─── NEBULA COMMAND CENTER — DASHBOARD CSS ─────────────────────────────────
   Theme: Premium Dark / Ice-Blue  |  Brand: Nebula Ice Baths UAE
   ──────────────────────────────────────────────────────────────────────────── */

@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700;800;900&display=swap');

/* ── Root Variables ─────────────────────────────────────────────────────────── */
:root {
  --bg-base:        #05090f;
  --bg-sidebar:     #070d18;
  --bg-card:        #0b1422;
  --bg-card-alt:    #0d1829;
  --bg-hover:       #111f35;
  --bg-input:       #0d1829;
  --bg-modal:       #080f1d;

  --accent-ice:     #38bdf8;
  --accent-blue:    #4f8ef7;
  --accent-purple:  #818cf8;
  --accent-teal:    #2dd4bf;
  --accent-green:   #10b981;
  --accent-amber:   #f59e0b;
  --accent-orange:  #f97316;
  --accent-red:     #ef4444;

  --grad-ice:       linear-gradient(135deg, #38bdf8 0%, #818cf8 100%);
  --grad-card:      linear-gradient(160deg, #0b1422 0%, #0d1829 100%);
  --grad-sidebar:   linear-gradient(180deg, #070d18 0%, #05090f 100%);

  --text-primary:   #f0f6ff;
  --text-secondary: #7ea8cc;
  --text-muted:     #3d5a78;
  --text-label:     #4a7fa5;

  --border:         rgba(56, 189, 248, 0.07);
  --border-accent:  rgba(56, 189, 248, 0.18);
  --border-card:    rgba(56, 189, 248, 0.1);

  --shadow-card:    0 4px 32px rgba(0, 0, 0, 0.55);
  --shadow-glow:    0 0 24px rgba(56, 189, 248, 0.12);
  --shadow-glow-lg: 0 0 48px rgba(56, 189, 248, 0.18);

  --sidebar-w:      260px;
  --topbar-h:       64px;
  --radius-sm:      6px;
  --radius:         12px;
  --radius-lg:      16px;
  --radius-xl:      20px;
  --transition:     all 0.22s cubic-bezier(0.4, 0, 0.2, 1);
}

/* ── Reset & Base ───────────────────────────────────────────────────────────── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

html { font-size: 14px; scroll-behavior: smooth; }

body {
  font-family: 'Inter', system-ui, -apple-system, sans-serif;
  background: var(--bg-base);
  color: var(--text-primary);
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

/* ── Scrollbar ──────────────────────────────────────────────────────────────── */
::-webkit-scrollbar { width: 5px; height: 5px; }
::-webkit-scrollbar-track { background: transparent; }
::-webkit-scrollbar-thumb { background: rgba(56,189,248,0.2); border-radius: 99px; }
::-webkit-scrollbar-thumb:hover { background: rgba(56,189,248,0.4); }

/* ── Layout Shell ───────────────────────────────────────────────────────────── */
.shell {
  display: flex;
  height: 100vh;
  width: 100vw;
  overflow: hidden;
}

/* ── Sidebar ────────────────────────────────────────────────────────────────── */
.sidebar {
  width: var(--sidebar-w);
  min-width: var(--sidebar-w);
  background: var(--grad-sidebar);
  border-right: 1px solid var(--border);
  display: flex;
  flex-direction: column;
  padding: 0;
  position: relative;
  z-index: 50;
  overflow: hidden;
}

.sidebar::before {
  content: '';
  position: absolute;
  top: -60px;
  left: -60px;
  width: 200px;
  height: 200px;
  background: radial-gradient(circle, rgba(56,189,248,0.06) 0%, transparent 70%);
  pointer-events: none;
}

/* Logo */
.sidebar-logo {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 22px 20px 20px;
  border-bottom: 1px solid var(--border);
  text-decoration: none;
}

.logo-mark {
  width: 38px;
  height: 38px;
  background: var(--grad-ice);
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  box-shadow: 0 0 16px rgba(56,189,248,0.3);
}

.logo-mark svg { width: 20px; height: 20px; color: #fff; }

.logo-text { line-height: 1.2; }
.logo-text span:first-child {
  display: block;
  font-size: 15px;
  font-weight: 800;
  color: var(--text-primary);
  letter-spacing: -0.3px;
}
.logo-text span:last-child {
  display: block;
  font-size: 10px;
  font-weight: 500;
  color: var(--text-secondary);
  text-transform: uppercase;
  letter-spacing: 1.2px;
}

/* Section label */
.sidebar-section-label {
  font-size: 9.5px;
  font-weight: 600;
  letter-spacing: 1.5px;
  text-transform: uppercase;
  color: var(--text-muted);
  padding: 18px 20px 8px;
}

/* Nav */
.sidebar-nav { flex: 1; overflow-y: auto; padding: 8px 12px; }

.nav-item {
  display: flex;
  align-items: center;
  gap: 11px;
  padding: 11px 12px;
  border-radius: var(--radius-sm);
  cursor: pointer;
  transition: var(--transition);
  position: relative;
  margin-bottom: 2px;
  color: var(--text-secondary);
  font-size: 13.5px;
  font-weight: 500;
  user-select: none;
  border: 1px solid transparent;
}

.nav-item:hover {
  background: rgba(56,189,248,0.06);
  color: var(--text-primary);
  border-color: var(--border);
}

.nav-item.active {
  background: rgba(56,189,248,0.1);
  color: var(--accent-ice);
  border-color: rgba(56,189,248,0.2);
  box-shadow: 0 0 16px rgba(56,189,248,0.08);
}

.nav-item.active::before {
  content: '';
  position: absolute;
  left: 0;
  top: 50%;
  transform: translateY(-50%);
  width: 3px;
  height: 60%;
  background: var(--grad-ice);
  border-radius: 0 2px 2px 0;
}

.nav-icon {
  width: 32px;
  height: 32px;
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  background: rgba(56,189,248,0.05);
  transition: var(--transition);
}
.nav-item.active .nav-icon { background: rgba(56,189,248,0.15); }
.nav-item svg { width: 15px; height: 15px; }

.nav-badge {
  margin-left: auto;
  background: rgba(239,68,68,0.2);
  color: #ef4444;
  font-size: 10px;
  font-weight: 700;
  padding: 2px 7px;
  border-radius: 99px;
  border: 1px solid rgba(239,68,68,0.3);
}

/* Sidebar Footer */
.sidebar-footer {
  border-top: 1px solid var(--border);
  padding: 14px 16px;
}

.user-card {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 8px 10px;
  border-radius: var(--radius-sm);
  transition: var(--transition);
  cursor: pointer;
}
.user-card:hover { background: rgba(56,189,248,0.06); }

.user-avatar {
  width: 34px;
  height: 34px;
  border-radius: 50%;
  background: var(--grad-ice);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 12px;
  font-weight: 700;
  color: #fff;
  flex-shrink: 0;
}

.user-info { flex: 1; min-width: 0; }
.user-info strong {
  display: block;
  font-size: 12.5px;
  font-weight: 600;
  color: var(--text-primary);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.user-info span {
  font-size: 11px;
  color: var(--text-secondary);
}

/* ── Main Content ───────────────────────────────────────────────────────────── */
.main {
  flex: 1;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  min-width: 0;
}

/* ── Topbar ─────────────────────────────────────────────────────────────────── */
.topbar {
  height: var(--topbar-h);
  min-height: var(--topbar-h);
  background: rgba(5,9,15,0.9);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--border);
  display: flex;
  align-items: center;
  padding: 0 28px;
  gap: 16px;
  position: sticky;
  top: 0;
  z-index: 40;
}

.topbar-title { flex: 1; }
.topbar-title h1 {
  font-size: 17px;
  font-weight: 700;
  letter-spacing: -0.3px;
  color: var(--text-primary);
}
.topbar-title p {
  font-size: 12px;
  color: var(--text-secondary);
  margin-top: 1px;
}

.topbar-actions { display: flex; align-items: center; gap: 10px; }

.topbar-btn {
  display: flex;
  align-items: center;
  gap: 7px;
  padding: 8px 14px;
  border-radius: var(--radius-sm);
  border: 1px solid var(--border);
  background: var(--bg-card);
  color: var(--text-secondary);
  font-size: 12.5px;
  font-weight: 500;
  cursor: pointer;
  transition: var(--transition);
}
.topbar-btn:hover {
  background: var(--bg-hover);
  color: var(--text-primary);
  border-color: var(--border-accent);
}
.topbar-btn svg { width: 14px; height: 14px; }

.pulse-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--accent-green);
  box-shadow: 0 0 6px var(--accent-green);
  animation: pulse 2s infinite;
}

@keyframes pulse {
  0%, 100% { opacity: 1; transform: scale(1); }
  50%       { opacity: 0.7; transform: scale(0.85); }
}

.refresh-time { font-size: 11px; color: var(--text-muted); }

/* ── View Container ─────────────────────────────────────────────────────────── */
.view-container {
  flex: 1;
  overflow-y: auto;
  padding: 28px;
}

.view { display: none; }
.view.active { display: block; animation: fadeSlide 0.25s ease; }

@keyframes fadeSlide {
  from { opacity: 0; transform: translateY(8px); }
  to   { opacity: 1; transform: translateY(0); }
}

/* ── View Headers ───────────────────────────────────────────────────────────── */
.view-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 22px;
}
.view-header-left h2 {
  font-size: 20px;
  font-weight: 800;
  letter-spacing: -0.4px;
  color: var(--text-primary);
}
.view-header-left p {
  font-size: 12.5px;
  color: var(--text-secondary);
  margin-top: 3px;
}

/* ── Grid Layouts ───────────────────────────────────────────────────────────── */
.grid-2   { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; }
.grid-3   { display: grid; grid-template-columns: 1fr 1fr 1fr; gap: 20px; }
.grid-4   { display: grid; grid-template-columns: repeat(4, 1fr); gap: 20px; }
.grid-ads { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; margin-top: 20px; }
.col-span-2 { grid-column: span 2; }
.col-span-3 { grid-column: span 3; }
.mt-20 { margin-top: 20px; }

/* ── Cards ──────────────────────────────────────────────────────────────────── */
.card {
  background: var(--grad-card);
  border: 1px solid var(--border-card);
  border-radius: var(--radius-lg);
  padding: 22px;
  position: relative;
  overflow: hidden;
  transition: var(--transition);
  box-shadow: var(--shadow-card);
}

.card::before {
  content: '';
  position: absolute;
  inset: 0;
  border-radius: inherit;
  background: radial-gradient(ellipse at top left, rgba(56,189,248,0.04) 0%, transparent 60%);
  pointer-events: none;
}

.card:hover {
  border-color: var(--border-accent);
  box-shadow: var(--shadow-card), var(--shadow-glow);
  transform: translateY(-2px);
}

/* Card Header */
.card-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  margin-bottom: 18px;
}

.card-title-group { flex: 1; }

.card-icon {
  width: 40px;
  height: 40px;
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  margin-bottom: 12px;
}
.card-icon svg { width: 18px; height: 18px; }
.card-icon.ice    { background: rgba(56,189,248,0.12);  color: var(--accent-ice);    }
.card-icon.green  { background: rgba(16,185,129,0.12);  color: var(--accent-green);  }
.card-icon.purple { background: rgba(129,140,248,0.12); color: var(--accent-purple); }
.card-icon.amber  { background: rgba(245,158,11,0.12);  color: var(--accent-amber);  }
.card-icon.red    { background: rgba(239,68,68,0.12);   color: var(--accent-red);    }
.card-icon.teal   { background: rgba(45,212,191,0.12);  color: var(--accent-teal);   }
.card-icon.blue   { background: rgba(79,142,247,0.12);  color: var(--accent-blue);   }

.card-label {
  font-size: 11px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 1.1px;
  color: var(--text-label);
  margin-bottom: 5px;
}

.card-title {
  font-size: 14px;
  font-weight: 600;
  color: var(--text-primary);
}

.card-badge {
  font-size: 10.5px;
  font-weight: 600;
  padding: 4px 10px;
  border-radius: 99px;
  white-space: nowrap;
  flex-shrink: 0;
}
.badge-green  { background: rgba(16,185,129,0.15);  color: var(--accent-green);  border: 1px solid rgba(16,185,129,0.25); }
.badge-red    { background: rgba(239,68,68,0.15);   color: var(--accent-red);    border: 1px solid rgba(239,68,68,0.25); }
.badge-amber  { background: rgba(245,158,11,0.15);  color: var(--accent-amber);  border: 1px solid rgba(245,158,11,0.25); }
.badge-ice    { background: rgba(56,189,248,0.12);  color: var(--accent-ice);    border: 1px solid rgba(56,189,248,0.2); }
.badge-purple { background: rgba(129,140,248,0.12); color: var(--accent-purple); border: 1px solid rgba(129,140,248,0.2); }

/* ── Big Metric ─────────────────────────────────────────────────────────────── */
.metric-hero {
  font-size: 36px;
  font-weight: 800;
  letter-spacing: -1.5px;
  line-height: 1;
  color: var(--text-primary);
  margin-bottom: 4px;
}
.metric-hero .currency {
  font-size: 18px;
  font-weight: 600;
  color: var(--text-secondary);
  margin-right: 3px;
  vertical-align: super;
  font-size: 15px;
}

.metric-sub {
  font-size: 12px;
  color: var(--text-secondary);
  margin-top: 6px;
  display: flex;
  align-items: center;
  gap: 6px;
}

.trend-badge {
  display: inline-flex;
  align-items: center;
  gap: 3px;
  font-size: 11px;
  font-weight: 600;
  padding: 2px 8px;
  border-radius: 99px;
}
.trend-up   { background: rgba(16,185,129,0.15); color: #10b981; }
.trend-down { background: rgba(239,68,68,0.15);  color: #ef4444; }
.trend-badge svg { width: 10px; height: 10px; }

/* ── Divider ────────────────────────────────────────────────────────────────── */
.divider {
  border: none;
  border-top: 1px solid var(--border);
  margin: 16px 0;
}

/* ── Stat Row ───────────────────────────────────────────────────────────────── */
.stat-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 9px 0;
  border-bottom: 1px solid var(--border);
}
.stat-row:last-child { border-bottom: none; }

.stat-row-label {
  font-size: 12.5px;
  color: var(--text-secondary);
  display: flex;
  align-items: center;
  gap: 8px;
}
.stat-row-label .dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  flex-shrink: 0;
}

.stat-row-value {
  font-size: 13px;
  font-weight: 600;
  color: var(--text-primary);
}

.stat-row-sub {
  font-size: 11px;
  color: var(--text-muted);
  text-align: right;
}

/* ── Aging Bar ──────────────────────────────────────────────────────────────── */
.aging-bar-wrap { margin: 16px 0 12px; }
.aging-bar-track {
  height: 8px;
  background: rgba(255,255,255,0.05);
  border-radius: 99px;
  display: flex;
  overflow: hidden;
  gap: 2px;
}
.aging-bar-seg {
  height: 100%;
  border-radius: 99px;
  transition: var(--transition);
}
.aging-bar-seg:hover { filter: brightness(1.3); }

/* ── Chart Canvas ───────────────────────────────────────────────────────────── */
.chart-wrap {
  position: relative;
  height: 180px;
  margin-top: 16px;
}
.chart-wrap-sm { height: 120px; }

/* ── Account List ───────────────────────────────────────────────────────────── */
.account-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 11px 14px;
  background: rgba(56,189,248,0.03);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  margin-bottom: 8px;
  transition: var(--transition);
}
.account-item:hover { background: rgba(56,189,248,0.07); border-color: var(--border-accent); }

.account-name { font-size: 13px; font-weight: 500; color: var(--text-primary); }
.account-type { font-size: 11px; color: var(--text-secondary); }
.account-balance { font-size: 15px; font-weight: 700; color: var(--accent-ice); }

/* ── Stat Mini Grid ─────────────────────────────────────────────────────────── */
.stat-mini-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 10px;
  margin-top: 14px;
}
.stat-mini {
  background: rgba(56,189,248,0.04);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 12px;
  text-align: center;
  transition: var(--transition);
}
.stat-mini:hover { background: rgba(56,189,248,0.08); border-color: var(--border-accent); }
.stat-mini-val { font-size: 20px; font-weight: 800; color: var(--text-primary); }
.stat-mini-label { font-size: 10px; color: var(--text-muted); text-transform: uppercase; letter-spacing: 0.8px; margin-top: 3px; }
.stat-mini-val.green  { color: var(--accent-green); }
.stat-mini-val.amber  { color: var(--accent-amber); }
.stat-mini-val.red    { color: var(--accent-red); }
.stat-mini-val.ice    { color: var(--accent-ice); }

/* ── Build Progress ─────────────────────────────────────────────────────────── */
.build-item {
  padding: 13px 0;
  border-bottom: 1px solid var(--border);
}
.build-item:last-child { border-bottom: none; }

.build-item-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 9px;
}
.build-id { font-size: 10.5px; color: var(--text-muted); font-family: 'JetBrains Mono', monospace; }
.build-name { font-size: 13px; font-weight: 600; color: var(--text-primary); }
.build-eta { font-size: 11px; color: var(--text-secondary); }
.build-assignee { font-size: 11px; color: var(--text-muted); margin-top: 1px; }

.progress-wrap {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-top: 6px;
}

.progress-track {
  flex: 1;
  height: 6px;
  background: rgba(255,255,255,0.05);
  border-radius: 99px;
  overflow: hidden;
}

.progress-fill {
  height: 100%;
  border-radius: 99px;
  background: var(--grad-ice);
  position: relative;
  transition: width 0.6s cubic-bezier(0.4, 0, 0.2, 1);
}

.progress-fill::after {
  content: '';
  position: absolute;
  right: 0;
  top: 50%;
  transform: translateY(-50%);
  width: 10px;
  height: 10px;
  background: var(--accent-ice);
  border-radius: 50%;
  box-shadow: 0 0 6px var(--accent-ice);
}

.progress-pct { font-size: 11.5px; font-weight: 700; color: var(--accent-ice); min-width: 32px; text-align: right; }

.stage-pill {
  font-size: 10px;
  font-weight: 600;
  padding: 3px 9px;
  border-radius: 99px;
  background: rgba(56,189,248,0.1);
  color: var(--accent-ice);
  border: 1px solid rgba(56,189,248,0.2);
  white-space: nowrap;
}

.priority-dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  flex-shrink: 0;
}
.priority-dot.urgent { background: #ef4444; box-shadow: 0 0 5px #ef4444; }
.priority-dot.high   { background: #f97316; }
.priority-dot.normal { background: #10b981; }

/* ── Ship Table ─────────────────────────────────────────────────────────────── */
.ship-count-hero {
  font-size: 56px;
  font-weight: 900;
  letter-spacing: -3px;
  color: var(--text-primary);
  line-height: 1;
  background: var(--grad-ice);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.ship-table { width: 100%; margin-top: 16px; border-collapse: collapse; }
.ship-table th {
  font-size: 10px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.8px;
  color: var(--text-muted);
  text-align: left;
  padding: 0 0 8px;
  border-bottom: 1px solid var(--border);
}
.ship-table td {
  font-size: 12.5px;
  color: var(--text-secondary);
  padding: 10px 0;
  border-bottom: 1px solid var(--border);
  vertical-align: middle;
}
.ship-table tr:last-child td { border-bottom: none; }
.ship-table td strong { color: var(--text-primary); font-weight: 500; }

.manifest-btn {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 10px 18px;
  border-radius: var(--radius-sm);
  background: var(--grad-ice);
  color: #05090f;
  font-size: 12.5px;
  font-weight: 700;
  border: none;
  cursor: pointer;
  transition: var(--transition);
  margin-top: 14px;
  box-shadow: 0 0 20px rgba(56,189,248,0.25);
}
.manifest-btn:hover {
  transform: translateY(-1px);
  box-shadow: 0 0 30px rgba(56,189,248,0.4);
}
.manifest-btn svg { width: 14px; height: 14px; }

/* ── Issues ─────────────────────────────────────────────────────────────────── */
.issue-item {
  padding: 14px;
  background: rgba(56,189,248,0.03);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  margin-bottom: 10px;
  transition: var(--transition);
  position: relative;
}
.issue-item:hover { background: rgba(56,189,248,0.06); border-color: var(--border-accent); }

.issue-item.resolved { opacity: 0.45; }

.issue-top {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 6px;
}

.issue-title {
  font-size: 13.5px;
  font-weight: 600;
  color: var(--text-primary);
}
.issue-meta {
  font-size: 11px;
  color: var(--text-muted);
  margin-top: 2px;
}
.issue-desc {
  font-size: 12px;
  color: var(--text-secondary);
  line-height: 1.55;
  margin-top: 8px;
}

.priority-badge {
  font-size: 10px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  padding: 3px 9px;
  border-radius: 99px;
  white-space: nowrap;
  flex-shrink: 0;
}
.priority-badge.high   { background: rgba(239,68,68,0.15); color: #ef4444; border: 1px solid rgba(239,68,68,0.25); }
.priority-badge.medium { background: rgba(245,158,11,0.15); color: #f59e0b; border: 1px solid rgba(245,158,11,0.25); }
.priority-badge.low    { background: rgba(56,189,248,0.1); color: var(--accent-ice); border: 1px solid rgba(56,189,248,0.2); }

.resolve-btn {
  background: rgba(16,185,129,0.12);
  color: var(--accent-green);
  border: 1px solid rgba(16,185,129,0.25);
  border-radius: var(--radius-sm);
  font-size: 11px;
  font-weight: 600;
  padding: 6px 12px;
  cursor: pointer;
  transition: var(--transition);
  display: flex;
  align-items: center;
  gap: 5px;
  flex-shrink: 0;
}
.resolve-btn:hover { background: rgba(16,185,129,0.22); }
.resolve-btn svg { width: 12px; height: 12px; }

.add-issue-btn {
  display: flex;
  align-items: center;
  gap: 8px;
  width: 100%;
  padding: 11px;
  border-radius: var(--radius-sm);
  border: 1px dashed rgba(56,189,248,0.25);
  background: transparent;
  color: var(--text-secondary);
  font-size: 13px;
  font-weight: 500;
  cursor: pointer;
  transition: var(--transition);
  justify-content: center;
  margin-top: 4px;
}
.add-issue-btn:hover {
  border-color: rgba(56,189,248,0.5);
  color: var(--accent-ice);
  background: rgba(56,189,248,0.04);
}
.add-issue-btn svg { width: 14px; height: 14px; }

/* ── IoT Fleet ──────────────────────────────────────────────────────────────── */
.iot-hero {
  display: flex;
  align-items: center;
  gap: 20px;
  margin-bottom: 18px;
  padding: 16px;
  background: rgba(56,189,248,0.05);
  border: 1px solid rgba(56,189,248,0.12);
  border-radius: var(--radius);
}

.iot-stat { text-align: center; flex: 1; }
.iot-stat-val { font-size: 26px; font-weight: 800; }
.iot-stat-label { font-size: 10px; color: var(--text-muted); text-transform: uppercase; letter-spacing: 0.8px; margin-top: 2px; }
.iot-stat-val.online { color: var(--accent-green); }
.iot-stat-val.offline { color: var(--accent-red); }
.iot-stat-val.maintenance { color: var(--accent-amber); }
.iot-stat-val.total { color: var(--text-primary); }

.iot-divider { width: 1px; height: 40px; background: var(--border); }

.iot-unit-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 9px 12px;
  border-radius: var(--radius-sm);
  border: 1px solid var(--border);
  margin-bottom: 6px;
  transition: var(--transition);
  background: rgba(56,189,248,0.02);
}
.iot-unit-row:hover { background: rgba(56,189,248,0.06); border-color: var(--border-accent); }

.iot-status-dot {
  width: 9px;
  height: 9px;
  border-radius: 50%;
  flex-shrink: 0;
  margin-right: 10px;
}
.iot-status-dot.online { background: var(--accent-green); box-shadow: 0 0 7px var(--accent-green); animation: pulse 2s infinite; }
.iot-status-dot.offline { background: var(--accent-red); }
.iot-status-dot.maintenance { background: var(--accent-amber); }

.iot-unit-name { font-size: 12.5px; font-weight: 500; color: var(--text-primary); }
.iot-unit-loc  { font-size: 11px; color: var(--text-secondary); }
.iot-temp { font-size: 14px; font-weight: 700; color: var(--accent-ice); }
.iot-ping { font-size: 10.5px; color: var(--text-muted); }

.aws-btn {
  display: flex;
  align-items: center;
  gap: 10px;
  width: 100%;
  padding: 13px 18px;
  border-radius: var(--radius);
  background: linear-gradient(135deg, rgba(255,153,0,0.12) 0%, rgba(255,153,0,0.06) 100%);
  border: 1px solid rgba(255,153,0,0.3);
  color: #ff9900;
  font-size: 13px;
  font-weight: 700;
  cursor: pointer;
  transition: var(--transition);
  text-decoration: none;
  margin-top: 14px;
  justify-content: center;
  box-shadow: 0 0 16px rgba(255,153,0,0.08);
}
.aws-btn:hover {
  background: linear-gradient(135deg, rgba(255,153,0,0.2) 0%, rgba(255,153,0,0.1) 100%);
  border-color: rgba(255,153,0,0.5);
  transform: translateY(-1px);
  box-shadow: 0 0 24px rgba(255,153,0,0.2);
}
.aws-btn svg { width: 16px; height: 16px; }
.aws-btn .aws-arrow { margin-left: auto; opacity: 0.6; }

/* ── Technician Calendar ────────────────────────────────────────────────────── */
.calendar-grid {
  display: grid;
  grid-template-columns: 80px repeat(5, 1fr);
  gap: 6px;
  margin-top: 14px;
}

.cal-day-header {
  text-align: center;
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.8px;
  padding: 8px 4px;
  color: var(--accent-ice);
  border-bottom: 1px solid var(--border);
}

.cal-tech-label {
  font-size: 11px;
  font-weight: 500;
  color: var(--text-muted);
  display: flex;
  align-items: center;
  padding: 4px 0;
  border-bottom: 1px solid var(--border);
  white-space: nowrap;
}

.cal-cell {
  min-height: 52px;
  border-radius: var(--radius-sm);
  padding: 4px;
  border-bottom: 1px solid var(--border);
  position: relative;
}

.cal-event {
  border-radius: 5px;
  padding: 5px 7px;
  font-size: 10.5px;
  font-weight: 500;
  line-height: 1.3;
  cursor: pointer;
  transition: var(--transition);
  margin-bottom: 2px;
}
.cal-event:hover { filter: brightness(1.2); transform: scale(1.01); }
.cal-event .ev-time { font-size: 9.5px; opacity: 0.8; display: block; margin-bottom: 1px; }
.cal-event .ev-loc { font-size: 9.5px; opacity: 0.75; display: block; }

.cal-event.repair      { background: rgba(239,68,68,0.18); color: #fc8181; border-left: 3px solid #ef4444; }
.cal-event.service     { background: rgba(56,189,248,0.12); color: var(--accent-ice); border-left: 3px solid var(--accent-ice); }
.cal-event.install     { background: rgba(16,185,129,0.12); color: #34d399; border-left: 3px solid #10b981; }

/* ── Marketing Cards ────────────────────────────────────────────────────────── */
.live-pulse {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: rgba(16,185,129,0.1);
  border: 1px solid rgba(16,185,129,0.25);
  padding: 5px 12px;
  border-radius: 99px;
  font-size: 11.5px;
  font-weight: 600;
  color: var(--accent-green);
  margin-bottom: 14px;
}
.live-pulse .live-dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--accent-green);
  box-shadow: 0 0 6px var(--accent-green);
  animation: pulse 1.5s infinite;
}

.visitor-number {
  font-size: 64px;
  font-weight: 900;
  letter-spacing: -4px;
  line-height: 1;
  color: var(--text-primary);
  background: var(--grad-ice);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.visitor-stats {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
  margin-top: 16px;
}
.visitor-stat {
  background: rgba(56,189,248,0.04);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 10px 12px;
}
.visitor-stat-val { font-size: 17px; font-weight: 700; color: var(--text-primary); }
.visitor-stat-label { font-size: 10.5px; color: var(--text-muted); margin-top: 2px; text-transform: uppercase; letter-spacing: 0.5px; }

/* Ad Performance Card */
.ad-kpi-grid {
  display: grid;
  grid-template-columns: 1fr 1fr 1fr;
  gap: 10px;
  margin: 14px 0;
}
.ad-kpi {
  background: rgba(56,189,248,0.04);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 12px;
  transition: var(--transition);
}
.ad-kpi:hover { background: rgba(56,189,248,0.08); }
.ad-kpi-val { font-size: 19px; font-weight: 800; color: var(--text-primary); }
.ad-kpi-label { font-size: 10px; color: var(--text-muted); text-transform: uppercase; letter-spacing: 0.7px; margin-top: 3px; }
.ad-kpi-val.highlight { color: var(--accent-ice); }
.ad-kpi-val.green { color: var(--accent-green); }
.ad-kpi-val.amber { color: var(--accent-amber); }

.ad-platform-badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 11px;
  font-weight: 700;
  padding: 4px 12px;
  border-radius: 99px;
  margin-bottom: 14px;
}
.badge-google { background: rgba(66,133,244,0.15); color: #4285f4; border: 1px solid rgba(66,133,244,0.3); }
.badge-meta   { background: rgba(24,119,242,0.15); color: #1877f2; border: 1px solid rgba(24,119,242,0.3); }

.ad-campaign-label {
  font-size: 11px;
  color: var(--text-muted);
  margin-top: 10px;
  display: flex;
  align-items: center;
  gap: 6px;
}
.ad-campaign-label strong { color: var(--text-secondary); font-weight: 500; }

/* ── Quick Links ────────────────────────────────────────────────────────────── */
.quicklinks-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 10px;
  margin-top: 4px;
}

.quicklink-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 13px 14px;
  background: rgba(56,189,248,0.03);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  text-decoration: none;
  cursor: pointer;
  transition: var(--transition);
  position: relative;
  overflow: hidden;
}

.quicklink-item::after {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(90deg, transparent, rgba(56,189,248,0.03));
  opacity: 0;
  transition: var(--transition);
}

.quicklink-item:hover {
  background: rgba(56,189,248,0.07);
  border-color: var(--border-accent);
  transform: translateY(-1px);
}
.quicklink-item:hover::after { opacity: 1; }

.quicklink-icon {
  width: 36px;
  height: 36px;
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}
.quicklink-icon.pdf    { background: rgba(239,68,68,0.1); color: #ef4444; }
.quicklink-icon.xlsx   { background: rgba(16,185,129,0.1); color: #10b981; }
.quicklink-icon.docx   { background: rgba(79,142,247,0.1); color: #4f8ef7; }
.quicklink-icon.zip    { background: rgba(245,158,11,0.1); color: #f59e0b; }
.quicklink-icon svg { width: 16px; height: 16px; }

.quicklink-name {
  font-size: 12.5px;
  font-weight: 500;
  color: var(--text-primary);
  line-height: 1.3;
}
.quicklink-meta {
  font-size: 11px;
  color: var(--text-muted);
  margin-top: 2px;
  display: flex;
  align-items: center;
  gap: 6px;
}
.quicklink-type-pill {
  background: rgba(56,189,248,0.1);
  color: var(--accent-ice);
  font-size: 9px;
  font-weight: 700;
  padding: 2px 6px;
  border-radius: 4px;
  letter-spacing: 0.5px;
}

.quicklink-download {
  margin-left: auto;
  color: var(--text-muted);
  flex-shrink: 0;
  transition: var(--transition);
}
.quicklink-item:hover .quicklink-download { color: var(--accent-ice); }
.quicklink-download svg { width: 14px; height: 14px; }

/* Category pill filters */
.category-pills {
  display: flex;
  gap: 7px;
  flex-wrap: wrap;
  margin-bottom: 14px;
}
.cat-pill {
  font-size: 11px;
  font-weight: 500;
  padding: 5px 12px;
  border-radius: 99px;
  border: 1px solid var(--border);
  color: var(--text-secondary);
  cursor: pointer;
  transition: var(--transition);
  background: transparent;
}
.cat-pill:hover, .cat-pill.active {
  background: rgba(56,189,248,0.1);
  color: var(--accent-ice);
  border-color: rgba(56,189,248,0.3);
}

/* ── Modal ──────────────────────────────────────────────────────────────────── */
.modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(5,9,15,0.85);
  backdrop-filter: blur(8px);
  z-index: 100;
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.22s ease;
}
.modal-overlay.open {
  opacity: 1;
  pointer-events: all;
}

.modal-box {
  background: var(--bg-modal);
  border: 1px solid var(--border-accent);
  border-radius: var(--radius-xl);
  width: 100%;
  max-width: 480px;
  padding: 28px;
  box-shadow: 0 24px 64px rgba(0,0,0,0.7), var(--shadow-glow-lg);
  transform: scale(0.95);
  transition: transform 0.22s ease;
}
.modal-overlay.open .modal-box { transform: scale(1); }

.modal-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 22px;
}
.modal-header h3 { font-size: 16px; font-weight: 700; color: var(--text-primary); }
.modal-close {
  width: 32px; height: 32px;
  border-radius: 8px;
  border: 1px solid var(--border);
  background: transparent;
  color: var(--text-secondary);
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: var(--transition);
}
.modal-close:hover { background: rgba(239,68,68,0.1); color: var(--accent-red); border-color: rgba(239,68,68,0.2); }
.modal-close svg { width: 14px; height: 14px; }

.form-group { margin-bottom: 16px; }
.form-label {
  display: block;
  font-size: 11.5px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.8px;
  color: var(--text-label);
  margin-bottom: 7px;
}
.form-input, .form-select, .form-textarea {
  width: 100%;
  padding: 10px 13px;
  background: var(--bg-input);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  color: var(--text-primary);
  font-size: 13px;
  font-family: inherit;
  transition: var(--transition);
  outline: none;
}
.form-input:focus, .form-select:focus, .form-textarea:focus {
  border-color: var(--accent-ice);
  box-shadow: 0 0 0 3px rgba(56,189,248,0.1);
}
.form-select { appearance: none; cursor: pointer; }
.form-textarea { resize: vertical; min-height: 90px; }

.modal-actions {
  display: flex;
  gap: 10px;
  margin-top: 22px;
}
.btn-primary {
  flex: 1;
  padding: 11px;
  border-radius: var(--radius-sm);
  background: var(--grad-ice);
  border: none;
  color: #05090f;
  font-size: 13px;
  font-weight: 700;
  cursor: pointer;
  transition: var(--transition);
}
.btn-primary:hover { box-shadow: 0 0 20px rgba(56,189,248,0.4); transform: translateY(-1px); }

.btn-secondary {
  padding: 11px 18px;
  border-radius: var(--radius-sm);
  background: transparent;
  border: 1px solid var(--border);
  color: var(--text-secondary);
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
  transition: var(--transition);
}
.btn-secondary:hover { border-color: var(--border-accent); color: var(--text-primary); }

/* ── Toast Notification ─────────────────────────────────────────────────────── */
.toast {
  position: fixed;
  bottom: 28px;
  right: 28px;
  background: var(--bg-card);
  border: 1px solid var(--border-accent);
  border-radius: var(--radius);
  padding: 14px 18px;
  font-size: 13px;
  font-weight: 500;
  color: var(--text-primary);
  display: flex;
  align-items: center;
  gap: 10px;
  z-index: 200;
  box-shadow: var(--shadow-card), var(--shadow-glow);
  transform: translateY(80px);
  opacity: 0;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  max-width: 340px;
}
.toast.show { transform: translateY(0); opacity: 1; }
.toast-icon { width: 20px; height: 20px; border-radius: 50%; display: flex; align-items: center; justify-content: center; flex-shrink: 0; }
.toast-icon.success { background: rgba(16,185,129,0.2); color: #10b981; }
.toast-icon svg { width: 12px; height: 12px; }

/* ── Shopify Sessions ───────────────────────────────────────────────────────── */
.shopify-stat-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 14px;
}

/* ── Responsive Utilities ───────────────────────────────────────────────────── */
.text-ice    { color: var(--accent-ice) !important; }
.text-green  { color: var(--accent-green) !important; }
.text-amber  { color: var(--accent-amber) !important; }
.text-red    { color: var(--accent-red) !important; }
.text-muted  { color: var(--text-muted) !important; }
.text-secondary { color: var(--text-secondary) !important; }

.font-mono { font-family: 'JetBrains Mono', 'Fira Code', monospace !important; }

.flex        { display: flex; }
.items-center{ align-items: center; }
.gap-8       { gap: 8px; }
.gap-12      { gap: 12px; }
.w-full      { width: 100%; }
.mt-4        { margin-top: 4px; }
.mt-8        { margin-top: 8px; }
.mt-12       { margin-top: 12px; }
.mt-16       { margin-top: 16px; }

/* ── Scroll Fade Edge ───────────────────────────────────────────────────────── */
.scroll-fade {
  max-height: 340px;
  overflow-y: auto;
}
