/* ============================= */
/* ===== formular.css       ===== */
/* ===== Bewerbungs-Popup   ===== */
/* ============================= */

/* ===== POPUP OVERLAY ===== */
.bewerbung-popup-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.85);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    display: none;
    justify-content: center;
    align-items: center;
    z-index: 9999;
    animation: popupFadeIn 0.3s ease;
}

@keyframes popupFadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

/* ===== POPUP CONTAINER ===== */
.bewerbung-popup {
    width: 90%;
    max-width: 700px;
    max-height: 85vh;
    background: rgba(18, 22, 33, 0.95);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border: 1px solid rgba(145, 70, 255, 0.4);
    border-radius: 32px;
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.8), 0 0 0 1px rgba(145, 70, 255, 0.2);
    display: flex;
    flex-direction: column;
    overflow: hidden;
    animation: popupSlideIn 0.4s ease;
}

@keyframes popupSlideIn {
    from { opacity: 0; transform: translateY(30px); }
    to { opacity: 1; transform: translateY(0); }
}

/* ===== POPUP HEADER ===== */
.popup-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1.5rem 2rem;
    background: rgba(0, 0, 0, 0.3);
    border-bottom: 1px solid rgba(145, 70, 255, 0.3);
}

.popup-title {
    display: flex;
    align-items: center;
    gap: 12px;
}

.popup-title h2 {
    font-size: 1.6rem;
    font-weight: 700;
    color: #fff;
    margin: 0;
}

.popup-close {
    background: rgba(255, 255, 255, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.2);
    color: #fff;
    width: 36px;
    height: 36px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    cursor: pointer;
    transition: all 0.2s ease;
}

.popup-close:hover {
    background: rgba(255, 60, 60, 0.3);
    border-color: rgba(255, 60, 60, 0.6);
    transform: rotate(90deg);
}

/* ===== TAB-NAVIGATION ===== */
.popup-tabs {
    display: flex;
    padding: 1rem 2rem 0;
    gap: 8px;
    background: rgba(0, 0, 0, 0.2);
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}

.popup-tab {
    padding: 0.8rem 1.5rem;
    background: transparent;
    border: none;
    color: rgba(255, 255, 255, 0.6);
    font-size: 0.95rem;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 8px;
    cursor: pointer;
    transition: all 0.2s ease;
    border-radius: 12px 12px 0 0;
    position: relative;
}

.popup-tab:hover {
    color: #fff;
    background: rgba(145, 70, 255, 0.15);
}

.popup-tab.active {
    color: #c084fc;
    background: rgba(145, 70, 255, 0.2);
    border-bottom: 2px solid #9146ff;
}

.popup-tab .tab-icon {
    font-size: 1.1rem;
}

/* ===== POPUP CONTENT ===== */
.popup-content {
    padding: 2rem;
    overflow-y: auto;
    flex: 1;
}

/* ===== FORMULAR FIELDS ===== */
.tab-pane {
    display: none;
}

.tab-pane.active {
    display: block;
    animation: fadeIn 0.3s ease;
}

.form-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1.2rem;
    margin-bottom: 1.5rem;
}

.form-group {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.form-group.full-width {
    grid-column: 1 / -1;
}

.form-group label {
    font-size: 0.9rem;
    font-weight: 600;
    color: rgba(255, 255, 255, 0.8);
    display: flex;
    align-items: center;
    gap: 6px;
}

.required-star {
    color: #9146ff;
    margin-left: 2px;
}

.form-group input,
.form-group select,
.form-group textarea {
    background: rgba(0, 0, 0, 0.4);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 12px;
    padding: 0.8rem 1rem;
    color: #fff;
    font-size: 0.95rem;
    transition: all 0.2s ease;
    font-family: inherit;
}

.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
    outline: none;
    border-color: #9146ff;
    background: rgba(145, 70, 255, 0.1);
    box-shadow: 0 0 0 3px rgba(145, 70, 255, 0.15);
}

.form-group input::placeholder,
.form-group textarea::placeholder {
    color: rgba(255, 255, 255, 0.3);
}

.form-hint {
    font-size: 0.75rem;
    color: rgba(255, 255, 255, 0.4);
    margin-top: 2px;
}

/* ===== CONFIRM BOX ===== */
.confirm-box {
    margin: 1.5rem 0;
    padding: 1rem 1.2rem;
    background: rgba(145, 70, 255, 0.1);
    border: 1px solid rgba(145, 70, 255, 0.3);
    border-radius: 12px;
    display: flex;
    align-items: flex-start;
    gap: 12px;
}

.confirm-box input[type="checkbox"] {
    width: 18px;
    height: 18px;
    min-width: 18px;
    margin-top: 2px;
    accent-color: #9146ff;
    cursor: pointer;
}

.confirm-box label {
    font-size: 0.85rem;
    color: rgba(255, 255, 255, 0.8);
    line-height: 1.5;
    cursor: pointer;
}

.confirm-box label strong {
    color: #c084fc;
}

/* ===== SUBMIT BUTTON ===== */
.submit-btn {
    width: 100%;
    padding: 1rem;
    background: linear-gradient(135deg, rgba(145, 70, 255, 0.8), rgba(100, 30, 220, 0.9));
    border: 1px solid rgba(145, 70, 255, 0.5);
    border-radius: 16px;
    color: #fff;
    font-size: 1rem;
    font-weight: 700;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    cursor: pointer;
    transition: all 0.3s ease;
}

.submit-btn:hover {
    background: linear-gradient(135deg, rgba(165, 90, 255, 0.9), rgba(120, 50, 240, 1));
    transform: translateY(-2px);
    box-shadow: 0 8px 20px rgba(145, 70, 255, 0.4);
}

/* ===== SUCCESS MESSAGE ===== */
.success-msg {
    position: fixed;
    top: 20px;
    right: 20px;
    background: rgba(0, 210, 100, 0.15);
    backdrop-filter: blur(8px);
    border: 1px solid rgba(0, 210, 100, 0.4);
    border-radius: 16px;
    padding: 1.2rem 1.8rem;
    color: #4ade80;
    z-index: 10000;
    animation: slideInRight 0.3s ease;
}

@keyframes slideInRight {
    from { transform: translateX(100%); opacity: 0; }
    to { transform: translateX(0); opacity: 1; }
}

/* ===== FEHLER ===== */
.field-error {
    color: #f87171;
    font-size: 0.8rem;
    margin-top: 4px;
}

input.error,
select.error,
textarea.error {
    border-color: #f87171 !important;
    background: rgba(248, 113, 113, 0.1) !important;
}

/* ===== RESPONSIVE ===== */
@media (max-width: 768px) {
    .bewerbung-popup {
        width: 95%;
        max-height: 90vh;
    }
    
    .popup-header {
        padding: 1.2rem 1.5rem;
    }
    
    .popup-tabs {
        padding: 0.8rem 1.5rem 0;
        overflow-x: auto;
    }
    
    .popup-tab {
        padding: 0.6rem 1rem;
        white-space: nowrap;
    }
    
    .popup-content {
        padding: 1.5rem;
    }
    
    .form-grid {
        grid-template-columns: 1fr;
    }
}