/* Newton eMobility application theme: app shell in Newton brand colors. */
@font-face { font-family: "Poppins"; font-weight: 400; font-style: normal; font-display: swap; src: url("../fonts/poppins-400.woff2") format("woff2"); }
@font-face { font-family: "Poppins"; font-weight: 500; font-style: normal; font-display: swap; src: url("../fonts/poppins-500.woff2") format("woff2"); }
@font-face { font-family: "Poppins"; font-weight: 600; font-style: normal; font-display: swap; src: url("../fonts/poppins-600.woff2") format("woff2"); }
@font-face { font-family: "Poppins"; font-weight: 700; font-style: normal; font-display: swap; src: url("../fonts/poppins-700.woff2") format("woff2"); }

:root {
  --nev-accent: #28c3f4;
  --nev-accent-dark: #0a7a9f;
  --nev-navy: #0d1b25;
  --nev-ink: #242424;
  --nev-text: #333333;
  --nev-muted: #767676;
  --nev-surface: #ffffff;
  --nev-surface-alt: #f4f6f8;

  --bs-body-font-family: "Poppins", system-ui, -apple-system, "Segoe UI", sans-serif;
  --bs-body-color: var(--nev-text);
  --bs-body-color-rgb: 51, 51, 51;
  --bs-heading-color: var(--nev-ink);
  --bs-primary: #28c3f4;
  --bs-primary-rgb: 40, 195, 244;
  --bs-link-color: var(--nev-accent-dark);
  --bs-link-color-rgb: 10, 122, 159;
  --bs-link-hover-color: var(--nev-navy);
  --bs-link-hover-color-rgb: 13, 27, 37;
}

body { margin-bottom: 0; }

.btn:focus, .btn:active:focus, .btn-link.nav-link:focus, .form-control:focus, .form-check-input:focus {
  box-shadow: 0 0 0 0.1rem #fff, 0 0 0 0.25rem var(--nev-accent-dark);
}

.btn-primary {
  --bs-btn-color: var(--nev-navy); --bs-btn-bg: var(--nev-accent); --bs-btn-border-color: var(--nev-accent);
  --bs-btn-hover-color: #fff; --bs-btn-hover-bg: var(--nev-navy); --bs-btn-hover-border-color: var(--nev-navy);
  --bs-btn-active-color: #fff; --bs-btn-active-bg: var(--nev-navy); --bs-btn-active-border-color: var(--nev-navy);
  --bs-btn-disabled-color: var(--nev-navy); --bs-btn-disabled-bg: var(--nev-accent); --bs-btn-disabled-border-color: var(--nev-accent);
  --bs-btn-focus-shadow-rgb: 40, 195, 244;
  font-weight: 600;
}
.btn-outline-primary {
  --bs-btn-color: var(--nev-accent-dark); --bs-btn-border-color: var(--nev-accent-dark);
  --bs-btn-hover-color: var(--nev-navy); --bs-btn-hover-bg: var(--nev-accent); --bs-btn-hover-border-color: var(--nev-accent);
  --bs-btn-active-color: var(--nev-navy); --bs-btn-active-bg: var(--nev-accent); --bs-btn-active-border-color: var(--nev-accent);
}

.nev-icon { width: 1.5rem; height: 1.5rem; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; flex: none; }

/* Public shell: sign-in, panel picker, access denied, error */
.nev-body { display: flex; flex-direction: column; min-height: 100vh; background: var(--nev-surface-alt); }
.nev-body > main { flex: 1 0 auto; display: flex; flex-direction: column; justify-content: center; }
.nev-header { background: var(--nev-surface); border-bottom: 1px solid #e5e7eb; }
.nev-header .navbar-brand img { display: block; height: 44px; width: auto; }
.nev-footer { background: var(--nev-surface); border-top: 1px solid #e5e7eb; color: var(--nev-muted); font-size: .875rem; }
.nev-auth { padding: 3rem 0; }
.nev-auth__card { background: #fff; border-radius: .75rem; border-top: 4px solid var(--nev-accent); box-shadow: 0 .75rem 2rem rgba(13, 27, 37, .08); padding: 2rem; }

/* Sign-in page only: a faded, low-contrast photo behind the card. The near-opaque tint on top
   (the page's own surface color) keeps the card's contrast unaffected no matter what the photo
   contains, rather than relying on filter/opacity on the image itself. */
.nev-auth--login {
  background-image: linear-gradient(rgba(244, 246, 248, .86), rgba(244, 246, 248, .86)), url("../images/login-bg.jpg");
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
}

/* Panel shell */
.nev-app { background: var(--nev-surface-alt); }
.nev-app-topbar { background: var(--nev-navy); min-height: 64px; }
.nev-app-topbar .navbar-toggler { border-color: rgba(255, 255, 255, .25); }
.nev-app__body { min-height: calc(100vh - 64px); }
.nev-content { background: var(--nev-surface-alt); min-width: 0; }
.nev-page-title { font-size: 1.85rem; font-weight: 700; color: var(--nev-navy); margin-bottom: .15rem; }

.nev-sidebar { background-color: var(--nev-navy) !important; color: #fff; --bs-offcanvas-bg: var(--nev-navy); --bs-offcanvas-color: #fff; border-color: transparent !important; }
.nev-sidebar .offcanvas-header { border-bottom: 1px solid rgba(255, 255, 255, .12); }
.nev-sidebar .nav-link { color: rgba(255, 255, 255, .78); font-weight: 500; }
.nev-sidebar .nav-link:hover, .nev-sidebar .nav-link:focus { color: #fff; }
.nev-sidebar .nav-link.active { background: var(--nev-accent); color: var(--nev-navy); font-weight: 600; }
.nev-sidebar__group { display: flex; align-items: center; gap: .6rem; width: 100%; text-align: left; background: none; border: 0; }
.nev-sidebar__group .nev-icon { width: 1.1rem; height: 1.1rem; color: var(--nev-accent); }
.nev-sidebar__chevron { transition: transform .2s; }
.nev-sidebar__group:not(.collapsed) .nev-sidebar__chevron { transform: rotate(180deg); }
.nev-sidebar__sub { padding: .15rem 0 .35rem 1.6rem; }
.nev-sidebar__sub .nav-link { font-size: .9rem; padding: .4rem .75rem; }
@media (min-width: 992px) {
  .nev-sidebar-collapsed .nev-sidebar { display: none !important; }
}
@media (prefers-reduced-motion: reduce) {
  .nev-sidebar__chevron { transition: none; }
}

/* Module cards (dashboard) */
/* flex, not a fixed grid column: a row with fewer cards than fit simply ends, instead of leaving a
   blank grid slot where a missing card would have been (e.g. a panel with one module left over). */
.nev-module { background: #fff; border-radius: .6rem; box-shadow: 0 .15rem .5rem rgba(13, 27, 37, .1); overflow: hidden; flex: 1 1 280px; max-width: 340px; }
.nev-module__title { display: flex; align-items: center; gap: .6rem; margin: 0; padding: .85rem 1rem; background: var(--nev-navy); color: #fff; font-size: 1rem; font-weight: 600; }
.nev-module__title .nev-icon { width: 1.15rem; height: 1.15rem; color: var(--nev-accent); }
.nev-module__list { list-style: none; margin: 0; padding: 0; }
.nev-module__list > li { border-top: 1px solid #e9edf0; }
.nev-module__list > li:first-child { border-top: 0; }
.nev-module__item { display: flex; align-items: center; justify-content: space-between; gap: .75rem; padding: .75rem 1rem; color: var(--nev-muted); }
.nev-module__link { color: var(--nev-ink); text-decoration: none; font-weight: 500; }
.nev-module__link:hover, .nev-module__link:focus { background: var(--nev-surface-alt); color: var(--nev-accent-dark); }
.nev-module__soon { font-size: .7rem; font-weight: 600; letter-spacing: .04em; text-transform: uppercase; color: var(--nev-accent-dark); background: rgba(40, 195, 244, .14); padding: .15rem .5rem; border-radius: 999px; }

/* Attendance */
.nev-status--present { --bs-btn-active-bg: #198754; --bs-btn-active-border-color: #198754; --bs-btn-active-color: #fff; }
.nev-status--absent { --bs-btn-active-bg: #dc3545; --bs-btn-active-border-color: #dc3545; --bs-btn-active-color: #fff; }
.nev-status--halfday { --bs-btn-active-bg: #fd7e14; --bs-btn-active-border-color: #fd7e14; --bs-btn-active-color: #000; }
.nev-status--paidleave { --bs-btn-active-bg: var(--nev-accent); --bs-btn-active-border-color: var(--nev-accent); --bs-btn-active-color: var(--nev-navy); }
.nev-status--unpaidleave { --bs-btn-active-bg: #6c757d; --bs-btn-active-border-color: #6c757d; --bs-btn-active-color: #fff; }
.btn-check:checked + .nev-status { background: var(--bs-btn-active-bg); border-color: var(--bs-btn-active-border-color); color: var(--bs-btn-active-color); }

.nev-att-table th, .nev-att-table td { white-space: nowrap; padding: .35rem .3rem; }
.nev-att-day { text-align: center; min-width: 1.7rem; font-weight: 500; }
.nev-att { text-align: center; font-size: .8rem; font-weight: 600; }
.nev-att-table .nev-att--present, .nev-legend--present { background: #d1e7dd; color: #0f5132; }
.nev-att-table .nev-att--absent, .nev-legend--absent { background: #f8d7da; color: #842029; }
.nev-att-table .nev-att--halfday, .nev-legend--halfday { background: #ffe5d0; color: #7a3d00; }
.nev-att-table .nev-att--paidleave, .nev-legend--paidleave { background: #cff4fc; color: #055160; }
.nev-att-table .nev-att--unpaidleave, .nev-legend--unpaidleave { background: #e2e3e5; color: #41464b; }
.nev-legend { display: inline-block; min-width: 1.5rem; text-align: center; border-radius: .25rem; font-weight: 600; }

/* Payslip and printing */
.nev-payslip { max-width: 46rem; }
@media print {
  .nev-app-topbar, .nev-sidebar, .nev-no-print, .alert { display: none !important; }
  .nev-content { padding: 0 !important; background: #fff; }
  .nev-payslip { border: 0; box-shadow: none; max-width: none; }
}

/* An empty validation summary (no errors) must not show as a blank alert box. */
.validation-summary-valid { display: none; }
