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

:root {
  --bg:        #080b0f;
  --bg2:       #0d1117;
  --card:      #111827;
  --card2:     #1a2236;
  --border:    #1e2d40;
  --border2:   #243447;
  --accent:    #00e676;
  --accent2:   #00c853;
  --accent3:   rgba(0,230,118,0.08);
  --text:      #eef2f7;
  --text2:     #6b7f96;
  --text3:     #3d5166;
  --danger:    #f44336;
  --warning:   #ff9800;
  --info:      #2196f3;
  --radius:    14px;
  --radius-sm: 8px;
  --radius-xs: 5px;
  --shadow:    0 4px 24px rgba(0,0,0,0.4);
  --shadow-sm: 0 2px 8px rgba(0,0,0,0.3);
  --glow:      0 0 20px rgba(0,230,118,0.15);
}

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

body {
  font-family: 'DM Sans', 'Inter', sans-serif;
  background: var(--bg);
  color: var(--text);
  min-height: 100vh;
  -webkit-font-smoothing: antialiased;
}

h1,h2,h3,h4 { font-family:'Bebas Neue',sans-serif; letter-spacing:1.5px; }

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

/* SIDEBAR */
.sidebar {
  background: linear-gradient(180deg, #0d1117 0%, #080b0f 100%);
  border-right: 1px solid var(--border);
  padding: 0;
  position: fixed;
  width: 240px;
  height: 100vh;
  display: flex;
  flex-direction: column;
  z-index: 100;
  overflow-y: auto;
}

.sidebar-logo {
  padding: 20px 20px 16px;
  border-bottom: 1px solid var(--border);
  margin-bottom: 8px;
}

.sidebar-logo h1 {
  font-size: 26px;
  color: var(--accent);
  line-height: 1;
  letter-spacing: 2px;
}

.sidebar-logo span {
  font-size: 10px;
  color: var(--text2);
  font-family: 'DM Sans', sans-serif;
  text-transform: uppercase;
  letter-spacing: 2px;
  display: block;
  margin-top: 2px;
}

.sidebar-team {
  margin: 0 12px 8px;
  padding: 10px 12px;
  background: var(--accent3);
  border: 1px solid rgba(0,230,118,0.15);
  border-radius: var(--radius-sm);
  display: flex;
  align-items: center;
  gap: 8px;
}

.sidebar-team-dot {
  width: 8px;
  height: 8px;
  background: var(--accent);
  border-radius: 50%;
  flex-shrink: 0;
  box-shadow: 0 0 6px var(--accent);
}

.sidebar-team-name {
  font-size: 12px;
  font-weight: 600;
  color: var(--accent);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.nav-section {
  padding: 12px 16px 4px;
  font-size: 9px;
  color: var(--text3);
  text-transform: uppercase;
  letter-spacing: 2.5px;
  font-weight: 700;
  font-family: 'Inter', sans-serif;
}

.nav-item {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 9px 16px;
  color: var(--text2);
  text-decoration: none;
  font-size: 13px;
  font-weight: 500;
  transition: all 0.15s;
  border-left: 2px solid transparent;
  cursor: pointer;
  margin: 1px 0;
  border-radius: 0 6px 6px 0;
  margin-right: 8px;
}

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

.nav-item.active {
  color: var(--accent);
  border-left-color: var(--accent);
  background: var(--accent3);
}

.nav-item .icon {
  font-size: 15px;
  width: 18px;
  text-align: center;
  flex-shrink: 0;
}

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

.user-info {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 10px;
}

.user-avatar {
  width: 32px;
  height: 32px;
  background: linear-gradient(135deg, var(--accent), var(--accent2));
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--bg);
  font-weight: 700;
  font-size: 13px;
  flex-shrink: 0;
}

.user-name  { font-size: 13px; font-weight: 600; line-height: 1.2; }
.user-email { font-size: 10px; color: var(--text2); }

.btn-logout {
  width: 100%;
  padding: 7px;
  background: transparent;
  border: 1px solid var(--border);
  color: var(--text2);
  border-radius: var(--radius-xs);
  cursor: pointer;
  font-size: 12px;
  font-family: 'DM Sans', sans-serif;
  transition: all 0.15s;
}

.btn-logout:hover { border-color: var(--danger); color: var(--danger); background: rgba(244,67,54,0.05); }

/* MAIN */
.main {
  margin-left: 240px;
  padding: 28px;
  min-height: 100vh;
  overflow-x: hidden;
}

/* PAGE HEADER */
.page-header { margin-bottom: 24px; }

.page-header h2 {
  font-size: 32px;
  color: var(--text);
  line-height: 1;
}

.page-header p {
  color: var(--text2);
  font-size: 13px;
  margin-top: 4px;
}

/* CARDS */
.card {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 20px;
  transition: border-color 0.2s;
}

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

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

.card-title {
  font-family: 'Bebas Neue', sans-serif;
  font-size: 18px;
  letter-spacing: 1px;
  color: var(--text);
}

/* STAT CARDS */
.stats-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 12px;
  margin-bottom: 20px;
}

.stat-card {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 18px 20px;
  position: relative;
  overflow: hidden;
  transition: all 0.2s;
}

.stat-card:hover {
  border-color: rgba(0,230,118,0.3);
  box-shadow: var(--glow);
}

.stat-card::before {
  content: '';
  position: absolute;
  top: 0; left: 0; right: 0;
  height: 2px;
  background: linear-gradient(90deg, var(--accent), transparent);
}

.stat-card::after {
  content: '';
  position: absolute;
  top: 0; right: 0;
  width: 60px; height: 60px;
  background: radial-gradient(circle at top right, rgba(0,230,118,0.06), transparent);
}

.stat-label {
  font-size: 10px;
  color: var(--text2);
  text-transform: uppercase;
  letter-spacing: 1.5px;
  font-weight: 600;
  margin-bottom: 8px;
  font-family: 'Inter', sans-serif;
}

.stat-value {
  font-family: 'Bebas Neue', sans-serif;
  font-size: 34px;
  color: var(--text);
  line-height: 1;
}

.stat-sub {
  font-size: 11px;
  color: var(--text2);
  margin-top: 4px;
}

/* BUTTONS */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 9px 18px;
  border-radius: var(--radius-sm);
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
  border: none;
  transition: all 0.15s;
  text-decoration: none;
  font-family: 'DM Sans', sans-serif;
  white-space: nowrap;
}

.btn-primary {
  background: var(--accent);
  color: #000;
  box-shadow: 0 2px 12px rgba(0,230,118,0.25);
}

.btn-primary:hover {
  background: var(--accent2);
  box-shadow: 0 4px 16px rgba(0,230,118,0.35);
  transform: translateY(-1px);
}

.btn-primary:active { transform: translateY(0); }

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

.btn-secondary:hover {
  border-color: var(--border2);
  background: #1e2d40;
  color: var(--text);
}

.btn-danger {
  background: transparent;
  color: var(--danger);
  border: 1px solid rgba(244,67,54,0.3);
}

.btn-danger:hover {
  background: rgba(244,67,54,0.1);
  border-color: var(--danger);
}

.btn-ghost {
  background: transparent;
  color: var(--text2);
  border: 1px solid var(--border);
}

.btn-ghost:hover { color: var(--text); background: rgba(255,255,255,0.04); }

.btn-sm { padding: 5px 12px; font-size: 12px; border-radius: var(--radius-xs); }
.btn-xs { padding: 3px 8px; font-size: 11px; border-radius: 4px; }

/* TABLES */
.table-wrap { overflow-x: auto; }

table { width: 100%; border-collapse: collapse; font-size: 13px; }

thead th {
  text-align: left;
  padding: 8px 12px;
  color: var(--text2);
  font-size: 10px;
  text-transform: uppercase;
  letter-spacing: 1.5px;
  font-weight: 700;
  border-bottom: 1px solid var(--border);
  font-family: 'Inter', sans-serif;
  background: rgba(0,0,0,0.2);
  white-space: nowrap;
}

tbody td {
  padding: 11px 12px;
  border-bottom: 1px solid rgba(30,45,64,0.6);
  color: var(--text);
  vertical-align: middle;
}

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

/* BADGES */
.badge {
  display: inline-flex;
  align-items: center;
  padding: 2px 9px;
  border-radius: 20px;
  font-size: 11px;
  font-weight: 600;
  font-family: 'Inter', sans-serif;
  letter-spacing: 0.3px;
}

.badge-green  { background: rgba(0,230,118,0.12); color: var(--accent); border: 1px solid rgba(0,230,118,0.2); }
.badge-red    { background: rgba(244,67,54,0.12);  color: var(--danger); border: 1px solid rgba(244,67,54,0.2); }
.badge-yellow { background: rgba(255,152,0,0.12);  color: var(--warning); border: 1px solid rgba(255,152,0,0.2); }
.badge-gray   { background: rgba(107,127,150,0.12); color: var(--text2); border: 1px solid rgba(107,127,150,0.2); }
.badge-blue   { background: rgba(33,150,243,0.12); color: var(--info); border: 1px solid rgba(33,150,243,0.2); }

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

.form-group label {
  display: block;
  font-size: 11px;
  font-weight: 600;
  color: var(--text2);
  text-transform: uppercase;
  letter-spacing: 1px;
  margin-bottom: 5px;
  font-family: 'Inter', sans-serif;
}

.form-control {
  width: 100%;
  padding: 9px 12px;
  background: var(--bg2);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  color: var(--text);
  font-size: 13px;
  font-family: 'DM Sans', sans-serif;
  transition: all 0.15s;
  outline: none;
}

.form-control:focus {
  border-color: var(--accent);
  box-shadow: 0 0 0 3px rgba(0,230,118,0.08);
}

.form-control::placeholder { color: var(--text3); }
select.form-control option { background: var(--bg2); }

textarea.form-control { resize: vertical; min-height: 80px; }

/* MODAL */
.modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.75);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 1000;
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
}

.modal {
  background: var(--card);
  border: 1px solid var(--border2);
  border-radius: var(--radius);
  padding: 28px;
  width: 100%;
  max-width: 500px;
  max-height: 90vh;
  overflow-y: auto;
  box-shadow: 0 24px 80px rgba(0,0,0,0.6);
  animation: modalIn 0.2s ease;
}

@keyframes modalIn {
  from { transform: translateY(12px) scale(0.98); opacity: 0; }
  to   { transform: translateY(0) scale(1); opacity: 1; }
}

.modal-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  margin-bottom: 20px;
}

.modal-title { font-size: 22px; line-height: 1; }

.modal-close {
  background: var(--card2);
  border: 1px solid var(--border);
  color: var(--text2);
  width: 28px;
  height: 28px;
  border-radius: 6px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 16px;
  line-height: 1;
  transition: all 0.15s;
  flex-shrink: 0;
}

.modal-close:hover { color: var(--text); border-color: var(--border2); background: #1e2d40; }

/* GRIDS */
.grid-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.grid-3 { display: grid; grid-template-columns: 1fr 1fr 1fr; gap: 12px; }

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

.empty-state .icon { font-size: 36px; margin-bottom: 12px; opacity: 0.6; }
.empty-state h3 { font-size: 18px; margin-bottom: 6px; color: var(--text); font-family: 'Bebas Neue', sans-serif; }
.empty-state p { font-size: 13px; }

/* TOAST */
.toast {
  position: fixed;
  bottom: 20px;
  right: 20px;
  padding: 12px 18px;
  border-radius: var(--radius-sm);
  font-size: 13px;
  font-weight: 500;
  z-index: 9999;
  animation: toastIn 0.25s ease;
  display: flex;
  align-items: center;
  gap: 8px;
  box-shadow: var(--shadow);
  font-family: 'DM Sans', sans-serif;
}

.toast-success {
  background: var(--card2);
  color: var(--accent);
  border: 1px solid rgba(0,230,118,0.2);
}

.toast-error {
  background: var(--card2);
  color: var(--danger);
  border: 1px solid rgba(244,67,54,0.2);
}

@keyframes toastIn {
  from { transform: translateX(20px); opacity: 0; }
  to   { transform: translateX(0);    opacity: 1; }
}

/* DIVIDER */
.divider {
  height: 1px;
  background: var(--border);
  margin: 16px 0;
}

/* UTILS */
.text-accent  { color: var(--accent); }
.text-danger  { color: var(--danger); }
.text-warning { color: var(--warning); }
.text-muted   { color: var(--text2); }
.text-sm      { font-size: 12px; }
.fw-bold      { font-weight: 700; }
.mt-8  { margin-top: 8px; }
.mt-12 { margin-top: 12px; }
.mt-16 { margin-top: 16px; }
.mt-20 { margin-top: 20px; }
.mb-12 { margin-bottom: 12px; }
.mb-16 { margin-bottom: 16px; }
.flex  { display: flex; }
.flex-between { display: flex; align-items: center; justify-content: space-between; }
.flex-center  { display: flex; align-items: center; justify-content: center; }
.gap-6  { gap: 6px; }
.gap-8  { gap: 8px; }
.gap-12 { gap: 12px; }
.gap-16 { gap: 16px; }

/* TAB BUTTONS */
.tab-btn {
  padding: 8px 14px;
  cursor: pointer;
  font-size: 12px;
  font-weight: 600;
  color: var(--text2);
  border-bottom: 2px solid transparent;
  margin-bottom: -1px;
  transition: all 0.15s;
  font-family: 'DM Sans', sans-serif;
  letter-spacing: 0.3px;
}

.tab-btn.active { color: var(--accent); border-bottom-color: var(--accent); }
.tab-btn:hover  { color: var(--text); }

/* INFO BLOCKS */
.info-block {
  background: var(--bg2);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 12px 14px;
}

.info-block-label {
  font-size: 10px;
  color: var(--text2);
  text-transform: uppercase;
  letter-spacing: 1px;
  font-weight: 600;
  margin-bottom: 4px;
  font-family: 'Inter', sans-serif;
}

.info-block-value {
  font-size: 14px;
  font-weight: 600;
  color: var(--text);
}

/* ATTR INPUT */
.attr-input {
  width: 64px;
  padding: 6px 8px;
  background: var(--bg2);
  border: 1px solid var(--border);
  border-radius: var(--radius-xs);
  color: var(--text);
  font-size: 14px;
  font-weight: 700;
  text-align: center;
  font-family: 'DM Sans', sans-serif;
  transition: border-color 0.15s;
}

.attr-input:focus { outline: none; border-color: var(--accent); }
.attr-input::-webkit-inner-spin-button { opacity: 0; }

/* PTAB */
.ptab {
  padding: 8px 14px;
  cursor: pointer;
  font-size: 12px;
  font-weight: 600;
  color: var(--text2);
  border-bottom: 2px solid transparent;
  margin-bottom: -1px;
  transition: all 0.15s;
}

.ptab.active { color: var(--accent); border-bottom-color: var(--accent); }
.ptab:hover  { color: var(--text); }

/* HIGHLIGHT ROW */
.row-highlight { background: rgba(0,230,118,0.03) !important; }