/* Auth Pages Styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

:root {
    --primary: #8B3A3A;
    --primary-dark: #6d2e2e;
    --text-dark: #212121;
    --text-light: #757575;
    --border: #e0e0e0;
    --bg-light: #f5f5f5;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
    line-height: 1.6;
    color: var(--text-dark);
}

.auth-container {
    display: grid;
    grid-template-columns: 1fr 1fr;
    min-height: 100vh;
}

.auth-left {
    padding: 40px;
    display: flex;
    flex-direction: column;
    background: white;
}

.auth-brand {
    margin-bottom: 40px;
    text-align: center;
}

.auth-brand a {
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 24px 32px;
    background: linear-gradient(135deg, #8B3A3A 0%, #6d2e2e 100%);
    border-radius: 20px;
    box-shadow: 0 4px 20px rgba(139, 58, 58, 0.2);
}

.auth-logo {
    height: 80px;
    width: auto;
    display: block;
}

.auth-logo-text {
    padding: 0;
}

.logo-text-main {
    font-size: 32px;
    font-weight: 700;
    color: white;
    letter-spacing: -0.5px;
}

.auth-content {
    max-width: 450px;
    margin: 0 auto;
    width: 100%;
}

.auth-header {
    margin-bottom: 30px;
}

.auth-header h1 {
    font-size: 32px;
    color: var(--text-dark);
    margin-bottom: 8px;
}

.auth-header p {
    color: var(--text-light);
    font-size: 16px;
}

.user-type-badge {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 12px 20px;
    background: linear-gradient(135deg, #f0f0f0 0%, #e8e8e8 100%);
    border-radius: 12px;
    margin-bottom: 30px;
    font-weight: 600;
    color: var(--text-dark);
}

.user-type-badge.freelancer {
    background: linear-gradient(135deg, #fff3e0 0%, #ffe0b2 100%);
}

.badge-icon {
    font-size: 24px;
}

.auth-form {
    margin-bottom: 30px;
}

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

.form-group label {
    display: block;
    margin-bottom: 8px;
    font-weight: 600;
    color: var(--text-dark);
}

.phone-input {
    display: flex;
    align-items: center;
    border: 2px solid var(--border);
    border-radius: 12px;
    overflow: hidden;
    transition: border-color 0.3s ease;
}

.phone-input:focus-within {
    border-color: var(--primary);
}

.phone-prefix {
    padding: 14px 16px;
    background: var(--bg-light);
    font-weight: 600;
    color: var(--text-dark);
}

.phone-input input {
    flex: 1;
    padding: 14px 16px;
    border: none;
    outline: none;
    font-size: 16px;
}

.form-input {
    width: 100%;
    padding: 14px 16px;
    border: 2px solid var(--border);
    border-radius: 12px;
    font-size: 16px;
    outline: none;
    transition: border-color 0.3s ease;
}

.form-input:focus {
    border-color: var(--primary);
}

.password-input {
    position: relative;
    display: flex;
    align-items: center;
    border: 2px solid var(--border);
    border-radius: 12px;
    overflow: hidden;
    transition: border-color 0.3s ease;
}

.password-input:focus-within {
    border-color: var(--primary);
}

.password-input input {
    flex: 1;
    padding: 14px 16px;
    border: none;
    outline: none;
    font-size: 16px;
}

.password-toggle {
    background: none;
    border: none;
    padding: 14px 16px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: opacity 0.3s ease;
}

.password-toggle:hover {
    opacity: 0.7;
}

.eye-icon {
    font-size: 20px;
}

.form-footer {
    display: flex;
    justify-content: flex-end;
    margin-bottom: 20px;
}

.forgot-password {
    color: var(--primary);
    text-decoration: none;
    font-size: 14px;
    font-weight: 600;
}

.forgot-password:hover {
    text-decoration: underline;
}

.btn-primary {
    background: var(--primary);
    color: white;
    border: none;
    padding: 14px 28px;
    border-radius: 12px;
    font-weight: 600;
    font-size: 16px;
    cursor: pointer;
    transition: all 0.3s ease;
    display: inline-flex;
    align-items: center;
    gap: 8px;
}

.btn-primary:hover {
    background: var(--primary-dark);
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(139, 58, 58, 0.3);
}

.btn-large {
    padding: 16px 32px;
    font-size: 18px;
}

.btn-full {
    width: 100%;
    justify-content: center;
}

.btn-icon {
    font-size: 20px;
}

.btn-google {
    background: white;
    color: var(--text-dark);
    border: 2px solid var(--border);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
    font-weight: 600;
    transition: all 0.3s ease;
}

.btn-google:hover {
    background: var(--bg-light);
    border-color: var(--text-light);
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

.btn-google svg {
    flex-shrink: 0;
}

.auth-divider {
    text-align: center;
    margin: 30px 0;
    position: relative;
}

.auth-divider::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 0;
    right: 0;
    height: 1px;
    background: var(--border);
}

.auth-divider span {
    background: white;
    padding: 0 15px;
    position: relative;
    color: var(--text-light);
    font-size: 14px;
}

.auth-links {
    text-align: center;
}

.auth-links p {
    margin: 10px 0;
    color: var(--text-light);
}

.auth-links a {
    color: var(--primary);
    text-decoration: none;
    font-weight: 600;
}

.auth-links a:hover {
    text-decoration: underline;
}

.test-info {
    margin-top: 30px;
    padding: 20px;
    background: linear-gradient(135deg, #e3f2fd 0%, #bbdefb 100%);
    border-radius: 12px;
    border-left: 4px solid #2196F3;
}

.test-info p {
    margin: 5px 0;
    color: #1565C0;
    font-size: 14px;
}

.test-info strong {
    color: #0d47a1;
    font-size: 15px;
}

.app-download-prompt {
    margin-top: 40px;
    padding: 20px;
    background: var(--bg-light);
    border-radius: 12px;
    text-align: center;
}

.app-download-prompt p {
    margin-bottom: 15px;
    font-weight: 600;
    color: var(--text-dark);
}

.store-badges {
    display: flex;
    gap: 10px;
    justify-content: center;
}

.store-badges a {
    display: block;
}

.store-badges img {
    height: 40px;
    width: auto;
}

.auth-right {
    background: linear-gradient(135deg, var(--primary) 0%, var(--primary-dark) 100%);
    padding: 60px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
}

.auth-right.freelancer-bg {
    background: linear-gradient(135deg, #FF8F00 0%, #F57C00 100%);
}

.auth-illustration {
    max-width: 500px;
}

.auth-illustration h2 {
    font-size: 36px;
    margin-bottom: 16px;
}

.auth-illustration p {
    font-size: 18px;
    margin-bottom: 30px;
    opacity: 0.9;
}

.feature-list {
    list-style: none;
}

.feature-list li {
    padding: 12px 0;
    font-size: 18px;
    opacity: 0.95;
}

/* Responsive */
@media (max-width: 968px) {
    .auth-container {
        grid-template-columns: 1fr;
    }

    .auth-right {
        display: none;
    }

    .auth-left {
        padding: 20px;
    }

    .auth-content {
        max-width: 100%;
    }
}

@media (max-width: 480px) {
    .auth-header h1 {
        font-size: 24px;
    }

    .auth-illustration h2 {
        font-size: 28px;
    }
}

/* Modal Styles */
.modal {
    display: none;
    position: fixed;
    z-index: 1000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.5);
    animation: fadeIn 0.3s ease;
}

.modal.show {
    display: flex;
    align-items: center;
    justify-content: center;
}

.modal-content {
    background: white;
    border-radius: 16px;
    max-width: 500px;
    width: 90%;
    max-height: 90vh;
    overflow-y: auto;
    animation: slideUp 0.3s ease;
}

.modal-header {
    padding: 24px;
    border-bottom: 1px solid var(--border);
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.modal-header h2 {
    margin: 0;
    font-size: 24px;
    color: var(--text-dark);
}

.modal-close {
    background: none;
    border: none;
    font-size: 32px;
    color: var(--text-light);
    cursor: pointer;
    padding: 0;
    width: 32px;
    height: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: color 0.3s ease;
}

.modal-close:hover {
    color: var(--text-dark);
}

.modal-body {
    padding: 24px;
}

.modal-body p {
    margin-bottom: 20px;
    color: var(--text-light);
}

.sms-code-input {
    display: flex;
    gap: 10px;
    justify-content: center;
    margin-bottom: 20px;
}

.code-digit {
    width: 50px;
    height: 60px;
    text-align: center;
    font-size: 24px;
    font-weight: 600;
    border: 2px solid var(--border);
    border-radius: 12px;
    outline: none;
    transition: border-color 0.3s ease;
}

.code-digit:focus {
    border-color: var(--primary);
}

.error-message {
    color: #d32f2f;
    font-size: 14px;
    margin-bottom: 15px;
    padding: 10px;
    background: #ffebee;
    border-radius: 8px;
    display: none;
}

.error-message.show {
    display: block;
}

.btn-secondary {
    background: var(--bg-light);
    color: var(--text-dark);
    border: 2px solid var(--border);
}

.btn-secondary:hover {
    background: #e0e0e0;
    transform: translateY(-2px);
}

/* Loading Overlay */
.loading-overlay {
    display: none;
    position: fixed;
    z-index: 2000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.7);
    align-items: center;
    justify-content: center;
    flex-direction: column;
}

.loading-overlay.show {
    display: flex;
}

.loading-spinner {
    width: 50px;
    height: 50px;
    border: 4px solid rgba(255, 255, 255, 0.3);
    border-top-color: white;
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

.loading-overlay p {
    color: white;
    margin-top: 20px;
    font-size: 16px;
}

@keyframes fadeIn {
    from {
        opacity: 0;
    }
    to {
        opacity: 1;
    }
}

@keyframes slideUp {
    from {
        transform: translateY(50px);
        opacity: 0;
    }
    to {
        transform: translateY(0);
        opacity: 1;
    }
}

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

#recaptcha-container {
    display: none;
}
