/* Mega HR Application Form Styles - TEK BAŞLIK VERSİYONU */

* {
    box-sizing: border-box;
}

.mega-hr-form-wrapper {
    max-width: 1000px;
    margin: 0 auto;
    padding: 20px;
    overflow-x: hidden;
}

.mega-hr-form-title {
    font-size: 1.75rem;
    font-weight: 700;
    margin-bottom: 30px;
    color: #1e3a5f;
}

.mega-hr-application-form {
    background: #fff;
    border-radius: 12px;
    box-shadow: 0 4px 6px -1px rgba(0,0,0,0.1);
}

.form-section {
    padding: 25px 30px;
    border-bottom: 1px solid #e2e8f0;
}

.form-section:last-of-type {
    border-bottom: none;
}

.form-section h3 {
    font-size: 1.125rem;
    font-weight: 600;
    margin-bottom: 20px;
    color: #1e3a5f;
}

/* Alt başlıklar - küçük yazılar */
.subsection-title {
    font-size: 0.8125rem;
    font-weight: 600;
    color: #64748b;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin: 0 0 15px 0;
}

.form-divider {
    border: none;
    border-top: 1px dashed #e2e8f0;
    margin: 25px 0;
}

.section-title-center {
    text-align: center !important;
    font-size: 0.875rem !important;
    font-weight: 600 !important;
    color: #475569 !important;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 15px !important;
}

.section-note {
    text-align: center;
    font-size: 0.8125rem;
    color: #64748b;
    margin-bottom: 15px;
    font-style: italic;
}

.form-row {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 20px;
}

.form-group {
    margin-bottom: 18px;
}

.form-group label {
    display: block;
    font-size: 0.8125rem;
    font-weight: 500;
    margin-bottom: 6px;
    color: #475569;
}

.required {
    color: #ef4444;
}

.form-group input[type="text"],
.form-group input[type="email"],
.form-group input[type="tel"],
.form-group input[type="date"],
.form-group input[type="file"],
.form-group select,
.form-group textarea {
    width: 100%;
    max-width: 100%;
    padding: 10px 14px;
    border: 1px solid #d1d5db;
    border-radius: 6px;
    font-size: 0.9375rem;
    transition: border-color 0.2s, box-shadow 0.2s;
    background: #fff;
    box-sizing: border-box;
}

.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
    outline: none;
    border-color: #1e3a5f;
    box-shadow: 0 0 0 3px rgba(30, 58, 95, 0.1);
}

.form-group input[type="file"] {
    padding: 8px;
    background: #f8fafc;
    cursor: pointer;
    width: 100%;
    max-width: 100%;
    box-sizing: border-box;
}

/* Button Group */
.button-group {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
}

.button-group-multi {
    gap: 6px;
}

.button-option {
    flex: 1;
    min-width: 80px;
}

.button-option input {
    display: none;
}

.button-option span {
    display: block;
    padding: 10px 16px;
    text-align: center;
    border: 1px solid #d1d5db;
    border-radius: 6px;
    cursor: pointer;
    transition: all 0.2s;
    font-size: 0.875rem;
    background: #fff;
}

.button-option:hover span {
    border-color: #1e3a5f;
    background: #f8fafc;
}

.button-option input:checked + span {
    background: #1e3a5f;
    color: #fff;
    border-color: #1e3a5f;
}

.checkbox-option input:checked + span {
    background: #1e3a5f;
    color: #fff;
    border-color: #1e3a5f;
}

.button-group-multi .button-option {
    flex: 0 1 auto;
    min-width: auto;
}

.button-group-multi .button-option span {
    padding: 8px 14px;
    font-size: 0.8125rem;
}

/* KVKK */
.checkbox-label {
    display: flex;
    align-items: center;
    gap: 8px;
    cursor: pointer;
    font-size: 0.875rem;
}

.kvkk-label a {
    color: #1e3a5f;
    text-decoration: underline;
}

/* Tables */
.table-responsive {
    overflow-x: auto;
    margin-top: 10px;
    -webkit-overflow-scrolling: touch;
}

.static-table,
.dynamic-table {
    width: 100%;
    border-collapse: collapse;
    min-width: 600px;
}

.static-table th,
.dynamic-table th {
    text-align: left;
    padding: 12px 10px;
    font-size: 0.6875rem;
    font-weight: 600;
    color: #1e3a5f;
    background: #f1f5f9;
    border: 1px solid #e2e8f0;
    text-transform: uppercase;
    letter-spacing: 0.3px;
}

.static-table td,
.dynamic-table td {
    padding: 8px;
    border: 1px solid #e2e8f0;
    vertical-align: middle;
    background: white;
}

.static-table tbody tr:hover,
.dynamic-table tbody tr:hover {
    background: #f8fafc;
}

.static-table tbody tr:hover td,
.dynamic-table tbody tr:hover td {
    background: #f8fafc;
}

.row-label {
    font-weight: 600;
    font-size: 0.75rem;
    color: #1e3a5f;
    background: #f1f5f9 !important;
    text-align: left;
    padding-left: 12px !important;
    min-width: 110px;
    white-space: nowrap;
}

.static-table input,
.dynamic-table input,
.dynamic-table select {
    width: 100%;
    padding: 8px 10px;
    border: 1px solid #e2e8f0;
    border-radius: 4px;
    font-size: 0.8125rem;
    background: #fff;
}

.static-table input:focus,
.dynamic-table input:focus,
.dynamic-table select:focus {
    outline: none;
    border-color: #1e3a5f;
}

/* İşlem butonları */
.col-actions {
    width: 80px;
    text-align: center;
    white-space: nowrap;
}

.add-row-btn,
.remove-row-btn {
    width: 28px !important;
    height: 28px !important;
    min-width: 28px !important;
    min-height: 28px !important;
    border: none !important;
    border-radius: 4px !important;
    cursor: pointer;
    font-size: 16px !important;
    font-weight: 700 !important;
    line-height: 28px !important;
    text-align: center !important;
    transition: all 0.2s;
    display: inline-block !important;
    margin: 0 2px !important;
    padding: 0 !important;
    color: #fff !important;
    vertical-align: middle;
    box-sizing: border-box !important;
}

.add-row-btn {
    background: #22c55e !important;
    background-color: #22c55e !important;
}

.add-row-btn:hover {
    background: #16a34a !important;
    background-color: #16a34a !important;
}

.remove-row-btn {
    background: #ef4444 !important;
    background-color: #ef4444 !important;
}

.remove-row-btn:hover {
    background: #dc2626 !important;
    background-color: #dc2626 !important;
}

/* Buton içindeki yazı rengi */
.add-row-btn,
.add-row-btn *,
.remove-row-btn,
.remove-row-btn * {
    color: #fff !important;
}

/* Form Actions */
.form-actions {
    padding: 25px 30px;
    background: #f8fafc;
    border-radius: 0 0 12px 12px;
}

.submit-btn {
    display: block;
    width: 100%;
    padding: 14px;
    background: #1e3a5f;
    color: #ffffff !important;
    border: none;
    border-radius: 6px;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: background 0.2s;
}

.submit-btn:hover {
    background: #15294a;
    color: #ffffff !important;
}

.submit-btn:disabled {
    background: #94a3b8;
    cursor: not-allowed;
}

/* Success */
.success-message {
    text-align: center;
    padding: 50px 30px;
    background: #f0fdf4;
    border: 1px solid #86efac;
    border-radius: 12px;
    color: #166534;
    font-size: 1rem;
}

.success-message::before {
    content: '✓';
    display: block;
    font-size: 2.5rem;
    margin-bottom: 15px;
}

/* Responsive */
@media (max-width: 992px) {
    .mega-hr-form-wrapper {
        padding: 15px;
    }
    
    .form-section {
        padding: 20px;
    }
}

@media (max-width: 768px) {
    .mega-hr-form-wrapper {
        padding: 10px;
        overflow-x: hidden;
    }
    
    .mega-hr-application-form {
        overflow-x: hidden;
        width: 100%;
    }
    
    .mega-hr-form-title {
        font-size: 1.5rem;
    }
    
    .form-section {
        padding: 16px;
        overflow-x: hidden;
        width: 100%;
    }
    
    .form-section h3 {
        font-size: 1rem;
    }
    
    .section-title-center {
        font-size: 0.8125rem !important;
    }
    
    .form-row {
        grid-template-columns: 1fr;
        gap: 0;
        width: 100%;
    }
    
    .form-group {
        width: 100% !important;
        max-width: 100% !important;
        overflow: hidden;
    }
    
    /* TÜM INPUT'LAR - Mobilde taşmasın */
    .form-group input,
    .form-group select,
    .form-group textarea {
        width: 100% !important;
        max-width: 100% !important;
        min-width: 0 !important;
        box-sizing: border-box !important;
    }
    
    /* DATE INPUT - ZORLA KÜÇÜLT */
    input[type="date"],
    .form-group input[type="date"] {
        width: 100% !important;
        max-width: 100% !important;
        min-width: 0 !important;
        box-sizing: border-box !important;
        -webkit-appearance: none;
        -moz-appearance: none;
        appearance: none;
    }
    
    /* File input özel */
    .form-group input[type="file"] {
        width: 100% !important;
        max-width: 100% !important;
        font-size: 0.8125rem;
    }
    
    .button-group {
        flex-direction: column;
    }
    
    .button-option {
        min-width: 100%;
    }
    
    .button-group-multi {
        flex-direction: row;
        flex-wrap: wrap;
    }
    
    .button-group-multi .button-option {
        flex: 1 1 45%;
        min-width: 45%;
    }
    
    /* Tablo - Mobil */
    .table-responsive {
        margin: 10px -16px;
        padding: 0 16px;
    }
    
    .static-table,
    .dynamic-table {
        min-width: 500px;
    }
    
    .static-table th,
    .dynamic-table th {
        padding: 10px 8px;
        font-size: 0.625rem;
    }
    
    .static-table td,
    .dynamic-table td {
        padding: 6px;
    }
    
    .static-table input,
    .dynamic-table input,
    .dynamic-table select {
        padding: 6px 8px;
        font-size: 0.75rem;
    }
    
    /* Tablo içindeki date input - daha dar */
    .dynamic-table input[type="date"] {
        width: 100%;
        min-width: 90px;
        max-width: 110px;
        padding: 6px 4px;
        font-size: 0.6875rem;
    }
    
    .row-label {
        font-size: 0.6875rem;
        min-width: 80px;
    }
    
    .col-actions {
        width: 60px;
    }
    
    .add-row-btn,
    .remove-row-btn {
        width: 26px !important;
        height: 26px !important;
        min-width: 26px !important;
        min-height: 26px !important;
        font-size: 14px !important;
        line-height: 26px !important;
        color: #fff !important;
    }
}

@media (max-width: 480px) {
    .button-group-multi .button-option {
        flex: 1 1 100%;
        min-width: 100%;
    }
    
    .form-actions {
        padding: 20px 16px;
    }
    
    .submit-btn {
        padding: 12px;
        font-size: 0.9375rem;
    }
}

/* Conditional */
.military-section,
.license-type-field,
.disability-detail-field,
.military-detail-field {
    transition: opacity 0.3s;
}