/* Modern Auth System - Clean Light Theme (No Gradients) */
/* Brand Colors: Purple #667eea, Gold #fbbf24 */

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
    background: #ffffff;
    color: #1a202c;
    line-height: 1.6;
}

/* Main Wrapper */
.ma-wrapper {
    display: flex;
    min-height: 100vh;
}

/* Left Panel - Branding */
.ma-brand-panel {
    flex: 1;
    background: #1a202c;
    padding: 60px;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    color: white;
    position: relative;
}

.ma-brand-panel::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: #fbbf24;
}

.ma-brand-content {
    max-width: 500px;
    width: 100%;
    position: relative;
    z-index: 1;
}

.ma-brand-logo {
    font-size: 48px;
    font-weight: 900;
    margin-bottom: 24px;
    color: #fbbf24;
    text-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

.ma-brand-tagline {
    font-size: 20px;
    font-weight: 300;
    margin-bottom: 16px;
    line-height: 1.6;
    color: #e2e8f0;
}

.ma-features {
    margin-top: 48px;
}

.ma-feature-item {
    display: flex;
    align-items: flex-start;
    gap: 16px;
    margin-bottom: 24px;
}

.ma-feature-icon {
    width: 48px;
    height: 48px;
    background: #fbbf24;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 20px;
    flex-shrink: 0;
    color: #1a202c;
}

.ma-feature-text {
    font-size: 15px;
    line-height: 1.5;
}

.ma-feature-text strong {
    display: block;
    margin-bottom: 4px;
}

/* Right Panel - Form */
.ma-form-panel {
    flex: 1;
    padding: 60px;
    display: flex;
    flex-direction: column;
    justify-content: center;
    background: #fafafa;
}

.ma-form-container {
    max-width: 420px;
    width: 100%;
    margin: 0 auto;
}

.ma-form-header {
    margin-bottom: 40px;
}

.ma-form-title {
    font-size: 32px;
    font-weight: 700;
    color: #1a202c;
    margin-bottom: 8px;
}

.ma-form-subtitle {
    font-size: 16px;
    color: #718096;
}

/* Form Elements */
.ma-form {
    width: 100%;
}

.ma-form-group {
    margin-bottom: 24px;
}

.ma-label {
    display: block;
    font-size: 14px;
    font-weight: 600;
    color: #2d3748;
    margin-bottom: 8px;
}

.ma-required {
    color: #ef4444;
}

.ma-input-wrapper {
    position: relative;
    display: flex;
    align-items: center;
}

.ma-input {
    width: 100%;
    padding: 14px 16px !important;
    padding-left: 52px !important;
    border: 2px solid #e2e8f0 !important;
    border-radius: 12px;
    font-size: 15px;
    background: white;
    transition: all 0.3s ease;
    font-family: inherit;
    color: #1a202c;
}

.ma-input:focus {
    outline: none;
    border-color: #fbbf24;
    box-shadow: 0 0 0 4px rgba(251, 191, 36, 0.1);
}

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

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

.ma-input::placeholder {
    color: #a0aec0;
}

.ma-input-icon {
    position: absolute;
    left: 16px;
    color: #a0aec0;
    font-size: 18px;
    pointer-events: none;
}

.ma-password-toggle {
    position: absolute;
    right: 16px;
    background: none;
    border: none;
    color: #a0aec0;
    cursor: pointer;
    padding: 4px 8px;
    transition: color 0.2s ease;
    font-size: 16px;
}

.ma-password-toggle:hover {
    color: #fbbf24;
}

.ma-help-text {
    display: block;
    margin-top: 6px;
    font-size: 13px;
    color: #718096;
}

/* Form Options */
.ma-form-options {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 24px;
}

.ma-checkbox {
    display: flex;
    align-items: center;
    gap: 8px;
    cursor: pointer;
}

.ma-checkbox input[type="checkbox"] {
    width: 18px;
    height: 18px;
    cursor: pointer;
    accent-color: #fbbf24;
}

.ma-checkbox-label {
    font-size: 14px;
    color: #4a5568;
    cursor: pointer;
}

.ma-link {
    font-size: 14px;
    color: #fbbf24;
    text-decoration: none;
    font-weight: 500;
    transition: color 0.2s ease;
}

.ma-link:hover {
    color: #d97706;
    text-decoration: underline;
}

.ma-link-bold {
    font-weight: 600;
}

/* Button */
.ma-btn {
    width: 100%;
    padding: 16px;
    border: none;
    border-radius: 12px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    font-family: inherit;
}

.ma-btn-primary {
    background: #fbbf24;
    color: #1a202c;
    box-shadow: 0 4px 12px rgba(251, 191, 36, 0.3);
    font-weight: 700;
}

.ma-btn-primary:hover {
    background: #f59e0b;
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(251, 191, 36, 0.4);
}

.ma-btn-primary:active {
    transform: translateY(0);
}

.ma-btn.loading {
    pointer-events: none;
    opacity: 0.8;
}

.ma-btn-loading {
    display: none;
}

.ma-btn.loading .ma-btn-text {
    display: none;
}

.ma-btn.loading .ma-btn-loading {
    display: inline-flex;
    align-items: center;
    gap: 8px;
}

.ma-spinner {
    display: inline-block;
    width: 16px;
    height: 16px;
    border: 2px solid rgba(26, 32, 44, 0.3);
    border-top-color: #1a202c;
    border-radius: 50%;
    animation: ma-spin 0.6s linear infinite;
}

@keyframes ma-spin {
    to { transform: rotate(360deg); }
}

/* Form Footer */
.ma-form-footer {
    margin-top: 32px;
    padding-top: 32px;
    border-top: 1px solid #e2e8f0;
    text-align: center;
}

.ma-footer-text {
    font-size: 15px;
    color: #718096;
    margin-right: 4px;
}

/* Alerts */
.ma-alert {
    padding: 14px 16px;
    border-radius: 10px;
    margin-bottom: 24px;
    display: flex;
    align-items: center;
    gap: 12px;
    font-size: 14px;
    font-weight: 500;
}

.ma-alert i {
    font-size: 18px;
}

.ma-alert-error {
    background: #fef2f2;
    color: #991b1b;
    border: 1px solid #fecaca;
}

.ma-alert-success {
    background: #ecfdf5;
    color: #065f46;
    border: 1px solid #a7f3d0;
}

.ma-alert-warning {
    background: #fffbeb;
    color: #92400e;
    border: 1px solid #fde68a;
}

/* Password Strength */
.ma-password-strength {
    margin-top: 8px;
}

.ma-strength-bar {
    height: 4px;
    background: #e2e8f0;
    border-radius: 2px;
    overflow: hidden;
    margin-bottom: 6px;
}

.ma-strength-fill {
    height: 100%;
    width: 0;
    background: #ef4444;
    transition: width 0.3s ease, background-color 0.3s ease;
}

.ma-strength-text {
    display: block;
    font-size: 12px;
    font-weight: 600;
    text-align: right;
}

/* Error Messages */
.ma-error-message {
    display: block;
    margin-top: 6px;
    font-size: 13px;
    color: #ef4444;
    font-weight: 500;
}

/* Animations */
.ma-shake {
    animation: ma-shake 0.5s ease-in-out;
}

@keyframes ma-shake {
    0%, 100% { transform: translateX(0); }
    25% { transform: translateX(-8px); }
    75% { transform: translateX(8px); }
}

/* Responsive Design */
@media (max-width: 1024px) {
    .ma-brand-panel {
        padding: 40px;
    }

    .ma-features {
        display: none;
    }
}

@media (max-width: 768px) {
    .ma-wrapper {
        flex-direction: column;
    }

    .ma-brand-panel {
        padding: 40px 20px;
        min-height: 300px;
    }

    .ma-brand-logo {
        font-size: 36px;
    }

    .ma-brand-tagline {
        font-size: 16px;
    }

    .ma-form-panel {
        padding: 40px 20px;
    }

    .ma-form-title {
        font-size: 28px;
    }
}

@media (max-width: 480px) {
    .ma-brand-panel {
        min-height: 250px;
        padding: 30px 20px;
    }

    .ma-brand-logo {
        font-size: 32px;
    }

    .ma-form-title {
        font-size: 24px;
    }

    .ma-form-panel {
        padding: 30px 20px;
    }

    .ma-form-header {
        margin-bottom: 32px;
    }

    .ma-input {
        padding: 12px 16px !important;
        padding-left: 48px !important;
        font-size: 16px; /* Prevents iOS zoom */
    }
}

/* Focus Visible for Accessibility */
.ma-btn:focus-visible,
.ma-input:focus-visible,
.ma-checkbox input:focus-visible,
.ma-link:focus-visible {
    outline: 2px solid #fbbf24;
    outline-offset: 2px;
}

/* Smooth Transitions */
* {
    transition-property: background-color, border-color, color, fill, stroke, opacity, box-shadow, transform;
    transition-duration: 200ms;
    transition-timing-function: cubic-bezier(0.4, 0, 0.2, 1);
}

button,
a,
input,
select,
textarea {
    transition-property: background-color, border-color, color, fill, stroke, opacity, box-shadow, transform, outline;
}