* {
  box-sizing: border-box;
}

body {
  margin: 0;
  font-family: Arial, sans-serif;
  background: #f5f5f5;
  color: #111;
}

.login-body {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  background: linear-gradient(135deg, #111, #2b2108);
}

.login-card {
  width: 390px;
  background: #fff;
  padding: 35px;
  border-radius: 18px;
  box-shadow: 0 20px 60px rgba(0,0,0,.35);
}

.login-logo {
  width: 160px;
  display: block;
  margin: 0 auto 20px;
}

.login-card h2 {
  text-align: center;
  margin-bottom: 25px;
}

label {
  display: block;
  margin: 14px 0 6px;
  font-weight: 600;
}

input, select, textarea {
  width: 100%;
  padding: 12px;
  border: 1px solid #ddd;
  border-radius: 10px;
}

button, .btn {
  background: #c89b2a;
  color: #111;
  border: none;
  padding: 12px 18px;
  border-radius: 10px;
  font-weight: 700;
  cursor: pointer;
  text-decoration: none;
  display: inline-block;
}

.alert {
  background: #ffe1e1;
  color: #9b0000;
  padding: 10px;
  border-radius: 8px;
  margin-bottom: 15px;
}

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

.sidebar {
  width: 250px;
  background: #080808;
  color: #fff;
  padding: 20px;
  position: fixed;
  inset: 0 auto 0 0;
}

.brand img {
  width: 150px;
  display: block;
  margin: 0 auto 30px;
}

.sidebar nav a {
  display: block;
  padding: 13px 14px;
  color: #fff;
  text-decoration: none;
  border-radius: 10px;
  margin-bottom: 8px;
}

.sidebar nav a:hover {
  background: #c89b2a;
  color: #111;
}

.sidebar-user {
  position: absolute;
  bottom: 25px;
  left: 20px;
  right: 20px;
  border-top: 1px solid #333;
  padding-top: 15px;
}

.sidebar-user span {
  display: block;
  color: #c89b2a;
  font-size: 13px;
}

.main {
  margin-left: 250px;
  padding: 30px;
  width: calc(100% - 250px);
}

.topbar {
  background: #fff;
  padding: 22px;
  border-radius: 18px;
  margin-bottom: 25px;
  box-shadow: 0 8px 25px rgba(0,0,0,.05);
}

.topbar h1 {
  margin: 0;
}

.topbar p {
  margin: 6px 0 0;
  color: #666;
}

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

.card {
  background: #fff;
  padding: 22px;
  border-radius: 18px;
  box-shadow: 0 8px 25px rgba(0,0,0,.05);
  border-left: 5px solid #c89b2a;
}

.card span {
  color: #666;
  font-size: 14px;
}

.card h2 {
  margin: 10px 0 0;
  font-size: 30px;
}

.panel {
  margin-top: 25px;
  background: #fff;
  padding: 25px;
  border-radius: 18px;
  box-shadow: 0 8px 25px rgba(0,0,0,.05);
}

@media(max-width: 900px) {
  .sidebar {
    width: 210px;
  }

  .main {
    margin-left: 210px;
    width: calc(100% - 210px);
  }

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

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

.form-grid textarea {
  grid-column: 1 / -1;
  min-height: 90px;
}

table {
  width: 100%;
  border-collapse: collapse;
  margin-top: 15px;
}

th, td {
  padding: 13px;
  border-bottom: 1px solid #eee;
  text-align: left;
}

th {
  background: #111;
  color: #fff;
}

.badge {
  background: #f2e4b8;
  color: #111;
  padding: 6px 10px;
  border-radius: 999px;
  font-size: 12px;
  font-weight: bold;
}

.danger {
  background: #b00020;
  color: #fff;
}
.page-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.page-header h1 {
  margin: 0;
}

.page-header p {
  margin: 6px 0 0;
  color: #666;
}

.section-title {
  margin-bottom: 18px;
}

.action-row {
  display: flex;
  gap: 8px;
  align-items: center;
}

.table-wrap {
  overflow-x: auto;
}

.panel h2 {
  margin-top: 0;
}

select {
  min-width: 140px;
}
.sidebar-brand {
    text-align: center;
    padding: 25px 15px;
    border-bottom: 1px solid rgba(255,255,255,.08);
    margin-bottom: 20px;
}

.sidebar-brand img {
    width: 150px;
    max-width: 100%;
    margin-bottom: 12px;
}

.sidebar-brand h2 {
    color: #D4AF37;
    font-size: 20px;
    font-weight: 700;
    margin: 0;
}
.login-logo {
    width: 180px;
    display: block;
    margin: 0 auto 20px;
}
/* ===== SIDEBAR ===== */

.sidebar {
    width: 260px;
    min-height: 100vh;
    background: #ffffff;
    border-right: 1px solid #e5e7eb;
    box-shadow: 2px 0 12px rgba(0,0,0,.05);
}

.sidebar-brand {
    text-align: center;
    padding: 30px 20px;
    border-bottom: 1px solid #ececec;
}

.sidebar-brand img {
    width: 170px;
    margin-bottom: 12px;
}

.sidebar-brand h2 {
    color: #111;
    font-size: 22px;
    margin: 0;
    font-weight: 700;
}

.sidebar ul {
    list-style: none;
    padding: 20px 0;
    margin: 0;
}

.sidebar li {
    margin: 4px 12px;
}

.sidebar a {
    display: flex;
    align-items: center;
    gap: 12px;
    color: #222;
    text-decoration: none;
    padding: 14px 18px;
    border-radius: 10px;
    transition: .2s;
    font-weight: 600;
}

.sidebar a:hover {
    background: #f5f5f5;
    color: #000;
}

.sidebar a.active {
    background: #D4AF37;
    color: #fff;
}

.sidebar a.active svg,
.sidebar a:hover svg {
    color: inherit;
}

.sidebar hr {
    border: none;
    border-top: 1px solid #ececec;
    margin: 15px;
}
.main {
    background: #f8f9fb;
    min-height: 100vh;
    padding: 30px;
}

.topbar {
    background: #fff;
    padding: 25px;
    border-radius: 14px;
    margin-bottom: 25px;
    box-shadow: 0 2px 10px rgba(0,0,0,.05);
}

.panel {
    background: #fff;
    border-radius: 14px;
    padding: 25px;
    box-shadow: 0 2px 10px rgba(0,0,0,.05);
    margin-bottom: 25px;
}

/* Sidebar text visibility fix */
.sidebar nav a {
  color: #111 !important;
  background: transparent;
  font-weight: 600;
}

.sidebar nav a:hover {
  background: #f5f5f5 !important;
  color: #111 !important;
}

.sidebar-user strong,
.sidebar-user span {
  color: #111 !important;
}

.sidebar-user {
  border-top: 1px solid #ddd;
}

/* Professional sidebar menu */
.sidebar {
  overflow-y: auto;
}

.sidebar-menu {
  padding: 10px 12px 90px;
}

.menu-section {
  font-size: 11px;
  font-weight: 800;
  color: #9ca3af;
  text-transform: uppercase;
  letter-spacing: 1px;
  margin: 20px 10px 8px;
}

.sidebar-menu a {
  display: flex;
  align-items: center;
  gap: 10px;
  color: #111 !important;
  text-decoration: none;
  padding: 12px 14px;
  border-radius: 12px;
  font-weight: 650;
  margin-bottom: 4px;
}

.sidebar-menu a:hover {
  background: #f3f4f6 !important;
}

.sidebar-menu a.active,
.sidebar-menu a:focus {
  background: #D4AF37 !important;
  color: #111 !important;
}

.sidebar-brand {
  padding-bottom: 18px;
}

.dashboard-toolbar {
  display: flex;
  justify-content: flex-end;
  gap: 15px;
  margin-bottom: 25px;
}

.search-box {
  max-width: 320px;
  background: #fff;
}

.gold-btn {
  background: linear-gradient(135deg, #d4a017, #b8860b);
  color: #fff;
}

.kpi-grid {
  display: grid;
  grid-template-columns: repeat(6, 1fr);
  gap: 18px;
  margin-bottom: 25px;
}

.kpi-card {
  background: #fff;
  border-radius: 16px;
  padding: 22px;
  box-shadow: 0 8px 25px rgba(0,0,0,.05);
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.kpi-card span {
  color: #555;
  font-size: 14px;
}

.kpi-card h2 {
  margin: 8px 0;
  font-size: 24px;
}

.kpi-card p {
  margin: 0;
  font-size: 13px;
}

.up { color: #16a34a; }
.down { color: #dc2626; }

.kpi-icon {
  width: 48px;
  height: 48px;
  border-radius: 14px;
  display: grid;
  place-items: center;
  font-size: 22px;
}

.gold { background: #d4a017; }
.purple { background: #5145cd; }
.green { background: #22c55e; }
.blue { background: #0ea5e9; }
.orange { background: #f97316; }

.dashboard-grid {
  display: grid;
  grid-template-columns: 2fr 1.2fr 1.2fr;
  gap: 20px;
  margin-bottom: 25px;
}

.dashboard-grid.two {
  grid-template-columns: 1fr 1fr;
}

.dash-panel {
  background: #fff;
  border-radius: 18px;
  padding: 22px;
  box-shadow: 0 8px 25px rgba(0,0,0,.05);
}

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

.fake-chart {
  height: 260px;
  margin-top: 20px;
  border-left: 1px solid #ddd;
  border-bottom: 1px solid #ddd;
  background: linear-gradient(to top, rgba(212,160,23,.15), transparent);
  border-radius: 12px;
}

.donut-wrap {
  display: flex;
  align-items: center;
  gap: 25px;
}

.donut {
  width: 160px;
  height: 160px;
  border-radius: 50%;
  background: conic-gradient(#22c55e 0 50%, #3b82f6 50% 80%, #f97316 80% 92%, #ef4444 92%);
  display: grid;
  place-items: center;
  font-size: 28px;
  font-weight: 800;
  color: #111;
  text-align: center;
}

.donut small {
  font-size: 12px;
  font-weight: 500;
}

.legend {
  list-style: none;
  padding: 0;
}

.legend li {
  margin-bottom: 12px;
}

.dot {
  width: 10px;
  height: 10px;
  display: inline-block;
  border-radius: 50%;
  margin-right: 8px;
}

.green-bg { background: #22c55e; }
.blue-bg { background: #3b82f6; }
.orange-bg { background: #f97316; }
.red-bg { background: #ef4444; }

.category-list div {
  display: flex;
  justify-content: space-between;
  padding: 14px 0;
  border-bottom: 1px solid #eee;
}

.outline-btn {
  background: #fff;
  color: #b8860b;
  border: 1px solid #d4a017;
}

.status {
  padding: 5px 10px;
  border-radius: 8px;
  font-size: 12px;
}

.delivered { background: #dcfce7; color: #15803d; }
.processing { background: #dbeafe; color: #1d4ed8; }
.pending { background: #fef3c7; color: #b45309; }
.cancelled { background: #fee2e2; color: #b91c1c; }

@media(max-width: 1300px) {
  .kpi-grid { grid-template-columns: repeat(3, 1fr); }
  .dashboard-grid { grid-template-columns: 1fr; }
}

@media(max-width: 800px) {
  .kpi-grid { grid-template-columns: 1fr; }
  .dashboard-grid.two { grid-template-columns: 1fr; }
}

/* Top right admin profile */
.modern-topbar {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.topbar-admin {
  display: flex;
  align-items: center;
  gap: 14px;
}

.admin-meta {
  text-align: right;
}

.admin-meta strong {
  display: block;
  color: #111;
  font-size: 14px;
}

.admin-meta span {
  display: block;
  color: #777;
  font-size: 12px;
}

.avatar-link {
  text-decoration: none;
}

.avatar-img,
.avatar-placeholder {
  width: 46px;
  height: 46px;
  border-radius: 50%;
  object-fit: cover;
  border: 2px solid #d4a017;
}

.avatar-placeholder {
  background: #111;
  color: #d4a017;
  display: grid;
  place-items: center;
  font-weight: 800;
  font-size: 18px;
}

.profile-box {
  display: flex;
  gap: 25px;
  align-items: center;
}

.profile-photo-large {
  width: 130px;
  height: 130px;
  border-radius: 24px;
  object-fit: cover;
  border: 3px solid #d4a017;
}

.placeholder-large {
  background: #111;
  color: #d4a017;
  display: grid;
  place-items: center;
  font-size: 44px;
  font-weight: 800;
}

.details-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 18px;
}

.details-grid div {
  background: #f8f9fb;
  padding: 18px;
  border-radius: 14px;
}

.details-grid span {
  display: block;
  color: #777;
  font-size: 13px;
  margin-bottom: 8px;
}

.details-grid strong {
  color: #111;
}

.user-cell {
  display: flex;
  align-items: center;
  gap: 10px;
}

.mini-avatar {
  width: 34px;
  height: 34px;
  border-radius: 50%;
  object-fit: cover;
  border: 2px solid #d4a017;
}

.mini-placeholder {
  background: #111;
  color: #d4a017;
  display: grid;
  place-items: center;
  font-weight: 800;
}
