* {
  box-sizing: border-box;
}

html,
body {
  margin: 0;
  padding: 0;
  min-height: 100%;
}

body {
  font-family: Arial, Helvetica, sans-serif;
  background: #f5f6f8;
  color: #111827;
}

button,
input,
select,
textarea {
  font: inherit;
}

button {
  cursor: pointer;
}

a {
  color: inherit;
  text-decoration: none;
}

.hidden {
  display: none !important;
}

/* =========================
   ADMIN SHELL
========================= */

.admin-shell {
  min-height: 100vh;
  display: flex;
}

/* =========================
   SIDEBAR
========================= */

.sidebar {
  width: 240px;
  min-height: 100vh;
  background: #111827;
  color: #ffffff;
  padding: 24px 16px;
  display: flex;
  flex-direction: column;
  position: fixed;
  left: 0;
  top: 0;
  bottom: 0;
}

.brand {
  padding: 0 10px 24px;
  border-bottom: 1px solid #273449;
  margin-bottom: 20px;
}

.brand h2 {
  margin: 0;
  font-size: 22px;
}

.brand span {
  display: block;
  margin-top: 5px;
  color: #9ca3af;
  font-size: 13px;
}

/* =========================
   NAVIGATION
========================= */

.nav {
  display: flex;
  flex-direction: column;
  gap: 5px;
}

.nav a {
  padding: 11px 12px;
  border-radius: 8px;
  color: #cbd5e1;
  font-size: 14px;
  transition: 0.2s;
}

.nav a:hover {
  background: #1f2937;
  color: #ffffff;
}

.nav a.active {
  background: #2563eb;
  color: #ffffff;
}

/* =========================
   LOGOUT
========================= */

.logout-button {
  margin-top: auto;
  width: 100%;
  padding: 11px 12px;
  border: 1px solid #374151;
  border-radius: 8px;
  background: transparent;
  color: #d1d5db;
}

.logout-button:hover {
  background: #1f2937;
  color: #ffffff;
}

/* =========================
   MAIN CONTENT
========================= */

.main-content {
  width: calc(100% - 240px);
  min-height: 100vh;
  margin-left: 240px;
}

/* =========================
   TOPBAR
========================= */

.topbar {
  min-height: 72px;
  padding: 16px 28px;
  background: #ffffff;
  border-bottom: 1px solid #e5e7eb;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
}

.topbar h1 {
  margin: 0;
  font-size: 24px;
  color: #111827;
}

.admin-user {
  color: #4b5563;
  font-size: 14px;
  font-weight: 600;
}

/* =========================
   PAGE CONTENT
========================= */

#page-content {
  padding: 28px;
}

.page-placeholder {
  background: #ffffff;
  border: 1px solid #e5e7eb;
  border-radius: 14px;
  padding: 28px;
}

.page-placeholder h2 {
  margin: 0 0 8px;
  font-size: 22px;
}

.page-placeholder p {
  margin: 0;
  color: #6b7280;
}

/* =========================
   ADMIN MESSAGE
========================= */

.admin-message {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 24px;
  text-align: center;
}

.admin-message h1 {
  margin: 0 0 10px;
}

.admin-message p {
  margin: 0 0 20px;
  color: #6b7280;
}

.admin-message button {
  border: 0;
  border-radius: 8px;
  padding: 11px 20px;
  background: #2563eb;
  color: #ffffff;
  font-weight: 700;
}

/* =========================
   MOBILE
========================= */

@media (max-width: 799px) {

  .admin-shell {
    display: block;
  }

  .sidebar {
    position: static;
    width: 100%;
    min-height: auto;
    padding: 16px;
  }

  .brand {
    padding-bottom: 16px;
    margin-bottom: 14px;
  }

  .nav {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 6px;
  }

  .nav a {
    font-size: 13px;
    padding: 10px;
  }

  .logout-button {
    margin-top: 16px;
  }

  .main-content {
    width: 100%;
    margin-left: 0;
  }

  .topbar {
    padding: 16px 18px;
  }

  .topbar h1 {
    font-size: 20px;
  }

  #page-content {
    padding: 18px;
  }

  .page-placeholder {
    padding: 20px;
  }
}
