:root {
    --primary-color: #6366f1;
    --primary-dark: #4f46e5;
    --secondary-color: #8b5cf6;
    --accent-color: #06b6d4;
    --dark-bg: #05050a;
    --darker-bg: #0d0d16;
    --card-bg: rgba(17, 17, 27, 0.92);
    --card-border: rgba(255, 255, 255, 0.08);
    --text-primary: #ffffff;
    --text-secondary: #c7c9d9;
    --text-muted: #b8bcc8;
    --success-color: #10b981;
    --danger-color: #ef4444;
    --warning-color: #f59e0b;
    
    /* Override Bootstrap's --bs-secondary-color for dark mode */
    --bs-secondary-color: rgba(255, 255, 255, 0.65);
    --bs-body-secondary-color: rgba(255, 255, 255, 0.65);
}

* {
    box-sizing: border-box;
}

body {
    margin: 0;
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    background: radial-gradient(circle at top, rgba(99, 102, 241, 0.15), transparent),
        radial-gradient(circle at bottom, rgba(6, 182, 212, 0.12), transparent),
        var(--dark-bg);
    color: var(--text-primary);
    min-height: 100vh;
}

.wizard-shell {
    display: flex;
    min-height: 100vh;
}

.wizard-sidebar {
    width: 320px;
    background: rgba(30, 32, 45, 0.95);
    border-right: 1px solid rgba(255, 255, 255, 0.08);
    padding: 2rem;
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.wizard-brand {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    font-weight: 700;
    text-decoration: none;
    color: var(--text-primary);
    font-size: 1.1rem;
}

.wizard-brand img {
    height: 80px;
    width: auto;
}

.wizard-nav {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.nav-link {
    background: transparent;
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 10px;
    padding: 0.65rem 0.9rem;
    text-align: center;
    color: var(--text-secondary);
    font-size: 0.8rem;
    letter-spacing: 0.3px;
    text-transform: uppercase;
    cursor: pointer;
    transition: all 0.2s ease;
    width: 100%;
}

.nav-link.active {
    background: linear-gradient(135deg, var(--primary-color), var(--accent-color));
    color: white;
    border-color: transparent;
    box-shadow: 0 12px 30px rgba(99, 102, 241, 0.25);
}

.nav-link:hover:not(.active) {
    border-color: rgba(255, 255, 255, 0.25);
    color: white;
}

.nav-link--solve {
    margin-top: 0.25rem;
    border-color: rgba(16, 185, 129, 0.6);
    color: white;
    font-weight: 700;
    background: linear-gradient(135deg, #16a34a, #22c55e);
    box-shadow: 0 10px 25px rgba(16, 185, 129, 0.45);
}

.sidebar-divider {
    height: 1px;
    background: rgba(255, 255, 255, 0.08);
}

.file-ops h4 {
    margin: 0 0 0.75rem;
    font-size: 0.95rem;
    letter-spacing: 0.8px;
    text-transform: uppercase;
    color: var(--text-secondary);
}

.file-buttons {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.ghost-btn {
    background: rgba(255, 255, 255, 0.04);
    border: 1px dashed rgba(255, 255, 255, 0.12);
    color: var(--text-secondary);
    border-radius: 10px;
    padding: 0.65rem 0.9rem;
    font-size: 0.9rem;
    cursor: pointer;
    transition: all 0.2s ease;
}

.ghost-btn:hover {
    border-color: var(--accent-color);
    color: white;
}

.file-btn {
    border-radius: 12px;
    border-width: 1px;
    border-style: solid;
    font-weight: 600;
}

.file-btn--upload {
    border-color: rgba(99, 102, 241, 0.6);
}

.file-btn--download {
    border-color: rgba(14, 165, 233, 0.6);
}

.file-btn--save {
    border-color: rgba(16, 185, 129, 0.6);
}

.file-btn--upload:hover {
    border-color: rgba(99, 102, 241, 1);
}

.file-btn--download:hover {
    border-color: rgba(14, 165, 233, 1);
}

.file-btn--save:hover {
    border-color: rgba(16, 185, 129, 1);
}

.file-name-label {
    display: block;
    margin: 1rem 0 0.35rem;
    font-size: 0.8rem;
    letter-spacing: 0.5px;
    text-transform: uppercase;
    color: var(--text-muted);
}

.file-ops input[type="text"] {
    width: 100%;
    border-radius: 10px;
    background: rgba(0, 0, 0, 0.25);
    border: 1px solid rgba(255, 255, 255, 0.08);
    color: white;
    padding: 0.6rem 0.75rem;
    font-size: 0.9rem;
}

.file-ops input[type="text"]:focus {
    border-color: var(--accent-color);
    outline: none;
    background: rgba(255, 255, 255, 0.08);
}

.sidebar-footer {
    margin-top: auto;
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
    padding-top: 0.75rem;
}

.toggle-switch {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.9rem;
    color: var(--text-secondary);
}

.toggle-switch input[type="checkbox"] {
    opacity: 0;
    width: 0;
    height: 0;
}

.toggle-switch .switch {
    position: relative;
    width: 46px;
    height: 24px;
    background: rgba(255, 255, 255, 0.2);
    border-radius: 999px;
    transition: background 0.3s ease;
}

.toggle-switch .switch::after {
    content: '';
    position: absolute;
    top: 2px;
    left: 2px;
    width: 20px;
    height: 20px;
    border-radius: 50%;
    background: white;
    transition: transform 0.3s ease;
}

.toggle-switch input:checked + .switch {
    background: linear-gradient(135deg, var(--primary-color), var(--accent-color));
}

.toggle-switch input:checked + .switch::after {
    transform: translateX(22px);
}

.toggle-switch .switch-label {
    letter-spacing: 0.5px;
}
.progress-stack {
    display: flex;
    flex-direction: column;
    gap: 0.35rem;
    font-size: 0.85rem;
    color: var(--text-muted);
}

.progress-track {
    width: 100%;
    height: 8px;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.08);
    overflow: hidden;
}

.progress-value {
    height: 100%;
    width: 0%;
    border-radius: 999px;
    background: linear-gradient(135deg, var(--primary-color), var(--accent-color));
    transition: width 0.3s ease;
}

.wizard-main {
    flex: 1;
    padding: 3rem;
    overflow-y: auto;
}

.wizard-panel {
    display: none;
    animation: fadeIn 0.3s ease;
}

.wizard-panel.active {
    display: block;
}

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

.panel-header {
    display: flex;
    justify-content: space-between;
    gap: 2rem;
    margin-bottom: 2rem;
    flex-wrap: wrap;
}

.eyebrow {
    text-transform: uppercase;
    letter-spacing: 1.2px;
    color: var(--accent-color);
    font-size: 0.85rem;
    margin-bottom: 0.25rem;
}

.panel-header h1 {
    margin: 0;
    font-size: 2.4rem;
}

.panel-subtitle {
    margin-top: 0.5rem;
    color: var(--text-secondary);
    max-width: 640px;
}

.panel-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 0.75rem;
    align-items: flex-start;
}

.primary-btn,
.secondary-btn {
    border: none;
    border-radius: 12px;
    padding: 0.85rem 1.5rem;
    font-size: 0.95rem;
    font-weight: 600;
    cursor: pointer;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.primary-btn {
    background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
    color: white;
    box-shadow: 0 15px 30px rgba(99, 102, 241, 0.35);
}

.secondary-btn {
    background: transparent;
    border: 1px solid rgba(255, 255, 255, 0.2);
    color: white;
}

.primary-btn:hover,
.secondary-btn:hover {
    transform: translateY(-2px);
}

.summary-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 1.25rem;
    margin-bottom: 2rem;
}

.summary-card {
    background: var(--card-bg);
    border: 1px solid var(--card-border);
    border-radius: 16px;
    padding: 1.25rem;
    box-shadow: 0 25px 60px rgba(0, 0, 0, 0.25);
}

.summary-card span {
    text-transform: uppercase;
    font-size: 0.75rem;
    letter-spacing: 1px;
    color: var(--text-muted);
}

.summary-card h3 {
    margin: 0.5rem 0 0;
    font-size: 1.8rem;
}

.muted-text {
    margin-top: 0.25rem;
    color: var(--text-muted);
    font-size: 0.85rem;
}

.preview-block {
    background: rgba(17, 17, 27, 0.85);
    border: 1px solid var(--card-border);
    border-radius: 18px;
    padding: 1.5rem;
}

.preview-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1rem;
}

.json-filename {
    font-size: 0.85rem;
    font-weight: 400;
    color: var(--accent-color);
    margin-left: 0.75rem;
    padding: 0.25rem 0.6rem;
    background: rgba(6, 182, 212, 0.15);
    border-radius: 6px;
    border: 1px solid rgba(6, 182, 212, 0.3);
}

.json-filename:empty {
    display: none;
}

.code-block {
    margin: 0;
    background: rgba(5, 5, 12, 0.85);
    border-radius: 14px;
    padding: 1rem;
    border: 1px solid rgba(255, 255, 255, 0.08);
    color: var(--text-secondary);
    max-height: 400px;
    overflow: auto;
    font-family: 'SFMono-Regular', Consolas, 'Liberation Mono', Menlo, monospace;
    font-size: 0.85rem;
    line-height: 1.6;
}

.code-block.small {
    max-height: 260px;
}

#jsonPreview {
    background: #ffffff;
    color: #111;
    border-color: #e5e7eb;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
}

.solution-meta {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 1rem;
    margin-bottom: 1.5rem;
}

.status-pill {
    align-self: flex-start;
    border-radius: 999px;
    padding: 0.45rem 1.25rem;
    font-weight: 600;
    background: rgba(99, 102, 241, 0.15);
    border: 1px solid rgba(99, 102, 241, 0.45);
}

.split-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    gap: 1.25rem;
}

.data-list {
    list-style: none;
    padding: 0;
    margin: 0;
}

.data-list li {
    padding: 0.45rem 0;
    border-bottom: 1px solid rgba(255, 255, 255, 0.06);
    font-size: 0.92rem;
    color: var(--text-secondary);
}

.data-list.compact li {
    padding: 0.3rem 0;
}

.data-list li:last-child {
    border-bottom: none;
}

.insights-grid {
    grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
}

.solution-toolbar {
    display: flex;
    justify-content: flex-end;
    margin-bottom: 1rem;
    gap: 0.5rem;
}

.loading-modal .modal-content {
    background: rgba(13, 13, 25, 0.95);
    border: 1px solid rgba(255, 255, 255, 0.08);
    color: white;
}

.modal-content {
    background: rgba(28, 28, 42, 0.98);
    border-radius: 18px;
    border: 1px solid rgba(99, 102, 241, 0.25);
    color: var(--text-primary);
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.5),
                0 0 0 1px rgba(255, 255, 255, 0.05),
                0 0 60px rgba(99, 102, 241, 0.08);
}

.modal-header,
.modal-footer {
    border-color: rgba(99, 102, 241, 0.15);
}

.modal-header {
    background: rgba(99, 102, 241, 0.08);
    border-bottom: 1px solid rgba(99, 102, 241, 0.2);
}

/* Darker backdrop for better modal contrast */
.modal-backdrop.show {
    opacity: 0.85;
    background-color: #000;
}

.spinner-border {
    width: 3rem;
    height: 3rem;
    border-width: 0.25rem;
}

.modal-header .btn-close,
.btn-close {
    background: transparent url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16' fill='%23ffffff'%3e%3cpath d='M.293.293a1 1 0 0 1 1.414 0L8 6.586 14.293.293a1 1 0 1 1 1.414 1.414L9.414 8l6.293 6.293a1 1 0 0 1-1.414 1.414L8 9.414l-6.293 6.293a1 1 0 0 1-1.414-1.414L6.586 8 .293 1.707a1 1 0 0 1 0-1.414z'/%3e%3c/svg%3e") center/1em auto no-repeat !important;
    border-radius: 50%;
    width: 40px;
    height: 40px;
    border: 1px solid rgba(255, 255, 255, 0.3) !important;
    opacity: 1 !important;
    padding: 0.5rem;
    filter: none !important;
    cursor: pointer;
    transition: all 0.2s ease;
}

.modal-header .btn-close:hover,
.btn-close:hover {
    background-color: rgba(239, 68, 68, 0.3) !important;
    border-color: rgba(239, 68, 68, 0.6) !important;
}

/* Modal form controls for dark theme */
.modal .form-control,
.modal .form-select {
    background-color: rgba(5, 5, 12, 0.85);
    border: 1px solid rgba(255, 255, 255, 0.15);
    color: var(--text-primary);
}

.modal .form-control:focus,
.modal .form-select:focus {
    background-color: rgba(10, 10, 20, 0.9);
    border-color: var(--accent-color);
    color: var(--text-primary);
    box-shadow: 0 0 0 0.2rem rgba(6, 182, 212, 0.25);
}

.modal .form-control::placeholder {
    color: var(--text-muted);
}

.modal .form-label,
.modal label {
    color: var(--text-secondary);
}

/* Table input styling in modals */
.modal .table input,
.modal .table select {
    background-color: rgba(5, 5, 12, 0.85);
    border: 1px solid rgba(255, 255, 255, 0.15);
    color: var(--text-primary);
    border-radius: 6px;
    padding: 0.4rem 0.6rem;
}

.modal .table input:focus,
.modal .table select:focus {
    background-color: rgba(10, 10, 20, 0.9);
    border-color: var(--accent-color);
    outline: none;
    box-shadow: 0 0 0 0.15rem rgba(6, 182, 212, 0.25);
}

.modal .table input::placeholder {
    color: var(--text-muted);
}

.step-indicator {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 2rem;
    padding: 0 1rem;
}

.step {
    flex: 1;
    text-align: center;
    padding: 0.5rem;
    background-color: rgba(255, 255, 255, 0.1);
    color: var(--text-muted);
    border-radius: 4px;
    margin: 0 0.25rem;
    font-size: 0.85rem;
    font-weight: 500;
    position: relative;
    transition: all 0.3s ease;
}

.step.active {
    background-color: var(--primary-color);
    color: white;
    font-weight: 600;
    transform: scale(1.05);
    box-shadow: 0 0 10px rgba(99, 102, 241, 0.4);
    border: 2px solid var(--primary-color);
}

.step.completed {
    background-color: var(--success-color);
    color: white;
}

/* Clickable step navigation */
.step {
    cursor: pointer;
    user-select: none;
}

.step:hover:not(.active) {
    background-color: rgba(99, 102, 241, 0.3);
    color: white;
    transform: scale(1.02);
}

.step.completed:hover:not(.active) {
    background-color: rgba(16, 185, 129, 0.7);
}

.step::after {
    content: '';
    position: absolute;
    right: -0.5rem;
    top: 50%;
    transform: translateY(-50%);
    width: 0;
    height: 0;
    border-top: 8px solid transparent;
    border-bottom: 8px solid transparent;
    border-left: 8px solid rgba(255, 255, 255, 0.1);
    z-index: 1;
}

.step.active::after {
    border-left-color: var(--primary-color);
}

.step.completed::after {
    border-left-color: var(--success-color);
}

.step:last-child::after {
    display: none;
}

.table {
    margin-bottom: 1rem;
    border-radius: 18px;
    overflow: hidden;
    color: var(--text-primary);
}

.table th {
    font-weight: 600;
    background-color: rgba(99, 102, 241, 0.3) !important;
    background: linear-gradient(135deg, rgba(99, 102, 241, 0.4), rgba(6, 182, 212, 0.3)) !important;
    border-bottom: 2px solid rgba(255, 255, 255, 0.08) !important;
    color: #ffffff !important;
}

/* Override Bootstrap table-light for dark theme */
.table thead.table-light,
.table thead.table-light th,
.modal .table thead,
.modal .table thead th,
.table thead th,
thead th {
    background: linear-gradient(135deg, rgba(99, 102, 241, 0.4), rgba(6, 182, 212, 0.3)) !important;
    color: #ffffff !important;
    border-color: rgba(255, 255, 255, 0.1) !important;
}

.table th,
.table td {
    padding: 0.85rem 0.9rem;
    border: none;
    font-size: 0.9rem;
}

.table tbody tr {
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}

.table tbody tr:last-child {
    border-bottom: none;
}

.table-striped tbody tr:nth-of-type(odd) {
    background-color: rgba(255, 255, 255, 0.02);
}

@media (max-width: 1024px) {
    .wizard-shell {
        flex-direction: column;
    }

    .wizard-sidebar {
        width: 100%;
        flex-direction: row;
        flex-wrap: wrap;
        gap: 1rem;
    }

    .wizard-nav {
        flex-direction: row;
        flex-wrap: wrap;
    }

    .wizard-main {
        padding: 2rem;
    }
}

@media (max-width: 720px) {
    .panel-header {
        flex-direction: column;
        align-items: flex-start;
    }

    .wizard-sidebar {
        flex-direction: column;
    }
}

/* Step 6: Termination Options Styles */
#terminationOptions .card-body {
    padding: 1rem;
}

#terminationOptions .form-check {
    padding: 0.5rem 0.75rem;
    margin-bottom: 0.5rem;
    border-radius: 8px;
    transition: background-color 0.2s;
}

#terminationOptions .form-check:hover {
    background: rgba(99, 102, 241, 0.1);
}

#terminationOptions .form-check-input:checked ~ .form-check-label {
    color: #ffffff;
}

#terminationOptions .form-control-sm {
    background: rgba(5, 5, 12, 0.8);
    border: 1px solid rgba(99, 102, 241, 0.4);
    color: #ffffff;
}

#terminationOptions .form-control-sm:focus {
    border-color: var(--primary-color);
    box-shadow: 0 0 0 2px rgba(99, 102, 241, 0.2);
}

#terminationOptions .form-control-sm:disabled {
    background: rgba(107, 114, 128, 0.2);
    color: rgba(255, 255, 255, 0.4);
    cursor: not-allowed;
}

#terminationChevron {
    transition: transform 0.2s ease;
}

#terminationBadge {
    font-size: 0.7rem;
    padding: 0.2rem 0.5rem;
}

/* Success text styling for form hints */
.text-success.form-text {
    color: #10b981 !important;
}

/* Solve Progress Modal Styles */
.progress-stats-card {
    transition: all 0.3s ease;
}

/* =============================================================================
   BOOTSTRAP TEXT UTILITY OVERRIDES FOR DARK MODE
   ============================================================================= */

/* GLOBAL: Fix Bootstrap's .text-muted which defaults to dark gray (#6c757d) */
/* Using high-specificity selectors to override Bootstrap */
.text-muted,
p.text-muted,
small.text-muted,
span.text-muted,
div.text-muted {
    color: rgba(255, 255, 255, 0.65) !important;
}

/* Combined class selectors */
.text-muted.small,
p.text-muted.small,
.small.text-muted {
    color: rgba(255, 255, 255, 0.6) !important;
}

/* Modal-specific overrides - ensure all modal text is visible */
.modal .text-muted,
.modal-body .text-muted,
.modal-content .text-muted,
.modal-body p.text-muted,
.modal-content p.text-muted {
    color: rgba(255, 255, 255, 0.65) !important;
}

/* Small text inside modals */
.modal small,
.modal-body small,
.modal .small,
.modal-body .small,
p.small.text-muted {
    color: rgba(255, 255, 255, 0.6) !important;
}

.text-secondary,
.modal .text-secondary,
.modal-body .text-secondary {
    color: rgba(255, 255, 255, 0.7) !important;
}

.form-text,
.modal .form-text,
.modal-body .form-text {
    color: rgba(255, 255, 255, 0.55) !important;
}

/* Rule category descriptions - ensure visible on dark background */
.rule-category-info small,
.rule-category-section small {
    color: rgba(255, 255, 255, 0.6) !important;
}

/* Chip text in templates */
.chip-text,
.rule-template-chip .chip-text {
    color: rgba(255, 255, 255, 0.9) !important;
}

/* Step description text - all step containers */
.step3-header .text-muted,
.step3-container .text-muted,
.step4-header .text-muted,
.step4-container .text-muted,
.step5-container .text-muted,
.step6-container .text-muted,
.step-description {
    color: rgba(255, 255, 255, 0.65) !important;
}

/* Card field help text */
.wizard-card-field small,
.wizard-card-field .form-text {
    color: rgba(255, 255, 255, 0.55) !important;
}

/* Step container descriptions */
.step3-header p,
.step4-header p,
.step5-header p,
.step6-header p,
.step-header-section p {
    color: rgba(255, 255, 255, 0.65) !important;
}

/* Variable selector section text */
.variable-selector-section h6,
.variable-labels-section h6,
.resource-grids-container h6,
.rule-templates-section h6 {
    color: rgba(255, 255, 255, 0.9) !important;
}

.variable-selector-section p,
.variable-selector-section .text-muted,
.variable-selector-section p.text-muted.small,
.variable-selector-section .small {
    color: rgba(255, 255, 255, 0.65) !important;
}

/* Rule templates section */
.rule-templates-section .text-muted,
.rule-category-section .text-muted {
    color: rgba(255, 255, 255, 0.65) !important;
}

/* Form labels in wizard modals */
.modal-body .form-label,
.modal-body label.small {
    color: rgba(255, 255, 255, 0.85) !important;
}

/* Variable type hints */
.variable-type-hint,
.form-text.variable-type-hint {
    color: rgba(255, 255, 255, 0.5) !important;
}

/* Resource grid headers */
.resource-grid-header h6 {
    color: rgba(255, 255, 255, 0.9) !important;
}

.progress-stats-card .text-muted {
    color: rgba(255, 255, 255, 0.6) !important;
}

#scoreSparkline {
    display: flex;
    align-items: flex-end;
    gap: 2px;
    height: 40px;
    padding: 4px;
    background: rgba(0, 0, 0, 0.2);
    border-radius: 6px;
}

.sparkline-bar {
    flex: 1;
    min-width: 4px;
    max-width: 20px;
    border-radius: 2px 2px 0 0;
    transition: height 0.3s ease;
}

.sparkline-placeholder {
    width: 100%;
    text-align: center;
    align-self: center;
}

#progressCurrentScore {
    font-size: 0.95rem;
    font-weight: 600;
}

#progressImprovements {
    font-size: 1.1rem;
}

.loading-modal .progress {
    border-radius: 4px;
    overflow: hidden;
}

.loading-modal .progress-bar {
    transition: width 0.3s ease;
}

#cancelSolveBtn {
    font-size: 0.85rem;
    padding: 0.4rem 1rem;
}

#cancelSolveBtn:hover {
    background: rgba(239, 68, 68, 0.2);
}

/* Pulse animation for solving indicator */
#progressTitle {
    animation: pulse 2s infinite;
}

@keyframes pulse {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.7; }
}

/* =============================================================================
   PLANNING PIN FEATURE STYLES
   ============================================================================= */

/* Pinned column styling */
.col-pinned {
    width: 70px !important;
    text-align: center;
}

.col-assignedTo {
    width: 140px !important;
}

/* Pinned checkbox styling */
.entity-pinned {
    width: 18px;
    height: 18px;
    cursor: pointer;
    accent-color: #10b981;
}

.entity-pinned:checked {
    background-color: #10b981;
    border-color: #10b981;
}

/* AssignedTo dropdown styling */
.entity-assignedTo {
    font-size: 0.8rem;
    padding: 0.25rem 0.5rem;
    background: rgba(5, 5, 12, 0.8);
    border: 1px solid rgba(99, 102, 241, 0.3);
    color: #ffffff;
}

.entity-assignedTo:disabled {
    background: rgba(107, 114, 128, 0.2);
    color: rgba(255, 255, 255, 0.4);
    cursor: not-allowed;
}

/* Priority dropdown styling */
.entity-priority {
    font-size: 0.8rem;
    padding: 0.25rem 0.5rem;
    background: rgba(5, 5, 12, 0.8);
    border: 1px solid rgba(99, 102, 241, 0.3);
    color: #ffffff;
    min-width: 100px;
}

.entity-priority:focus {
    border-color: #6366f1;
    box-shadow: 0 0 0 2px rgba(99, 102, 241, 0.2);
}

.entity-priority option {
    background: #1e1b4b;
    color: #ffffff;
}

.entity-assignedTo:not(:disabled):focus {
    border-color: #10b981;
    box-shadow: 0 0 0 2px rgba(16, 185, 129, 0.2);
}

/* Pinned row highlight */
.pinned-row {
    background: rgba(16, 185, 129, 0.08) !important;
    border-left: 3px solid #10b981;
}

.pinned-row:hover {
    background: rgba(16, 185, 129, 0.12) !important;
}

/* Pinned column header styling */
th[data-column="pinned"],
th[data-column="assignedTo"] {
    background: linear-gradient(135deg, rgba(16, 185, 129, 0.4), rgba(6, 182, 212, 0.3)) !important;
}

/* Planning Pin legend addition */
.column-legend-item .swatch.pinned {
    background: linear-gradient(135deg, rgba(16, 185, 129, 0.5), rgba(6, 182, 212, 0.4));
    border: 1px solid rgba(16, 185, 129, 0.6);
}



/* =============================================================================
   CRITICAL: FINAL DARK MODE TEXT OVERRIDES (Highest Priority)
   Must be at the end of the file to ensure they override all other styles
   ============================================================================= */

/* Force all text-muted to be visible on dark backgrounds */
.modal-content .text-muted,
.modal-body .text-muted,
#step2Modal .text-muted,
#step3Modal .text-muted,
#step4Modal .text-muted,
#step5Modal .text-muted,
#step6Modal .text-muted,
#step7Modal .text-muted {
    color: rgba(255, 255, 255, 0.65) !important;
}

/* Step container specific overrides */
.step3-container .text-muted,
.step3-header .text-muted,
.step4-container .text-muted,
.step4-header .text-muted,
.variable-selector-section .text-muted,
.rule-category-info .text-muted {
    color: rgba(255, 255, 255, 0.65) !important;
}

/* Small text combined with text-muted */
.modal-content .text-muted.small,
.modal-content p.text-muted.small,
.modal-content small.text-muted {
    color: rgba(255, 255, 255, 0.6) !important;
}

/* Ensure form labels are visible */
.modal-content .form-label,
.modal-content label {
    color: rgba(255, 255, 255, 0.85) !important;
}


/* Ultra-high specificity override for Bootstrap's text-muted */
body .text-muted,
body p.text-muted,
body small.text-muted,
body span.text-muted,
body label.text-muted,
body div.text-muted {
    color: rgba(255, 255, 255, 0.65) !important;
}

/* Small text combined with text-muted - body level */
body .text-muted.small,
body p.text-muted.small,
body .small.text-muted {
    color: rgba(255, 255, 255, 0.6) !important;
}
