/* Register Page Styles */
.register-page {
    min-height: 100vh;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
    position: relative;
    overflow: hidden;
}

/* Background Elements */
.background-elements {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
}

.math-element {
    position: absolute;
    font-size: 2rem;
    font-weight: bold;
    color: rgba(255, 255, 255, 0.1);
    animation: float 6s ease-in-out infinite;
}

.element-1 { top: 15%; left: 7%; animation-delay: 0s; }
.element-2 { top: 25%; right: 12%; animation-delay: 1s; }
.element-3 { top: 65%; left: 10%; animation-delay: 2s; }
.element-4 { bottom: 25%; right: 18%; animation-delay: 3s; }
.element-5 { top: 45%; right: 8%; animation-delay: 4s; }

@keyframes float {
    0%, 100% { transform: translateY(0px) rotate(0deg); }
    50% { transform: translateY(-20px) rotate(180deg); }
}

/* Register Container */
.register-container {
    display: grid;
    grid-template-columns: 1fr 1fr;
    max-width: 1200px;
    width: 100%;
    background: white;
    border-radius: 20px;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.1);
    overflow: hidden;
    min-height: 700px;
}

/* Branding Section */
.register-branding {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    padding: 50px 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    overflow: hidden;
}

.brand-content {
    text-align: center;
    z-index: 2;
    position: relative;
}

.logo-container {
    margin-bottom: 25px;
}

.brand-logo {
    width: 100px;
    height: 100px;
    border-radius: 20px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.2);
}

.brand-content h1 {
    font-size: 2.2rem;
    font-weight: 700;
    margin-bottom: 8px;
    color: white;
}

.brand-subtitle {
    font-size: 1.1rem;
    opacity: 0.9;
    margin-bottom: 35px;
    font-weight: 300;
}

/* Benefits List */
.benefits-list {
    display: grid;
    gap: 15px;
    max-width: 320px;
    margin: 0 auto;
}

.benefit-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 18px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 10px;
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.2);
    text-align: left;
}

.benefit-icon {
    font-size: 1.3rem;
    flex-shrink: 0;
}

.benefit-text {
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.benefit-text strong {
    font-size: 0.9rem;
    font-weight: 600;
}

.benefit-text span {
    font-size: 0.8rem;
    opacity: 0.9;
}

/* Form Section */
.register-form-section {
    padding: 50px 40px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.form-container {
    width: 100%;
    max-width: 380px;
}

.form-header {
    text-align: center;
    margin-bottom: 30px;
}

.form-header h2 {
    font-size: 1.8rem;
    font-weight: 700;
    color: #2d3748;
    margin-bottom: 8px;
}

.form-header p {
    color: #718096;
    font-size: 0.95rem;
}

/* Flash Messages */
.flash-messages {
    margin-bottom: 20px;
}

.flash-message {
    padding: 12px 16px;
    border-radius: 10px;
    margin-bottom: 10px;
    font-size: 0.9rem;
    font-weight: 500;
}

.flash-message.error {
    background: #fed7d7;
    color: #c53030;
    border: 1px solid #feb2b2;
}

.flash-message.success {
    background: #c6f6d5;
    color: #276749;
    border: 1px solid #9ae6b4;
}

/* Form Styles */
.register-form {
    margin-bottom: 25px;
}

.form-group {
    margin-bottom: 20px;
}

.form-label {
    display: block;
    margin-bottom: 8px;
    color: #4a5568;
    font-weight: 600;
    font-size: 0.9rem;
}

.required-indicator {
    color: #e53e3e;
    margin-left: 2px;
}

.input-container {
    position: relative;
}

.form-input {
    width: 100%;
    padding: 14px 45px 14px 45px;
    border: 2px solid #e2e8f0;
    border-radius: 12px;
    font-size: 1rem;
    transition: all 0.3s ease;
    background: #fafafa;
}

.form-input:focus {
    outline: none;
    border-color: #667eea;
    background: white;
    box-shadow: 0 0 0 3px rgba(102, 126, 234, 0.1);
}

.input-icon {
    position: absolute;
    left: 15px;
    top: 50%;
    transform: translateY(-50%);
    font-size: 1.1rem;
}

.password-toggle {
    position: absolute;
    right: 15px;
    top: 50%;
    transform: translateY(-50%);
    background: none;
    border: none;
    cursor: pointer;
    font-size: 1.1rem;
    padding: 5px;
    border-radius: 5px;
    transition: background-color 0.3s ease;
}

.password-toggle:hover {
    background: #f7fafc;
}

.input-hint {
    font-size: 0.8rem;
    color: #718096;
    margin-top: 6px;
}

/* Register Button */
.register-button {
    width: 100%;
    padding: 16px 20px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    border: none;
    border-radius: 12px;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
    margin-top: 10px;
}

.register-button:hover:not(:disabled) {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(102, 126, 234, 0.3);
}

.register-button:disabled {
    opacity: 0.6;
    cursor: not-allowed;
    transform: none;
    background: #cbd5e0;
}

.button-loader {
    display: none;
}

.spinner {
    width: 20px;
    height: 20px;
    border: 2px solid transparent;
    border-top: 2px solid white;
    border-radius: 50%;
    animation: spin 1s linear infinite;
    margin: 0 auto;
}

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

/* Login Section */
.login-section {
    text-align: center;
    margin-top: 20px;
}

.login-section p {
    color: #718096;
    font-size: 0.9rem;
}

.login-link {
    color: #667eea;
    text-decoration: none;
    font-weight: 600;
    transition: color 0.3s ease;
}

.login-link:hover {
    color: #5a67d8;
    text-decoration: underline;
}

/* Error Message */
.error-message {
    display: none;
    padding: 12px 16px;
    background: #fed7d7;
    color: #c53030;
    border: 1px solid #feb2b2;
    border-radius: 10px;
    margin-bottom: 20px;
    font-size: 0.9rem;
    font-weight: 500;
}

/* Responsive Design */
@media (max-width: 968px) {
    .register-container {
        grid-template-columns: 1fr;
        max-width: 500px;
    }
    
    .register-branding {
        display: none;
    }
    
    .register-form-section {
        padding: 40px 30px;
    }
}

@media (max-width: 480px) {
    .register-page {
        padding: 10px;
    }
    
    .register-form-section {
        padding: 30px 20px;
    }
    
    .form-header h2 {
        font-size: 1.6rem;
    }
    
    .benefits-list {
        gap: 12px;
    }
    
    .benefit-item {
        padding: 10px 14px;
    }
}

/* Reduced motion support */
@media (prefers-reduced-motion: reduce) {
    .math-element {
        animation: none;
    }
}