html {
  font-size: 14px;
}

@media (min-width: 768px) {
  html {
    font-size: 16px;
  }
}

.btn:focus, .btn:active:focus, .btn-link.nav-link:focus, .form-control:focus, .form-check-input:focus {
  box-shadow: 0 0 0 0.1rem white, 0 0 0 0.25rem #258cfb;
}

html {
  position: relative;
  min-height: 100%;
}

body {
  margin-bottom: 0;
}

:root {
  --bv-primary: #2563eb;
  --bv-primary-dark: #1d4ed8;
  --bv-accent: #38bdf8;
  --bv-surface: #ffffff;
  --bv-surface-muted: #f8fbff;
  --bv-text: #0f172a;
  --bv-text-muted: #475569;
  --bv-border: #dbe5f3;
  --bv-shadow: 0 18px 50px rgba(15, 23, 42, 0.12);
}

body.app-shell {
  font-family: "Inter", "Segoe UI", system-ui, -apple-system, sans-serif;
  color: var(--bv-text);
  background: radial-gradient(1200px 600px at 10% 0%, #e0f2fe 0%, #f8fbff 40%, #ffffff 100%);
}

/* Sidebar layout */
.sidebar {
  position: fixed;
  top: 0;
  left: 0;
  width: 220px;
  height: 100vh;
  background: linear-gradient(180deg, #eff6ff 0%, #ffffff 70%);
  border-right: 1px solid var(--bv-border);
  display: flex;
  flex-direction: column;
  padding: 1.5rem 0;
  z-index: 1000;
}

.sidebar-brand {
  padding: 0 1.25rem 1.5rem;
  border-bottom: 1px solid var(--bv-border);
  margin-bottom: 0.5rem;
}

.sidebar-brand a {
  font-weight: 600;
  font-size: 1.25rem;
  color: var(--bv-primary);
  text-decoration: none;
}

.sidebar-nav {
  flex: 1;
  display: flex;
  flex-direction: column;
  padding: 0.5rem 0;
}

.sidebar-link {
  display: block;
  padding: 0.6rem 1.25rem;
  color: var(--bv-text-muted);
  font-weight: 500;
  text-decoration: none;
}

.sidebar-link:hover,
.sidebar-link:focus {
  color: var(--bv-primary);
  background: rgba(37, 99, 235, 0.06);
}

.sidebar-footer {
  padding: 0.5rem 0;
  border-top: 1px solid var(--bv-border);
}

.sidebar-footer .sidebar-session,
.sidebar-footer .sidebar-user {
  padding: 0.25rem 1.25rem;
}

.sidebar-user {
  font-weight: 500;
  color: var(--bv-text);
  margin-bottom: 0;
}

.sidebar-user-type {
  font-size: 0.7rem;
  padding: 0 1.25rem;
  margin-bottom: 0.25rem;
}

.sidebar-session {
  color: var(--bv-text-muted);
  margin-bottom: 0.5rem;
}

.main-content {
  min-height: 100vh;
  padding: 2rem;
}

.main-content.has-sidebar {
  margin-left: 220px;
}

.main-content main {
  padding: 0;
}

.card-panel {
  background: var(--bv-surface);
  border: 1px solid var(--bv-border);
  border-radius: 18px;
  padding: 1.5rem;
  box-shadow: var(--bv-shadow);
  overflow: hidden;
}

.display-4,
.display-5 {
  color: var(--bv-text);
  letter-spacing: -0.02em;
}

.table {
  border-color: var(--bv-border);
}

.table thead {
  background: #eff6ff;
  color: var(--bv-text-muted);
}

.table a {
  color: var(--bv-primary);
  font-weight: 600;
  text-decoration: none;
}

.table a:hover,
.table a:focus {
  color: var(--bv-primary-dark);
  text-decoration: underline;
}

.alert {
  border-radius: 14px;
  border-width: 1px;
}

.alert-danger {
  background: #fee2e2;
  border-color: #fecaca;
  color: #991b1b;
}


.alert-secondary {
  background: #e0f2fe;
  border-color: #bae6fd;
  color: #0c4a6e;
}

.footer {
  background: transparent;
  color: var(--bv-text-muted);
  padding-top: 1.5rem;
}

.footer a {
  color: var(--bv-primary);
}

.footer a:hover,
.footer a:focus {
  color: var(--bv-primary-dark);
}

.form-floating > .form-control-plaintext::placeholder, .form-floating > .form-control::placeholder {
  color: var(--bs-secondary-color);
  text-align: end;
}

.form-floating > .form-control-plaintext:focus::placeholder, .form-floating > .form-control:focus::placeholder {
  text-align: start;
}