/* =====================================================
   CUSTOM MUDBLAZOR LAYOUT STYLES - DARK BLUE THEME
   ===================================================== */

/* =====================================================
   APP BAR
   ===================================================== */
.app-bar {
  background: linear-gradient(135deg, #1e3a5f 0%, #0f2027 100%) !important;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.15) !important;
}

.content-appbar {
  background: linear-gradient(135deg, #1e3a5f 0%, #2c5364 100%) !important;
  color: white !important;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1) !important;
}

.menu-toggle-btn,
.menu-icon-white {
  color: white !important;
}

/* =====================================================
   DRAWER
   ===================================================== */
.drawer-custom {
  background: linear-gradient(
    180deg,
    #1e3a5f 0%,
    #152d47 50%,
    #0d1f30 100%
  ) !important;
  border-right: 1px solid rgba(255, 255, 255, 0.1) !important;
}

.full-height-drawer {
  height: 100vh !important;
}

.drawer-header-section {
  background: rgba(0, 0, 0, 0.2);
  padding: 16px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.drawer-logo-area {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 16px;
  background: white;
  border-radius: 8px;
}

.drawer-logo-img {
  max-width: 100%;
  height: auto;
  max-height: 80px;
  object-fit: contain;
}

/* Drawer Content Layout */
.drawer-content {
  display: flex;
  flex-direction: column;
  height: 100%;
  padding: 0;
  overflow: hidden;
}

.navmenu-scrollable {
  flex: 1;
  overflow-y: auto;
  overflow-x: hidden;
  padding: 5px 0;
  scrollbar-width: thin;
  scrollbar-color: rgba(255, 255, 255, 0.3) transparent;
}

.navmenu-scrollable::-webkit-scrollbar {
  width: 6px;
}

.navmenu-scrollable::-webkit-scrollbar-thumb {
  background-color: rgba(255, 255, 255, 0.3);
  border-radius: 3px;
}

.navmenu-scrollable::-webkit-scrollbar-thumb:hover {
  background-color: rgba(255, 255, 255, 0.5);
}

.drawer-footer,
.drawer-footer-fixed {
  padding: 16px;
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  background: rgba(0, 0, 0, 0.15);
  position: sticky;
  bottom: 0;
  z-index: 10;
}

/* =====================================================
   USER INFO
   ===================================================== */
.user-info-section {
  padding: 12px 16px;
}

.logged-in-user-card,
.user-status-card {
  background: rgba(255, 255, 255, 0.12);
  backdrop-filter: blur(10px);
  border: 1px solid rgba(255, 255, 255, 0.25);
  border-radius: 16px;
  padding: 16px;
  margin-left: 14px;
  margin-right: 14px;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
  transition: all 0.3s ease;
}

.logged-in-user-card:hover {
  background: rgba(255, 255, 255, 0.15);
  border-color: rgba(255, 255, 255, 0.35);
  box-shadow: 0 6px 16px rgba(0, 0, 0, 0.2);
}

.user-info-row,
.user-info {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 8px;
}

.user-avatar {
  background: linear-gradient(135deg, #1e3a5f 0%, #2c5364 100%) !important;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.2);
}

.user-details {
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.user-name {
  font-weight: 600 !important;
  line-height: 1.2;
}

.user-company,
.user-zone {
  font-size: 11px !important;
  line-height: 1.2;
}

.logout-btn {
  border-radius: 8px !important;
  font-weight: 600 !important;
}

/* =====================================================
   NAVIGATION MENU
   ===================================================== */
.nav-menu-custom {
  flex: 1;
  padding: 8px 12px !important;
  margin: 0 !important;
  overflow-y: auto;
  scrollbar-width: thin;
  scrollbar-color: rgba(255, 255, 255, 0.2) transparent;
}

.nav-menu-custom::-webkit-scrollbar {
  width: 6px;
}

.nav-menu-custom::-webkit-scrollbar-thumb {
  background-color: rgba(255, 255, 255, 0.2);
  border-radius: 4px;
}

.nav-menu-custom::-webkit-scrollbar-thumb:hover {
  background-color: rgba(255, 255, 255, 0.4);
}

.nav-link-custom {
  color: rgba(255, 255, 255, 0.8) !important;
  border-radius: 8px !important;
  margin: 4px 0 !important;
  padding: 12px 16px !important;
  transition: all 0.3s ease !important;
  font-weight: 500 !important;
}

.nav-link-custom .mud-icon-root {
  color: rgba(255, 255, 255, 0.8) !important;
}

.nav-link-custom:hover {
  background: rgba(255, 255, 255, 0.1) !important;
  color: white !important;
  transform: translateX(4px);
}

.nav-link-custom:hover .mud-icon-root {
  color: white !important;
}

.nav-link-active {
  background: rgba(255, 255, 255, 0.2) !important;
  color: white !important;
  font-weight: 600 !important;
}

.nav-link-active .mud-icon-root {
  color: white !important;
}

/* MudTable Header Styling */
.mud-table-head .mud-table-cell {
  background-color: #1e3a5f !important;
  color: white !important;
}

.mud-table-head .mud-table-cell:hover {
  color: #f5f5f5 !important;
}

.mud-table-head .mud-table-cell:hover * {
  color: #f5f5f5 !important;
}

.mud-table-sortlabel:hover {
  color: #f5f5f5 !important;
}

.mud-table-sortlabel:hover span {
  color: #f5f5f5 !important;
}

.mud-table-sortlabel:hover .mud-button-root {
  color: #f5f5f5 !important;
}

.mud-table-sortlabel .mud-button-root:hover {
  color: #f5f5f5 !important;
  background-color: transparent !important;
}

/* =====================================================
   COLLAPSIBLE NAV GROUPS
   ===================================================== */
.mud-nav-group {
  margin: 4px 0 !important;
  border-radius: 10px;
  overflow: hidden;
  transition: all 0.3s ease;
  background: rgba(255, 255, 255, 0.05);
}

.mud-nav-group:not(:last-child) {
  margin-bottom: 6px !important;
}

.mud-nav-group:hover {
  background: rgba(255, 255, 255, 0.08);
}

.mud-nav-group:hover .mud-icon-root {
  color: #fff;
  transform: scale(1.1);
}

/* Custom Nav Group Styling */
.custom-nav-group {
  margin: 6px 0 !important;
  background: rgba(255, 255, 255, 0.06) !important;
  border-radius: 12px !important;
}

.custom-nav-group:hover {
  background: rgba(255, 255, 255, 0.1) !important;
}

/* Standalone Nav Link with Nav Group Styling */
.nav-link-group-style {
  margin: 6px 0 !important;
  background: rgba(255, 255, 255, 0.06) !important;
  border-radius: 12px !important;
  padding: 14px 16px !important;
  font-weight: 600 !important;
  color: rgba(255, 255, 255, 0.95) !important;
  font-size: 15px !important;
  transition: all 0.3s ease;
  display: flex;
  align-items: center;
  gap: 12px;
}

.nav-link-group-style .mud-icon-root {
  color: rgba(255, 255, 255, 0.9) !important;
  font-size: 20px !important;
  transition: all 0.3s ease;
}

.nav-link-group-style:hover {
  background: rgba(255, 255, 255, 0.12) !important;
  color: #fff !important;
  transform: translateX(4px);
}

.nav-link-group-style:hover .mud-icon-root {
  color: #fff !important;
  transform: scale(1.1);
}

/* Parent Nav Group Titles */
.mud-nav-group-text,
.mud-nav-group-title {
  font-weight: 600 !important;
  color: rgba(255, 255, 255, 0.95) !important;
  letter-spacing: 0.3px;
  display: flex;
  align-items: center;
  justify-content: flex-start !important;
  gap: 12px;
  padding: 14px 16px !important;
  margin: 0 !important;
  border-radius: 10px;
  font-size: 15px !important;
  transition: all 0.3s ease;
  text-align: left !important;
}

.mud-nav-group-text:hover,
.mud-nav-group-title:hover {
  background: rgba(255, 255, 255, 0.12);
  color: #fff !important;
}

.mud-nav-group .mud-icon-root {
  color: rgba(255, 255, 255, 0.9);
  font-size: 20px;
  transition: all 0.3s ease;
}

.mud-collapse-icon .mud-icon-root {
  font-size: 18px;
  transition: transform 0.3s ease;
}

.mud-nav-group.mud-nav-group-open .mud-collapse-icon .mud-icon-root {
  transform: rotate(90deg);
}

/* Nav Group Child Links - Use MudBlazor Default Indentation */
.mud-nav-group .mud-nav-link,
.navmenu-scrollable .mud-nav-group .mud-nav-link {
  padding-top: 10px !important;
  padding-bottom: 10px !important;
  font-size: 14px !important;
  color: rgba(255, 255, 255, 0.85) !important;
  border-radius: 8px !important;
  margin-top: 2px !important;
  margin-bottom: 2px !important;
  transition: all 0.25s ease;
  background: transparent;
}

/* Custom Nav Item Styling */
.custom-nav-item {
  padding-left: 16px !important;
  font-size: 14px !important;
  border-radius: 10px !important;
  margin: 3px 10px !important;
}

.custom-nav-item:hover {
  background: rgba(255, 255, 255, 0.15) !important;
  transform: translateX(6px);
}

.mud-nav-group .mud-nav-link .mud-icon-root,
.navmenu-scrollable .mud-nav-group .mud-nav-link .mud-icon-root {
  font-size: 18px;
  margin-right: 10px;
  color: rgba(255, 255, 255, 0.75) !important;
  transition: all 0.25s ease;
}

.mud-nav-group .mud-nav-link:hover,
.navmenu-scrollable .mud-nav-group .mud-nav-link:hover {
  background: rgba(255, 255, 255, 0.12) !important;
  color: #fff !important;
  transform: translateX(4px);
}

.mud-nav-group .mud-nav-link:hover .mud-icon-root,
.navmenu-scrollable .mud-nav-group .mud-nav-link:hover .mud-icon-root {
  color: #fff !important;
}

.mud-nav-group .mud-nav-link-active,
.navmenu-scrollable .mud-nav-group .mud-nav-link-active {
  background: rgba(255, 255, 255, 0.22) !important;
  color: #fff !important;
  font-weight: 600 !important;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.15);
}

.mud-nav-group .mud-nav-link-active .mud-icon-root,
.navmenu-scrollable .mud-nav-group .mud-nav-link-active .mud-icon-root {
  color: #fff !important;
}

/* =====================================================
   MAIN CONTENT
   ===================================================== */
.main-content {
  background: #f5f5f5 !important;
  min-height: 100vh;
}

.content-wrapper {
  padding: 24px;
  margin: 0 auto;
}

/* =====================================================
   MUDBLAZOR COMPONENT OVERRIDES - Dark Blue Theme
   ===================================================== */
/* MudTextField focus/hover colors */
.mud-input-control:hover .mud-input-slot,
.mud-input-control.mud-input-focused .mud-input-slot {
  border-color: #1e3a5f !important;
}

.mud-input-control .mud-input-slot:hover,
.mud-input-control .mud-input-slot:focus-within {
  border-color: #1e3a5f !important;
}

.mud-input-label.mud-input-label-animated.mud-input-label-inputcontrol.mud-focused {
  color: #1e3a5f !important;
}

.mud-input-root-outlined:hover .mud-input-outlined-border,
.mud-input-root-outlined.mud-input-focused .mud-input-outlined-border {
  border-color: #1e3a5f !important;
}

.mud-input-label-animated.mud-input-label-inputcontrol.mud-input-focused {
  color: #1e3a5f !important;
}

/* =====================================================
   UTILITY CLASSES
   ===================================================== */
.text-white {
  color: white !important;
}

.text-white-50 {
  color: rgba(255, 255, 255, 0.7) !important;
}

/* =====================================================
   PAGE STYLES - SHARED (Dark Blue Theme)
   ===================================================== */
.login-container,
.contact-container,
.privacy-container,
.about-container {
  min-height: 100vh;
  background: linear-gradient(135deg, #1e3a5f 0%, #0f2027 100%);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
  position: relative;
  overflow: hidden;
}

.login-container::before,
.contact-container::before,
.privacy-container::before,
.about-container::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 1000 1000"><rect width="100%" height="100%" fill="%23ffffff" opacity="0.05"/><circle cx="200" cy="200" r="100" fill="%23ffffff" opacity="0.05"/><circle cx="800" cy="300" r="150" fill="%23ffffff" opacity="0.03"/><circle cx="400" cy="700" r="120" fill="%23ffffff" opacity="0.04"/></svg>');
  pointer-events: none;
}

.login-card,
.contact-card,
.privacy-card,
.about-card {
  background: rgba(255, 255, 255, 0.95);
  backdrop-filter: blur(10px);
  border-radius: 16px;
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.3);
  padding: 40px;
  width: 100%;
  max-width: 420px;
  position: relative;
  z-index: 1;
  border: 1px solid rgba(255, 255, 255, 0.2);
}

.contact-card,
.privacy-card,
.about-card {
  max-width: 800px;
  max-height: 90vh;
  overflow-y: auto;
}

.login-header,
.contact-header,
.privacy-header,
.about-header {
  text-align: center;
  margin-bottom: 32px;
}

.contact-content,
.privacy-content,
.about-content {
  margin-bottom: 32px;
}

.login-footer,
.contact-footer,
.privacy-footer,
.about-footer {
  border-top: 1px solid #e0e0e0;
  padding-top: 20px;
}

/* =====================================================
   LOGIN PAGE
   ===================================================== */
/*.login-header {
    padding: 0 20px;
}
*/
.login-logo {
  max-width: 100%;
  width: auto;
  height: auto;
  max-height: 250px;
  object-fit: contain;
  display: block;
  margin: 0 auto;
  margin-bottom: 16px;
}

.qa-logo {
  max-width: 100%;
  width: auto;
  height: auto;
  max-height: 35px;
  object-fit: contain;
  display: block;
  margin: 0 auto;
}

.logo-text {
  font-size: 28px;
  font-weight: 700;
  color: #1e3a5f;
  margin-bottom: 4px;
  letter-spacing: -0.5px;
}

.subtitle {
  font-size: 12px;
  font-weight: 500;
  color: #666;
  text-transform: uppercase;
  letter-spacing: 1px;
}

.login-form {
  margin-bottom: 32px;
}

.login-field {
  margin-bottom: 24px !important;
}

.login-field .mud-input-control,
.login-field .mud-input-control .mud-input-root,
.login-field .mud-input-control .mud-input-root .mud-input-root-outlined {
  background-color: #f8f9fa;
  border-radius: 8px;
}

.login-button {
  width: 100%;
  height: 48px;
  font-size: 16px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  border-radius: 8px;
  margin-top: 8px;
  transition: all 0.3s ease;
}

.login-button:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 16px rgba(30, 58, 95, 0.4);
}

.login-button:disabled {
  transform: none;
  box-shadow: 0 2px 8px rgba(30, 58, 95, 0.2);
}

.navy-button {
  background: linear-gradient(135deg, #1e3a5f 0%, #2c5364 100%) !important;
  color: white !important;
  box-shadow: 0 4px 12px rgba(30, 58, 95, 0.3) !important;
}

.navy-button:hover {
  background: linear-gradient(135deg, #2c5282 0%, #355a6e 100%) !important;
  transform: translateY(-2px);
  box-shadow: 0 6px 16px rgba(30, 58, 95, 0.4) !important;
}

.navy-button:disabled {
  background: #1e3a5f !important;
  opacity: 0.6;
  transform: none;
  box-shadow: 0 2px 8px rgba(30, 58, 95, 0.2) !important;
}

/* Login Footer */
.footer-top-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 12px;
  gap: 16px;
}

.footer-bottom-row {
  display: flex;
  justify-content: center;
  align-items: center;
}

.company-info {
  display: flex;
  flex-direction: column;
}

.company-logo {
  font-size: 12px;
  font-weight: 600;
  color: #1e3a5f;
  margin-bottom: 2px;
}

.company-subtitle {
  font-size: 10px;
  color: #666;
  font-weight: 400;
}

.copyright {
  font-size: 15px;
  color: #666;
}

.nav-links {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  flex-wrap: nowrap;
  white-space: nowrap;
}

.footer-link,
.footer-link:link,
.footer-link:visited,
.footer-link:active {
  font-size: 16px;
  color: #1e3a5f !important;
  text-decoration: none !important;
  display: inline-flex;
  align-items: center;
  gap: 4px;
  transition: color 0.2s ease;
  white-space: nowrap;
}

.footer-link .mud-icon-root {
  font-size: 14px;
  color: #1e3a5f !important;
}

.footer-link .mr-1 {
  margin-right: 0;
}

.footer-link:hover,
.footer-link:hover .mud-icon-root {
  color: #2c5364 !important;
  text-decoration: none !important;
}

.separator {
  font-size: 10px;
  color: #ccc;
  margin: 0 2px;
  display: inline-block;
}

/* =====================================================
   CONTACT PAGE
   ===================================================== */
.contact-info-card,
.privacy-section,
.about-section {
  margin-bottom: 24px;
  border-radius: 12px;
}

.contact-item,
.feature-item {
  display: flex;
  align-items: flex-start;
  margin-bottom: 20px;
  padding: 16px;
  background: #f8f9fa;
  border-radius: 8px;
}

.contact-icon,
.feature-icon {
  margin-right: 16px;
  margin-top: 4px;
  color: #1e3a5f;
}

.contact-form {
  margin-top: 24px;
}

.contact-field {
  margin-bottom: 20px;
}

.contact-button {
  width: 100%;
  height: 48px;
  font-size: 16px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  border-radius: 8px;
  background: linear-gradient(135deg, #1e3a5f 0%, #0f2027 100%);
  box-shadow: 0 4px 12px rgba(30, 58, 95, 0.3);
  transition: all 0.3s ease;
}

.contact-button:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 16px rgba(30, 58, 95, 0.4);
}

/* =====================================================
   ABOUT PAGE
   ===================================================== */
.features-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 20px;
  margin-top: 16px;
}

/* =====================================================
   ANIMATIONS
   ===================================================== */
.mud-drawer {
  transition: all 0.3s ease !important;
}

/* =====================================================
   RESPONSIVE DESIGN
   ===================================================== */
@media (max-width: 768px) {
  .drawer-content {
    padding: 12px;
  }

  .content-wrapper {
    padding: 16px;
  }

  .nav-link-custom {
    padding: 10px 12px !important;
    font-size: 14px !important;
  }

  .contact-card,
  .privacy-card,
  .about-card {
    padding: 24px;
    margin: 16px;
    max-height: 85vh;
  }

  .features-grid {
    grid-template-columns: 1fr;
  }

  .contact-item,
  .feature-item {
    flex-direction: column;
    text-align: center;
  }

  .contact-icon,
  .feature-icon {
    margin-right: 0;
    margin-bottom: 8px;
  }
}

@media (max-width: 480px) {
  .login-container {
    padding: 16px;
  }

  .login-card {
    padding: 24px;
    border-radius: 12px;
  }

  .logo-text {
    font-size: 24px;
  }

  .footer-content {
    flex-direction: column;
    text-align: center;
    gap: 12px;
  }

  .footer-links {
    text-align: center;
    min-width: 100%;
  }

  .nav-links {
    justify-content: center;
    flex-wrap: nowrap;
  }

  .footer-link {
    font-size: 9px;
  }

  .separator {
    margin: 0 2px;
  }
}

/* =====================================================
   Search field - white text for dark backgrounds
   ===================================================== */

.white-search-field input {
    color: white !important;
}

.white-search-field .mud-input-adornment-start {
    color: white !important;
}

.white-search-field .mud-input-adornment svg {
    color: white !important;
    fill: white !important;
}

.white-search-field ::placeholder {
    color: rgba(255, 255, 255, 0.7) !important;
}

.white-search-field .mud-input-outlined .mud-input-outlined-border {
    border-color: rgba(255, 255, 255, 0.5) !important;
}

.white-search-field .mud-input-slot {
    color: white !important;
}