/* Basic Styles for SantaFe Careers */
.sf-careers-container {
    padding: 20px 0;
    max-width: 1280px;
    margin: 0 auto;
}

/* Filter Bar Layout */
.sf-filter-bar {
    display: flex;
    justify-content: flex-start;
    gap: 20px;
    margin-bottom: 30px;
    align-items: center;
    flex-wrap: wrap;
}

.sf-filter-item {
    flex: 1;
    min-width: 250px;
}

.sf-filter-action {
    flex: 0 0 auto;
}

.sf-select {
    width: 100%;
    padding: 12px 15px;
    border: 1px solid #ccc;
    background: #fff;
    font-size: 16px;
    color: #333;
    -webkit-appearance: none;
    -moz-appearance: none;
    appearance: none;
    background-image: url("data:image/svg+xml;charset=UTF-8,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='currentColor' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3e%3cpolyline points='6 9 12 15 18 9'%3e%3c/polyline%3e%3c/svg%3e");
    background-repeat: no-repeat;
    background-position: right 1rem center;
    background-size: 1em;
}

/* Buttons */
.sf-btn {
    padding: 12px 25px;
    font-weight: bold;
    font-size: 16px;
    border: none;
    cursor: pointer;
    transition: all 0.3s ease;
    text-transform: none;
    /* Reset if theme enforces uppercase */
}

.sf-btn-red {
    background-color: #ff0000;
    color: #fff;
    min-width: 150px;
}

.sf-btn-red:hover {
    background-color: #cc0000;
}

.sf-btn-outline {
    background-color: transparent;
    border: 2px solid #105caa;
    color: #105caa;
    padding: 10px 20px;
    min-width: 120px;
}

.sf-btn-outline:hover {
    background-color: #105caa;
    color: #fff;
}

.sf-btn-submit {
    /* Specific to submit button matches design */
    width: 100%;
    max-width: 200px;
    margin-top: 20px;
}

/* Job List */
#sf-careers-app .sf-careers-list,
.sf-careers-list {
    display: flex;
    flex-direction: column;
    gap: 20px;
    width: 100%;
}

/* Job Card */
#sf-careers-app .sf-job-card,
.sf-job-card {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    padding: 30px;
    background-color: #f3f8fa !important;
    border: 1px solid #e1e8ed;
    border-radius: 4px;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.05);
    gap: 20px;
    position: relative;
    box-sizing: border-box;
    width: 100%;
    margin-bottom: 0;
    /* Reset margins */
}

#sf-careers-app .sf-job-content,
.sf-job-content {
    flex: 1;
}

#sf-careers-app .sf-job-title,
.sf-job-title {
    font-size: 24px;
    font-weight: bold;
    color: #333;
    margin: 0 0 10px 0;
    line-height: 1.2;
}

#sf-careers-app .sf-job-location,
.sf-job-location {
    font-size: 16px;
    color: #555;
    margin: 0 0 15px 0;
}

#sf-careers-app .sf-job-excerpt,
.sf-job-excerpt {
    font-size: 16px;
    line-height: 1.6;
    color: #333;
    margin-bottom: 20px;
}

#sf-careers-app .sf-job-excerpt p,
.sf-job-excerpt p {
    margin: 0 0 10px;
}

#sf-careers-app .sf-job-excerpt p:last-child,
.sf-job-excerpt p:last-child {
    margin-bottom: 0;
}

#sf-careers-app .sf-job-posted,
.sf-job-posted {
    font-size: 14px;
    color: #000;
    margin: 0;
}

#sf-careers-app .sf-job-action,
.sf-job-action {
    flex-shrink: 0;
    padding-top: 0;
}

/* Specificity for Filter Bar */
#sf-careers-app .sf-filter-item,
.sf-filter-item {
    flex: 1;
    min-width: 250px;
    max-width: 48%;
    /* Prevent stretching too wide with only 2 items */
}

/* Modal */
.sf-modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.6);
    z-index: 9999;
    /* Ensure high z-index */
    overflow: auto;
    display: flex;
    justify-content: center;
    align-items: center;
}

.sf-modal-content {
    background: #fff;
    padding: 40px;
    max-width: 800px;
    /* Matched to design roughly */
    width: 90%;
    max-height: 90vh;
    overflow-y: auto;
    position: relative;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.3);
}

.sf-close-btn {
    position: absolute;
    top: 15px;
    right: 20px;
    font-size: 30px;
    line-height: 1;
    border: none;
    background: none;
    cursor: pointer;
    color: #333;
}

/* Application Form Styling */
.sf-form-header {
    text-align: center;
    margin-bottom: 30px;
}

.sf-form-header h2 {
    font-size: 18px;
    margin: 0 0 10px;
    color: #333;
    font-weight: normal;
}

.sf-form-header h3 {
    font-size: 28px;
    margin: 0;
    color: #333;
    font-weight: bold;
}

.sf-form-intro {
    font-size: 14px;
    color: #666;
    margin-bottom: 30px;
    line-height: 1.6;
}

.sf-form-row.two-col {
    display: flex;
    gap: 20px;
}

.sf-form-row.two-col .sf-form-group {
    flex: 1;
}

.sf-form-group {
    margin-bottom: 20px;
}

.sf-form-group label {
    display: block;
    margin-bottom: 8px;
    font-weight: bold;
    color: #333;
    font-size: 14px;
}

.sf-form-group input[type="text"],
.sf-form-group input[type="email"] {
    width: 100%;
    padding: 12px 15px;
    border: 1px solid #ddd;
    border-radius: 4px;
    font-size: 14px;
    box-sizing: border-box;
    /* IMPORTANT */
}

/* File Input Hack to match look slightly better */
.sf-form-group input[type="file"] {
    width: 100%;
    padding: 10px;
    border: 1px solid #ddd;
    /* Box look for file input container */
    background: #fff;
    border-radius: 4px;
}

.sf-hint {
    font-weight: normal;
    color: #999;
    font-size: 12px;
    margin-left: 5px;
}

.required {
    color: red;
}

/* Responsive Form */
@media (max-width: 600px) {
    .sf-form-row.two-col {
        flex-direction: column;
        gap: 0;
    }
}

/* Spinner */
.spinner {
    width: 40px;
    height: 40px;
    border: 4px solid #f3f3f3;
    border-top: 4px solid #105caa;
    /* Blue spinner */
    border-radius: 50%;
    animation: spin 1s linear infinite;
    margin: 20px auto;
}

@keyframes spin {
    0% {
        transform: rotate(0deg);
    }

    100% {
        transform: rotate(360deg);
    }
}