/* ===================================
   Dark Mode Override for Bootstrap
   =================================== */

/* Root Variables */
:root {
    --bs-body-bg: #ffffff;
    --bs-body-color: #1a202c;
    --bs-border-color: #e2e8f0;
}

[data-bs-theme="dark"] {
    /* n8n-inspired dark theme with maroon/purple tones */
    --bs-body-bg: #0c0810;
    --bs-body-color: #f5f0ff;
    --bs-border-color: #2a1f35;
}

/* Dark Mode Styles */
[data-bs-theme="dark"] body {
    background-color: var(--bs-body-bg);
    background-image: 
        radial-gradient(ellipse at top, #37174d 0%, transparent 50%),
        radial-gradient(ellipse at bottom right, #180d1c 0%, transparent 50%),
        radial-gradient(ellipse at bottom left, #150a15 0%, transparent 40%);
    background-attachment: fixed;
    color: var(--bs-body-color);
}

[data-bs-theme="dark"] .bg-white {
    background-color: #060306 !important;
}

[data-bs-theme="dark"] .bg-light {
    background-color: #1f1726 !important;
}

[data-bs-theme="dark"] .text-dark {
    color: #f5f0ff !important;
}

[data-bs-theme="dark"] .border {
    border-color: #2a1f35 !important;
}

[data-bs-theme="dark"] .card {
    background-color: #150f18;
    border-color: #2a1f35;
    color: #f5f0ff;
}

[data-bs-theme="dark"] .btn-outline-secondary {
    border-color: #2a1f35;
    color: #a89bb8;
}

[data-bs-theme="dark"] .btn-outline-secondary:hover {
    background-color: #2a1f35;
    border-color: #3d2d4a;
    color: #f5f0ff;
}

[data-bs-theme="dark"] .form-control,
[data-bs-theme="dark"] .form-select {
    background-color: #150f18;
    border-color: #2a1f35;
    color: #f5f0ff;
}

[data-bs-theme="dark"] .form-control:focus,
[data-bs-theme="dark"] .form-select:focus {
    background-color: #1f1726;
    border-color: #a78bfa;
    color: #f5f0ff;
    box-shadow: 0 0 0 3px rgba(167, 139, 250, 0.15);
}

[data-bs-theme="dark"] .modal-content {
    background-color: #150f18;
    color: #f5f0ff;
}

[data-bs-theme="dark"] .modal-header {
    border-bottom-color: #2a1f35;
}

[data-bs-theme="dark"] .modal-footer {
    border-top-color: #2a1f35;
}

[data-bs-theme="dark"] .dropdown-menu {
    background-color: #150f18;
    border-color: #2a1f35;
}

[data-bs-theme="dark"] .dropdown-item {
    color: #a89bb8;
}

[data-bs-theme="dark"] .dropdown-item:hover,
[data-bs-theme="dark"] .dropdown-item:focus {
    background-color: #2a1f35;
    color: #f5f0ff;
}

[data-bs-theme="dark"] .navbar {
    background-color: rgba(21, 15, 24, 0.95) !important;
    backdrop-filter: blur(10px);
    border-bottom-color: #2a1f35 !important;
}

[data-bs-theme="dark"] .list-group-item {
    background-color: #150f18;
    border-color: #2a1f35;
    color: #f5f0ff;
}

[data-bs-theme="dark"] .table {
    color: #f5f0ff;
}

[data-bs-theme="dark"] .table-striped > tbody > tr:nth-of-type(odd) > * {
    background-color: rgba(42, 31, 53, 0.3);
}

[data-bs-theme="dark"] .alert {
    border-color: #2a1f35;
}

[data-bs-theme="dark"] hr {
    border-color: #2a1f35;
    opacity: 1;
}

/* Text Colors */
[data-bs-theme="dark"] .text-muted {
    color: #a89bb8 !important;
}

[data-bs-theme="dark"] .text-secondary {
    color: #a89bb8 !important;
}

/* Link Colors */
[data-bs-theme="dark"] a {
    color: #c4b5fd;
}

[data-bs-theme="dark"] a:hover {
    color: #a78bfa;
}

/* Badge Colors */
[data-bs-theme="dark"] .badge {
    background-color: #2a1f35;
    color: #f5f0ff;
}

/* Custom Scrollbar for Dark Mode */
[data-bs-theme="dark"] ::-webkit-scrollbar {
    width: 10px;
    height: 10px;
}

[data-bs-theme="dark"] ::-webkit-scrollbar-track {
    background: #0c0810;
}

[data-bs-theme="dark"] ::-webkit-scrollbar-thumb {
    background: #2a1f35;
    border-radius: 5px;
}

[data-bs-theme="dark"] ::-webkit-scrollbar-thumb:hover {
    background: #3d2d4a;
}

/* Ensure smooth transitions */
* {
    transition: background-color 0.2s ease, color 0.2s ease, border-color 0.2s ease;
}

button,
input,
select,
textarea {
    transition: background-color 0.2s ease, color 0.2s ease, border-color 0.2s ease, box-shadow 0.2s ease;
}



