/* Modern Split Layout Signup Styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    height: 100vh;
    /* overflow: hidden; */
    background-color: #f8fafc;
}

/* Screen Reader Only Content */
.sr-only {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}

.signup-wrapper {
    display: flex;
    min-height: 100vh;
}

/* Left Panel - Information Section */
.info-panel {
    flex: 0 0 60%;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 3rem;
    color: white;
    position: relative;
    /* overflow: hidden; */
}

.info-panel::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 100 100"><defs><pattern id="grid" width="10" height="10" patternUnits="userSpaceOnUse"><path d="M 10 0 L 0 0 0 10" fill="none" stroke="rgba(255,255,255,0.1)" stroke-width="0.5"/></pattern></defs><rect width="100" height="100" fill="url(%23grid)"/></svg>');
    opacity: 0.5;
}

.info-content {
    max-width: 500px;
    z-index: 1;
    position: relative;
}

.logo {
    display: flex;
    align-items: center;
    gap: 1rem;
    margin-bottom: 3rem;
}

.logo img {
    width: 3.5rem;
    height: 3.5rem;
    /* filter: brightness(0) invert(1); */
}

.logo-text {
    font-size: 1.75rem;
    font-weight: 700;
    letter-spacing: -0.025em;
}

.main-title {
    font-size: 3rem;
    font-weight: 800;
    line-height: 1.1;
    margin-bottom: 1.5rem;
    letter-spacing: -0.025em;
}

.description {
    font-size: 1.125rem;
    line-height: 1.6;
    margin-bottom: 2.5rem;
    opacity: 0.9;
}

.features {
    list-style: none;
}

.features li {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    margin-bottom: 1rem;
    font-size: 1rem;
    opacity: 0.95;
}

.features li::before {
    content: '✓';
    background-color: rgba(255, 255, 255, 0.2);
    border-radius: 50%;
    width: 1.5rem;
    height: 1.5rem;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: bold;
    flex-shrink: 0;
}

/* Right Panel - Form Section */
.form-panel {
    flex: 0 0 40%;
    background: white;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 2rem;
    /* overflow-y: auto; */
}

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

.form-header {
    text-align: center;
    margin-bottom: 2rem;
}

.form-title {
    font-size: 1.875rem;
    font-weight: 700;
    color: #1f2937;
    margin-bottom: 0.5rem;
}

.form-subtitle {
    color: #6b7280;
    font-size: 1rem;
}

.signup-form {
    display: flex;
    flex-direction: column;
    /* gap: 1rem; */
}

.form-group {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.form-label {
    font-size: 0.875rem;
    font-weight: 500;
    color: #374151;
}

.form-input {
    padding: 0.875rem 1rem;
    border: 1.5px solid #e5e7eb;
    border-radius: 8px;
    font-size: 1rem;
    transition: all 0.2s ease;
    background-color: #ffffff;
}

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

.form-input:hover:not(:focus) {
    border-color: #d1d5db;
}

/* Form Help and Error Messages */
.form-help {
    font-size: 0.75rem;
    color: #6b7280;
    margin-top: 0.25rem;
}

.error-message {
    font-size: 0.75rem;
    color: #ef4444;
    margin-top: 0.1rem;
    min-height: 1rem;
    margin-bottom:.5rem;
    display: none; /* Initially hidden */
}

.form-input.error {
    border-color: #ef4444;
    box-shadow: 0 0 0 3px rgba(239, 68, 68, 0.1);
}

.form-input.success {
    border-color: #10b981;
    box-shadow: 0 0 0 3px rgba(16, 185, 129, 0.1);
}

/* Verification Title */
.verification-title {
    font-size: 1.5rem;
    font-weight: 600;
    color: #1f2937;
    margin-bottom: 0.5rem;
}

.recaptcha-container {
    margin: 0.5rem 0;
}

.submit-button {
    padding: 0.875rem 1rem;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    border: none;
    border-radius: 8px;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s ease;
    margin-top: 0.5rem;
}

.submit-button:hover {
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(102, 126, 234, 0.3);
}

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

.privacy-terms {
    text-align: center;
    font-size: 0.875rem;
    color: #6b7280;
    margin-top: 1rem;
    line-height: 1.5;
}

.privacy-terms a {
    color: #667eea;
    text-decoration: none;
    font-weight: 500;
}

.privacy-terms a:hover {
    text-decoration: underline;
}

/* Verification Form Styles */
#verification-form {
    display: none;
    text-align: center;
    margin-top: 2rem;
}

.verification-container h2 {
    font-size: 1.5rem;
    font-weight: 600;
    color: #1f2937;
    margin-bottom: 0.5rem;
}

.verification-container p {
    color: #6b7280;
    margin-bottom: 1.5rem;
}

.verification-code-input {
    display: flex;
    justify-content: center;
    gap: 0.5rem;
    margin: 1.5rem 0;
}

.code-digit {
    width: 3rem !important;
    height: 3rem !important;
    text-align: center !important;
    font-size: 1.25rem !important;
    font-weight: 600 !important;
    border: 2px solid #e5e7eb !important;
    border-radius: 8px !important;
    background-color: #ffffff !important;
}

.code-digit:focus {
    border-color: #667eea !important;
    box-shadow: 0 0 0 3px rgba(102, 126, 234, 0.1) !important;
}

.timer {
    font-size: 0.875rem;
    color: #ef4444;
    margin: 1rem 0;
}

.resend-code {
    background: none;
    border: none;
    color: #667eea;
    text-decoration: underline;
    cursor: pointer;
    font-size: 0.875rem;
    margin-top: 1rem;
}

.form-footer {
    text-align: center;
    margin-top: 2rem;
    padding-top: 1.5rem;
    border-top: 1px solid #e5e7eb;
    font-size: 0.875rem;
    color: #6b7280;
}

.form-footer a {
    color: #667eea;
    text-decoration: none;
    font-weight: 500;
}

.form-footer a:hover {
    text-decoration: underline;
}

.copyright {
    text-align: center;
    font-size: 0.75rem;
    color: #9ca3af;
    margin-top: 1.5rem;
    opacity: 0.8;
}

/* Readonly field styles */
.readonly-field {
    background-color: #f9fafb !important;
    color: #6b7280 !important;
    cursor: not-allowed !important;
    border-color: #e5e7eb !important;
}

.email-locked {
    font-size: 0.75rem;
    color: #9ca3af;
    margin-left: 0.5rem;
    font-style: italic;
}

.invitation-message {
    background-color: #eff6ff;
    border-left: 4px solid #667eea;
    padding: 1rem;
    margin-bottom: 1.5rem;
    border-radius: 4px;
    color: #1e40af;
    font-size: 0.875rem;
}

/* Responsive Design */
@media (max-width: 1024px) {
    .info-panel {
        flex: 0 0 50%;
    }
    
    .form-panel {
        flex: 0 0 50%;
    }
    
    .main-title {
        font-size: 2.5rem;
    }
}

@media (max-width: 768px) {
    .signup-wrapper {
        flex-direction: column;
    }
    
    .info-panel {
        flex: 0 0 40%;
        padding: 2rem;
    }
    
    .form-panel {
        flex: 1;
        padding: 1.5rem;
    }
    
    .main-title {
        font-size: 2rem;
    }
    
    .description {
        font-size: 1rem;
    }
    
    .features {
        display: none;
    }
}

@media (max-width: 480px) {
    body {
        overflow-y: auto;
    }
    
    .signup-wrapper {
        min-height: 100vh;
        height: auto;
    }
    
    .info-panel {
        flex: none;
        min-height: 50vh;
        padding: 1.5rem;
    }
    
    .form-panel {
        flex: none;
        padding: 1rem;
    }
    
    .main-title {
        font-size: 1.75rem;
    }
    
    .form-input {
        font-size: 16px; /* Prevent zoom on iOS */
    }
    
    .verification-code-input {
        gap: 0.25rem;
    }
    
    .code-digit {
        width: 2.5rem !important;
        height: 2.5rem !important;
        font-size: 1.125rem !important;
    }
}

/* Dark Mode Support - Only affects the right panel */
@media (prefers-color-scheme: dark) {
    /* Right Panel - Form Section in Dark Mode */
    .form-panel {
        background: #1f2937;
        color: #f9fafb;
    }
    
    .form-title {
        color: #f9fafb;
    }
    
    .form-subtitle {
        color: #d1d5db;
    }
    
    .form-label {
        color: #d1d5db;
    }
    
    .form-input {
        background-color: #374151;
        border-color: #4b5563;
        color: #f9fafb;
    }
    
    .form-input:focus {
        border-color: #667eea;
        box-shadow: 0 0 0 3px rgba(102, 126, 234, 0.2);
    }
    
    .form-input:hover:not(:focus) {
        border-color: #6b7280;
    }
    
    .form-help {
        color: #9ca3af;
    }
    
    .error-message {
        color: #f87171;
    }
    
    .form-input.error {
        border-color: #f87171;
        box-shadow: 0 0 0 3px rgba(248, 113, 113, 0.2);
    }
    
    .form-input.success {
        border-color: #34d399;
        box-shadow: 0 0 0 3px rgba(52, 211, 153, 0.2);
    }
    
    .form-input::placeholder {
        color: #9ca3af;
    }
    
    .privacy-terms {
        color: #d1d5db;
    }
    
    .privacy-terms a {
        color: #818cf8;
    }
    
    /* Verification Form in Dark Mode */
    .verification-container h2 {
        color: #f9fafb;
    }
    
    .verification-title {
        color: #f9fafb;
    }
    
    .verification-container p {
        color: #d1d5db;
    }
    
    .code-digit {
        background-color: #374151 !important;
        border-color: #4b5563 !important;
        color: #f9fafb !important;
    }
    
    .code-digit:focus {
        border-color: #667eea !important;
        box-shadow: 0 0 0 3px rgba(102, 126, 234, 0.2) !important;
    }
    
    .resend-code {
        color: #818cf8;
    }
    
    .form-footer {
        border-top-color: #374151;
        color: #d1d5db;
    }
    
    .form-footer a {
        color: #818cf8;
    }
    
    .copyright {
        color: #6b7280;
    }
    
    /* Readonly field styles in dark mode */
    .readonly-field {
        background-color: #4b5563 !important;
        color: #9ca3af !important;
        border-color: #6b7280 !important;
    }
    
    .email-locked {
        color: #6b7280;
    }
    
    .invitation-message {
        background-color: #1e3a8a;
        border-left-color: #818cf8;
        color: #ddd6fe;
    }
}
