/* Signup page specific CSS to match the image layout exactly */

/* ========== SIGNUP SECTION ========== */
.signup-section {
    padding: 3rem 0;
    background-color: #e8f4fd;
    min-height: calc(100vh - 80px);
    display: flex;
    align-items: center;
}

.signup-container {
    max-width: 1000px;
    margin: 0 auto;
    background-color: var(--white);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-lg);
    overflow: hidden;
}

.signup-header {
    text-align: center;
    padding: 2rem 2rem 1rem;
    background-color: var(--white);
}

.signup-header h1 {
    font-size: 2rem;
    font-weight: 700;
    color: #333;
    margin-bottom: 0.5rem;
}

.signup-header p {
    color: #666;
    font-size: 1rem;
    margin-bottom: 0;
}

.signup-form-container {
    display: grid;
    grid-template-columns: 1fr 1fr;
    min-height: 600px;
}

.signup-form {
    padding: 2rem;
    background-color: var(--white);
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.form-group {
    margin-bottom: 1.5rem;
}

.form-group label {
    display: block;
    margin-bottom: 0.5rem;
    font-weight: 600;
    font-size: 0.9rem;
    color: #333;
}

.form-input {
    width: 100%;
    padding: 0.75rem 1rem;
    border: 2px solid #e0e0e0;
    border-radius: 8px;
    font-size: 1rem;
    transition: border-color 0.2s ease;
    background-color: #fff;
}

.form-input:focus {
    outline: none;
    border-color: var(--duolingo-blue);
}

.form-input::placeholder {
    color: #999;
}

/* Select dropdown styling */
select.form-input {
    cursor: pointer;
    appearance: none;
    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='currentColor' 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 1rem center;
    background-size: 1rem;
    padding-right: 2.5rem;
}

/* Checkbox styling */
.checkbox-group {
    display: flex;
    align-items: flex-start;
    gap: 0.75rem;
    margin-bottom: 1.5rem;
}

.checkbox-group input[type="checkbox"] {
    margin-top: 0.25rem;
    flex-shrink: 0;
    width: 18px;
    height: 18px;
    accent-color: var(--duolingo-blue);
}

.checkbox-group label {
    margin-bottom: 0;
    font-weight: normal;
    font-size: 0.85rem;
    line-height: 1.4;
    color: #555;
}

.checkbox-group a {
    color: var(--duolingo-blue);
    text-decoration: underline;
}

.checkbox-group a:hover {
    color: #0ea5e9;
}

/* Submit button */
.signup-form .button {
    background-color: #58cc02;
    color: white;
    border: none;
    padding: 1rem;
    border-radius: 8px;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: background-color 0.2s ease;
    margin-bottom: 1.5rem;
}

.signup-form .button:hover {
    background-color: #4ade80;
    transform: none;
}

/* Form footer */
.form-footer {
    text-align: center;
}

.form-footer p {
    font-size: 0.8rem;
    color: #666;
    margin-bottom: 0.5rem;
    line-height: 1.4;
}

.form-footer a {
    color: var(--duolingo-blue);
    text-decoration: underline;
}

.form-footer a:hover {
    color: #0ea5e9;
}

/* Right side image area */
.signup-image {
    background: linear-gradient(135deg, #1cb0f6 0%, #58cc02 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 2rem;
    position: relative;
    overflow: hidden;
}

.signup-image::before {
    content: '';
    position: absolute;
    top: -20%;
    right: -20%;
    width: 60%;
    height: 80%;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 50%;
    animation: float-blob 8s ease-in-out infinite;
}

.signup-image img {
    max-width: 100%; /* Change from 90% to 100% */
    max-height: 500px; /* Increase from 400px to 500px or more */
    width: auto;
    height: auto;
    object-fit: contain;
    position: relative;
    z-index: 2;
    filter: drop-shadow(0 10px 20px rgba(0, 0, 0, 0.2));
}

/* Enhanced floating animation for signup image */
.signup-image .floating {
    animation: enhanced-floating 6s ease-in-out infinite;
}

@keyframes enhanced-floating {
    0% {
        transform: translateY(0) scale(1);
    }
    25% {
        transform: translateY(-15px) scale(1.02);
    }
    50% {
        transform: translateY(-10px) scale(1);
    }
    75% {
        transform: translateY(-20px) scale(0.98);
    }
    100% {
        transform: translateY(0) scale(1);
    }
}

/* ========== RESPONSIVE DESIGN ========== */
@media (max-width: 768px) {
    .signup-section {
        padding: 2rem 0;
        background-color: #e8f4fd;
    }
    
    .signup-container {
        margin: 0 1rem;
        max-width: none;
    }
    
    .signup-header {
        padding: 1.5rem 1rem 1rem;
    }
    
    .signup-header h1 {
        font-size: 1.75rem;
    }
    
    .signup-form-container {
        grid-template-columns: 1fr;
        min-height: auto;
    }
    
    .signup-form {
        padding: 1.5rem;
    }
    
    .signup-image {
        min-height: 300px;
        padding: 1.5rem;
    }
    
    .signup-image img {
        max-height: 250px;
    }
    
    .form-group {
        margin-bottom: 1.25rem;
    }
    
    .checkbox-group {
        margin-bottom: 1.25rem;
    }
}

@media (max-width: 480px) {
    .signup-section {
        padding: 1rem 0;
    }
    
    .signup-container {
        margin: 0 0.5rem;
    }
    
    .signup-header {
        padding: 1rem;
    }
    
    .signup-header h1 {
        font-size: 1.5rem;
    }
    
    .signup-header p {
        font-size: 0.9rem;
    }
    
    .signup-form {
        padding: 1rem;
    }
    
    .form-input {
        padding: 0.6rem 0.8rem;
        font-size: 0.9rem;
    }
    
    .form-group label {
        font-size: 0.85rem;
    }
    
    .checkbox-group label {
        font-size: 0.8rem;
    }
    
    .form-footer p {
        font-size: 0.75rem;
    }
    
    .signup-image {
        min-height: 250px;
        padding: 1rem;
    }
    
    .signup-image img {
        max-height: 200px;
    }
}

/* ========== ADDITIONAL STYLES FOR BETTER UX ========== */

/* Focus states for accessibility */
.form-input:focus,
.checkbox-group input:focus {
    box-shadow: 0 0 0 3px rgba(28, 176, 246, 0.1);
}

/* Loading state for form submission */
.signup-form.loading .button {
    background-color: #ccc;
    cursor: not-allowed;
    position: relative;
}

.signup-form.loading .button::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 20px;
    height: 20px;
    margin: -10px 0 0 -10px;
    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); }
}

/* Error states */
.form-input.error {
    border-color: #e53e3e;
}

.error-message {
    color: #e53e3e;
    font-size: 0.8rem;
    margin-top: 0.25rem;
    display: none;
}

.form-input.error + .error-message {
    display: block;
}

/* Success animation */
@keyframes success-bounce {
    0%, 100% { transform: scale(1); }
    50% { transform: scale(1.05); }
}

.form-group.success .form-input {
    border-color: #38a169;
    animation: success-bounce 0.3s ease;
}
