/* Add these styles at the top after the root variables */
:root[data-bs-theme="light"] {
    --custom-border-color: #e9ecef;
    --custom-bg-color: #ffffff;
    --custom-text-color: var(--bs-body-color);
    --title-blue: #1a73e8;
}

/* Simple navbar styling */
.navbar-custom {
    background-color: #ffffff;
    padding: 0px;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
}

.navbar-brand-container {
    display: flex;
    align-items: center;
    justify-content: space-between;
    width: 100%;
}

/* Text logo */
.app-logo {
    display: inline-block; 
    margin-right: 15px;
}

.app-logo-text {
    color: #1a73e8;
    font-size: 24px;
    font-weight: 700;
    display: inline-block;
    margin-left: 8px;
}

.app-logo i {
    color: #1a73e8;
    font-size: 24px;
}

/* Partner logo */
.partner-logo {
    height: 60px;
    width: auto;
}

.upload-container {
    max-width: 800px;
    margin: 2rem auto;
    padding: 2rem;
    border-radius: 8px;
    background: var(--custom-bg-color);
    border: 1px solid var(--custom-border-color);
    color: var(--custom-text-color);
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.05);
}

.title-text {
    color: var(--title-blue) !important;
}

.loading-spinner {
    display: none;
    text-align: center;
    margin: 1rem 0;
}

.loading-spinner.active {
    display: block;
}

/* Modal Styles for Contract Checker */
.modal-lg {
    max-width: 800px;
}

.modal-content {
    border-radius: 10px;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
}

.modal-header {
    background-color: var(--title-blue);
    color: white;
    border-radius: 10px 10px 0 0;
}

.modal-title {
    font-weight: 600;
}

.alert-success, .alert-danger {
    border-radius: 6px;
}

.alert-success i, .alert-danger i {
    margin-right: 10px;
}

.compliance-progress {
    margin-bottom: 20px;
}

.progress {
    height: 10px;
    border-radius: 10px;
}

.category-title {
    font-weight: bold;
    margin-bottom: 5px;
}

.category-box {
    padding: 15px;
    border-radius: 6px;
    margin-bottom: 15px;
    background-color: #f8f9fa;
    border-left: 4px solid #6c757d;
}

.category-box.essential {
    border-left-color: #dc3545;
}

.category-box.statutory {
    border-left-color: #ffc107;
}

.category-box.commercial_advisory {
    border-left-color: #0d6efd;
}

.compliance-reference {
    font-size: 0.85rem;
    color: #6c757d;
    margin-top: 10px;
    padding-top: 5px;
    border-top: 1px solid #dee2e6;
}

.compliance-reference a {
    color: #0d6efd;
    text-decoration: none;
}

.compliance-reference a:hover {
    text-decoration: underline;
}

.missing-elements .list-group-item,
.compliant-elements .list-group-item {
    padding: 10px 15px;
    display: flex;
    align-items: center;
}

.missing-elements .fa-times-circle {
    color: #dc3545;
}

.compliant-elements .fa-check-circle {
    color: #28a745;
}

pre {
    white-space: pre-wrap;
    word-wrap: break-word;
    padding: 1.5rem;
    border-radius: 8px;
    font-size: 1.1rem;
    margin: 1.5rem 0;
    background: var(--custom-bg-color);
    border: 1px solid var(--custom-border-color);
    color: var(--custom-text-color);
}

.alert {
    margin-bottom: 1.5rem;
    padding: 1.25rem;
}

.file-input-wrapper {
    position: relative;
    overflow: hidden;
    display: inline-block;
}

.file-input-wrapper input[type=file] {
    font-size: 100px;
    position: absolute;
    left: 0;
    top: 0;
    opacity: 0;
    cursor: pointer;
}

.drop-zone {
    border: 2px dashed var(--bs-secondary);
    border-radius: 8px;
    padding: 2rem;
    text-align: center;
    transition: all 0.3s ease;
    background: var(--custom-bg-color);
    color: var(--custom-text-color);
}

.drop-zone.highlighted {
    border-color: var(--title-blue);
    background: rgba(38, 84, 195, 0.1);
}

.drop-zone.file-selected {
    border-color: var(--bs-success);
    background: rgba(var(--bs-success-rgb), 0.1);
}

.drop-zone i {
    color: var(--title-blue);
}

.drop-zone p:not(.text-muted) {
    color: var(--title-blue);
}

body {
    background-color: var(--custom-bg-color);
}

/* Custom button style */
.btn-custom-blue {
    background-color: var(--title-blue);
    border-color: var(--title-blue);
    color: white;
    font-weight: bold;
}

.btn-custom-blue:hover {
    background-color: #1e43a2;
    border-color: #1e43a2;
    color: white;
}

/* Theme toggle button styles */
#themeToggle i {
    margin-right: 0.5rem;
}

/* Health & Safety Assessment Styles - Bright Theme */
/* Main container styling */
.health-safety-container {
    background-color: #ffffff !important;
    border-radius: 10px !important;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1) !important;
    padding: 20px !important;
}

/* Headings and text styling */
.health-safety-container h1, 
.health-safety-container h2, 
.health-safety-container h3, 
.health-safety-container h4, 
.health-safety-container h5,
.health-safety-container .lead,
.health-safety-container p, 
.health-safety-container label,
.card-header h2,
.intro-section h1,
.intro-section p,
.assessment-section h2,
.question-item h5,
.form-check-label {
    color: #1F4287 !important; /* Rich blue color for text */
    text-shadow: none !important;
}

/* Card header styling - vibrant blue */
.health-safety-container .card-header {
    background-color: #4EA5D9 !important; /* Bright blue */
    border-bottom: 1px solid #44CFCB !important;
    border-radius: 8px 8px 0 0 !important;
    padding: 15px 20px !important;
}

/* Card header text - make it white for contrast */
.health-safety-container .card-header h2 {
    color: #ffffff !important;
    font-weight: 600 !important;
    text-shadow: 0 1px 2px rgba(0, 0, 0, 0.1) !important;
}

/* Question styling - Bright, high-contrast version */
.health-safety-container .question-item {
    background-color: white !important; /* White background */
    border-left: 6px solid #FF6B6B !important; /* Bright red accent for emphasis */
    padding: 20px !important;
    margin-bottom: 20px !important;
    border-radius: 0 8px 8px 0 !important;
    box-shadow: 0 4px 8px rgba(0,0,0,0.08) !important;
    border: 1px solid #E0E0E0 !important;
    border-left-width: 6px !important;
}

/* Force the question text to be visible */
.health-safety-container .question-item h5 {
    color: #000000 !important; /* Pure black for maximum contrast */
    font-weight: 700 !important; /* Extra bold */
    margin-bottom: 15px !important;
    font-size: 1.15rem !important;
    line-height: 1.5 !important;
    text-shadow: none !important;
    font-family: Arial, Helvetica, sans-serif !important;
    display: block !important;
    visibility: visible !important;
    opacity: 1 !important;
    padding: 0 !important;
}

/* Form elements styling - Force visibility */
.health-safety-container .form-check-label {
    color: #000000 !important; /* Pure black for maximum contrast */
    font-weight: 500 !important; /* Medium weight */
    font-size: 1rem !important;
    font-family: Arial, Helvetica, sans-serif !important;
    display: inline-block !important;
    visibility: visible !important;
    opacity: 1 !important;
    margin-left: 5px !important;
}

.health-safety-container .form-check-input:checked {
    background-color: #44CFCB !important; /* Teal color for checked items */
    border-color: #44CFCB !important;
}

/* Introduction section styling */
.health-safety-container .intro-section {
    background-color: #F5F9FC !important;
    border-left: 6px solid #4EA5D9 !important;
    padding: 20px !important;
    border-radius: 0 10px 10px 0 !important;
    margin-bottom: 30px !important;
}

.health-safety-container .intro-section h1 {
    color: #1F4287 !important;
    font-size: 2.2rem !important;
    font-weight: bold !important;
    margin-bottom: 1rem !important;
}

.health-safety-container .intro-section .lead {
    font-size: 1.2rem !important;
    font-weight: normal !important;
    color: #1F4287 !important;
}

/* Progress bar styling */
.health-safety-container .progress {
    height: 12px !important;
    border-radius: 10px !important;
    background-color: #E0E0E0 !important;
    overflow: hidden;
}

.health-safety-container .progress-bar {
    background-color: #44CFCB !important; /* Teal progress bar */
}

/* OpenAI Results Progress Bar */
#openai-results .progress {
    height: 12px;
    border-radius: 10px;
    overflow: hidden;
    background-color: rgba(0, 0, 0, 0.05);
    box-shadow: inset 0 1px 3px rgba(0, 0, 0, 0.1);
}

#openai-results .progress-bar {
    transition: width 0.6s ease-in-out;
}

/* Alerts styling */
.health-safety-container .alert-info {
    background-color: #E0F4FF !important;
    border-color: #4EA5D9 !important;
    color: #1F4287 !important;
}

/* Toggle button styling */
.section-toggle-btn {
    background-color: rgba(78, 165, 217, 0.2) !important;
    border: none !important;
    border-radius: 50% !important;
    width: 32px !important;
    height: 32px !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    transition: all 0.3s ease !important;
}

.section-toggle-btn:hover {
    background-color: rgba(78, 165, 217, 0.6) !important;
    transform: scale(1.1) !important;
}

.section-toggle-btn .toggle-icon {
    color: #1F4287 !important;
    font-size: 16px !important;
    transition: transform 0.3s ease !important;
}

.section-toggle-btn.active {
    background-color: #4EA5D9 !important; 
}

.section-toggle-btn.active .toggle-icon {
    color: white !important;
}

/* Section body styling */
.card-body {
    background-color: white !important;
    padding: 20px !important;
    border-radius: 0 0 8px 8px !important;
}

/* Alert styling */
.alert-info {
    padding: 0.6rem;
    font-size: 0.85rem;
}

.alert-info i {
    font-size: 0.85rem;
    margin-right: 0.4rem;
}

/* Custom color classes for sections */
.bg-purple {
    background-color: #6f42c1 !important;
}

.border-purple {
    border-color: #6f42c1 !important;
}

.text-purple {
    color: #6f42c1 !important;
}

/* Submit button styling with green color scheme */
.submit-btn {
    background-color: #31C67A;
    color: white;
    border: none;
    border-radius: 6px;
    padding: 12px 25px;
    font-size: 1.1rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 4px 6px rgba(49, 198, 122, 0.2);
}

.submit-btn:hover {
    background-color: #27A866;
    box-shadow: 0 6px 8px rgba(49, 198, 122, 0.3);
    transform: translateY(-2px);
}

/* OpenAI Results Section Styling */
#openai-results {
    border-radius: 16px;
    overflow: hidden;
    box-shadow: 0 8px 15px rgba(0, 0, 0, 0.1);
}

.section-breakdown .card {
    border-radius: 12px;
    overflow: hidden;
    transition: transform 0.2s ease-in-out, box-shadow 0.2s ease-in-out;
}

.section-breakdown .card:hover {
    transform: translateY(-3px);
    box-shadow: 0 6px 12px rgba(0, 0, 0, 0.15);
}

.section-breakdown .card-header {
    border-radius: 12px 12px 0 0 !important;
}

.recommendations {
    background-color: #f8f9fa;
    border-radius: 12px;
    padding: 20px;
    margin-top: 20px;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.05);
}

.recommendations h4 {
    color: #31C67A;
    margin-bottom: 15px;
}

/* Accordion custom styling */
#reportAccordion .accordion-button:not(.collapsed) {
    color: white;
    box-shadow: none;
}

#reportAccordion .accordion-item {
    border-radius: 10px;
    overflow: hidden;
    margin-bottom: 10px;
    border: 1px solid rgba(0, 0, 0, 0.125);
}

#reportAccordion .accordion-button {
    border-radius: 10px;
}

#reportAccordion .accordion-button:not(.collapsed) {
    border-radius: 10px 10px 0 0;
}

#reportAccordion .accordion-collapse {
    border-radius: 0 0 10px 10px;
}

/* Section 1 - General Information (Purple) */
#generalAccordion .accordion-button:not(.collapsed) {
    background: linear-gradient(to right, #9c56c2, #7e3f9d);
}

/* Section 2 - First Day Onboarding (Blue) */
#firstDayAccordion .accordion-button:not(.collapsed) {
    background: linear-gradient(to right, #0d6efd, #0b5ed7);
}

/* Section 3 - Additional Questions (Red) */
#additionalAccordion .accordion-button:not(.collapsed) {
    background: linear-gradient(to right, #ff7675, #f53b57);
}

/* Section 4 - Summary (Green) */
#summaryAccordion .accordion-button:not(.collapsed) {
    background-color: #31C67A;
}

/* Custom summary-green background color class */
.bg-summary-green {
    background-color: #31C67A !important;
}

.bg-summary-green.bg-opacity-10 {
    background-color: rgba(49, 198, 122, 0.1) !important;
}

.text-summary-green {
    color: #31C67A !important;
}

/* Print styles */
@media print {
    body {
        background-color: white !important;
        padding: 0 !important;
        font-size: 12pt;
    }
    
    /* Hide elements that shouldn't appear in print */
    .navbar, .footer, .toggle-btn, .section-toggle-btn, #submit-assessment, #downloadReportBtn, 
    .health-safety-form, #loadingOverlay, .alert, .master-progress, button.accordion-button::after {
        display: none !important;
    }
    
    /* Ensure content is displayed properly */
    .accordion-collapse {
        display: block !important;
        height: auto !important;
    }
    
    .accordion-button {
        color: white !important;
        box-shadow: none !important;
        border-radius: 5px 5px 0 0 !important;
        page-break-inside: avoid;
    }
    
    .accordion-item {
        page-break-inside: avoid;
        margin-bottom: 20px;
        border: 1px solid #ddd !important;
    }
    
    .card {
        page-break-inside: avoid;
        margin-bottom: 15px;
        border: 1px solid #ddd !important;
    }
    
    /* Make sure text is black for readability in print */
    .card-body {
        color: #000 !important;
    }
    
    /* Ensure headers print properly */
    h1, h2, h3, h4, h5 {
        page-break-after: avoid;
        page-break-inside: avoid;
    }
    
    /* Add a header for the report */
    .print-header {
        display: block !important;
        text-align: center;
        margin-bottom: 20px;
        border-bottom: 2px solid #31C67A;
        padding-bottom: 15px;
    }
    
    .print-header h1 {
        color: #1F4287 !important;
        font-size: 24pt;
        margin-bottom: 5px;
    }
    
    .print-header p {
        color: #666;
        font-size: 12pt;
    }
    
    .print-footer {
        display: block !important;
        text-align: center;
        margin-top: 20px;
        border-top: 1px solid #ddd;
        padding-top: 10px;
        font-size: 10pt;
        color: #666;
    }
    
    /* Add page numbers */
    @page {
        margin: 2cm;
    }
    
    /* Container modifications */
    .container, .container-fluid {
        width: 100% !important;
        max-width: 100% !important;
        padding: 0 !important;
        margin: 0 !important;
    }
    
    /* Results area */
    #resultsArea {
        display: block !important;
        padding: 0 !important;
        margin: 0 !important;
        border: none !important;
    }
    
    /* Progress bars and pills */
    .progress-bar {
        print-color-adjust: exact;
        -webkit-print-color-adjust: exact;
    }
    
    .badge {
        print-color-adjust: exact;
        -webkit-print-color-adjust: exact;
    }
}
/* Footer Styles with Pure CSS Starfield */
.compliance-footer {
    background: linear-gradient(135deg, #1e293b 0%, #334155 100%) !important;
    margin-top: auto;
    position: relative;
    overflow: hidden;
}

.compliance-footer::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: 
        radial-gradient(2px 2px at 20px 30px, #fff, transparent),
        radial-gradient(2px 2px at 40px 70px, #3b82f6, transparent),
        radial-gradient(1px 1px at 90px 40px, #ef4444, transparent),
        radial-gradient(1px 1px at 130px 80px, #fff, transparent),
        radial-gradient(2px 2px at 160px 30px, #3b82f6, transparent),
        radial-gradient(1px 1px at 200px 60px, #ef4444, transparent),
        radial-gradient(1px 1px at 230px 20px, #fff, transparent),
        radial-gradient(2px 2px at 280px 90px, #3b82f6, transparent),
        radial-gradient(1px 1px at 320px 50px, #ef4444, transparent),
        radial-gradient(1px 1px at 360px 10px, #fff, transparent);
    background-size: 400px 120px;
    background-repeat: repeat;
    animation: stars-move 20s linear infinite;
    z-index: 1;
    pointer-events: none;
}

@keyframes stars-move {
    0% { background-position: 0px 0px; }
    100% { background-position: -400px 0px; }
}

.star {
    position: absolute;
    background: white;
    border-radius: 50%;
    animation: moveTowardsViewer infinite;
}

.star.accent {
    background: #3b82f6;
}

.star.secondary {
    background: #ef4444;
}

@keyframes moveTowardsViewer {
    0% { 
        transform: scale(0.1); 
        opacity: 0; 
    }
    10% { 
        opacity: 1; 
    }
    90% { 
        opacity: 1; 
    }
    100% { 
        transform: scale(1.5); 
        opacity: 0; 
    }
}

.footer > * {
    position: relative;
    z-index: 2;
}

.footer-brand .brand-name {
    font-family: 'Montserrat', sans-serif;
    font-weight: 700;
    font-size: 1.5rem;
    color: #fff;
    margin-bottom: 0.5rem;
}

.footer-brand .brand-tagline {
    color: #cbd5e1;
    font-size: 0.9rem;
    line-height: 1.5;
    margin-bottom: 0;
}

.footer-heading {
    color: #fff;
    font-weight: 600;
    font-size: 1.1rem;
    margin-bottom: 1rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

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

.footer-links li {
    margin-bottom: 0.5rem;
}

.footer-links a {
    color: #cbd5e1;
    text-decoration: none;
    font-size: 0.9rem;
    transition: color 0.3s ease;
}

.footer-links a:hover {
    color: #fff;
}

.footer-contact p {
    color: #cbd5e1;
    margin-bottom: 0.5rem;
    font-size: 0.9rem;
}

.social-links a {
    display: inline-block;
    width: 35px;
    height: 35px;
    line-height: 35px;
    text-align: center;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.1);
    transition: all 0.3s ease;
}

.social-links a:hover {
    background: rgba(255, 255, 255, 0.2);
    transform: translateY(-2px);
}

.footer-bottom {
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    background: rgba(0, 0, 0, 0.2);
}

.footer-legal a {
    color: #cbd5e1;
    text-decoration: none;
    font-size: 0.85rem;
    margin-right: 1.5rem;
    transition: color 0.3s ease;
}

.footer-legal a:hover {
    color: #fff;
}

.copyright {
    color: #cbd5e1;
    font-size: 0.85rem;
}

/* Ensure footer stays at bottom */
body {
    display: flex;
    flex-direction: column;
    min-height: 100vh;
}

.container.mt-4 {
    flex: 1;
}
