:root {
  font-family: Inter, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  color: #172033;
  background: #f4f7fc;
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  min-height: 100vh;
}

button,
input {
  font: inherit;
}

.login-body {
  display: grid;
  place-items: center;
  padding: 24px;
  background:
    radial-gradient(circle at top left, #dbeafe, transparent 35%),
    radial-gradient(circle at bottom right, #ede9fe, transparent 40%),
    #f5f7fb;
}

.login-card {
  width: min(430px, 100%);
  padding: 38px;
  background: white;
  border: 1px solid #e5eaf3;
  border-radius: 22px;
  box-shadow: 0 24px 60px rgba(42, 55, 95, 0.12);
}

.brand {
  font-weight: 800;
  font-size: 21px;
  color: #4f46e5;
}

h1 {
  margin: 20px 0 5px;
}

.muted {
  color: #718096;
}

label {
  display: block;
  margin: 18px 0 7px;
  font-weight: 650;
}

input {
  width: 100%;
  padding: 13px 15px;
  border: 1px solid #d9dfeb;
  border-radius: 11px;
  outline: none;
}

input:focus {
  border-color: #6366f1;
  box-shadow: 0 0 0 3px rgba(99, 102, 241, 0.14);
}

button {
  border: 0;
  cursor: pointer;
}

.login-card button {
  width: 100%;
  margin-top: 22px;
  padding: 13px;
  color: white;
  font-weight: 750;
  background: linear-gradient(135deg, #4f46e5, #7c3aed);
  border-radius: 11px;
}

.message {
  min-height: 22px;
  margin-top: 14px;
}

.message.error {
  color: #dc2626;
}

footer {
  margin-top: 30px;
  text-align: center;
  color: #8a94a7;
  font-size: 13px;
}

.layout {
  display: grid;
  grid-template-columns: 245px minmax(0, 1fr);
  min-height: 100vh;
}

.sidebar {
  display: flex;
  flex-direction: column;
  padding: 28px 20px;
  color: white;
  background: #111827;
}

.sidebar .brand {
  color: white;
  padding: 0 10px 24px;
}

.sidebar nav {
  display: grid;
  gap: 7px;
}

.sidebar a {
  padding: 12px 14px;
  color: #b9c2d1;
  text-decoration: none;
  border-radius: 10px;
}

.sidebar a:hover,
.sidebar a.active {
  color: white;
  background: #27324a;
}

.logout {
  margin-top: auto;
  padding: 12px;
  color: #fecaca;
  background: transparent;
  border: 1px solid #4b5563;
  border-radius: 10px;
}

.content {
  padding: 32px;
}

.topbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.topbar h1 {
  margin: 0;
}

.user-badge {
  padding: 10px 14px;
  background: white;
  border: 1px solid #e1e7f0;
  border-radius: 999px;
}

.cards {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 18px;
  margin-top: 30px;
}

.stat-card,
.panel {
  background: white;
  border: 1px solid #e4e9f2;
  border-radius: 16px;
  box-shadow: 0 8px 28px rgba(23, 32, 51, 0.05);
}

.stat-card {
  padding: 22px;
}

.stat-card span {
  display: block;
  color: #718096;
}

.stat-card strong {
  display: block;
  margin-top: 14px;
  font-size: 30px;
}

.panel {
  margin-top: 22px;
  padding: 26px;
}

.panel h2 {
  margin-top: 0;
}

@media (max-width: 900px) {
  .layout {
    grid-template-columns: 1fr;
  }

  .sidebar {
    min-height: auto;
  }

  .sidebar nav {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .logout {
    margin-top: 20px;
  }

  .cards {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 560px) {
  .content {
    padding: 20px;
  }

  .topbar {
    align-items: flex-start;
    gap: 15px;
    flex-direction: column;
  }

  .cards {
    grid-template-columns: 1fr;
  }
}
