/* GLOBAL DESIGN SYSTEM & THEME VARIABLES */

.app-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  background-color: #363434;
  padding: 0.75rem 1.5rem;
  border-bottom: 1px solid #e2e8f0;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.02);
  position: sticky;
  top: 0;
  z-index: 1000;
}

.brand-logo {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  text-decoration: none;
  color: #1e293b;
}

.brand-logo .logo-img {
  height: 32px;
  width: auto;
  object-fit: contain;
}

.brand-logo h1 {
  font-size: 1.25rem;
  font-weight: 700;
  margin: 0;
  color: #f5f6f8;
}

.brand-subtitle {
  font-size: 0.875rem;
  font-weight: 400;
  color: #eff1f3;
}

/* Nav Wrapper */
.nav-wrapper {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex: 1;
  margin-left: 2rem;
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  margin-left: auto;
}

.nav-link,
.dropdown-btn {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.5rem 0.875rem;
  border-radius: 0.375rem;
  color: #475569;
  font-weight: 500;
  font-size: 0.9rem;
  text-decoration: none;
  background: transparent;
  border: none;
  cursor: pointer;
  transition: all 0.2s ease;
}

.nav-link:hover,
.dropdown-btn:hover,
.nav-link.active,
.dropdown-btn.active {
  background-color: #1f3942;
  color: #f2f4f8;
}

/* Dropdowns */
.nav-dropdown,
.user-profile {
  position: relative;
}

.dropdown-menu {
  display: none;
  position: absolute;
  top: 100%;
  left: 0;
  margin-top: 0.5rem;
  background-color: #ffffff;
  border: 1px solid #e2e8f0;
  border-radius: 0.5rem;
  box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.1);
  min-width: 220px;
  z-index: 1010;
  padding: 0.5rem 0;
}

.profile-menu {
  left: auto;
  right: 0;
}

.nav-dropdown:hover .dropdown-menu,
.nav-dropdown:focus-within .dropdown-menu {
  display: block;
}

.dropdown-item {
  display: flex;
  align-items: center;
  gap: 0.625rem;
  padding: 0.625rem 1rem;
  color: #334155;
  font-size: 0.875rem;
  text-decoration: none;
  background: none;
  border: none;
  width: 100%;
  text-align: left;
  cursor: pointer;
}

.dropdown-item:hover {
  background-color: #1a5964;
  color:  #3983ac;
}

.dropdown-divider {
  height: 1px;
  background-color: #0c4d5d;
  margin: 0.5rem 0;
}

/* User Profile */
.user-profile .profile-btn {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  background: none;
  border: none;
  cursor: pointer;
  padding: 0.25rem 0.5rem;
  border-radius: 9999px;
}

.user-profile .profile-btn:hover {
  background-color: #19646c;
}

.avatar-circle {
  width: 32px;
  height: 32px;
  background-color:  #3983ac;
  color: #ffffff;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 600;
  font-size: 0.875rem;
}

.profile-name {
  font-size: 0.875rem;
  font-weight: 500;
  color: #1e293b;
}

.dropdown-header {
  padding: 0.75rem 1rem;
  border-bottom: 1px solid #e2e8f0;
  margin-bottom: 0.25rem;
}

.user-fullname {
  font-weight: 600;
  color: #0f172a;
  font-size: 0.875rem;
}

.user-email {
  font-size: 0.75rem;
  color: #64748b;
}

/* Mobile Toggle Button */
.mobile-toggle-btn {
  display: none;
  background: none;
  border: none;
  font-size: 1.25rem;
  color: white;
  cursor: pointer;
  padding: 0.5rem;
}

.mobile-toggle-btn .icon-close {
  display: none;
}

.mobile-toggle-btn.active .icon-open {
  display: none;
}

.mobile-toggle-btn.active .icon-close {
  display: block;
}

.mobile-overlay {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(15, 23, 42, 0.4);
  backdrop-filter: blur(2px);
  z-index: 990;
}

/* RESPONSIVE MEDIA QUERIES */

@media (max-width: 1024px) {
  .brand-subtitle {
    display: none; 
  }
}

@media (max-width: 991px) {
  .mobile-toggle-btn {
    display: block;
  }

  .mobile-overlay.active {
    display: block;
  }

  .nav-wrapper {
    position: fixed;
    top: 61px; 
    right: -100%;
    width: 280px;
    height: calc(100vh - 61px);
    background-color: #0f3b3e;
    flex-direction: column;
    justify-content: flex-start;
    align-items: stretch;
    padding: 1.5rem 1rem;
    gap: 1.5rem;
    margin-left: 0;
    box-shadow: -4px 0 12px rgba(0, 0, 0, 0.05);
    transition: right 0.3s ease-in-out;
    overflow-y: auto;
  }

  .nav-wrapper.show {
    right: 0;
  }

  .nav-links {
    flex-direction: column;
    align-items: stretch;
    width: 100%;
  }

  .nav-dropdown {
    width: 100%;
  }

  .dropdown-menu {
    position: static;
    box-shadow: none;
    border: none;
    padding-left: 1rem;
    margin-top: 0;
    background-color: #154651;
    border-radius: 0.375rem;
  }

  .user-profile {
    border-top: 1px solid #18435c;
    padding-top: 1rem;
    width: 100%;
  }

  .user-profile .profile-menu {
    position: static;
    box-shadow: none;
    border: none;
    width: 100%;
    background-color: #174957;
  }
}
























:root {
  /* Surface & Background Colors */
  --bg-main: #f8fafc;
  --surface-card: #ffffff;
  --surface-subtle: #f1f5f9;
  
  /* Text & Border Colors */
  --text-primary: #181a40;
  --text-secondary: #475569;
  --text-muted: #94a3b8;
  --border-light: #e2e8f0;
  --border-focus: #3db5c0;

  /* Image Accent Palette */
  --accent-coral: #ff5943;
  --accent-coral-hover: #e04833;
  --accent-amber: #fbb02d;
  --accent-teal: #3db5c0;
  --accent-teal-hover: #329ba5;
  --accent-navy: #181a40;

  /* Elevational Shadows & Radii */
  --radius-sm: 8px;
  --radius-md: 14px;
  --radius-lg: 20px;
  
  --shadow-sm: 0 2px 8px rgba(24, 26, 64, 0.04);
  --shadow-md: 0 10px 30px rgba(24, 26, 64, 0.08);
  --shadow-hover: 0 16px 36px rgba(24, 26, 64, 0.12);

  --transition-smooth: all 0.25s cubic-bezier(0.4, 0, 0.2, 1);
}

/* ==========================================================================
   SPATIAL UPLOAD PAGE STYLES
   ========================================================================== */

.upload-page-wrapper {
  display: flex;
  justify-content: center;
  align-items: center;
  padding: 3rem 1rem;
  width: 100%;
  background-color: var(--bg-main);
}

.upload-card {
  width: 100%;
  max-width: 720px;
  background: var(--surface-card);
  border: 1px solid var(--border-light);
  border-radius: var(--radius-lg);
  padding: 40px;
  box-shadow: var(--shadow-md);
  transition: var(--transition-smooth);
}

.upload-card:hover {
  box-shadow: var(--shadow-hover);
  border-color: rgba(61, 181, 192, 0.4);
}

/* Header & Branding */
.upload-header {
  text-align: center;
  margin-bottom: 28px;
}

.header-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 56px;
  height: 56px;
  background: rgba(61, 181, 192, 0.12);
  border: 1px solid rgba(61, 181, 192, 0.25);
  border-radius: 16px;
  margin-bottom: 16px;
}

.badge-icon {
  font-size: 1.5rem;
  color: var(--accent-teal);
}

.upload-title {
  font-size: 1.75rem;
  font-weight: 800;
  color: var(--text-primary);
  letter-spacing: -0.5px;
  margin-bottom: 6px;
}

.upload-subtitle {
  font-size: 0.9rem;
  color: var(--text-secondary);
}

/* Info Callout Notice */
.info-notice {
  background: rgba(251, 176, 45, 0.08);
  border: 1px solid rgba(251, 176, 45, 0.3);
  border-left: 4px solid var(--accent-amber);
  border-radius: var(--radius-sm);
  padding: 14px 18px;
  display: flex;
  align-items: flex-start;
  gap: 14px;
  margin-bottom: 24px;
}

.notice-icon {
  color: var(--accent-amber);
  font-size: 1.2rem;
  margin-top: 1px;
  flex-shrink: 0;
}

.notice-content {
  font-size: 0.875rem;
  color: var(--text-primary);
  line-height: 1.5;
}

.notice-content code {
  background: rgba(24, 26, 64, 0.06);
  color: var(--accent-coral);
  padding: 2px 6px;
  border-radius: 4px;
  font-family: monospace;
  font-weight: 600;
  font-size: 0.85rem;
}

.notice-subtext {
  display: block;
  margin-top: 4px;
  color: var(--accent-coral);
  font-size: 0.8rem;
  font-weight: 600;
}

/* Alert Banners */
.messages-container,
#statusAlertContainer {
  margin-bottom: 20px;
}

.alert-banner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 12px 16px;
  border-radius: var(--radius-sm);
  font-size: 0.875rem;
  font-weight: 500;
}

.alert-banner.alert-success {
  background: rgba(61, 181, 192, 0.12);
  border: 1px solid rgba(61, 181, 192, 0.3);
  color: #15737e;
}

.alert-banner.alert-danger,
.alert-banner.alert-error {
  background: rgba(255, 89, 67, 0.12);
  border: 1px solid rgba(255, 89, 67, 0.3);
  color: #c9321f;
}

.alert-banner.alert-warning {
  background: rgba(251, 176, 45, 0.15);
  border: 1px solid rgba(251, 176, 45, 0.4);
  color: #a67000;
}

.alert-content {
  display: flex;
  align-items: center;
  gap: 10px;
}

.alert-close {
  background: none;
  border: none;
  color: inherit;
  font-size: 1.25rem;
  cursor: pointer;
  line-height: 1;
  opacity: 0.7;
  transition: var(--transition-smooth);
}

.alert-close:hover {
  opacity: 1;
}

/* Form Layout */
.upload-form {
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.form-group {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.form-label {
  font-size: 0.85rem;
  font-weight: 700;
  color: var(--text-primary);
  display: flex;
  align-items: center;
  gap: 8px;
}

.label-icon {
  color: var(--accent-teal);
  font-size: 0.9rem;
}

/* File Dropzone Input */
.dropzone-wrapper {
  position: relative;
  border: 2px dashed var(--border-light);
  border-radius: var(--radius-md);
  padding: 32px 20px;
  text-align: center;
  background: var(--surface-subtle);
  transition: var(--transition-smooth);
  cursor: pointer;
}

.dropzone-wrapper:hover,
.dropzone-wrapper.has-file {
  border-color: var(--accent-teal);
  background: rgba(61, 181, 192, 0.05);
}

.dropzone-wrapper input[type="file"] {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  opacity: 0;
  cursor: pointer;
  z-index: 2;
}

.dropzone-content {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
  pointer-events: none;
}

.dropzone-icon {
  font-size: 2.25rem;
  color: var(--accent-teal);
  margin-bottom: 4px;
  transition: var(--transition-smooth);
}

.dropzone-wrapper:hover .dropzone-icon {
  transform: translateY(-3px);
  color: var(--accent-coral);
}

.dropzone-text {
  font-size: 0.95rem;
  font-weight: 700;
  color: var(--text-primary);
}

.dropzone-hint {
  font-size: 0.8rem;
  color: var(--text-muted);
}

.selected-file-name {
  display: none;
  margin-top: 10px;
  font-size: 0.825rem;
  font-weight: 700;
  color: var(--accent-teal);
  background: rgba(61, 181, 192, 0.1);
  border: 1px solid rgba(61, 181, 192, 0.25);
  padding: 4px 14px;
  border-radius: 20px;
}

/* Section Divider */
.divider-text {
  display: flex;
  align-items: center;
  text-align: center;
  margin: 10px 0;
}

.divider-text::before,
.divider-text::after {
  content: '';
  flex: 1;
  border-bottom: 1px solid var(--border-light);
}

.divider-text span {
  padding: 0 14px;
  font-size: 0.75rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 1px;
  color: var(--text-muted);
}

/* Form Grid */
.form-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
}

.form-grid .full-width {
  grid-column: span 2;
}

.form-group input[type="text"],
.form-group select {
  width: 100%;
  background-color: var(--surface-card);
  border: 1.5px solid var(--border-light);
  border-radius: var(--radius-sm);
  padding: 10px 14px;
  font-family: inherit;
  font-size: 0.875rem;
  color: var(--text-primary);
  outline: none;
  transition: var(--transition-smooth);
}

.form-group input[type="text"]:focus,
.form-group select:focus {
  border-color: var(--accent-teal);
  box-shadow: 0 0 0 3px rgba(61, 181, 192, 0.2);
  background-color: #ffffff;
}

.badge-optional {
  font-size: 0.7rem;
  font-weight: 600;
  color: var(--text-muted);
  background: var(--surface-subtle);
  padding: 2px 6px;
  border-radius: 4px;
  margin-left: 4px;
}

/* Submit Button */
.btn-submit-upload {
  width: 100%;
  background: var(--accent-coral);
  color: #ffffff;
  border: none;
  border-radius: var(--radius-sm);
  padding: 14px 20px;
  font-family: inherit;
  font-size: 0.95rem;
  font-weight: 700;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  box-shadow: 0 4px 14px rgba(255, 89, 67, 0.3);
  transition: var(--transition-smooth);
  margin-top: 8px;
}

.btn-submit-upload:hover {
  background: var(--accent-coral-hover);
  box-shadow: 0 6px 18px rgba(255, 89, 67, 0.4);
  transform: translateY(-1px);
}

.btn-submit-upload:active {
  transform: translateY(0);
}

.btn-submit-upload:disabled {
  opacity: 0.65;
  cursor: not-allowed;
  transform: none;
  box-shadow: none;
}

/* Progress Bar Section */
.progress-section {
  background: var(--surface-subtle);
  border: 1px solid var(--border-light);
  border-radius: var(--radius-sm);
  padding: 16px;
  margin-top: 4px;
}

.progress-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 0.825rem;
  font-weight: 700;
  margin-bottom: 8px;
}

.progress-status-text {
  color: var(--text-primary);
}

.progress-percentage {
  color: var(--accent-teal);
  font-family: monospace;
  font-size: 0.9rem;
}

.progress-track {
  width: 100%;
  height: 10px;
  background-color: var(--border-light);
  border-radius: 20px;
  overflow: hidden;
  position: relative;
}

.progress-bar-fill {
  height: 100%;
  width: 0%;
  background: var(--accent-teal);
  border-radius: 20px;
  transition: width 0.2s linear, background-color 0.3s ease;
}

.progress-bar-fill.processing-pulse {
  background: linear-gradient(
    45deg,
    var(--accent-teal) 25%,
    var(--accent-amber) 25%,
    var(--accent-amber) 50%,
    var(--accent-teal) 50%,
    var(--accent-teal) 75%,
    var(--accent-amber) 75%
  );
  background-size: 30px 30px;
  animation: stripeMove 1s linear infinite;
}

.progress-bar-fill.success {
  background: #10b981;
}

.progress-bar-fill.error {
  background: var(--accent-coral);
}

@keyframes stripeMove {
  0% { background-position: 0 0; }
  100% { background-position: 30px 0; }
}

@media (max-width: 600px) {
  .form-grid {
    grid-template-columns: 1fr;
  }
  .form-grid .full-width {
    grid-column: span 1;
  }
}


:root {
    --bg-main: #f8fafc;
    --bg-card: #ffffff;
    --border-color: #e2e8f0;
    --text-primary: #0f172a;
    --text-secondary: #64748b;
    --accent-primary:  #3983ac;
    --accent-hover:  #3983ac;

    /* Status Colors */
    --color-issued: #10b981;  /* Green */
    --color-paid:  #3983ac;    /* Blue */
    --color-pending: #f59e0b; /* Amber */
    --color-disputed: #ef4444;/* Red */
    --color-none: #94a3b8;    /* Slate */
}

* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
    background-color: var(--bg-main);
    color: var(--text-primary);
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    overflow-y: auto; /* Fix: Allow page scrolling */
}

/* Top Navigation Header (Dark Theme) */
header {
    background-color: #0f172a;
    color: #ffffff;
    padding: 0.65rem 1.75rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-bottom: 1px solid #1e293b;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
    z-index: 1000;
}

.brand-logo {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    text-decoration: none;
    color: #ffffff;
}

.brand-logo .logo-icon {
    background: linear-gradient(135deg,  #3983ac,  #3983ac);
    width: 38px;
    height: 38px;
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.1rem;
    box-shadow: 0 2px 8px rgba(37, 99, 235, 0.4);
}

.brand-logo h1 {
    font-size: 1.15rem;
    font-weight: 700;
    letter-spacing: -0.025em;
}

.brand-logo h1 span {
    color: #60a5fa;
    font-weight: 400;
}

/* Nav Links */
.nav-wrapper {
    display: flex;
    align-items: center;
    gap: 1.5rem;
}

.nav-links {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.nav-links a {
    color: #94a3b8;
    text-decoration: none;
    font-size: 0.875rem;
    font-weight: 500;
    padding: 0.5rem 0.85rem;
    border-radius: 0.375rem;
    transition: all 0.2s ease;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.nav-links a:hover, 
.nav-links a.active {
    background-color: #1e293b;
    color: #ffffff;
}

.nav-links a i {
    font-size: 0.9rem;
}

/* Nav Dropdown Container (Management Tools) */
.nav-dropdown {
    position: relative;
    display: inline-block;
}

.dropdown-btn {
    background: none;
    border: none;
    color: #94a3b8;
    padding: 0.5rem 0.85rem;
    font-size: 0.875rem;
    font-weight: 500;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    transition: all 0.2s ease;
}

.dropdown-btn:hover, 
.dropdown-btn.active {
    color: #ffffff;
}

.caret-icon {
    font-size: 0.75rem;
    transition: transform 0.2s ease;
}

.nav-dropdown:hover .caret-icon {
    transform: rotate(180deg);
}

.nav-dropdown .dropdown-menu {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    min-width: 220px;
    background-color: #1e293b;
    border: 1px solid #334155;
    border-radius: 8px;
    box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.3);
    padding: 6px 0;
    z-index: 1000;
}

.nav-dropdown:hover .dropdown-menu {
    display: block;
}

.nav-dropdown .dropdown-item {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 10px 16px;
    color: #cbd5e1;
    text-decoration: none;
    font-size: 0.9rem;
    transition: background-color 0.2s ease, color 0.2s ease;
}

.nav-dropdown .dropdown-item:hover {
    background-color: #334155;
    color: #ffffff;
}

.dropdown-divider {
    height: 1px;
    background-color: #334155;
    margin: 6px 0;
}

.nav-dropdown .dropdown-item.admin-link {
    color: #38bdf8;
}

.nav-dropdown .dropdown-item.admin-link:hover {
    color: #ffffff;
    background-color: #0284c7;
}

/* User Profile Dropdown Section */
.user-profile {
    position: relative;
}

.profile-btn {
    background: #1e293b;
    border: 1px solid #334155;
    padding: 0.35rem 0.65rem 0.35rem 0.4rem;
    border-radius: 9999px;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 0.65rem;
    transition: all 0.2s ease;
}

.profile-btn:hover {
    border-color: #475569;
    background: #334155;
}

.avatar-circle {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    background: linear-gradient(135deg,  #3983ac,  #3983ac);
    color: #ffffff;
    font-weight: 700;
    font-size: 0.85rem;
    display: flex;
    align-items: center;
    justify-content: center;
    text-transform: uppercase;
}

.profile-name {
    font-size: 0.85rem;
    font-weight: 600;
    color: #f1f5f9;
}

.user-profile .dropdown-menu {
    position: absolute;
    right: 0;
    top: calc(100% + 0.6rem);
    width: 230px;
    background-color: #ffffff;
    border: 1px solid #e2e8f0;
    border-radius: 0.5rem;
    box-shadow: 0 10px 25px -5px rgba(0, 0, 0, 0.1), 0 8px 10px -6px rgba(0, 0, 0, 0.1);
    display: none;
    flex-direction: column;
    overflow: hidden;
    z-index: 1100;
}

.user-profile .dropdown-menu.show {
    display: flex;
}

.user-profile .dropdown-header {
    padding: 0.85rem 1rem;
    background-color: #f8fafc;
    border-bottom: 1px solid #e2e8f0;
}

.user-profile .dropdown-header .user-fullname {
    font-size: 0.875rem;
    font-weight: 600;
    color: var(--text-primary);
}

.user-profile .dropdown-header .user-email {
    font-size: 0.75rem;
    color: var(--text-secondary);
    margin-top: 0.1rem;
    word-break: break-all;
}

.user-profile .dropdown-item {
    padding: 0.65rem 1rem;
    font-size: 0.85rem;
    color: #334155;
    text-decoration: none;
    display: flex;
    align-items: center;
    gap: 0.65rem;
    transition: background 0.15s ease;
    background: none;
    border: none;
    width: 100%;
    text-align: left;
    cursor: pointer;
}

.user-profile .dropdown-item:hover {
    background-color: #f1f5f9;
    color: var(--accent-primary);
}

.user-profile .dropdown-item.logout-btn {
    color: #ef4444;
    border-top: 1px solid #f1f5f9;
}

.user-profile .dropdown-item.logout-btn:hover {
    background-color: #fef2f2;
    color: #dc2626;
}


.user-management-container {
    padding: 24px;
    color: #f8fafc;
    max-width: 1400px;
    margin: 0 auto;
}

.page-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 16px;
    margin-bottom: 20px;
}

.page-header h2 {
    font-size: 1.5rem;
    font-weight: 700;
    color: #f8fafc;
    margin-bottom: 4px;
    display: flex;
    align-items: center;
    gap: 10px;
}

.subtitle {
    color: #94a3b8;
    font-size: 0.9rem;
}

.btn-primary-add {
    background-color: #0284c7;
    color: #ffffff;
    border: none;
    padding: 10px 18px;
    border-radius: 8px;
    font-weight: 600;
    font-size: 0.9rem;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 8px;
    transition: all 0.2s ease;
    box-shadow: 0 4px 6px -1px rgba(2, 132, 199, 0.2);
}

.btn-primary-add:hover {
    background-color: #0369a1;
    transform: translateY(-1px);
}

.form-full {
    grid-column: span 2;
}

.required {
    color: #f43f5e;
}

/* Metrics Cards */
.metrics-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 16px;
    margin-bottom: 24px;
}

.metric-card {
    background-color: #1e293b;
    border: 1px solid #334155;
    border-radius: 12px;
    padding: 16px;
    display: flex;
    align-items: center;
    gap: 16px;
    transition: transform 0.2s ease, border-color 0.2s ease;
}

.metric-card:hover {
    border-color: #475569;
    transform: translateY(-2px);
}

.metric-icon {
    width: 48px;
    height: 48px;
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.25rem;
}

.metric-icon.blue { background: rgba(56, 189, 248, 0.15); color: #38bdf8; }
.metric-icon.green { background: rgba(34, 197, 94, 0.15); color: #22c55e; }
.metric-icon.purple { background: rgba(168, 85, 247, 0.15); color: #a855f7; }
.metric-icon.teal { background: rgba(20, 184, 166, 0.15); color: #14b8a6; }

.metric-value {
    display: block;
    font-size: 1.4rem;
    font-weight: 700;
    color: #f8fafc;
}

.metric-label {
    font-size: 0.8rem;
    color: #94a3b8;
}

/* Filter Card */
.filter-card {
    background-color: #1e293b;
    border: 1px solid #334155;
    border-radius: 12px;
    padding: 16px;
    margin-bottom: 20px;
}

.filter-form {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    justify-content: space-between;
}

.search-box {
    position: relative;
    flex: 1;
    min-width: 260px;
}

.search-box i {
    position: absolute;
    left: 12px;
    top: 50%;
    transform: translateY(-50%);
    color: #64748b;
}

.search-box input {
    width: 100%;
    padding: 9px 12px 9px 36px;
    background-color: #0f172a;
    border: 1px solid #334155;
    border-radius: 8px;
    color: #f8fafc;
    font-size: 0.9rem;
    transition: border-color 0.2s ease;
}

.search-box input:focus {
    outline: none;
    border-color: #0284c7;
}

.filter-selects {
    display: flex;
    gap: 10px;
    align-items: center;
    flex-wrap: wrap;
}

.filter-selects select {
    background-color: #0f172a;
    border: 1px solid #334155;
    color: #f8fafc;
    padding: 9px 12px;
    border-radius: 8px;
    font-size: 0.875rem;
    cursor: pointer;
}

.filter-selects select:focus {
    outline: none;
    border-color: #0284c7;
}

.btn-reset {
    color: #f43f5e;
    text-decoration: none;
    font-size: 0.85rem;
    padding: 8px 12px;
    border-radius: 8px;
    background: rgba(244, 63, 94, 0.1);
    transition: background 0.2s ease;
}

.btn-reset:hover {
    background: rgba(244, 63, 94, 0.2);
}

/* Custom Table */
.table-card {
    background-color: #1e293b;
    border: 1px solid #334155;
    border-radius: 12px;
    overflow-x: auto;
}

.custom-table {
    width: 100%;
    border-collapse: collapse;
    text-align: left;
    font-size: 0.9rem;
}

.custom-table th {
    background-color: #0f172a;
    padding: 14px 16px;
    color: #94a3b8;
    font-weight: 600;
    border-bottom: 1px solid #334155;
}

.custom-table td {
    padding: 14px 16px;
    border-bottom: 1px solid #334155;
    vertical-align: middle;
}

.custom-table tbody tr:hover {
    background-color: rgba(51, 65, 85, 0.3);
}

.user-meta {
    display: flex;
    align-items: center;
    gap: 12px;
}

.avatar-circle {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    background: #0284c7;
    color: #ffffff;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    flex-shrink: 0;
}

.user-name { display: block; color: #f8fafc; }
.user-email { font-size: 0.78rem; color: #94a3b8; }

.contact-meta {
    display: flex;
    flex-direction: column;
    gap: 2px;
    font-size: 0.8rem;
    color: #cbd5e1;
}

.geo-badge {
    color: #e2e8f0;
    font-size: 0.85rem;
    display: flex;
    align-items: center;
    gap: 6px;
}

.geo-badge small {
    color: #94a3b8;
}

.text-muted {
    color: #64748b;
    font-size: 0.85rem;
}

/* Role Badges */
.role-badge {
    display: inline-block;
    padding: 4px 10px;
    border-radius: 20px;
    font-size: 0.75rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.3px;
}

.role-super_admin { background: rgba(239, 68, 68, 0.2); color: #f87171; }
.role-admin { background: rgba(245, 158, 11, 0.2); color: #fbbf24; }
.role-gis_expert { background: rgba(14, 165, 233, 0.2); color: #38bdf8; }
.role-acm { background: rgba(168, 85, 247, 0.2); color: #c084fc; }
.role-team_leader { background: rgba(20, 184, 166, 0.2); color: #2dd4bf; }
.role-collector { background: rgba(34, 197, 94, 0.2); color: #4ade80; }
.role-county_boss { background: rgba(236, 72, 153, 0.2); color: #f472b6; }

/* Status Badges */
.status-badge {
    font-size: 0.8rem;
    padding: 4px 8px;
    border-radius: 6px;
    display: inline-flex;
    align-items: center;
    gap: 6px;
}

.status-badge.active { color: #4ade80; background: rgba(74, 222, 128, 0.1); }
.status-badge.inactive { color: #f43f5e; background: rgba(244, 63, 94, 0.1); }

.action-buttons {
    display: flex;
    justify-content: flex-end;
    gap: 6px;
    align-items: center;
}

.btn-edit {
    background-color: #334155;
    color: #f8fafc;
    border: none;
    padding: 6px 12px;
    border-radius: 6px;
    cursor: pointer;
    font-size: 0.85rem;
    transition: background 0.2s ease;
}

.btn-edit:hover { background-color: #0284c7; }

.btn-key {
    background-color: #334155;
    color: #f59e0b;
    border: none;
    padding: 6px 10px;
    border-radius: 6px;
    cursor: pointer;
    font-size: 0.85rem;
    transition: background 0.2s, color 0.2s;
}

.btn-key:hover {
    background-color: #f59e0b;
    color: #0f172a;
}

.empty-state {
    text-align: center;
    padding: 40px !important;
}

.empty-content {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 12px;
    color: #64748b;
}

.empty-content i {
    font-size: 2.5rem;
}

.text-right { text-align: right; }

/* Modal Styles */
.modal-backdrop {
    display: none;
    position: fixed;
    top: 0; left: 0; width: 100%; height: 100%;
    background: rgba(15, 23, 42, 0.8);
    backdrop-filter: blur(4px);
    z-index: 2000;
    align-items: center;
    justify-content: center;
    animation: fadeIn 0.2s ease;
}

.modal-box {
    background-color: #1e293b;
    border: 1px solid #334155;
    border-radius: 12px;
    width: 90%;
    max-width: 560px;
    box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.5);
    overflow: hidden;
}

.modal-sm {
    max-width: 440px;
}

.modal-header {
    padding: 16px 20px;
    background: #0f172a;
    border-bottom: 1px solid #334155;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.modal-header h3 { 
    font-size: 1.1rem; 
    color: #f8fafc; 
    margin: 0; 
    display: flex;
    align-items: center;
    gap: 8px;
}

.close-btn { 
    background: none; 
    border: none; 
    color: #94a3b8; 
    font-size: 1.5rem; 
    cursor: pointer; 
    transition: color 0.2s;
}

.close-btn:hover { color: #f8fafc; }

.modal-body { padding: 20px; }

.info-banner {
    background: rgba(56, 189, 248, 0.1);
    border-left: 3px solid #38bdf8;
    padding: 10px 14px;
    border-radius: 4px;
    font-size: 0.85rem;
    margin-bottom: 16px;
    color: #cbd5e1;
}

.warning-banner {
    background: rgba(245, 158, 11, 0.1);
    border-left: 3px solid #f59e0b;
    color: #fbbf24;
}

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

@media (max-width: 640px) {
    .form-grid {
        grid-template-columns: 1fr;
    }
    .form-full {
        grid-column: span 1;
    }
}

.form-group { display: flex; flex-direction: column; gap: 6px; }
.form-group label { font-size: 0.8rem; color: #cbd5e1; font-weight: 600; }

.form-control, .form-select {
    background-color: #0f172a;
    border: 1px solid #334155;
    color: #f8fafc;
    padding: 8px 12px;
    border-radius: 6px;
    font-size: 0.875rem;
    transition: border-color 0.2s ease;
}

.form-control:focus, .form-select:focus {
    outline: none;
    border-color: #0284c7;
}

.checkbox-group { grid-column: span 2; margin-top: 6px; }
.checkbox-label { display: flex; align-items: center; gap: 10px; cursor: pointer; font-size: 0.85rem; color: #e2e8f0; }

.modal-footer {
    padding: 14px 20px;
    background: #0f172a;
    border-top: 1px solid #334155;
    display: flex;
    justify-content: flex-end;
    gap: 10px;
}

.btn-cancel { 
    background: #334155; 
    color: #f8fafc; 
    border: none; 
    padding: 8px 16px; 
    border-radius: 6px; 
    cursor: pointer; 
    transition: background 0.2s ease;
}

.btn-cancel:hover { background: #475569; }

.btn-save { 
    background: #0284c7; 
    color: #ffffff; 
    border: none; 
    padding: 8px 16px; 
    border-radius: 6px; 
    cursor: pointer; 
    font-weight: 600; 
    transition: background 0.2s ease;
}

.btn-save:hover { background: #0369a1; }

.btn-warning-save {
    background-color: #d97706;
}

.btn-warning-save:hover {
    background-color: #b45309;
}

.margin-bottom-14 {
    margin-bottom: 14px;
}

/* Alert Messaging */
.messages-container {
    margin-bottom: 20px;
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.alert-banner {
    padding: 12px 16px;
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    font-size: 0.9rem;
    border: 1px solid transparent;
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.3);
    animation: slideInDown 0.3s ease-in-out;
}

.alert-content {
    display: flex;
    align-items: center;
    gap: 12px;
}

.alert-success { background-color: rgba(34, 197, 94, 0.15); border-color: rgba(34, 197, 94, 0.4); color: #4ade80; }
.alert-error, .alert-danger { background-color: rgba(244, 63, 94, 0.15); border-color: rgba(244, 63, 94, 0.4); color: #f43f5e; }
.alert-warning { background-color: rgba(245, 158, 11, 0.15); border-color: rgba(245, 158, 11, 0.4); color: #fbbf24; }
.alert-info { background-color: rgba(56, 189, 248, 0.15); border-color: rgba(56, 189, 248, 0.4); color: #38bdf8; }

.alert-close {
    background: none;
    border: none;
    color: currentColor;
    font-size: 1.25rem;
    cursor: pointer;
    opacity: 0.7;
    padding: 0 4px;
    line-height: 1;
}

.alert-close:hover { opacity: 1; }

@keyframes slideInDown {
    from { opacity: 0; transform: translateY(-8px); }
    to { opacity: 1; transform: translateY(0); }
}

@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}


/* ==========================================================================
   RMS ACCESS PORTAL — LOGIN / AUTHENTICATION
   ========================================================================== */

/* ==========================================================================
   LOGIN PAGE ROOT
   ========================================================================== */

.auth-body {
    margin: 0;
    min-height: 100vh;

    background: #ffffff;

    font-family: "Plus Jakarta Sans", sans-serif;
    color: #151936;

    display: flex;
    align-items: center;
    justify-content: center;

    overflow: hidden;
}


/* ==========================================================================
   LOGIN STAGE
   ========================================================================== */

.auth-body .login-stage {
    width: 100%;
    min-height: 100vh;

    display: flex;
    align-items: center;
    justify-content: center;

    padding: 34px 42px;

    box-sizing: border-box;
}


/* ==========================================================================
   MAIN VISUAL CANVAS
   ========================================================================== */

.auth-body .login-canvas {
    position: relative;

    width: min(1200px, 92vw);
    height: min(650px, 82vh);

    min-height: 500px;

    overflow: hidden;

    border-radius: 46px;

    background: #f4f5f7;

    box-shadow:
        0 20px 60px rgba(24, 29, 68, 0.08);
}


/* ==========================================================================
   DARK LEFT SIDE
   ========================================================================== */

.auth-body .canvas-dark {
    position: absolute;

    inset: 0 auto 0 0;

    width: 50%;

    background:
        radial-gradient(
            circle at 17% 50%,
            rgba(51, 83, 126, 0.16),
            transparent 32%
        ),
        radial-gradient(
            circle at 78% 91%,
            rgba(28, 126, 143, 0.12),
            transparent 31%
        ),
        linear-gradient(
            90deg,
            #171943 0%,
            #191b4b 48%,
            #171a42 100%
        );

    overflow: hidden;
}


/* ==========================================================================
   LIGHT RIGHT SIDE
   ========================================================================== */

.auth-body .canvas-light {
    position: absolute;

    inset: 0 0 0 auto;

    width: 50%;

    background:
        radial-gradient(
            circle at 72% 32%,
            rgba(246, 225, 175, 0.28),
            transparent 28%
        ),
        radial-gradient(
            circle at 27% 78%,
            rgba(185, 225, 223, 0.25),
            transparent 30%
        ),
        linear-gradient(
            135deg,
            #f8f9f9 0%,
            #f1f3f3 100%
        );

    overflow: hidden;
}


/* ==========================================================================
   CENTRAL DIVIDER
   ========================================================================== */

.auth-body .canvas-divider {
    position: absolute;

    top: 0;
    bottom: 0;
    left: 50%;

    width: 2px;

    transform: translateX(-1px);

    background: rgba(70, 159, 184, 0.78);

    z-index: 4;
}


/* ==========================================================================
   GIS NETWORK PATTERNS
   ========================================================================== */

.auth-body .network {
    position: absolute;

    inset: -20%;

    pointer-events: none;
}


/* ==========================================================================
   DARK-SIDE NETWORK
   ========================================================================== */

.auth-body .network-left {
    opacity: 0.62;

    background:
        radial-gradient(
            circle at 13% 43%,
            rgba(224, 108, 88, 0.95) 0 2px,
            transparent 3px
        ),
        radial-gradient(
            circle at 23% 55%,
            rgba(226, 111, 89, 0.85) 0 2px,
            transparent 3px
        ),
        radial-gradient(
            circle at 31% 37%,
            rgba(65, 151, 180, 0.75) 0 2px,
            transparent 3px
        ),
        radial-gradient(
            circle at 42% 65%,
            rgba(87, 167, 178, 0.8) 0 2px,
            transparent 3px
        ),
        repeating-linear-gradient(
            122deg,
            transparent 0 49px,
            rgba(83, 148, 174, 0.22) 50px,
            transparent 51px 82px
        ),
        repeating-linear-gradient(
            33deg,
            transparent 0 57px,
            rgba(203, 105, 92, 0.20) 58px,
            transparent 59px 91px
        );

    transform: rotate(-3deg) scale(1.05);
}


/* ==========================================================================
   LOWER DARK NETWORK
   ========================================================================== */

.auth-body .network-bottom {
    inset: auto -15% -17% 20%;

    height: 65%;

    opacity: 0.72;

    background:
        radial-gradient(
            circle at 18% 38%,
            rgba(215, 103, 89, 0.95) 0 2px,
            transparent 3px
        ),
        radial-gradient(
            circle at 42% 58%,
            rgba(78, 159, 173, 0.95) 0 2px,
            transparent 3px
        ),
        radial-gradient(
            circle at 67% 32%,
            rgba(215, 103, 89, 0.85) 0 2px,
            transparent 3px
        ),
        repeating-linear-gradient(
            145deg,
            transparent 0 43px,
            rgba(214, 111, 93, 0.26) 44px,
            transparent 45px 78px
        ),
        repeating-linear-gradient(
            40deg,
            transparent 0 51px,
            rgba(77, 156, 175, 0.25) 52px,
            transparent 53px 82px
        );
}


/* ==========================================================================
   LIGHT-SIDE NETWORK
   ========================================================================== */

.auth-body .network-right {
    opacity: 0.66;

    background:
        radial-gradient(
            circle at 72% 12%,
            rgba(220, 150, 64, 0.95) 0 2px,
            transparent 3px
        ),
        radial-gradient(
            circle at 83% 27%,
            rgba(218, 91, 78, 0.92) 0 2px,
            transparent 3px
        ),
        radial-gradient(
            circle at 55% 44%,
            rgba(76, 157, 179, 0.82) 0 2px,
            transparent 3px
        ),
        radial-gradient(
            circle at 77% 58%,
            rgba(217, 112, 85, 0.8) 0 2px,
            transparent 3px
        ),
        repeating-linear-gradient(
            126deg,
            transparent 0 47px,
            rgba(185, 167, 102, 0.22) 48px,
            transparent 49px 82px
        ),
        repeating-linear-gradient(
            42deg,
            transparent 0 58px,
            rgba(73, 145, 167, 0.18) 59px,
            transparent 60px 91px
        );

    transform: rotate(3deg) scale(1.06);
}


.auth-body .network-right-two {
    opacity: 0.45;

    background:
        repeating-linear-gradient(
            154deg,
            transparent 0 62px,
            rgba(209, 97, 83, 0.18) 63px,
            transparent 64px 98px
        ),
        repeating-linear-gradient(
            25deg,
            transparent 0 72px,
            rgba(68, 151, 168, 0.18) 73px,
            transparent 74px 112px
        );

    transform: scale(1.15);
}


/* ==========================================================================
   DECORATIVE LINES
   ========================================================================== */

.auth-body .dark-line {
    position: absolute;

    width: 1px;

    background: rgba(66, 154, 180, 0.58);

    opacity: 0.7;
}


.auth-body .line-one {
    top: 0;
    bottom: 0;
    left: 56%;
}


.auth-body .line-two {
    top: 0;
    bottom: 0;
    left: 73%;

    opacity: 0.12;
}


/* ==========================================================================
   LOGIN CARD
   ========================================================================== */

.auth-body .login-card {
    position: absolute;

    z-index: 10;

    top: 50%;
    left: 50%;

    width: 360px;

    transform: translate(-50%, -50%);

    padding: 24px 24px 22px;

    box-sizing: border-box;

    background:
        linear-gradient(
            145deg,
            rgba(255, 255, 255, 0.97),
            rgba(245, 247, 248, 0.97)
        );

    border: 1px solid rgba(255, 255, 255, 0.88);

    border-radius: 10px;

    box-shadow:
        0 18px 40px rgba(26, 31, 62, 0.22),
        0 3px 10px rgba(26, 31, 62, 0.10);

    backdrop-filter: blur(12px);
}


/* ==========================================================================
   LOGIN BRAND
   ========================================================================== */

.auth-body .login-brand {
    display: flex;
    flex-direction: column;
    align-items: center;

    margin-bottom: 16px;
}


/*
   IMPORTANT:
   Keep this selector separate from the application's global .brand-logo.
*/

.auth-body .login-brand .brand-logo {
    position: relative;

    width: 58px;
    height: 48px;

    display: flex;
    align-items: center;
    justify-content: center;

    margin-bottom: 5px;
}


/* ==========================================================================
   LOGO GRID
   ========================================================================== */

.auth-body .logo-grid {
    width: 39px;
    height: 39px;

    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 4px;

    padding: 5px;

    box-sizing: border-box;

    background: #171a42;

    border-radius: 2px;

    box-shadow:
        0 3px 8px rgba(22, 26, 65, 0.18);
}


.auth-body .logo-grid span {
    display: block;

    border-radius: 1px;

    background: #f05b45;
}


.auth-body .logo-grid span:nth-child(2),
.auth-body .logo-grid span:nth-child(6),
.auth-body .logo-grid span:nth-child(8) {
    background: #f5b42f;
}


.auth-body .logo-grid span:nth-child(4),
.auth-body .logo-grid span:nth-child(9) {
    background: #f06c3d;
}


/* ==========================================================================
   GIS LOCATION ICON
   ========================================================================== */

.auth-body .logo-map-pin {
    position: absolute;

    right: 1px;
    bottom: 1px;

    width: 28px;
    height: 32px;

    display: flex;
    align-items: center;
    justify-content: center;

    color: #2e9b9d;

    font-size: 26px;

    filter:
        drop-shadow(
            0 2px 2px rgba(25, 70, 74, 0.18)
        );
}


.auth-body .brand-name {
    color: #20233e;

    font-size: 13px;
    font-weight: 700;

    letter-spacing: 0.45px;

    line-height: 1;
}


/* ==========================================================================
   LOGIN FORM
   ========================================================================== */

.auth-body .auth-form {
    width: 100%;
}


/* ==========================================================================
   LOGIN ERROR
   ========================================================================== */

.auth-body .alert-error {
    display: flex;
    align-items: flex-start;

    gap: 7px;

    margin-bottom: 11px;

    padding: 9px 10px;

    border-radius: 5px;

    background: #fff0ef;

    border: 1px solid #f6d0cc;

    color: #a83c34;

    font-size: 9px;

    line-height: 1.4;
}


.auth-body .alert-error i {
    flex: 0 0 auto;

    margin-top: 1px;
}


/* ==========================================================================
   LOGIN FORM GROUP
   ========================================================================== */

.auth-body .auth-form .form-group {
    margin-bottom: 10px;
}


/* ==========================================================================
   LOGIN INPUT WRAPPER
   ========================================================================== */

.auth-body .auth-form .input-wrapper {
    position: relative;

    width: 100%;
}


/* ==========================================================================
   LOGIN INPUT
   ========================================================================== */

.auth-body .auth-form .form-control {
    width: 100%;

    height: 38px;

    box-sizing: border-box;

    padding: 0 36px 0 32px;

    border: 1px solid #d8dadd;

    border-radius: 4px;

    background: rgba(255, 255, 255, 0.94);

    color: #252735;

    font-family: "Plus Jakarta Sans", sans-serif;

    font-size: 11px;
    font-weight: 500;

    outline: none;

    transition:
        border-color 0.18s ease,
        box-shadow 0.18s ease,
        background 0.18s ease;
}


.auth-body .auth-form .form-control::placeholder {
    color: #888b91;

    opacity: 1;
}


.auth-body .auth-form .form-control:focus {
    background: #ffffff;

    border-color: #4a9ea8;

    box-shadow:
        0 0 0 3px rgba(74, 158, 168, 0.10);
}


/* ==========================================================================
   LOGIN FIELD ICON
   ========================================================================== */

.auth-body .auth-form .field-icon {
    position: absolute;

    left: 10px;
    top: 50%;

    transform: translateY(-50%);

    z-index: 2;

    color: #777b83;

    font-size: 11px;

    pointer-events: none;
}


/* ==========================================================================
   PASSWORD TOGGLE
   ========================================================================== */

.auth-body .auth-form .password-toggle {
    position: absolute;

    top: 50%;
    right: 7px;

    transform: translateY(-50%);

    width: 24px;
    height: 24px;

    display: flex;
    align-items: center;
    justify-content: center;

    padding: 0;

    border: 0;

    background: transparent;

    color: #7c8087;

    cursor: pointer;

    font-size: 11px;
}


.auth-body .auth-form .password-toggle:hover {
    color: #20233e;
}


/* ==========================================================================
   CLOUDFLARE TURNSTILE
   ========================================================================== */

.auth-body .turnstile-wrapper {
    width: 100%;

    min-height: 52px;

    display: flex;
    align-items: center;
    justify-content: center;

    margin: 10px 0 9px;

    overflow: hidden;
}


/*
   The Turnstile widget is controlled by Cloudflare.
   We give it a clean container rather than trying to
   manipulate the internal iframe.
*/

.auth-body .cf-turnstile {
    width: 100%;

    min-height: 52px;

    display: flex;
    align-items: center;
    justify-content: center;
}


/*
   Contain the third-party iframe so it cannot create
   horizontal overflow inside the login card.
*/

.auth-body .cf-turnstile iframe {
    display: block;

    max-width: 100% !important;

    border: 0 !important;
}


/* ==========================================================================
   LOGIN OPTIONS
   ========================================================================== */

.auth-body .auth-form .form-options {
    display: flex;

    align-items: center;

    justify-content: space-between;

    margin: 8px 1px 12px;
}


/* ==========================================================================
   REMEMBER ME
   ========================================================================== */

.auth-body .auth-form .remember-me {
    display: flex;

    align-items: center;

    gap: 6px;

    cursor: pointer;

    color: #686b72;

    font-size: 9px;
}


/* Hide native checkbox */

.auth-body .auth-form .remember-me input {
    position: absolute;

    width: 1px;
    height: 1px;

    opacity: 0;

    pointer-events: none;
}


/* Custom checkbox */

.auth-body .auth-form .checkbox-custom {
    width: 11px;
    height: 11px;

    box-sizing: border-box;

    border: 1px solid #c6c8cc;

    border-radius: 2px;

    background: #ffffff;

    transition: all 0.15s ease;
}


/* Checked state */

.auth-body .auth-form .remember-me input:checked + .checkbox-custom {
    background: #252849;

    border-color: #252849;

    box-shadow:
        inset 0 0 0 2px #ffffff;
}


.auth-body .auth-form .label-text {
    white-space: nowrap;
}


/* ==========================================================================
   FORGOT PASSWORD
   ========================================================================== */

.auth-body .auth-form .forgot-link {
    color: #555961;

    font-size: 9px;

    font-weight: 500;

    text-decoration: none;

    transition: color 0.15s ease;
}


.auth-body .auth-form .forgot-link:hover {
    color: #1f2347;

    text-decoration: underline;
}


/* ==========================================================================
   LOGIN BUTTON
   ========================================================================== */

.auth-body .auth-form .btn-submit {
    width: 100%;

    height: 38px;

    display: flex;

    align-items: center;

    justify-content: center;

    gap: 7px;

    padding: 0;

    border: 0;

    border-radius: 4px;

    background:
        linear-gradient(
            135deg,
            #25294d 0%,
            #171a3e 100%
        );

    color: #ffffff;

    font-family: "Plus Jakarta Sans", sans-serif;

    font-size: 11px;

    font-weight: 600;

    cursor: pointer;

    box-shadow:
        0 4px 9px rgba(27, 31, 67, 0.20);

    transition:
        transform 0.15s ease,
        box-shadow 0.15s ease,
        background 0.15s ease;
}


.auth-body .auth-form .btn-submit:hover {
    background:
        linear-gradient(
            135deg,
            #2d3159 0%,
            #1b1f48 100%
        );

    box-shadow:
        0 6px 13px rgba(27, 31, 67, 0.25);

    transform: translateY(-1px);
}


.auth-body .auth-form .btn-submit:active {
    transform: translateY(0);

    box-shadow:
        0 3px 7px rgba(27, 31, 67, 0.18);
}


.auth-body .auth-form .btn-submit i {
    font-size: 9px;

    transition: transform 0.15s ease;
}


.auth-body .auth-form .btn-submit:hover i {
    transform: translateX(2px);
}


/* ==========================================================================
   ACCESSIBILITY
   ========================================================================== */

.auth-body .sr-only {
    position: absolute;

    width: 1px;
    height: 1px;

    padding: 0;
    margin: -1px;

    overflow: hidden;

    clip: rect(0, 0, 0, 0);

    white-space: nowrap;

    border: 0;
}


/* ==========================================================================
   RESPONSIVE — TABLET
   ========================================================================== */

@media (max-width: 800px) {

    .auth-body {
        overflow-y: auto;
    }


    .auth-body .login-stage {
        min-height: 100vh;

        padding: 20px;
    }


    .auth-body .login-canvas {
        width: 100%;

        height: 600px;

        min-height: 600px;

        border-radius: 28px;
    }


    /* Top / bottom composition */

    .auth-body .canvas-dark,
    .auth-body .canvas-light {
        width: 100%;
    }


    .auth-body .canvas-dark {
        height: 50%;

        inset: 0 0 auto 0;
    }


    .auth-body .canvas-light {
        height: 50%;

        inset: auto 0 0 0;
    }


    /* Horizontal divider */

    .auth-body .canvas-divider {
        top: 50%;

        bottom: auto;

        left: 0;
        right: 0;

        width: 100%;

        height: 2px;

        transform: translateY(-1px);
    }


    .auth-body .login-card {
        width: 320px;

        max-width: calc(100% - 32px);
    }
}


/* ==========================================================================
   RESPONSIVE — SMALL PHONES
   ========================================================================== */

@media (max-width: 480px) {

    .auth-body {
        overflow-y: auto;
    }


    .auth-body .login-stage {
        min-height: 100vh;

        padding: 12px;
    }


    .auth-body .login-canvas {
        width: 100%;

        height: calc(100vh - 24px);

        min-height: 500px;

        border-radius: 24px;
    }


    .auth-body .login-card {
        width: calc(100% - 32px);

        max-width: 320px;

        padding: 22px 20px 20px;
    }


    .auth-body .turnstile-wrapper {
        margin-top: 9px;

        margin-bottom: 8px;
    }
}


/* ==========================================================================
   RESPONSIVE — VERY SMALL PHONES
   ========================================================================== */

@media (max-width: 360px) {

    .auth-body .login-stage {
        padding: 8px;
    }


    .auth-body .login-canvas {
        height: calc(100vh - 16px);

        min-height: 480px;

        border-radius: 20px;
    }


    .auth-body .login-card {
        width: calc(100% - 24px);

        max-width: 320px;

        padding: 20px 16px 18px;
    }


    .auth-body .login-brand {
        margin-bottom: 12px;
    }


    .auth-body .login-brand .brand-logo {
        transform: scale(0.92);

        margin-bottom: 2px;
    }


    .auth-body .auth-form .form-control {
        height: 36px;

        font-size: 10px;
    }


    .auth-body .auth-form .btn-submit {
        height: 36px;

        font-size: 10px;
    }


    .auth-body .turnstile-wrapper,
    .auth-body .cf-turnstile {
        min-height: 50px;
    }
}
/* ==========================================================================
   FIELD SQUADS & TEAM MANAGEMENT STYLES
   ========================================================================== */

/* ==========================================================================
   RMS FIELD SQUADS — COMMAND CENTER
   Scoped under .squad-page to prevent global CSS leakage.
   ========================================================================== */


/* ==========================================================================
   PAGE SHELL
   ========================================================================== */

.squad-page {
    width: 100%;
    max-width: 1480px;
    margin: 0 auto;
    padding: 28px;
    box-sizing: border-box;
}


/* ==========================================================================
   PAGE HEADER
   ========================================================================== */

.squad-page-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 24px;

    margin-bottom: 28px;
}


.squad-heading {
    display: flex;
    align-items: center;
    gap: 16px;
    min-width: 0;
}


.squad-heading-icon {
    width: 52px;
    height: 52px;

    flex: 0 0 52px;

    display: flex;
    align-items: center;
    justify-content: center;

    border-radius: 14px;

    background:
        linear-gradient(
            145deg,
            rgba(56, 189, 248, 0.18),
            rgba(14, 116, 144, 0.08)
        );

    border: 1px solid rgba(56, 189, 248, 0.25);

    color: #38bdf8;

    font-size: 1.2rem;

    box-shadow:
        0 8px 24px rgba(0, 0, 0, 0.12);
}


.squad-eyebrow {
    display: block;

    margin-bottom: 4px;

    color: #38bdf8;

    font-size: 0.66rem;
    font-weight: 800;

    letter-spacing: 0.14em;
}


.squad-page-title {
    margin: 0;

    color: #f8fafc;

    font-size: clamp(1.55rem, 2vw, 2rem);
    font-weight: 800;

    line-height: 1.1;

    letter-spacing: -0.03em;
}


.squad-page-subtitle {
    margin: 6px 0 0;

    color: #94a3b8;

    font-size: 0.84rem;
}


/* ==========================================================================
   PRIMARY ACTION
   ========================================================================== */

.squad-primary-action {
    display: inline-flex;
    align-items: center;
    gap: 10px;

    flex: 0 0 auto;

    min-height: 44px;

    padding: 0 17px;

    border: 1px solid rgba(56, 189, 248, 0.35);
    border-radius: 10px;

    background:
        linear-gradient(
            135deg,
            #0284c7 0%,
            #0369a1 100%
        );

    color: #ffffff;

    font-family: inherit;
    font-size: 0.82rem;
    font-weight: 700;

    cursor: pointer;

    box-shadow:
        0 8px 24px rgba(2, 132, 199, 0.22);

    transition:
        transform 0.18s ease,
        box-shadow 0.18s ease,
        border-color 0.18s ease;
}


.squad-primary-action:hover {
    transform: translateY(-2px);

    border-color: rgba(125, 211, 252, 0.65);

    box-shadow:
        0 12px 30px rgba(2, 132, 199, 0.30);

    color: #ffffff;
}


.squad-primary-action:active {
    transform: translateY(0);
}


.squad-action-icon {
    width: 25px;
    height: 25px;

    display: flex;
    align-items: center;
    justify-content: center;

    border-radius: 7px;

    background: rgba(255, 255, 255, 0.14);

    font-size: 0.7rem;
}


/* ==========================================================================
   ALERTS
   ========================================================================== */

.squad-alert-stack {
    display: flex;
    flex-direction: column;
    gap: 10px;

    margin-bottom: 22px;
}


.squad-alert {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 14px;

    min-height: 46px;

    box-sizing: border-box;

    padding: 10px 14px;

    border-radius: 10px;

    font-size: 0.78rem;

    backdrop-filter: blur(12px);
}


.squad-alert-content {
    display: flex;
    align-items: center;
    gap: 10px;
}


.squad-alert-icon {
    font-size: 0.95rem;
}


.squad-alert-success {
    color: #34d399;

    background: rgba(16, 185, 129, 0.09);

    border: 1px solid rgba(16, 185, 129, 0.25);
}


.squad-alert-error,
.squad-alert-danger {
    color: #fb7185;

    background: rgba(244, 63, 94, 0.09);

    border: 1px solid rgba(244, 63, 94, 0.25);
}


.squad-alert-warning {
    color: #fbbf24;

    background: rgba(245, 158, 11, 0.09);

    border: 1px solid rgba(245, 158, 11, 0.25);
}


.squad-alert-info {
    color: #38bdf8;

    background: rgba(56, 189, 248, 0.09);

    border: 1px solid rgba(56, 189, 248, 0.25);
}


/* ==========================================================================
   COMMAND METRIC
   ========================================================================== */

.squad-command-strip {
    margin-bottom: 32px;
}


.squad-command-card {
    position: relative;

    display: flex;
    align-items: center;

    min-height: 108px;

    padding: 22px 24px;

    box-sizing: border-box;

    overflow: hidden;

    border: 1px solid rgba(71, 85, 105, 0.72);
    border-radius: 16px;

    background:
        radial-gradient(
            circle at 88% 30%,
            rgba(14, 165, 233, 0.12),
            transparent 28%
        ),
        linear-gradient(
            135deg,
            rgba(30, 41, 59, 0.98),
            rgba(15, 23, 42, 0.98)
        );

    box-shadow:
        0 12px 32px rgba(0, 0, 0, 0.14);
}


.squad-command-card::after {
    content: "";

    position: absolute;

    right: -80px;
    top: -100px;

    width: 230px;
    height: 230px;

    border: 1px solid rgba(56, 189, 248, 0.10);
    border-radius: 50%;

    pointer-events: none;
}


.squad-command-icon {
    width: 58px;
    height: 58px;

    flex: 0 0 58px;

    display: flex;
    align-items: center;
    justify-content: center;

    margin-right: 18px;

    border-radius: 14px;

    color: #38bdf8;

    background: rgba(56, 189, 248, 0.10);

    border: 1px solid rgba(56, 189, 248, 0.20);

    font-size: 1.3rem;
}


.squad-command-data {
    display: flex;
    flex-direction: column;
}


.squad-command-label {
    color: #64748b;

    font-size: 0.64rem;
    font-weight: 800;

    letter-spacing: 0.12em;
}


.squad-command-value {
    margin: 1px 0;

    color: #f8fafc;

    font-size: 1.8rem;
    font-weight: 800;

    line-height: 1;
}


.squad-command-description {
    color: #64748b;

    font-size: 0.72rem;
}


.squad-command-status {
    margin-left: auto;

    display: inline-flex;
    align-items: center;
    gap: 7px;

    padding: 7px 11px;

    border: 1px solid rgba(52, 211, 153, 0.18);
    border-radius: 999px;

    color: #34d399;

    background: rgba(52, 211, 153, 0.07);

    font-size: 0.66rem;
    font-weight: 700;

    text-transform: uppercase;
    letter-spacing: 0.08em;
}


.status-dot,
.squad-status-dot {
    width: 6px;
    height: 6px;

    display: inline-block;

    border-radius: 50%;

    background: #34d399;

    box-shadow:
        0 0 0 3px rgba(52, 211, 153, 0.10),
        0 0 12px rgba(52, 211, 153, 0.45);
}


/* ==========================================================================
   SECTION HEADER
   ========================================================================== */

.squad-section-header {
    display: flex;
    align-items: flex-end;
    justify-content: space-between;

    margin-bottom: 16px;
}


.squad-section-eyebrow {
    display: block;

    margin-bottom: 3px;

    color: #64748b;

    font-size: 0.62rem;
    font-weight: 800;

    letter-spacing: 0.14em;
}


.squad-section-header h2 {
    margin: 0;

    color: #e2e8f0;

    font-size: 1.08rem;
    font-weight: 750;
}


.squad-unit-count {
    padding: 5px 9px;

    border: 1px solid #334155;
    border-radius: 999px;

    color: #94a3b8;

    background: rgba(30, 41, 59, 0.55);

    font-size: 0.68rem;
    font-weight: 700;
}


/* ==========================================================================
   SQUAD GRID
   ========================================================================== */

.squad-page .squads-grid {
    display: grid;

    grid-template-columns:
        repeat(
            auto-fit,
            minmax(310px, 1fr)
        );

    gap: 18px;
}


/* ==========================================================================
   SQUAD CARD
   ========================================================================== */

.squad-page .squad-card {
    position: relative;

    min-width: 0;

    overflow: hidden;

    border: 1px solid #334155;
    border-radius: 16px;

    background:
        linear-gradient(
            145deg,
            rgba(30, 41, 59, 0.98),
            rgba(15, 23, 42, 0.98)
        );

    box-shadow:
        0 8px 25px rgba(0, 0, 0, 0.12);

    transition:
        transform 0.22s ease,
        border-color 0.22s ease,
        box-shadow 0.22s ease;
}


.squad-page .squad-card:hover {
    transform: translateY(-4px);

    border-color: rgba(56, 189, 248, 0.45);

    box-shadow:
        0 18px 42px rgba(0, 0, 0, 0.22),
        0 0 0 1px rgba(56, 189, 248, 0.04);
}


/* Top accent */

.squad-card-accent {
    position: absolute;

    top: 0;
    left: 0;
    right: 0;

    height: 2px;

    background:
        linear-gradient(
            90deg,
            transparent,
            #38bdf8 35%,
            #2dd4bf 65%,
            transparent
        );

    opacity: 0.75;
}


.squad-card-body {
    min-height: 280px;

    display: flex;
    flex-direction: column;

    padding: 20px;
}


/* ==========================================================================
   CARD HEADER
   ========================================================================== */

.squad-card-header {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;

    gap: 12px;

    margin-bottom: 20px;
}


.squad-card-identity {
    min-width: 0;
}


.squad-status-badge {
    display: inline-flex;
    align-items: center;
    gap: 7px;

    margin-bottom: 9px;

    padding: 4px 8px;

    border: 1px solid rgba(52, 211, 153, 0.20);
    border-radius: 999px;

    color: #34d399;

    background: rgba(52, 211, 153, 0.07);

    font-size: 0.59rem;
    font-weight: 800;

    letter-spacing: 0.09em;
}


.squad-name {
    margin: 0;

    overflow: hidden;

    color: #f8fafc;

    font-size: 1.05rem;
    font-weight: 750;

    line-height: 1.25;

    text-overflow: ellipsis;
    white-space: nowrap;
}


.squad-reference {
    display: block;

    margin-top: 5px;

    color: #64748b;

    font-size: 0.62rem;
    font-weight: 700;

    letter-spacing: 0.08em;
}


/* Menu */

.squad-menu-btn {
    width: 34px;
    height: 34px;

    flex: 0 0 34px;

    display: flex;
    align-items: center;
    justify-content: center;

    border: 1px solid transparent;
    border-radius: 9px;

    background: transparent;

    color: #64748b;

    cursor: pointer;

    transition:
        background 0.18s ease,
        border-color 0.18s ease,
        color 0.18s ease;
}


.squad-menu-btn:hover,
.squad-menu-btn:focus {
    color: #e2e8f0;

    background: #1e293b;

    border-color: #334155;
}


/* ==========================================================================
   DROPDOWN
   ========================================================================== */

.squad-page .squad-dropdown {
    min-width: 190px;

    padding: 6px;

    border: 1px solid #334155;
    border-radius: 10px;

    background: #0f172a;

    box-shadow:
        0 18px 40px rgba(0, 0, 0, 0.35);
}


.squad-page .squad-dropdown .dropdown-header {
    padding: 7px 10px;

    color: #475569;

    font-size: 0.58rem;
    font-weight: 800;

    letter-spacing: 0.1em;
}


.squad-page .squad-dropdown .dropdown-item {
    display: flex;
    align-items: center;
    gap: 9px;

    padding: 9px 10px;

    border-radius: 7px;

    color: #f87171;

    font-size: 0.76rem;
}


.squad-page .squad-dropdown .dropdown-item:hover {
    background: rgba(244, 63, 94, 0.10);

    color: #fb7185;
}


.squad-danger-action i {
    width: 16px;

    text-align: center;
}


/* ==========================================================================
   OPERATIONAL STATS
   ========================================================================== */

.squad-stats-row {
    display: grid;

    grid-template-columns: 1fr 1fr;

    gap: 10px;

    margin-bottom: 20px;
}


.squad-stat {
    display: flex;
    align-items: center;
    gap: 10px;

    min-width: 0;

    padding: 11px;

    border: 1px solid #263449;
    border-radius: 10px;

    background: rgba(15, 23, 42, 0.70);
}


.squad-stat-icon {
    width: 32px;
    height: 32px;

    flex: 0 0 32px;

    display: flex;
    align-items: center;
    justify-content: center;

    border-radius: 8px;

    color: #2dd4bf;

    background: rgba(45, 212, 191, 0.09);

    font-size: 0.72rem;
}


.squad-stat-icon-blue {
    color: #38bdf8;

    background: rgba(56, 189, 248, 0.09);
}


.squad-stat-label {
    display: block;

    color: #64748b;

    font-size: 0.59rem;
    font-weight: 800;

    text-transform: uppercase;
    letter-spacing: 0.08em;
}


.squad-stat-value {
    display: inline-block;

    margin-top: 2px;

    color: #e2e8f0;

    font-size: 1rem;
    font-weight: 800;

    line-height: 1;
}


.squad-stat-suffix {
    margin-left: 3px;

    color: #475569;

    font-size: 0.54rem;
    font-weight: 700;
}


/* ==========================================================================
   MEMBERS
   ========================================================================== */

.squad-members-section {
    margin-top: auto;

    padding-top: 15px;

    border-top: 1px solid rgba(51, 65, 85, 0.70);
}


.squad-members-heading {
    display: flex;
    align-items: center;
    justify-content: space-between;

    margin-bottom: 10px;

    color: #94a3b8;

    font-size: 0.63rem;
    font-weight: 800;

    text-transform: uppercase;
    letter-spacing: 0.08em;
}


.squad-members-count {
    min-width: 18px;
    height: 18px;

    display: inline-flex;
    align-items: center;
    justify-content: center;

    padding: 0 5px;

    border-radius: 999px;

    color: #38bdf8;

    background: rgba(56, 189, 248, 0.09);

    font-size: 0.58rem;
}


.avatar-stack-wrapper {
    display: flex;
    align-items: center;
    gap: 11px;
}


.avatar-stack {
    display: flex;
    align-items: center;
}


.squad-page .avatar-circle {
    width: 34px;
    height: 34px;

    flex: 0 0 34px;

    display: inline-flex;
    align-items: center;
    justify-content: center;

    margin-left: -9px;

    border: 2px solid #1e293b;
    border-radius: 50%;

    color: #ffffff;

    background:
        linear-gradient(
            135deg,
            #0284c7,
            #0369a1
        );

    box-shadow:
        0 2px 7px rgba(0, 0, 0, 0.25);

    font-size: 0.72rem;
    font-weight: 800;
}


.squad-page .avatar-circle:first-child {
    margin-left: 0;
}


.squad-page .avatar-2 {
    background:
        linear-gradient(
            135deg,
            #0d9488,
            #0f766e
        );
}


.squad-page .avatar-3 {
    background:
        linear-gradient(
            135deg,
            #7c3aed,
            #5b21b6
        );
}


.squad-page .avatar-4 {
    background:
        linear-gradient(
            135deg,
            #d97706,
            #b45309
        );
}


.squad-page .avatar-5 {
    background:
        linear-gradient(
            135deg,
            #db2777,
            #9d174d
        );
}


.squad-page .avatar-more {
    color: #cbd5e1;

    background: #334155;
}


.squad-members-caption {
    color: #64748b;

    font-size: 0.62rem;
}


/* No members */

.squad-no-members {
    display: flex;
    align-items: center;
    gap: 9px;

    color: #64748b;

    font-size: 0.68rem;
}


.squad-no-members-icon {
    width: 30px;
    height: 30px;

    display: flex;
    align-items: center;
    justify-content: center;

    border: 1px dashed #475569;
    border-radius: 8px;

    color: #64748b;
}


/* ==========================================================================
   CARD FOOTER
   ========================================================================== */

.squad-card-footer {
    display: flex;
    align-items: center;
    justify-content: space-between;

    margin-top: 18px;
    padding-top: 12px;

    border-top: 1px solid rgba(51, 65, 85, 0.55);

    color: #475569;

    font-size: 0.61rem;
    font-weight: 700;
}


.squad-card-footer span:first-child {
    display: inline-flex;
    align-items: center;
    gap: 6px;
}


.squad-card-footer i {
    color: #38bdf8;
}


.squad-card-arrow {
    opacity: 0;

    transform: translate(-3px, 3px);

    transition:
        opacity 0.18s ease,
        transform 0.18s ease;
}


.squad-card:hover .squad-card-arrow {
    opacity: 1;

    transform: translate(0, 0);
}


/* ==========================================================================
   EMPTY STATE
   ========================================================================== */

.squad-empty-state {
    grid-column: 1 / -1;

    min-height: 350px;

    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;

    padding: 50px 24px;

    box-sizing: border-box;

    border: 1px dashed #334155;
    border-radius: 18px;

    background:
        radial-gradient(
            circle at 50% 0%,
            rgba(56, 189, 248, 0.06),
            transparent 35%
        ),
        rgba(15, 23, 42, 0.45);

    text-align: center;
}


.empty-visual {
    position: relative;

    width: 86px;
    height: 86px;

    display: flex;
    align-items: center;
    justify-content: center;

    margin-bottom: 22px;
}


.empty-ring {
    position: absolute;

    border: 1px solid rgba(56, 189, 248, 0.12);

    border-radius: 50%;
}


.empty-ring-one {
    inset: 0;

    animation: squad-pulse 3s ease-in-out infinite;
}


.empty-ring-two {
    inset: 12px;

    border-color: rgba(45, 212, 191, 0.15);

    animation: squad-pulse 3s ease-in-out 0.5s infinite;
}


.empty-icon {
    position: relative;
    z-index: 2;

    width: 52px;
    height: 52px;

    display: flex;
    align-items: center;
    justify-content: center;

    border: 1px solid #334155;
    border-radius: 15px;

    background: #1e293b;

    color: #475569;

    font-size: 1.25rem;
}


.squad-empty-eyebrow {
    margin-bottom: 7px;

    color: #38bdf8;

    font-size: 0.61rem;
    font-weight: 800;

    letter-spacing: 0.14em;
}


.squad-empty-state h3 {
    margin: 0;

    color: #e2e8f0;

    font-size: 1.1rem;
    font-weight: 750;
}


.squad-empty-state p {
    max-width: 440px;

    margin: 8px auto 20px;

    color: #64748b;

    font-size: 0.78rem;

    line-height: 1.6;
}


.squad-empty-action {
    display: inline-flex;
    align-items: center;
    gap: 8px;

    padding: 9px 15px;

    border: 1px solid #334155;
    border-radius: 9px;

    background: #1e293b;

    color: #cbd5e1;

    font-family: inherit;

    font-size: 0.72rem;
    font-weight: 700;

    cursor: pointer;

    transition:
        background 0.18s ease,
        border-color 0.18s ease,
        color 0.18s ease;
}


.squad-empty-action:hover {
    background: #263449;

    border-color: #38bdf8;

    color: #f8fafc;
}


@keyframes squad-pulse {

    0%,
    100% {
        transform: scale(1);
        opacity: 0.55;
    }

    50% {
        transform: scale(1.06);
        opacity: 1;
    }
}


/* ==========================================================================
   CREATE SQUAD MODAL
   ========================================================================== */

.squad-page + #createTeamModal,
.squad-page ~ #createTeamModal {
    /* intentionally empty:
       Bootstrap controls modal positioning.
    */
}


/*
   The modal sits inside the template but outside .squad-page.
   Therefore modal-specific selectors deliberately use the unique
   #createTeamModal ID rather than relying on generic classes.
*/

#createTeamModal .squad-modal {
    overflow: hidden;

    border: 1px solid #334155;
    border-radius: 16px;

    background: #0f172a;

    box-shadow:
        0 30px 80px rgba(0, 0, 0, 0.55);
}


#createTeamModal .squad-modal-header {
    padding: 22px 24px;

    border: 0;

    background:
        radial-gradient(
            circle at 100% 0%,
            rgba(56, 189, 248, 0.18),
            transparent 35%
        ),
        linear-gradient(
            135deg,
            #172554,
            #0f172a
        );
}


.squad-modal-heading {
    display: flex;
    align-items: center;
    gap: 13px;
}


#createTeamModal .modal-header-icon {
    width: 42px;
    height: 42px;

    flex: 0 0 42px;

    display: flex;
    align-items: center;
    justify-content: center;

    border: 1px solid rgba(56, 189, 248, 0.24);
    border-radius: 11px;

    background: rgba(56, 189, 248, 0.10);

    color: #38bdf8;

    font-size: 1rem;
}


.squad-modal-eyebrow {
    display: block;

    margin-bottom: 3px;

    color: #38bdf8;

    font-size: 0.58rem;
    font-weight: 800;

    letter-spacing: 0.14em;
}


#createTeamModal .modal-title {
    color: #f8fafc;

    font-size: 1.05rem;
    font-weight: 750;
}


.squad-modal-heading p {
    margin: 3px 0 0;

    color: #64748b;

    font-size: 0.68rem;
}


#createTeamModal .squad-modal-body {
    padding: 24px;

    background:
        linear-gradient(
            180deg,
            #0f172a,
            #111c30
        );
}


.squad-form-section + .squad-form-section {
    margin-top: 25px;
}


.squad-form-section-heading {
    display: flex;
    align-items: flex-start;
    gap: 10px;

    margin-bottom: 10px;
}


.squad-form-number {
    width: 24px;
    height: 24px;

    flex: 0 0 24px;

    display: flex;
    align-items: center;
    justify-content: center;

    border: 1px solid #334155;
    border-radius: 7px;

    color: #38bdf8;

    background: rgba(56, 189, 248, 0.06);

    font-size: 0.58rem;
    font-weight: 800;
}


.squad-modal-label {
    display: block;

    margin: 0;

    color: #e2e8f0;

    font-size: 0.72rem;
    font-weight: 750;
}


.squad-form-help {
    display: block;

    margin-top: 2px;

    color: #64748b;

    font-size: 0.63rem;
}


.squad-input-shell {
    position: relative;
}


.squad-input-shell > i {
    position: absolute;

    left: 13px;
    top: 50%;

    transform: translateY(-50%);

    z-index: 2;

    color: #64748b;

    font-size: 0.72rem;

    pointer-events: none;
}


#createTeamModal .squad-form-control {
    width: 100%;
    min-height: 44px;

    box-sizing: border-box;

    padding: 0 14px 0 37px;

    border: 1px solid #334155;
    border-radius: 9px;

    outline: none;

    background: #0b1220;

    color: #f8fafc;

    font-family: inherit;

    font-size: 0.78rem;

    transition:
        border-color 0.18s ease,
        box-shadow 0.18s ease,
        background 0.18s ease;
}


#createTeamModal .squad-form-control::placeholder {
    color: #475569;
}


#createTeamModal .squad-form-control:focus {
    border-color: #0284c7;

    background: #0f172a;

    box-shadow:
        0 0 0 3px rgba(2, 132, 199, 0.12);
}


#createTeamModal .squad-form-control.is-invalid {
    border-color: #f43f5e;
}


.squad-field-error {
    display: flex;
    align-items: center;
    gap: 6px;

    margin-top: 6px;

    color: #fb7185;

    font-size: 0.66rem;
}


/* ==========================================================================
   MEMBER SELECTOR
   ========================================================================== */

#createTeamModal .member-selector-box {
    display: grid;

    grid-template-columns:
        repeat(
            auto-fill,
            minmax(190px, 1fr)
        );

    gap: 8px;

    max-height: 250px;

    overflow-y: auto;

    padding: 12px;

    border: 1px solid #334155;
    border-radius: 11px;

    background: #0b1220;
}


.member-selector-item {
    min-width: 0;
}


.member-pill-checkbox {
    position: absolute;

    opacity: 0;

    pointer-events: none;
}


#createTeamModal .member-pill-label {
    position: relative;

    display: flex;
    align-items: center;
    gap: 9px;

    width: 100%;
    min-height: 42px;

    box-sizing: border-box;

    padding: 6px 9px;

    border: 1px solid #263449;
    border-radius: 9px;

    background: #111c30;

    color: #cbd5e1;

    cursor: pointer;

    transition:
        background 0.16s ease,
        border-color 0.16s ease,
        color 0.16s ease,
        transform 0.16s ease;
}


#createTeamModal .member-pill-label:hover {
    transform: translateY(-1px);

    border-color: #475569;

    background: #172337;

    color: #f8fafc;
}


.member-pill-avatar {
    width: 26px;
    height: 26px;

    flex: 0 0 26px;

    display: flex;
    align-items: center;
    justify-content: center;

    border-radius: 7px;

    background: rgba(56, 189, 248, 0.08);

    color: #38bdf8;

    font-size: 0.62rem;
}


.member-pill-name {
    min-width: 0;

    overflow: hidden;

    font-size: 0.7rem;
    font-weight: 650;

    text-overflow: ellipsis;
    white-space: nowrap;
}


.member-pill-check {
    width: 20px;
    height: 20px;

    margin-left: auto;

    flex: 0 0 20px;

    display: flex;
    align-items: center;
    justify-content: center;

    border: 1px solid #334155;
    border-radius: 6px;

    color: transparent;

    font-size: 0.55rem;
}


.member-pill-checkbox:checked + .member-pill-label {
    border-color: rgba(56, 189, 248, 0.55);

    background:
        linear-gradient(
            135deg,
            rgba(2, 132, 199, 0.20),
            rgba(14, 116, 144, 0.10)
        );

    color: #f8fafc;

    box-shadow:
        inset 0 0 0 1px rgba(56, 189, 248, 0.06);
}


.member-pill-checkbox:checked + .member-pill-label .member-pill-avatar {
    background: rgba(56, 189, 248, 0.16);

    color: #7dd3fc;
}


.member-pill-checkbox:checked + .member-pill-label .member-pill-check {
    border-color: #38bdf8;

    background: #0284c7;

    color: #ffffff;
}


.no-users-available {
    grid-column: 1 / -1;

    display: flex;
    align-items: center;
    justify-content: center;

    gap: 10px;

    min-height: 90px;

    color: #64748b;

    text-align: left;
}


.no-users-available > i {
    font-size: 1.2rem;
}


.no-users-available strong,
.no-users-available span {
    display: block;
}


.no-users-available strong {
    color: #94a3b8;

    font-size: 0.72rem;
}


.no-users-available span {
    margin-top: 3px;

    font-size: 0.62rem;
}


/* ==========================================================================
   MODAL FOOTER
   ========================================================================== */

#createTeamModal .squad-modal-footer {
    display: flex;
    align-items: center;
    justify-content: flex-end;

    gap: 9px;

    padding: 16px 24px;

    border-top: 1px solid #263449;

    background: #0b1220;
}


#createTeamModal .btn-squad-cancel,
#createTeamModal .btn-squad-submit {
    min-height: 38px;

    padding: 0 14px;

    border-radius: 8px;

    font-family: inherit;

    font-size: 0.7rem;
    font-weight: 700;

    cursor: pointer;

    transition:
        background 0.18s ease,
        border-color 0.18s ease,
        transform 0.18s ease;
}


#createTeamModal .btn-squad-cancel {
    border: 1px solid #334155;

    background: transparent;

    color: #94a3b8;
}


#createTeamModal .btn-squad-cancel:hover {
    border-color: #475569;

    background: #1e293b;

    color: #f8fafc;
}


#createTeamModal .btn-squad-submit {
    display: inline-flex;
    align-items: center;
    gap: 8px;

    border: 1px solid rgba(56, 189, 248, 0.30);

    background:
        linear-gradient(
            135deg,
            #0284c7,
            #0369a1
        );

    color: #ffffff;

    box-shadow:
        0 6px 18px rgba(2, 132, 199, 0.18);
}


#createTeamModal .btn-squad-submit:hover {
    transform: translateY(-1px);

    box-shadow:
        0 9px 24px rgba(2, 132, 199, 0.28);
}


/* ==========================================================================
   RESPONSIVE
   ========================================================================== */

@media (max-width: 900px) {

    .squad-page {
        padding: 22px;
    }

    .squad-page-header {
        align-items: flex-start;
    }

    .squad-command-status {
        display: none;
    }
}


@media (max-width: 640px) {

    .squad-page {
        padding: 16px;
    }

    .squad-page-header {
        flex-direction: column;
        align-items: stretch;

        gap: 16px;
    }


    .squad-heading {
        align-items: flex-start;
    }


    .squad-heading-icon {
        width: 44px;
        height: 44px;

        flex-basis: 44px;

        border-radius: 12px;
    }


    .squad-page-title {
        font-size: 1.45rem;
    }


    .squad-page-subtitle {
        max-width: 430px;

        font-size: 0.75rem;

        line-height: 1.5;
    }


    .squad-primary-action {
        width: 100%;

        justify-content: center;
    }


    .squad-command-card {
        padding: 18px;
    }


    .squad-command-icon {
        width: 48px;
        height: 48px;

        flex-basis: 48px;

        margin-right: 13px;
    }


    .squad-command-value {
        font-size: 1.55rem;
    }


    .squad-page .squads-grid {
        grid-template-columns: 1fr;
    }


    #createTeamModal .modal-dialog {
        margin: 10px;
    }


    #createTeamModal .squad-modal-body {
        padding: 18px;
    }


    #createTeamModal .member-selector-box {
        grid-template-columns: 1fr;
    }


    #createTeamModal .squad-modal-footer {
        padding: 13px 18px;
    }

}


@media (max-width: 420px) {

    .squad-page {
        padding: 12px;
    }


    .squad-heading-icon {
        display: none;
    }


    .squad-page-title {
        font-size: 1.3rem;
    }


    .squad-page-subtitle {
        font-size: 0.71rem;
    }


    .squad-command-card {
        min-height: 90px;

        padding: 15px;
    }


    .squad-command-icon {
        width: 42px;
        height: 42px;

        flex-basis: 42px;

        font-size: 1rem;
    }


    .squad-command-label {
        font-size: 0.56rem;
    }


    .squad-command-value {
        font-size: 1.35rem;
    }


    .squad-command-description {
        font-size: 0.61rem;
    }


    .squad-card-body {
        padding: 17px;

        min-height: 270px;
    }


    .squad-stats-row {
        gap: 7px;
    }


    .squad-stat {
        padding: 9px;
    }


    .squad-stat-icon {
        width: 28px;
        height: 28px;

        flex-basis: 28px;
    }


    .squad-members-caption {
        display: none;
    }


    #createTeamModal .squad-modal-header {
        padding: 18px;
    }


    .squad-modal-heading p {
        display: none;
    }


    #createTeamModal .squad-modal-footer {
        flex-direction: column-reverse;
    }


    #createTeamModal .btn-squad-cancel,
    #createTeamModal .btn-squad-submit {
        width: 100%;

        justify-content: center;
    }

}

/* ==========================================================================
   DAILY FIELD DISPATCHES STYLES
   ========================================================================== */


.dispatches-container {
    width: 100%;
    max-width: 1600px;
    margin: 0 auto;
    padding: 28px 30px 40px;
    color: #172033;
}

/* ============================================================
   HEADER
   ============================================================ */

.dispatches-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-end;
    gap: 24px;
    margin-bottom: 24px !important;
}

.dispatches-title {
    margin: 0;
    color: #111827;
    font-size: 1.45rem;
    font-weight: 800;
    letter-spacing: -0.025em;
}

.dispatches-title .icon-primary {
    color:  #3983ac;
}

.dispatches-subtitle {
    margin-top: 7px !important;
    color: #64748b !important;
    font-size: 0.84rem;
    font-weight: 500;
}

/* ============================================================
   DATE CONTROLLER
   ============================================================ */

.date-filter-form {
    flex-shrink: 0;
}

.date-input-group {
    height: 42px;
    padding: 0 11px;

    border: 1px solid #dbe1e8;
    border-radius: 9px;

    background: #ffffff;
}

.date-input-label {
    margin: 0 !important;
    color: #64748b;
    font-size: 0.72rem;
    font-weight: 700;
    white-space: nowrap;
}

.date-input-label .icon-primary {
    color:  #3983ac;
}

.date-input-field {
    width: 145px !important;
    height: 34px !important;
    padding: 0 6px !important;

    border: 0 !important;
    outline: 0 !important;
    box-shadow: none !important;

    background: transparent !important;
    color: #334155;

    font-size: 0.76rem;
    font-weight: 600;
}

.date-filter-form > .btn {
    height: 42px;
    padding: 0 15px;

    border-radius: 9px;

    font-size: 0.76rem;
    font-weight: 700;
}

/* ============================================================
   ALERTS
   ============================================================ */

.dispatch-alert {
    display: flex;
    align-items: center;
    gap: 8px;

    margin-bottom: 18px !important;
    padding: 11px 14px;

    border-radius: 9px;

    font-size: 0.78rem;
    font-weight: 600;
}

.dispatch-alert .btn-close {
    margin-left: auto;
}

/* ============================================================
   METRICS
   ============================================================ */

.dispatch-metrics-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 16px;

    margin-bottom: 20px !important;
}

.dispatch-metric-card {
    position: relative;

    display: flex;
    align-items: center;
    gap: 14px;

    min-height: 94px;
    padding: 18px 20px;

    overflow: hidden;

    background: #ffffff;
    border: 1px solid #e5e7eb;
    border-radius: 14px;

    box-shadow:
        0 1px 2px rgba(15, 23, 42, 0.03),
        0 5px 18px rgba(15, 23, 42, 0.04);

    transition:
        transform 0.2s ease,
        box-shadow 0.2s ease;
}

.dispatch-metric-card:hover {
    transform: translateY(-2px);

    box-shadow:
        0 4px 8px rgba(15, 23, 42, 0.05),
        0 12px 28px rgba(15, 23, 42, 0.07);
}

.dispatch-metric-card::before {
    content: "";

    position: absolute;
    inset: 0 auto auto 0;

    width: 100%;
    height: 3px;

    background:  #3983ac;
}

.dispatch-metric-card:nth-child(2)::before {
    background: #16a34a;
}

.dispatch-metric-card:nth-child(3)::before {
    background: #0d9488;
}

/* ============================================================
   METRIC ICONS
   ============================================================ */

.dispatch-metric-card .metric-icon-box {
    flex: 0 0 46px;

    width: 46px;
    height: 46px;

    display: flex;
    align-items: center;
    justify-content: center;

    border-radius: 12px;

    font-size: 1rem;
}

.dispatch-metric-card .metric-icon-box.icon-blue {
    color:  #3983ac;
    background: #eff6ff;
}

.dispatch-metric-card .metric-icon-box.icon-green {
    color: #16a34a;
    background: #f0fdf4;
}

.dispatch-metric-card .metric-icon-box.icon-teal {
    color: #0d9488;
    background: #f0fdfa;
}

.dispatch-metric-card .metric-label {
    display: block;

    margin-bottom: 3px;

    color: #64748b;

    font-size: 0.68rem;
    font-weight: 800;

    text-transform: uppercase;
    letter-spacing: 0.045em;
}

.dispatch-metric-card .metric-value {
    margin: 0;

    color: #111827;

    font-size: 1.55rem;
    font-weight: 800;
    line-height: 1.1;
}

/* ============================================================
   MAIN TWO-COLUMN LAYOUT
   ============================================================ */

.dispatch-layout-grid {
    display: grid;

    grid-template-columns: minmax(300px, 350px) minmax(0, 1fr);

    gap: 20px;

    align-items: start;
}

/* ============================================================
   FORM CARD
   ============================================================ */

.dispatch-form-card,
.dispatch-table-card {
    overflow: hidden;

    background: #ffffff;

    border: 1px solid #e5e7eb;
    border-radius: 14px;

    box-shadow:
        0 1px 2px rgba(15, 23, 42, 0.03),
        0 5px 18px rgba(15, 23, 42, 0.035);
}

.dispatch-card-header {
    display: flex;
    align-items: center;

    min-height: 56px;
    padding: 0 18px;

    background: linear-gradient(
        135deg,
        #1e3a8a,
         #3983ac
    );

    border-bottom: 1px solid  #3983ac;
}

.dispatch-card-title {
    color: #172033;
    font-size: 0.84rem;
    font-weight: 800;
}

.dispatch-card-header .dispatch-card-title {
    color: #ffffff !important;
}

.dispatch-card-header .fa-paper-plane {
    opacity: 0.9;
}

.dispatch-card-body {
    padding: 20px !important;
}

/* ============================================================
   FORM FIELDS
   ============================================================ */

.form-group-custom {
    margin-bottom: 16px !important;
}

.dispatch-label {
    display: block;

    margin-bottom: 7px !important;

    color: #334155;

    font-size: 0.73rem;
    font-weight: 800;
}

.form-group-custom .select2-container {
    width: 100% !important;
}

/*
   Select2 Bootstrap theme
   Scoped to dispatch page only.
*/

.dispatch-form-card .select2-container--bootstrap-5 .select2-selection {
    min-height: 43px;

    border-color: #dbe1e8;
    border-radius: 8px;

    background: #f8fafc;

    box-shadow: none;

    transition:
        border-color 0.2s ease,
        box-shadow 0.2s ease,
        background 0.2s ease;
}

.dispatch-form-card
.select2-container--bootstrap-5
.select2-selection:hover {
    background: #ffffff;
    border-color: #cbd5e1;
}

.dispatch-form-card
.select2-container--bootstrap-5.select2-container--focus
.select2-selection,
.dispatch-form-card
.select2-container--bootstrap-5.select2-container--open
.select2-selection {
    background: #ffffff;
    border-color:  #3983ac;

    box-shadow:
        0 0 0 3px rgba(37, 99, 235, 0.10);
}

.dispatch-form-card
.select2-container--bootstrap-5
.select2-selection__rendered {
    color: #334155;

    font-size: 0.78rem;
    font-weight: 500;
}

.dispatch-form-card
.select2-container--bootstrap-5
.select2-selection__placeholder {
    color: #94a3b8;
}

.dispatch-form-card
.select2-container--bootstrap-5
.select2-selection__arrow {
    top: 8px;
}

/* Native inputs/selects if Select2 isn't applied */

.dispatch-form-card
.form-control,
.dispatch-form-card
.form-select {
    min-height: 43px;

    border-color: #dbe1e8;
    border-radius: 8px;

    background-color: #f8fafc;

    color: #334155;

    font-size: 0.78rem;
    font-weight: 500;

    box-shadow: none;

    transition:
        border-color 0.2s ease,
        box-shadow 0.2s ease,
        background 0.2s ease;
}

.dispatch-form-card
.form-control:hover,
.dispatch-form-card
.form-select:hover {
    background: #ffffff;
    border-color: #cbd5e1;
}

.dispatch-form-card
.form-control:focus,
.dispatch-form-card
.form-select:focus {
    background: #ffffff;
    border-color:  #3983ac;

    box-shadow:
        0 0 0 3px rgba(37, 99, 235, 0.10);
}

/* Validation */

.dispatch-field-error {
    margin-top: 5px !important;

    color: #dc2626 !important;

    font-size: 0.69rem !important;
    font-weight: 600;
}

/* Submit */

.dispatch-form-card form > .btn-primary {
    min-height: 44px;

    border: 0;
    border-radius: 8px;

    background:  #3983ac;

    font-size: 0.78rem;
    font-weight: 800;

    box-shadow:
        0 3px 8px rgba(37, 99, 235, 0.20);

    transition:
        background 0.2s ease,
        transform 0.2s ease,
        box-shadow 0.2s ease;
}

.dispatch-form-card form > .btn-primary:hover {
    background:  #3983ac;

    transform: translateY(-1px);

    box-shadow:
        0 5px 14px rgba(37, 99, 235, 0.25);
}

/* ============================================================
   TABLE CARD
   ============================================================ */

.dispatch-table-card {
    min-width: 0;
}

.dispatch-table-header {
    min-height: 56px;

    padding: 0 18px;

    background: #ffffff;

    border-bottom: 1px solid #e5e7eb;
}

.dispatch-table-header .dispatch-card-title {
    color: #1e293b;
}

.dispatch-count-pill {
    padding: 5px 9px;

    border-radius: 999px !important;

    background: #f1f5f9 !important;
    color: #64748b !important;

    font-size: 0.64rem !important;
    font-weight: 800 !important;
}

/* ============================================================
   TABLE
   ============================================================ */

.dispatch-table-wrapper {
    width: 100%;
    overflow-x: auto;

    -webkit-overflow-scrolling: touch;
}

.dispatch-table {
    width: 100%;
    min-width: 720px;

    margin: 0 !important;

    border-collapse: separate;
    border-spacing: 0;

    font-size: 0.78rem;
}

.dispatch-table thead th {
    height: 47px;

    padding: 0 12px;

    background: #f8fafc;

    border-bottom: 1px solid #e5e7eb;

    color: #64748b;

    font-size: 0.65rem;
    font-weight: 800;

    text-transform: uppercase;
    letter-spacing: 0.05em;

    white-space: nowrap;
}

.dispatch-table tbody td {
    height: 65px;

    padding: 10px 12px;

    border-bottom: 1px solid #eef2f7;

    color: #475569;

    vertical-align: middle;

    white-space: nowrap;
}

.dispatch-table tbody tr:last-child td {
    border-bottom: 0;
}

.dispatch-table tbody tr {
    transition: background 0.15s ease;
}

.dispatch-table tbody tr:hover {
    background: #f8fbff;
}

/* ============================================================
   SQUAD CELL
   ============================================================ */

.squad-icon-badge {
    flex: 0 0 34px;

    width: 34px;
    height: 34px;

    display: flex;
    align-items: center;
    justify-content: center;

    border-radius: 9px;

    background: #eff6ff;
    color:  #3983ac;

    font-size: 0.75rem;
}

.squad-team-name {
    color: #1e293b;

    font-size: 0.78rem;
    font-weight: 700 !important;
}

.county-text {
    color: #334155;
    font-weight: 600;
}

.subcounty-text {
    color: #64748b;
    font-weight: 500;
}

/* ============================================================
   BLOCK BADGE
   ============================================================ */

.block-badge {
    display: inline-flex;
    align-items: center;

    padding: 5px 8px !important;

    border: 1px solid #dbeafe !important;
    border-radius: 6px !important;

    background: #eff6ff !important;
    color:  #3983ac !important;

    font-size: 0.67rem !important;
    font-weight: 700 !important;
}

.block-badge i {
    font-size: 0.62rem;
}

/* ============================================================
   OFFICERS
   ============================================================ */

.officers-pill {
    display: inline-flex;
    align-items: center;

    padding: 5px 9px !important;

    border: 1px solid #ccfbf1;

    border-radius: 999px !important;

    background: #f0fdfa !important;
    color: #0f766e !important;

    font-size: 0.66rem !important;
    font-weight: 800 !important;
}

.officers-pill i {
    font-size: 0.62rem;
}

/* ============================================================
   EMPTY STATE
   ============================================================ */

.dispatch-empty-state {
    padding: 65px 20px !important;
}

.dispatch-empty-state .empty-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;

    width: 54px;
    height: 54px;

    margin-bottom: 14px !important;

    border-radius: 14px;

    background: #f1f5f9;

    color: #94a3b8 !important;

    font-size: 1.2rem !important;
}

.dispatch-empty-state .empty-title {
    margin-bottom: 6px;

    color: #334155;

    font-size: 0.92rem;
    font-weight: 800;
}

.dispatch-empty-state .empty-desc {
    max-width: 400px;

    margin: 0 auto;

    color: #94a3b8 !important;

    font-size: 0.75rem;
    line-height: 1.5;
}

/* ============================================================
   SELECT2 DROPDOWN
   ============================================================ */

.select2-container--bootstrap-5 .select2-dropdown {
    overflow: hidden;

    border: 1px solid #dbe1e8;
    border-radius: 9px;

    box-shadow:
        0 10px 30px rgba(15, 23, 42, 0.10);
}

.select2-container--bootstrap-5
.select2-search__field {
    border-color: #dbe1e8 !important;
    border-radius: 7px !important;

    font-size: 0.76rem !important;
}

.select2-container--bootstrap-5
.select2-results__option {
    padding: 9px 11px;

    font-size: 0.75rem;
}

.select2-container--bootstrap-5
.select2-results__option--highlighted {
    background: #eff6ff !important;
    color:  #3983ac !important;
}

.select2-container--bootstrap-5
.select2-results__option[aria-selected="true"] {
    background: #dbeafe !important;
    color:  #3983ac !important;
}

/* ============================================================
   TABLET
   ============================================================ */

@media (max-width: 1100px) {

    .dispatches-container {
        padding: 24px 20px 35px;
    }

    .dispatch-layout-grid {
        grid-template-columns: 300px minmax(0, 1fr);
        gap: 16px;
    }

    .dispatch-table {
        min-width: 700px;
    }
}

/* ============================================================
   MOBILE
   ============================================================ */

@media (max-width: 800px) {

    .dispatches-container {
        padding: 20px 14px 30px;
    }

    .dispatches-header {
        align-items: flex-start !important;
        flex-direction: column;

        gap: 15px;

        margin-bottom: 18px !important;
    }

    .dispatches-title {
        font-size: 1.2rem;
    }

    .dispatches-subtitle {
        font-size: 0.76rem;
        line-height: 1.5;
    }

    .date-filter-form {
        width: 100%;
        align-items: stretch !important;
    }

    .date-input-group {
        flex: 1;
    }

    .date-input-field {
        width: 100% !important;
    }

    .date-filter-form > .btn {
        flex: 0 0 auto;
    }

    .dispatch-metrics-grid {
        grid-template-columns: 1fr;
        gap: 10px;
    }

    .dispatch-metric-card {
        min-height: 80px;
        padding: 14px;
        border-radius: 11px;
    }

    .dispatch-layout-grid {
        grid-template-columns: 1fr;
        gap: 14px;
    }

    .dispatch-form-card {
        order: 1;
    }

    .dispatch-table-card {
        order: 2;
    }

    .dispatch-table-header {
        min-height: 54px;
        padding: 0 14px;
    }

    .dispatch-table-header .dispatch-card-title {
        font-size: 0.76rem;
    }

    .dispatch-table {
        min-width: 720px;
    }
}

/* ============================================================
   SMALL PHONES
   ============================================================ */

@media (max-width: 480px) {

    .dispatches-container {
        padding: 16px 10px 25px;
    }

    .dispatches-title {
        font-size: 1.05rem;
    }

    .dispatches-subtitle {
        font-size: 0.71rem;
    }

    .date-filter-form {
        flex-direction: column;
    }

    .date-input-group {
        width: 100%;
    }

    .date-filter-form > .btn {
        width: 100%;
    }

    .dispatch-metric-card {
        min-height: 72px;
    }

    .dispatch-metric-card .metric-icon-box {
        flex-basis: 38px;
        width: 38px;
        height: 38px;
        border-radius: 10px;
    }

    .dispatch-metric-card .metric-value {
        font-size: 1.25rem;
    }

    .dispatch-card-body {
        padding: 15px !important;
    }

    .dispatch-card-header {
        min-height: 52px;
        padding: 0 15px;
    }

    .dispatch-table {
        min-width: 700px;
    }

    .dispatch-empty-state {
        padding: 50px 15px !important;
    }
}

/* ============================================================
   REDUCED MOTION
   ============================================================ */

@media (prefers-reduced-motion: reduce) {

    .dispatch-metric-card,
    .dispatch-table tbody tr,
    .dispatch-form-card form > .btn-primary {
        transition: none;
    }
}
/* ==========================================================================
   NOTICE AUDIT LOGS STYLES
   ========================================================================== */

.audit-container {
    padding: 24px;
    max-width: 1400px;
    margin: 0 auto;
}

/* Header */
.audit-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 24px;
}

.audit-title {
    font-size: 1.5rem;
    font-weight: 700;
    color: #f8fafc;
    margin: 0 0 4px 0;
    display: flex;
    align-items: center;
    gap: 10px;
}

.icon-primary {
    color: #38bdf8;
}

.audit-subtitle {
    color: #94a3b8;
    font-size: 0.88rem;
    margin: 0;
}

/* Metric Cards */
.audit-metrics-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 16px;
}

.audit-metric-card {
    background-color: #1e293b;
    border: 1px solid #334155;
    border-radius: 12px;
    padding: 18px;
    display: flex;
    align-items: center;
    gap: 16px;
}

.audit-metric-card.border-blue { border-left: 4px solid #38bdf8; }
.audit-metric-card.border-green { border-left: 4px solid #34d399; }
.audit-metric-card.border-amber { border-left: 4px solid #fbbf24; }
.audit-metric-card.border-rose { border-left: 4px solid #f43f5e; }

.metric-icon-box {
    width: 48px;
    height: 48px;
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.2rem;
}

.icon-blue { background: rgba(56, 189, 248, 0.12); color: #38bdf8; }
.icon-green { background: rgba(52, 211, 153, 0.12); color: #34d399; }
.icon-amber { background: rgba(251, 191, 36, 0.12); color: #fbbf24; }
.icon-rose { background: rgba(244, 63, 94, 0.12); color: #f43f5e; }

.metric-label {
    display: block;
    font-size: 0.72rem;
    font-weight: 700;
    text-transform: uppercase;
    color: #94a3b8;
    letter-spacing: 0.5px;
}

.metric-value {
    font-size: 1.4rem;
    font-weight: 800;
    color: #f8fafc;
    margin: 2px 0 0 0;
}

.text-green { color: #34d399; }
.text-amber { color: #fbbf24; }
.text-rose { color: #f43f5e; }

/* Filter Layout */
.audit-card {
    background-color: #1e293b;
    border: 1px solid #334155;
    border-radius: 12px;
    overflow: hidden;
}

.audit-card-body {
    padding: 16px;
}

.filter-grid {
    display: grid;
    grid-template-columns: 1fr 240px auto;
    gap: 12px;
}

@media (max-width: 768px) {
    .filter-grid {
        grid-template-columns: 1fr;
    }
}

.filter-search-group {
    position: relative;
    display: flex;
    align-items: center;
}

.filter-input-icon {
    position: absolute;
    left: 12px;
    color: #64748b;
    font-size: 0.85rem;
}

.audit-input-field {
    width: 100%;
    padding: 10px 12px 10px 36px;
    background-color: #0f172a;
    border: 1px solid #334155;
    border-radius: 8px;
    color: #f8fafc;
    font-size: 0.88rem;
    transition: border-color 0.2s ease;
}

.audit-select-field {
    width: 100%;
    padding: 10px 12px;
    background-color: #0f172a;
    border: 1px solid #334155;
    border-radius: 8px;
    color: #f8fafc;
    font-size: 0.88rem;
    transition: border-color 0.2s ease;
}

.audit-input-field:focus,
.audit-select-field:focus {
    outline: none;
    border-color: #0284c7;
    box-shadow: 0 0 0 3px rgba(2, 132, 199, 0.2);
}

.filter-actions-group {
    display: flex;
    gap: 8px;
}

.btn-audit-filter {
    background-color: #0284c7;
    color: #ffffff;
    border: none;
    border-radius: 8px;
    padding: 0 18px;
    font-weight: 700;
    font-size: 0.88rem;
    cursor: pointer;
    transition: background-color 0.2s ease;
}

.btn-audit-filter:hover {
    background-color: #0369a1;
}

.btn-audit-reset {
    display: flex;
    align-items: center;
    justify-content: center;
    background-color: #0f172a;
    border: 1px solid #334155;
    color: #94a3b8;
    border-radius: 8px;
    padding: 0 14px;
    transition: background-color 0.2s ease, color 0.2s ease;
}

.btn-audit-reset:hover {
    background-color: #334155;
    color: #f8fafc;
}

/* Data Table */
.audit-table-wrapper {
    overflow-x: auto;
}

.audit-table {
    width: 100%;
    border-collapse: collapse;
    text-align: left;
}

.audit-table thead th {
    background-color: #0f172a;
    color: #64748b;
    font-size: 0.72rem;
    font-weight: 700;
    text-transform: uppercase;
    padding: 12px 16px;
    border-bottom: 1px solid #334155;
    letter-spacing: 0.5px;
}

.audit-table tbody td {
    padding: 14px 16px;
    border-bottom: 1px solid #334155;
    vertical-align: middle;
}

.audit-table tbody tr:last-child td {
    border-bottom: none;
}

.audit-table tbody tr:hover {
    background-color: rgba(51, 65, 85, 0.4);
}

/* Table Elements */
.parcel-code-text {
    font-weight: 700;
    color: #38bdf8;
    font-size: 0.88rem;
}

.rate-payer-name {
    font-weight: 600;
    color: #f8fafc;
    font-size: 0.88rem;
}

.rate-payer-id {
    color: #64748b;
    font-size: 0.78rem;
    display: block;
}

.amount-value {
    font-weight: 700;
    color: #cbd5e1;
    font-size: 0.88rem;
}

.collector-text, .date-text {
    color: #cbd5e1;
    font-size: 0.85rem;
}

/* Status Badges */
.status-pill {
    display: inline-flex;
    align-items: center;
    padding: 4px 10px;
    border-radius: 20px;
    font-size: 0.75rem;
    font-weight: 700;
}

.status-issued { background-color: rgba(56, 189, 248, 0.15); color: #38bdf8; border: 1px solid rgba(56, 189, 248, 0.3); }
.status-paid { background-color: rgba(52, 211, 153, 0.15); color: #34d399; border: 1px solid rgba(52, 211, 153, 0.3); }
.status-pending { background-color: rgba(251, 191, 36, 0.15); color: #fbbf24; border: 1px solid rgba(251, 191, 36, 0.3); }
.status-disputed { background-color: rgba(244, 63, 94, 0.15); color: #f43f5e; border: 1px solid rgba(244, 63, 94, 0.3); }

.btn-map-action {
    background-color: rgba(2, 132, 199, 0.15);
    border: 1px solid rgba(2, 132, 199, 0.3);
    color: #38bdf8;
    font-size: 0.78rem;
    font-weight: 700;
    padding: 5px 12px;
    border-radius: 6px;
    cursor: pointer;
    transition: background-color 0.2s ease;
}

.btn-map-action:hover {
    background-color: #0284c7;
    color: #ffffff;
}

.no-location-text {
    color: #64748b;
    font-size: 0.8rem;
}

/* Pagination Footer */
.audit-card-footer {
    background-color: #0f172a;
    padding: 12px 20px;
    border-top: 1px solid #334155;
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 12px;
}

.pagination-info {
    color: #64748b;
    font-size: 0.8rem;
}

.audit-pagination {
    display: flex;
    align-items: center;
    gap: 6px;
}

.page-nav-link {
    background-color: #1e293b;
    border: 1px solid #334155;
    color: #f8fafc;
    padding: 4px 10px;
    border-radius: 6px;
    font-size: 0.8rem;
    font-weight: 600;
    text-decoration: none;
    transition: background-color 0.2s ease;
}

.page-nav-link:hover {
    background-color: #334155;
    color: #ffffff;
}

.page-current-pill {
    background-color: #0f172a;
    color: #94a3b8;
    padding: 4px 10px;
    font-size: 0.8rem;
    font-weight: 600;
}

/* Empty State */
.audit-empty-state {
    padding: 48px 20px;
    text-align: center;
}

.empty-icon {
    font-size: 2.2rem;
    color: #475569;
    margin-bottom: 12px;
}

.empty-title {
    font-size: 1rem;
    font-weight: 700;
    color: #cbd5e1;
    margin: 0 0 4px 0;
}

.empty-desc {
    font-size: 0.82rem;
    color: #64748b;
    margin: 0;
}

/* Modal Dark Override */
.dark-modal-content {
    background-color: #1e293b;
    border: 1px solid #334155;
    border-radius: 12px;
    overflow: hidden;
}

.dark-modal-header {
    background-color: #0f172a;
    padding: 16px 20px;
    border-bottom: 1px solid #334155;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.dark-modal-title {
    margin: 0;
    color: #f8fafc;
    font-size: 0.95rem;
    font-weight: 700;
}

#noticeMap {
    height: 420px;
    width: 100%;
}


