@import url('https://fonts.googleapis.com/css2?family=Manrope:wght@400;600;700&display=swap');

:root {
  --bg: #0f172a;
  --panel: #111827;
  --surface: #1f2937;
  --accent: #22d3ee;
  --accent-2: #8b5cf6;
  --text: #e5e7eb;
  --muted: #9ca3af;
  --border: #1f2937;
  --danger: #f472b6;
  --success: #34d399;
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  font-family: 'Manrope', 'Segoe UI', system-ui, -apple-system, sans-serif;
  background: radial-gradient(circle at 20% 20%, rgba(34, 211, 238, 0.08), transparent 35%), radial-gradient(circle at 80% 0%, rgba(139, 92, 246, 0.08), transparent 30%), var(--bg);
  color: var(--text);
}

a {
  color: var(--accent);
  text-decoration: none;
}

.layout {
  display: grid;
  grid-template-columns: 260px 1fr;
  min-height: 100vh;
}

.sidebar {
  background: var(--panel);
  border-right: 1px solid var(--border);
  padding: 24px;
  display: flex;
  flex-direction: column;
  gap: 18px;
}

.brand {
  font-weight: 700;
  font-size: 18px;
  letter-spacing: 0.6px;
  display: flex;
  align-items: center;
  gap: 8px;
  color: var(--text);
  text-decoration: none;
}

.brand .brand-sim {
  padding: 8px 10px;
  border-radius: 10px;
  background: linear-gradient(135deg, var(--accent), var(--accent-2));
  color: #0b1021;
  font-weight: 800;
}

.brand .brand-tip {
  padding: 8px 10px;
  border-radius: 10px;
  background: var(--surface);
  border: 1px solid var(--border);
}

.nav {
  display: grid;
  gap: 8px;
}

.nav a {
  padding: 12px 14px;
  border-radius: 12px;
  background: transparent;
  color: var(--text);
  border: 1px solid transparent;
  transition: all 0.2s ease;
}

.nav a.active,
.nav a:hover {
  background: var(--surface);
  border-color: var(--border);
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.25);
}

.content {
  padding: 24px 32px;
}

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

.title {
  font-size: 24px;
  font-weight: 700;
}

.search-bar {
  background: var(--panel);
  border: 1px solid var(--border);
  border-radius: 14px;
  padding: 14px;
  display: grid;
  grid-template-columns: 2fr repeat(5, 1fr) 110px;
  gap: 10px;
}

.search-bar input,
.search-bar select,
.search-bar button,
.form-control {
  width: 100%;
  border-radius: 12px;
  border: 1px solid var(--border);
  background: var(--surface);
  color: var(--text);
  padding: 10px 12px;
  font-size: 14px;
}

.search-bar button,
.btn {
  background: linear-gradient(135deg, var(--accent), var(--accent-2));
  border: none;
  color: #0b1021;
  font-weight: 700;
  cursor: pointer;
  padding: 12px 14px;
  border-radius: 12px;
  transition: transform 0.1s ease, box-shadow 0.2s ease;
}

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

.btn.danger {
  background: linear-gradient(135deg, #f97316, var(--danger));
  color: #0b0f1f;
}

.btn:hover {
  transform: translateY(-1px);
  box-shadow: 0 10px 25px rgba(34, 211, 238, 0.25);
}

.cards {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 16px;
  margin: 20px 0;
}

.card {
  background: var(--panel);
  border: 1px solid var(--border);
  border-radius: 16px;
  padding: 14px 16px;
  display: grid;
  gap: 8px;
}

.card .label {
  color: var(--muted);
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 0.4px;
}

.card .value {
  font-size: 26px;
  font-weight: 700;
}

.table-wrap {
  margin-top: 16px;
  background: var(--panel);
  border: 1px solid var(--border);
  border-radius: 16px;
  overflow: hidden;
}

table {
  width: 100%;
  border-collapse: collapse;
  color: var(--text);
}

thead {
  background: #0b1221;
}

th,
td {
  padding: 12px 10px;
  border-bottom: 1px solid var(--border);
  font-size: 14px;
}

tbody tr:hover {
  background: rgba(255, 255, 255, 0.02);
}

.badge {
  display: inline-block;
  padding: 4px 10px;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 700;
  color: #0b1021;
}

.badge.success {
  background: var(--success);
}

.badge.muted {
  background: var(--muted);
  color: #0b0f1f;
}

.badge.warn {
  background: var(--danger);
}

.badge.operator-beeline {
  background: #facc15;
  color: #0b0f1f;
}
.badge.operator-mts {
  background: #ef4444;
  color: #0b0f1f;
}
.badge.operator-megafon {
  background: #22c55e;
  color: #0b0f1f;
}
.badge.operator-t2 {
  background: #f472b6;
  color: #0b0f1f;
}

.table-actions {
  display: flex;
  gap: 8px;
}

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

.form-grid {
  display: grid;
  gap: 12px;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
}

textarea {
  resize: vertical;
  min-height: 90px;
}

.section {
  background: var(--panel);
  border: 1px solid var(--border);
  border-radius: 16px;
  padding: 18px;
  margin-bottom: 18px;
}

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

.space-between {
  justify-content: space-between;
}

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

.color-dot {
  width: 12px;
  height: 12px;
  border-radius: 50%;
  display: inline-block;
  margin-right: 6px;
  border: 1px solid rgba(255, 255, 255, 0.1);
}

.pagination {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 12px 14px;
  background: var(--panel);
  border: 1px solid var(--border);
  border-radius: 14px;
  margin-top: 12px;
}

.pagination-controls {
  display: flex;
  gap: 8px;
}

.flash {
  background: linear-gradient(135deg, rgba(34, 211, 238, 0.12), rgba(139, 92, 246, 0.12));
  border: 1px solid rgba(34, 211, 238, 0.3);
  color: var(--text);
  padding: 12px 14px;
  border-radius: 12px;
  margin-bottom: 12px;
}

@media (max-width: 1080px) {
  .layout {
    grid-template-columns: 1fr;
  }
  .sidebar {
    flex-direction: row;
    align-items: center;
    justify-content: space-between;
  }
  .nav {
    grid-template-columns: repeat(auto-fit, minmax(130px, 1fr));
  }
  .search-bar {
    grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
  }
}
