/* Navigation Styles */
nav {
  background-color: #ffffff;
  padding: 0.75rem 0;
  position: sticky;
  top: 0;
  z-index: 1000;
  transition: box-shadow 0.3s ease;
  font-family: 'Roboto', sans-serif;
}

nav::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 50%;
  transform: translateX(-50%);
  width: calc(100% - 160px);
  height: 1px;
  background-color: #e5e7eb;
  transition: opacity 0.3s ease;
}

@media (max-width: 768px) {
  nav::after {
    width: calc(100% - 2rem);
  }
}

@media (max-width: 480px) {
  nav::after {
    width: calc(100% - 1.5rem);
  }
}

nav.shadow {
  box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
}

nav.shadow::after {
  opacity: 0;
}

.nav-content {
  max-width: 1400px;
  margin: 0 auto;
  padding: 0 2rem;
  display: flex;
  justify-content: space-between;
  align-items: center;
  width: 100%;
  position: relative;
  min-height: 50px;
  z-index: 1001;
  overflow: visible;
}

.logo {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 2rem;
  font-weight: 500;
  color: #0f0f0f;
  text-decoration: none;
  flex-shrink: 0;
  padding: 0.25rem 0;
  line-height: 1;
  height: fit-content;
  outline: none;
  border: none;
  background: transparent;
}

.logo:focus {
  outline: none;
  box-shadow: none;
}

.logo:focus-visible {
  outline: 2px solid transparent;
  outline-offset: 2px;
}

.logo img {
  height: 36px;
  width: auto;
}

.logo span {
  font-weight: 500;
}

.logo span #boxtext,
#boxtext {
  color: #0E2431;
  font-weight: 300 !important;
  font-family: 'Roboto', sans-serif;
}

.nav-links {
  display: flex;
  list-style: none;
  gap: 10px;
  align-items: center;
  margin: 0;
  padding: 0;
  flex: 1;
  justify-content: center;
  overflow: visible;
}

.nav-links li {
  margin: 0;
  padding: 0;
}

.nav-links li a {
  color: #0E2431;
  font-size: 18px;
  font-weight: 400;
  padding: 7px 10px;
  padding-bottom: 3px;
  border-bottom: 2px solid transparent;
  text-decoration: none;
  position: relative;
  display: inline-flex;
  align-items: center;
  transition: color 0.2s, border-bottom-color 0.2s;
  box-sizing: border-box;
  line-height: 1.5;
  margin-bottom: 1px;
}

.nav-links li a:focus {
  outline: none;
  font-weight: 400;
  border-bottom: 2px solid transparent;
}

.nav-links li a:focus-visible {
  outline: 2px solid transparent;
  outline-offset: 2px;
  font-weight: 400;
  border-bottom: 2px solid transparent;
}

.nav-links li a:active {
  font-weight: 400;
  border-bottom: 2px solid transparent;
}

.nav-links li a:hover {
  color: #0E2431;
  border-bottom-color: #0E2431;
}

.nav-links li a.active-link {
  color: #0E2431;
  font-weight: 500;

  border-bottom-color: #0E2431;
}

.nav-links li a.active-link:focus,
.nav-links li a.active-link:focus-visible,
.nav-links li a.active-link:active {
  font-weight: 500;
  border-bottom: 2px solid #0E2431;
}

.nav-dropdown:hover .dropdown-trigger,
.nav-dropdown.active .dropdown-trigger {
  color: #0E2431;

}

/* Dropdown Styles */
.nav-dropdown {
  position: relative;
  display: flex;
  align-items: center;
  height: auto;
}

.dropdown-menu {
  position: absolute;
  top: calc(100% + 4px);
  left: 50%;
  transform: translateX(-50%);
  background-color: white;
  border-radius: 0.75rem;
  box-shadow: 0 10px 40px rgba(0, 0, 0, 0.15), 0 4px 6px rgba(0, 0, 0, 0.1);
  list-style: none;
  padding: 0.5rem 0.375rem 0.375rem 0.375rem;
  margin-top: 0;
  min-width: 230px;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.15s, visibility 0.15s, transform 0.15s;
  transform: translateX(-50%) translateY(-8px);
  z-index: 1002;
  border: 1px solid #e5e7eb;
  pointer-events: none;
}

/* Arrow at top of Resources dropdown pointing up at trigger */
.dropdown-menu::before {
  content: '';
  position: absolute;
  top: -8px;
  left: 50%;
  transform: translateX(-50%);
  width: 0;
  height: 0;
  border-left: 8px solid transparent;
  border-right: 8px solid transparent;
  border-bottom: 8px solid white;
  z-index: 1003;
  filter: drop-shadow(0 -2px 2px rgba(0, 0, 0, 0.05));
}

.dropdown-menu::after {
  content: '';
  position: absolute;
  top: -9px;
  left: 50%;
  transform: translateX(-50%);
  width: 0;
  height: 0;
  border-left: 9px solid transparent;
  border-right: 9px solid transparent;
  border-bottom: 9px solid #e5e7eb;
  z-index: 1002;
}

.dropdown-menu li:first-child a {
  padding-top: 0.875rem;
  padding-bottom: 0.75rem;
  border: 2px solid transparent;
  min-height: 3rem;
}

.dropdown-menu li:first-child a:hover {
  padding-top: 0.875rem;
  padding-bottom: 0.75rem;
  border: 2px solid transparent;
}

.nav-dropdown.active .dropdown-menu {
  opacity: 1;
  visibility: visible;
  transform: translateX(-50%) translateY(0);
  pointer-events: auto;
}

.dropdown-menu li {
  margin: 0;
}

.dropdown-menu li a {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  padding: 0.75rem 1rem;
  color: #111827;
  font-size: 0.9375rem;
  font-weight: 600;
  text-decoration: none;
  transition: background-color 0.2s, color 0.2s;
  border-radius: 0.5rem;
  border: 2px solid transparent;
  position: relative;
  width: 100%;
  box-sizing: border-box;
  margin: 0;
  min-height: 2.75rem;
  outline: none;
}

.dropdown-menu li a:focus,
.dropdown-menu li a:focus-visible {
  outline: none;
  border: 2px solid transparent;
  font-weight: 600;
}

.dropdown-menu li a.active-link {
  border: 2px solid transparent;
  border-bottom: 2px solid transparent;
}

.dropdown-menu li a svg {
  flex-shrink: 0;
  color: #2563eb;
  stroke-width: 2.5;
  width: 18px;
  height: 18px;
  transition: color 0.2s;
}

.dropdown-menu li a img {
  flex-shrink: 0;
  width: 18px;
  height: 18px;
  object-fit: contain;
}

.dropdown-menu li a > span:not(.dropdown-badge-new):not(.dropdown-badge-sample) {
  flex: 1;
  white-space: nowrap;
}

.dropdown-menu li a:hover {
  background-color: #f9fafb;
  color: #111827;
  border: 2px solid transparent;
  padding: 0.75rem 1rem;
}

.dropdown-menu li a:active,
.dropdown-menu li a:focus:active,
.dropdown-menu li a:focus-visible:active {
  font-weight: 600;
}

.dropdown-badge-new {
  background-color: #fbbf24;
  color: #78350f;
  font-size: 0.75rem;
  font-weight: 700;
  padding: 0.125rem 0.5rem;
  border-radius: 9999px;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.dropdown-badge-sample {
  background-color: #6366f1;
  color: #fff;
  font-size: 0.75rem;
  font-weight: 700;
  padding: 0.125rem 0.5rem;
  border-radius: 9999px;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  flex-shrink: 0;
  white-space: nowrap;
}

/* Auth Buttons - Consistent sizing across all pre-login pages */
.auth-buttons {
  display: flex;
  gap: 1rem;
  align-items: center;
  margin-left: auto;
  padding-right: 2rem;
}

/* Force consistent sizing for all auth buttons - only on prelogin pages */
.prelogin-body nav .auth-buttons a:not(.login-submit-btn):not(.login-dropdown-menu a):not(.login-dropdown-menu button),
.prelogin-body nav .auth-buttons .login:not(.login-submit-btn),
.prelogin-body nav .auth-buttons .subscribe,
.prelogin-body .auth-buttons a:not(.login-submit-btn):not(.login-dropdown-menu a):not(.login-dropdown-menu button),
.prelogin-body .auth-buttons .login:not(.login-submit-btn),
.prelogin-body .auth-buttons .subscribe,
.prelogin-body .login:not(.login-submit-btn):not(.login-dropdown-menu .login-submit-btn),
.prelogin-body .subscribe {
  padding: 8px 18px !important;
  font-weight: 600 !important;
  font-size: 15px !important;
  cursor: pointer;
  border-radius: 8px;
  text-decoration: none;
  display: inline-flex !important;
  align-items: center;
  justify-content: center;
  min-height: 40px !important;
  height: 40px !important;
  min-width: fit-content;
  max-width: none !important;
  width: auto !important;
  box-sizing: border-box !important;
  white-space: nowrap !important;
  line-height: 1 !important;
}

/* Login and Subscribe button base styles - apply to all pages */
.login {
  background: #fff;
  border-radius: 8px;
  transition: all 0.3s ease;
  box-shadow: 0 2px 2px #0f0a1f0a, 0 2px 6px #0f0a1f0f;
  color: #202020;
  border: 1px solid #aaaaaa;
  position: relative;
  overflow: visible;
  z-index: 100;
  padding: 8px 18px;
  font-weight: 600;
  font-size: 15px;
  min-height: 40px;
  height: 40px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  box-sizing: border-box;
  white-space: nowrap;
  line-height: 1;
  cursor: pointer;
  text-decoration: none;
}

.subscribe {
  background: #26262d;
  color: white;
  border: 2px solid #26262d;
  box-shadow: 0 2px 2px #0f0a1f0a, 0 2px 6px #0f0a1f0f;
  border-radius: 8px;
  padding: 8px 18px;
  font-weight: 600;
  font-size: 15px;
  min-height: 40px;
  height: 40px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  box-sizing: border-box;
  white-space: nowrap;
  line-height: 1;
  cursor: pointer;
  text-decoration: none;
}

.login:hover {
  background-color: #f1f1f1;
  color: #3b3b3b;
  box-shadow: none;
  border: 1px solid #5f5f5f;
  transition: all 0.3s ease;
  text-decoration: none;
}

.subscribe:hover {
  background-color: #3161ff;
  text-decoration: none;
  border: 2px solid #3161ff;
}

.auth-buttons.desktop-auth {
  display: flex;
}

.auth-buttons.mobile-auth {
  display: none;
}


/* Login Dropdown */
.login-dropdown {
  position: relative;
}

.login-dropdown-menu {
  position: absolute;
  top: calc(100% + 8px);
  right: 0;
  background-color: white;
  border-radius: 16px;
  box-shadow: 0 4px 24px rgba(0, 0, 0, 0.06), 0 0 0 1px rgba(0, 0, 0, 0.04);
  padding: 20px;
  min-width: 350px;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.15s, visibility 0.15s, transform 0.15s;
  transform: translateY(-8px);
  z-index: 1000;
  border: 1px solid rgba(158, 158, 158, 0.788);
  pointer-events: none;
}

.login-dropdown-menu::before {
  content: '';
  position: absolute;
  top: -8px;
  right: 20px;
  width: 0;
  height: 0;
  border-left: 8px solid transparent;
  border-right: 8px solid transparent;
  border-bottom: 8px solid white;
  filter: drop-shadow(0 -2px 2px rgba(0, 0, 0, 0.05));
}

.login-dropdown.active .login-dropdown-menu {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
  pointer-events: auto;
}

.login-form-group {
  margin-bottom: 0;
}

.login-form-group:first-of-type {
  margin-top: 0;
}

.login-form-group:not(:first-of-type) {
  margin-top: 16px;
}

.login-form-group:last-of-type {
  margin-bottom: 0;
}

.login-form-group label {
  display: block;
  font-size: 13px;
  font-weight: 500;
  color: #6b7280;
  margin-bottom: 6px;
  margin-top: 0;
  font-family: 'Roboto', sans-serif;
}

.login-input {
  width: 100%;
  padding: 10px 14px;
  font-size: 14px;
  border: 1.5px solid #d1d5db;
  border-radius: 6px;
  background-color: #ffffff;
  color: #111827;
  transition: all 0.2s ease;
  box-sizing: border-box;
  font-family: 'Roboto', sans-serif;
}

.login-input::placeholder {
  color: #9ca3af;
  opacity: 1;
}

.login-input:focus {
  outline: none;
  border-color: #3161ff;
  box-shadow: 0 0 0 3px rgba(49, 97, 255, 0.1);
}

/* Login modal inputs - smaller screens: 80% width, centered */
@media (max-width: 768px) {
  .login-dropdown-menu {
    min-width: 90%;
    max-width: 90%;
    left: 50%;
    transform: translateX(-50%) translateY(-8px);
    right: auto;
  }
  
  .login-dropdown.active .login-dropdown-menu {
    transform: translateX(-50%) translateY(0);
  }
  
  .login-dropdown-menu::before {
    right: auto;
    left: 50%;
    transform: translateX(-50%);
  }
  
  .login-form-group {
    display: flex;
    flex-direction: column;
    align-items: center;
  }
  
  .login-form-group label {
    width: 80%;
    text-align: left;
  }
  
  .login-input {
    width: 80% !important;
    max-width: 80% !important;
    margin-left: auto;
    margin-right: auto;
  }
  
  .login-submit-btn,
  #dropdown-login-btn {
    width: 80% !important;
    max-width: 80% !important;
    margin-left: auto;
    margin-right: auto;
  }
  
  .login-error-message {
    width: 80% !important;
    max-width: 80% !important;
    margin-left: auto;
    margin-right: auto;
  }
}

/* Login Submit Button - Must override prelogin-body rules */
button.login-submit-btn,
button#dropdown-login-btn,
.login-dropdown-menu button.login-submit-btn,
.login-dropdown-menu button#dropdown-login-btn,
.prelogin-body .login-dropdown-menu button.login-submit-btn,
.prelogin-body .login-dropdown-menu button#dropdown-login-btn,
.prelogin-body nav .auth-buttons button.login-submit-btn,
.prelogin-body nav .auth-buttons button#dropdown-login-btn,
body.prelogin-body .login-dropdown-menu button.login-submit-btn,
body.prelogin-body .login-dropdown-menu button#dropdown-login-btn {
  width: 100% !important;
  padding: 10px 16px !important;
  background-color: #e5e7eb !important;
  color: #9ca3af !important;
  border: none !important;
  border-radius: 6px !important;
  font-size: 14px !important;
  font-weight: 500 !important;
  cursor: default !important;
  transition: all 0.2s ease !important;
  box-shadow: none !important;
  font-family: 'Roboto', sans-serif !important;
  display: block !important;
  text-align: center !important;
  margin-top: 16px !important;
  box-sizing: border-box !important;
  min-height: auto !important;
  height: auto !important;
  min-width: auto !important;
  max-width: 100% !important;
  white-space: normal !important;
  line-height: normal !important;
}

button.login-submit-btn:enabled,
button#dropdown-login-btn:enabled,
.login-dropdown-menu button.login-submit-btn:enabled,
.login-dropdown-menu button#dropdown-login-btn:enabled,
.prelogin-body .login-dropdown-menu button.login-submit-btn:enabled,
.prelogin-body .login-dropdown-menu button#dropdown-login-btn:enabled,
.prelogin-body nav .auth-buttons button.login-submit-btn:enabled,
.prelogin-body nav .auth-buttons button#dropdown-login-btn:enabled,
body.prelogin-body .login-dropdown-menu button.login-submit-btn:enabled,
body.prelogin-body .login-dropdown-menu button#dropdown-login-btn:enabled {
  background-color: #3161ff !important;
  color: white !important;
  cursor: pointer !important;
  box-shadow: 0 4px 8px rgba(49, 97, 255, 0.2) !important;
}

button.login-submit-btn:enabled:hover,
button#dropdown-login-btn:enabled:hover,
.login-dropdown-menu button.login-submit-btn:enabled:hover,
.login-dropdown-menu button#dropdown-login-btn:enabled:hover,
.prelogin-body .login-dropdown-menu button.login-submit-btn:enabled:hover,
.prelogin-body .login-dropdown-menu button#dropdown-login-btn:enabled:hover,
.prelogin-body nav .auth-buttons button.login-submit-btn:enabled:hover,
.prelogin-body nav .auth-buttons button#dropdown-login-btn:enabled:hover,
body.prelogin-body .login-dropdown-menu button.login-submit-btn:enabled:hover,
body.prelogin-body .login-dropdown-menu button#dropdown-login-btn:enabled:hover {
  background-color: #2563eb !important;
  transform: translateY(-1px) !important;
  box-shadow: 0 4px 12px rgba(49, 97, 255, 0.3) !important;
}

button.login-submit-btn:enabled:active,
button#dropdown-login-btn:enabled:active,
.login-dropdown-menu button.login-submit-btn:enabled:active,
.login-dropdown-menu button#dropdown-login-btn:enabled:active,
.prelogin-body .login-dropdown-menu button.login-submit-btn:enabled:active,
.prelogin-body .login-dropdown-menu button#dropdown-login-btn:enabled:active,
.prelogin-body nav .auth-buttons button.login-submit-btn:enabled:active,
.prelogin-body nav .auth-buttons button#dropdown-login-btn:enabled:active,
body.prelogin-body .login-dropdown-menu button.login-submit-btn:enabled:active,
body.prelogin-body .login-dropdown-menu button#dropdown-login-btn:enabled:active {
  transform: translateY(0) !important;
}

/* Login Error Message */
.login-error-message {
  background-color: #ffeaea;
  border: 1.5px solid #ff8f8f;
  border-radius: 8px;
  color: #ff4d4d;
  padding: 0 14px;
  font-size: 14px;
  font-weight: 400;
  width: 100%;
  font-family: 'Roboto', sans-serif;
  display: flex;
  align-items: center;
  opacity: 0;
  max-height: 0;
  overflow: hidden;
  margin-top: 0;
  margin-bottom: 0;
  transition: opacity 0.3s ease, max-height 0.3s ease, margin-top 0.3s ease, margin-bottom 0.3s ease, padding 0.3s ease;
}

.login-error-message.show {
  opacity: 1;
  max-height: 100px;
  padding: 8px 12px;
  margin-top: 12px;
  margin-bottom: 0;
}

.login-error-icon {
  width: 22px;
  height: 22px;
  margin-right: 8px;
  flex-shrink: 0;
}

.login-error-text {
  flex: 1;
  line-height: 1.4;
}

.login-error-text a {
  color: #3161ff;
  text-decoration: underline;
  font-weight: 500;
  display: inline;
  white-space: nowrap;
  padding: 0;
  margin: 0;
}

.login-error-text a:hover {
  color: #2563eb;
}

/* Admin Dropdown Styles */
.admin-dropdown {
  position: relative;
  display: inline-block;
}

.admin-dropdown-trigger {
  display: inline-flex;
  align-items: center;
}

.admin-dropdown-menu {
  position: absolute;
  top: calc(100% + 8px);
  right: 0;
  background-color: white;
  border-radius: 0.75rem;
  box-shadow: 0 10px 40px rgba(0, 0, 0, 0.15), 0 4px 6px rgba(0, 0, 0, 0.1);
  list-style: none;
  padding: 0.5rem 0.375rem 0.375rem 0.375rem;
  margin-top: 0;
  min-width: 200px;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.2s ease, visibility 0.2s ease, transform 0.2s ease;
  transform: translateY(-8px);
  z-index: 1002;
  border: 1px solid #e5e7eb;
  pointer-events: none;
}

/* White arrow connecting dropdown to button */
.admin-dropdown-menu::before {
  content: '';
  position: absolute;
  top: -8px;
  right: 20px;
  width: 0;
  height: 0;
  border-left: 8px solid transparent;
  border-right: 8px solid transparent;
  border-bottom: 8px solid white;
  z-index: 1001;
}

/* Shadow for arrow */
.admin-dropdown-menu::after {
  content: '';
  position: absolute;
  top: -9px;
  right: 20px;
  width: 0;
  height: 0;
  border-left: 9px solid transparent;
  border-right: 9px solid transparent;
  border-bottom: 9px solid #e5e7eb;
  z-index: 1000;
}

.admin-dropdown.active .admin-dropdown-menu {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
  pointer-events: auto;
}

.admin-dropdown-menu li {
  margin: 0;
}

.admin-dropdown-menu li:first-child a {
  padding-top: 0.875rem;
  padding-bottom: 0.75rem;
  border: 2px solid transparent;
  min-height: 3rem;
}

.admin-dropdown-menu li a {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  padding: 0.75rem 1rem;
  color: #111827;
  font-size: 0.9375rem;
  font-weight: 600;
  text-decoration: none;
  transition: background-color 0.2s, color 0.2s;
  border-radius: 0.5rem;
  border: 2px solid transparent;
  position: relative;
  width: 100%;
  box-sizing: border-box;
  margin: 0;
  min-height: 2.75rem;
}

.admin-dropdown-menu li a svg {
  flex-shrink: 0;
  color: #2563eb;
  stroke-width: 2.5;
  width: 18px;
  height: 18px;
  transition: color 0.2s;
}

.admin-dropdown-menu li a > span {
  flex: 1;
}

.admin-dropdown-menu li a:hover {
  background-color: #f9fafb;
  color: #111827;
  border: 2px solid transparent;
}

/* Responsive Design */


/* Tablet Breakpoint */
@media (max-width: 1024px) {
  .nav-content {
    padding: 0 1.5rem;
    max-width: 100%;
  }

  .logo {
    padding: 0.25rem 0;
  }

  .nav-links {
    gap: 1.5rem;
  }

  .nav-links li a {
    font-size: 16px;
    padding: 6px 8px;
  }

  .auth-buttons {
    padding-right: 1.5rem;
    gap: 1rem;
  }

  .auth-buttons a,
  .auth-buttons .login,
  .auth-buttons .subscribe {
    padding: 8px 18px !important;
    font-size: 15px !important;
    min-height: 40px !important;
    height: 40px !important;
    min-width: fit-content;
    max-width: none !important;
    width: auto !important;
    white-space: nowrap !important;
  }
}

/* Medium Tablet/Small Desktop */
@media (max-width: 900px) {
  .nav-links {
    gap: 1rem;
  }

  .nav-links li a {
    font-size: 15px;
    padding: 6px 6px;
  }

  .auth-buttons {
    gap: 1rem;
  }

  .auth-buttons a,
  .auth-buttons .login,
  .auth-buttons .subscribe {
    padding: 8px 18px !important;
    font-size: 15px !important;
    min-height: 40px !important;
    height: 40px !important;
    min-width: fit-content;
    max-width: none !important;
    width: auto !important;
    white-space: nowrap !important;
  }

  /* Hide mobile-specific nav items on medium tablet */
  .mobile-contact-us,
  .mobile-admin-button,
  .mobile-admin-dropdown {
    display: none;
  }
}

/* Mobile Menu Toggle Button */
.mobile-menu-toggle,
.hamburger {
  display: none;
  flex-direction: column;
  justify-content: space-around;
  width: 24px;
  height: 24px;
  background: transparent;
  border: none;
  cursor: pointer;
  padding: 0;
  z-index: 1001;
  position: relative;
}

.mobile-menu-toggle span,
.hamburger .bar {
  width: 100%;
  height: 2px;
  background-color: #0E2431;
  border-radius: 2px;
  transition: all 0.3s ease;
}

/* Hide mobile-specific nav items on desktop */
.mobile-contact-us,
.mobile-admin-button,
.mobile-admin-dropdown {
  display: none;
}

/* Mobile Sidebar */
.mobile-sidebar {
  position: fixed;
  top: 0;
  right: -100%;
  width: 100%;
  height: 100vh;
  max-height: 100vh;
  background-color: #ffffff;
  z-index: 10002;
  transition: right 0.3s ease;
  overflow: hidden;
  box-shadow: -2px 0 10px rgba(0, 0, 0, 0.1);
  touch-action: pan-y;
  overscroll-behavior: contain;
  display: flex;
  flex-direction: column;
}

.mobile-sidebar.active {
  right: 0;
}

.mobile-sidebar-header {
  display: flex;
  justify-content: flex-end;
  align-items: center;
  padding: 1.5rem 1.5rem 0 1.5rem;
  border-bottom: none;
  background-color: #ffffff;
  flex-shrink: 0;
}

.mobile-sidebar-close {
  background: #f3f4f6;
  border: none;
  font-size: 24px;
  line-height: 1;
  color: #6b7280;
  cursor: pointer;
  padding: 0.5rem;
  width: 36px;
  height: 36px;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.2s ease;
  flex-shrink: 0;
  border-radius: 8px;
}

.mobile-sidebar-close:hover {
  background: #e5e7eb;
  color: #111827;
  transform: scale(1.05);
}

.mobile-sidebar-close span {
  display: block;
  line-height: 1;
}

.mobile-sidebar-content {
  padding: 0;
  border: none;
  border-bottom: none !important;
  flex: 1;
  overflow-y: auto;
  overflow-x: hidden;
  -webkit-overflow-scrolling: touch;
  min-height: 0;
  flex-basis: 0;
}

/* Mobile Auth Buttons */
.mobile-sidebar-auth {
  display: flex;
  gap: 1rem;
  padding: 1.5rem 1.5rem;
  border-bottom: 1px solid #e5e7eb;
  align-items: center;
  margin-top: 0;
}

.mobile-sidebar-auth .admin-dropdown {
  flex: 1;
  min-width: 0;
}

.mobile-sidebar-auth .admin-dropdown .mobile-subscribe-btn {
  width: 100%;
}

.mobile-login-btn,
.mobile-subscribe-btn {
  flex: 1;
  padding: 8px 18px !important;
  font-weight: 600 !important;
  font-size: 15px !important;
  cursor: pointer;
  border-radius: 8px;
  text-decoration: none;
  display: inline-flex !important;
  align-items: center;
  justify-content: center;
  min-width: 0;
  width: 100%;
  min-height: 40px !important;
  height: 40px !important;
  min-width: fit-content;
  max-width: none !important;
  width: auto !important;
  box-sizing: border-box !important;
  white-space: nowrap !important;
  line-height: 1 !important;
  transition: all 0.3s ease;
}

.mobile-login-btn {
  background: #fff;
  color: #202020;
  border: 1px solid #aaaaaa;
  box-shadow: 0 2px 2px #0f0a1f0a, 0 2px 6px #0f0a1f0f;
  position: relative;
  overflow: visible;
  z-index: 100;
}


.mobile-login-btn:hover {
  background-color: #f1f1f1;
  color: #3b3b3b;
  box-shadow: none;
  border: 1px solid #5f5f5f;
  text-decoration: none;
  padding: 8px 18px !important;
  min-height: 40px !important;
  height: 40px !important;
}


.mobile-subscribe-btn {
  background: #26262d;
  color: white;
  border: 2px solid #26262d;
  box-shadow: 0 2px 2px #0f0a1f0a, 0 2px 6px #0f0a1f0f;
}

.mobile-subscribe-btn:hover {
  background-color: #3161ff;
  text-decoration: none;
  border: 2px solid #3161ff;
  padding: 8px 18px !important;
  min-height: 40px !important;
  height: 40px !important;
}

/* Mobile Navigation Links */
.mobile-sidebar-nav {
  display: flex;
  flex-direction: column;
  padding: 0;
  min-height: 0;
  flex: 1;
  border: none;
  margin-top: 0;
}

.mobile-sidebar-nav > .mobile-nav-link:first-child {
  border-top: none;
}

.mobile-nav-link {
  display: block;
  padding: 1rem 1.5rem;
  color: #0E2431;
  text-decoration: none;
  font-size: 16px;
  font-weight: 400;
  border-bottom: 1px solid #e5e7eb;
  transition: background-color 0.2s ease;
}

.mobile-nav-link:hover {
  background-color: #f9fafb;
}

/* Add extra space after Contact Us for scrolling */
.mobile-sidebar-nav > .mobile-nav-link:last-of-type {
  margin-bottom: 0;
}

.mobile-sidebar-footer {
  padding: 1.5rem 1.5rem;
  border-top: 1px solid #e5e7eb;
  background-color: #ffffff;
  flex-shrink: 0;
}

.mobile-sidebar-branding {
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0.7;
}

.mobile-nav-link-nested {
  padding-left: 2.5rem;
  font-size: 15px;
  color: #4b5563;
}

/* Mobile Overview Dropdown */
.mobile-overview-dropdown {
  border-bottom: 1px solid #e5e7eb;
}

.mobile-overview-trigger {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 1rem 1.5rem;
  background: transparent;
  border: none;
  color: #0E2431;
  font-size: 16px;
  font-weight: 400;
  text-align: left;
  cursor: pointer;
  transition: background-color 0.2s ease;
}

.mobile-overview-trigger:hover {
  background-color: #f9fafb;
}

.mobile-dropdown-chevron {
  font-size: 20px;
  transition: transform 0.3s ease;
  color: #6b7280;
}

.mobile-overview-dropdown.active .mobile-dropdown-chevron {
  transform: rotate(90deg);
}

.mobile-overview-menu {
  display: none;
  background-color: #f9fafb;
}

.mobile-overview-dropdown.active .mobile-overview-menu {
  display: block;
}

.mobile-overview-menu .mobile-nav-link {
  border-bottom: 1px solid #e5e7eb;
}

.mobile-overview-menu .mobile-nav-link:last-child {
  border-bottom: none;
}

/* Body scroll lock when sidebar is open - but allow sidebar to scroll */
body.mobile-sidebar-open {
  overflow: hidden;
  position: fixed;
  width: 100%;
  height: 100%;
}

body.mobile-sidebar-open .mobile-sidebar-content {
  overflow-y: auto !important;
  -webkit-overflow-scrolling: touch !important;
  touch-action: pan-y !important;
}

/* Mobile Breakpoint - nav switches to hamburger at 1090px */
@media (max-width: 1090px) {
  nav {
    padding: 0.75rem 0;
  }

  .nav-content {
    padding: 0 1rem;
    max-width: 100%;
    justify-content: space-between;
    align-items: center;
  }

  .logo {
    padding: 0.25rem 0;
    margin-right: 0;
    flex-shrink: 1;
    min-width: 0;
    font-size: 2.25rem;
  }

  .logo img {
    flex-shrink: 0;

  }

  #boxtext {
    display: inline;
  }

  /* Show hamburger on mobile */
  .mobile-menu-toggle,
  .hamburger {
    display: flex;
  }

  /* Show mobile-specific nav items on mobile */
  .mobile-contact-us,
  .mobile-admin-button,
  .mobile-admin-dropdown {
    display: block;
  }

  /* Hide desktop nav links on mobile */
  .nav-links {
    display: none;
  }

  /* Hide desktop auth buttons on mobile */
  .auth-buttons.desktop-auth {
    display: none;
  }

  /* Show mobile auth buttons on mobile */
  .auth-buttons.mobile-auth {
    display: flex;
    gap: 1rem;
    align-items: center;
    padding: 0.75rem 2rem;
    background-color: #ffffff;
    border-top: 1px solid #e5e7eb;
  }
}

/* Small Mobile Breakpoint */
@media (max-width: 480px) {
  .nav-content {
    padding: 0 0.75rem;
  }

  .logo {
    font-size: 1.8rem;
  }


}

/* Global override to ensure auth buttons are always the same size on all pre-login pages */
.prelogin-body nav .auth-buttons a:not(.login-submit-btn):not(.login-dropdown-menu a):not(.login-dropdown-menu button),
.prelogin-body nav .auth-buttons .login:not(.login-submit-btn):not(.login-dropdown-menu .login-submit-btn),
.prelogin-body nav .auth-buttons .subscribe,
body.prelogin-body .login:not(.login-submit-btn):not(.login-dropdown-menu .login-submit-btn),
body.prelogin-body .subscribe {
  padding: 8px 18px !important;
  font-size: 15px !important;
  font-weight: 600 !important;
  min-height: 40px !important;
  height: 40px !important;
  line-height: 1 !important;
  box-sizing: border-box !important;
}

/* Admin Modal Styles */
.admin-modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.6);
    backdrop-filter: blur(4px);
    -webkit-backdrop-filter: blur(4px);
    z-index: 2000;
    align-items: center;
    justify-content: center;
    padding: 1rem;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.3s ease, visibility 0.3s ease;
}

.admin-modal.active {
    display: flex;
    opacity: 1;
    visibility: visible;
}

.admin-modal-content {
    background: linear-gradient(to bottom, #ffffff, #fafbfc);
    border-radius: 1.25rem;
    padding: 0;
    max-width: 540px;
    width: 100%;
    max-height: 90vh;
    overflow: hidden;
    position: relative;
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.25), 0 0 0 1px rgba(0, 0, 0, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.8);
    transform: scale(0.95);
    transition: transform 0.3s ease;
}

.admin-modal.active .admin-modal-content {
    transform: scale(1);
}

.admin-modal-close {
    position: absolute;
    top: 1rem;
    right: 1rem;
    background: rgba(255, 255, 255, 0.9);
    border: 1px solid #e5e7eb;
    font-size: 1.5rem;
    color: #6b7280;
    cursor: pointer;
    line-height: 1;
    padding: 0;
    width: 36px;
    height: 36px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    transition: all 0.2s ease;
    z-index: 10;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.admin-modal-close:hover {
    background-color: #ffffff;
    color: #111827;
    transform: rotate(90deg);
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.15);
}

.admin-modal-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 2rem;
    margin-top: 0.5rem;
    align-items: stretch;
}

.admin-modal-section {
    background-color: transparent;
    border-radius: 0;
    padding: 2.5rem;
    border: none;
    display: flex;
    flex-direction: column;
}

.admin-modal-single {
    max-width: 100%;
    margin: 0;
}

.admin-modal-section h2 {
    font-size: 1.75rem;
    font-weight: 600;
    color: #111827;
    margin-bottom: 2rem;
    margin-top: 0;
    letter-spacing: -0.025em;
    font-family: 'Roboto', sans-serif;
}

.admin-form-group {
    margin-bottom: 1.75rem;
    flex-shrink: 0;
}

.admin-forgot-password-container {
    display: flex;
    justify-content: center;
    margin-top: 1.25rem;
}

.admin-forgot-password {
    font-size: 0.875rem;
    color: #2563eb;
    text-decoration: none;
    font-weight: 500;
    transition: all 0.2s;
}

.admin-forgot-password:hover {
    color: #1d4ed8;
    text-decoration: underline;
}

.admin-error-message {
    padding: 1rem 1.125rem;
    background: linear-gradient(135deg, #fef2f2 0%, #fee2e2 100%);
    border: 2px solid #fecaca;
    border-radius: 0.75rem;
    color: #991b1b;
    font-size: 0.875rem;
    margin-bottom: 1rem;
    display: none;
    align-items: center;
    gap: 0.75rem;
    animation: fadeIn 0.3s ease;
    font-family: 'Roboto', sans-serif;
    font-weight: 500;
    box-shadow: 0 2px 4px rgba(239, 68, 68, 0.1);
}

.admin-error-message.show {
    display: flex;
}

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

.admin-error-message::before {
    content: '⚠️';
    font-size: 1.125rem;
    flex-shrink: 0;
    line-height: 1;
}

.admin-modal-section .admin-security-text {
    margin-top: 0.75rem;
    margin-bottom: 0;
}

.admin-form-group label {
    display: block;
    font-size: 0.9375rem;
    font-weight: 500;
    color: #374151;
    margin-bottom: 0.625rem;
    font-family: 'Roboto', sans-serif;
    letter-spacing: -0.01em;
}

.admin-input {
    width: 100%;
    padding: 0.875rem 1.125rem;
    font-size: 0.9375rem;
    border: 2px solid #e5e7eb;
    border-radius: 0.625rem;
    background-color: #ffffff;
    color: #111827;
    transition: all 0.2s ease;
    box-sizing: border-box;
    font-family: 'Roboto', sans-serif;
}

.admin-input:focus {
    outline: none;
    border-color: #2563eb;
    background-color: #ffffff;
    box-shadow: 0 0 0 4px rgba(37, 99, 235, 0.1), 0 2px 4px rgba(0, 0, 0, 0.05);
    transform: translateY(-1px);
}

.admin-input:hover {
    border-color: #d1d5db;
}

.admin-input::placeholder {
    color: #9ca3af;
    font-weight: 400;
}

.admin-radio-group {
    display: flex;
    flex-direction: row;
    gap: 1rem;
    margin-top: 0.75rem;
    align-items: stretch;
}

.admin-radio-box {
    display: flex;
    flex: 1;
    cursor: pointer;
    user-select: none;
    position: relative;
    min-width: 0;
}

.admin-radio-box input[type="radio"] {
    position: absolute;
    opacity: 0;
    width: 0;
    height: 0;
    margin: 0;
    padding: 0;
}

.admin-radio-box-content {
    width: 100%;
    padding: 1.25rem 1rem;
    border: 2px solid #e5e7eb;
    border-radius: 0.75rem;
    background-color: #ffffff;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
    transition: all 0.2s ease;
    height: 100%;
    box-sizing: border-box;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.05);
}

.admin-radio-box:hover .admin-radio-box-content {
    border-color: #2563eb;
    background-color: #f8fafc;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
    transform: translateY(-2px);
}

.admin-radio-box input[type="radio"]:checked + .admin-radio-box-content {
    border-color: #2563eb;
    background: linear-gradient(135deg, #eff6ff 0%, #dbeafe 100%);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
    transform: translateY(-2px);
}

.admin-radio-price {
    font-size: 1.5rem;
    color: #111827;
    font-weight: 600;
    line-height: 1.4;
    margin-bottom: 0.375rem;
    font-family: 'Roboto', sans-serif;
}

.admin-radio-desc {
    font-size: 0.8125rem;
    color: #6b7280;
    font-weight: 400;
    line-height: 1.4;
    font-family: 'Roboto', sans-serif;
}

.admin-btn-primary {
    width: 100%;
    padding: 1rem 1.5rem;
    background: linear-gradient(135deg, #2563eb 0%, #1d4ed8 100%);
    color: #ffffff;
    border: none;
    border-radius: 0.75rem;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s ease;
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
    margin-top: auto;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.625rem;
    font-family: 'Roboto', sans-serif;
    letter-spacing: 0.01em;
}

.admin-btn-account {
    margin-top: 0.5rem;
}

.admin-btn-primary svg {
    flex-shrink: 0;
    width: 18px;
    height: 18px;
    stroke-width: 2.5;
}

.admin-btn-primary:hover {
    background: linear-gradient(135deg, #1d4ed8 0%, #1e40af 100%);
    transform: translateY(-2px);
    box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
}

.admin-btn-primary:active {
    transform: translateY(0);
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
}

.admin-security-text {
    font-size: 0.8125rem;
    color: #6b7280;
    margin-top: 1.25rem;
    text-align: center;
    line-height: 1.6;
    font-family: 'Roboto', sans-serif;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
}

.admin-security-text::before {
    content: '🔒';
    font-size: 0.875rem;
}

/* Responsive Design for Admin Modal */
@media (max-width: 768px) {
    .admin-modal-grid {
        grid-template-columns: 1fr;
        gap: 1.5rem;
    }
    
    .admin-modal-content {
        padding: 1.5rem;
        max-height: 95vh;
    }
    
    .admin-modal-section {
        padding: 1.5rem;
    }
    
    .admin-modal-section h2 {
        font-size: 1.25rem;
        margin-bottom: 1.25rem;
    }
    
    .admin-radio-group {
        flex-direction: row;
        gap: 0.75rem;
        flex-wrap: nowrap;
    }
    
    .admin-radio-box-content {
        padding: 0.875rem;
        min-height: 70px;
    }
    
    .admin-radio-price {
        font-size: 1.125rem;
    }
    
    .admin-radio-desc {
        font-size: 0.75rem;
    }
}

@media (max-width: 480px) {
    .admin-modal-content {
        padding: 1rem;
    }
    
    .admin-modal-section {
        padding: 1.25rem;
    }
    
    .admin-modal-close {
        top: 0.5rem;
        right: 0.5rem;
        width: 28px;
        height: 28px;
        font-size: 1.5rem;
    }
}
