/* SMS Pro Africa - Enhanced Registration Styles */

.modern-register-wrapper {
    background: linear-gradient(135deg, #051B47 0%, #1a2f5f 50%, #2a4377 100%);
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
}

.register-card {
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    border-radius: 20px;
    box-shadow: 0 25px 50px rgba(0, 0, 0, 0.15);
    padding: 40px;
    max-width: 900px;
    width: 100%;
    margin: 0 auto;
}

.register-header {
    text-align: center;
    margin-bottom: 40px;
}

.register-header h2 {
    color: #2c3e50;
    font-weight: 700;
    font-size: 2.5rem;
    margin-bottom: 10px;
}

.register-header p {
    color: #6c757d;
    font-size: 1.1rem;
    margin-bottom: 0;
}

.modern-stepper {
    display: flex;
    justify-content: center;
    margin-bottom: 40px;
    position: relative;
}

.modern-stepper::before {
    content: '';
    position: absolute;
    top: 25px;
    left: 25%;
    right: 25%;
    height: 2px;
    background: #e9ecef;
    z-index: 1;
}

.step-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    position: relative;
    z-index: 2;
    flex: 1;
    max-width: 150px;
}

.step-circle {
    width: 50px;
    height: 50px;
    border-radius: 50%;
    background: #e9ecef;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 10px;
    transition: all 0.3s ease;
    color: #6c757d;
    font-size: 1.2rem;
}

.step-circle.active {
    background: linear-gradient(135deg, #E44C55, #ff6b75);
    color: white;
    transform: scale(1.1);
    box-shadow: 0 4px 15px rgba(228, 76, 85, 0.3);
}

.step-circle.completed {
    background: linear-gradient(135deg, #051B47, #1a2f5f);
    color: white;
    box-shadow: 0 4px 15px rgba(5, 27, 71, 0.3);
}

.step-label {
    font-size: 0.9rem;
    color: #6c757d;
    text-align: center;
    font-weight: 500;
}

.step-label.active {
    color: #E44C55;
    font-weight: 600;
}

.form-section {
    display: none;
    animation: fadeIn 0.5s ease-in-out;
}

.form-section.active {
    display: block;
}

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

.modern-form-group {
    margin-bottom: 25px;
}

.modern-form-group label {
    display: block;
    margin-bottom: 8px;
    color: #2c3e50;
    font-weight: 600;
    font-size: 0.95rem;
}

.modern-form-control {
    width: 100%;
    padding: 15px 20px;
    border: 2px solid #e9ecef;
    border-radius: 12px;
    font-size: 1rem;
    transition: all 0.3s ease;
    background: #fff;
}

.modern-form-control:focus {
    outline: none;
    border-color: #E44C55;
    box-shadow: 0 0 0 3px rgba(228, 76, 85, 0.1);
    transform: translateY(-2px);
}

.modern-form-control:hover {
    border-color: #E44C55;
}

.row.modern-row {
    margin: 0 -10px;
}

.row.modern-row > div {
    padding: 0 10px;
}

.plan-selection {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 20px;
    margin: 30px 0;
}

.plan-card {
    border: 2px solid #e9ecef;
    border-radius: 15px;
    padding: 25px;
    text-align: center;
    cursor: pointer;
    transition: all 0.3s ease;
    background: #fff;
    position: relative;
    overflow: hidden;
}

.plan-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(102, 126, 234, 0.1), transparent);
    transition: left 0.5s ease;
}

.plan-card:hover::before {
    left: 100%;
}

.plan-card:hover {
    border-color: #E44C55;
    transform: translateY(-5px);
    box-shadow: 0 15px 30px rgba(228, 76, 85, 0.2);
}

.plan-card.selected {
    border-color: #E44C55;
    background: linear-gradient(135deg, #E44C55, #ff6b75);
    color: white;
    transform: translateY(-5px);
    box-shadow: 0 15px 30px rgba(228, 76, 85, 0.3);
}

.plan-card input[type="radio"] {
    display: none;
}

.plan-name {
    font-size: 1.4rem;
    font-weight: 700;
    margin-bottom: 10px;
}

.plan-price {
    font-size: 2rem;
    font-weight: 800;
    margin: 15px 0;
    color: #E44C55;
}

.plan-card.selected .plan-price {
    color: white;
}

.plan-description {
    font-size: 0.95rem;
    opacity: 0.8;
    margin-bottom: 15px;
}

.plan-features {
    font-size: 0.9rem;
    opacity: 0.7;
}

.navigation-buttons {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-top: 40px;
    padding-top: 30px;
    border-top: 1px solid #e9ecef;
}

.btn-modern {
    padding: 15px 30px;
    border-radius: 12px;
    font-weight: 600;
    font-size: 1rem;
    border: none;
    cursor: pointer;
    transition: all 0.3s ease;
    display: inline-flex;
    align-items: center;
    gap: 10px;
}

.btn-modern-primary {
    background: linear-gradient(135deg, #E44C55, #ff6b75);
    color: white;
}

.btn-modern-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 25px rgba(228, 76, 85, 0.3);
}

.btn-modern-secondary {
    background: linear-gradient(135deg, #051B47, #1a2f5f);
    color: white;
}

.btn-modern-secondary:hover {
    background: linear-gradient(135deg, #1a2f5f, #2a4377);
    transform: translateY(-2px);
    box-shadow: 0 8px 20px rgba(5, 27, 71, 0.3);
}

.progress-bar-container {
    width: 100%;
    height: 6px;
    background: #e9ecef;
    border-radius: 3px;
    margin-bottom: 30px;
    overflow: hidden;
}

.progress-bar {
    height: 100%;
    background: linear-gradient(90deg, #E44C55, #ff6b75);
    border-radius: 3px;
    transition: width 0.5s ease;
    width: 33.33%;
    box-shadow: 0 2px 8px rgba(228, 76, 85, 0.3);
}

.error-message {
    color: #dc3545;
    font-size: 0.875rem;
    margin-top: 5px;
    display: block;
}

.success-message {
    color: #28a745;
    font-size: 0.875rem;
    margin-top: 5px;
    display: block;
}

/* Phone number input with country code */
.phone-input-container {
    display: flex;
    align-items: center;
    border: 2px solid #e9ecef;
    border-radius: 12px;
    background: #fff;
    transition: all 0.3s ease;
}

.phone-input-container:focus-within {
    border-color: #E44C55;
    box-shadow: 0 0 0 3px rgba(228, 76, 85, 0.1);
}

.country-code-input {
    padding: 15px 10px;
    background: #f8f9fa;
    border: none !important;
    border-right: 1px solid #e9ecef !important;
    font-weight: 600;
    color: #667eea;
    border-radius: 10px 0 0 10px;
    width: 80px;
    text-align: center;
    font-size: 0.95rem;
}

.phone-number-input {
    border: none !important;
    padding: 15px 20px;
    flex: 1;
    background: transparent;
    border-radius: 0 10px 10px 0;
    color: #2c3e50;
    font-size: 1rem;
}

.phone-input-container input:focus {
    outline: none;
    box-shadow: none !important;
    border: none !important;
}

.country-code-input:focus {
    background: #e3f2fd;
    color: #1976d2;
}

.phone-number-input::placeholder {
    color: #adb5bd;
    font-size: 0.9rem;
}

/* Responsive Design */
@media (max-width: 768px) {
    .modern-register-wrapper {
        padding: 10px;
    }
    
    .register-card {
        padding: 25px 15px;
        margin: 5px;
        border-radius: 15px;
        max-width: 100%;
    }
    
    .register-header h2 {
        font-size: 1.8rem;
        margin-bottom: 8px;
    }
    
    .register-header p {
        font-size: 1rem;
    }
    
    .modern-stepper {
        flex-direction: row;
        justify-content: space-between;
        margin-bottom: 30px;
    }
    
    .modern-stepper::before {
        top: 20px;
        left: 15%;
        right: 15%;
    }
    
    .step-item {
        max-width: 100px;
    }
    
    .step-circle {
        width: 40px;
        height: 40px;
        font-size: 1rem;
    }
    
    .step-label {
        font-size: 0.75rem;
        text-align: center;
        line-height: 1.2;
    }
    
    .row.modern-row {
        margin: 0 -5px;
    }
    
    .row.modern-row > div {
        padding: 0 5px;
        margin-bottom: 15px;
    }
    
    .floating-label {
        margin-bottom: 20px;
    }
    
    .floating-label input,
    .floating-label select {
        padding: 18px 15px 8px 15px;
        font-size: 16px; /* Prevents zoom on iOS */
    }
    
    .floating-label label {
        left: 15px;
        font-size: 0.9rem;
    }
    
    .plan-selection {
        grid-template-columns: 1fr;
        gap: 15px;
    }
    
    .plan-card {
        padding: 20px 15px;
    }
    
    .plan-name {
        font-size: 1.2rem;
    }
    
    .plan-price {
        font-size: 1.6rem;
    }
    
    .navigation-buttons {
        flex-direction: column;
        gap: 15px;
        margin-top: 30px;
        padding-top: 20px;
    }
    
    .btn-modern {
        width: 100%;
        justify-content: center;
        padding: 18px 30px;
        font-size: 1.1rem;
    }
    
    .phone-input-container {
        flex-direction: row;
    }
    
    .country-code-input {
        width: 70px;
        padding: 12px 8px;
        font-size: 0.9rem;
    }
    
    .phone-number-input {
        padding: 12px 15px;
        font-size: 16px; /* Prevents zoom on iOS */
    }
}

@media (max-width: 480px) {
    .register-card {
        padding: 20px 12px;
    }
    
    .register-header h2 {
        font-size: 1.6rem;
    }
    
    .modern-stepper {
        margin-bottom: 25px;
    }
    
    .step-circle {
        width: 35px;
        height: 35px;
        font-size: 0.9rem;
    }
    
    .step-label {
        font-size: 0.7rem;
        max-width: 80px;
    }
    
    .floating-label input,
    .floating-label select {
        padding: 16px 12px 6px 12px;
    }
    
    .plan-card {
        padding: 15px 10px;
    }
}

/* Animation pour les transitions */
.slide-enter {
    transform: translateX(100%);
    opacity: 0;
}

.slide-enter-active {
    transform: translateX(0);
    opacity: 1;
    transition: all 0.3s ease;
}

.slide-exit {
    transform: translateX(0);
    opacity: 1;
}

.slide-exit-active {
    transform: translateX(-100%);
    opacity: 0;
    transition: all 0.3s ease;
}

/* Loading spinner */
.loading-spinner {
    display: inline-block;
    width: 20px;
    height: 20px;
    border: 2px solid #ffffff;
    border-radius: 50%;
    border-top-color: transparent;
    animation: spin 1s ease-in-out infinite;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

/* Custom select styling */
.modern-select {
    position: relative;
}

.modern-select select {
    appearance: none;
    background-color: #fff !important;
    background-image: url("data:image/svg+xml;charset=UTF-8,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23667eea' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3e%3cpolyline points='6,9 12,15 18,9'%3e%3c/polyline%3e%3c/svg%3e");
    background-repeat: no-repeat;
    background-position: right 15px center;
    background-size: 20px;
    padding-right: 50px;
    border: 2px solid #e9ecef !important;
    color: #2c3e50 !important;
    font-weight: 500;
}

.modern-select select:focus {
    background-color: #fff !important;
    border-color: #667eea !important;
    color: #2c3e50 !important;
}

.modern-select select option {
    background-color: #fff;
    color: #2c3e50;
    padding: 10px;
}

/* Floating labels effect */
.floating-label {
    position: relative;
    margin-bottom: 25px;
}

.floating-label input,
.floating-label select {
    width: 100%;
    padding: 20px 20px 10px 20px;
    border: 2px solid #e9ecef;
    border-radius: 12px;
    font-size: 1rem;
    background: #fff !important;
    transition: all 0.3s ease;
    color: #2c3e50 !important;
}

.floating-label label {
    position: absolute;
    top: 20px;
    left: 20px;
    font-size: 1rem;
    color: #6c757d;
    pointer-events: none;
    transition: all 0.3s ease;
    background: #fff;
    padding: 0 5px;
    z-index: 10;
}

.floating-label input:focus + label,
.floating-label input:not(:placeholder-shown) + label,
.floating-label select:focus + label,
.floating-label select:not([value=""]) + label,
.floating-label.has-value label {
    top: -10px;
    left: 15px;
    font-size: 0.8rem;
    color: #E44C55;
    font-weight: 600;
}

.floating-label input:focus,
.floating-label select:focus {
    outline: none;
    border-color: #E44C55;
    box-shadow: 0 0 0 3px rgba(228, 76, 85, 0.1);
}

/* Special styling for select fields */
.floating-label select {
    cursor: pointer;
}

.floating-label select option {
    color: #2c3e50 !important;
    background: #fff !important;
    padding: 10px;
}

/* Select2 overrides */
.select2-container--bootstrap-5 .select2-selection {
    border: 2px solid #e9ecef !important;
    border-radius: 12px !important;
    min-height: 58px !important;
    padding: 10px 15px !important;
    background: #fff !important;
}

.select2-container--bootstrap-5.select2-container--focus .select2-selection {
    border-color: #E44C55 !important;
    box-shadow: 0 0 0 3px rgba(228, 76, 85, 0.1) !important;
}

.select2-container--bootstrap-5 .select2-selection__rendered {
    color: #2c3e50 !important;
    padding-top: 8px !important;
    font-size: 1rem !important;
}

.select2-dropdown {
    border: 2px solid #E44C55 !important;
    border-radius: 12px !important;
    box-shadow: 0 10px 25px rgba(0,0,0,0.1) !important;
}

.select2-results__option {
    color: #2c3e50 !important;
    padding: 12px 15px !important;
}

.select2-results__option--highlighted {
    background-color: #E44C55 !important;
    color: white !important;
}
