﻿/* Animated Background - Forest Green Theme */
.particles-background {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -1;
    background: linear-gradient(135deg, #2d5a32 0%, #1a3d1f 25%, #0f2912 50%, #1a3d1f 75%, #2d5a32 100%);
    background-size: 400% 400%;
    animation: gradientShift 15s ease infinite;
}

@keyframes gradientShift {
    0% {
        background-position: 0% 50%;
    }

    50% {
        background-position: 100% 50%;
    }

    100% {
        background-position: 0% 50%;
    }
}

/* Main Container */
.registration-container {
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    padding: 2rem;
    position: relative;
}

/* Header */
.registration-header {
    text-align: center;
    margin-bottom: 2rem;
}

.app-brand {
    margin-bottom: 1rem;
}

.app-brand-link {
    display: flex;
    align-items: center;
    justify-content: center;
    text-decoration: none;
    color: inherit;
    transition: transform 0.3s ease;
}

    .app-brand-link:hover {
        transform: scale(1.05);
    }

.logo-img {
    height: 60px;
    width: auto;
    margin-right: 1rem;
}

.app-brand-text {
    font-size: 1.5rem;
    font-weight: 700;
    color: #fff;
}

.registration-tagline h1 {
    color: #fff;
    font-size: 2.5rem;
    font-weight: 700;
    margin-bottom: 0.5rem;
    text-shadow: 2px 2px 4px rgba(0,0,0,0.3);
}

.registration-tagline p {
    color: rgba(255, 255, 255, 0.8);
    font-size: 1.1rem;
    margin-bottom: 0;
}

/* Progress Indicator */
.progress-container {
    width: 100%;
    max-width: 600px;
    margin-bottom: 2rem;
}

.progress-bar {
    height: 4px;
    background-color: rgba(255, 255, 255, 0.3);
    border-radius: 2px;
    overflow: hidden;
    margin-bottom: 1rem;
}

.progress-fill {
    height: 100%;
    background: linear-gradient(90deg, #396940, #4a7c54);
    border-radius: 2px;
    transition: width 0.5s ease;
    width: 25%;
}

.step-indicators {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.step-indicator {
    display: flex;
    flex-direction: column;
    align-items: center;
    color: rgba(255, 255, 255, 0.6);
    transition: all 0.3s ease;
}

    .step-indicator.active {
        color: #fff;
        transform: scale(1.1);
    }

    .step-indicator.completed {
        color: #4a7c54;
    }

.step-number {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background-color: rgba(255, 255, 255, 0.2);
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 600;
    margin-bottom: 0.5rem;
    transition: all 0.3s ease;
}

.step-indicator.active .step-number {
    background-color: #396940;
    color: #fff;
    box-shadow: 0 0 15px rgba(57, 105, 64, 0.5);
}

.step-indicator.completed .step-number {
    background-color: #396940;
    color: #fff;
}

.step-label {
    font-size: 0.875rem;
    font-weight: 500;
    text-align: center;
}

/* Form Container */
.form-container {
    background: #fff;
    border-radius: 1rem;
    padding: 2rem;
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.1);
    width: 100%;
    max-width: 500px;
    min-height: 500px;
    position: relative;
}

/* Form Steps */
.form-step {
    display: none;
    animation: fadeIn 0.5s ease-in-out;
}

    .form-step.active {
        display: block;
    }

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(20px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.step-header {
    text-align: center;
    margin-bottom: 2rem;
}

.step-icon {
    font-size: 3rem;
    color: #396940;
    margin-bottom: 1rem;
}

.step-header h2 {
    font-size: 1.5rem;
    font-weight: 600;
    color: #333;
    margin-bottom: 0.5rem;
}

.step-header p {
    color: #666;
    font-size: 0.95rem;
    margin-bottom: 0;
}

/* Form Content */
.form-content {
    margin-bottom: 2rem;
}

.input-group-modern {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.input-row {
    display: flex;
    gap: 1rem;
}

.input-col {
    flex: 1;
}

/* Form Groups - Simplified Layout */
.form-group {
    margin-bottom: 1rem;
}

.form-label {
    display: block;
    margin-bottom: 0.5rem;
    font-weight: 500;
    color: #333;
    font-size: 0.95rem;
}

.input-with-icon {
    position: relative;
}

    .input-with-icon input,
    .input-with-icon select,
    .input-with-icon textarea {
        width: 100%;
        padding: 0.875rem 0.875rem 0.875rem 2.75rem;
        border: 2px solid #e9ecef;
        border-radius: 0.5rem;
        font-size: 1rem;
        transition: all 0.3s ease;
        background: #fff;
        box-sizing: border-box;
    }

        .input-with-icon input:focus,
        .input-with-icon select:focus,
        .input-with-icon textarea:focus {
            outline: none;
            border-color: #396940;
            box-shadow: 0 0 0 0.2rem rgba(57, 105, 64, 0.25);
        }

.input-icon {
    position: absolute;
    top: 50%;
    left: 0.875rem;
    transform: translateY(-50%);
    color: #666;
    font-size: 1.25rem;
    pointer-events: none;
    transition: color 0.3s ease;
}

.input-with-icon input:focus ~ .input-icon,
.input-with-icon select:focus ~ .input-icon,
.input-with-icon textarea:focus ~ .input-icon {
    color: #396940;
}

/* Simplified Phone Input Layout */
.phone-input-group {
    display: flex;
    gap: 0.75rem;
    width: 100%;
}

.country-select {
    flex: 0 0 130px;
    width: 130px;
    padding: 0.875rem 0.5rem;
    border: 2px solid #e9ecef;
    border-radius: 0.5rem;
    font-size: 1rem;
    transition: all 0.3s ease;
    background: #fff;
    box-sizing: border-box;
}

    .country-select:focus {
        outline: none;
        border-color: #396940;
        box-shadow: 0 0 0 0.2rem rgba(57, 105, 64, 0.25);
    }

.phone-number-input {
    flex: 1;
}

    .phone-number-input input {
        width: 100%;
        padding: 0.875rem;
        border: 2px solid #e9ecef;
        border-radius: 0.5rem;
        font-size: 1rem;
        transition: all 0.3s ease;
        background: #fff;
        box-sizing: border-box;
    }

        .phone-number-input input:focus {
            outline: none;
            border-color: #396940;
            box-shadow: 0 0 0 0.2rem rgba(57, 105, 64, 0.25);
        }

/* Blood Type Selector */
.blood-type-selector {
    margin-bottom: 1rem;
}

.blood-type-label {
    display: block;
    margin-bottom: 1rem;
    font-weight: 500;
    color: #333;
}

.blood-type-options {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 0.5rem;
}

.blood-type-option {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0.75rem;
    border: 2px solid #e9ecef;
    border-radius: 0.5rem;
    cursor: pointer;
    transition: all 0.3s ease;
    background: #fff;
    font-weight: 500;
    box-sizing: border-box;
}

    .blood-type-option:hover {
        border-color: #396940;
        background: rgba(57, 105, 64, 0.1);
    }

input[type="radio"]:checked + .blood-type-option {
    border-color: #396940;
    background: #396940;
    color: #fff;
}

input[type="radio"] {
    display: none;
}

/* Health Info Note */
.health-info-note {
    background: rgba(57, 105, 64, 0.1);
    border: 1px solid rgba(57, 105, 64, 0.3);
    border-radius: 0.5rem;
    padding: 1rem;
    display: flex;
    align-items: flex-start;
    gap: 0.75rem;
    margin-top: 1rem;
}

    .health-info-note i {
        color: #396940;
        font-size: 1.25rem;
        margin-top: 0.125rem;
    }

    .health-info-note p {
        margin: 0;
        color: #333;
        font-size: 0.9rem;
        line-height: 1.4;
    }

/* Password Toggle */
.password-toggle {
    position: absolute;
    top: 50%;
    right: 0.875rem;
    transform: translateY(-50%);
    background: none;
    border: none;
    color: #666;
    font-size: 1.25rem;
    cursor: pointer;
    transition: color 0.3s ease;
    z-index: 2;
}

    .password-toggle:hover {
        color: #396940;
    }

/* Password Requirements */
.password-requirements {
    margin-top: 1rem;
    padding: 1rem;
    background: #f8f9fa;
    border-radius: 0.5rem;
}

    .password-requirements h6 {
        font-size: 0.9rem;
        font-weight: 600;
        color: #333;
        margin-bottom: 0.5rem;
    }

    .password-requirements ul {
        list-style: none;
        padding: 0;
        margin: 0;
    }

    .password-requirements li {
        display: flex;
        align-items: center;
        gap: 0.5rem;
        font-size: 0.85rem;
        color: #666;
        margin-bottom: 0.25rem;
    }

        .password-requirements li i {
            font-size: 1rem;
            color: #dc3545;
        }

        .password-requirements li.valid i {
            color: #396940;
        }

/* Navigation Buttons */
.form-navigation {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-top: 2rem;
}

    .form-navigation .btn {
        padding: 0.75rem 1.5rem;
        font-weight: 500;
        border-radius: 0.5rem;
        transition: all 0.3s ease;
    }

        .form-navigation .btn:hover {
            transform: translateY(-2px);
            box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
        }

/* Button Color Updates */
.btn-primary {
    background-color: #396940;
    border-color: #396940;
}

    .btn-primary:hover {
        background-color: #2d5a32;
        border-color: #2d5a32;
    }

    .btn-primary:focus {
        box-shadow: 0 0 0 0.2rem rgba(57, 105, 64, 0.25);
    }

.btn-success {
    background-color: #4a7c54;
    border-color: #4a7c54;
}

    .btn-success:hover {
        background-color: #396940;
        border-color: #396940;
    }

.btn-outline-primary {
    color: #396940;
    border-color: #396940;
}

    .btn-outline-primary:hover {
        background-color: #396940;
        border-color: #396940;
        color: #fff;
    }

/* Validation States */
.form-control.is-valid {
    border-color: #396940;
    box-shadow: 0 0 0 0.2rem rgba(57, 105, 64, 0.25);
}

.form-control.is-invalid {
    border-color: #dc3545;
    box-shadow: 0 0 0 0.2rem rgba(220, 53, 69, 0.25);
}

/* Enhanced Validation Messages */
.validation-message {
    color: #dc3545;
    font-size: 0.875rem;
    margin-top: 0.25rem;
    display: none;
    word-wrap: break-word;
}

    .validation-message:not(:empty) {
        display: block;
    }

/* Phone validation indicator */
.validation-indicator {
    margin-top: 0.5rem;
    min-height: 1.5rem;
    font-size: 0.875rem;
}

/* Footer */
.registration-footer {
    margin-top: 2rem;
    text-align: center;
}

    .registration-footer p {
        color: rgba(255, 255, 255, 0.8);
        font-size: 0.95rem;
        margin: 0;
    }

.login-link {
    color: #fff;
    text-decoration: none;
    font-weight: 500;
    transition: color 0.3s ease;
}

    .login-link:hover {
        color: #4a7c54;
        text-decoration: underline;
    }

/* Welcome Modal */
.welcome-modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.8);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 9999;
}

.welcome-content {
    background: #fff;
    padding: 3rem;
    border-radius: 1rem;
    text-align: center;
    max-width: 400px;
    animation: slideIn 0.5s ease-out;
}

@keyframes slideIn {
    from {
        transform: translateY(-50px);
        opacity: 0;
    }

    to {
        transform: translateY(0);
        opacity: 1;
    }
}

.welcome-icon {
    font-size: 4rem;
    color: #396940;
    margin-bottom: 1rem;
}

.welcome-content h3 {
    color: #333;
    margin-bottom: 1rem;
}

.welcome-content p {
    color: #666;
    margin-bottom: 2rem;
}

/* Responsive Design */
@media (max-width: 768px) {
    .registration-container {
        padding: 1rem;
    }

    .registration-tagline h1 {
        font-size: 2rem;
    }

    .form-container {
        padding: 1.5rem;
    }

    .input-row {
        flex-direction: column;
        gap: 1rem;
    }

    .blood-type-options {
        grid-template-columns: repeat(2, 1fr);
    }

    .step-indicators {
        flex-wrap: wrap;
        gap: 1rem;
    }

    .step-label {
        font-size: 0.8rem;
    }

    .phone-input-group {
        flex-direction: column;
        gap: 0.75rem;
    }

    .country-select {
        flex: none;
        width: 100%;
    }
}

@media (max-width: 480px) {
    .blood-type-options {
        grid-template-columns: repeat(2, 1fr);
    }
}
