/* ============================================
   AURABOT AUTH DASHBOARD — MAIN STYLESHEET
   ============================================ */

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

:root {
  --bg: #09090b;
  --surface: #18181b;
  --surface-hover: #27272a;
  --border: #3f3f46;
  --text: #fafafa;
  --text-secondary: #a1a1aa;
  --text-muted: #71717a;
  --teal: #14b8a6;
  --blue: #3b82f6;
  --purple: #8b5cf6;
  --orange: #f59e0b;
  --green: #22c55e;
  --red: #ef4444;
}

body {
  font-family: 'Inter', sans-serif;
  background: var(--bg);
  color: var(--text);
  font-size: 14px;
  line-height: 1.5;
}

/* Layout */
.layout {
  display: flex;
  min-height: 100vh;
}

/* Sidebar */
.sidebar {
  width: 240px;
  background: var(--surface);
  border-right: 1px solid var(--border);
  padding: 24px 16px;
  position: fixed;
  height: 100vh;
  flex-shrink: 0;
}

.brand {
  display: flex;
  align-items: center;
  gap: 12px;
  padding-bottom: 24px;
  border-bottom: 1px solid var(--border);
  margin-bottom: 24px;
}

.brand-icon {
  width: 36px;
  height: 36px;
  background: linear-gradient(135deg, var(--teal), var(--blue));
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #000;
}

.menu-item svg { flex-shrink: 0; opacity: 0.7; }
.menu-item:hover svg { opacity: 1; }
.menu-item.active svg { opacity: 1; }

.brand-text { font-size: 17px; font-weight: 700; }
.brand-text span { color: var(--teal); }

.menu { display: flex; flex-direction: column; gap: 4px; }

.menu-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 10px 12px;
  border-radius: 6px;
  color: var(--text-secondary);
  cursor: pointer;
  transition: all 0.15s;
  font-weight: 500;
}

.menu-item:hover { background: var(--surface-hover); color: var(--text); }
.menu-item.active { background: var(--teal); color: #000; }

.menu-badge {
  margin-left: auto;
  background: var(--surface-hover);
  padding: 2px 8px;
  border-radius: 12px;
  font-size: 11px;
  font-weight: 700;
}

.menu-item.active .menu-badge { background: rgba(0,0,0,0.2); }

/* Content */
.content {
  margin-left: 240px;
  flex: 1;
  padding: 32px;
}

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

.page-title { font-size: 28px; font-weight: 700; margin-bottom: 4px; }
.page-subtitle { color: var(--text-secondary); }

/* Buttons */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 10px 18px;
  border-radius: 6px;
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
  border: none;
  transition: all 0.15s;
}

.btn-primary { background: var(--teal); color: #000; }
.btn-primary:hover { opacity: 0.9; }

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

.btn-icon { background: none; border: 1px solid var(--border); border-radius: 6px; padding: 5px 7px; cursor: pointer; color: var(--text-muted); transition: all 0.15s; display: inline-flex; align-items: center; }
.btn-icon:hover { color: var(--text); border-color: var(--text-secondary); }
.btn-danger-icon:hover { color: var(--red); border-color: var(--red); }

/* Stats */
.stats-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 20px;
  margin-bottom: 24px;
}

.stat-box {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 20px;
}

.stat-icon {
  width: 40px;
  height: 40px;
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 18px;
  margin-bottom: 12px;
}

.stat-icon.teal { background: rgba(20,184,166,0.15); color: var(--teal); }
.stat-icon.blue { background: rgba(59,130,246,0.15); color: var(--blue); }
.stat-icon.orange { background: rgba(245,158,11,0.15); color: var(--orange); }
.stat-icon.purple { background: rgba(139,92,246,0.15); color: var(--purple); }
.stat-icon svg { stroke: currentColor; }

.stat-label { font-size: 13px; color: var(--text-secondary); margin-bottom: 4px; }
.stat-value { font-size: 28px; font-weight: 700; }

/* Cards Grid */
.cards-row {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 20px;
  margin-bottom: 20px;
}

.card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 10px;
}

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

.card-title {
  font-weight: 600;
  display: flex;
  align-items: center;
  gap: 8px;
}

.card-dot { width: 8px; height: 8px; border-radius: 50%; }

.card-body { padding: 20px; }

/* Plan Bars */
.plan-row { margin-bottom: 16px; }
.plan-row:last-child { margin-bottom: 0; }

.plan-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 6px;
}

.plan-name { display: flex; align-items: center; gap: 8px; color: var(--text-secondary); }
.plan-dot-small { width: 8px; height: 8px; border-radius: 50%; }
.plan-count { font-weight: 600; font-size: 16px; }

.plan-track {
  height: 6px;
  background: var(--bg);
  border-radius: 3px;
  overflow: hidden;
}

.plan-fill { height: 100%; border-radius: 3px; transition: width 0.4s; }

/* Status List */
.status-row {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px 0;
  border-bottom: 1px solid var(--border);
}

.status-row:last-child { border-bottom: none; padding-bottom: 0; }

.status-icon-box {
  width: 36px;
  height: 36px;
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 16px;
}

.status-info { flex: 1; }
.status-name { font-weight: 500; }
.status-desc { font-size: 12px; color: var(--text-muted); }

.status-tag {
  padding: 4px 10px;
  border-radius: 20px;
  font-size: 11px;
  font-weight: 600;
  text-transform: uppercase;
  background: rgba(34,197,94,0.1);
  color: var(--green);
}

.status-tag.offline { background: rgba(239,68,68,0.1); color: var(--red); }

/* Quick Actions */
.actions-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 12px;
}

.action-card {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 16px;
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: 8px;
  cursor: pointer;
  transition: all 0.15s;
}

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

.action-icon {
  width: 40px;
  height: 40px;
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 18px;
}

.action-title { font-weight: 600; }
.action-desc { font-size: 12px; color: var(--text-muted); }

/* Form */
.form-group { margin-bottom: 14px; }
.form-label { display: block; font-size: 12px; color: var(--text-secondary); margin-bottom: 5px; font-weight: 500; }
.form-input {
  width: 100%;
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: 6px;
  padding: 10px 12px;
  color: var(--text);
  font-size: 14px;
}
.form-input:focus { outline: none; border-color: var(--teal); }

/* Table */
.table-card { margin-top: 20px; }

.table-wrap { overflow-x: auto; }

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

th {
  text-align: left;
  padding: 14px 16px;
  font-size: 11px;
  font-weight: 600;
  text-transform: uppercase;
  color: var(--text-muted);
  border-bottom: 1px solid var(--border);
}

td { padding: 14px 16px; border-bottom: 1px solid var(--border); }
tr:hover td { background: var(--surface-hover); }
tr:last-child td { border-bottom: none; }

.user-info { display: flex; align-items: center; gap: 10px; }
.user-avatar {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--teal), var(--blue));
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 600;
  font-size: 12px;
  color: #000;
}

.badge {
  padding: 4px 10px;
  border-radius: 20px;
  font-size: 11px;
  font-weight: 600;
  text-transform: uppercase;
}

.badge-scanner { background: rgba(20,184,166,0.1); color: var(--teal); }
.badge-aura { background: rgba(59,130,246,0.1); color: var(--blue); }
.badge-aurabot { background: rgba(139,92,246,0.1); color: var(--purple); }
.badge-premium { background: rgba(245,158,11,0.1); color: var(--orange); }
.badge-free { background: rgba(113,113,122,0.1); color: var(--text-muted); }
.badge-trial { background: rgba(245,158,11,0.1); color: var(--orange); }
.badge-pro { background: rgba(20,184,166,0.1); color: var(--teal); }
.badge-enterprise { background: rgba(59,130,246,0.1); color: var(--blue); }

.status-dot { display: inline-block; width: 6px; height: 6px; border-radius: 50%; margin-right: 6px; }
.status-dot.ok { background: var(--green); box-shadow: 0 0 6px var(--green); }
.status-dot.bad { background: var(--red); box-shadow: 0 0 6px var(--red); }

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

/* Empty */
.empty-state {
  text-align: center;
  padding: 50px 20px;
  color: var(--text-muted);
}
.empty-state .icon { font-size: 40px; margin-bottom: 12px; opacity: 0.4; }

/* Alert */
.alert {
  position: fixed;
  top: 20px;
  right: 20px;
  padding: 14px 20px;
  border-radius: 8px;
  font-weight: 500;
  z-index: 1000;
  animation: slideIn 0.3s;
  transition: opacity 0.5s ease;
}
.alert.ok { background: rgba(34,197,94,0.1); color: var(--green); border: 1px solid var(--green); }
.alert.err { background: rgba(239,68,68,0.1); color: var(--red); border: 1px solid var(--red); }
.alert.fading { opacity: 0; }
@keyframes slideIn { from { transform: translateX(100%); } to { transform: translateX(0); } }

.hidden { display: none !important; }

/* Modal */
.modal {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 1000;
  display: flex;
  align-items: center;
  justify-content: center;
}

.modal-overlay {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(0,0,0,0.7);
}

.modal-content {
  position: relative;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 12px;
  width: 90%;
  max-width: 500px;
  max-height: 90vh;
  overflow-y: auto;
  box-shadow: 0 20px 60px rgba(0,0,0,0.5);
}

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

.modal-header h3 {
  font-size: 18px;
  font-weight: 600;
}

.modal-body {
  padding: 24px;
}

.user-detail-header {
  display: flex;
  align-items: center;
  gap: 16px;
  margin-bottom: 24px;
  padding-bottom: 20px;
  border-bottom: 1px solid var(--border);
}

.user-detail-avatar {
  width: 56px;
  height: 56px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--teal), var(--blue));
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 24px;
  font-weight: 600;
  color: #000;
}

.detail-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
  margin-bottom: 24px;
}

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

.detail-item label {
  font-size: 11px;
  text-transform: uppercase;
  color: var(--text-muted);
  font-weight: 500;
}

.detail-item span {
  font-size: 14px;
}

.text-mono {
  font-family: 'SF Mono', monospace;
  font-size: 12px;
  color: var(--text-secondary);
}

.modal-actions {
  display: flex;
  gap: 12px;
  padding-top: 20px;
  border-top: 1px solid var(--border);
}

/* Auth0 Enhanced Stats */
.stat-sub { font-size: 12px; color: var(--text-muted); margin-top: 4px; }
.stat-sub .highlight { color: var(--teal); }
.stat-sub .down { color: var(--red); }

.stats-grid-3 {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
  margin-bottom: 24px;
}

/* Distribution Bars */
.dist-row {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 14px;
}
.dist-row:last-child { margin-bottom: 0; }
.dist-label { min-width: 100px; font-size: 13px; }
.dist-bar-wrap { flex: 1; height: 24px; background: var(--bg); border-radius: 4px; overflow: hidden; position: relative; }
.dist-bar { height: 100%; border-radius: 4px; transition: width 0.4s; min-width: 2px; }
.dist-count { min-width: 30px; text-align: right; font-weight: 600; font-size: 14px; }
.dist-pct { min-width: 50px; text-align: right; font-size: 12px; color: var(--text-muted); }

/* Top Login Ranking */
.rank-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 10px 0;
  border-bottom: 1px solid var(--border);
}
.rank-item:last-child { border-bottom: none; }
.rank-number {
  width: 24px;
  height: 24px;
  border-radius: 50%;
  background: var(--surface-hover);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 12px;
  font-weight: 700;
  color: var(--text-secondary);
}
.rank-info { flex: 1; }
.rank-name { font-weight: 600; font-size: 13px; }
.rank-email { font-size: 11px; color: var(--text-muted); }
.rank-meta { text-align: right; }
.rank-date { font-size: 11px; color: var(--text-muted); }

/* Filter Bar */
.filter-bar {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 16px 20px;
  border-bottom: 1px solid var(--border);
  flex-wrap: wrap;
}
.filter-input {
  flex: 1;
  min-width: 200px;
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: 6px;
  padding: 8px 12px;
  color: var(--text);
  font-size: 13px;
}
.filter-input:focus { outline: none; border-color: var(--teal); }
.filter-select {
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: 6px;
  padding: 8px 12px;
  color: var(--text);
  font-size: 13px;
  cursor: pointer;
}
.filter-select:focus { outline: none; border-color: var(--teal); }

/* Role/Status Badges */
.badge-role-customer { background: rgba(59,130,246,0.15); color: var(--blue); }
.badge-role-admin { background: rgba(20,184,166,0.15); color: var(--teal); }
.badge-verified { background: rgba(34,197,94,0.15); color: var(--green); }
.badge-not-verified { background: rgba(239,68,68,0.15); color: var(--red); }
.badge-active { background: rgba(34,197,94,0.15); color: var(--green); }
.badge-expired { background: rgba(239,68,68,0.15); color: var(--red); }
.badge-premium { background: rgba(20,184,166,0.15); color: var(--teal); }

/* Plan select dropdown */
.plan-select {
  background: var(--surface);
  color: var(--text);
  border: 1px solid var(--border);
  border-radius: 6px;
  padding: 4px 8px;
  font-size: 12px;
  font-family: 'Inter', sans-serif;
  cursor: pointer;
  outline: none;
  min-width: 100px;
}
.plan-select:hover { border-color: var(--teal); }
.plan-select:focus { border-color: var(--teal); box-shadow: 0 0 0 2px rgba(20,184,166,0.2); }
.plan-select.saving { opacity: 0.5; pointer-events: none; }
.plan-saved {
  display: inline-block;
  color: var(--green);
  font-size: 11px;
  margin-left: 6px;
  opacity: 0;
  transition: opacity 0.3s;
}
.plan-saved.show { opacity: 1; }

/* AuraBot User Accordion Cards */
.ab-user-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 10px;
  margin-bottom: 8px;
  overflow: hidden;
  transition: border-color 0.2s;
}
.ab-user-card:hover { border-color: var(--teal); }
.ab-user-card.expanded { border-color: var(--teal); }
.ab-user-header {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 14px 18px;
  cursor: pointer;
  user-select: none;
}
.ab-user-header:hover { background: var(--surface-hover); }
.ab-avatar {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 15px;
  flex-shrink: 0;
}
.ab-user-name { font-weight: 600; font-size: 14px; }
.ab-user-email { font-size: 12px; color: var(--text-muted); }
.ab-user-meta {
  display: flex;
  gap: 10px;
  align-items: center;
  margin-left: auto;
  flex-shrink: 0;
}
.ab-chevron {
  transition: transform 0.2s;
  color: var(--text-muted);
  flex-shrink: 0;
}
.ab-user-card.expanded .ab-chevron { transform: rotate(180deg); }
.ab-details {
  display: none;
  border-top: 1px solid var(--border);
  padding: 18px;
}
.ab-user-card.expanded .ab-details { display: block; }

/* Tier System */
.tier-overview {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 12px;
  margin-bottom: 20px;
}
.tier-card {
  padding: 16px;
  border-radius: 10px;
  border: 1px solid var(--border);
  background: var(--surface);
  cursor: pointer;
  transition: border-color 0.2s, transform 0.15s;
}
.tier-card:hover { transform: translateY(-2px); }
.tier-card.active { border-width: 2px; }
.tier-card.tier-top { border-color: var(--green); }
.tier-card.tier-top.active { background: rgba(34,197,94,0.05); }
.tier-card.tier-medio { border-color: var(--blue); }
.tier-card.tier-medio.active { background: rgba(59,130,246,0.05); }
.tier-card.tier-baixo { border-color: var(--orange); }
.tier-card.tier-baixo.active { background: rgba(245,158,11,0.05); }
.tier-icon {
  width: 36px;
  height: 36px;
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 18px;
  margin-bottom: 8px;
}
.tier-top .tier-icon { background: rgba(34,197,94,0.15); }
.tier-medio .tier-icon { background: rgba(59,130,246,0.15); }
.tier-baixo .tier-icon { background: rgba(245,158,11,0.15); }
.tier-label {
  font-size: 12px;
  font-weight: 600;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.5px;
}
.tier-top .tier-label { color: var(--green); }
.tier-medio .tier-label { color: var(--blue); }
.tier-baixo .tier-label { color: var(--orange); }
.tier-count {
  font-size: 28px;
  font-weight: 800;
  margin: 2px 0;
}
.tier-top .tier-count { color: var(--green); }
.tier-medio .tier-count { color: var(--blue); }
.tier-baixo .tier-count { color: var(--orange); }
.tier-desc {
  font-size: 11px;
  color: var(--text-muted);
}

.tier-section {
  margin-bottom: 20px;
}
.tier-section-header {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 14px;
  margin-bottom: 8px;
  border-radius: 8px;
  border-left: 3px solid;
}
.tier-section.top .tier-section-header {
  border-left-color: var(--green);
  background: rgba(34,197,94,0.05);
}
.tier-section.medio .tier-section-header {
  border-left-color: var(--blue);
  background: rgba(59,130,246,0.05);
}
.tier-section.baixo .tier-section-header {
  border-left-color: var(--orange);
  background: rgba(245,158,11,0.05);
}
.tier-section-icon {
  font-size: 16px;
}
.tier-section-title {
  font-weight: 700;
  font-size: 13px;
}
.tier-section.top .tier-section-title { color: var(--green); }
.tier-section.medio .tier-section-title { color: var(--blue); }
.tier-section.baixo .tier-section-title { color: var(--orange); }
.tier-section-count {
  font-size: 11px;
  color: var(--text-muted);
  margin-left: auto;
}

.score-badge {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 2px 8px;
  border-radius: 10px;
  font-size: 11px;
  font-weight: 700;
}
.score-badge.top { background: rgba(34,197,94,0.1); color: var(--green); }
.score-badge.medio { background: rgba(59,130,246,0.1); color: var(--blue); }
.score-badge.baixo { background: rgba(245,158,11,0.1); color: var(--orange); }

.ab-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 12px;
}
.ab-metric {
  padding: 12px 14px;
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: 8px;
}
.ab-metric-label {
  font-size: 11px;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.5px;
  margin-bottom: 4px;
}
.ab-metric-value {
  font-size: 18px;
  font-weight: 700;
}
.ab-metric-sub {
  font-size: 11px;
  color: var(--text-muted);
  margin-top: 2px;
}
.ab-section-title {
  font-size: 12px;
  font-weight: 600;
  color: var(--text-secondary);
  text-transform: uppercase;
  letter-spacing: 0.5px;
  margin: 16px 0 8px 0;
  padding-bottom: 6px;
  border-bottom: 1px solid var(--border);
}
.ab-section-title:first-child { margin-top: 0; }
.ab-profit-positive { color: var(--green); }
.ab-profit-negative { color: var(--red); }
.ab-profit-zero { color: var(--text-muted); }
.ab-exchange-tag {
  display: inline-block;
  padding: 2px 8px;
  border-radius: 4px;
  font-size: 11px;
  font-weight: 600;
  margin-right: 4px;
  background: rgba(59,130,246,0.1);
  color: var(--blue);
}

/* ============================================
   AURA USER PROFESSIONAL DETAIL VIEW
   ============================================ */

/* User Detail Header */
.au-user-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  background: linear-gradient(135deg, rgba(20,184,166,0.1), rgba(59,130,246,0.05));
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 20px;
  margin-bottom: 16px;
}

.au-user-avatar-section {
  display: flex;
  align-items: center;
  gap: 16px;
}

.au-user-avatar {
  width: 64px;
  height: 64px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--teal), var(--blue));
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 28px;
  font-weight: 700;
  color: #000;
  position: relative;
  box-shadow: 0 4px 15px rgba(20,184,166,0.3);
}

.au-user-status-dot {
  position: absolute;
  bottom: 3px;
  right: 3px;
  width: 16px;
  height: 16px;
  border-radius: 50%;
  background: var(--green);
  border: 3px solid var(--surface);
  box-shadow: 0 0 8px var(--green);
}

.au-user-status-dot.offline { background: var(--red); box-shadow: 0 0 8px var(--red); }
.au-user-status-dot.away { background: var(--orange); box-shadow: 0 0 8px var(--orange); }

.au-user-info { display: flex; flex-direction: column; gap: 4px; }
.au-user-name { font-size: 20px; font-weight: 700; color: var(--text); }
.au-user-email { font-size: 13px; color: var(--text-secondary); }

.au-user-badges {
  display: flex;
  gap: 8px;
  margin-top: 6px;
}

.au-badge {
  font-size: 10px;
  font-weight: 700;
  padding: 4px 12px;
  border-radius: 20px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.au-badge-plan {
  background: rgba(20,184,166,0.15);
  border: 1px solid rgba(20,184,166,0.4);
  color: var(--teal);
}

.au-badge-plan.premium {
  background: rgba(245,158,11,0.15);
  border-color: rgba(245,158,11,0.4);
  color: var(--orange);
}

.au-badge-status {
  background: rgba(34,197,94,0.15);
  border: 1px solid rgba(34,197,94,0.4);
  color: var(--green);
}

.au-badge-status.inactive {
  background: rgba(239,68,68,0.15);
  border-color: rgba(239,68,68,0.4);
  color: var(--red);
}

.au-user-quick-stats {
  display: flex;
  gap: 24px;
  text-align: right;
}

.au-quick-item { display: flex; flex-direction: column; gap: 2px; }
.au-quick-label { font-size: 11px; color: var(--text-muted); text-transform: uppercase; }
.au-quick-value { font-size: 24px; font-weight: 700; color: var(--text); }

/* Sections */
.au-section {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 20px;
  margin-bottom: 16px;
}

.au-section-header {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 16px;
  padding-bottom: 12px;
  border-bottom: 1px solid var(--border);
}

.au-section-icon {
  width: 32px;
  height: 32px;
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 16px;
}

.au-section-title {
  font-size: 13px;
  font-weight: 700;
  color: var(--text-secondary);
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

/* Grid de metricas */
.au-metrics-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 12px;
}

@media (max-width: 1200px) { .au-metrics-grid { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 768px) { .au-metrics-grid { grid-template-columns: 1fr; } }

.au-metric-card {
  background: rgba(0,0,0,0.2);
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 16px;
  transition: transform 0.2s, box-shadow 0.2s;
}

.au-metric-card:hover {
  transform: translateY(-2px);
  box-shadow: 0 4px 20px rgba(0,0,0,0.3);
  border-color: rgba(20,184,166,0.3);
}

.au-metric-card.highlight {
  background: linear-gradient(135deg, rgba(20,184,166,0.1), rgba(59,130,246,0.05));
  border-color: rgba(20,184,166,0.3);
}

.au-metric-card.success {
  background: linear-gradient(135deg, rgba(34,197,94,0.08), rgba(34,197,94,0.02));
  border-color: rgba(34,197,94,0.25);
}

.au-metric-card.danger {
  background: linear-gradient(135deg, rgba(239,68,68,0.08), rgba(239,68,68,0.02));
  border-color: rgba(239,68,68,0.25);
}

.au-metric-label {
  font-size: 11px;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.5px;
  margin-bottom: 6px;
}

.au-metric-value {
  font-size: 22px;
  font-weight: 700;
  color: var(--text);
  line-height: 1.2;
}

.au-metric-value.success { color: var(--green); }
.au-metric-value.danger { color: var(--red); }
.au-metric-value.warning { color: var(--orange); }

.au-metric-sub {
  font-size: 11px;
  color: var(--text-muted);
  margin-top: 4px;
}

/* Timeline */
.au-timeline {
  margin-top: 16px;
  padding: 16px;
  background: rgba(0,0,0,0.2);
  border-radius: 10px;
}

.au-timeline-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 12px;
  font-size: 13px;
}

.au-timeline-bar {
  height: 10px;
  background: var(--bg);
  border-radius: 5px;
  overflow: hidden;
  position: relative;
}

.au-timeline-progress {
  height: 100%;
  background: linear-gradient(90deg, var(--teal), var(--green));
  border-radius: 5px;
  transition: width 0.5s ease;
}

.au-timeline-progress.warning {
  background: linear-gradient(90deg, var(--orange), var(--red));
}

.au-timeline-labels {
  display: flex;
  justify-content: space-between;
  margin-top: 8px;
  font-size: 11px;
  color: var(--text-muted);
}

/* Graficos */
.au-charts-grid {
  display: grid;
  grid-template-columns: 280px 1fr;
  gap: 20px;
  margin-top: 16px;
}

@media (max-width: 1100px) { .au-charts-grid { grid-template-columns: 1fr; } }

.au-chart-card {
  background: rgba(0,0,0,0.2);
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 16px;
}

.au-chart-header {
  font-size: 12px;
  font-weight: 600;
  color: var(--text-secondary);
  margin-bottom: 12px;
  text-transform: uppercase;
}

.au-chart-container {
  display: flex;
  justify-content: center;
  align-items: center;
  min-height: 140px;
}

.au-chart-legend {
  display: flex;
  justify-content: center;
  gap: 16px;
  margin-top: 12px;
  font-size: 11px;
  flex-wrap: wrap;
}

.au-chart-legend span {
  display: flex;
  align-items: center;
  gap: 6px;
}

.au-legend-dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
}

/* Heatmap */
.au-heatmap {
  margin-top: 16px;
  padding: 14px;
  background: rgba(0,0,0,0.2);
  border-radius: 10px;
}
.au-heatmap-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 8px;
}
.au-heatmap-title {
  font-size: 12px;
  font-weight: 600;
  color: var(--text-secondary);
  text-transform: uppercase;
}
.au-heatmap-legend {
  display: flex;
  gap: 3px;
  align-items: center;
  font-size: 10px;
  color: var(--text-muted);
}
.au-heatmap-legend .au-hm-cell {
  flex-shrink: 0;
}
.au-heatmap-body {
  display: flex;
  gap: 0;
  overflow-x: auto;
}
.au-hm-labels {
  display: flex;
  flex-direction: column;
  gap: 2px;
  padding-top: 18px;
  margin-right: 4px;
  flex-shrink: 0;
}
.au-hm-label {
  height: 11px;
  font-size: 9px;
  color: var(--text-muted);
  display: flex;
  align-items: center;
  line-height: 1;
}
.au-hm-weeks {
  display: flex;
  gap: 2px;
  flex: 1;
  min-width: 0;
}
.au-hm-week {
  display: flex;
  flex-direction: column;
  gap: 2px;
}
.au-hm-month {
  height: 14px;
  font-size: 9px;
  color: var(--text-muted);
  line-height: 14px;
  white-space: nowrap;
}
.au-hm-cell {
  width: 11px;
  height: 11px;
  border-radius: 2px;
  background: rgba(255,255,255,0.04);
  outline: 1px solid rgba(255,255,255,0.03);
}
.au-hm-cell.l1 { background: rgba(20,184,166,0.15); }
.au-hm-cell.l2 { background: rgba(20,184,166,0.35); }
.au-hm-cell.l3 { background: rgba(20,184,166,0.6); }
.au-hm-cell.l4 { background: rgba(34,197,94,0.85); }

/* Security Grid */
.au-security-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 12px;
}

@media (max-width: 1100px) { .au-security-grid { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 600px) { .au-security-grid { grid-template-columns: 1fr; } }

/* Responsive */
@media (max-width: 1100px) {
  .stats-grid, .stats-grid-3 { grid-template-columns: repeat(2, 1fr); }
  .cards-row { grid-template-columns: 1fr; }
}

@media (max-width: 768px) {
  .sidebar { display: none; }
  .content { margin-left: 0; padding: 20px; }
  .stats-grid, .stats-grid-3 { grid-template-columns: 1fr; }
}
