@import url('../variables.css');

/* Career/Apply Page Styles - Mobile First Approach */

/* Global Styles */
body {
    margin: 0;
    padding: 0;
    scrollbar-width: none;
    -ms-overflow-style: none;
    display: flex;
    flex-direction: column;
    min-height: 100vh;
    font-family: 'Roboto', sans-serif;
    color: var(--text-color);
    background-color: #f8f9fa;
    overflow-x: hidden;
    width: 100%;
    max-width: 100%;
}

*::-webkit-scrollbar {
    display: none;
}

html {
    scroll-behavior: smooth;
}

html, body {
    height: 100%;
    margin: 0;
}

/* Apply box-sizing globally */
*, *::before, *::after {
    box-sizing: border-box;
}

/* Main content wrapper */
main {
    flex: 1 0 auto; /* Allow this to grow and push footer down */
}

/* Container */
.container-fluid {
    width: 100%;
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 15px;
}

/* Button styles */
.btn {
    display: inline-block;
    padding: 0.75rem 1.5rem;
    font-size: 0.9375rem;
    font-weight: 500;
    text-align: center;
    border-radius: 0.25rem;
    transition: all 0.3s ease;
    cursor: pointer;
    text-decoration: none;
    border: 1px solid transparent;
}

.btn-primary {
    background-color: var(--secondary-color);
    color: #fff;
    border-color: var(--secondary-color);
}

.btn-primary:hover {
    background-color: #b38a4b;
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
}

.btn-outline {
    background-color: transparent;
    border-color: var(--border-color);
    color: var(--text-color);
}

.btn-outline:hover {
    border-color: var(--secondary-color);
    color: var(--secondary-color);
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.05);
}

/* Section styles */
section {
    padding: 40px 0;
}

.section-title {
    text-align: center;
    font-size: 1.75rem;
    color: var(--primary-color);
    margin-bottom: 30px;
    font-weight: 600;
}

/* Hero Section */
.careers-hero {
    background: linear-gradient(to right, rgba(45, 46, 46, 0.9), rgba(45, 46, 46, 0.8)), url('https://source.unsplash.com/random/1200x800/?office,team') no-repeat center center;
    background-size: cover;
    color: #fff;
    padding: 60px 0;
    text-align: center;
}

.hero-content {
    max-width: 700px;
    margin: 0 auto;
}

.careers-hero h1 {
    font-size: 2.2rem;
    margin-bottom: 15px;
    font-weight: 700;
}

.careers-hero p {
    font-size: 1.1rem;
    margin-bottom: 30px;
    opacity: 0.9;
}

/* Why Join Us Section */
.why-join-us {
    background-color: #fff;
    padding: 50px 0;
}

.benefits-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 20px;
}

.benefit-card {
    background-color: var(--light-bg);
    border-radius: 8px;
    padding: 25px;
    text-align: center;
    transition: all 0.3s ease;
    border: 1px solid var(--border-color);
}

.benefit-card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow);
}

.benefit-icon {
    width: 60px;
    height: 60px;
    background-color: var(--secondary-color);
    color: #fff;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 15px;
    font-size: 1.5rem;
}

.benefit-card h3 {
    font-size: 1.25rem;
    margin-bottom: 10px;
    color: var(--primary-color);
}

.benefit-card p {
    color: #666;
    margin: 0;
    font-size: 0.9rem;
    line-height: 1.5;
}

/* Open Positions Section */
.open-positions {
    background-color: var(--light-bg);
    padding: 50px 0 60px;
}

.positions-filter {
    background-color: #fff;
    padding: 20px;
    border-radius: 10px;
    box-shadow: var(--shadow);
    border: 1px solid var(--border-color);
    margin-bottom: 24px;
    width: 100%;
}

.positions-filter form {
    display: flex;
    flex-direction: column;
    gap: 15px;
    width: 100%;
}

.open-positions .filter-group {
    flex: 1;
    min-width: 0;
    width: 100%;
}

.filter-group label {
    display: block;
    margin-bottom: 8px;
    font-size: 0.9rem;
    color: #666;
    font-weight: 500;
}

.form-select {
    width: 100%;
    min-width: 0;
    padding: 12px 15px;
    border-radius: 4px;
    border: 1px solid var(--border-color);
    background-color: #fff;
    font-size: 0.95rem;
    color: var(--text-color);
    appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='%23666'%3E%3Cpath d='M7 10l5 5 5-5z'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 15px center;
    background-size: 15px;
}

.positions-list {
    display: flex;
    flex-direction: column;
    gap: 20px;
    width: 100%;
    margin: 0 auto;
}

.positions-list.has-jobs {
    display: grid;
    grid-template-columns: 1fr;
}

.open-positions .no-results {
    width: 100%;
    background-color: #fff;
    border-radius: 8px;
    box-shadow: var(--shadow);
    border: 1px solid var(--border-color);
}

.job-card {
    background-color: #fff;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: var(--shadow);
    transition: all 0.3s ease;
    border: 1px solid var(--border-color);
}

.job-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.1);
}

.job-header {
    padding: 20px;
    border-bottom: 1px solid var(--border-color);
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.job-title {
    font-size: 1.25rem;
    margin: 0;
    color: var(--primary-color);
}

.job-badge {
    display: inline-block;
    padding: 4px 10px;
    border-radius: 20px;
    font-size: 0.75rem;
    font-weight: 500;
    margin-right: 5px;
}

.job-badge.full-time {
    background-color: #e3f2fd;
    color: #1976d2;
}

.job-badge.part-time {
    background-color: #e8f5e9;
    color: #388e3c;
}

.job-badge.contract {
    background-color: #fff3e0;
    color: #f57c00;
}

.job-details {
    padding: 20px;
}

.job-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 15px;
    margin-bottom: 15px;
    font-size: 0.85rem;
    color: #666;
}

.job-meta span {
    display: flex;
    align-items: center;
}

.job-meta i {
    margin-right: 5px;
    color: var(--secondary-color);
}

.job-description {
    margin-bottom: 15px;
    font-size: 0.95rem;
    line-height: 1.5;
    color: var(--text-color);
}

.job-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.tag {
    display: inline-block;
    padding: 5px 10px;
    background-color: var(--light-bg);
    border-radius: 4px;
    font-size: 0.75rem;
    color: #666;
}

.job-footer {
    padding: 15px 20px;
    border-top: 1px solid var(--border-color);
    display: flex;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 10px;
}

.no-results {
    text-align: center;
    padding: 50px 20px;
    width: 100%;
}

.no-results-content {
    max-width: 400px;
    margin: 0 auto;
}

.no-results i {
    font-size: 3rem;
    color: #ccc;
    margin-bottom: 15px;
}

.no-results h3 {
    font-size: 1.5rem;
    margin-bottom: 10px;
    color: var(--primary-color);
}

.no-results p {
    color: #666;
}

/* Application Process Section */
.application-process {
    background-color: #fff;
    padding: 60px 0;
}

.process-steps {
    max-width: 800px;
    margin: 0 auto;
}

.process-step {
    display: flex;
    align-items: flex-start;
    margin-bottom: 30px;
    position: relative;
}

.process-step:last-child {
    margin-bottom: 0;
}

.process-step::after {
    content: '';
    position: absolute;
    top: 50px;
    left: 25px;
    height: calc(100% - 20px);
    width: 2px;
    background-color: var(--border-color);
    z-index: 1;
}

.process-step:last-child::after {
    display: none;
}

.step-number {
    width: 50px;
    height: 50px;
    background-color: var(--secondary-color);
    color: #fff;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.25rem;
    font-weight: 600;
    margin-right: 20px;
    flex-shrink: 0;
    position: relative;
    z-index: 2;
}

.step-content {
    flex: 1;
    padding-top: 5px;
}

.step-content h3 {
    font-size: 1.2rem;
    margin: 0 0 8px 0;
    color: var(--primary-color);
}

.step-content p {
    margin: 0;
    color: #666;
    font-size: 0.95rem;
}

/* FAQ Section */
.faq-section {
    background-color: var(--light-bg);
    padding: 60px 0;
}

.faq-container {
    max-width: 800px;
    margin: 0 auto;
}

.faq-item {
    background-color: #fff;
    border-radius: 8px;
    overflow: hidden;
    margin-bottom: 15px;
    box-shadow: var(--shadow);
    border: 1px solid var(--border-color);
}

.faq-question {
    padding: 18px 20px;
    cursor: pointer;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.faq-question h3 {
    font-size: 1.1rem;
    margin: 0;
    color: var(--primary-color);
    font-weight: 500;
}

.faq-toggle {
    color: var(--secondary-color);
    transition: transform 0.3s ease;
}

.faq-item.active .faq-toggle {
    transform: rotate(45deg);
}

.faq-answer {
    padding: 0 20px;
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.3s ease, padding 0.3s ease;
}

.faq-item.active .faq-answer {
    padding: 0 20px 20px;
    max-height: 300px;
}

.faq-answer p {
    margin: 0;
    color: #666;
    font-size: 0.95rem;
    line-height: 1.6;
}

/* Media Queries */
@media (min-width: 576px) {
    .benefits-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .positions-filter form {
        flex-direction: row;
        gap: 20px;
    }
    
    .job-header {
        flex-direction: row;
        justify-content: space-between;
        align-items: center;
    }
    
    .job-footer .btn {
        flex-basis: auto;
        padding: 0.75rem 1.5rem;
        font-size: 0.9375rem;
    }
}

@media (min-width: 768px) {
    .section-title {
        font-size: 2rem;
        margin-bottom: 40px;
    }
    
    .careers-hero {
        padding: 80px 0;
    }
    
    .careers-hero h1 {
        font-size: 2.5rem;
    }
    
    .careers-hero p {
        font-size: 1.2rem;
    }
    
    .positions-list.has-jobs {
        grid-template-columns: repeat(2, 1fr);
        gap: 25px;
    }
    
    .job-title {
        font-size: 1.4rem;
    }
    
    .job-description {
        font-size: 1rem;
    }
    
    .faq-question h3 {
        font-size: 1.2rem;
    }
    
    .step-content h3 {
        font-size: 1.3rem;
    }
}

@media (min-width: 992px) {
    .benefits-grid {
        grid-template-columns: repeat(4, 1fr);
        gap: 30px;
    }
    
    .positions-list.has-jobs {
        grid-template-columns: repeat(3, 1fr);
    }
    
    .careers-hero {
        padding: 100px 0;
    }
    
    .careers-hero h1 {
        font-size: 3rem;
    }
    
    .process-step {
        margin-bottom: 40px;
    }
    
    .step-number {
        width: 60px;
        height: 60px;
        font-size: 1.5rem;
    }
    
    .process-step::after {
        top: 60px;
        left: 30px;
    }
    
    .mobile-nav-container {
        display: none;
    }
}

@media (min-width: 1200px) {
    .section-title {
        font-size: 2.25rem;
    }
    
    .job-footer {
        padding: 20px 25px;
    }
    
    .faq-question {
        padding: 22px 25px;
    }
    
    .faq-item.active .faq-answer {
        padding: 0 25px 25px;
    }
    
    .job-title {
        font-size: 1.5rem;
    }
    
    .step-content h3 {
        font-size: 1.4rem;
    }
}

@media (max-width: 576px) {
    section {
        padding: 30px 0;
    }
    
    .job-card {
        border-radius: 6px;
    }
    
    .job-header, .job-details {
        padding: 15px;
    }
    
    .job-footer {
        padding: 12px 15px;
    }
    
    .job-title {
        font-size: 1.2rem;
        width: 100%;
        margin-bottom: 5px;
    }
    
    .job-header {
        gap: 8px;
    }
    
    .hero-content {
        width: 100%;
        padding: 0 10px;
    }
    
    .btn {
        white-space: normal;
        word-break: break-word;
    }
    
    .job-footer .btn {
        flex-basis: calc(50% - 5px);
        text-align: center;
        padding: 10px;
        font-size: 0.9rem;
    }
}

@media (max-width: 380px) {
    .job-footer {
        flex-direction: column;
    }
    
    .job-footer .btn {
        flex-basis: 100%;
        margin-bottom: 8px;
    }
    
    .job-footer .btn:last-child {
        margin-bottom: 0;
    }
}

/* Mobile nav fix - simplified and matches team page structure */
@media (max-width: 991px) {
    body {
        padding-bottom: 62px !important;
    }
}

.mobile-nav-container {
    height: 62px;
    position: fixed;
    bottom: 0;
    left: 0;
    width: 100%;
    z-index: 1000;
}