/* Auth styles moved to dedicated auth.css file */
  
  /* ------------------------------------------------------------------
     Global brand buttons – use purple brand colors
     ------------------------------------------------------------------*/
  .btn-brand {
    background: #3736af !important;
    border-color: #3736af !important;
    color: #fff !important;
    --bs-btn-bg: #3736af;
    --bs-btn-border-color: #3736af;
    --bs-btn-color: #fff;
    --bs-btn-hover-bg: #2b2a88;
    --bs-btn-hover-border-color: #2b2a88;
  }
  
  .btn-brand:hover,
  .btn-brand:focus {
    background: #2b2a88 !important;
    border-color: #2b2a88 !important;
    color: #fff !important;
  }
  
  .btn-outline-brand {
    color: #3736af !important;
    border-color: #3736af !important;
    --bs-btn-color: #3736af;
    --bs-btn-border-color: #3736af;
  }
  
  .btn-outline-brand:hover,
  .btn-outline-brand:focus {
    background: #3736af !important;
    color: #fff !important;
  }
  
  /* Auth-specific button styles moved to auth.css */
  
  /* ------------------------------------------------------------------
     Navbar – centered pill design with brand colors
     ------------------------------------------------------------------*/
  .navbar-wrapper {
    z-index: 1100 !important;
    background: transparent;
  }

  #mainNav {
    background: rgba(17, 26, 46, 0.95) !important;
    border: 1px solid rgba(255,255,255,0.12) !important;
    backdrop-filter: blur(20px) !important;
    box-shadow: 0 8px 32px rgba(0,0,0,0.3) !important;
    max-width: none;
    transition: all 0.3s ease !important;
  }

  #mainNav:hover {
    background: rgba(17, 26, 46, 0.98) !important;
    box-shadow: 0 12px 40px rgba(0,0,0,0.4) !important;
  }

  /* Mobile navbar - remove pill when expanded */
  @media (max-width: 991.98px) {
    .navbar-wrapper {
      padding: 0.75rem 1rem !important;
    }

    #mainNav {
      border-radius: 1rem !important;
    }

    #mainNav .navbar-collapse {
      margin-top: 1rem;
      padding-top: 1rem;
      border-top: 1px solid rgba(255, 255, 255, 0.1);
    }

    #mainNav .navbar-nav {
      gap: 0.25rem !important;
    }

    #mainNav .nav-link {
      padding: 0.75rem 1rem !important;
      border-radius: 0.5rem;
    }

    #mainNav .nav-link:hover {
      background: rgba(255, 255, 255, 0.05);
    }

    #mainNav .nav-item.ms-2 {
      margin-left: 0 !important;
      margin-top: 0.5rem;
    }

    #mainNav .btn-outline-brand {
      width: 100%;
      justify-content: center;
    }
  }
  
  #mainNav .btn-brand {
    background: linear-gradient(90deg, #3736af, #3693ff) !important;
    border: none !important;
    color: #ffffff !important;
  }
  
  #mainNav .btn-brand:hover {
    background: linear-gradient(90deg, #2b2a88, #2e6bff) !important;
    transform: translateY(-1px) !important;
    box-shadow: 0 4px 12px rgba(54,147,255,0.3) !important;
    color: #ffffff !important;
  }
  
  #mainNav .btn-outline-brand {
    background: transparent !important;
    border: 1px solid rgba(255, 255, 255, 0.25) !important;
    color: #ffffff !important;
    border-radius: 999px !important;
  }
  
  #mainNav .btn-outline-brand:hover {
    background: rgba(255, 255, 255, 0.1) !important;
    border-color: rgba(255, 255, 255, 0.4) !important;
    color: #ffffff !important;
    transform: translateY(-1px) !important;
  }
  
  /* ------------------------------------------------------------------
     Global scroll safeguard - let hero section background extend to top
     ------------------------------------------------------------------*/
  html, body { 
    max-width: 100%; 
    overflow-x: hidden; 
    background: transparent;
  }
  body { 
    padding-top: 90px; /* Adjusted for centered navbar */
  }
  body > * { max-width: 100%; }

/* Dark Theme Support */
.dark-theme-preview body,
body.dark-theme {
    background-color: #1a1a1a;
    color: #ffffff;
}

.dark-theme-preview .card,
body.dark-theme .card {
    background-color: #2d2d2d;
    border-color: #444;
}

.dark-theme-preview .settings-card,
body.dark-theme .settings-card {
    background-color: #2d2d2d;
    box-shadow: 0 2px 10px rgba(0,0,0,0.3);
}

.dark-theme-preview .form-control,
body.dark-theme .form-control {
    background-color: #3a3a3a;
    border-color: #555;
    color: #ffffff;
}

.dark-theme-preview .form-control:focus,
body.dark-theme .form-control:focus {
    background-color: #3a3a3a;
    border-color: var(--primary);
    color: #ffffff;
    box-shadow: 0 0 0 0.2rem rgba(55, 54, 175, 0.25);
}

.dark-theme-preview .list-group-item,
body.dark-theme .list-group-item {
    background-color: #2d2d2d;
    border-color: #444;
    color: #ffffff;
}

.dark-theme-preview .notification-item,
body.dark-theme .notification-item {
    border-bottom-color: #444;
}

.dark-theme-preview .session-item,
body.dark-theme .session-item {
    background-color: #3a3a3a;
    border-color: #555;
}

.dark-theme-preview .text-muted,
body.dark-theme .text-muted {
    color: #aaa !important;
}

.dark-theme-preview .breadcrumb,
body.dark-theme .breadcrumb {
    background-color: transparent;
}

.dark-theme-preview .breadcrumb-item a,
body.dark-theme .breadcrumb-item a {
    color: #ccc;
}

.dark-theme-preview .breadcrumb-item.active,
body.dark-theme .breadcrumb-item.active {
    color: #fff;
}

.dark-theme-preview .alert,
body.dark-theme .alert {
    border-color: #444;
}

.dark-theme-preview .alert-success,
body.dark-theme .alert-success {
    background-color: rgba(40, 167, 69, 0.1);
    border-color: #28a745;
    color: #4caf50;
}

.dark-theme-preview .alert-danger,
body.dark-theme .alert-danger {
    background-color: rgba(220, 53, 69, 0.1);
    border-color: #dc3545;
    color: #f44336;
}

.dark-theme-preview .alert-warning,
body.dark-theme .alert-warning {
    background-color: rgba(255, 193, 7, 0.1);
    border-color: #ffc107;
    color: #ff9800;
}

.dark-theme-preview .alert-info,
body.dark-theme .alert-info {
    background-color: rgba(23, 162, 184, 0.1);
    border-color: #17a2b8;
    color: #00bcd4;
}

/* Settings specific styles */
.settings-toggle-animation {
    transition: all 0.3s ease;
}

/* Settings page header styling */
.settings-header-card .card-title {
    font-size: 1.5rem;
    font-weight: 600;
    margin-bottom: 0.5rem;
}

.settings-header-card p {
    color: #6c757d;
    margin-bottom: 0;
}

.form-check-input:checked {
    background-color: var(--primary);
    border-color: var(--primary);
}

.password-strength-indicator {
    font-size: 0.875rem;
    margin-top: 0.5rem;
}

.strength-text {
    font-weight: 500;
}

.strength-text.weak { color: #dc3545; }
.strength-text.fair { color: #ffc107; }
.strength-text.good { color: #17a2b8; }
.strength-text.strong { color: #28a745; }

/* Auto-save indicator animation */
@keyframes fadeInOut {
    0% { opacity: 0; transform: translateY(-10px); }
    50% { opacity: 1; transform: translateY(0); }
    100% { opacity: 0; transform: translateY(-10px); }
}

.auto-save-indicator {
    animation: fadeInOut 2s ease-in-out;
}

/* Mobile responsive adjustments */
@media (max-width: 768px) {
    .settings-header {
        padding: 1rem;
    }
    
    .settings-header h5 {
        font-size: 1.1rem;
    }
    
    .settings-header p {
        font-size: 0.8rem;
    }
    
    .theme-preview {
        width: 35px;
        height: 35px;
        margin-right: 8px;
    }
    
    .notification-item {
        padding: 0.75rem;
        flex-direction: column;
        align-items: flex-start;
        gap: 0.5rem;
    }
    
    .session-item {
        padding: 0.75rem;
    }
}

/* Loading states */
.loading-spinner {
    width: 1rem;
    height: 1rem;
    border: 2px solid #f3f3f3;
    border-top: 2px solid var(--primary);
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* Form validation styles */
.is-invalid {
    border-color: #dc3545;
}

.invalid-feedback {
    display: block;
    width: 100%;
    margin-top: 0.25rem;
    font-size: 0.875rem;
    color: #dc3545;
}

.is-valid {
    border-color: #28a745;
}

.valid-feedback {
    display: block;
    width: 100%;
    margin-top: 0.25rem;
    font-size: 0.875rem;
    color: #28a745;
}

/* Custom checkbox styling */
.form-check-input:focus {
    border-color: var(--primary);
    outline: 0;
    box-shadow: 0 0 0 0.25rem rgba(55, 54, 175, 0.25);
}

/* Export progress styling */
.export-progress .progress {
    height: 6px;
    background-color: #e9ecef;
}

.export-progress .progress-bar {
    background-color: var(--primary);
    transition: width 0.3s ease;
}

/* Section content collapse animation */
.section-content {
    max-height: 2000px;
    overflow: hidden;
    transition: max-height 0.5s ease;
}

.section-content.collapsed {
    max-height: 0;
    padding-top: 0 !important;
    padding-bottom: 0 !important;
}

/* Tooltip styles */
.tooltip {
    font-size: 0.875rem;
}

.tooltip-inner {
    background-color: var(--primary);
    color: white;
}

/* ------------------------------------------------------------------
   Override base theme text-transform: capitalize on tables.
   The theme applies capitalize to .table td which turns "EURUSD"
   into "Eurusd". We reset it to none so data displays as stored.
   ------------------------------------------------------------------*/
.table td,
.table th,
table.dataTable td,
table.dataTable th {
    text-transform: none;
}

/* ------------------------------------------------------------------
   Footer – default light background for app pages
   ------------------------------------------------------------------*/
.site-footer {
    background: var(--color-surface, #ffffff);
}

.footer-brand {
    color: #3736af;
}