/* ============================================================
   CRM Rádio 360 — Stylesheet
   Dark theme, Syne + DM Sans typography
   ============================================================ */

:root {
  --bg-base:      #0d1117;
  --bg-surface:   #161b22;
  --bg-elevated:  #1c2230;
  --bg-card:      #1a2030;
  --border:       rgba(255,255,255,0.08);
  --border-hover: rgba(255,255,255,0.15);

  --text-primary:   #e8edf5;
  --text-secondary: #8b95a8;
  --text-muted:     #5a6478;

  --accent:       #3b82f6;
  --accent-dark:  #2563eb;
  --accent-glow:  rgba(59,130,246,0.25);

  --green:        #22c55e;
  --green-dim:    rgba(34,197,94,0.12);
  --amber:        #f59e0b;
  --amber-dim:    rgba(245,158,11,0.12);
  --red:          #ef4444;
  --red-dim:      rgba(239,68,68,0.12);
  --purple:       #8b5cf6;

  --sidebar-w: 220px;
  --topbar-h:  60px;
  --radius:    10px;
  --radius-sm: 6px;

  --font-display: 'Syne', sans-serif;
  --font-body:    'DM Sans', sans-serif;

  --shadow-sm:  0 1px 3px rgba(0,0,0,0.4);
  --shadow-md:  0 4px 16px rgba(0,0,0,0.5);
  --shadow-lg:  0 8px 32px rgba(0,0,0,0.6);
}

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

html { scroll-behavior: smooth; }

body {
  font-family: var(--font-body);
  background: var(--bg-base);
  color: var(--text-primary);
  font-size: 14px;
  line-height: 1.6;
  min-height: 100vh;
  width: 100%;
  display: flex;
  overflow-x: hidden;
}

a { color: inherit; text-decoration: none; }
button { cursor: pointer; font-family: inherit; }
input, textarea, select { font-family: inherit; }

/* ============================================================
   SIDEBAR
   ============================================================ */
.sidebar {
  width: var(--sidebar-w);
  height: 100vh;
  background: var(--bg-surface);
  border-right: 1px solid var(--border);
  display: flex;
  flex-direction: column;
  position: fixed;
  top: 0; left: 0;
  z-index: 200;
  transition: transform .3s ease;
}

.sidebar-header {
  padding: 18px 16px;
  border-bottom: 1px solid var(--border);
}

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

.brand-icon {
  width: 36px; height: 36px;
  background: var(--accent);
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  flex-shrink: 0;
  box-shadow: 0 0 16px var(--accent-glow);
}

.brand-icon svg { width: 18px; height: 18px; }

.brand-logo-img {
  width: 36px; height: 36px;
  border-radius: 10px;
  object-fit: contain;
  flex-shrink: 0;
}

.brand-name {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 15px;
  color: var(--text-primary);
}

.sidebar-section-label {
  font-size: 10px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 1.2px;
  color: var(--text-muted);
  padding: 16px 16px 6px;
}

.sidebar-nav {
  flex: 1;
  padding: 4px 8px;
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.nav-item {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 9px 10px;
  border-radius: var(--radius-sm);
  color: var(--text-secondary);
  transition: all .18s;
  font-size: 13.5px;
  font-weight: 500;
}

.nav-item svg { width: 16px; height: 16px; flex-shrink: 0; }

.nav-item:hover {
  background: rgba(255,255,255,0.05);
  color: var(--text-primary);
}

.nav-item.active {
  background: rgba(59,130,246,0.15);
  color: var(--accent);
  font-weight: 600;
}

.nav-item.active svg { stroke: var(--accent); }

.sidebar-footer {
  padding: 8px 8px 16px;
  border-top: 1px solid var(--border);
  margin-top: auto;
}

.nav-item.logout:hover {
  background: var(--red-dim);
  color: var(--red);
}

/* ============================================================
   MAIN WRAPPER & TOPBAR
   ============================================================ */
.main-wrapper {
  flex: 1;
  min-width: 0;
  display: flex;
  flex-direction: column;
  min-height: 100vh;
  margin-left: var(--sidebar-w);
  overflow-x: hidden;
}

.topbar {
  height: var(--topbar-h);
  background: var(--bg-surface);
  border-bottom: 1px solid var(--border);
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 0 20px;
  position: sticky;
  top: 0;
  z-index: 100;
}

.menu-toggle {
  display: none;
  background: none;
  border: none;
  color: var(--text-secondary);
  padding: 6px;
  border-radius: var(--radius-sm);
}

.menu-toggle:hover { background: rgba(255,255,255,0.06); color: var(--text-primary); }
.menu-toggle svg { width: 20px; height: 20px; }

.topbar-search {
  flex: 1;
  max-width: 360px;
  display: flex;
  align-items: center;
  gap: 8px;
  background: var(--bg-elevated);
  border: 1px solid var(--border);
  border-radius: 20px;
  padding: 0 14px;
  transition: border-color .2s;
}

.topbar-search:focus-within { border-color: var(--accent); }
.topbar-search svg { width: 15px; height: 15px; color: var(--text-muted); flex-shrink: 0; }

.topbar-search input {
  background: none;
  border: none;
  outline: none;
  color: var(--text-primary);
  font-size: 13px;
  width: 100%;
  padding: 8px 0;
}

.topbar-search input::placeholder { color: var(--text-muted); }

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

.on-air-badge {
  display: flex;
  align-items: center;
  gap: 6px;
  background: var(--red-dim);
  color: var(--red);
  border: 1px solid rgba(239,68,68,0.25);
  border-radius: 20px;
  padding: 4px 12px;
  font-size: 11px;
  font-weight: 700;
  font-family: var(--font-display);
  letter-spacing: .8px;
}

.on-air-dot {
  width: 7px; height: 7px;
  background: var(--red);
  border-radius: 50%;
  animation: pulse 1.5s infinite;
}

@keyframes pulse {
  0%, 100% { opacity: 1; transform: scale(1); }
  50%       { opacity: .5; transform: scale(.8); }
}

.icon-btn {
  width: 36px; height: 36px;
  background: none;
  border: none;
  color: var(--text-secondary);
  border-radius: var(--radius-sm);
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
  transition: all .18s;
}

.icon-btn:hover { background: rgba(255,255,255,0.06); color: var(--text-primary); }
.icon-btn svg { width: 18px; height: 18px; }

.notif-dot {
  width: 7px; height: 7px;
  background: var(--accent);
  border-radius: 50%;
  position: absolute;
  top: 6px; right: 6px;
  border: 2px solid var(--bg-surface);
}

.user-menu {
  display: flex;
  align-items: center;
  gap: 8px;
  cursor: pointer;
  padding: 4px 8px;
  border-radius: var(--radius-sm);
  transition: background .18s;
}

.user-menu:hover { background: rgba(255,255,255,0.05); }

.user-name {
  font-size: 13px;
  font-weight: 500;
  color: var(--text-secondary);
}

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

/* ============================================================
   PAGE CONTENT
   ============================================================ */
.page-content {
  flex: 1;
  width: 100%;
}

.page-inner {
  width: 100%;
  max-width: 1080px;
  margin-left: auto;
  margin-right: auto;
  padding: 36px 48px;
  box-sizing: border-box;
}

.page-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 28px;
  flex-wrap: wrap;
}

.page-title {
  font-family: var(--font-display);
  font-size: 24px;
  font-weight: 700;
  color: var(--text-primary);
  line-height: 1.2;
}

.page-subtitle {
  color: var(--text-secondary);
  font-size: 13px;
  margin-top: 4px;
}

/* ============================================================
   CARDS
   ============================================================ */
.card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
}

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

.card-title {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 15px;
}

.card-body { padding: 20px; }
.card-footer {
  padding: 14px 20px;
  border-top: 1px solid var(--border);
  background: rgba(255,255,255,0.02);
}

/* Stat cards */
.stat-cards {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
  gap: 16px;
  margin-bottom: 24px;
}

.stat-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 18px 20px;
  position: relative;
  overflow: hidden;
  transition: border-color .2s, transform .2s;
}

.stat-card:hover { border-color: var(--border-hover); transform: translateY(-2px); }

.stat-card::before {
  content: '';
  position: absolute;
  top: 0; left: 0; right: 0;
  height: 2px;
}

.stat-card.blue::before  { background: var(--accent); }
.stat-card.green::before { background: var(--green); }
.stat-card.amber::before { background: var(--amber); }
.stat-card.purple::before{ background: var(--purple); }

.stat-icon {
  width: 36px; height: 36px;
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 14px;
}

.stat-icon.blue   { background: rgba(59,130,246,0.15);  color: var(--accent); }
.stat-icon.green  { background: var(--green-dim);       color: var(--green); }
.stat-icon.amber  { background: var(--amber-dim);       color: var(--amber); }
.stat-icon.purple { background: rgba(139,92,246,0.15);  color: var(--purple); }
.stat-icon svg { width: 18px; height: 18px; }

.stat-value {
  font-family: var(--font-display);
  font-size: 26px;
  font-weight: 700;
  line-height: 1;
  margin-bottom: 4px;
}

.stat-label { color: var(--text-secondary); font-size: 12px; }

/* ============================================================
   BUTTONS
   ============================================================ */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  padding: 8px 16px;
  border-radius: var(--radius-sm);
  font-size: 13px;
  font-weight: 500;
  font-family: var(--font-body);
  border: none;
  cursor: pointer;
  transition: all .18s;
  white-space: nowrap;
}

.btn svg { width: 15px; height: 15px; }

.btn-primary {
  background: var(--accent);
  color: #fff;
  box-shadow: 0 0 16px var(--accent-glow);
}

.btn-primary:hover { background: var(--accent-dark); transform: translateY(-1px); }

.btn-secondary {
  background: rgba(255,255,255,0.07);
  color: var(--text-primary);
  border: 1px solid var(--border);
}

.btn-secondary:hover { background: rgba(255,255,255,0.12); border-color: var(--border-hover); }

.btn-outline {
  background: transparent;
  color: var(--text-secondary);
  border: 1px solid var(--border);
}

.btn-outline:hover { background: rgba(255,255,255,0.05); color: var(--text-primary); border-color: var(--border-hover); }

.btn-danger  { background: var(--red-dim); color: var(--red); border: 1px solid rgba(239,68,68,0.25); }
.btn-danger:hover { background: rgba(239,68,68,0.25); }

.btn-sm { padding: 5px 11px; font-size: 12px; }
.btn-lg { padding: 11px 22px; font-size: 15px; }
.btn[disabled] { opacity: .5; cursor: not-allowed; pointer-events: none; }

/* ============================================================
   FORMS
   ============================================================ */
.form-group { margin-bottom: 16px; }

.form-label {
  display: block;
  font-size: 12px;
  font-weight: 600;
  color: var(--text-secondary);
  margin-bottom: 6px;
  text-transform: uppercase;
  letter-spacing: .5px;
}

.form-control {
  width: 100%;
  background: var(--bg-elevated);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  color: var(--text-primary);
  padding: 9px 12px;
  font-size: 13.5px;
  transition: border-color .2s, box-shadow .2s;
  outline: none;
}

.form-control:focus {
  border-color: var(--accent);
  box-shadow: 0 0 0 3px var(--accent-glow);
}

.form-control::placeholder { color: var(--text-muted); }

.form-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 14px;
}

/* ============================================================
   TABLE
   ============================================================ */
.table-wrapper { overflow-x: auto; }

table {
  width: 100%;
  border-collapse: collapse;
}

thead tr {
  background: rgba(255,255,255,0.03);
}

th {
  padding: 10px 16px;
  text-align: left;
  font-size: 11px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: .8px;
  color: var(--text-muted);
  border-bottom: 1px solid var(--border);
  white-space: nowrap;
}

td {
  padding: 13px 16px;
  border-bottom: 1px solid rgba(255,255,255,0.04);
  font-size: 13.5px;
  color: var(--text-secondary);
  vertical-align: middle;
}

tbody tr:hover td { background: rgba(255,255,255,0.025); }
tbody tr:last-child td { border-bottom: none; }

.contact-cell {
  display: flex;
  align-items: center;
  gap: 11px;
}

.avatar {
  width: 36px; height: 36px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 13px;
  font-weight: 700;
  color: #fff;
  flex-shrink: 0;
}

.contact-name { font-weight: 500; color: var(--text-primary); font-size: 13.5px; }
.contact-meta { font-size: 11.5px; color: var(--text-muted); }

.mono { font-family: 'Courier New', monospace; font-size: 12.5px; }

/* ============================================================
   BADGES
   ============================================================ */
.badge {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 3px 9px;
  border-radius: 20px;
  font-size: 11px;
  font-weight: 600;
  border: 1px solid transparent;
}

.badge-green  { background: var(--green-dim);            color: var(--green);  border-color: rgba(34,197,94,0.2); }
.badge-amber  { background: var(--amber-dim);            color: var(--amber);  border-color: rgba(245,158,11,0.2); }
.badge-red    { background: var(--red-dim);              color: var(--red);    border-color: rgba(239,68,68,0.2); }
.badge-blue   { background: rgba(59,130,246,0.12);       color: var(--accent); border-color: rgba(59,130,246,0.2); }
.badge-purple { background: rgba(139,92,246,0.12);       color: var(--purple); border-color: rgba(139,92,246,0.2); }
.badge-muted  { background: rgba(255,255,255,0.06);      color: var(--text-muted); }

/* ============================================================
   TABS
   ============================================================ */
.tabs {
  display: flex;
  gap: 2px;
  background: var(--bg-elevated);
  border-radius: var(--radius-sm);
  padding: 3px;
  width: fit-content;
  margin-bottom: 20px;
}

.tab-btn {
  display: flex;
  align-items: center;
  gap: 7px;
  padding: 7px 14px;
  border-radius: 5px;
  background: none;
  border: none;
  color: var(--text-secondary);
  font-size: 13px;
  font-weight: 500;
  transition: all .18s;
}

.tab-btn:hover { color: var(--text-primary); }
.tab-btn.active { background: var(--bg-card); color: var(--text-primary); box-shadow: var(--shadow-sm); }
.tab-btn svg { width: 14px; height: 14px; }

/* ============================================================
   MODAL / DIALOG
   ============================================================ */
.modal-backdrop {
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,.65);
  backdrop-filter: blur(4px);
  z-index: 500;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
  opacity: 0;
  pointer-events: none;
  transition: opacity .2s;
}

.modal-backdrop.open { opacity: 1; pointer-events: all; }

.modal {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  width: 100%;
  max-width: 520px;
  box-shadow: var(--shadow-lg);
  transform: translateY(16px);
  transition: transform .25s;
}

.modal-backdrop.open .modal { transform: translateY(0); }

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

.modal-title { font-family: var(--font-display); font-size: 16px; font-weight: 700; }

.modal-close {
  width: 28px; height: 28px;
  background: none;
  border: none;
  color: var(--text-muted);
  border-radius: 6px;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all .15s;
}

.modal-close:hover { background: rgba(255,255,255,0.07); color: var(--text-primary); }
.modal-close svg { width: 16px; height: 16px; }

.modal-body { padding: 20px 22px; }
.modal-footer {
  padding: 14px 22px;
  border-top: 1px solid var(--border);
  display: flex;
  justify-content: flex-end;
  gap: 10px;
}

/* ============================================================
   TOAST
   ============================================================ */
.toast-container {
  position: fixed;
  bottom: 24px;
  right: 24px;
  display: flex;
  flex-direction: column;
  gap: 8px;
  z-index: 9999;
}

.toast {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 12px 16px;
  background: var(--bg-elevated);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  box-shadow: var(--shadow-md);
  font-size: 13px;
  color: var(--text-primary);
  min-width: 260px;
  max-width: 380px;
  animation: slideIn .25s ease;
}

.toast svg { width: 16px; height: 16px; flex-shrink: 0; }
.toast.success { border-left: 3px solid var(--green); }
.toast.error   { border-left: 3px solid var(--red); }
.toast.info    { border-left: 3px solid var(--accent); }
.toast.success svg { color: var(--green); }
.toast.error   svg { color: var(--red); }
.toast.info    svg { color: var(--accent); }

@keyframes slideIn {
  from { transform: translateX(110%); opacity: 0; }
  to   { transform: translateX(0);    opacity: 1; }
}

/* ============================================================
   SEARCH BAR inline
   ============================================================ */
.search-bar {
  display: flex;
  align-items: center;
  gap: 8px;
  background: var(--bg-elevated);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 0 12px;
  max-width: 320px;
  transition: border-color .2s;
}

.search-bar:focus-within { border-color: var(--accent); }
.search-bar svg { width: 14px; height: 14px; color: var(--text-muted); flex-shrink: 0; }
.search-bar input {
  background: none; border: none; outline: none;
  color: var(--text-primary); font-size: 13px;
  padding: 8px 0; width: 100%;
}
.search-bar input::placeholder { color: var(--text-muted); }

/* ============================================================
   EMPTY STATE
   ============================================================ */
.empty-state {
  text-align: center;
  padding: 48px 20px;
  color: var(--text-muted);
}

.empty-state svg { width: 40px; height: 40px; margin-bottom: 12px; opacity: .4; }
.empty-state h3 { font-size: 15px; color: var(--text-secondary); margin-bottom: 6px; }
.empty-state p  { font-size: 13px; }

/* ============================================================
   SIDEBAR OVERLAY (mobile)
   ============================================================ */
.sidebar-overlay {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,.6);
  z-index: 150;
}

/* ============================================================
   RESPONSIVE
   ============================================================ */
@media (max-width: 768px) {
  .sidebar { transform: translateX(-100%); }
  .sidebar.open { transform: translateX(0); }
  .sidebar-overlay.open { display: block; }
  .main-wrapper { margin-left: 0; }
  .menu-toggle { display: flex; }
  .page-inner { padding: 16px; }
  .form-grid { grid-template-columns: 1fr; }
  .stat-cards { grid-template-columns: 1fr 1fr; }
  .user-name { display: none; }
}

@media (max-width: 480px) {
  .stat-cards { grid-template-columns: 1fr; }
}

/* ============================================================
   LOGIN PAGE
   ============================================================ */
html, body {
  width: 100%;
  height: 100%;
}

.login-page {
  width: 100vw;
  min-height: 100vh;
  background: var(--bg-base);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
  position: relative;
  overflow: hidden;
  /* garante que não haja sidebar empurrando */
  margin: 0;
}

.login-page::before {
  content: '';
  position: absolute;
  width: 600px; height: 600px;
  background: radial-gradient(circle, rgba(59,130,246,0.12) 0%, transparent 70%);
  top: -100px; left: 50%;
  transform: translateX(-50%);
  pointer-events: none;
}

.login-box {
  background: var(--bg-surface);
  border: 1px solid var(--border);
  border-radius: 16px;
  padding: 40px;
  width: 100%;
  max-width: 420px;
  box-shadow: var(--shadow-lg);
  position: relative;
  z-index: 1;
}

.login-brand {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 14px;
  margin-bottom: 32px;
  text-align: center;
}

.login-icon {
  width: 56px; height: 56px;
  background: var(--accent);
  border-radius: 16px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  box-shadow: 0 0 30px var(--accent-glow);
}

.login-icon svg { width: 26px; height: 26px; }

.login-title {
  font-family: var(--font-display);
  font-size: 22px;
  font-weight: 700;
  color: var(--text-primary);
}

.login-subtitle { color: var(--text-secondary); font-size: 13px; margin-top: 4px; }

.login-error {
  background: var(--red-dim);
  border: 1px solid rgba(239,68,68,0.25);
  border-radius: var(--radius-sm);
  color: var(--red);
  padding: 10px 14px;
  font-size: 13px;
  margin-bottom: 16px;
  display: flex;
  align-items: center;
  gap: 8px;
}

/* ============================================================
   CHART AREA
   ============================================================ */
.chart-container {
  padding: 20px;
  height: 300px;
  position: relative;
}

/* ============================================================
   CONFIG SECTION
   ============================================================ */
.config-section {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  margin-bottom: 20px;
  overflow: hidden;
}

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

.config-section-title {
  display: flex;
  align-items: center;
  gap: 8px;
  font-family: var(--font-display);
  font-size: 15px;
  font-weight: 600;
}

.config-section-title svg { width: 18px; height: 18px; color: var(--accent); }
.config-section-body { padding: 20px; }
.config-section-footer {
  padding: 14px 20px;
  border-top: 1px solid var(--border);
  background: rgba(255,255,255,0.02);
  display: flex;
  justify-content: flex-end;
}

/* webhook URL */
.webhook-url-row {
  display: flex;
  gap: 10px;
  align-items: center;
}

.webhook-url-row .form-control { font-family: monospace; font-size: 12px; }

/* connection status */
.conn-status {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 4px 11px;
  border-radius: 20px;
  font-size: 11px;
  font-weight: 600;
}

.conn-status.connected    { background: var(--green-dim);  color: var(--green); border: 1px solid rgba(34,197,94,0.2); }
.conn-status.disconnected { background: var(--red-dim);    color: var(--red);   border: 1px solid rgba(239,68,68,0.2); }
.conn-status.checking     { background: var(--amber-dim);  color: var(--amber); border: 1px solid rgba(245,158,11,0.2); }

.diag-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 16px 0;
  border-bottom: 1px solid rgba(255,255,255,0.04);
  gap: 16px;
  flex-wrap: wrap;
}

.diag-row:last-child { border-bottom: none; padding-bottom: 0; }
.diag-info p { font-size: 13.5px; font-weight: 500; color: var(--text-primary); }
.diag-info span { font-size: 12px; color: var(--text-muted); }

/* ============================================================
   SOCIAL / REDES
   ============================================================ */
.social-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 16px 18px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 16px;
  cursor: pointer;
  transition: border-color .2s;
}

.social-card:hover { border-color: var(--border-hover); }

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

.social-icon {
  width: 36px; height: 36px;
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.social-icon.whatsapp { background: rgba(37,211,102,0.15); color: #25d366; }
.social-icon.instagram{ background: rgba(228,64,95,0.15);  color: #e4405f; }
.social-icon.facebook { background: rgba(24,119,242,0.15); color: #1877f2; }
.social-icon.youtube  { background: rgba(255,0,0,0.15);    color: #ff0000; }
.social-icon svg { width: 18px; height: 18px; }

.social-name { font-weight: 600; font-size: 14px; color: var(--text-primary); }
.social-desc { font-size: 12px; color: var(--text-muted); }

/* ============================================================
   ACTIONS (dropdown)
   ============================================================ */
.actions-btn {
  width: 28px; height: 28px;
  background: none;
  border: none;
  color: var(--text-muted);
  border-radius: 5px;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all .15s;
}

.actions-btn:hover { background: rgba(255,255,255,0.07); color: var(--text-primary); }
.actions-btn svg { width: 16px; height: 16px; }

/* Loader */
.spinner {
  width: 20px; height: 20px;
  border: 2px solid rgba(255,255,255,0.1);
  border-top-color: var(--accent);
  border-radius: 50%;
  animation: spin .6s linear infinite;
  display: inline-block;
}

@keyframes spin { to { transform: rotate(360deg); } }

/* Utility */
.mt-1 { margin-top: 4px; }
.mt-2 { margin-top: 8px; }
.mt-3 { margin-top: 12px; }
.mt-4 { margin-top: 16px; }
.mb-4 { margin-bottom: 16px; }
.d-flex { display: flex; }
.align-center { align-items: center; }
.gap-2 { gap: 8px; }
.gap-3 { gap: 12px; }
.text-right { text-align: right; }
.text-muted { color: var(--text-muted); font-size: 12px; }
.text-center { text-align: center; }
.w-full { width: 100%; }
.fw-600 { font-weight: 600; }
.font-display { font-family: var(--font-display); }
