/* ==========================================
Careers Page Layout
========================================== */
.careers-hero {
    position: relative;
    width: 100%;
    height: 480px;
    background: url('../images/join.png') no-repeat center center/cover;
    display: flex;
    justify-content: center;
    align-items: center;
    text-align: center;
    overflow: hidden;
}

/* Semi-transparent overlay so the background image shows through */
.careers-hero::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(41, 46, 60, 0.65); /* Matches navy theme color */
    z-index: 1;
} 

/* Ensure content sits above the overlay */
.careers-hero .section-container {
    position: relative;
    z-index: 2;
    padding: 0 20px;
}

.careers-hero h1 {
    font-size: 40px;
    font-weight: 700;
    color: #ffffff;
    margin-bottom: 15px;
}

.careers-hero p {
    font-size: 18px;
    color: #ffffff;
    max-width: 700px;
    margin: 0 auto;
    line-height: 1.6;
}

/* Section Grid Container */
.careers-content {
    background-color: #f8fafc;
    padding: 20px 0;
}

.careers-grid {
    display: grid;
    grid-template-columns: 1.5fr 1fr;
    gap: 0px;
    align-items: start;
}

/* Left Column: Roles Accordion */
.roles-list h2 {
    font-size: 28px;
    color: #1e3a8a;
    margin-bottom: 25px;
    margin-left: 5px;
}

.role-card {
    background: #ffffff;
    border: 1px solid #e2e8f0;
    border-radius: 10px;
    margin-bottom: 18px;
    overflow: hidden;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.03);
    transition: border-color 0.3s ease, box-shadow 0.3s ease;
}

.role-card:hover {
    border-color: #cbd5e1;
    box-shadow: 0 6px 15px rgba(0, 0, 0, 0.06);
}

.role-header {
    width: 100%;
    padding: 22px 25px;
    background: none;
    border: none;
    display: flex;
    justify-content: space-between;
    align-items: center;
    text-align: left;
    cursor: pointer;
    outline: none;
    transition: background-color 0.2s ease;
}

.role-header:hover {
    background-color: #f1f5f9;
}

.role-title-group h3 {
    font-size: 20px;
    color: #1e3a8a;
    margin: 0 0 5px 0;
}

.role-meta {
    font-size: 13px;
    color: #64748b;
    font-weight: 500;
}

.toggle-icon {
    font-size: 24px;
    font-weight: 600;
    color: #1e3a8a;
    transition: transform 0.3s ease;
    line-height: 1;
}

/* Expand / Collapse Details */
.role-details {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.4s cubic-bezier(0, 1, 0, 1);
    background-color: #ffffff;
}

.role-card.active .role-details {
    max-height: 1000px; /* High max-height to accommodate open content */
    transition: max-height 0.5s ease-in-out;
}

.role-card.active {
    border-color: #3b82f6;
}

.role-card.active .toggle-icon {
    transform: rotate(45deg); /* Turns + into x */
}

.role-body {
    padding: 0 25px 25px 25px;
    border-top: 1px solid #f1f5f9;
}

.role-body h4 {
    font-size: 16px;
    color: #0f172a;
    margin: 20px 0 10px 0;
}

.role-body p {
    font-size: 14px;
    color: #475569;
    line-height: 1.6;
    margin-bottom: 15px;
}

.role-body ul {
    margin: 0;
    padding-left: 20px;
}

.role-body li {
    font-size: 14px;
    color: #475569;
    line-height: 1.6;
    margin-bottom: 8px;
}

/* Add padding to the left open roles container */
.roles-list {
    padding: 60px 60px 60px 60px; /* Top, Right, Bottom, Left */
}

/* Add padding to the right application sidebar container */
.apply-sidebar {
    padding: 60px 60px 60px 60px;
} 

/* Right Column: Sticky Application Sidebar */
.apply-sidebar {
    position: sticky;
    top: 100px; /* Sticks nicely during vertical scrolling */
}

.instruction-card {
    background: #ffffff;
    border: 1px solid #e2e8f0;
    border-radius: 12px;
    padding: 35px 30px;
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.05);
}

.card-badge {
    display: inline-block;
    background-color: #e0e7ff;
    color: #1e3a8a;
    font-size: 12px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    padding: 4px 12px;
    border-radius: 20px;
    margin-bottom: 15px;
}

.instruction-card h3 {
    font-size: 22px;
    color: #0f172a;
    margin-bottom: 12px;
}

.instruction-card p {
    font-size: 14px;
    color: #64748b;
    line-height: 1.6;
    margin-bottom: 20px;
}

.email-link {
    display: flex;
    align-items: center;
    gap: 10px;
    background-color: #1e3a8a;
    color: #ffffff;
    text-decoration: none;
    padding: 14px 18px;
    border-radius: 8px;
    font-weight: 600;
    font-size: 15px;
    word-break: break-all;
    transition: background-color 0.3s ease, transform 0.2s ease;
    margin-bottom: 25px;
}

.email-link:hover {
    background-color: #152860;
    transform: translateY(-2px);
}

.email-icon {
    width: 20px;
    height: 20px;
    flex-shrink: 0;
}

.application-tips h4 {
    font-size: 15px;
    color: #1e293b;
    margin-bottom: 12px;
}

.application-tips ul {
    padding-left: 18px;
    margin: 0;
}

.application-tips li {
    font-size: 13px;
    color: #64748b;
    line-height: 1.6;
    margin-bottom: 10px;
}

.application-tips code {
    background: #f1f5f9;
    padding: 2px 6px;
    border-radius: 4px;
    color: #0f172a;
}

/* Responsive Adjustments */
@media (max-width: 992px) {
    .careers-grid {
        grid-template-columns: 1fr;
    }

    .apply-sidebar {
        position: relative;
        top: 0;
    }
}