:root {
  --nav-sidebar-width: 250px;
  --primary: #2f6fc2;
  --secondary: #17457a;
  --accent: #f4b942;
  --header-bg: #ffffff;
  --header-color: #17243a;
  --header-branding-color: #17457a;
  --header-link-color: #5f6f84;
  --breadcrumbs-bg: #f8fafc;
  --breadcrumbs-fg: #748197;
  --link-fg: #2867b4;
  --link-hover-color: #17457a;
  --body-bg: #f4f7fb;
  --body-fg: #223047;
  --hairline-color: #e3e9f1;
  --border-color: #dce4ee;
  --button-bg: #2f6fc2;
  --button-hover-bg: #174f91;
  --default-button-bg: #20b486;
  --default-button-hover-bg: #15966e;
}

html, body { background: #f4f7fb; }
body { font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Microsoft YaHei", sans-serif; }
#header {
  min-height: 64px;
  padding: 0 24px;
  background: #fff;
  border-bottom: 1px solid #e3e9f1;
  box-shadow: 0 2px 9px rgba(34, 62, 96, .04);
}
#site-name a { color: #17457a !important; font-size: 20px; font-weight: 750; }
#user-tools { color: #7c8798; }
#user-tools a { color: #52637a; border-bottom: 0; }

#nav-sidebar {
  background: linear-gradient(180deg, #174b83, #103b6d);
  border-right: 0;
  box-shadow: 4px 0 16px rgba(17, 54, 94, .08);
}
#nav-filter {
  margin: 14px;
  width: calc(100% - 28px);
  box-sizing: border-box;
  color: #fff;
  background: rgba(255,255,255,.1);
  border: 1px solid rgba(255,255,255,.12);
  border-radius: 8px;
}
#nav-filter::placeholder { color: rgba(255,255,255,.55); }
#nav-sidebar .module { background: transparent; }
#nav-sidebar .module table,
#nav-sidebar .module tbody,
#nav-sidebar .module tr,
#nav-sidebar .module tr:nth-child(odd),
#nav-sidebar .module tr:nth-child(even) {
  background: transparent !important;
}
#nav-sidebar .module caption {
  padding: 15px 18px 7px;
  color: rgba(255,255,255,.55);
  background: transparent;
  font-size: 11px;
  letter-spacing: .5px;
}
#nav-sidebar table { width: 100%; }
#nav-sidebar th, #nav-sidebar td { padding: 0; border: 0; }
#nav-sidebar th, #nav-sidebar td,
#nav-sidebar th:first-child, #nav-sidebar td:first-child {
  background: transparent !important;
}
#nav-sidebar th a, #nav-sidebar td a {
  display: block;
  margin: 2px 10px;
  padding: 9px 12px;
  color: rgba(255,255,255,.84);
  border-radius: 7px;
}
#nav-sidebar td a { color: rgba(255,255,255,.55); font-size: 11px; text-align: right; }
#nav-sidebar tr.current-model th a,
#nav-sidebar th a:hover { color: #fff; background: rgba(60, 137, 226, .42); }
.toggle-nav-sidebar { color: #fff; background: #17457a; border: 0; }

#content { padding: 28px 30px 40px; }
#content h1 { color: #1b2940; font-size: 26px; font-weight: 750; }
.breadcrumbs { padding: 12px 30px; border-bottom: 1px solid #e3e9f1; }
.module, #changelist .actions, .inline-group, .submit-row {
  overflow: hidden;
  background: #fff;
  border: 1px solid #e1e7ef;
  border-radius: 10px;
  box-shadow: 0 4px 15px rgba(28, 61, 99, .05);
}
.module h2, .module caption, .inline-group h2 {
  color: #24334b;
  background: #f8fafc;
  border-bottom: 1px solid #e3e9f1;
}
input[type=text], input[type=password], input[type=email], input[type=url],
input[type=number], textarea, select, .vTextField {
  padding: 9px 11px;
  border-color: #d5deea;
  border-radius: 7px;
}
input[type=submit], button, .button, a.button { border-radius: 7px; }
#changelist .results { overflow: auto; border: 1px solid #e1e7ef; border-radius: 10px; background: #fff; }
#result_list thead th { color: #617087; background: #f7f9fc; }
#result_list tbody tr:hover { background: #f5f9ff; }

.dashboard.qexams-home #content,
.qexams-home #content {
  width: auto !important;
  max-width: none !important;
  margin: 0 !important;
}
.qexams-home #content-main {
  width: 100% !important;
  max-width: none !important;
  float: none !important;
}
.qexams-home .main > .content {
  min-width: 0;
}
.q-home-head { margin-bottom: 20px; }
.q-home-head h1 { margin: 0 !important; font-size: 29px !important; }
.q-home-head p { margin: 6px 0 0; color: #7e8a9c; }
.q-stat-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 16px; margin-bottom: 20px; }
.q-stat-card {
  min-height: 86px;
  padding: 18px 20px;
  display: flex;
  align-items: center;
  gap: 15px;
  box-sizing: border-box;
  color: #1d2b42 !important;
  background: #fff;
  border: 1px solid #e1e7ef;
  border-radius: 11px;
  box-shadow: 0 4px 15px rgba(28, 61, 99, .05);
  text-decoration: none;
}
.q-stat-icon { width: 48px; height: 48px; display: flex; align-items: center; justify-content: center; color: #fff; border-radius: 50%; font-weight: 800; }
.q-stat-card small, .q-stat-card strong { display: block; }
.q-stat-card small { color: #66758a; font-size: 12px; }
.q-stat-card strong { margin-top: 3px; font-size: 26px; line-height: 1; }
.q-blue .q-stat-icon { background: #3478d4; }.q-green .q-stat-icon { background: #20b486; }
.q-purple .q-stat-icon { background: #7157d9; }.q-orange .q-stat-icon { background: #f2a024; }
.q-manage-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 18px; }
.q-manage-card { overflow: hidden; background: #fff; border: 1px solid #e1e7ef; border-radius: 11px; box-shadow: 0 4px 15px rgba(28, 61, 99, .05); }
.q-manage-card h2 { margin: 0; padding: 15px 18px; color: #26364e; background: #fbfcfe; border-bottom: 1px solid #e5eaf1; font-size: 16px; }
.q-manage-row { min-height: 50px; padding: 0 18px; display: flex; align-items: center; justify-content: space-between; border-bottom: 1px solid #edf1f5; }
.q-manage-row:last-child { border-bottom: 0; }
.q-manage-row > span:first-child { color: #34445b; font-weight: 600; }
.q-manage-row > span:last-child { display: flex; gap: 9px; }
.q-manage-row a { min-width: 52px; padding: 6px 10px; box-sizing: border-box; color: #fff !important; background: #2f6fc2; border-radius: 6px; text-align: center; text-decoration: none; }
.q-manage-row a.q-add { background: #20a97d; }

@media (max-width: 1050px) {
  .q-stat-grid { grid-template-columns: repeat(2, 1fr); }
}
@media (min-width: 1500px) {
  .qexams-home #content { padding-left: 42px; padding-right: 42px; }
  .q-stat-grid { gap: 20px; }
  .q-manage-grid { gap: 20px; }
}
@media (max-width: 767px) {
  #header { padding: 0 12px; }
  #content { padding: 20px 14px 30px; }
  .q-stat-grid, .q-manage-grid { grid-template-columns: 1fr; }
}
