/* ============================================
   ServiceBit — Design System (Light Theme)
   ============================================ */

@import url('https://fonts.googleapis.com/css2?family=Syne:wght@400;500;600;700;800&family=DM+Sans:ital,opsz,wght@0,9..40,300;0,9..40,400;0,9..40,500;0,9..40,600;0,9..40,700;1,9..40,400&family=IBM+Plex+Mono:wght@400;500;600&display=swap');

:root {
  /* ── Backgrounds ── */
  --bg: #F4F1EC;
  --surface: #FFFFFF;
  --surface2: #EEEBe5;
  --surface3: #E6E1D9;
  --border: #DDD8D0;
  --border2: #CBC5BC;

  /* ── Primary — Fresh Green ── */
  --primary: #1A9E52;
  --primary-light: #22C55E;
  --primary-hover: #167F42;
  --primary-glow: rgba(26, 158, 82, 0.14);

  /* ── Accent — Warm Amber ── */
  --accent: #C9780E;
  --accent-light: #E08B1A;
  --accent-bg: rgba(201, 120, 14, 0.08);
  --accent-border: rgba(201, 120, 14, 0.2);

  /* ── Info — Slate Teal ── */
  --info: #0A91B0;
  --info-bg: rgba(10, 145, 176, 0.08);
  --info-border: rgba(10, 145, 176, 0.2);

  /* ── Text ── */
  --text: #1B2B1E;
  --text-muted: #5E6E5A;
  --text-dim: #9DAA99;

  /* ── Semantic ── */
  --success: #1A9E52;
  --success-bg: rgba(26, 158, 82, 0.08);
  --success-border: rgba(26, 158, 82, 0.2);
  --warning: #C9780E;
  --warning-bg: rgba(201, 120, 14, 0.08);
  --warning-border: rgba(201, 120, 14, 0.2);
  --danger: #C93030;
  --danger-bg: rgba(201, 48, 48, 0.07);
  --danger-border: rgba(201, 48, 48, 0.18);
  --voice: #6D35D9;
  --voice-bg: rgba(109, 53, 217, 0.08);
  --voice-border: rgba(109, 53, 217, 0.2);
  --orange: #C9780E;
  --orange-bg: rgba(201, 120, 14, 0.08);

  --font: 'DM Sans', -apple-system, BlinkMacSystemFont, sans-serif;
  --font-display: 'Syne', 'DM Sans', sans-serif;
  --mono: 'IBM Plex Mono', 'SF Mono', 'Fira Code', monospace;
  --radius-sm: 6px;
  --radius: 10px;
  --radius-lg: 14px;
  --radius-xl: 20px;
  --radius-full: 9999px;
  --shadow-sm: 0 1px 3px rgba(0,0,0,0.07), 0 1px 2px rgba(0,0,0,0.04);
  --shadow: 0 4px 12px rgba(0,0,0,0.08), 0 1px 4px rgba(0,0,0,0.05);
  --shadow-lg: 0 20px 60px rgba(0,0,0,0.12), 0 8px 20px rgba(0,0,0,0.07);
  --shadow-glow: 0 0 30px rgba(26, 158, 82, 0.12);
  --transition: 0.15s ease;
  --sidebar-width: 240px;
}

/* ── Reset ── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }
body {
  font-family: var(--font);
  background: var(--bg);
  color: var(--text);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  min-height: 100vh;
}
a { color: inherit; text-decoration: none; }
button { cursor: pointer; font-family: var(--font); border: none; outline: none; }
input, textarea, select { font-family: var(--font); outline: none; }
img { max-width: 100%; display: block; }
ul { list-style: none; }

/* ── Typography ── */
h1, h2, h3, h4, h5 { font-family: var(--font-display); font-weight: 700; line-height: 1.2; color: var(--text); }
h1 { font-size: clamp(2rem, 5vw, 3.5rem); font-weight: 800; letter-spacing: -0.03em; }
h2 { font-size: clamp(1.5rem, 3vw, 2.25rem); font-weight: 700; letter-spacing: -0.02em; }
h3 { font-size: 1.2rem; font-weight: 600; }
h4 { font-size: 1rem; font-weight: 600; }
p { color: var(--text-muted); line-height: 1.7; }

/* ── Buttons ── */
.btn {
  display: inline-flex; align-items: center; gap: 8px;
  padding: 10px 20px; border-radius: var(--radius);
  font-size: 14px; font-weight: 600;
  transition: all var(--transition); white-space: nowrap; cursor: pointer;
  border: 1px solid transparent;
  font-family: var(--font);
}
.btn-primary { background: var(--primary); color: white; border-color: var(--primary); }
.btn-primary:hover { background: var(--primary-hover); border-color: var(--primary-hover); transform: translateY(-1px); box-shadow: 0 4px 14px rgba(26,158,82,0.3); }
.btn-secondary { background: var(--surface); color: var(--text); border-color: var(--border); }
.btn-secondary:hover { background: var(--surface2); border-color: var(--border2); }
.btn-ghost { background: transparent; color: var(--text-muted); border: none; padding: 8px 12px; }
.btn-ghost:hover { color: var(--text); background: var(--surface2); border-radius: var(--radius); }
.btn-danger-soft { background: var(--danger-bg); color: var(--danger); border-color: var(--danger-border); }
.btn-success { background: var(--success); color: white; border-color: var(--success); }
.btn-success:hover { background: var(--primary-hover); }
.btn-voice { background: var(--voice-bg); color: var(--voice); border-color: var(--voice-border); }
.btn-voice:hover { background: rgba(109,53,217,0.14); }
.btn-lg { padding: 14px 28px; font-size: 15px; }
.btn-sm { padding: 6px 14px; font-size: 12px; }
.btn-xs { padding: 4px 10px; font-size: 11px; }
.btn-icon { padding: 8px; border-radius: var(--radius); background: var(--surface); border: 1px solid var(--border); color: var(--text-muted); display: inline-flex; align-items: center; justify-content: center; }
.btn-icon:hover { color: var(--text); background: var(--surface2); border-color: var(--border2); }
.btn-full { width: 100%; justify-content: center; }

/* ── Forms ── */
.form-group { display: flex; flex-direction: column; gap: 6px; }
.form-label { font-size: 13px; font-weight: 600; color: var(--text-muted); }
.form-label span { color: var(--danger); margin-left: 2px; }
.form-input {
  background: var(--surface); border: 1px solid var(--border);
  border-radius: var(--radius); padding: 10px 14px;
  color: var(--text); font-size: 14px;
  transition: border-color var(--transition), box-shadow var(--transition); width: 100%;
}
.form-input:focus { border-color: var(--primary); box-shadow: 0 0 0 3px var(--primary-glow); }
.form-input::placeholder { color: var(--text-dim); }
.form-input:disabled { opacity: 0.5; cursor: not-allowed; background: var(--surface2); }
.form-textarea { resize: vertical; min-height: 100px; }
.form-select {
  background: var(--surface); border: 1px solid var(--border);
  border-radius: var(--radius); padding: 10px 14px;
  color: var(--text); font-size: 14px; width: 100%; cursor: pointer;
  appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 24 24' fill='none' stroke='%235E6E5A' stroke-width='2'%3E%3Cpath d='M6 9l6 6 6-6'/%3E%3C/svg%3E");
  background-repeat: no-repeat; background-position: right 12px center;
}
.form-select:focus { border-color: var(--primary); outline: none; box-shadow: 0 0 0 3px var(--primary-glow); }
.form-hint { font-size: 11px; color: var(--text-dim); }

/* ── Cards ── */
.card { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius-lg); padding: 20px; box-shadow: var(--shadow-sm); }
.card-sm { padding: 14px 16px; }
.card-lg { padding: 28px 32px; }
.card-hover { transition: border-color var(--transition), transform var(--transition), box-shadow var(--transition); }
.card-hover:hover { border-color: var(--border2); transform: translateY(-1px); box-shadow: var(--shadow); }

/* ── Badges ── */
.badge {
  display: inline-flex; align-items: center; gap: 4px;
  padding: 3px 9px; border-radius: var(--radius-full);
  font-size: 11px; font-weight: 600; letter-spacing: 0.04em; text-transform: uppercase;
}
.badge-green { background: var(--success-bg); color: var(--success); border: 1px solid var(--success-border); }
.badge-amber { background: var(--warning-bg); color: var(--warning); border: 1px solid var(--warning-border); }
.badge-red { background: var(--danger-bg); color: var(--danger); border: 1px solid var(--danger-border); }
.badge-blue { background: var(--info-bg); color: var(--info); border: 1px solid var(--info-border); }
.badge-voice { background: var(--voice-bg); color: var(--voice); border: 1px solid var(--voice-border); }
.badge-neutral { background: var(--surface2); color: var(--text-muted); border: 1px solid var(--border); }
.badge-orange { background: var(--orange-bg); color: var(--orange); border: 1px solid rgba(201,120,14,0.22); }

/* ── Status Dots ── */
.dot { display: inline-block; width: 7px; height: 7px; border-radius: 50%; flex-shrink: 0; }
.dot-green { background: var(--success); }
.dot-amber { background: var(--warning); }
.dot-red { background: var(--danger); }
.dot-blue { background: var(--info); }
.dot-pulse { animation: dot-pulse 2s ease infinite; }
@keyframes dot-pulse { 0%, 100% { opacity: 1; } 50% { opacity: 0.35; } }

/* ── Avatar ── */
.avatar { width: 36px; height: 36px; border-radius: 50%; display: flex; align-items: center; justify-content: center; font-size: 13px; font-weight: 700; flex-shrink: 0; }
.avatar-sm { width: 28px; height: 28px; font-size: 11px; }
.avatar-lg { width: 48px; height: 48px; font-size: 16px; }
.avatar-blue { background: var(--info-bg); color: var(--info); border: 1px solid var(--info-border); }
.avatar-green { background: var(--success-bg); color: var(--success); border: 1px solid var(--success-border); }
.avatar-amber { background: var(--warning-bg); color: var(--warning); border: 1px solid var(--warning-border); }
.avatar-purple { background: var(--voice-bg); color: var(--voice); border: 1px solid var(--voice-border); }

/* ── Divider ── */
.divider { height: 1px; background: var(--border); margin: 20px 0; }

/* ── Toggle / Switch ── */
.toggle { position: relative; display: inline-flex; align-items: center; cursor: pointer; }
.toggle input { opacity: 0; width: 0; height: 0; position: absolute; }
.toggle-slider {
  width: 44px; height: 24px; background: var(--surface3); border: 1px solid var(--border);
  border-radius: var(--radius-full); transition: all var(--transition); position: relative;
}
.toggle-slider::after {
  content: ''; position: absolute; top: 3px; left: 3px;
  width: 16px; height: 16px; border-radius: 50%; background: var(--text-dim);
  transition: all var(--transition);
}
.toggle input:checked + .toggle-slider { background: var(--primary); border-color: var(--primary); }
.toggle input:checked + .toggle-slider::after { left: 23px; background: white; }

/* ── Progress Bar ── */
.progress-bar { height: 4px; background: var(--surface3); border-radius: var(--radius-full); overflow: hidden; }
.progress-fill { height: 100%; background: var(--primary); border-radius: var(--radius-full); transition: width 0.4s ease; }

/* ── Tabs ── */
.tabs { display: flex; gap: 4px; background: var(--surface2); padding: 4px; border-radius: var(--radius-lg); border: 1px solid var(--border); }
.tab { padding: 7px 16px; border-radius: var(--radius); font-size: 13px; font-weight: 500; color: var(--text-muted); cursor: pointer; transition: all var(--transition); white-space: nowrap; }
.tab.active { background: var(--surface); color: var(--text); font-weight: 600; box-shadow: var(--shadow-sm); }
.tab:hover:not(.active) { color: var(--text); }

/* ── Notifications badge ── */
.notif-dot { position: absolute; top: -2px; right: -2px; width: 10px; height: 10px; background: var(--danger); border-radius: 50%; border: 2px solid var(--surface); }

/* ── App Layout (Dashboard/Tech) ── */
.app-layout { display: flex; min-height: 100vh; }
.sidebar {
  width: var(--sidebar-width); background: var(--surface); border-right: 1px solid var(--border);
  display: flex; flex-direction: column; position: fixed; left: 0; top: 0; bottom: 0; z-index: 100;
  overflow-y: auto; box-shadow: 2px 0 8px rgba(0,0,0,0.04);
}
.sidebar-logo {
  padding: 20px 20px 16px; border-bottom: 1px solid var(--border);
  display: flex; align-items: center; gap: 10px; flex-shrink: 0;
}
.logo-mark {
  width: 32px; height: 32px; background: var(--primary); border-radius: 8px;
  display: flex; align-items: center; justify-content: center;
  font-size: 13px; font-weight: 800; color: white; letter-spacing: -0.5px; flex-shrink: 0;
  font-family: var(--font-display);
}
.logo-text { font-size: 15px; font-weight: 700; color: var(--text); font-family: var(--font-display); }
.logo-text span { color: var(--primary); }
.sidebar-nav { flex: 1; padding: 12px 0; }
.nav-section-label { font-size: 10px; font-weight: 700; letter-spacing: 0.1em; text-transform: uppercase; color: var(--text-dim); padding: 12px 20px 6px; font-family: var(--mono); }
.nav-item {
  display: flex; align-items: center; gap: 10px;
  padding: 9px 16px; margin: 1px 8px; border-radius: var(--radius);
  color: var(--text-muted); font-size: 13px; font-weight: 500; cursor: pointer;
  transition: all var(--transition); position: relative;
}
.nav-item:hover { background: var(--bg); color: var(--text); }
.nav-item.active { background: var(--success-bg); color: var(--primary); font-weight: 600; border: 1px solid var(--success-border); }
.nav-item.active .nav-icon { color: var(--primary); }
.nav-icon { width: 18px; height: 18px; flex-shrink: 0; color: var(--text-dim); }
.nav-badge { margin-left: auto; background: var(--danger); color: white; border-radius: var(--radius-full); font-size: 10px; font-weight: 700; padding: 1px 6px; min-width: 18px; text-align: center; }
.sidebar-footer { padding: 12px 8px; border-top: 1px solid var(--border); flex-shrink: 0; }
.sidebar-user { display: flex; align-items: center; gap: 10px; padding: 8px; border-radius: var(--radius); cursor: pointer; transition: background var(--transition); }
.sidebar-user:hover { background: var(--bg); }
.sidebar-user-info .name { font-size: 13px; font-weight: 600; color: var(--text); }
.sidebar-user-info .role { font-size: 11px; color: var(--text-muted); }
.main-content { margin-left: var(--sidebar-width); flex: 1; display: flex; flex-direction: column; min-height: 100vh; }
.topbar { padding: 14px 28px; border-bottom: 1px solid var(--border); display: flex; align-items: center; justify-content: space-between; background: var(--surface); position: sticky; top: 0; z-index: 50; box-shadow: 0 1px 4px rgba(0,0,0,0.05); }
.page-content { padding: 28px; flex: 1; }

/* ── Stats Cards ── */
.stats-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(180px, 1fr)); gap: 16px; margin-bottom: 24px; }
.stat-card { padding: 18px 20px; }
.stat-label { font-size: 11px; font-weight: 700; letter-spacing: 0.06em; text-transform: uppercase; color: var(--text-dim); margin-bottom: 8px; font-family: var(--mono); }
.stat-value { font-size: 28px; font-weight: 800; color: var(--text); line-height: 1; letter-spacing: -0.03em; font-family: var(--mono); }
.stat-change { font-size: 12px; margin-top: 4px; }

/* ── Table ── */
.table-wrap { overflow-x: auto; }
table { width: 100%; border-collapse: collapse; font-size: 13px; }
thead th { padding: 10px 14px; text-align: left; font-size: 11px; font-weight: 700; letter-spacing: 0.06em; text-transform: uppercase; color: var(--text-dim); border-bottom: 1px solid var(--border); white-space: nowrap; background: var(--surface2); font-family: var(--mono); }
tbody td { padding: 12px 14px; border-bottom: 1px solid var(--border); color: var(--text-muted); vertical-align: middle; }
tbody td:first-child { color: var(--text); font-weight: 500; }
tbody tr:hover td { background: var(--bg); }
tbody tr:last-child td { border-bottom: none; }

/* ── Chat Widget ── */
.chat-widget { position: fixed; bottom: 24px; right: 24px; z-index: 9000; }
.chat-trigger {
  width: 54px; height: 54px; border-radius: 50%; background: var(--primary); color: white;
  display: flex; align-items: center; justify-content: center;
  box-shadow: var(--shadow-lg); cursor: pointer; border: none;
  transition: all var(--transition);
}
.chat-trigger:hover { transform: scale(1.08); background: var(--primary-hover); }
.chat-trigger-pulse { animation: chat-glow 3s ease infinite; }
@keyframes chat-glow { 0%, 100% { box-shadow: var(--shadow-lg), 0 0 0 0 rgba(26,158,82,0.4); } 60% { box-shadow: var(--shadow-lg), 0 0 0 12px rgba(26,158,82,0); } }
.chat-panel {
  position: absolute; bottom: 68px; right: 0; width: 340px;
  background: var(--surface); border: 1px solid var(--border);
  border-radius: var(--radius-xl); box-shadow: var(--shadow-lg);
  display: none; flex-direction: column; overflow: hidden; max-height: 500px;
  animation: slideUp 0.2s ease;
}
.chat-panel.open { display: flex; }
@keyframes slideUp { from { opacity: 0; transform: translateY(12px); } to { opacity: 1; transform: translateY(0); } }
.chat-head {
  padding: 14px 16px; background: linear-gradient(135deg, var(--primary), #167A3E);
  display: flex; align-items: center; gap: 10px; flex-shrink: 0;
}
.chat-head-av { width: 32px; height: 32px; background: rgba(255,255,255,0.2); border-radius: 50%; display: flex; align-items: center; justify-content: center; flex-shrink: 0; }
.chat-head-info h4 { color: white; font-size: 14px; font-weight: 600; }
.chat-head-info p { color: rgba(255,255,255,0.7); font-size: 11px; }
.chat-head-close { margin-left: auto; background: rgba(255,255,255,0.15); border: none; color: white; width: 26px; height: 26px; border-radius: 50%; cursor: pointer; display: flex; align-items: center; justify-content: center; font-size: 14px; transition: background var(--transition); }
.chat-head-close:hover { background: rgba(255,255,255,0.25); }
.chat-messages { flex: 1; overflow-y: auto; padding: 14px 12px; display: flex; flex-direction: column; gap: 10px; background: var(--bg); }
.chat-msg { display: flex; gap: 8px; align-items: flex-start; }
.chat-msg.user { flex-direction: row-reverse; }
.chat-av { width: 26px; height: 26px; border-radius: 50%; display: flex; align-items: center; justify-content: center; font-size: 9px; font-weight: 700; flex-shrink: 0; }
.chat-av-ai { background: var(--success-bg); color: var(--success); border: 1px solid var(--success-border); }
.chat-av-user { background: var(--info-bg); color: var(--info); border: 1px solid var(--info-border); }
.chat-bubble { padding: 8px 12px; border-radius: 12px 12px 12px 2px; font-size: 13px; line-height: 1.5; max-width: 240px; background: var(--surface); border: 1px solid var(--border); color: var(--text); box-shadow: var(--shadow-sm); }
.chat-msg.user .chat-bubble { background: var(--primary); border-color: var(--primary); color: white; border-radius: 12px 12px 2px 12px; }
.chat-time { font-size: 10px; color: var(--text-dim); margin-top: 3px; font-family: var(--mono); }
.chat-typing { display: flex; gap: 4px; align-items: center; padding: 8px 12px; background: var(--surface); border: 1px solid var(--border); border-radius: 12px 12px 12px 2px; }
.chat-typing span { width: 6px; height: 6px; background: var(--text-dim); border-radius: 50%; animation: typing 1.2s ease infinite; }
.chat-typing span:nth-child(2) { animation-delay: 0.2s; }
.chat-typing span:nth-child(3) { animation-delay: 0.4s; }
@keyframes typing { 0%, 60%, 100% { transform: translateY(0); opacity: 0.4; } 30% { transform: translateY(-4px); opacity: 1; } }
.chat-input-bar { padding: 10px 12px; border-top: 1px solid var(--border); display: flex; gap: 8px; flex-shrink: 0; background: var(--surface); }
.chat-text-input { flex: 1; background: var(--bg); border: 1px solid var(--border); border-radius: var(--radius); padding: 8px 12px; color: var(--text); font-size: 13px; resize: none; max-height: 80px; }
.chat-text-input:focus { border-color: var(--primary); outline: none; }
.chat-send-btn { width: 34px; height: 34px; background: var(--primary); color: white; border-radius: var(--radius); display: flex; align-items: center; justify-content: center; cursor: pointer; border: none; flex-shrink: 0; transition: background var(--transition); align-self: flex-end; }
.chat-send-btn:hover { background: var(--primary-hover); }

/* ── Scrollbar ── */
::-webkit-scrollbar { width: 5px; height: 5px; }
::-webkit-scrollbar-track { background: transparent; }
::-webkit-scrollbar-thumb { background: var(--border); border-radius: 3px; }
::-webkit-scrollbar-thumb:hover { background: var(--border2); }

/* ── Utilities ── */
.flex { display: flex; }
.flex-col { flex-direction: column; }
.items-center { align-items: center; }
.items-start { align-items: flex-start; }
.justify-between { justify-content: space-between; }
.justify-center { justify-content: center; }
.gap-1 { gap: 4px; }
.gap-2 { gap: 8px; }
.gap-3 { gap: 12px; }
.gap-4 { gap: 16px; }
.gap-6 { gap: 24px; }
.w-full { width: 100%; }
.text-center { text-align: center; }
.text-right { text-align: right; }
.text-sm { font-size: 13px; }
.text-xs { font-size: 11px; }
.text-lg { font-size: 16px; }
.text-muted { color: var(--text-muted) !important; }
.text-dim { color: var(--text-dim) !important; }
.text-success { color: var(--success) !important; }
.text-warning { color: var(--warning) !important; }
.text-danger { color: var(--danger) !important; }
.text-voice { color: var(--voice) !important; }
.text-primary { color: var(--primary) !important; }
.text-white { color: white !important; }
.text-orange { color: var(--orange) !important; }
.font-mono { font-family: var(--mono); }
.font-display { font-family: var(--font-display); }
.fw-500 { font-weight: 500; }
.fw-600 { font-weight: 600; }
.fw-700 { font-weight: 700; }
.fw-800 { font-weight: 800; }
.truncate { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.mt-auto { margin-top: auto; }
.mb-0 { margin-bottom: 0; }
.hidden { display: none !important; }
.pointer { cursor: pointer; }
.relative { position: relative; }
.grid-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.grid-3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; }
.grid-4 { display: grid; grid-template-columns: repeat(4, 1fr); gap: 16px; }
.mb-4 { margin-bottom: 16px; }
.mb-6 { margin-bottom: 24px; }
.mt-4 { margin-top: 16px; }
.mt-6 { margin-top: 24px; }
.p-0 { padding: 0; }

/* ── Section Header ── */
.section-header { display: flex; align-items: center; justify-content: space-between; margin-bottom: 16px; }
.section-title { font-size: 15px; font-weight: 700; color: var(--text); font-family: var(--font-display); }
.section-sub { font-size: 12px; color: var(--text-dim); margin-top: 2px; }

/* ── Empty State ── */
.empty-state { text-align: center; padding: 48px 24px; }
.empty-state-icon { width: 52px; height: 52px; background: var(--surface2); border-radius: var(--radius-lg); display: flex; align-items: center; justify-content: center; margin: 0 auto 16px; color: var(--text-dim); border: 1px solid var(--border); }
.empty-state h4 { font-size: 15px; color: var(--text); margin-bottom: 8px; }
.empty-state p { font-size: 13px; color: var(--text-muted); max-width: 280px; margin: 0 auto 20px; }

/* ── Alert Banner ── */
.alert-banner { border-radius: var(--radius); padding: 12px 16px; display: flex; align-items: flex-start; gap: 10px; font-size: 13px; }
.alert-banner-info { background: var(--info-bg); border: 1px solid var(--info-border); color: var(--info); }
.alert-banner-success { background: var(--success-bg); border: 1px solid var(--success-border); color: var(--success); }
.alert-banner-warning { background: var(--warning-bg); border: 1px solid var(--warning-border); color: var(--warning); }
.alert-banner-danger { background: var(--danger-bg); border: 1px solid var(--danger-border); color: var(--danger); }

/* ── Market Check Badge ── */
.market-badge { border-radius: var(--radius); padding: 12px 16px; display: flex; align-items: center; gap: 12px; }
.market-badge-green { background: var(--success-bg); border: 1px solid var(--success-border); }
.market-badge-amber { background: var(--warning-bg); border: 1px solid var(--warning-border); }
.market-badge-red { background: var(--danger-bg); border: 1px solid var(--danger-border); }
.market-badge-icon { width: 36px; height: 36px; border-radius: 50%; display: flex; align-items: center; justify-content: center; flex-shrink: 0; font-size: 16px; }
.market-badge-green .market-badge-icon { background: var(--success-bg); color: var(--success); }
.market-badge-amber .market-badge-icon { background: var(--warning-bg); color: var(--warning); }

/* ── Responsive ── */
@media (max-width: 768px) {
  .sidebar { transform: translateX(-100%); transition: transform 0.25s ease; }
  .sidebar.open { transform: translateX(0); }
  .main-content { margin-left: 0; }
  .grid-3, .grid-4 { grid-template-columns: 1fr 1fr; }
  .grid-2 { grid-template-columns: 1fr; }
  .stats-grid { grid-template-columns: repeat(2, 1fr); }
  .topbar { padding: 12px 16px; }
  .page-content { padding: 16px; }
}
@media (max-width: 480px) {
  .grid-3, .grid-4, .grid-2 { grid-template-columns: 1fr; }
  .stats-grid { grid-template-columns: repeat(2, 1fr); }
}

/* ─── Role-based visibility ─────────────────────────── */
body.role-tech .manager-only {
  display: none !important;
}
