:root {
  --ink: #17212f;
  --muted: #647083;
  --line: #dce5ea;
  --surface: rgba(255,255,255,.94);
  --app-bg: #edf4f2;
  --primary: #0b6b5b;
  --primary-dark: #06493f;
  --primary-soft: #e1f2ee;
  --accent: #bd8b2f;
  --accent-soft: #fff3d8;
  --danger: #b42318;
  --sidebar-w: 320px;
  --shadow-sm: 0 8px 22px rgba(25, 45, 70, .08);
  --shadow-md: 0 16px 42px rgba(20, 42, 67, .14);
}

* {
  letter-spacing: 0;
}

body {
  min-height: 100vh;
  font-family: "IBM Plex Sans Arabic", "Tahoma", "Arial", sans-serif;
  background:
    linear-gradient(135deg, rgba(11,107,91,.08) 0 25%, transparent 25% 50%, rgba(189,139,47,.08) 50% 75%, transparent 75%) 0 0 / 44px 44px,
    radial-gradient(circle at 1px 1px, rgba(14, 76, 68, .13) 1px, transparent 0) 0 0 / 22px 22px,
    linear-gradient(180deg, #f8fbfa 0%, var(--app-bg) 100%);
  color: var(--ink);
}

h1,
h2,
h3,
h4,
h5,
h6,
.brand-block h5,
.student-hero-content h1,
.student-pane-head h2,
.entry-portal-brand h1,
.student-access-header h1,
.warehouse-login-card h1 {
  font-family: "Tajawal", "IBM Plex Sans Arabic", "Tahoma", sans-serif;
}

body::before {
  content: "";
  position: fixed;
  inset: 0;
  z-index: -1;
  background:
    linear-gradient(90deg, transparent 0 48%, rgba(11,107,91,.04) 48% 52%, transparent 52%),
    linear-gradient(0deg, transparent 0 48%, rgba(189,139,47,.04) 48% 52%, transparent 52%);
  background-size: 96px 96px;
  opacity: .65;
}

.auth-main {
  min-height: 100vh;
  display: block;
  padding: 0;
  overflow: hidden;
}

.app-main {
  min-height: 100vh;
  padding: 28px;
  margin-right: var(--sidebar-w);
  transition: margin .24s ease, padding .24s ease;
}

body.sidebar-collapsed .app-main {
  margin-right: 0;
}

.sidebar {
  position: fixed;
  inset-block: 0;
  right: 0;
  z-index: 1040;
  width: var(--sidebar-w);
  box-sizing: border-box;
  padding: 18px;
  color: #fff;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  height: 100vh;
  height: 100dvh;
  background:
    linear-gradient(145deg, rgba(4,51,48,.98), rgba(20,55,78,.98)),
    #12364b;
  box-shadow: -18px 0 40px rgba(12, 35, 54, .18);
  transition: transform .24s ease;
}

.sidebar * {
  box-sizing: border-box;
}

body.sidebar-collapsed .sidebar {
  transform: translateX(104%);
}

.sidebar-pattern {
  position: absolute;
  inset: 0;
  pointer-events: none;
  opacity: .24;
  background:
    linear-gradient(45deg, transparent 44%, rgba(255,255,255,.28) 45% 55%, transparent 56%),
    linear-gradient(-45deg, transparent 44%, rgba(255,255,255,.18) 45% 55%, transparent 56%);
  background-size: 34px 34px;
}

.brand-block,
.sidebar-nav,
.sidebar-user,
.logout-link {
  position: relative;
  z-index: 1;
}

.brand-block {
  flex: 0 0 auto;
  display: grid;
  grid-template-columns: 46px 1fr;
  gap: 10px;
  align-items: center;
  padding-bottom: 18px;
  margin-bottom: 14px;
  border-bottom: 1px solid rgba(255,255,255,.16);
}

.brand-block > div:last-child {
  min-width: 0;
}

.brand-block h5 {
  font-weight: 800;
  font-size: 1rem;
  line-height: 1.35;
  margin: 0;
  white-space: normal;
}

.brand-block small {
  color: rgba(255,255,255,.68);
  line-height: 1.35;
  white-space: normal;
}

.brand-mark {
  width: 46px;
  height: 46px;
  display: grid;
  place-items: center;
  border-radius: 8px;
  background: linear-gradient(135deg, var(--accent), #e0bd6a);
  color: #122d35;
  font-size: 1.4rem;
  box-shadow: 0 10px 22px rgba(0,0,0,.2);
}

.sidebar-rail-toggle {
  border: 0;
  display: grid;
  place-items: center;
  color: #fff;
}

.sidebar-rail-toggle {
  position: fixed;
  top: 18px;
  right: calc(var(--sidebar-w) - 17px);
  z-index: 1050;
  width: 38px;
  height: 38px;
  border-radius: 8px 0 0 8px;
  background: linear-gradient(135deg, var(--primary), var(--primary-dark));
  box-shadow: var(--shadow-md);
  transition: right .24s ease, transform .18s ease;
}

.sidebar-rail-toggle:hover {
  transform: translateX(-2px);
}

body.sidebar-collapsed .sidebar-rail-toggle {
  right: 0;
}

.sidebar-nav {
  flex: 1 1 auto;
  min-height: 0;
  flex-wrap: nowrap !important;
  align-content: stretch;
  gap: 4px;
  overflow-y: auto;
  overflow-x: hidden;
  margin-block: 2px;
  padding-inline-end: 6px;
  padding-inline-start: 2px;
  padding-bottom: 8px;
  scrollbar-width: thin;
  scrollbar-color: rgba(255,255,255,.38) transparent;
  overscroll-behavior: contain;
  touch-action: pan-y;
  -webkit-overflow-scrolling: touch;
}

.sidebar-nav-hint {
  position: relative;
  z-index: 1;
  display: flex;
  align-items: center;
  gap: 7px;
  padding: 0 7px 7px;
  color: rgba(255,255,255,.68);
  font-size: .72rem;
}
.sidebar-nav-hint span { font-weight: 700; color: rgba(255,255,255,.84); }
.sidebar-nav-hint small { margin-inline-start:auto; color:rgba(255,255,255,.52); }
.sidebar-nav-hint button {
  flex: 0 0 auto;
  width: 24px;
  height: 24px;
  display: grid;
  place-items: center;
  padding: 0;
  border: 1px solid rgba(255,255,255,.18);
  border-radius: 5px;
  color: #f8e8ba;
  background: rgba(255,255,255,.08);
}
.sidebar-nav-hint button:hover, .sidebar-nav-hint button:focus { background:rgba(255,255,255,.18); color:#fff; }

.sidebar-presence {
  position: relative;
  z-index: 1;
  display: grid;
  gap: 7px;
  margin: 0 16px 12px;
  padding: 10px;
  border: 1px solid rgba(255, 255, 255, .12);
  border-radius: 10px;
  background: rgba(255, 255, 255, .07);
}

.presence-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  color: rgba(255, 255, 255, .82);
  font-size: .78rem;
}

.presence-item span { display: flex; align-items: center; gap: 7px; }
.presence-item strong {
  min-width: 28px;
  padding: 2px 7px;
  border-radius: 999px;
  color: #fff;
  background: rgba(255, 255, 255, .14);
  text-align: center;
}
.presence-item--online i { color: #61e6a6; }
.presence-item--online strong { background: #16875f; }
.sidebar .sidebar-presence .presence-link,
.sidebar .sidebar-presence .presence-link:visited {
  display: flex;
  align-items: center;
  gap: 7px;
  margin-top: 3px;
  padding: 9px 10px;
  border: 1px solid rgba(240, 208, 132, .32);
  border-radius: 8px;
  color: #f8e8ba;
  background: rgba(240, 208, 132, .09);
  font-size: .78rem;
  font-weight: 700;
  text-decoration: none;
  line-height: 1.35;
  transition: background .18s ease, border-color .18s ease, transform .18s ease;
}
.sidebar .sidebar-presence .presence-link span { flex: 1; color: inherit; text-decoration: none; }
.sidebar .sidebar-presence .presence-link > i:first-child { color: #f0d084; font-size: .95rem; }
.sidebar .sidebar-presence .presence-link > i:last-child { color: rgba(255,255,255,.65); font-size: .7rem; }
.sidebar .sidebar-presence .presence-link:hover,
.sidebar .sidebar-presence .presence-link:focus {
  color: #fff;
  border-color: rgba(240, 208, 132, .6);
  background: rgba(240, 208, 132, .17);
  text-decoration: none;
  transform: translateX(-2px);
}

.sidebar-nav::-webkit-scrollbar {
  width: 7px;
}

.sidebar-nav::-webkit-scrollbar-track {
  background: transparent;
}

.sidebar-nav::-webkit-scrollbar-thumb {
  background: rgba(240,208,132,.62);
  border-radius: 999px;
}

.sidebar-nav::-webkit-scrollbar-thumb:hover {
  background: rgba(255,255,255,.52);
}

.sidebar .nav-link {
  display: flex;
  align-items: center;
  gap: 12px;
  width: 100%;
  min-height: 40px;
  color: rgba(255,255,255,.84);
  border: 1px solid transparent;
  border-radius: 8px;
  font-weight: 700;
  padding: 8px 10px;
  line-height: 1.35;
  white-space: normal;
  overflow: visible;
}

.sidebar .nav-link i {
  flex: 0 0 25px;
  width: 25px;
  height: 25px;
  display: grid;
  place-items: center;
  color: #f0d084;
  font-size: 1.05rem;
}

.sidebar .nav-link span {
  flex: 1 1 auto;
  min-width: 0;
  overflow-wrap: anywhere;
}
.sidebar .nav-link--sub { margin-inline-start:12px; width:calc(100% - 12px); font-size:.88rem; background:rgba(255,255,255,.035); }
.sidebar .nav-link--sub i { font-size:.9rem; }

.sidebar .nav-link:hover,
.sidebar .nav-link:focus,
.sidebar .nav-link.active {
  background: rgba(255,255,255,.13);
  border-color: rgba(255,255,255,.16);
  color: #fff;
}

.sidebar-user {
  flex: 0 0 auto;
  display: flex;
  gap: 10px;
  align-items: center;
  padding: 12px;
  margin-top: 12px;
  border: 1px solid rgba(255,255,255,.14);
  border-radius: 8px;
  background: rgba(255,255,255,.08);
}

.sidebar-user > div:last-child {
  min-width: 0;
}

.sidebar-user strong,
.sidebar-user small {
  display: block;
  overflow-wrap: anywhere;
  line-height: 1.35;
}

.sidebar-user small {
  color: rgba(255,255,255,.66);
}

.user-avatar {
  width: 36px;
  height: 36px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  background: rgba(255,255,255,.16);
}

.logout-link {
  flex: 0 0 auto;
  display: flex;
  align-items: center;
  gap: 9px;
  margin-top: 8px;
  padding: 9px 12px;
  color: #fff;
  text-decoration: none;
  border-radius: 8px;
  background: rgba(180, 35, 24, .32);
}

.logout-link span {
  min-width: 0;
  overflow-wrap: anywhere;
}

.logout-link:hover {
  color: #fff;
  background: rgba(180, 35, 24, .48);
}

.flash-stack {
  max-width: 980px;
}

.app-footer {
  margin-top: 28px;
  padding: 14px 18px;
  text-align: center;
  color: rgba(52, 64, 84, .78);
  font-weight: 700;
  font-size: .92rem;
}

.auth-main .app-footer {
  position: fixed;
  left: 0;
  right: 0;
  bottom: 10px;
  z-index: 3;
  margin: 0;
  color: rgba(237,247,255,.82);
  text-shadow: 0 1px 8px rgba(0,0,0,.5);
}

.stat-card,
.panel,
.table-wrap {
  background: var(--surface);
  border: 1px solid rgba(210, 224, 230, .9);
  border-radius: 8px;
  box-shadow: var(--shadow-sm);
  backdrop-filter: blur(10px);
}

.stat-card {
  position: relative;
  overflow: hidden;
  padding: 20px;
  border-top: 4px solid var(--primary);
}

.stat-card::after {
  content: "";
  position: absolute;
  inset-inline-start: 14px;
  inset-block-start: 14px;
  width: 58px;
  height: 58px;
  border: 1px solid rgba(189,139,47,.28);
  transform: rotate(45deg);
}

.stat-card:nth-child(2n),
.row > .col-md-4:nth-child(2) .stat-card {
  border-top-color: var(--accent);
}

.stat-label {
  color: var(--muted);
  font-size: .9rem;
  font-weight: 700;
}

.stat-value {
  font-size: 1.9rem;
  font-weight: 800;
  color: var(--primary-dark);
}

.dashboard-stat {
  min-height: 132px;
}

.dashboard-stat .stat-icon {
  position: absolute;
  inset-inline-start: 18px;
  inset-block-start: 16px;
  width: 42px;
  height: 42px;
  display: grid;
  place-items: center;
  border-radius: 8px;
  color: var(--primary);
  background: var(--primary-soft);
  font-size: 1.35rem;
}

.accent-stat {
  border-top-color: var(--accent);
}

.accent-stat .stat-icon {
  color: #8a5d00;
  background: var(--accent-soft);
}

.danger-stat {
  border-top-color: var(--danger);
}

.danger-stat .stat-icon {
  color: var(--danger);
  background: #fee4e2;
}

.chart-panel {
  height: 100%;
  background: var(--surface);
  border: 1px solid rgba(210, 224, 230, .9);
  border-radius: 8px;
  box-shadow: var(--shadow-sm);
  padding: 18px;
  backdrop-filter: blur(10px);
}

.chart-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 14px;
}

.chart-head h5 {
  margin: 0;
  font-weight: 800;
  color: var(--ink);
}

.chart-head span {
  color: var(--muted);
  font-size: .9rem;
}

.chart-head > i {
  width: 38px;
  height: 38px;
  display: grid;
  place-items: center;
  border-radius: 8px;
  color: var(--primary);
  background: var(--primary-soft);
  font-size: 1.2rem;
  flex: 0 0 auto;
}

.chart-box {
  position: relative;
  height: 270px;
}

.chart-box-lg {
  height: 340px;
}

.ltr-field,
.ltr-field input,
.ltr-field textarea {
  direction: ltr;
  text-align: left;
  font-family: Consolas, "Courier New", monospace;
}

.panel,
.table-wrap {
  padding: 18px;
}

.table {
  --bs-table-bg: transparent;
  --bs-table-hover-bg: rgba(11,107,91,.05);
}

.table thead th {
  color: #344054;
  font-weight: 800;
  border-bottom-color: #cfdbe2;
}

.form-control,
.form-select {
  border-color: #cdd8df;
  border-radius: 8px;
  min-height: 42px;
}

.form-control:focus,
.form-select:focus {
  border-color: var(--primary);
  box-shadow: 0 0 0 .2rem rgba(11,107,91,.14);
}

.btn {
  border-radius: 8px;
  font-weight: 800;
}

.btn-primary {
  --bs-btn-bg: var(--primary);
  --bs-btn-border-color: var(--primary);
  --bs-btn-hover-bg: var(--primary-dark);
  --bs-btn-hover-border-color: var(--primary-dark);
  box-shadow: 0 8px 16px rgba(11,107,91,.16);
}

.btn-outline-primary {
  --bs-btn-color: var(--primary);
  --bs-btn-border-color: rgba(11,107,91,.45);
  --bs-btn-hover-bg: var(--primary);
  --bs-btn-hover-border-color: var(--primary);
}

.btn-outline-secondary {
  --bs-btn-color: #344054;
  --bs-btn-border-color: #b8c4cc;
}

.btn-outline-danger {
  --bs-btn-color: var(--danger);
  --bs-btn-border-color: rgba(180,35,24,.38);
}

.nav-tabs {
  border-bottom: 1px solid #cfdbe2;
  gap: 6px;
}

.nav-tabs .nav-link {
  border-radius: 8px 8px 0 0;
  color: #344054;
  font-weight: 800;
}

.nav-tabs .nav-link.active {
  color: var(--primary-dark);
  border-color: #cfdbe2 #cfdbe2 var(--surface);
  background: var(--surface);
}

.badge-low {
  background: var(--accent-soft);
  color: #835b08;
  border: 1px solid #f0cf7a;
}

.code-img {
  max-width: 220px;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 10px;
}

.logo-preview {
  width: 92px;
  height: 92px;
  object-fit: contain;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 8px;
}

.place-items-center {
  place-items: center;
}

.login-shell {
  position: relative;
  min-height: 100vh;
  display: grid;
  grid-template-columns: minmax(0, 1.1fr) minmax(360px, 460px);
  align-items: center;
  gap: 44px;
  padding: 48px clamp(22px, 5vw, 78px);
  overflow: hidden;
}

.login-shell::before {
  content: "";
  position: absolute;
  inset: 28px;
  border: 1px solid rgba(11,107,91,.16);
  border-radius: 8px;
  pointer-events: none;
}

.login-ornament {
  position: absolute;
  width: 240px;
  height: 240px;
  opacity: .28;
  pointer-events: none;
  background:
    linear-gradient(45deg, transparent 43%, rgba(11,107,91,.32) 44% 56%, transparent 57%),
    linear-gradient(-45deg, transparent 43%, rgba(189,139,47,.26) 44% 56%, transparent 57%);
  background-size: 32px 32px;
  transform: rotate(45deg);
}

.login-ornament-a {
  inset-block-start: -68px;
  inset-inline-end: -42px;
}

.login-ornament-b {
  inset-block-end: -84px;
  inset-inline-start: -58px;
}

.login-brand-panel,
.login-card {
  position: relative;
  z-index: 1;
}

.login-brand-panel {
  max-width: 720px;
  color: var(--ink);
}

.login-brand-top {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 18px;
  margin-bottom: 22px;
  text-align: center;
}

.login-logo {
  width: 118px;
  height: 118px;
  object-fit: contain;
  flex: 0 0 auto;
  padding: 6px;
  border-radius: 8px;
  background: rgba(255,255,255,.18);
  border: 1px solid rgba(255,255,255,.34);
  box-shadow: 0 18px 42px rgba(20, 42, 67, .12);
  backdrop-filter: blur(4px);
}

.login-logo-placeholder {
  display: grid;
  place-items: center;
  color: var(--primary);
  font-size: 2rem;
}

.login-kicker {
  display: inline-flex;
  align-items: center;
  color: var(--primary-dark);
  background: var(--primary-soft);
  border: 1px solid rgba(11,107,91,.16);
  border-radius: 999px;
  padding: 5px 12px;
  font-weight: 800;
  font-size: .86rem;
  margin-bottom: 10px;
}

.login-brand-panel h1 {
  margin: 0;
  font-size: clamp(2rem, 5vw, 4.2rem);
  font-weight: 800;
  line-height: 1.12;
  color: #122f38;
}

.login-lead {
  max-width: 650px;
  color: #4b5b68;
  font-size: clamp(1rem, 1.5vw, 1.18rem);
  line-height: 1.9;
  margin-bottom: 22px;
}

.login-address {
  display: inline-flex;
  gap: 8px;
  align-items: center;
  padding: 10px 14px;
  background: rgba(255,255,255,.72);
  border: 1px solid rgba(210,224,230,.9);
  border-radius: 8px;
  color: #344054;
  box-shadow: var(--shadow-sm);
  margin-bottom: 22px;
}

.login-metrics {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
  max-width: 650px;
}

.login-metrics div {
  min-height: 118px;
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 4px;
  padding: 16px;
  border-radius: 8px;
  background: rgba(255,255,255,.78);
  border: 1px solid rgba(210,224,230,.88);
  box-shadow: var(--shadow-sm);
}

.login-metrics i {
  color: var(--accent);
  font-size: 1.4rem;
}

.login-metrics strong {
  font-size: 1.05rem;
  color: var(--primary-dark);
}

.login-metrics span {
  color: var(--muted);
  font-size: .88rem;
}

.login-card {
  padding: 30px;
  border-radius: 8px;
  background:
    linear-gradient(180deg, rgba(255,255,255,.96), rgba(255,255,255,.88)),
    var(--surface);
  border: 1px solid rgba(255,255,255,.8);
  box-shadow: 0 24px 70px rgba(20, 42, 67, .2);
  backdrop-filter: blur(16px);
}

.login-card::before {
  content: "";
  position: absolute;
  inset-inline: 24px;
  inset-block-start: 0;
  height: 4px;
  border-radius: 0 0 8px 8px;
  background: linear-gradient(90deg, var(--primary), var(--accent));
}

.login-card-header {
  display: flex;
  gap: 14px;
  align-items: center;
  margin-bottom: 24px;
}

.login-icon {
  width: 52px;
  height: 52px;
  display: grid;
  place-items: center;
  border-radius: 8px;
  color: #fff;
  font-size: 1.45rem;
  background: linear-gradient(135deg, var(--primary), var(--primary-dark));
  box-shadow: 0 12px 24px rgba(11,107,91,.2);
}

.login-card h2 {
  margin: 0;
  font-size: 1.5rem;
  font-weight: 800;
}

.login-card p {
  margin: 4px 0 0;
  color: var(--muted);
}

.login-form .form-label {
  font-weight: 800;
  color: #344054;
  margin-bottom: 8px;
}

.login-input {
  position: relative;
  margin-bottom: 18px;
}

.login-input > i {
  position: absolute;
  inset-inline-start: 14px;
  top: 50%;
  transform: translateY(-50%);
  color: var(--primary);
  z-index: 2;
}

.login-input .form-control {
  min-height: 52px;
  padding-inline-start: 44px;
  padding-inline-end: 46px;
  background: rgba(255,255,255,.9);
}

.password-toggle {
  position: absolute;
  inset-inline-end: 8px;
  top: 50%;
  transform: translateY(-50%);
  width: 36px;
  height: 36px;
  display: grid;
  place-items: center;
  border: 0;
  border-radius: 8px;
  color: var(--muted);
  background: transparent;
}

.password-toggle:hover {
  background: var(--primary-soft);
  color: var(--primary);
}

.login-submit {
  min-height: 52px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 9px;
  margin-top: 4px;
}

.login-demo {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin-top: 18px;
  padding: 12px 14px;
  border-radius: 8px;
  background: var(--accent-soft);
  border: 1px solid rgba(189,139,47,.22);
  color: #6f4c05;
}

.login-demo span {
  font-weight: 700;
}

.login-demo strong {
  direction: ltr;
  font-weight: 800;
}

.warehouse-login {
  position: relative;
  min-height: 100vh;
  display: grid;
  place-items: center;
  overflow: hidden;
  isolation: isolate;
  background: #050b12;
}

.warehouse-bg {
  position: absolute;
  inset: 0;
  z-index: -4;
  overflow: hidden;
  background:
    radial-gradient(ellipse at center, rgba(0,24,48,.08) 0 18%, rgba(0,0,0,.22) 48%, rgba(0,0,0,.82) 100%),
    url("../img/warehouse-login-bg.png") center / cover no-repeat,
    linear-gradient(180deg, #111a20, #05080c 76%);
}

.warehouse-bg::before {
  content: "";
  position: absolute;
  inset: -12px;
  background:
    linear-gradient(90deg, rgba(0,0,0,.86) 0 13%, transparent 33% 67%, rgba(0,0,0,.86) 87% 100%),
    radial-gradient(ellipse at center, transparent 0 23%, rgba(0,0,0,.16) 48%, rgba(0,0,0,.76) 100%);
  filter: none;
  opacity: 1;
}

.warehouse-bg::after {
  content: "";
  position: absolute;
  inset: 0;
  background:
    linear-gradient(180deg, rgba(5,12,22,.18), rgba(0,0,0,.6)),
    radial-gradient(ellipse at center, transparent 0 26%, rgba(0,0,0,.20) 46%, rgba(0,0,0,.78) 94%),
    linear-gradient(90deg, rgba(255,255,255,.08), transparent 28% 72%, rgba(255,255,255,.08));
}

.rack {
  position: absolute;
  top: -8%;
  bottom: -10%;
  width: 42%;
  opacity: .7;
  filter: blur(1.4px);
  transform-origin: center bottom;
  background:
    repeating-linear-gradient(0deg, rgba(255,190,60,.72) 0 7px, transparent 7px 82px),
    repeating-linear-gradient(90deg, rgba(26,100,164,.84) 0 8px, transparent 8px 68px),
    linear-gradient(180deg, rgba(235,235,220,.34), rgba(120,82,39,.1));
  display: none;
}

.rack-left {
  left: 0;
  clip-path: polygon(0 0, 82% 0, 52% 100%, 0 100%);
}

.rack-right {
  right: 0;
  clip-path: polygon(18% 0, 100% 0, 100% 100%, 48% 100%);
}

.forklift-glow {
  position: absolute;
  right: 66%;
  bottom: 12%;
  width: 170px;
  height: 230px;
  opacity: .18;
  background:
    radial-gradient(circle at 72% 70%, rgba(255,182,62,.75), transparent 35%),
    linear-gradient(90deg, transparent 0 28%, rgba(255,160,36,.72) 28% 72%, transparent 72%);
  filter: blur(8px);
}

.login-network {
  position: absolute;
  inset: 0;
  z-index: 0;
  pointer-events: none;
}

.net-line {
  position: absolute;
  height: 2px;
  background: linear-gradient(90deg, rgba(255,255,255,.02), rgba(255,255,255,.54), rgba(255,255,255,.02));
  box-shadow: 0 0 10px rgba(255,255,255,.24);
  transform-origin: center;
}

.line-1 { width: 520px; top: 20%; right: 8%; transform: rotate(167deg); }
.line-2 { width: 470px; top: 35%; right: 2%; transform: rotate(28deg); }
.line-3 { width: 560px; top: 61%; right: 6%; transform: rotate(-18deg); }
.line-4 { width: 520px; top: 36%; left: 4%; transform: rotate(-24deg); }
.line-5 { width: 460px; top: 68%; left: 8%; transform: rotate(17deg); }
.line-6 { width: 610px; top: 50%; left: 19%; transform: rotate(148deg); }

.net-node {
  position: absolute;
  width: clamp(76px, 8vw, 132px);
  height: clamp(76px, 8vw, 132px);
  display: grid;
  place-items: center;
  border-radius: 50%;
  background:
    radial-gradient(circle at 35% 30%, rgba(255,255,255,.66) 0 42%, rgba(238,246,255,.36) 62%, rgba(255,255,255,.22) 72%);
  border: 3px solid rgba(255,255,255,.58);
  outline: 3px solid rgba(0,79,157,.34);
  color: rgba(0,79,157,.86);
  font-size: clamp(2rem, 4vw, 4.2rem);
  box-shadow: 0 12px 36px rgba(0,0,0,.28), inset 0 0 0 2px rgba(255,255,255,.18);
  backdrop-filter: blur(6px) saturate(115%);
}

.node-warehouse { top: 32%; right: 7%; }
.node-search { top: 12%; right: 29%; }
.node-supplier { top: 26%; left: 25%; width: clamp(62px, 6vw, 96px); height: clamp(62px, 6vw, 96px); font-size: clamp(1.5rem, 3vw, 3rem); }
.node-transfer { top: 38%; left: 5%; }
.node-qr { top: 54%; left: 21%; width: clamp(112px, 11vw, 174px); height: clamp(112px, 11vw, 174px); }
.node-forklift { bottom: 4%; right: 38%; }
.node-doc { bottom: 11%; left: 3%; width: clamp(62px, 6vw, 94px); height: clamp(62px, 6vw, 94px); font-size: clamp(1.5rem, 3vw, 3rem); }

.warehouse-login-card {
  position: relative;
  z-index: 2;
  width: min(440px, calc(100vw - 34px));
  padding: 24px 30px 28px;
  text-align: center;
  border-radius: 8px;
  background:
    linear-gradient(180deg, rgba(239,247,252,.20), rgba(224,237,248,.08)),
    rgba(255,255,255,.055);
  border: 1px solid rgba(255,255,255,.24);
  box-shadow: 0 22px 70px rgba(0,0,0,.26), inset 0 1px 0 rgba(255,255,255,.16);
  backdrop-filter: blur(6px) saturate(108%);
}

.warehouse-login-card::before {
  content: "";
  position: absolute;
  inset: 8px;
  border-radius: 8px;
  border: 1px solid rgba(255,255,255,.10);
  pointer-events: none;
}

.warehouse-login-card::after {
  content: "";
  position: absolute;
  inset-inline: 30px;
  top: -2px;
  height: 4px;
  border-radius: 0 0 8px 8px;
  background: linear-gradient(90deg, rgba(0,93,168,.30), rgba(105,184,255,.36), rgba(0,93,168,.30));
  box-shadow: 0 0 14px rgba(61,156,237,.16);
}

.warehouse-login-logo {
  width: 92px;
  height: 92px;
  object-fit: contain;
  display: block;
  margin: -4px auto 8px;
  padding: 4px;
  background: rgba(255,255,255,.10);
  border-radius: 8px;
  filter: drop-shadow(0 14px 24px rgba(0,0,0,.24));
}

.warehouse-login-card h1 {
  margin: 0 0 8px;
  color: #edf7ff;
  font-size: clamp(1.55rem, 2.5vw, 2.25rem);
  font-weight: 800;
  letter-spacing: 0;
  text-shadow: 0 2px 12px rgba(0,0,0,.62), 0 0 24px rgba(24,122,214,.38);
}

.warehouse-login-subtitle {
  margin: 0 0 12px;
  color: rgba(237,247,255,.86);
  text-shadow: 0 1px 9px rgba(0,0,0,.42);
  font-weight: 800;
}

.warehouse-login-form {
  position: relative;
  z-index: 1;
}

.warehouse-login-tabs {
  position: relative;
  z-index: 1;
  width: 100%;
  margin: 8px 0 14px;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
}

.warehouse-login-tabs .nav-item,
.warehouse-login-tabs .nav-link {
  width: 100%;
}

.warehouse-login-tabs .nav-link {
  border: 1px solid rgba(255,255,255,.24);
  color: rgba(255,255,255,.82);
  font-weight: 800;
  min-height: 42px;
}

.warehouse-login-tabs .nav-link.active {
  background: #fff;
  color: #0b6b5b;
}

.warehouse-input {
  position: relative;
  margin-bottom: 11px;
}

.warehouse-input input {
  width: 100%;
  height: 48px;
  border-radius: 8px;
  border: 1px solid rgba(255,255,255,.46);
  background: rgba(255,255,255,.46);
  box-shadow: inset 0 2px 5px rgba(0,0,0,.07), 0 6px 14px rgba(0,42,82,.08);
  color: #082f58;
  font-size: .98rem;
  font-weight: 700;
  padding: 0 48px 0 54px;
  outline: none;
}

.warehouse-input input::placeholder {
  color: rgba(0,54,105,.68);
}

.warehouse-input input:focus {
  border-color: #006fbd;
  box-shadow: 0 0 0 .2rem rgba(0,91,166,.18), inset 0 2px 5px rgba(0,0,0,.06);
}

.warehouse-input > i {
  position: absolute;
  top: 50%;
  inset-inline-end: 16px;
  transform: translateY(-50%);
  color: rgba(0,76,149,.82);
  font-size: 1.32rem;
}

.warehouse-password-toggle {
  position: absolute;
  top: 50%;
  inset-inline-start: 10px;
  transform: translateY(-50%);
  width: 36px;
  height: 36px;
  display: grid;
  place-items: center;
  border: 0;
  border-radius: 8px;
  background: transparent;
  color: rgba(0,76,149,.82);
}

.warehouse-remember {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  width: 100%;
  color: rgba(237,247,255,.92);
  text-shadow: 0 1px 8px rgba(0,0,0,.46);
  font-size: .98rem;
  font-weight: 800;
  margin: 2px 0 12px;
  text-align: right;
}

.warehouse-remember input {
  width: 18px;
  height: 18px;
  accent-color: #005da8;
}

.warehouse-login-button {
  width: 100%;
  height: 54px;
  border: 1px solid rgba(255,255,255,.48);
  border-radius: 8px;
  background: linear-gradient(180deg, rgba(0,137,223,.68), rgba(0,80,148,.64) 82%);
  color: #fff;
  font-size: 1.35rem;
  font-weight: 800;
  box-shadow: 0 10px 22px rgba(0,63,120,.26), inset 0 1px 0 rgba(255,255,255,.22);
  backdrop-filter: blur(4px);
}

.warehouse-login-button:hover {
  background: linear-gradient(180deg, rgba(0,146,235,.90), rgba(0,74,136,.86));
}

.warehouse-secondary-link {
  color: rgba(255,255,255,.82);
  display: block;
  font-weight: 700;
  margin-top: 12px;
  text-align: center;
  text-decoration: none;
}

.warehouse-secondary-link:hover {
  color: #fff;
}

.entry-portal,
.student-access {
  min-height: 100vh;
  padding: 28px;
  display: grid;
  place-items: center;
}

.entry-portal-panel,
.student-access-header,
.student-access-card {
  border: 1px solid rgba(11,107,91,.14);
  border-radius: 8px;
  background: rgba(255,255,255,.94);
  box-shadow: var(--shadow-md);
}

.entry-portal-panel {
  width: min(960px, 100%);
  padding: 28px;
}

.entry-portal-brand {
  text-align: center;
  margin-bottom: 22px;
}

.entry-portal-mark {
  width: 64px;
  height: 64px;
  border-radius: 8px;
  display: inline-grid;
  place-items: center;
  color: #122d35;
  background: linear-gradient(135deg, var(--accent), #e0bd6a);
  font-size: 1.9rem;
  margin-bottom: 12px;
}

.entry-portal-brand span,
.student-access-header span {
  color: var(--primary);
  font-weight: 800;
}

.entry-portal-brand h1,
.student-access-header h1 {
  font-weight: 800;
  margin: 6px 0;
}

.entry-portal-brand p,
.student-access-header p {
  color: var(--muted);
  margin: 0;
}

.entry-portal-grid,
.student-access-grid {
  display: grid;
  gap: 16px;
}

.entry-portal-grid {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.entry-card {
  min-height: 190px;
  border: 1px solid #dce5ea;
  border-radius: 8px;
  color: var(--ink);
  display: flex;
  flex-direction: column;
  gap: 10px;
  justify-content: center;
  padding: 22px;
  text-align: center;
  text-decoration: none;
  background: #fff;
}

.entry-card:hover {
  border-color: rgba(11,107,91,.35);
  color: var(--ink);
  transform: translateY(-1px);
  box-shadow: var(--shadow-sm);
}

.entry-card i {
  color: var(--primary);
  font-size: 2.4rem;
}

.entry-card strong {
  font-size: 1.25rem;
  font-weight: 800;
}

.entry-card span {
  color: var(--muted);
}

.student-access {
  align-content: center;
}

.student-access-header {
  width: min(1040px, 100%);
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 18px;
  margin-bottom: 16px;
}

.student-access-header img {
  width: 68px;
  height: 68px;
  border-radius: 8px;
  object-fit: contain;
  background: #fff;
  border: 1px solid #dce5ea;
}

.student-access-grid {
  width: min(1040px, 100%);
  grid-template-columns: .75fr 1.25fr;
  align-items: start;
}

.student-access-card {
  padding: 18px;
}

.student-access-card h2 {
  font-size: 1.15rem;
  font-weight: 800;
  margin-bottom: 14px;
}

.student-access-pro {
  min-height: 100vh;
  padding: 28px;
  display: grid;
  place-items: center;
  background:
    linear-gradient(135deg, rgba(11,107,91,.12) 0 24%, transparent 24% 50%, rgba(189,139,47,.13) 50% 74%, transparent 74%) 0 0 / 54px 54px,
    radial-gradient(circle at 84% 14%, rgba(11,107,91,.22), transparent 28%),
    linear-gradient(135deg, #f7fbfa 0%, #e8f2f0 100%);
}

.student-access-shell {
  width: min(1180px, 100%);
  display: grid;
  grid-template-columns: minmax(0, .95fr) minmax(420px, 1.05fr);
  min-height: 680px;
  border: 1px solid rgba(11,107,91,.18);
  border-radius: 8px;
  overflow: hidden;
  background: rgba(255,255,255,.76);
  box-shadow: 0 28px 70px rgba(18,54,75,.18);
}

.student-access-hero {
  position: relative;
  min-height: 100%;
  color: #fff;
  padding: 24px;
  display: flex;
  flex-direction: column;
  background:
    linear-gradient(145deg, rgba(5,58,52,.96), rgba(18,54,75,.96)),
    #12364b;
  isolation: isolate;
}

.student-access-hero::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  opacity: .22;
  background:
    linear-gradient(45deg, transparent 44%, rgba(255,255,255,.24) 45% 55%, transparent 56%),
    linear-gradient(-45deg, transparent 44%, rgba(255,255,255,.16) 45% 55%, transparent 56%);
  background-size: 38px 38px;
}

.student-access-topbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 48px;
}

.student-back-link,
.student-secure {
  min-height: 38px;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  border-radius: 8px;
  padding: 8px 10px;
  font-weight: 800;
}

.student-back-link {
  color: #fff;
  text-decoration: none;
  background: rgba(255,255,255,.1);
  border: 1px solid rgba(255,255,255,.16);
}

.student-back-link:hover {
  color: #fff;
  background: rgba(255,255,255,.16);
}

.student-secure {
  color: #ffe2a4;
  border: 1px solid rgba(255,226,164,.26);
  background: rgba(189,139,47,.16);
  white-space: nowrap;
}

.student-hero-content {
  margin-top: auto;
}

.student-brand-lockup {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 22px;
}

.student-brand-lockup img,
.student-brand-lockup > span {
  width: 58px;
  height: 58px;
  flex: 0 0 58px;
  border-radius: 8px;
  display: grid;
  place-items: center;
  object-fit: contain;
  background: #fff;
  color: var(--primary);
  font-size: 1.6rem;
  border: 1px solid rgba(255,255,255,.3);
}

.student-brand-lockup small,
.student-brand-lockup strong {
  display: block;
}

.student-brand-lockup small {
  color: rgba(255,255,255,.68);
  font-weight: 700;
}

.student-brand-lockup strong {
  font-size: 1rem;
  font-weight: 700;
}

.student-hero-content h1 {
  max-width: 560px;
  margin: 0 0 14px;
  font-size: clamp(1.95rem, 3.4vw, 3.1rem);
  font-weight: 700;
  line-height: 1.28;
  letter-spacing: 0;
}

.student-hero-content p {
  max-width: 560px;
  color: rgba(255,255,255,.76);
  font-size: .98rem;
  font-weight: 500;
  line-height: 1.8;
  margin: 0 0 24px;
}

.student-flow {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
}

.student-flow > div {
  min-height: 118px;
  border: 1px solid rgba(255,255,255,.14);
  border-radius: 8px;
  background: rgba(255,255,255,.09);
  padding: 14px;
}

.student-flow i {
  color: #f1c66e;
  font-size: 1.35rem;
}

.student-flow span,
.student-flow strong {
  display: block;
}

.student-flow span {
  color: rgba(255,255,255,.62);
  font-size: .84rem;
  font-weight: 600;
  margin-top: 10px;
}

.student-flow strong {
  margin-top: 2px;
  line-height: 1.45;
  font-weight: 700;
}

.student-access-workspace {
  padding: 24px;
  display: flex;
  flex-direction: column;
  justify-content: center;
  background:
    linear-gradient(180deg, rgba(255,255,255,.96), rgba(248,252,251,.96));
}

.student-access-tabs {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
  padding: 6px;
  border-radius: 8px;
  background: #edf4f2;
  border: 1px solid #dce8e5;
  margin-bottom: 18px;
}

.student-access-tabs button {
  min-height: 46px;
  border: 0;
  border-radius: 8px;
  background: transparent;
  color: #516172;
  font-weight: 700;
}

.student-access-tabs button.active {
  background: #fff;
  color: var(--primary);
  box-shadow: 0 8px 18px rgba(18,54,75,.08);
}

.student-access-pane {
  display: none;
}

.student-access-pane.active {
  display: block;
}

.student-pane-head {
  margin-bottom: 16px;
}

.student-pane-head h2 {
  margin: 0 0 4px;
  font-weight: 700;
  font-size: 1.35rem;
}

.student-pane-head p {
  color: var(--muted);
  margin: 0;
}

.student-modern-form {
  display: grid;
  gap: 14px;
}

.student-form-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
}

.student-modern-form label {
  display: grid;
  gap: 7px;
}

.student-modern-form label > span {
  color: #344152;
  font-weight: 700;
  font-size: .9rem;
}

.student-field {
  min-height: 52px;
  display: flex;
  align-items: center;
  gap: 10px;
  border: 1px solid #d5e1e6;
  border-radius: 8px;
  background: #fff;
  padding: 0 12px;
}

.student-field:focus-within {
  border-color: rgba(11,107,91,.6);
  box-shadow: 0 0 0 4px rgba(11,107,91,.1);
}

.student-field i {
  color: var(--primary);
  flex: 0 0 auto;
}

.student-field input {
  width: 100%;
  border: 0;
  outline: 0;
  background: transparent;
  color: var(--ink);
  font: inherit;
  min-width: 0;
}

.student-primary-action {
  min-height: 54px;
  border: 0;
  border-radius: 8px;
  background: linear-gradient(135deg, var(--primary), var(--primary-dark));
  color: #fff;
  font-weight: 700;
  box-shadow: 0 12px 26px rgba(11,107,91,.22);
}

.student-primary-action:hover {
  filter: brightness(1.05);
}

.admin-access-pro {
  min-height: 100vh;
  padding: 28px;
  display: grid;
  place-items: center;
  background:
    linear-gradient(135deg, rgba(18,54,75,.12) 0 24%, transparent 24% 50%, rgba(189,139,47,.13) 50% 74%, transparent 74%) 0 0 / 54px 54px,
    radial-gradient(circle at 18% 12%, rgba(18,54,75,.24), transparent 30%),
    linear-gradient(135deg, #f8fbfa 0%, #e7f0f2 100%);
}

.admin-access-shell {
  width: min(1180px, 100%);
  min-height: 680px;
  display: grid;
  grid-template-columns: minmax(0, .95fr) minmax(420px, 1.05fr);
  border: 1px solid rgba(18,54,75,.18);
  border-radius: 8px;
  overflow: hidden;
  background: rgba(255,255,255,.78);
  box-shadow: 0 28px 70px rgba(18,54,75,.18);
}

.admin-access-hero {
  position: relative;
  min-height: 100%;
  color: #fff;
  padding: 24px;
  display: flex;
  flex-direction: column;
  background:
    linear-gradient(145deg, rgba(12,38,56,.97), rgba(5,58,52,.96)),
    #12364b;
  isolation: isolate;
}

.admin-access-hero::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  opacity: .22;
  background:
    linear-gradient(45deg, transparent 44%, rgba(255,255,255,.24) 45% 55%, transparent 56%),
    linear-gradient(-45deg, transparent 44%, rgba(255,255,255,.15) 45% 55%, transparent 56%);
  background-size: 38px 38px;
}

.admin-access-workspace {
  padding: 28px;
  display: flex;
  flex-direction: column;
  justify-content: center;
  background: linear-gradient(180deg, rgba(255,255,255,.97), rgba(248,252,251,.97));
}

.admin-modern-form {
  margin-top: 18px;
}

.admin-password-toggle {
  flex: 0 0 40px;
  width: 40px;
  height: 40px;
  border: 0;
  border-radius: 8px;
  background: #eef5f4;
  color: var(--primary);
}

.admin-primary-action {
  background: linear-gradient(135deg, #12364b, var(--primary));
}

.admin-access-note {
  display: grid;
  grid-template-columns: auto 1fr auto;
  gap: 10px;
  align-items: center;
  margin-top: 18px;
  padding: 12px;
  border: 1px solid #dbe8e5;
  border-radius: 8px;
  background: #f3f8f7;
  color: #526477;
  font-weight: 600;
}

.admin-access-note i {
  color: var(--primary);
}

.admin-access-note a {
  color: var(--primary);
  font-weight: 800;
  text-decoration: none;
  white-space: nowrap;
}

.portal-pro {
  min-height: 100vh;
  padding: 28px;
  display: grid;
  place-items: center;
  background:
    linear-gradient(135deg, rgba(11,107,91,.1) 0 24%, transparent 24% 50%, rgba(18,54,75,.11) 50% 74%, transparent 74%) 0 0 / 54px 54px,
    radial-gradient(circle at 78% 16%, rgba(189,139,47,.22), transparent 28%),
    linear-gradient(135deg, #f8fbfa 0%, #e7f0f2 100%);
}

.portal-shell {
  width: min(1180px, 100%);
  min-height: 680px;
  display: grid;
  grid-template-columns: minmax(0, .95fr) minmax(420px, 1.05fr);
  border: 1px solid rgba(11,107,91,.18);
  border-radius: 8px;
  overflow: hidden;
  background: rgba(255,255,255,.78);
  box-shadow: 0 28px 70px rgba(18,54,75,.18);
}

.portal-hero {
  position: relative;
  min-height: 100%;
  color: #fff;
  padding: 24px;
  display: flex;
  flex-direction: column;
  background:
    linear-gradient(145deg, rgba(5,58,52,.96), rgba(12,38,56,.97)),
    #12364b;
  isolation: isolate;
}

.portal-hero::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  opacity: .22;
  background:
    linear-gradient(45deg, transparent 44%, rgba(255,255,255,.24) 45% 55%, transparent 56%),
    linear-gradient(-45deg, transparent 44%, rgba(255,255,255,.14) 45% 55%, transparent 56%);
  background-size: 38px 38px;
}

.portal-topline {
  display: flex;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 48px;
}

.portal-topline span {
  min-height: 38px;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  border-radius: 8px;
  padding: 8px 10px;
  color: #ffe2a4;
  background: rgba(189,139,47,.16);
  border: 1px solid rgba(255,226,164,.26);
  font-weight: 700;
}

.portal-workspace {
  padding: 28px;
  display: flex;
  flex-direction: column;
  justify-content: center;
  background: linear-gradient(180deg, rgba(255,255,255,.97), rgba(248,252,251,.97));
}

.portal-action-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 14px;
  margin-top: 18px;
}

.portal-action-card {
  position: relative;
  min-height: 158px;
  display: grid;
  grid-template-columns: 62px 1fr;
  gap: 12px;
  align-items: center;
  border: 1px solid #dce8e5;
  border-radius: 8px;
  background: #fff;
  color: var(--ink);
  padding: 18px;
  text-decoration: none;
  box-shadow: 0 10px 22px rgba(18,54,75,.06);
}

.portal-action-card:hover {
  color: var(--ink);
  border-color: rgba(11,107,91,.34);
  transform: translateY(-1px);
  box-shadow: 0 16px 32px rgba(18,54,75,.1);
}

.portal-action-card > div {
  width: 58px;
  height: 58px;
  display: grid;
  place-items: center;
  border-radius: 8px;
  color: #fff;
  font-size: 1.55rem;
  background: linear-gradient(135deg, var(--primary), var(--primary-dark));
}

.portal-action-card strong,
.portal-action-card span,
.portal-action-card em {
  grid-column: 2;
}

.portal-action-card strong {
  font-size: 1.12rem;
  font-weight: 700;
  align-self: end;
}

.portal-action-card span {
  color: var(--muted);
  line-height: 1.65;
  align-self: start;
}

.portal-action-card em {
  justify-self: start;
  align-self: end;
  font-style: normal;
  color: var(--primary);
  font-weight: 800;
}

.portal-action-student > div {
  background: linear-gradient(135deg, #bd8b2f, #d3ad62);
  color: #112b31;
}

.portal-note {
  display: flex;
  gap: 10px;
  align-items: center;
  margin-top: 18px;
  padding: 12px;
  border-radius: 8px;
  border: 1px solid #dbe8e5;
  background: #f3f8f7;
  color: #526477;
  font-weight: 600;
}

.portal-note i {
  color: var(--primary);
}

body.auth-screen::before {
  display: none;
}

@media (max-width: 991.98px) {
  .app-main {
    margin-right: 0;
    padding: 78px 14px 20px;
  }
  body {
    background:
      linear-gradient(180deg, #f8fbfa 0%, var(--app-bg) 100%);
  }
  body::before {
    opacity: .28;
    background-size: 72px 72px;
  }
  .sidebar {
    width: min(var(--sidebar-w), calc(100vw - 58px));
    transform: translateX(104%);
    padding: 16px 14px;
  }
  body.sidebar-open .sidebar {
    transform: translateX(0);
  }
  body.sidebar-open .sidebar-overlay {
    opacity: 1;
    pointer-events: auto;
  }
  .sidebar-rail-toggle,
  body.sidebar-collapsed .sidebar-rail-toggle {
    right: 14px;
    top: 16px;
    border-radius: 8px;
  }
  .sidebar-overlay {
    position: fixed;
    inset: 0;
    z-index: 1030;
    background: rgba(16, 24, 40, .42);
    opacity: 0;
    pointer-events: none;
    transition: opacity .2s ease;
  }
  .brand-block {
    grid-template-columns: 42px 1fr;
    gap: 9px;
    margin-bottom: 10px;
    padding-bottom: 14px;
  }
  .brand-mark {
    width: 42px;
    height: 42px;
  }
  .sidebar .nav-link {
    min-height: 42px;
    padding: 9px 10px;
  }
  .sidebar-user {
    margin-top: 14px;
    padding: 12px;
  }
  .flash-stack {
    max-width: none;
  }
  .alert {
    border-radius: 8px;
  }
  .alert-info form {
    width: 100%;
  }
  .alert-info .form-select {
    width: 100%;
  }
  .panel,
  .table-wrap,
  .chart-panel,
  .stat-card {
    padding: 14px;
  }
  .table-wrap {
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
  }
  .table-wrap .table {
    min-width: 720px;
    margin-bottom: 0;
  }
  .table th,
  .table td {
    white-space: nowrap;
  }
  .table td:first-child,
  .table th:first-child {
    position: sticky;
    right: 0;
    z-index: 1;
    background: rgba(255,255,255,.96);
    box-shadow: -1px 0 0 rgba(207,219,226,.8);
  }
  .d-flex.justify-content-between.align-items-center,
  .d-flex.justify-content-between.mb-3,
  .d-flex.justify-content-between.align-items-center.mb-3 {
    align-items: stretch !important;
    flex-direction: column;
    gap: 10px;
  }
  .d-flex.justify-content-between.align-items-center > .btn,
  .d-flex.justify-content-between.align-items-center > a.btn,
  .d-flex.justify-content-between.mb-3 .btn,
  .d-flex.justify-content-between.mb-3 a.btn {
    width: 100%;
  }
  h2 {
    font-size: 1.45rem;
    line-height: 1.35;
  }
  h3 {
    font-size: 1.25rem;
  }
  .form-control,
  .form-select,
  .btn {
    min-height: 44px;
  }
  .input-group {
    flex-wrap: nowrap;
  }
  .input-group > .btn,
  .input-group > label.btn {
    flex: 0 0 auto;
  }
  .nav-tabs {
    display: flex;
    flex-wrap: nowrap;
    overflow-x: auto;
    overflow-y: hidden;
    padding-bottom: 2px;
    -webkit-overflow-scrolling: touch;
  }
  .nav-tabs .nav-item {
    flex: 0 0 auto;
  }
  .nav-tabs .nav-link {
    white-space: nowrap;
  }
  .app-footer {
    font-size: .78rem;
    line-height: 1.55;
    padding: 12px 8px;
  }
  .login-shell {
    grid-template-columns: 1fr;
    gap: 22px;
    padding: 24px;
  }
  .login-shell::before {
    inset: 12px;
  }
  .login-brand-panel {
    text-align: center;
  }
  .login-brand-top {
    justify-content: center;
  }
  .login-metrics {
    grid-template-columns: 1fr;
  }
  .login-card {
    padding: 22px;
  }
  .warehouse-login {
    padding: 20px;
  }
  .warehouse-login-card {
    padding: 24px 20px;
  }
  .warehouse-login-card h1 {
    font-size: 2rem;
  }
  .warehouse-login-logo {
    width: 92px;
    height: 92px;
  }
  .net-line {
    opacity: .36;
  }
  .net-node {
    opacity: .72;
    transform: scale(.76);
  }
  .node-search,
  .node-supplier,
  .node-doc {
    display: none;
  }
  .node-warehouse { top: 7%; right: 4%; }
  .node-transfer { top: 10%; left: 3%; }
  .node-qr { bottom: 3%; left: 5%; top: auto; }
  .node-forklift { bottom: 4%; right: 6%; }
  .line-1,
  .line-2,
  .line-4,
  .line-6 {
    display: none;
  }
  .entry-portal,
  .student-access {
    padding: 18px 12px;
  }
  .entry-portal-grid,
  .student-access-grid {
    grid-template-columns: 1fr;
  }
  .student-access-header {
    align-items: flex-start;
    flex-direction: column;
  }
  .student-access-pro {
    padding: 14px;
    place-items: start center;
  }
  .admin-access-pro {
    padding: 14px;
    place-items: start center;
  }
  .portal-pro {
    padding: 14px;
    place-items: start center;
  }
  .student-access-shell {
    grid-template-columns: 1fr;
    min-height: auto;
  }
  .admin-access-shell {
    grid-template-columns: 1fr;
    min-height: auto;
  }
  .portal-shell {
    grid-template-columns: 1fr;
    min-height: auto;
  }
  .student-access-hero {
    min-height: auto;
    padding: 18px;
  }
  .admin-access-hero {
    min-height: auto;
    padding: 18px;
  }
  .portal-hero {
    min-height: auto;
    padding: 18px;
  }
  .student-access-topbar {
    align-items: flex-start;
    flex-direction: column;
    margin-bottom: 26px;
  }
  .student-hero-content h1 {
    font-size: 1.8rem;
  }
  .student-flow {
    grid-template-columns: 1fr;
  }
  .student-flow > div {
    min-height: auto;
  }
  .student-access-workspace {
    padding: 16px;
  }
  .admin-access-workspace {
    padding: 16px;
  }
  .portal-workspace {
    padding: 16px;
  }
  .student-form-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 575.98px) {
  .app-main {
    padding: 72px 10px 16px;
  }
  .sidebar {
    width: calc(100vw - 44px);
  }
  .sidebar-rail-toggle,
  body.sidebar-collapsed .sidebar-rail-toggle {
    right: 10px;
    top: 12px;
    width: 42px;
    height: 42px;
  }
  .panel,
  .table-wrap,
  .chart-panel,
  .stat-card {
    padding: 12px;
  }
  .row.g-3 {
    --bs-gutter-y: .75rem;
  }
  .btn,
  .form-control,
  .form-select {
    font-size: .95rem;
  }
  .btn:not(.btn-sm) {
    width: 100%;
  }
  .btn-sm {
    min-height: 36px;
    padding: .35rem .55rem;
  }
  .chart-box,
  .chart-box-lg {
    height: 240px;
  }
  .stat-value {
    font-size: 1.55rem;
  }
  .code-img {
    max-width: 100%;
  }
  .login-shell {
    padding: 16px 12px 72px;
  }
  .login-card {
    padding: 18px;
  }
  .student-access-pro {
    padding: 10px;
  }
  .admin-access-pro {
    padding: 10px;
  }
  .portal-pro {
    padding: 10px;
  }
  .student-access-tabs {
    grid-template-columns: 1fr;
  }
  .student-brand-lockup {
    align-items: flex-start;
  }
  .student-secure,
  .student-back-link {
    width: 100%;
    justify-content: center;
  }
  .admin-access-note {
    grid-template-columns: 1fr;
    text-align: center;
  }
  .portal-topline {
    flex-direction: column;
  }
  .portal-topline span,
  .portal-note {
    justify-content: center;
    text-align: center;
  }
  .portal-action-card {
    grid-template-columns: 1fr;
    text-align: center;
  }
  .portal-action-card > div,
  .portal-action-card em {
    justify-self: center;
  }
  .portal-action-card strong,
  .portal-action-card span,
  .portal-action-card em {
    grid-column: 1;
  }
}

@media print {
  .no-print,
  .sidebar,
  .sidebar-rail-toggle,
  .sidebar-overlay {
    display: none !important;
  }
  body {
    background: #fff;
  }
  body::before {
    display: none;
  }
  .app-main,
  main {
    width: 100% !important;
    margin: 0 !important;
    padding: 0 !important;
  }
  .panel {
    border: 0;
    box-shadow: none;
    padding: 0 !important;
  }
  .print-code-block {
    display: flex !important;
    align-items: center !important;
    gap: 14px;
    break-inside: avoid;
  }
  .print-code-block .col-md-3,
  .print-code-block .col-md-4,
  .print-code-block .col-md-5 {
    width: auto !important;
    flex: 0 0 auto !important;
  }
  .code-img {
    max-width: 145px;
    border: 1px solid #999;
    padding: 6px;
  }
}
