/* ============================================
   AUTH PAGES - SHARED CSS (Login & Register)
   ============================================ */

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

body {
    background: #f8f9fa;
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
    padding: 1rem;
}

.auth-container {
    width: 100%;
    max-width: 448px;
}

/* Card */
.auth-card {
    background: white;
    border-radius: 1rem;
    box-shadow: 0 2px 12px rgba(0, 0, 0, 0.08);
    padding: 2rem;
    text-align: center;
}

/* Logo and Header inside Card */
.logo-wrapper {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.2rem;
    margin-bottom: 0.2rem;
}

.logo-wrapper img {
    max-width: 300px;
    height: auto;
}

.brand-name {
    font-size: 1.5rem;
    font-weight: 700;
    color: #111827;
}

.welcome-title {
    font-size: 1.875rem;
    font-weight: 700;
    color: #111827;
    margin-bottom: 0.5rem;
    line-height: 1.2;
    text-align: center;
}

.welcome-subtitle {
    color: #6b7280;
    font-size: 1rem;
    line-height: 1.5;
    margin-bottom: 1.5rem;
    text-align: center;
}

/* Invitation Badge */
.invitation-badge {
    background: linear-gradient(135deg, #ec4899 0%, #8b5cf6 100%);
    color: white;
    padding: 16px;
    border-radius: 12px;
    margin-bottom: 24px;
    text-align: center;
}

.invitation-badge strong {
    display: block;
    font-size: 16px;
    margin-bottom: 4px;
}

.invitation-badge small {
    font-size: 13px;
    opacity: 0.9;
}

.role-badge {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    padding: 4px 10px;
    background: rgba(255, 255, 255, 0.2);
    border-radius: 6px;
    font-size: 13px;
    margin-top: 8px;
}

/* Form */
.form-group {
    margin-bottom: 1.25rem;
    text-align: left;
}

label {
    display: block;
    font-size: 0.875rem;
    font-weight: 600;
    color: #374151;
    margin-bottom: 0.5rem;
}

.input-wrapper {
    position: relative;
}

.form-control {
    width: 100%;
    height: 48px;
    padding: 0.75rem 1rem;
    border: 2px solid #e5e7eb;
    border-radius: 0.5rem;
    font-size: 1rem;
    transition: all 0.2s;
    outline: none;
}

.form-control:focus {
    border-color: #F2A3B9;
    box-shadow: 0 0 0 3px rgba(242, 163, 185, 0.1);
}

.form-control.error {
    border-color: #ef4444;
}

.form-control.error:focus {
    box-shadow: 0 0 0 3px rgba(239, 68, 68, 0.1);
}

.password-input {
    padding-right: 3rem;
}

.password-toggle {
    position: absolute;
    right: 0.75rem;
    top: 50%;
    transform: translateY(-50%);
    background: none;
    border: none;
    cursor: pointer;
    color: #6b7280;
    padding: 0.25rem;
    transition: color 0.2s;
}

.password-toggle:hover {
    color: #374151;
}

.password-toggle svg {
    width: 20px;
    height: 20px;
}

.form-hint {
    font-size: 0.875rem;
    color: #6b7280;
    margin-top: 0.5rem;
}

.error-message {
    display: flex;
    align-items: center;
    gap: 0.25rem;
    color: #ef4444;
    font-size: 0.875rem;
    margin-top: 0.5rem;
}

/* Remember & Forgot */
.form-footer {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 1.25rem;
    padding-top: 0.25rem;
    text-align: left;
}

.remember-wrapper {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.checkbox {
    width: 1rem;
    height: 1rem;
    border: 2px solid #d1d5db;
    border-radius: 0.25rem;
    cursor: pointer;
    accent-color: #F2A3B9;
}

.remember-label {
    font-size: 0.875rem;
    font-weight: 500;
    color: #374151;
    cursor: pointer;
    margin: 0;
}

.forgot-link {
    font-size: 0.875rem;
    font-weight: 600;
    color: #e91e8c;
    text-decoration: none;
    transition: color 0.2s;
}

.forgot-link:hover {
    color: #d01a7d;
}

/* Buttons */
.btn {
    width: 100%;
    height: 48px;
    border: none;
    border-radius: 0.5rem;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
}

.btn-primary {
    background: linear-gradient(135deg, #F2A3B9 0%, #7BE1F5 100%);
    color: white;
}

.btn-primary:hover:not(:disabled) {
    transform: translateY(-2px);
    box-shadow: 0 8px 16px rgba(242, 163, 185, 0.3);
}

.btn-primary:disabled {
    opacity: 0.6;
    cursor: not-allowed;
}

.btn-secondary {
    background: white;
    border: 2px solid #e5e7eb;
    color: #374151;
}

.btn-secondary:hover:not(:disabled) {
    background: #f9fafb;
}

/* Divider */
.divider {
    position: relative;
    text-align: center;
    margin: 1.5rem 0;
}

.divider::before {
    content: '';
    position: absolute;
    left: 0;
    right: 0;
    top: 50%;
    height: 1px;
    background: #e5e7eb;
}

.divider span {
    position: relative;
    background: white;
    padding: 0 1rem;
    color: #6b7280;
    font-size: 0.875rem;
    font-weight: 500;
}

/* Social Buttons */
.social-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 0.75rem;
    margin-bottom: 1.5rem;
}

.social-btn {
    height: 44px;
    background: transparent;
}

.social-btn svg {
    width: 20px;
    height: 20px;
}

/* Sign Up / Login Links */
.signup-section,
.login-section {
    text-align: center;
}

.signup-text,
.login-text {
    font-size: 0.875rem;
    color: #6b7280;
}

.signup-link,
.login-link {
    font-weight: 600;
    color: #e91e8c;
    text-decoration: none;
    transition: color 0.2s;
}

.signup-link:hover,
.login-link:hover {
    color: #d01a7d;
}

/* Security Notice */
.security-notice {
    text-align: center;
    font-size: 0.75rem;
    color: #9ca3af;
    margin-top: 1.5rem;
}

/* Alert */
.alert {
    padding: 0.75rem 1rem;
    border-radius: 0.5rem;
    margin-bottom: 1.25rem;
    font-size: 0.875rem;
    display: none;
}

.alert-danger {
    background: #fee2e2;
    color: #991b1b;
    border: 1px solid #fecaca;
}

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

/* Spinner */
.spinner {
    width: 1rem;
    height: 1rem;
    border: 2px solid rgba(255, 255, 255, 0.3);
    border-top-color: white;
    border-radius: 50%;
    animation: spin 0.6s linear infinite;
}

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

/* Responsive */
@media (max-width: 480px) {
    .auth-card {
        padding: 1.5rem;
    }
    
    .welcome-title {
        font-size: 1.5rem;
    }
    
    .social-grid {
        grid-template-columns: 1fr;
    }
}