* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
}

.auth-container {
    width: 100%;
    max-width: 480px;
}

.auth-box {
    background: white;
    padding: 40px;
    border-radius: 16px;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
}

.logo h2 {
    font-size: 32px;
    color: #1a1a1a;
    margin-bottom: 8px;
    text-align: left;
    font-weight: 700;
}

.logo p {
    color: #666;
    text-align: left;
    margin-bottom: 32px;
    font-size: 15px;
}

/* Form Steps */
.form-step {
    display: none;
}

.form-step.active {
    display: block;
    animation: fadeIn 0.3s ease-in;
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* User Info Display */
.user-info {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 12px 16px;
    background: #f8f9fa;
    border-radius: 8px;
    margin-bottom: 24px;
}

.display-email {
    font-size: 14px;
    color: #333;
    font-weight: 500;
}

.btn-change {
    background: transparent;
    border: none;
    color: #667eea;
    font-size: 14px;
    cursor: pointer;
    font-weight: 500;
    padding: 4px 8px;
}

.btn-change:hover {
    text-decoration: underline;
}

/* Form Elements */
.form-group {
    margin-bottom: 20px;
}

label {
    display: block;
    margin-bottom: 8px;
    color: #333;
    font-weight: 500;
    font-size: 14px;
}

input[type="email"],
input[type="password"],
input[type="text"] {
    width: 100%;
    padding: 14px 16px;
    border: 2px solid #e0e0e0;
    border-radius: 8px;
    font-size: 15px;
    transition: all 0.2s;
    background: white;
}

input:focus {
    outline: none;
    border-color: #667eea;
    box-shadow: 0 0 0 3px rgba(102, 126, 234, 0.1);
}

input::placeholder {
    color: #999;
}

small {
    display: block;
    margin-top: 6px;
    color: #666;
    font-size: 13px;
}

.password-hint {
    color: #666;
}

/* Checkbox */
.checkbox-group {
    margin: 20px 0;
}

.checkbox-label {
    display: flex;
    align-items: flex-start;
    cursor: pointer;
    font-weight: 400;
}

.checkbox-label input[type="checkbox"] {
    margin-right: 10px;
    margin-top: 2px;
    width: 18px;
    height: 18px;
    cursor: pointer;
}

.checkbox-label span {
    font-size: 14px;
    color: #555;
    line-height: 1.5;
}

.checkbox-label a {
    color: #667eea;
    text-decoration: none;
}

.checkbox-label a:hover {
    text-decoration: underline;
}

/* Buttons */
.btn-primary {
    width: 100%;
    padding: 16px;
    background: #667eea;
    color: white;
    border: none;
    border-radius: 8px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s;
    margin-top: 8px;
}

.btn-primary:hover:not(:disabled) {
    background: #5568d3;
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(102, 126, 234, 0.3);
}

.btn-primary:active:not(:disabled) {
    transform: translateY(0);
}

.btn-primary:disabled {
    background: #ccc;
    cursor: not-allowed;
    transform: none;
}

.btn-secondary {
    width: 100%;
    padding: 14px;
    background: white;
    color: #667eea;
    border: 2px solid #667eea;
    border-radius: 8px;
    font-size: 15px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s;
}

.btn-secondary:hover {
    background: #f0f3ff;
}

.btn-link {
    background: transparent;
    border: none;
    color: #667eea;
    font-size: 14px;
    cursor: pointer;
    padding: 8px;
    font-weight: 500;
}

.btn-link:hover {
    text-decoration: underline;
}

/* Divider */
.divider {
    text-align: center;
    margin: 24px 0;
    color: #999;
    font-size: 13px;
    position: relative;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.divider::before,
.divider::after {
    content: '';
    position: absolute;
    top: 50%;
    width: 42%;
    height: 1px;
    background: #e0e0e0;
}

.divider::before {
    left: 0;
}

.divider::after {
    right: 0;
}

/* Form Actions */
.form-actions {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-top: 12px;
}

.form-actions a,
.form-actions button {
    font-size: 14px;
    color: #667eea;
    text-decoration: none;
}

.form-actions a:hover {
    text-decoration: underline;
}

/* Info Text */
.info-text {
    text-align: center;
    color: #666;
    font-size: 14px;
    margin-bottom: 20px;
    line-height: 1.5;
}

/* Verify Icon */
.verify-icon {
    text-align: center;
    font-size: 64px;
    margin-bottom: 16px;
}

#verifyStep h2 {
    text-align: center;
    font-size: 24px;
    margin-bottom: 12px;
    color: #1a1a1a;
}

/* Messages */
.message {
    padding: 14px 16px;
    border-radius: 8px;
    margin-top: 16px;
    font-size: 14px;
    display: none;
    animation: slideDown 0.3s ease-out;
}

@keyframes slideDown {
    from {
        opacity: 0;
        transform: translateY(-10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.message.error {
    background: #fee;
    color: #c33;
    border: 1px solid #fcc;
}

.message.success {
    background: #efe;
    color: #2a7d2e;
    border: 1px solid #cfc;
}

/* Loading */
.loading {
    display: none;
    flex-direction: column;
    align-items: center;
    margin-top: 20px;
    color: #667eea;
}

.loading.active {
    display: flex;
}

.spinner {
    width: 40px;
    height: 40px;
    border: 4px solid #f3f3f3;
    border-top: 4px solid #667eea;
    border-radius: 50%;
    animation: spin 1s linear infinite;
    margin-bottom: 12px;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* Responsive */
@media (max-width: 480px) {
    .auth-box {
        padding: 32px 24px;
    }
    
    .logo h1 {
        font-size: 28px;
    }
    
    input[type="email"],
    input[type="password"],
    input[type="text"] {
        padding: 12px 14px;
    }
}