/* Somatex 5G Logistics–style admin formation */
:root {
  --stx-navy: #0b2341;
  --stx-navy-2: #12325a;
  --stx-blue: #0056b3;
  --stx-blue-deep: #003d80;
  --stx-blue-soft: #e8f1fb;
  --stx-bg: #eef2f7;
  --stx-line: #dbe3ef;
  --stx-text: #0f172a;
  --stx-muted: #64748b;
}

/* -------- Login -------- */
.stx-login-body {
  margin: 0;
  min-height: 100vh;
  background: var(--stx-bg);
  font-family: "Segoe UI", "PingFang SC", "Helvetica Neue", Arial, sans-serif;
  color: var(--stx-text);
}
.stx-login-shell {
  min-height: 100vh;
  display: grid;
  grid-template-columns: 360px 1fr;
}
.stx-login-side {
  background: linear-gradient(180deg, var(--stx-navy) 0%, #07182e 100%);
  color: #fff;
  padding: 36px 28px;
  display: flex;
  flex-direction: column;
}
.stx-login-side h1 {
  font-size: 28px;
  margin: 28px 0 12px;
  line-height: 1.2;
}
.stx-login-side > p {
  color: rgba(255,255,255,0.82);
  font-size: 14px;
  line-height: 1.6;
  margin-bottom: 22px;
}
.stx-login-points {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 10px;
}
.stx-login-points li {
  background: rgba(255,255,255,0.08);
  border: 1px solid rgba(255,255,255,0.1);
  border-radius: 10px;
  padding: 10px 12px;
  font-size: 13px;
}
.stx-login-points li::before {
  content: "✓ ";
  color: #7dd3fc;
  font-weight: 700;
}
.stx-login-foot {
  margin-top: auto;
  padding-top: 24px;
  font-size: 12px;
  color: rgba(255,255,255,0.55);
}
.stx-login-main {
  display: grid;
  place-items: center;
  padding: 32px 20px;
  background:
    radial-gradient(circle at 85% 15%, rgba(0,86,179,0.12), transparent 28%),
    var(--stx-bg);
}
.stx-login-card {
  width: min(440px, 100%);
  background: #fff;
  border: 1px solid var(--stx-line);
  border-radius: 14px;
  box-shadow: 0 10px 30px rgba(11, 35, 65, 0.08);
  padding: 28px;
}
.stx-login-card-head h2 {
  font-size: 22px;
  margin: 0 0 6px;
}
.stx-login-card-head p {
  margin: 0 0 18px;
  color: var(--stx-muted);
  font-size: 13px;
}
.stx-login-btn {
  width: 100%;
  margin-top: 6px;
  padding: 12px 16px;
  border-radius: 10px;
  font-weight: 700;
}
.stx-login-meta {
  margin-top: 18px;
  display: grid;
  gap: 6px;
  font-size: 12px;
  color: var(--stx-muted);
}
.stx-login-meta a {
  color: var(--stx-blue);
  font-weight: 600;
}

.stx-brand {
  display: flex;
  align-items: center;
  gap: 12px;
}
.stx-brand-lg { margin-bottom: 8px; }
.stx-menu-toggle,
.stx-sidebar-close,
.stx-sidebar-backdrop {
  display: none;
}
.stx-brand-mark {
  width: 42px;
  height: 42px;
  border-radius: 10px;
  display: grid;
  place-items: center;
  background: linear-gradient(145deg, #0b6ad4, #0056b3);
  color: #fff;
  font-weight: 800;
  font-size: 20px;
  box-shadow: 0 6px 16px rgba(0,86,179,0.35);
}
.stx-brand-text {
  display: flex;
  flex-direction: column;
  line-height: 1.15;
}
.stx-brand-text strong {
  font-size: 15px;
  letter-spacing: 0.04em;
  color: #fff;
}
.stx-brand-text span {
  font-size: 12px;
  color: rgba(255,255,255,0.72);
}

/* -------- Panel shell -------- */
.stx-admin {
  margin: 0;
  background: var(--stx-bg);
  color: var(--stx-text);
  font-family: "Segoe UI", "PingFang SC", "Helvetica Neue", Arial, sans-serif;
}
.stx-shell {
  display: grid;
  grid-template-columns: 260px 1fr;
  min-height: 100vh;
}
.stx-sidebar {
  background: linear-gradient(180deg, var(--stx-navy) 0%, #07182e 100%);
  color: #fff;
  padding: 18px 0 24px;
  position: sticky;
  top: 0;
  height: 100vh;
  overflow-y: auto;
}
.stx-sidebar .stx-brand {
  padding: 6px 18px 18px;
  border-bottom: 1px solid rgba(255,255,255,0.08);
  margin-bottom: 14px;
}
.stx-nav {
  display: flex;
  flex-direction: column;
  gap: 2px;
  padding: 0 10px;
}
.stx-nav-label {
  margin: 14px 10px 6px;
  font-size: 11px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: rgba(255,255,255,0.45);
  font-weight: 700;
}
.stx-nav a {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 11px 12px;
  border-radius: 10px;
  color: rgba(255,255,255,0.84);
  font-size: 13.5px;
  text-decoration: none;
}
.stx-nav a:hover {
  background: rgba(255,255,255,0.08);
  color: #fff;
}
.stx-nav a.active {
  background: rgba(0, 86, 179, 0.55);
  color: #fff;
  box-shadow: inset 0 0 0 1px rgba(255,255,255,0.08);
}
.stx-nav a.stx-logout { margin-top: 8px; color: #fecaca; }
.stx-ico {
  width: 18px;
  text-align: center;
  opacity: 0.9;
}

.stx-main {
  min-width: 0;
  display: flex;
  flex-direction: column;
}
.stx-topbar {
  background: #fff;
  border-bottom: 1px solid var(--stx-line);
  padding: 10px 18px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  position: sticky;
  top: 0;
  z-index: 20;
}
.stx-topbar-left,
.stx-topbar-right {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}
.stx-chip-label {
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 0.08em;
  color: var(--stx-blue);
  margin-right: 4px;
}
.stx-pill {
  display: inline-flex;
  align-items: center;
  padding: 6px 12px;
  border-radius: 999px;
  background: var(--stx-blue);
  color: #fff;
  font-size: 12px;
  font-weight: 600;
  text-decoration: none;
}
.stx-pill:hover { background: var(--stx-blue-deep); }
.stx-lang {
  border: 1px solid var(--stx-line);
  border-radius: 8px;
  padding: 6px 10px;
  font-size: 12px;
  color: var(--stx-muted);
  background: #fff;
}
.stx-user {
  display: flex;
  align-items: center;
  gap: 10px;
  padding-left: 6px;
}
.stx-avatar {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: linear-gradient(145deg, #0b6ad4, #0056b3);
  color: #fff;
  display: grid;
  place-items: center;
  font-weight: 800;
}
.stx-user-meta {
  display: flex;
  flex-direction: column;
  line-height: 1.2;
}
.stx-user-meta strong { font-size: 13px; }
.stx-user-meta span { font-size: 11px; color: var(--stx-muted); }

.stx-content {
  padding: 20px;
  flex: 1;
}
.stx-footer {
  text-align: center;
  padding: 14px 20px 20px;
  color: var(--stx-muted);
  font-size: 12px;
}

/* Cards / stats in logistics style */
.stx-admin .admin-top h1 { font-size: 22px; }
.stx-admin .stats {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 14px;
}
.stx-admin .stat-card {
  background: #fff;
  border: 1px solid var(--stx-line);
  border-radius: 12px;
  overflow: hidden;
  padding: 0;
  box-shadow: 0 4px 14px rgba(11, 35, 65, 0.04);
}
.stx-admin .stat-card .label {
  background: var(--stx-blue);
  color: #fff;
  font-size: 12px;
  font-weight: 700;
  padding: 8px 12px;
}
.stx-admin .stat-card .value {
  font-size: 28px;
  font-weight: 800;
  color: var(--stx-navy);
  padding: 14px 12px 16px;
}
.stx-admin .action-card,
.stx-admin .panel,
.stx-admin .table-wrap {
  border: 1px solid var(--stx-line);
  border-radius: 12px;
  box-shadow: 0 4px 14px rgba(11, 35, 65, 0.04);
}
.stx-admin .btn-primary {
  background: var(--stx-blue);
  border-radius: 10px;
}
.stx-admin .btn-primary:hover { background: var(--stx-blue-deep); }
.stx-admin .data-table th {
  background: #f5f8fc;
  color: var(--stx-muted);
}

@media (max-width: 980px) {
  .stx-login-shell { grid-template-columns: 1fr; }
  .stx-login-side { padding-bottom: 28px; }
  .stx-admin .stats { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .stx-topbar-left .stx-pill:nth-child(n+4) { display: none; }

  /* Mobile admin panel — desktop layout unchanged above */
  .stx-shell { grid-template-columns: 1fr; }
  .stx-menu-toggle {
    display: inline-flex;
    width: 38px;
    height: 38px;
    border: 1px solid var(--stx-line);
    border-radius: 8px;
    background: #fff;
    color: var(--stx-blue);
    font-size: 18px;
    align-items: center;
    justify-content: center;
    cursor: pointer;
  }
  .stx-sidebar-close {
    display: inline-flex;
    margin-left: auto;
    width: 34px;
    height: 34px;
    border: 0;
    border-radius: 8px;
    background: rgba(255,255,255,0.1);
    color: #fff;
    cursor: pointer;
  }
  .stx-sidebar-backdrop {
    display: block;
    position: fixed;
    inset: 0;
    background: rgba(7, 24, 46, 0.45);
    z-index: 40;
  }
  .stx-sidebar-backdrop[hidden] { display: none; }
  .stx-sidebar {
    position: fixed;
    top: 0;
    left: 0;
    width: min(280px, 86vw);
    height: 100vh;
    z-index: 50;
    transform: translateX(-105%);
    transition: transform 0.2s ease;
  }
  .stx-shell.sidebar-open .stx-sidebar { transform: translateX(0); }
  .stx-content { padding: 14px; }
  .stx-topbar { padding: 10px 12px; }
  .stx-admin .action-grid { grid-template-columns: 1fr; }
  .stx-admin .admin-top { align-items: flex-start; }
  .stx-admin .admin-top h1 { font-size: 20px; }
  .stx-admin .data-table { min-width: 560px; }
}
@media (max-width: 640px) {
  .stx-admin .stats { grid-template-columns: 1fr; }
  .stx-user-meta { display: none; }
  .stx-lang { display: none; }
  .stx-topbar-left .stx-pill { display: none; }
  .stx-chip-label { display: none; }
  .stx-login-card { padding: 20px; }
  .stx-login-side { padding: 24px 18px; }
  .stx-login-side h1 { font-size: 24px; }
}
