/* =============================================
   careers.css — Layout improved, original colors preserved
   ============================================= */

/* ── HERO ─────────────────────────────────── */
.hero-careers {
    background: linear-gradient(135deg, #0f1124 0%, #1a1f3d 100%);
    min-height: 100vh;
    position: relative;
    overflow: hidden;
    display: flex;
    align-items: center;
}

.hero-careers .container {
    position: relative;
    z-index: 2;
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    padding-top: 120px;
    padding-bottom: 140px;
}

.hero-orb-4 {
    width: 420px;
    height: 420px;
    background: radial-gradient(circle, rgba(139, 92, 246, 0.25) 0%, transparent 70%);
    bottom: -80px;
    left: 15%;
    animation: orbFloat4 19s ease-in-out infinite;
    filter: blur(45px);
}

@keyframes orbFloat4 {
    0%, 100% { transform: translate(30px, 20px) scale(1); }
    50% { transform: translate(-40px, -50px) scale(1.15); }
}


.stats-bar {
    background: rgba(15, 17, 36, 0.95);
    padding: 0;
    border-bottom: 1px solid rgba(139, 92, 246, 0.2);
}

.stats-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    text-align: center;
}

.stat-item {
    padding: 40px 20px;
    position: relative;
}

.stat-item:not(:last-child)::after {
    content: '';
    position: absolute;
    right: 0; top: 25%; bottom: 25%;
    width: 1px;
    background: rgba(139, 92, 246, 0.15);
}

.stat-number {
    font-size: 2.8rem;
    font-weight: 800;
    background: linear-gradient(90deg, #8b5cf6, #a78bfa);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    line-height: 1;
    margin-bottom: 8px;
}

.stat-label {
    color: #94a3b8;
    font-size: 0.9rem;
    text-transform: uppercase;
    letter-spacing: 1px;
}


.positions-section {
    padding: 100px 0;
}

.tabs {
    display: flex;
    justify-content: center;
    gap: 12px;
    margin: 36px 0 48px;
    flex-wrap: wrap;
}

.tab-btn {
    padding: 12px 32px;
    background: rgba(139, 92, 246, 0.1);
    border: 1px solid rgba(139, 92, 246, 0.3);
    color: #c4b5fd;
    border-radius: 50px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
}

.tab-btn:hover {
    background: rgba(139, 92, 246, 0.2);
}

.tab-btn.active {
    color: white;
    background: #8b5cf6;
    box-shadow: 0 10px 25px rgba(139, 92, 246, 0.3);
}

.tab-btn::after {
    content: none !important;
}


.positions-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(340px, 1fr));
    gap: 24px;
    margin-top: 50px;
    align-items: start;
}

.position-card {
    background: linear-gradient(145deg, #161b2e, #0f1324);
    border-radius: 20px;
    padding: 32px;
    border: 1px solid rgba(139, 92, 246, 0.15);
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1), opacity 0.25s ease;
    position: relative;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    box-sizing: border-box;
}

.position-card.hidden-by-filter {
    opacity: 0;
    pointer-events: none;
    transform: translateY(8px) scale(0.98);
}

.position-card::before {
    content: '';
    position: absolute;
    top: 0; left: -100%;
    width: 40%; height: 100%;
    background: linear-gradient(90deg, transparent, rgba(167, 139, 250, 0.15), transparent);
    transition: 0.7s;
}
.position-card:hover::before { left: 200%; }

.position-card:hover {
    transform: translateY(-8px);
    border-color: #8b5cf6;
    box-shadow: 0 25px 50px -12px rgb(139 92 246 / 0.25);
}

.position-card.closed {
    opacity: 0.55;
}
.position-card.closed:hover {
    opacity: 0.75;
    transform: none;
    box-shadow: none;
}

.position-header {
    display: flex;
    align-items: flex-start;
    gap: 18px;
    margin-bottom: 20px;
    flex-shrink: 0;
}

.position-icon {
    width: 52px; height: 52px;
    background: rgba(139, 92, 246, 0.12);
    border-radius: 14px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.6rem;
    color: #c4b5fd;
    flex-shrink: 0;
}

.position-header > div > h3 {
    font-size: 1.1rem;
    font-weight: 700;
    color: #e2e8f0;
    margin-bottom: 6px;
    line-height: 1.2;
}

.status-badge {
    display: inline-block;
    padding: 4px 14px;
    border-radius: 9999px;
    font-size: 0.75rem;
    font-weight: 700;
    letter-spacing: 0.5px;
}

.status-badge.open {
    background: #22c55e;
    color: #052e16;
}

.status-badge.closed {
    background: #64748b;
    color: white;
}

.pricing-tag {
    display: inline-block;
    background: rgba(148, 163, 184, 0.1);
    color: #94a3b8;
    font-size: 0.8rem;
    font-weight: 500;
    padding: 4px 12px;
    border-radius: 9999px;
    margin: 4px 0 6px 0;
    border: 1px solid rgba(148, 163, 184, 0.2);
    letter-spacing: 0.2px;
}

.position-body {
    flex: 1;
    display: flex;
    flex-direction: column;
}

.position-body > p {
    font-size: 0.9rem;
    color: #64748b;
    line-height: 1.65;
}

.position-body .apply-btn {
    margin-top: auto;
    align-self: flex-start;
    width: auto;
}


.card-tabs {
    display: flex;
    gap: 8px;
    margin: 20px 0 18px;
    border-bottom: 1px solid rgba(139, 92, 246, 0.2);
}

.card-tab-btn {
    padding: 8px 20px;
    background: transparent;
    border: none;
    color: #94a3b8;
    font-weight: 600;
    cursor: pointer;
    border-radius: 8px 8px 0 0;
    transition: all 0.3s ease;
}

.card-tab-btn.active {
    background: rgba(139, 92, 246, 0.15);
    color: #c4b5fd;
    border-bottom: 3px solid #8b5cf6;
}

.card-content {
    display: block;
    margin-bottom: 20px;
    opacity: 0;
    transform: translateY(6px);
    pointer-events: none;
    max-height: 0;
    overflow: hidden;
    transition: opacity 0.22s ease, transform 0.22s ease, max-height 0.25s ease;
}
.card-content.active {
    opacity: 1;
    transform: translateY(0);
    pointer-events: auto;
    max-height: 500px;
    overflow: visible;
}


.benefits ul,
.requirements ul {
    list-style: none;
    padding: 0;
    margin: 0;
}

.benefits h4,
.requirements h4 {
    color: #c4b5fd;
    margin: 16px 0 10px;
    font-size: 1.05rem;
}

.list-scroll-container {
    max-height: 260px;
    overflow: hidden;
    position: relative;
}

.benefits li,
.requirements li {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    padding: 6px 0;
    color: #cbd5e1;
    font-size: 0.88rem;
    line-height: 1.5;
    border-bottom: 1px solid rgba(139, 92, 246, 0.06);
}

.benefits li:last-child,
.requirements li:last-child {
    border-bottom: none;
}

.benefits li i,
.requirements li i {
    color: #8b5cf6;
    font-size: 0.7rem;
    margin-top: 4px;
    flex-shrink: 0;
}

.list-nav {
    display: flex;
    justify-content: center;
    gap: 12px;
    margin-top: 12px;
}

.list-nav button {
    background: rgba(139, 92, 246, 0.1);
    border: 1px solid rgba(139, 92, 246, 0.4);
    color: #c4b5fd;
    width: 38px; height: 38px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    font-size: 16px;
    transition: all 0.3s ease;
}

.list-nav button:hover {
    background: #8b5cf6;
    color: white;
    transform: scale(1.08);
}

.list-nav button:disabled {
    opacity: 0.3;
    cursor: not-allowed;
}


.values-section {
    padding: 100px 0;
    border-top: 1px solid rgba(139, 92, 246, 0.12);
}

.values-section .section-header {
    margin-bottom: 60px;
}

.values-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 24px;
}

.value-card {
    background: linear-gradient(145deg, #161b2e, #0f1324);
    border: 1px solid rgba(139, 92, 246, 0.12);
    border-radius: 20px;
    text-align: center;
    padding: 44px 32px;
    transition: transform 0.3s ease, box-shadow 0.3s ease, border-color 0.3s ease;
}

.value-card:hover {
    transform: translateY(-6px);
    border-color: rgba(139, 92, 246, 0.35);
    box-shadow: 0 20px 40px rgba(139, 92, 246, 0.12);
}

.value-card i {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 64px; height: 64px;
    border-radius: 16px;
    background: rgba(139, 92, 246, 0.1);
    border: 1px solid rgba(139, 92, 246, 0.2);
    font-size: 1.7rem;
    color: #a78bfa;
    margin: 0 auto 24px;
    transition: background 0.3s;
}

.value-card:hover i {
    background: rgba(139, 92, 246, 0.18);
}

.value-card h3 {
    font-size: 1.15rem;
    font-weight: 700;
    color: #e2e8f0;
    margin-bottom: 10px;
}

.value-card p {
    font-size: 0.88rem;
    color: #64748b;
    line-height: 1.65;
}


.form-container {
    max-width: 680px;
    margin: 0 auto;
    background: #161b2e;
    padding: 48px 42px;
    border-radius: 24px;
    border: 1px solid rgba(139, 92, 246, 0.2);
}

.form-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
}

.form-group { margin-bottom: 22px; }

.form-group label {
    display: block;
    margin-bottom: 8px;
    color: #94a3b8;
    font-weight: 500;
}

.form-group input,
.form-group textarea {
    width: 100%;
    padding: 14px 18px;
    background: #0f1324;
    border: 1px solid rgba(139, 92, 246, 0.3);
    border-radius: 12px;
    color: white;
    font-size: 1rem;
}

.form-group input:focus,
.form-group textarea:focus {
    outline: none;
    border-color: #8b5cf6;
    box-shadow: 0 0 0 3px rgba(139, 92, 246, 0.2);
}

.nav-links a::after {
    content: none !important;
}

    .apply-modal-overlay {
      display: none; position: fixed; inset: 0;
      background: rgba(0,0,0,.75); z-index: 2000;
      align-items: center; justify-content: center; padding: 16px;
    }
    .apply-modal-overlay.active { display: flex; }
    .apply-modal {
      background: #161b2e;
      border: 1px solid rgba(139,92,246,.25);
      border-radius: 20px;
      width: 100%; max-width: 580px;
      max-height: 90vh; overflow-y: auto;
      padding: 36px 40px;
      position: relative;
    }
    .apply-modal-close {
      position: absolute; top: 16px; right: 18px;
      background: none; border: none; color: #64748b;
      font-size: 1.1rem; cursor: pointer; padding: 6px;
      border-radius: 6px; transition: color .15s;
    }
    .apply-modal-close:hover { color: #e2e8f0; }
    .apply-modal h3 { font-size: 1.3rem; font-weight: 700; color: #e2e8f0; margin-bottom: 4px; }
    .apply-modal .modal-sub { font-size: .88rem; color: #64748b; margin-bottom: 28px; }
    .apply-modal .form-group { margin-bottom: 20px; }
    .apply-modal .form-group label { display: block; margin-bottom: 8px; color: #94a3b8; font-weight: 500; font-size: .9rem; }
    .apply-modal .form-group label span { color: #ed4245; margin-left: 2px; }
    .apply-modal .form-group textarea,
    .apply-modal .form-group input {
      width: 100%; padding: 14px 18px;
      background: #0f1324;
      border: 1px solid rgba(139,92,246,.3);
      border-radius: 12px; color: #e2e8f0;
      font-size: .93rem; font-family: inherit;
      resize: vertical; transition: border-color .2s, box-shadow .2s;
    }
    .apply-modal .form-group textarea:focus,
    .apply-modal .form-group input:focus {
      outline: none; border-color: #8b5cf6;
      box-shadow: 0 0 0 3px rgba(139,92,246,.18);
    }
    .apply-modal .form-group textarea { min-height: 110px; }
    .char-hint { font-size: .72rem; color: #64748b; text-align: right; margin-top: 4px; }
    .char-hint.warn { color: #f59e0b; }
    .modal-error-box {
      background: rgba(237,66,69,.1); border: 1px solid rgba(237,66,69,.28);
      color: #ed4245; border-radius: 10px; padding: 11px 15px;
      font-size: .85rem; margin-bottom: 18px; display: none;
    }
    .modal-success-box { text-align: center; padding: 24px 0; }
    .modal-success-box i { font-size: 3rem; color: #43b581; margin-bottom: 16px; display: block; }
    .modal-success-box h4 { font-size: 1.15rem; font-weight: 700; margin-bottom: 8px; color: #e2e8f0; }
    .modal-success-box p { font-size: .88rem; color: #64748b; line-height: 1.65; }
    .modal-submit-btn {
      width: 100%; padding: 14px;
      background: #8b5cf6; color: #fff;
      border: none; border-radius: 12px;
      font-size: .95rem; font-weight: 700;
      cursor: pointer; transition: background .2s;
    }
    .modal-submit-btn:hover { background: #7c3aed; }
    .modal-submit-btn:disabled { opacity: .5; cursor: not-allowed; }

    /* Login notice */
    .login-notice {
      background: rgba(139,92,246,.08);
      border: 1px solid rgba(139,92,246,.2);
      border-radius: 12px; padding: 16px 22px;
      display: flex; align-items: center; gap: 12px;
      margin-bottom: 32px; font-size: .9rem; color: #94a3b8;
    }
    .login-notice i { color: #8b5cf6; }
    .login-notice a { color: #c4b5fd; font-weight: 600; text-decoration: none; }
    .login-notice a:hover { text-decoration: underline; }
    .login-notice--success {
      background: rgba(59,165,93,0.08);
      border-color: rgba(59,165,93,0.25);
    }
    .login-notice--success i { color: #3ba55d; }
    .login-notice--warn {
      background: rgba(237,66,69,0.08);
      border-color: rgba(237,66,69,0.2);
    }
    .login-notice--warn i { color: #ed4245; }

    /* apply-btn inside cards */
    .apply-btn {
      display: inline-flex; align-items: center; gap: 8px;
      background: #8b5cf6; color: #fff;
      padding: 11px 24px; border-radius: 50px;
      border: none; cursor: pointer;
      font-size: .85rem; font-weight: 600;
      transition: background .2s, box-shadow .2s;
      text-decoration: none; margin-top: auto;
    }
    .apply-btn:hover {
      background: #7c3aed;
      box-shadow: 0 8px 20px rgba(139,92,246,.3);
    }
    .apply-btn.disabled {
      background: #334155; color: #64748b; cursor: not-allowed; box-shadow: none;
    }

    /* hero eyebrow */
    .eyebrow-text {
      display: inline-block;
      background: rgba(139,92,246,.12);
      border: 1px solid rgba(139,92,246,.3);
      color: #c4b5fd; font-size: .78rem; font-weight: 700;
      letter-spacing: .08em; text-transform: uppercase;
      padding: 5px 16px; border-radius: 20px; margin-bottom: 22px;
    }
    .hero-careers h1 { font-size: clamp(2rem,5vw,3.4rem); font-weight: 800; color: #e2e8f0; line-height: 1.15; margin-bottom: 18px; }
    .hero-careers h1 span { color: #a78bfa; }
    .hero-careers p { font-size: 1.1rem; color: #64748b; max-width: 520px; margin: 0 auto 32px; line-height: 1.75; }
    .hero-careers .hero-cta { display: flex; gap: 14px; justify-content: center; flex-wrap: wrap; }


@media (max-width: 900px) {
    .values-grid {
        grid-template-columns: 1fr;
        max-width: 480px;
        margin: 0 auto;
    }
}

@media (max-width: 768px) {
    .stats-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .stat-item:nth-child(2)::after { display: none; }

    .stat-item:nth-child(1),
    .stat-item:nth-child(2) {
        border-bottom: 1px solid rgba(139, 92, 246, 0.12);
    }

    .positions-grid {
        grid-template-columns: 1fr;
    }

    .form-grid {
        grid-template-columns: 1fr;
    }

    .form-container {
        padding: 32px 24px;
    }
}

@media (max-width: 480px) {
    .stat-number { font-size: 2.2rem; }
}

/* ── Apply Modal (am-*) ──────────────────────────────────────────────────── */
.am-overlay {
    position: fixed; inset: 0;
    background: rgba(5,6,15,0.82);
    backdrop-filter: blur(6px);
    -webkit-backdrop-filter: blur(6px);
    z-index: 1000;
    display: flex; align-items: center; justify-content: center;
    padding: 20px;
    opacity: 0; pointer-events: none;
    transition: opacity 0.25s ease;
}
.am-overlay.active { opacity: 1; pointer-events: all; }

.am-modal {
    background: #12131f;
    border: 1px solid rgba(88,101,242,0.18);
    border-radius: 20px;
    width: 100%; max-width: 660px;
    max-height: 90vh;
    display: flex; flex-direction: column;
    box-shadow: 0 32px 80px rgba(0,0,0,0.6), 0 0 0 1px rgba(88,101,242,0.06);
    transform: translateY(20px) scale(0.97);
    transition: transform 0.28s cubic-bezier(0.34,1.4,0.64,1), opacity 0.28s ease;
    overflow: hidden;
}
.am-overlay.active .am-modal { transform: translateY(0) scale(1); }

.am-header {
    display: flex; align-items: center; gap: 14px;
    padding: 22px 24px 18px;
    border-bottom: 1px solid rgba(255,255,255,0.06);
    flex-shrink: 0;
}
.am-header__icon {
    width: 44px; height: 44px;
    background: linear-gradient(135deg, rgba(88,101,242,0.25), rgba(88,101,242,0.1));
    border: 1px solid rgba(88,101,242,0.3);
    border-radius: 12px;
    display: flex; align-items: center; justify-content: center;
    font-size: 1.05rem; color: #818cf8; flex-shrink: 0;
}
.am-header__eyebrow {
    display: block; font-size: 0.68rem; font-weight: 700;
    letter-spacing: 0.1em; text-transform: uppercase;
    color: #5865f2; margin-bottom: 3px;
}
.am-header__title { font-size: 1.05rem; font-weight: 700; color: #e0e2f0; margin: 0; }
.am-close {
    margin-left: auto;
    width: 34px; height: 34px;
    background: rgba(255,255,255,0.05); border: 1px solid rgba(255,255,255,0.07);
    border-radius: 9px; color: #72768a; cursor: pointer;
    display: flex; align-items: center; justify-content: center;
    font-size: 1.2rem; transition: background 0.15s, color 0.15s; flex-shrink: 0;
}
.am-close:hover { background: rgba(237,66,69,0.12); color: #ed4245; border-color: rgba(237,66,69,0.25); }

.am-error {
    margin: 0 24px; margin-top: 16px;
    padding: 11px 15px;
    background: rgba(237,66,69,0.1); border: 1px solid rgba(237,66,69,0.28);
    color: #ed4245; border-radius: 10px; font-size: 0.84rem;
    display: none; flex-shrink: 0;
}

.am-body {
    flex: 1; overflow-y: auto;
    padding: 20px 24px;
    display: flex; flex-direction: column; gap: 20px;
}
.am-body::-webkit-scrollbar { width: 4px; }
.am-body::-webkit-scrollbar-track { background: transparent; }
.am-body::-webkit-scrollbar-thumb { background: rgba(88,101,242,0.3); border-radius: 4px; }

.am-field__head { display: flex; align-items: center; justify-content: space-between; margin-bottom: 5px; }
.am-field__label { font-size: 0.82rem; font-weight: 700; color: #c8caf0; letter-spacing: 0.01em; }
.am-required { color: #5865f2; margin-left: 2px; }
.am-optional-tag {
    font-size: 0.7rem; font-weight: 600; color: #72768a;
    background: rgba(255,255,255,0.05); border: 1px solid rgba(255,255,255,0.07);
    padding: 2px 8px; border-radius: 6px;
}
.am-char-hint { font-size: 0.72rem; color: #72768a; font-weight: 500; transition: color 0.15s; }
.am-char-hint.warn { color: #f59e0b; }
.am-field__hint { font-size: 0.78rem; color: #52556a; line-height: 1.5; margin-bottom: 8px; }

.am-textarea {
    width: 100%;
    background: #0d0e1c; border: 1px solid rgba(88,101,242,0.14);
    border-radius: 12px; color: #c8caf0;
    padding: 13px 15px; font-size: 0.875rem; line-height: 1.65;
    resize: vertical; outline: none; font-family: inherit;
    transition: border-color 0.2s, box-shadow 0.2s;
    min-height: 110px;
}
.am-textarea:focus { border-color: rgba(88,101,242,0.45); box-shadow: 0 0 0 3px rgba(88,101,242,0.12); }
.am-textarea::placeholder { color: #3a3d52; }

.am-input {
    width: 100%;
    background: #0d0e1c; border: 1px solid rgba(88,101,242,0.14);
    border-radius: 10px; color: #c8caf0;
    padding: 11px 15px; font-size: 0.875rem; outline: none;
    transition: border-color 0.2s, box-shadow 0.2s; font-family: inherit;
}
.am-input:focus { border-color: rgba(88,101,242,0.45); box-shadow: 0 0 0 3px rgba(88,101,242,0.12); }
.am-input::placeholder { color: #3a3d52; }

.am-footer {
    padding: 16px 24px;
    border-top: 1px solid rgba(255,255,255,0.06);
    display: flex; align-items: center; justify-content: flex-end; gap: 10px;
    flex-shrink: 0; background: #0f1020;
}
.am-btn-cancel {
    padding: 9px 20px; border-radius: 9px; font-size: 0.85rem; font-weight: 600;
    background: transparent; color: #72768a;
    border: 1px solid rgba(255,255,255,0.09); cursor: pointer;
    transition: background 0.15s, color 0.15s; font-family: inherit;
}
.am-btn-cancel:hover { background: rgba(255,255,255,0.05); color: #c8caf0; }
.am-btn-submit {
    display: flex; align-items: center; gap: 7px;
    padding: 9px 22px; border-radius: 9px; font-size: 0.875rem; font-weight: 600;
    background: linear-gradient(135deg, #5865f2, #4752c4);
    color: #fff; border: none; cursor: pointer;
    box-shadow: 0 4px 16px rgba(88,101,242,0.35);
    transition: opacity 0.15s, box-shadow 0.15s, transform 0.15s; font-family: inherit;
}
.am-btn-submit:hover { opacity: 0.9; box-shadow: 0 6px 22px rgba(88,101,242,0.5); transform: translateY(-1px); }
.am-btn-submit:disabled { opacity: 0.55; cursor: not-allowed; transform: none; box-shadow: none; }

@keyframes am-spin { to { transform: rotate(360deg); } }
.am-btn-submit .bx-spin { animation: am-spin 0.75s linear infinite; }

.am-success {
    flex: 1; display: flex; flex-direction: column; align-items: center;
    justify-content: center; text-align: center; padding: 48px 32px;
}
.am-success__icon { font-size: 3.2rem; color: #43b581; margin-bottom: 16px; line-height: 1; }
.am-success h4    { font-size: 1.2rem; font-weight: 700; color: #e0e2f0; margin-bottom: 10px; }
.am-success p     { font-size: 0.875rem; color: #72768a; line-height: 1.7; }

@media (max-width: 480px) {
    .am-modal  { border-radius: 16px; }
    .am-header { padding: 16px 18px 14px; }
    .am-body   { padding: 16px 18px; }
    .am-footer { padding: 14px 18px; }
    .am-error  { margin: 12px 18px 0; }
}

/* BH-specific apply button state badges */
.apply-btn.disabled {
    cursor: default; pointer-events: none;
    display: inline-flex; align-items: center; gap: 6px;
}