/* Registration Page Styles - Following Login Design Pattern */
@import url('https://fonts.googleapis.com/css2?family=Montserrat:wght@400;700&family=Mochiy+Pop+One&family=Poppins:wght@400;700&display=swap');

.registration-page {
    margin: 0;
    padding: 0;
    font-family: 'Montserrat', sans-serif;
    background: white;
    min-height: 100vh;
}

.registration-container {
    min-height: 100vh;
    background: white;
    position: relative;
    overflow: hidden;
    width: 100%;
    max-width: 402px;
    height: 874px;
    margin: 0 auto;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: flex-start;
    padding: 120px 20px 40px 20px;
    box-sizing: border-box;
}

/* Main Content Wrapper */
.main-content {
    display: flex;
    flex-direction: column;
    align-items: center;
    width: 100%;
    max-width: 350px;
    z-index: 10;
    gap: 20px;
}

/* Header Section */
.header-section {
    display: flex;
    flex-direction: column;
    align-items: center;
    width: 100%;
    gap: 15px;
}

/* Main Title */
.registration-title {
    font-family: 'Montserrat', sans-serif;
    font-weight: 700;
    font-size: 40px;
    line-height: 1.22;
    color: #000000;
    margin: 0;
    text-align: center;
}

/* General Error Message */
.general-error-message {
    width: 100%;
    text-align: center;
    z-index: 10;
}

.error-text {
    color: #dc2626;
    font-size: 14px;
    font-weight: 500;
    margin: 0;
    text-align: center;
    line-height: 1.4;
    font-family: 'Montserrat', sans-serif;
}

.error-text:not(:last-child) {
    margin-bottom: 4px;
}

/* Form Section */
.form-section {
    display: flex;
    flex-direction: column;
    align-items: center;
    width: 100%;
    gap: 15px;
}

/* Form Styles */
.registration-form {
    display: flex;
    flex-direction: column;
    align-items: center;
    width: 100%;
    gap: 10px;
    z-index: 10;
}

.form-group {
    display: flex;
    flex-direction: column;
    position: relative;
    width: 100%;
    max-width: 316px;
}

.form-input {
    width: 100%;
    height: 50px;
    background: #D9D9D9;
    border: 3px solid #000000;
    border-radius: 30px;
    padding: 0 20px;
    font-family: 'Mochiy Pop One', cursive;
    font-size: 14px;
    line-height: 1.45;
    color: rgba(0, 0, 0, 0.5);
    outline: none;
    box-sizing: border-box;
    position: relative;
    z-index: 10;
    pointer-events: auto;
}

.form-input:focus {
    background: #FFFFFF;
    color: #000000;
    z-index: 15;
}

.form-input::placeholder {
    color: rgba(0, 0, 0, 0.5);
    font-family: 'Mochiy Pop One', cursive;
    font-size: 14px;
    line-height: 1.45;
}

/* Password Input with Toggle */
.password-input {
    position: relative;
}

.password-toggle {
    position: absolute;
    top: 0;
    bottom: 0;
    right: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 20;
    padding: 0 12px;
    cursor: pointer;
    color: #666;
    background: none;
    border: none;
    border-top-right-radius: 30px;
    border-bottom-right-radius: 30px;
}

.password-toggle:hover {
    color: #333;
}

.password-toggle:focus {
    outline: none;
}

.eye-icon,
.eye-off-icon {
    width: 20px;
    height: 20px;
}

/* Select Styling */
select.form-input {
    cursor: pointer;
    appearance: none;
    background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' fill='none' viewBox='0 0 20 20'%3e%3cpath stroke='%23000' stroke-linecap='round' stroke-linejoin='round' stroke-width='1.5' d='M6 8l4 4 4-4'/%3e%3c/svg%3e");
    background-position: right 20px center;
    background-repeat: no-repeat;
    background-size: 16px;
}

/* Submit Button */
.submit-button {
    width: 100%;
    max-width: 316px;
    height: 50px;
    background: #000000;
    border: 3px solid #000000;
    border-radius: 30px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
    z-index: 10;
    margin-top: 10px;
}

.submit-button:hover {
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.3);
}

.submit-button:active {
    transform: translateY(0);
}

.button-text {
    font-family: 'Poppins', sans-serif;
    font-weight: 700;
    font-size: 25px;
    line-height: 1.5;
    color: #FFFFFF;
    display: flex;
    align-items: center;
    justify-content: center;
}

/* Error Messages */
.error-message {
    color: #dc2626;
    font-size: 12px;
    margin-top: 4px;
    display: block;
    font-family: 'Montserrat', sans-serif;
    position: absolute;
    top: 55px;
    left: 20px;
}

.form-input.error {
    border-color: #dc2626;
    background: #ffe6e6;
}

.input-field.error {
    border-color: #dc3545;
}

/* Footer Section */
.footer-section {
    display: flex;
    justify-content: center;
    width: 100%;
    margin-top: auto;
    padding-bottom: 30px;
}

.form-footer {
    text-align: center;
    z-index: 10;
}

.footer-text {
    font-family: 'Montserrat', sans-serif;
    font-size: 14px;
    color: #666666;
    margin: 0;
}

.footer-link {
    color: #000000;
    text-decoration: none;
    font-weight: 700;
}

.footer-link:hover {
    text-decoration: underline;
}

/* Back Button - Positioned Absolutely */
.back-button {
    position: absolute;
    top: 15px;
    left: 27px;
    display: flex;
    align-items: center;
    gap: 4px;
    background: none;
    border: none;
    cursor: pointer;
    z-index: 10;
    text-decoration: none;
    color: #000000;
    width: 95px;
    height: 30px;
}

.back-arrow {
    width: 30px;
    height: 30px;
    position: absolute;
    left: 0;
    top: 0;
    rotate: -90deg;
    transform: rotate(90deg);
}

.back-text {
    position: absolute;
    left: 34px;
    top: 5px;
    font-family: 'Montserrat', sans-serif;
    font-weight: 700;
    font-size: 14px;
    line-height: 1.22;
    color: #000000;
    width: 61px;
    height: 17px;
}

/* Background Elements - Positioned Absolutely */
.blue-creature {
    position: absolute;
    top: 500px;
    left: 220px;
    width: 150px;
    height: auto;
    z-index: -1;
    pointer-events: none;
}

.blue-creature img {
    width: 100%;
    height: 100%;
    object-fit: contain;
}

.orange-ball {
    position: absolute;
    top: 420px;
    left: 15px;
    width: 120px;
    height: 118px;
    z-index: -1;
    pointer-events: none;
}

.orange-ball img {
    width: 100%;
    height: 100%;
    object-fit: contain;
}

.green-eye {
    position: absolute;
    top: 80px;
    left: 300px;
    width: 60px;
    height: 60px;
    z-index: -1;
    pointer-events: none;
}

.green-eye img {
    width: 100%;
    height: 100%;
    object-fit: contain;
}



/* Animation Classes */
.fade-in {
    opacity: 0;
    transform: translateY(30px);
}

.slide-in-left {
    opacity: 0;
    transform: translateX(-50px);
}

.slide-in-right {
    opacity: 0;
    transform: translateX(50px);
}

.scale-in {
    opacity: 0;
    transform: scale(0.8);
}

.float-animation {
    animation: float 6s ease-in-out infinite;
}

.rotate-animation {
    animation: rotate 20s linear infinite;
}

/* Initial states for animated elements */
.registration-container,
.blue-creature,
.orange-ball,
.green-eye,
.back-button,
.registration-title,
.registration-form,
.form-group,
.submit-button {
    opacity: 0;
}

/* Simple CSS Animations - Fallback for GSAP */
.registration-container {
    animation: fadeInUp 0.8s ease-out forwards;
}

.blue-creature {
    animation: floatIn 0.8s ease-out 0.1s forwards, float 3s ease-in-out infinite 0.9s;
}

.orange-ball {
    animation: rotateIn 0.8s ease-out 0.2s forwards, rotate 20s linear infinite 1s;
}

.green-eye {
    animation: bounceIn 0.8s ease-out 0.3s forwards, pulse 2s infinite 1.1s;
}

.back-button {
    animation: fadeIn 0.6s ease-out 0.4s forwards;
}

.registration-title {
    animation: slideUp 0.7s ease-out 0.5s forwards;
}

.registration-form {
    animation: fadeInUp 0.6s ease-out 0.6s forwards;
}

.form-group {
    animation: slideInLeft 0.5s ease-out forwards;
}

.form-group:nth-child(1) {
    animation-delay: 0.7s;
}

.form-group:nth-child(2) {
    animation-delay: 0.75s;
}

.form-group:nth-child(3) {
    animation-delay: 0.8s;
}

.form-group:nth-child(4) {
    animation-delay: 0.85s;
}

.form-group:nth-child(5) {
    animation-delay: 0.9s;
}

.form-group:nth-child(6) {
    animation-delay: 0.95s;
}

.submit-button {
    animation: scaleIn 0.5s ease-out 1s forwards;
}

/* Keyframes for animations */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes floatIn {
    from {
        opacity: 0;
        transform: translateY(40px) scale(0.9);
    }

    to {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}

@keyframes rotateIn {
    from {
        opacity: 0;
        transform: scale(0.8) rotate(-90deg);
    }

    to {
        opacity: 1;
        transform: scale(1) rotate(0deg);
    }
}

@keyframes bounceIn {
    from {
        opacity: 0;
        transform: scale(0.5);
    }

    60% {
        transform: scale(1.1);
    }

    to {
        opacity: 1;
        transform: scale(1);
    }
}

@keyframes fadeIn {
    from {
        opacity: 0;
    }

    to {
        opacity: 1;
    }
}

@keyframes slideUp {
    from {
        opacity: 0;
        transform: translateY(20px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes slideInLeft {
    from {
        opacity: 0;
        transform: translateX(-30px);
    }

    to {
        opacity: 1;
        transform: translateX(0);
    }
}

@keyframes scaleIn {
    from {
        opacity: 0;
        transform: scale(0.8);
    }

    to {
        opacity: 1;
        transform: scale(1);
    }
}

@keyframes ripple {
    from {
        width: 0;
        height: 0;
        opacity: 1;
    }

    to {
        width: 200px;
        height: 200px;
        opacity: 0;
    }
}

/* Animation Classes */
.animate-in {
    opacity: 1;
    transform: none;
}

.pulse-animation {
    animation: pulse 2s infinite;
}

/* Keyframes */
@keyframes float {

    0%,
    100% {
        transform: translateY(0px);
    }

    50% {
        transform: translateY(-20px);
    }
}

@keyframes rotate {
    0% {
        transform: rotate(0deg);
    }

    100% {
        transform: rotate(360deg);
    }
}

@keyframes pulse {

    0%,
    100% {
        transform: scale(1);
    }

    50% {
        transform: scale(1.05);
    }
}

/* Form Validation States */
.form-input.error {
    border-color: #ff4757;
    box-shadow: 0 0 0 3px rgba(255, 71, 87, 0.1);
    animation: shake 0.5s ease-in-out;
}

@keyframes shake {

    0%,
    100% {
        transform: translateX(0);
    }

    25% {
        transform: translateX(-5px);
    }

    75% {
        transform: translateX(5px);
    }
}

.form-input.valid {
    border-color: #2ed573;
    box-shadow: 0 0 0 3px rgba(46, 213, 115, 0.1);
}

/* Loading States */
.submit-button.loading {
    pointer-events: none;
    opacity: 0.7;
}

.submit-button.loading .button-text {
    opacity: 0;
}

.submit-button.loading::after {
    content: '';
    position: absolute;
    width: 20px;
    height: 20px;
    border: 2px solid transparent;
    border-top: 2px solid white;
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    0% {
        transform: rotate(0deg);
    }

    100% {
        transform: rotate(360deg);
    }
}