:root {
  --vt-violet-950: #000028;
  --vt-violet-900: #000040;
  --vt-violet-800: #00135c;
  --vt-violet-700: #005a9c;
  --vt-violet-600: #0070c0;
  --vt-blue-700: #005a9c;
  --vt-blue-600: #0070c0;
  --vt-blue-500: #1593d1;
  --vt-gold-500: #ff5010;
  --vt-gold-400: #ff6d33;
  --vt-ink: #10182b;
  --vt-muted: #637086;
  --vt-surface: #ffffff;
  --vt-surface-soft: #f5f8fc;
  --vt-border: #dce5ef;
  --vt-success: #198754;
  --vt-danger: #c9364f;
  --vt-radius-sm: 0.65rem;
  --vt-radius: 1rem;
  --vt-radius-lg: 1.4rem;
  --vt-shadow-sm: 0 0.25rem 0.9rem rgba(0, 45, 82, 0.08);
  --vt-shadow: 0 0.8rem 2.5rem rgba(0, 31, 72, 0.13);
  --vt-focus-ring: 0 0 0 0.25rem rgba(0, 112, 192, 0.28);
  --bs-primary: #0070c0;
  --bs-primary-rgb: 0, 112, 192;
  --bs-primary-text-emphasis: #00385f;
  --bs-primary-bg-subtle: #e5f4ff;
  --bs-primary-border-subtle: #acd8f4;
  --bs-link-color: #0063aa;
  --bs-link-hover-color: #004f88;
  --lte-sidebar-width: 17.25rem;
  --lte-sidebar-mini-width: 4.75rem;
}

[data-bs-theme="dark"] {
  --vt-ink: #f2f3f8;
  --vt-muted: #aab2c5;
  --vt-surface: #0d1730;
  --vt-surface-soft: #070d25;
  --vt-border: #283552;
  --vt-shadow-sm: 0 0.25rem 0.9rem rgba(0, 0, 0, 0.24);
  --vt-shadow: 0 0.8rem 2.5rem rgba(0, 0, 0, 0.34);
}

html {
  font-size: 16px;
  min-height: 100%;
  scroll-behavior: smooth;
}

body {
  min-height: 100vh;
  color: var(--vt-ink);
  font-family: Inter, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

a {
  text-underline-offset: 0.18em;
}

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

button,
[role="button"],
a {
  touch-action: manipulation;
}

:focus-visible {
  outline: 0.18rem solid var(--vt-gold-400);
  outline-offset: 0.16rem;
}

.btn:focus-visible,
.form-control:focus,
.form-select:focus,
.form-check-input:focus {
  border-color: var(--bs-primary);
  box-shadow: var(--vt-focus-ring);
}

.min-w-0 {
  min-width: 0;
}

.skip-link {
  position: fixed;
  z-index: 10000;
  top: 0.75rem;
  left: 0.75rem;
  padding: 0.7rem 1rem;
  color: #000040;
  background: var(--vt-gold-400);
  border-radius: var(--vt-radius-sm);
  box-shadow: var(--vt-shadow);
  font-weight: 800;
  transform: translateY(-180%);
  transition: transform 160ms ease;
}

.skip-link:focus {
  color: #000040;
  transform: translateY(0);
}

.app-header {
  min-height: 4.15rem;
  border-bottom: 1px solid color-mix(in srgb, var(--vt-border) 78%, transparent);
  box-shadow: 0 0.2rem 1.25rem rgba(34, 22, 68, 0.06);
}

.app-header .container-fluid {
  min-height: inherit;
  padding-inline: clamp(0.75rem, 2vw, 1.5rem);
}

.app-header-action {
  display: inline-grid;
  width: 2.7rem;
  min-height: 2.7rem;
  place-items: center;
  color: var(--vt-muted);
  border: 0;
  border-radius: 50%;
  background: transparent;
  font-size: 1.18rem;
  transition: color 160ms ease, background-color 160ms ease, transform 160ms ease;
}

.app-header-action:hover,
.app-header-action:focus-visible {
  color: var(--bs-primary);
  background: var(--bs-primary-bg-subtle);
}

.app-header-action:active {
  transform: scale(0.94);
}

.app-header-context {
  color: var(--vt-muted);
  font-size: 0.88rem;
  font-weight: 700;
  letter-spacing: 0.015em;
}

.theme-menu {
  min-width: 11.5rem;
  padding: 0.45rem;
  border: 1px solid var(--vt-border);
  border-radius: 0.9rem;
  box-shadow: var(--vt-shadow);
}

.theme-menu .dropdown-item {
  min-height: 2.65rem;
  border-radius: 0.65rem;
  font-weight: 600;
}

.theme-menu .dropdown-item.active,
.theme-menu .dropdown-item:active {
  color: var(--bs-primary-text-emphasis);
  background: var(--bs-primary-bg-subtle);
}

.profile-toggle {
  min-height: 3rem;
  padding: 0.25rem 0.45rem;
  color: var(--vt-ink);
  border: 0;
  border-radius: 0.85rem;
  background: transparent;
}

.profile-toggle:hover,
.profile-toggle:focus-visible,
.profile-toggle[aria-expanded="true"] {
  color: var(--vt-ink);
  background: var(--vt-surface-soft);
}

.profile-avatar {
  display: inline-grid;
  width: 2.45rem;
  height: 2.45rem;
  flex: 0 0 auto;
  place-items: center;
  color: #fff;
  background: linear-gradient(145deg, var(--vt-violet-600), var(--vt-blue-600));
  border: 2px solid rgba(255, 255, 255, 0.85);
  border-radius: 50%;
  box-shadow: 0 0.25rem 0.75rem rgba(0, 112, 192, 0.24);
}

.profile-avatar-lg {
  width: 3rem;
  height: 3rem;
  font-size: 1.25rem;
}

.profile-name,
.profile-role {
  display: block;
  max-width: 10rem;
  overflow: hidden;
  line-height: 1.15;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.profile-name {
  font-size: 0.86rem;
  font-weight: 750;
}

.profile-role {
  margin-top: 0.18rem;
  color: var(--vt-muted);
  font-size: 0.7rem;
  font-weight: 600;
}

.profile-menu {
  width: min(18rem, calc(100vw - 1rem));
  padding: 0.5rem;
  border: 1px solid var(--vt-border);
  border-radius: 1rem;
  box-shadow: var(--vt-shadow);
}

.profile-menu-header {
  display: flex;
  align-items: center;
  gap: 0.8rem;
  padding: 0.65rem;
}

.profile-menu .dropdown-item {
  min-height: 2.75rem;
  border-radius: 0.65rem;
  font-weight: 600;
}

.vt-sidebar {
  --lte-sidebar-color: rgba(255, 255, 255, 0.8);
  --lte-sidebar-hover-color: #fff;
  --lte-sidebar-menu-active-bg: rgba(255, 255, 255, 0.15);
  --lte-sidebar-menu-active-color: #fff;
  overflow: hidden;
  background:
    radial-gradient(circle at 18% 8%, rgba(0, 112, 192, 0.42), transparent 26rem),
    linear-gradient(168deg, #00005a 0%, #000040 52%, #00122f 100%) !important;
  border-right: 1px solid rgba(255, 255, 255, 0.08);
}

.vt-sidebar::after {
  position: absolute;
  right: -3rem;
  bottom: -4rem;
  width: 12rem;
  height: 12rem;
  content: "";
  background: radial-gradient(circle, rgba(255, 80, 16, 0.2), transparent 68%);
  pointer-events: none;
}

.vt-sidebar .sidebar-brand {
  min-height: 4.15rem;
  padding: 0.55rem 0.75rem;
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
  background: rgba(0, 0, 32, 0.25);
}

.brand-link,
.kiosk-brand,
.monitor-brand {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  min-width: 0;
  color: inherit;
  text-decoration: none;
}

.brand-mark {
  display: inline-grid;
  width: 2.65rem;
  height: 2.65rem;
  flex: 0 0 auto;
  place-items: center;
  color: #000040;
  background: #fff;
  border: 1px solid rgba(255, 255, 255, 0.7);
  border-radius: 0.8rem;
  box-shadow: 0 0.35rem 1.1rem rgba(0, 112, 192, 0.24);
  font-size: 1.25rem;
  transform: none;
}

.brand-logo-frame {
  overflow: hidden;
  padding: 0;
}

.brand-logo {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  transform: scale(1.16);
}

.brand-text {
  display: flex;
  min-width: 0;
  flex-direction: column;
  color: #fff;
  line-height: 1;
}

.brand-text > span {
  font-size: 1.03rem;
  font-weight: 900;
  letter-spacing: 0.08em;
}

.brand-text > small {
  margin-top: 0.25rem;
  color: #ff7a40;
  font-size: 0.66rem;
  font-weight: 800;
  letter-spacing: 0.24em;
}

.vt-sidebar .sidebar-search {
  padding: 1rem 0.8rem 0.4rem;
}

.vt-sidebar .sidebar-search .input-group {
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, 0.14);
  border-radius: 0.75rem;
  background: rgba(255, 255, 255, 0.08);
}

.vt-sidebar .sidebar-search .input-group-text,
.vt-sidebar .sidebar-search .form-control {
  color: #fff;
  border: 0;
  background: transparent;
}

.vt-sidebar .sidebar-search .form-control {
  min-height: 2.4rem;
  padding-left: 0;
}

.vt-sidebar .sidebar-search .form-control::placeholder {
  color: rgba(255, 255, 255, 0.58);
}

.vt-sidebar .sidebar-search .form-control:focus {
  box-shadow: none;
}

.vt-sidebar .sidebar-search .input-group:focus-within {
  border-color: var(--vt-gold-400);
  box-shadow: 0 0 0 0.2rem rgba(255, 80, 16, 0.2);
}

.sidebar-search-empty {
  margin: 0.6rem 0.35rem 0;
  color: rgba(255, 255, 255, 0.65);
  font-size: 0.78rem;
}

.vt-sidebar .sidebar-wrapper {
  padding: 0 0.55rem 5rem;
}

.vt-sidebar .sidebar-menu .nav-header {
  padding: 1.15rem 0.8rem 0.45rem;
  color: rgba(255, 255, 255, 0.48);
  font-size: 0.66rem;
  font-weight: 850;
  letter-spacing: 0.14em;
}

.vt-sidebar .sidebar-menu > .nav-item > .nav-link {
  min-height: 2.95rem;
  margin-block: 0.14rem;
  padding: 0.7rem 0.8rem;
  color: rgba(255, 255, 255, 0.76);
  border: 1px solid transparent;
  border-radius: 0.78rem;
  font-weight: 650;
  transition: color 160ms ease, background-color 160ms ease, border-color 160ms ease, transform 160ms ease;
}

.vt-sidebar .sidebar-menu > .nav-item > .nav-link:hover,
.vt-sidebar .sidebar-menu > .nav-item > .nav-link:focus-visible {
  color: #fff;
  background: rgba(255, 255, 255, 0.09);
  border-color: rgba(255, 255, 255, 0.08);
  transform: translateX(0.12rem);
}

.vt-sidebar .sidebar-menu > .nav-item > .nav-link.active {
  color: #fff;
  background: linear-gradient(100deg, rgba(0, 112, 192, 0.62), rgba(0, 90, 156, 0.4));
  border-color: rgba(255, 255, 255, 0.14);
  box-shadow: inset 0.18rem 0 0 var(--vt-gold-400), 0 0.4rem 1rem rgba(9, 6, 30, 0.18);
}

.vt-sidebar .sidebar-menu .nav-icon {
  color: var(--vt-gold-400);
  font-size: 1.05rem;
}

.sidebar-mini.sidebar-collapse .vt-sidebar .brand-mark {
  margin-inline: auto;
}

.sidebar-mini.sidebar-collapse .vt-sidebar .sidebar-search {
  padding-inline: 0.55rem;
}

.sidebar-mini.sidebar-collapse .vt-sidebar .sidebar-search .form-control,
.sidebar-mini.sidebar-collapse .vt-sidebar .sidebar-search .input-group-text {
  visibility: hidden;
}

.sidebar-mini.sidebar-collapse .vt-sidebar:hover .sidebar-search .form-control,
.sidebar-mini.sidebar-collapse .vt-sidebar:hover .sidebar-search .input-group-text {
  visibility: visible;
}

.app-main {
  background:
    radial-gradient(circle at 92% -4%, rgba(0, 112, 192, 0.11), transparent 24rem),
    var(--vt-surface-soft);
}

.app-main:focus {
  outline: none;
}

.app-content-header {
  padding: clamp(1.15rem, 2.4vw, 1.85rem) 0 0.65rem;
}

.app-content {
  padding: 0 0 clamp(1.5rem, 3vw, 2.5rem);
}

.page-eyebrow {
  color: var(--bs-primary);
  font-size: 0.7rem;
  font-weight: 850;
  letter-spacing: 0.17em;
}

.page-title {
  color: var(--vt-ink);
  font-size: clamp(1.55rem, 2vw, 2rem);
  font-weight: 800;
  letter-spacing: -0.025em;
}

.breadcrumb {
  --bs-breadcrumb-divider: "›";
  color: var(--vt-muted);
  font-size: 0.84rem;
}

.breadcrumb a {
  color: var(--bs-primary);
  font-weight: 650;
  text-decoration: none;
}

.breadcrumb a:hover {
  text-decoration: underline;
}

.app-footer {
  min-height: 3.35rem;
  padding: 0.85rem clamp(0.85rem, 2vw, 1.5rem);
  color: var(--vt-muted);
  border-top: 1px solid var(--vt-border);
  background: color-mix(in srgb, var(--vt-surface) 94%, transparent);
  font-size: 0.78rem;
}

.app-footer strong {
  color: var(--vt-ink);
}

.system-dot {
  display: inline-block;
  width: 0.58rem;
  height: 0.58rem;
  flex: 0 0 auto;
  background: #2fc978;
  border: 2px solid rgba(47, 201, 120, 0.2);
  border-radius: 50%;
  box-shadow: 0 0 0 0.18rem rgba(47, 201, 120, 0.12);
}

.card {
  overflow: hidden;
  border: 1px solid var(--vt-border);
  border-radius: var(--vt-radius);
  box-shadow: var(--vt-shadow-sm);
}

.card-header {
  min-height: 3.6rem;
  padding: 0.9rem 1.1rem;
  border-bottom-color: var(--vt-border);
  background: color-mix(in srgb, var(--vt-surface) 96%, var(--bs-primary-bg-subtle));
}

.card-title {
  font-weight: 750;
}

.btn {
  min-height: 2.65rem;
  border-radius: 0.72rem;
  font-weight: 700;
}

.btn-primary {
  border-color: transparent;
  background: linear-gradient(135deg, var(--vt-violet-600), var(--vt-blue-600));
  box-shadow: 0 0.45rem 1.1rem rgba(0, 112, 192, 0.22);
}

.btn-primary:hover,
.btn-primary:focus-visible {
  border-color: transparent;
  background: linear-gradient(135deg, var(--vt-violet-700), var(--vt-blue-700));
}

.btn-warning {
  color: #000040;
  border-color: var(--vt-gold-500);
  background: linear-gradient(135deg, #ff8a50, var(--vt-gold-500));
}

.btn-outline-primary {
  --bs-btn-color: #0070c0;
  --bs-btn-border-color: #0070c0;
  --bs-btn-hover-bg: #0070c0;
  --bs-btn-hover-border-color: #0070c0;
  --bs-btn-active-bg: #005a9c;
  --bs-btn-active-border-color: #005a9c;
}

.text-bg-primary {
  color: #fff !important;
  background-color: #0070c0 !important;
}

.text-bg-warning {
  color: #000040 !important;
  background-color: #ff7a40 !important;
}

.form-label {
  color: var(--vt-ink);
  font-weight: 700;
}

.form-control,
.form-select,
.input-group-text {
  min-height: 2.75rem;
  border-color: var(--vt-border);
  border-radius: 0.72rem;
}

.form-control::placeholder {
  color: color-mix(in srgb, var(--vt-muted) 78%, transparent);
}

.table {
  --bs-table-color: var(--vt-ink);
  margin-bottom: 0;
}

.table > :not(caption) > * > * {
  padding: 0.85rem 0.9rem;
  border-bottom-color: var(--vt-border);
  vertical-align: middle;
}

.table thead th {
  color: var(--vt-muted);
  background: var(--vt-surface-soft);
  font-size: 0.72rem;
  font-weight: 850;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

div.dt-container .dt-search input,
div.dt-container .dt-length select {
  min-height: 2.45rem;
  border-color: var(--vt-border);
  border-radius: 0.62rem;
}

div.dt-container .dt-paging .dt-paging-button {
  border-radius: 0.55rem !important;
}

div.dt-container .dt-paging .dt-paging-button.current {
  color: #fff !important;
  border-color: transparent !important;
  background: var(--bs-primary) !important;
}

.swal2-popup {
  border: 1px solid var(--vt-border);
  border-radius: 1.25rem;
  box-shadow: 0 1.2rem 4rem rgba(22, 13, 48, 0.25);
}

.swal2-title {
  color: var(--vt-ink);
}

.swal2-confirm,
.swal2-cancel {
  min-height: 2.75rem;
  border-radius: 0.7rem !important;
  font-weight: 750 !important;
}

.status-pill {
  display: inline-flex;
  min-height: 1.75rem;
  align-items: center;
  gap: 0.38rem;
  padding: 0.25rem 0.65rem;
  border-radius: 999px;
  font-size: 0.75rem;
  font-weight: 750;
}

.status-pill-success {
  color: #0d673d;
  background: #d8f5e6;
}

.status-pill-warning {
  color: #78510b;
  background: #fff0c9;
}

.status-pill-danger {
  color: #8e2035;
  background: #fbe0e5;
}

[data-bs-theme="dark"] .status-pill-success {
  color: #8ee0b5;
  background: #123f2b;
}

[data-bs-theme="dark"] .status-pill-warning {
  color: #f7d578;
  background: #4a3512;
}

[data-bs-theme="dark"] .status-pill-danger {
  color: #f2a2b2;
  background: #4c1c27;
}

.empty-state {
  display: grid;
  min-height: 18rem;
  padding: 2rem;
  place-items: center;
  color: var(--vt-muted);
  text-align: center;
}

.empty-state-icon {
  display: inline-grid;
  width: 4.5rem;
  height: 4.5rem;
  margin-bottom: 1rem;
  place-items: center;
  color: var(--bs-primary);
  background: var(--bs-primary-bg-subtle);
  border-radius: 1.25rem;
  font-size: 2rem;
}

@media (max-width: 767.98px) {
  .app-header {
    min-height: 3.75rem;
  }

  .app-content-header {
    padding-top: 1rem;
  }

  .breadcrumb {
    justify-content: flex-start !important;
  }

  .profile-menu {
    position: fixed !important;
    top: 3.65rem !important;
    right: 0.5rem !important;
    left: auto !important;
    transform: none !important;
  }
}

@media (prefers-contrast: more) {
  :root {
    --vt-border: #818899;
    --vt-focus-ring: 0 0 0 0.28rem rgba(255, 190, 35, 0.55);
  }

  .card,
  .form-control,
  .form-select,
  .btn,
  .dropdown-menu {
    border-width: 2px;
  }
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  *,
  *::before,
  *::after {
    scroll-behavior: auto !important;
    transition-duration: 0.01ms !important;
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
  }
}

@media print {
  .skip-link,
  .app-header,
  .app-sidebar,
  .app-footer {
    display: none !important;
  }

  .app-main {
    background: #fff !important;
  }
}
