/* assets/css/admin.css */
@import url('./style.css');

html, body { height: 100%; }

body { display: flex; }

/* Sidebar */
.sidebar {
  width: 240px;
  min-height: 100vh;
  background: #11131a;
  border-right: 1px solid var(--border);
  padding: 16px 14px;
  position: sticky;
  top: 0;
}
.sidebar .logo {
  font-weight: 800;
  color: var(--brand);
  margin-bottom: 12px;
  letter-spacing: .2px;
}
.sidebar nav { display: flex; flex-direction: column; gap: 6px; }
.sidebar nav a {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  padding: 9px 10px;
  border-radius: 10px;
  color: var(--text);
  background: transparent;
  border: 1px solid transparent;
  text-decoration: none;
}
.sidebar nav a:hover {
  background: #191c25;
  border-color: #252a3a;
}
.sidebar nav a.active {
  background: #191c25;
  border-color: #2c3246;
  box-shadow: inset 0 0 0 1px rgba(79,70,229,.15);
}
.sidebar nav a .count {
  font-size: 12px;
  padding: 2px 8px;
  border-radius: 999px;
  background: #141a24;
  border: 1px solid #2a3042;
  color: var(--muted);
}

/* Main content */
.content {
  flex: 1;
  min-width: 0;
  padding: 24px;
}

.content h1 { margin-bottom: 12px; }

.cards {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
  gap: 12px;
}
.card {
  background: var(--panel-2);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 14px;
  box-shadow: 0 2px 10px var(--shadow);
}
.card-title { color: var(--muted); margin-bottom: 6px; font-weight: 600; }
.card-value { font-size: 22px; font-weight: 800; }

/* Tables and blocks */
.table {
  margin-top: 16px;
  background: var(--panel-2);
  border: 1px solid var(--border);
  border-radius: 12px;
  overflow: hidden;
}
.table-title {
  color: var(--muted);
  margin-bottom: 8px;
  padding: 12px 14px;
  border-bottom: 1px solid var(--border);
  background: #141722;
}

.table pre {
  margin: 0;
  padding: 12px 14px;
  white-space: pre-wrap;
  color: var(--text);
}

.status-dot {
  width: 8px; height: 8px; border-radius: 50%;
  background: var(--success);
  box-shadow: 0 0 0 3px rgba(24,210,124,.15);
  display: inline-block;
}

.kpi {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
}
.kpi .item {
  background: #131623;
  border: 1px solid #242a3d;
  border-radius: 10px;
  padding: 10px 12px;
}
.kpi .item .label { color: var(--muted); font-size: 12px; margin-bottom: 4px; }
.kpi .item .val { font-size: 18px; font-weight: 700; }

/* Forms spacing inside admin */
.content form textarea {
  width: 100%;
  min-height: 160px;
  resize: vertical;
}

/* Admin utilities */
.toolbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 10px;
}

.badge {
  display: inline-block;
  padding: 2px 8px;
  border-radius: 999px;
  border: 1px solid #2f3550;
  background: #15192a;
  color: var(--text);
  font-size: 12px;
}

/* Responsive */
@media (max-width: 980px) {
  .sidebar { width: 200px; }
}
@media (max-width: 760px) {
  .sidebar { display: none; }
  .content { padding: 16px; }
  .cards { grid-template-columns: repeat(auto-fill, minmax(180px, 1fr)); }
}
