/* Careers Openings & Application Modal Block Styles */
html.careers-modal-open,
body.careers-modal-open {
    overflow: hidden !important;
    height: 100vh !important;
}

.careers-openings-block {
    background: #0b192c;
    padding: 80px 0;
    color: #ffffff;
}

.careers-header-wrap {
    text-align: center;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    margin-bottom: 32px;
}

.careers-tag-badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-family: 'Montserrat', sans-serif;
    font-size: 12px;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 2px;
    color: #ccac60;
    background: rgba(204, 172, 96, 0.12);
    border: 1px solid #ccac60;
    padding: 6px 18px;
    border-radius: 30px;
    margin: 0 auto 16px;
    width: fit-content;
}

.careers-empty-state-box {
    background: #162942;
    border: 2px dashed rgba(204, 172, 96, 0.4);
    border-radius: 12px;
    padding: 56px 32px;
    max-width: 750px;
    margin: 40px auto 0;
    text-align: center;
    transition: border-color 0.3s ease, box-shadow 0.3s ease;
}

.careers-empty-state-box:hover {
    border-color: #ccac60;
    box-shadow: 0 10px 30px rgba(204, 172, 96, 0.15);
}

.careers-empty-icon {
    font-size: 40px;
    margin-bottom: 16px;
    display: block;
}

.careers-empty-state-box h3 {
    font-family: 'Montserrat', sans-serif;
    font-size: 22px;
    font-weight: 700;
    margin-bottom: 10px;
    color: #ffffff;
}

.careers-empty-state-box p {
    font-family: 'Inter', sans-serif;
    color: #a0aec0;
    font-size: 15px;
    margin-bottom: 28px;
    max-width: 520px;
    margin-left: auto;
    margin-right: auto;
    line-height: 1.6;
}

/* Active Job Cards Flex Grid (Centering support) */
.careers-jobs-grid {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 24px;
    max-width: 960px;
    margin: 40px auto 0;
}

.careers-job-card {
    background: #162942;
    border: 1px solid rgba(204, 172, 96, 0.25);
    border-radius: 12px;
    padding: 28px;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
    transition: transform 0.3s ease, border-color 0.3s ease, box-shadow 0.3s ease;
    flex: 1 1 420px;
    max-width: 460px;
    width: 100%;
    box-sizing: border-box;
}

.careers-job-card:hover {
    border-color: #ccac60;
    transform: translateY(-4px);
    box-shadow: 0 14px 40px rgba(204, 172, 96, 0.15);
}

.job-card-title {
    font-family: 'Montserrat', sans-serif;
    font-size: 1.25rem !important;
    font-weight: 700 !important;
    color: #ffffff !important;
}

.job-card-meta {
    font-family: 'Inter', sans-serif !important;
    color: #cbd5e1 !important;
    font-size: 0.9rem !important;
}

.job-card-excerpt {
    font-family: 'Inter', sans-serif !important;
    font-size: 14px !important;
    color: #e2e8f0 !important;
    line-height: 1.6 !important;
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.job-type-badge {
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    white-space: nowrap !important;
    background: rgba(204, 172, 96, 0.18) !important;
    border: 1px solid #ccac60 !important;
    color: #ccac60 !important;
    font-family: 'Montserrat', sans-serif !important;
    font-size: 11px !important;
    font-weight: 700 !important;
    padding: 5px 14px !important;
    border-radius: 20px !important;
    letter-spacing: 0.03em !important;
    line-height: 1 !important;
    text-transform: uppercase !important;
    flex-shrink: 0 !important;
}

/* Fixed Overlay & Modal Box */
.careers-modal-overlay {
    position: fixed !important;
    top: 0 !important;
    left: 0 !important;
    width: 100vw !important;
    height: 100vh !important;
    z-index: 999999 !important;
    background: rgba(4, 9, 16, 0.88) !important;
    backdrop-filter: blur(12px) !important;
    -webkit-backdrop-filter: blur(12px) !important;
    display: none;
    align-items: center;
    justify-content: center;
    padding: 20px !important;
    box-sizing: border-box !important;
}

.careers-modal-overlay.open {
    display: flex !important;
}

.careers-modal-box {
    background: #122238 !important;
    border: 1px solid #ccac60 !important;
    border-radius: 14px !important;
    width: 100% !important;
    max-width: 640px !important;
    padding: 36px !important;
    position: relative !important;
    box-shadow: 0 25px 60px rgba(0, 0, 0, 0.8) !important;
    color: #ffffff !important;
    max-height: 85vh !important;
    overflow-y: scroll !important;
    -webkit-overflow-scrolling: touch !important;
    box-sizing: border-box !important;
}

/* Custom Scrollbar for Application Modal Box */
.careers-modal-box::-webkit-scrollbar {
    width: 8px !important;
}

.careers-modal-box::-webkit-scrollbar-track {
    background: rgba(11, 25, 44, 0.6) !important;
    border-radius: 10px !important;
}

.careers-modal-box::-webkit-scrollbar-thumb {
    background: #ccac60 !important;
    border-radius: 10px !important;
}

.careers-modal-box::-webkit-scrollbar-thumb:hover {
    background: #e5c578 !important;
}

/* Wide Job Details Modal Box */
.careers-details-modal-box {
    width: 92vw !important;
    max-width: 1040px !important;
    height: 82vh !important;
    max-height: 780px !important;
    display: flex !important;
    flex-direction: column !important;
    padding: 32px 36px !important;
    overflow: hidden !important; /* Prevents outer box scroll trap */
}

.job-details-modal-header {
    flex: 0 0 auto !important;
}

.job-details-modal-footer {
    flex: 0 0 auto !important;
}

#detailsModalTitle {
    color: #ffffff !important;
    font-size: 1.75rem !important;
    font-weight: 800 !important;
    font-family: 'Montserrat', sans-serif !important;
}

#detailsModalMeta {
    color: #cbd5e1 !important;
    font-size: 0.95rem !important;
    font-family: 'Inter', sans-serif !important;
}

/* Scrollable Modal Body */
.job-details-modal-body {
    flex: 1 1 0% !important;
    height: 100% !important;
    max-height: 100% !important;
    min-height: 0 !important; /* CRITICAL for flexbox inner scrolling */
    overflow-y: scroll !important;
    -webkit-overflow-scrolling: touch !important;
    padding-right: 16px;
    margin-top: 12px !important;
    margin-bottom: 16px !important;
    font-family: 'Inter', sans-serif !important;
    color: #f1f5f9 !important;
    font-size: 15.5px !important;
    line-height: 1.75 !important;
    box-sizing: border-box !important;
}

/* Custom Gold Scrollbar for Modal Body */
.job-details-modal-body::-webkit-scrollbar {
    width: 8px !important;
}

.job-details-modal-body::-webkit-scrollbar-track {
    background: rgba(11, 25, 44, 0.6) !important;
    border-radius: 10px !important;
}

.job-details-modal-body::-webkit-scrollbar-thumb {
    background: #ccac60 !important;
    border-radius: 10px !important;
}

.job-details-modal-body::-webkit-scrollbar-thumb:hover {
    background: #e5c578 !important;
}

/* WYSIWYG Content Styling in Modal Body */
.job-details-modal-body p {
    color: #e2e8f0 !important;
    margin-bottom: 16px !important;
}

.job-details-modal-body strong,
.job-details-modal-body b {
    color: #ffffff !important;
}

.job-details-modal-body h1,
.job-details-modal-body h2,
.job-details-modal-body h3,
.job-details-modal-body h4 {
    color: #ccac60 !important;
    font-family: 'Montserrat', sans-serif !important;
    font-weight: 700 !important;
    margin-top: 24px !important;
    margin-bottom: 12px !important;
}

.job-details-modal-body h3 {
    font-size: 1.3rem !important;
}

.job-details-modal-body h4 {
    font-size: 1.15rem !important;
}

.job-details-modal-body ul,
.job-details-modal-body ol {
    color: #f1f5f9 !important;
    margin-bottom: 20px !important;
    padding-left: 24px !important;
}

.job-details-modal-body li {
    margin-bottom: 8px !important;
    color: #f1f5f9 !important;
}

.job-details-modal-body ul li::marker {
    color: #ccac60 !important;
}

.careers-modal-close {
    position: absolute;
    top: 20px;
    right: 20px;
    background: none;
    border: none;
    color: #a0aec0;
    font-size: 24px;
    cursor: pointer;
    line-height: 1;
}

.careers-modal-close:hover {
    color: #ffffff;
}

.careers-modal-title {
    font-family: 'Montserrat', sans-serif;
    font-size: 24px;
    font-weight: 800;
    margin-bottom: 8px;
    color: #ccac60;
    text-align: left;
}

.careers-modal-subtitle {
    font-family: 'Inter', sans-serif;
    font-size: 14px;
    color: #a0aec0;
    margin-bottom: 24px;
    text-align: left;
    line-height: 1.5;
}

/* Buttons */
.btn-gold {
    background: #ccac60 !important;
    color: #ffffff !important;
    font-family: 'Montserrat', sans-serif !important;
    font-weight: 800 !important;
    text-transform: uppercase !important;
    letter-spacing: 1px !important;
    border-radius: 6px !important;
    border: none !important;
    transition: all 0.3s ease;
}

.btn-gold:hover {
    background: #e5c578 !important;
    color: #ffffff !important;
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(204, 172, 96, 0.3);
}

.btn-outline-gold {
    background: transparent !important;
    color: #ccac60 !important;
    border: 1px solid #ccac60 !important;
    font-family: 'Montserrat', sans-serif !important;
    font-weight: 800 !important;
    text-transform: uppercase !important;
    letter-spacing: 1px !important;
    border-radius: 6px !important;
    transition: all 0.3s ease;
}

.btn-outline-gold:hover {
    background: rgba(204, 172, 96, 0.15) !important;
    color: #ffffff !important;
    border-color: #e5c578 !important;
}

@media (max-width: 768px) {
    .careers-empty-state-box {
        padding: 36px 20px;
    }
    .careers-modal-box {
        padding: 24px;
    }
    .careers-details-modal-box {
        width: 95vw !important;
        height: 90vh !important;
        padding: 24px !important;
    }
    .careers-jobs-grid {
        grid-template-columns: 1fr;
    }
    .careers-job-card {
        max-width: 100%;
    }
}
