/* Enhanced UX Styling */
.form-check-input:checked {
    background-color: var(--bs-primary);
    border-color: var(--bs-primary);
}

.child-form {
    border: 2px solid var(--bs-border-color);
    border-radius: 12px;
    padding: 1.5rem;
    margin-bottom: 1.5rem;
    background-color: var(--bs-body-bg);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
    transition: border-color 0.3s ease, box-shadow 0.3s ease;
}

.child-form:hover {
    border-color: var(--bs-primary);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

.child-number {
    background: linear-gradient(135deg, var(--bs-primary), var(--bs-primary-dark, #0d6efd));
    color: white;
    padding: 0.75rem 1.25rem;
    border-radius: 25px;
    display: inline-block;
    margin-bottom: 1rem;
    font-size: 0.95rem;
    font-weight: 600;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

/* Progress Bar Enhancements */
.progress {
    background-color: var(--bs-secondary-bg);
    border-radius: 10px;
}

.progress-bar {
    background: linear-gradient(90deg, var(--bs-success), var(--bs-primary));
    border-radius: 10px;
}

/* Header Section */
.header-section {
    background: linear-gradient(135deg, var(--bs-primary-bg-subtle), var(--bs-body-bg));
    border-radius: 12px;
    padding: 2rem;
    margin-bottom: 2rem;
    border: 1px solid var(--bs-border-color);
}

.language-toggle-wrapper {
    text-align: center;
    padding: 1rem;
    background-color: var(--bs-secondary-bg);
    border-radius: 8px;
    border: 1px solid var(--bs-border-color);
}

.form-switch-lg .form-check-input {
    width: 3rem;
    height: 1.5rem;
    border-radius: 3rem;
}

/* Form Sections */
.form-section {
    transition: transform 0.2s ease, box-shadow 0.2s ease;
    border: 2px solid var(--bs-border-color);
}

.form-section:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.1);
}

/* Required Field Indicators */
.text-danger {
    font-weight: bold;
}

/* Form Validation Enhancements */
.form-control:valid {
    border-color: var(--bs-success);
}

.form-control:invalid:not(:placeholder-shown) {
    border-color: var(--bs-danger);
}

/* Submit Section Styling */
#section-submit {
    background: linear-gradient(135deg, var(--bs-success-bg-subtle), var(--bs-body-bg));
    border: 2px solid var(--bs-success);
    box-shadow: 0 4px 16px rgba(25, 135, 84, 0.1);
}

#submitBtn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

#submitBtn:not(:disabled):hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 24px rgba(25, 135, 84, 0.3);
    transition: all 0.3s ease;
}

/* Alert Enhancements */
.alert {
    border-radius: 10px;
    border: none;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

/* Enhanced Child Count Controls */
.child-count-selector {
    background: linear-gradient(135deg, #1a1a2e, #16162a);
    border: 2px solid var(--bs-primary);
    border-radius: 20px;
    padding: 2rem;
    position: relative;
    overflow: hidden;
}

.child-count-selector::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: linear-gradient(90deg, var(--bs-primary), var(--bs-success), var(--bs-info));
}

.child-count-btn {
    width: 120px;
    height: 120px;
    border-radius: 20px;
    border-width: 3px;
    font-weight: 600;
    font-size: 1.5rem;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.child-count-btn::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255,255,255,0.3), transparent);
    transition: left 0.5s ease;
}

.child-count-btn:hover::before {
    left: 100%;
}

.child-count-btn:hover {
    transform: translateY(-4px) scale(1.05);
    box-shadow: 0 8px 24px rgba(13, 110, 253, 0.4);
    border-color: var(--bs-primary);
}

.child-count-btn:disabled {
    opacity: 0.4;
    transform: none;
    box-shadow: none;
    cursor: not-allowed;
}

.child-count-btn .btn-text {
    font-size: 0.9rem;
    font-weight: 500;
}

.child-count-display {
    text-align: center;
    background: #0a0a0f;
    border: 3px solid var(--bs-primary);
    border-radius: 20px;
    padding: 1.5rem;
    min-width: 150px;
    box-shadow: 0 8px 24px rgba(13, 110, 253, 0.2);
    position: relative;
}

.count-number {
    font-size: 4rem;
    font-weight: 800;
    color: var(--bs-primary);
    line-height: 1;
    text-shadow: 2px 2px 4px rgba(0,0,0,0.1);
}

.count-label {
    font-size: 1.2rem;
    font-weight: 600;
    color: var(--bs-secondary);
    margin-top: 0.5rem;
    text-transform: uppercase;
    letter-spacing: 1px;
}

/* Visual Child Icons */
.child-icons-display {
    display: flex;
    justify-content: center;
    gap: 1rem;
    flex-wrap: wrap;
    padding: 1rem;
    background: rgba(26, 26, 46, 0.5);
    border-radius: 15px;
    border: 2px dashed rgba(148, 163, 184, 0.2);
}

.child-icon {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.5rem;
    padding: 1rem;
    border-radius: 12px;
    background: #16162a;
    border: 2px solid rgba(148, 163, 184, 0.2);
    transition: all 0.3s ease;
    min-width: 80px;
    opacity: 0.4;
    transform: scale(0.9);
}

.child-icon.active {
    opacity: 1;
    transform: scale(1);
    border-color: var(--bs-success);
    background: var(--bs-success-bg-subtle);
    color: var(--bs-success);
    box-shadow: 0 4px 12px rgba(25, 135, 84, 0.2);
}

.child-icon i {
    font-size: 1.8rem;
    margin-bottom: 0.25rem;
}

.child-icon span {
    font-size: 0.8rem;
    font-weight: 600;
    text-align: center;
}

/* Animations */
@keyframes childIconAppear {
    from {
        opacity: 0;
        transform: scale(0.5) translateY(20px);
    }
    to {
        opacity: 1;
        transform: scale(1) translateY(0);
    }
}

.child-icon.entering {
    animation: childIconAppear 0.4s ease-out forwards;
}

.btn-outline-primary {
    border-width: 2px;
    font-weight: 600;
    transition: all 0.3s ease;
}

.btn-outline-primary:hover {
    transform: scale(1.05);
    box-shadow: 0 4px 12px rgba(13, 110, 253, 0.3);
}

/* Form Text Styling */
.form-text {
    font-size: 0.875rem;
    font-style: italic;
    color: var(--bs-secondary);
}

/* Responsive Improvements */
@media (max-width: 768px) {
    .container {
        padding-left: 1rem;
        padding-right: 1rem;
    }
    
    .header-section {
        padding: 1rem;
    }
    
    .language-toggle-wrapper {
        margin-top: 1rem;
    }
    
    .d-flex.justify-content-between {
        flex-direction: column;
        gap: 1rem;
    }
    
    .child-form {
        padding: 1rem;
    }
    
    .child-count-btn {
        width: 100px;
        height: 100px;
        font-size: 1.2rem;
    }
    
    .child-count-display {
        min-width: 120px;
        padding: 1rem;
    }
    
    .count-number {
        font-size: 3rem;
    }
    
    .child-icons-display {
        gap: 0.5rem;
    }
    
    .child-icon {
        min-width: 60px;
        padding: 0.75rem;
    }
}

/* Loading and Animation States */
.form-control, .btn {
    transition: all 0.2s ease;
}

/* Focus States */
.form-control:focus,
.form-select:focus,
.form-check-input:focus {
    border-color: var(--bs-primary);
    box-shadow: 0 0 0 0.2rem rgba(13, 110, 253, 0.25);
}
