/* Perfection IT Portal — Ultra-modern theme with selectable light / dark mode.
   Light is default; dark via [data-theme="dark"]. Brand: navy + azure gradient. */

:root,
[data-theme="light"] {
  color-scheme: light;
  --bg: #f3f6fb;
  --bg-alt: #eaf0f7;
  --surface: #ffffff;
  --surface-2: #f1f5fa;
  --surface-glass: rgba(255, 255, 255, 0.78);
  --border: #e2e9f3;
  --border-strong: #cbd6e6;
  --text: #0a1728;
  --text-muted: #5b6b84;
  --text-faint: #8a99b0;
  --accent: #0f7cc4;
  --accent-2: #0b5c96;
  --accent-soft: rgba(15, 124, 196, 0.1);
  --accent-grad: linear-gradient(135deg, #2a97d4 0%, #0b63a5 100%);
  --success: #0ea472;
  --warning: #d97706;
  --danger: #dc2626;
  --radius: 18px;
  --radius-sm: 12px;
  --container: 1180px;
  --shadow-sm: 0 1px 2px rgba(10, 23, 40, 0.06), 0 4px 16px -6px rgba(10, 23, 40, 0.1);
  --shadow: 0 12px 40px -12px rgba(10, 23, 40, 0.18);
  --shadow-lg: 0 24px 70px -20px rgba(10, 23, 40, 0.28);
  --header-bg: rgba(255, 255, 255, 0.78);
  --input-bg: #f7fafd;
  --mesh-1: rgba(42, 151, 212, 0.16);
  --mesh-2: rgba(11, 99, 165, 0.1);
  --grid-line: rgba(11, 22, 40, 0.06);
}

[data-theme="dark"] {
  color-scheme: dark;
  --bg: #040c18;
  --bg-alt: #071427;
  --surface: #0b1b30;
  --surface-2: rgba(21, 42, 68, 0.55);
  --surface-glass: rgba(9, 22, 38, 0.72);
  --border: #1a3352;
  --border-strong: #274a75;
  --text: #eaf1fa;
  --text-muted: #9db1c9;
  --text-faint: #647d99;
  --accent: #38a9e6;
  --accent-2: #0f7cc4;
  --accent-soft: rgba(56, 169, 230, 0.12);
  --accent-grad: linear-gradient(135deg, #38a9e6 0%, #0b63a5 100%);
  --success: #22c07a;
  --warning: #f5a524;
  --danger: #f05252;
  --shadow-sm: 0 1px 2px rgba(0, 0, 0, 0.4), 0 6px 20px -8px rgba(0, 0, 0, 0.55);
  --shadow: 0 16px 48px -14px rgba(0, 0, 0, 0.6);
  --shadow-lg: 0 30px 80px -20px rgba(0, 0, 0, 0.65);
  --header-bg: rgba(4, 12, 24, 0.72);
  --input-bg: #081525;
  --mesh-1: rgba(56, 169, 230, 0.22);
  --mesh-2: rgba(11, 99, 165, 0.28);
  --grid-line: rgba(234, 241, 250, 0.06);
}

* { box-sizing: border-box; }

html {
  font-size: 15px;
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
}

body {
  margin: 0;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  background:
    radial-gradient(900px 480px at 12% -6%, var(--mesh-1), transparent 60%),
    radial-gradient(760px 520px at 88% 8%, var(--mesh-2), transparent 62%),
    var(--bg);
  color: var(--text);
  font-family: "Inter", ui-sans-serif, system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  transition: background-color 0.3s ease, color 0.3s ease;
}

body::before {
  content: "";
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 0;
  background-image:
    linear-gradient(var(--grid-line) 1px, transparent 1px),
    linear-gradient(90deg, var(--grid-line) 1px, transparent 1px);
  background-size: 44px 44px;
  mask-image: radial-gradient(ellipse 90% 60% at 50% 0%, black 30%, transparent 75%);
  opacity: 0.7;
}

main { flex: 1; position: relative; z-index: 1; }

a { color: var(--accent); text-decoration: none; }
a:hover { color: var(--accent-2); }

::selection { background: rgba(42, 151, 212, 0.3); }

/* ---------- Header ---------- */
.site-header {
  position: sticky;
  top: 12px;
  z-index: 50;
  margin: 12px auto 0;
  width: min(var(--container), calc(100% - 24px));
  background: var(--header-bg);
  backdrop-filter: blur(18px) saturate(1.3);
  -webkit-backdrop-filter: blur(18px) saturate(1.3);
  border: 1px solid var(--border);
  border-radius: 20px;
  box-shadow: var(--shadow-sm);
}

.header-inner {
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 10px 14px 10px 16px;
  max-width: none;
}

.brand {
  display: flex;
  align-items: center;
  gap: 11px;
  font-weight: 800;
  letter-spacing: -0.02em;
  font-size: 1.02rem;
  color: var(--text);
  flex-shrink: 0;
}

.brand-mark {
  width: 38px;
  height: 38px;
  border-radius: 12px;
  background: #fff;
  padding: 3px;
  box-shadow: var(--shadow-sm);
}

[data-theme="dark"] .brand-mark { background: #fff; }

.brand-name-accent {
  background: var(--accent-grad);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.site-nav { flex: 1; display: flex; justify-content: center; min-width: 0; }

.nav-menu {
  list-style: none;
  display: flex;
  align-items: center;
  gap: 4px;
  margin: 0;
  padding: 4px;
  background: var(--surface-2);
  border: 1px solid var(--border);
  border-radius: 999px;
}

.nav-menu a {
  display: inline-flex;
  align-items: center;
  padding: 8px 16px;
  border-radius: 999px;
  color: var(--text-muted);
  font-weight: 600;
  font-size: 0.9rem;
  transition: all 0.2s ease;
  white-space: nowrap;
}

.nav-menu a:hover, .nav-menu a.active { color: var(--text); background: var(--surface); box-shadow: var(--shadow-sm); }

.header-actions { display: flex; align-items: center; gap: 10px; flex-shrink: 0; }

/* Theme toggle */
.theme-toggle {
  width: 42px;
  height: 42px;
  border-radius: 50%;
  border: 1px solid var(--border);
  background: var(--surface);
  color: var(--text-muted);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all 0.25s ease;
  position: relative;
  overflow: hidden;
}

.theme-toggle:hover { border-color: var(--accent); color: var(--accent); transform: translateY(-1px); box-shadow: var(--shadow-sm); }

.theme-toggle svg { position: absolute; transition: opacity 0.25s ease, transform 0.35s ease; }
.theme-toggle .icon-sun { opacity: 0; transform: rotate(90deg) scale(0.6); }
.theme-toggle .icon-moon { opacity: 1; transform: rotate(0) scale(1); }
[data-theme="dark"] .theme-toggle .icon-sun { opacity: 1; transform: rotate(0) scale(1); }
[data-theme="dark"] .theme-toggle .icon-moon { opacity: 0; transform: rotate(-90deg) scale(0.6); }

.user-chip {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 6px 14px 6px 6px;
  border-radius: 999px;
  border: 1px solid var(--border);
  background: var(--surface);
  color: var(--text);
  font-weight: 600;
  font-size: 0.88rem;
  cursor: pointer;
  transition: border-color 0.2s ease, transform 0.15s ease;
}

.user-chip:hover { border-color: var(--accent); }

.avatar {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background: var(--accent-grad);
  color: #fff;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-weight: 800;
  font-size: 0.85rem;
}

.nav-toggle { display: none; }

/* Buttons */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 10px 20px;
  border-radius: 999px;
  font-weight: 700;
  font-size: 0.9rem;
  border: 1px solid transparent;
  cursor: pointer;
  transition: transform 0.16s ease, box-shadow 0.2s ease, background 0.2s ease, border-color 0.2s ease;
  white-space: nowrap;
  text-decoration: none;
}

.btn-primary {
  background: var(--accent-grad);
  color: #fff;
  box-shadow: 0 8px 24px -10px rgba(42, 151, 212, 0.6);
}
.btn-primary:hover { transform: translateY(-1px); box-shadow: 0 14px 32px -10px rgba(42, 151, 212, 0.65); color: #fff; }
.btn-primary:active { transform: translateY(0); }

.btn-ghost, .btn-outline-primary, .btn-outline-secondary {
  background: var(--surface);
  color: var(--text);
  border-color: var(--border);
}
.btn-ghost:hover, .btn-outline-primary:hover, .btn-outline-secondary:hover {
  border-color: var(--accent); color: var(--accent); transform: translateY(-1px);
}
.btn-outline-danger { background: transparent; border-color: rgba(220,38,38,0.4); color: var(--danger); }
.btn-outline-danger:hover { background: rgba(220,38,38,0.1); border-color: var(--danger); }
.btn-outline-success { background: transparent; border-color: rgba(14,164,114,0.4); color: var(--success); }
.btn-lg { padding: 14px 28px; font-size: 1rem; border-radius: 14px; }
.btn-sm { padding: 7px 12px; font-size: 0.82rem; }

/* Layout containers */
.page-wrap { width: min(var(--container), 100% - 32px); margin: 0 auto; padding: 28px 0 64px; }
.page-head { display: flex; align-items: flex-end; justify-content: space-between; gap: 16px; margin: 8px 0 22px; flex-wrap: wrap; }
.page-head h1 { font-size: clamp(1.6rem, 3vw, 2.2rem); font-weight: 800; letter-spacing: -0.03em; margin: 0; }
.page-head p { margin: 6px 0 0; color: var(--text-muted); }

/* Cards */
.card, .stat-card, .feature-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: var(--shadow-sm);
}

.card { overflow: hidden; }
.card-header { background: transparent; border-bottom: 1px solid var(--border); padding: 16px 20px; font-weight: 700; }
.card-body { padding: 20px; }

a.feature-card, .stat-card { transition: transform 0.18s ease, border-color 0.18s ease, box-shadow 0.2s ease; }
a.feature-card:hover { transform: translateY(-4px); border-color: var(--accent); box-shadow: var(--shadow); }

/* Tables */
.table-responsive { border-radius: var(--radius); overflow: hidden; }
.table { margin: 0; color: var(--text); }
.table thead th {
  background: var(--surface-2);
  border: none;
  font-size: 0.72rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--text-muted);
  padding: 12px 16px;
  white-space: nowrap;
}
.table tbody td { padding: 14px 16px; border-top: 1px solid var(--border); vertical-align: middle; }
.table tbody tr { transition: background 0.15s ease; }
.table tbody tr:hover { background: var(--accent-soft); }
.table-warning { --bs-table-bg: rgba(217,119,6,0.12); }

/* Forms */
.form-label { font-size: 0.85rem; font-weight: 700; color: var(--text); margin-bottom: 8px; }
.form-control, .form-select {
  background: var(--input-bg);
  border: 1px solid var(--border);
  border-radius: 12px;
  color: var(--text);
  padding: 12px 14px;
  font-size: 0.95rem;
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
}
.form-control::placeholder { color: var(--text-faint); }
.form-control:focus, .form-select:focus {
  background: var(--surface);
  border-color: var(--accent);
  color: var(--text);
  box-shadow: 0 0 0 4px var(--accent-soft);
  outline: none;
}
.form-text { color: var(--text-muted); font-size: 0.82rem; }
.form-check-input { width: 1.1em; height: 1.1em; border: 1px solid var(--border-strong); background: var(--input-bg); }
.form-check-input:checked { background-color: var(--accent); border-color: var(--accent); }
.form-check-input:focus { box-shadow: 0 0 0 4px var(--accent-soft); border-color: var(--accent); }

/* Badges, alerts */
.badge { font-weight: 700; font-size: 0.72rem; letter-spacing: 0.02em; padding: 6px 10px; border-radius: 999px; }
.bg-success, .badge.bg-success { background: rgba(14,164,114,0.15) !important; color: var(--success) !important; border: 1px solid rgba(14,164,114,0.3); }
.bg-danger, .badge.bg-danger { background: rgba(220,38,38,0.12) !important; color: var(--danger) !important; border: 1px solid rgba(220,38,38,0.3); }
.bg-warning, .badge.bg-warning { background: rgba(217,119,6,0.14) !important; color: var(--warning) !important; border: 1px solid rgba(217,119,6,0.3); }
.bg-secondary, .badge.bg-secondary { background: var(--surface-2) !important; color: var(--text-muted) !important; border: 1px solid var(--border); }
.bg-info { background: var(--accent-soft) !important; color: var(--accent) !important; border: 1px solid var(--border); }
.bg-primary { background: var(--accent-grad) !important; }

.alert { border-radius: 14px; border: 1px solid var(--border); background: var(--surface); color: var(--text); box-shadow: var(--shadow-sm); }
.alert-success { border-left: 4px solid var(--success); }
.alert-danger { border-left: 4px solid var(--danger); }
.alert-warning { border-left: 4px solid var(--warning); }
.alert-info { border-left: 4px solid var(--accent); }

/* Hero */
.hero { position: relative; padding: 72px 0 48px; overflow: hidden; }
.hero-inner { position: relative; z-index: 1; text-align: center; }
.eyebrow {
  display: inline-flex; align-items: center; gap: 8px;
  padding: 7px 14px; border-radius: 999px;
  background: var(--accent-soft); border: 1px solid var(--border);
  color: var(--accent); font-weight: 700; font-size: 0.78rem;
  letter-spacing: 0.1em; text-transform: uppercase; margin-bottom: 18px;
}
.hero h1 { font-size: clamp(2.4rem, 6vw, 4rem); font-weight: 850; letter-spacing: -0.04em; line-height: 1.02; margin: 0 0 14px; }
.hero h1 .grad { background: var(--accent-grad); -webkit-background-clip: text; background-clip: text; color: transparent; }
.hero-sub { font-size: clamp(1.05rem, 2.4vw, 1.35rem); color: var(--text-muted); font-weight: 500; margin: 0 0 16px; }
.hero-lede { max-width: 680px; margin: 0 auto 32px; color: var(--text-muted); }
.hero-actions { display: flex; gap: 12px; justify-content: center; flex-wrap: wrap; }

.stats-grid, .services-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; }
.stat-card { padding: 26px 20px; text-align: center; }
.stat-number { font-size: 2rem; font-weight: 850; margin: 0 0 6px; background: var(--accent-grad); -webkit-background-clip: text; background-clip: text; color: transparent; }
.stat-label { margin: 0; color: var(--text-muted); font-size: 0.9rem; }
.feature-card { padding: 24px; display: block; color: var(--text); }
.feature-card h3 { margin: 0 0 8px; font-size: 1.05rem; }
.feature-card p { margin: 0; color: var(--text-muted); font-size: 0.93rem; }
.feature-icon { width: 46px; height: 46px; border-radius: 14px; background: var(--accent-soft); border: 1px solid var(--border); display: flex; align-items: center; justify-content: center; color: var(--accent); margin-bottom: 14px; }
.card-link { display: inline-flex; margin-top: 12px; color: var(--accent); font-weight: 700; font-size: 0.9rem; }

.section { padding: 56px 0; }
.section-alt { background: var(--bg-alt); border-top: 1px solid var(--border); border-bottom: 1px solid var(--border); }
.section-kicker { color: var(--accent); font-weight: 800; font-size: 0.78rem; letter-spacing: 0.1em; text-transform: uppercase; margin-bottom: 10px; }
.section h2 { font-size: clamp(1.5rem, 3vw, 2.1rem); letter-spacing: -0.02em; margin: 0 0 24px; font-weight: 800; }
.section-center { text-align: center; }
.engage-inner { text-align: center; }
.engage-lede { color: var(--text-muted); max-width: 620px; margin: 0 auto 26px; }

/* Auth */
.auth-page { min-height: calc(100vh - 220px); display: flex; align-items: center; justify-content: center; padding: 32px 0; position: relative; }
.auth-container {
  width: min(1020px, 100%);
  display: grid; grid-template-columns: 1fr 1fr;
  background: var(--surface); border: 1px solid var(--border);
  border-radius: 28px; overflow: hidden; box-shadow: var(--shadow-lg);
  position: relative; z-index: 1;
}
.auth-brand-panel {
  position: relative; overflow: hidden; padding: 44px 40px; color: #fff;
  background: radial-gradient(600px 400px at 20% 10%, rgba(56,169,230,0.5), transparent 60%),
    radial-gradient(500px 500px at 90% 90%, rgba(11,99,165,0.7), transparent 60%),
    linear-gradient(160deg, #0a2540 0%, #071427 55%, #040c18 100%);
  display: flex; flex-direction: column; justify-content: space-between; gap: 28px;
  min-height: 560px;
}
.auth-brand-panel::after {
  content: ""; position: absolute; inset: 0;
  background-image: linear-gradient(rgba(255,255,255,0.07) 1px, transparent 1px), linear-gradient(90deg, rgba(255,255,255,0.07) 1px, transparent 1px);
  background-size: 36px 36px;
  mask-image: radial-gradient(ellipse 80% 70% at 30% 20%, black, transparent 75%);
}
.auth-brand-panel > * { position: relative; z-index: 1; }
.auth-panel-logo { display: flex; align-items: center; gap: 12px; font-weight: 800; }
.auth-panel-logo img { width: 42px; height: 42px; border-radius: 12px; background: #fff; padding: 4px; }
.auth-panel-title { font-size: clamp(1.8rem, 3vw, 2.4rem); font-weight: 850; letter-spacing: -0.03em; line-height: 1.05; margin: 0; }
.auth-panel-sub { color: rgba(234,241,250,0.75); margin: 12px 0 0; }
.auth-points { list-style: none; margin: 28px 0 0; padding: 0; display: grid; gap: 14px; }
.auth-points li { display: flex; gap: 12px; align-items: flex-start; background: rgba(255,255,255,0.08); border: 1px solid rgba(255,255,255,0.14); border-radius: 14px; padding: 12px 14px; font-size: 0.9rem; backdrop-filter: blur(8px); }
.auth-points svg { flex-shrink: 0; margin-top: 2px; color: #7dd3fc; }

.auth-card { padding: 44px 42px; display: flex; flex-direction: column; justify-content: center; }
.auth-header { text-align: left; margin-bottom: 26px; }
.auth-title { font-size: 1.9rem; font-weight: 850; letter-spacing: -0.03em; margin: 0 0 6px; }
.auth-subtitle { color: var(--text-muted); margin: 0; }
.auth-form { display: flex; flex-direction: column; gap: 18px; }
.validation-summary { padding: 12px 14px; background: rgba(220,38,38,0.08); border: 1px solid rgba(220,38,38,0.25); border-radius: 12px; font-size: 0.88rem; }
.input-wrapper { position: relative; }
.input-icon { position: absolute; left: 14px; top: 50%; transform: translateY(-50%); color: var(--text-faint); pointer-events: none; }
.input-wrapper .form-control { padding-left: 46px; }
.form-row { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.forgot-link { font-size: 0.87rem; font-weight: 600; }
.auth-submit { width: 100%; padding: 15px 22px; font-size: 1rem; border-radius: 14px; margin-top: 6px; }
.auth-footer { margin-top: 24px; padding-top: 18px; border-top: 1px solid var(--border); }
.auth-note { display: flex; gap: 8px; align-items: center; justify-content: center; color: var(--text-muted); font-size: 0.87rem; margin: 0; }

.auth-illustration, .illustration-shape, .shape-1, .shape-2, .shape-3 { display: none; }

/* Dropdown, modal, misc */
.dropdown-menu { background: var(--surface); border: 1px solid var(--border); border-radius: 14px; box-shadow: var(--shadow); padding: 8px; }
.dropdown-item { color: var(--text-muted); border-radius: 10px; padding: 10px 12px; font-weight: 600; font-size: 0.9rem; }
.dropdown-item:hover { background: var(--surface-2); color: var(--text); }
.modal-content { background: var(--surface); border: 1px solid var(--border); border-radius: 20px; box-shadow: var(--shadow-lg); }
.modal-header, .modal-footer { border-color: var(--border); }
.nav-tabs .nav-link { color: var(--text-muted); border: none; font-weight: 600; }
.nav-tabs .nav-link.active { color: var(--accent); border-bottom: 2px solid var(--accent); background: transparent; }
pre code { font-size: 0.85rem; }
code { background: var(--surface-2); border: 1px solid var(--border); border-radius: 8px; padding: 2px 6px; color: var(--text); }

/* Footer */
.site-footer { border-top: 1px solid var(--border); padding: 28px 0; background: transparent; margin-top: auto; }
.footer-inner { display: flex; align-items: center; justify-content: space-between; gap: 16px; flex-wrap: wrap; width: min(var(--container), 100% - 32px); margin: 0 auto; }
.footer-nav { list-style: none; display: flex; gap: 18px; margin: 0; padding: 0; }
.footer-nav a { color: var(--text-muted); font-size: 0.88rem; font-weight: 600; }
.footer-nav a:hover { color: var(--accent); }
.footer-copy { margin: 0; color: var(--text-faint); font-size: 0.83rem; }

.skip-link { position: absolute; left: -999px; top: auto; background: var(--accent); color: #fff; padding: 10px 16px; border-radius: 10px; z-index: 100; }
.skip-link:focus { left: 16px; top: 16px; }

/* Entrance */
@keyframes rise { from { opacity: 0; transform: translateY(18px); } to { opacity: 1; transform: translateY(0); } }
.auth-container, .page-head, .card { animation: rise 0.5s ease both; }

@media (max-width: 960px) {
  .auth-container { grid-template-columns: 1fr; }
  .auth-brand-panel { min-height: auto; padding: 30px 26px; }
  .auth-card { padding: 30px 24px; }
  .stats-grid, .services-grid { grid-template-columns: 1fr; }
  .site-header { top: 8px; }
  .nav-menu { display: none; }
  .nav-toggle { display: inline-flex; width: 42px; height: 42px; border-radius: 12px; border: 1px solid var(--border); background: var(--surface); flex-direction: column; gap: 5px; align-items: center; justify-content: center; cursor: pointer; }
  .nav-toggle span { display: block; width: 18px; height: 2px; background: var(--text); border-radius: 2px; }
  .nav-menu.open { display: flex; position: absolute; top: calc(100% + 10px); left: 12px; right: 12px; background: var(--surface); border: 1px solid var(--border); border-radius: 16px; flex-direction: column; padding: 10px; box-shadow: var(--shadow); }
  .nav-menu.open a { padding: 12px; }
  .header-inner { flex-wrap: wrap; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; }
  html { scroll-behavior: auto; }
}

@media print {
  .site-header, .site-footer, .btn, .no-print { display: none !important; }
  body { background: #fff; color: #000; }
  .card { box-shadow: none !important; }
}

/* ---------- Validation: hide the summary box when there are no errors ---------- */
.validation-summary-valid { display: none !important; }
.validation-summary ul { margin: 0; padding-left: 18px; }

/* ---------- Bootstrap variant fixes for both themes ---------- */
.table-light {
  --bs-table-bg: var(--surface-2);
  --bs-table-color: var(--text);
  --bs-table-border-color: var(--border);
}
[data-bs-theme="dark"] .btn-close { filter: invert(1) grayscale(1) brightness(1.9); }
.dropdown-divider { border-top-color: var(--border); }
.form-check-label { color: var(--text); }
.modal-title, .card-title, h1, h2, h3, h4, h5 { color: var(--text); }
.table { --bs-table-color: var(--text); --bs-table-border-color: var(--border); }
.form-select option, .form-control option { background: var(--surface); color: var(--text); }

/* Brighter feedback text on dark surfaces for readability */
[data-theme="dark"] .text-danger { color: #f38ba8 !important; }
[data-theme="dark"] .text-warning { color: #f5b04c !important; }
[data-theme="dark"] .text-success { color: #4ade9e !important; }
[data-theme="dark"] .text-info { color: #7dd3fc !important; }
[data-theme="dark"] .form-text { color: var(--text-muted); }
[data-theme="dark"] .table thead th { color: var(--text-muted); }
[data-theme="dark"] .dropdown-item { color: var(--text-muted); }
[data-theme="dark"] .dropdown-item:hover { color: var(--text); }
[data-theme="dark"] .modal-content { color: var(--text); }
[data-theme="dark"] .toast { background: var(--surface); color: var(--text); border: 1px solid var(--border); }
[data-theme="dark"] pre, [data-theme="dark"] code { color: var(--text); }

/* Keep dark text readable on the amber expired banner */
.card-header.bg-warning { color: #1a1206 !important; }

/* Action buttons: keep icon buttons a consistent tap target */
.btn-group .btn { display: inline-flex; align-items: center; justify-content: center; min-width: 34px; }
.btn-group .btn .bi { font-size: 1rem; line-height: 1; }

/* Five-column stat grid for the admin dashboard */
.stats-grid-5 { grid-template-columns: repeat(5, 1fr); }
.stats-grid-5 .stat-card { padding: 22px 14px; }
.stats-grid-5 .stat-number { font-size: 1.7rem; }
@media (max-width: 1100px) { .stats-grid-5 { grid-template-columns: repeat(3, 1fr); } }
@media (max-width: 640px) { .stats-grid-5 { grid-template-columns: repeat(2, 1fr); } }
