/* ==================== JOB DETAIL PAGE ==================== */

.job-detail {
    position: relative;
    max-width: var(--gj-max-width);
    margin: 0 auto;
    padding: var(--gj-space-xl) var(--gj-page-px) var(--gj-space-3xl);
    display: flex;
    flex-direction: column;
    gap: var(--gj-space-lg);
}

.job-detail.job-detail-faded::before {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(to bottom, rgba(255, 255, 255, 0) 0%, rgba(255, 255, 255, 0.4) 100px, rgba(255, 255, 255, 0.6) 30%, rgba(255, 255, 255, 0.6) 100%);
    pointer-events: none;
    z-index: 1;
}

.job-detail-banner {
    padding: var(--gj-space-sm) var(--gj-space-md);
    border-radius: var(--gj-radius-md);
    background: var(--gj-brand-subtle);
    border: 1px solid var(--gj-border-light);
    font-size: var(--gj-text-sm);
    color: var(--gj-text-secondary);
}

.job-detail-banner strong {
    color: var(--gj-text-primary);
}

/* ==================== HEADER ==================== */

.job-detail-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: var(--gj-space-lg);
}

.job-detail-header-left {
    display: flex;
    gap: var(--gj-space-md);
    align-items: flex-start;
    min-width: 0;
}

.job-detail-logo {
    width: 64px;
    height: 64px;
    border-radius: var(--gj-radius-md);
    flex-shrink: 0;
    object-fit: cover;
    overflow: hidden;
}

.job-detail-logo-placeholder {
    background: var(--gj-gray-100);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: var(--gj-text-2xl);
    color: var(--gj-text-muted);
}

.job-detail-title {
    font-size: var(--gj-text-2xl);
    font-weight: 700;
    color: var(--gj-text-primary);
    line-height: 1.2;
}

.job-detail-employer-row {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: var(--gj-space-xs) var(--gj-space-sm);
    min-width: 0;
}

.job-detail-employer {
    font-size: var(--gj-text-base);
    color: var(--gj-brand);
    font-weight: 500;
}

.job-detail-employer:hover {
    color: var(--gj-brand-dark);
    text-decoration: underline;
}

.job-detail-employer-type {
    font-size: var(--gj-text-xs);
    color: var(--gj-text-muted);
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.job-detail-header-right {
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    gap: var(--gj-space-xs);
    flex-shrink: 0;
}

.job-detail-salary {
    font-size: var(--gj-text-lg);
    font-weight: 700;
    color: var(--gj-brand);
}


/* ==================== META BAR ==================== */

.job-detail-meta {
    display: flex;
    flex-wrap: wrap;
    gap: var(--gj-space-sm) var(--gj-space-lg);
    padding: var(--gj-space-md);
    background: var(--gj-gray-50);
    border-radius: var(--gj-radius-md);
}

.job-detail-meta-item {
    font-size: var(--gj-text-sm);
    color: var(--gj-text-secondary);
}

#shareJobBtn {
    cursor: pointer;
    user-select: none;
}

#shareJobBtn:hover {
    text-decoration: underline;
}


/* ==================== TAGS ==================== */

.job-detail-tags {
    display: flex;
    flex-wrap: wrap;
    gap: var(--gj-space-xs);
}


/* ==================== BENEFITS ==================== */

.job-detail-benefits h3,
.job-detail-languages h3 {
    font-size: var(--gj-text-base);
    font-weight: 600;
    margin-bottom: var(--gj-space-sm);
}

.job-detail-benefits-grid {
    display: flex;
    flex-wrap: wrap;
    gap: var(--gj-space-xs);
}

.job-detail-benefit {
    display: inline-flex;
    align-items: center;
    gap: var(--gj-space-xs);
    padding: 0.375rem 0.75rem;
    background: var(--gj-brand-subtle);
    border-radius: var(--gj-radius-full);
    font-size: var(--gj-text-sm);
    color: var(--gj-brand-dark);
}

.job-detail-benefit-icon {
    font-size: var(--gj-text-base);
}


/* ==================== LANGUAGES ==================== */

.job-detail-language-list {
    display: flex;
    flex-wrap: wrap;
    gap: var(--gj-space-xs);
}


/* ==================== DESCRIPTION ==================== */

.job-detail-description-content {
    font-size: var(--gj-text-base);
    line-height: 1.7;
    color: var(--gj-text-primary);
    padding: var(--gj-space-xl) var(--gj-space-xs);
    border-top: 1px solid var(--gj-border-light);
    border-bottom: 1px solid var(--gj-border-light);
}

/* Body text: explicit normal weight so it never inherits heading styles */
.job-detail-description-content p {
    font-weight: 400;
    margin-bottom: var(--gj-space-md);
}

/* In-content subheadings (from rich text): no border, smaller than page title */
.job-detail-description-content h2,
.job-detail-description-content h3 {
    margin-top: var(--gj-space-lg);
    margin-bottom: var(--gj-space-sm);
    padding-bottom: 0;
    border-bottom: none;
}

.job-detail-description-content h2 {
    font-size: var(--gj-text-2xl);
    font-weight: 700;
}

.job-detail-description-content h3 {
    font-size: var(--gj-text-lg);
    font-weight: 600;
}

.job-detail-description-content h2:first-child,
.job-detail-description-content h3:first-child,
.job-detail-description-content h2+h3 {
    margin-top: 0;
}

.job-detail-description-content ul,
.job-detail-description-content ol {
    padding-left: var(--gj-space-lg);
    margin-bottom: var(--gj-space-md);
}

.job-detail-description-content li {
    margin-bottom: var(--gj-space-xs);
}

.job-detail-description-content a {
    color: var(--gj-brand);
    text-decoration: underline;
}


/* ==================== APPLY SECTION ==================== */

.job-detail-apply {
    display: flex;
    align-items: center;
    gap: var(--gj-space-md);
    padding: var(--gj-space-lg);
    background: var(--gj-gray-50);
    border-radius: var(--gj-radius-lg);
    border: 1px solid var(--gj-border-light);
}

.job-detail-email-display {
    font-size: var(--gj-text-base);
    font-weight: 600;
    color: var(--gj-brand);
    word-break: break-all;
}


/* ==================== SIMILAR JOBS ==================== */

.similar-jobs {
    margin-top: var(--gj-space-3xl);
    padding: var(--gj-space-2xl) 0;
    border-top: 2px solid var(--gj-border);
}

.similar-jobs-title {
    font-size: var(--gj-text-xl);
    font-weight: 700;
    text-align: center;
    color: var(--gj-text-primary);
    margin-bottom: var(--gj-space-lg);
}

.job-list--similar {
    padding-bottom: 0;
}


/* ==================== RESPONSIVE ==================== */

@media (min-width: 768px) {
    .job-detail-logo {
        width: 80px;
        height: 80px;
    }
}

@media (max-width: 639px) {
    .job-detail-header {
        flex-direction: column;
    }

    .job-detail-header-right {
        flex-direction: row;
        align-items: center;
    }

    .job-detail-title {
        font-size: var(--gj-text-xl);
    }

    .job-detail-apply {
        flex-direction: column;
        text-align: center;
    }
}