/* Auth Container */
.auth-container {
    min-height: calc(100vh - 87px);
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 2rem;
    margin-top: 87px;
    background: linear-gradient(135deg, rgba(255, 240, 240, 0.103) 0%, rgba(255, 240, 240, 0.1) 50%, rgba(255, 240, 240, 0.034) 100%);
    position: relative;
    overflow: hidden;
}

/* Decorative Elements */
.auth-container::before {
    content: '';
    position: absolute;
    top: -50px;
    right: -50px;
    width: 200px;
    height: 200px;
    background: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" fill="%23FFE5E5"><path d="M12 2C6.48 2 2 6.48 2 12s4.48 10 10 10 10-4.48 10-10S17.52 2 12 2zm0 18c-4.41 0-8-3.59-8-8s3.59-8 8-8 8 3.59 8 8-3.59 8-8 8z"/></svg>') no-repeat;
    background-size: contain;
    opacity: 0.5;
    z-index: 0;
}

.auth-container::after {
    content: '';
    position: absolute;
    bottom: -50px;
    left: -50px;
    width: 200px;
    height: 200px;
    background: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" fill="%23FFE5E5"><path d="M12 2C6.48 2 2 6.48 2 12s4.48 10 10 10 10-4.48 10-10S17.52 2 12 2zm0 18c-4.41 0-8-3.59-8-8s3.59-8 8-8 8 3.59 8 8-3.59 8-8 8z"/></svg>') no-repeat;
    background-size: contain;
    opacity: 0.5;
    z-index: 0;
}

.auth-card {
    background: var(--white);
    padding: 3rem;
    border-radius: 20px;
    box-shadow: 0 8px 30px rgba(0, 0, 0, 0.1);
    width: 100%;
    max-width: 800px;
    position: relative;
    z-index: 1;
}

.auth-card h2 {
    font-family: var(--heading-font);
    font-size: 2.5rem;
    color: var(--deep-slate-gray);
    margin-bottom: 1rem;
    text-align: center;
}

.auth-subtitle {
    color: var(--deep-slate-gray);
    text-align: center;
    margin-bottom: 2rem;
    font-size: 1.1rem;
    opacity: 0.8;
}

/* Form Layout */
.auth-form {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.form-row {
    display: flex;
    gap: 1rem;
}

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

.form-group label {
    color: var(--deep-slate-gray);
    font-weight: 500;
}

.form-group input,
.form-group select {
    padding: 0.8rem 1rem;
    border: 1px solid #ddd;
    border-radius: 8px;
    font-size: 1rem;
    transition: border-color 0.3s ease;
}

.form-group input:focus,
.form-group select:focus {
    border-color: var(--deep-slate-gray);
    outline: none;
}

/* Phone Input Group */
.phone-input-group {
    display: flex;
    gap: 10px;
    align-items: center;
}

.phone-input-group .phone-code {
    width: 60px;
    padding: 8px;
    border: 1px solid #E5E7EB;
    border-radius: 8px;
    font-family: 'Poppins', sans-serif;
    font-size: 14px;
    color: #1D1D20;
    text-align: center;
}

.phone-input-group input[type="tel"] {
    flex: 1;
}

/* Password Requirements */
.password-requirements {
    background: #f8f8f8;
    padding: 1rem;
    border-radius: 8px;
    margin-top: 0.5rem;
}

.password-requirements p {
    color: var(--deep-slate-gray);
    font-weight: 500;
    margin-bottom: 0.5rem;
}

.password-requirements ul {
    list-style: none;
    padding-left: 0;
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 0.5rem;
}

.password-requirements li {
    color: var(--deep-slate-gray);
    font-size: 0.9rem;
    margin-bottom: 0.3rem;
    opacity: 0.8;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.password-requirements li::before {
    content: '✕';
    color: #ff4444;
    font-size: 1rem;
}

.password-requirements li.met::before {
    content: '✓';
    color: #4CAF50;
}

.password-requirements li.unmet::before {
    content: '✕';
    color: #ff4444;
}

/* Terms Group */
.terms-group {
    margin: 1rem 0;
}

.terms {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    cursor: pointer;
}

.terms span {
    color: var(--deep-slate-gray);
    font-size: 0.9rem;
}

.terms a {
    color: var(--deep-slate-gray);
    text-decoration: underline;
}

.terms-error {
    color: #ff4444;
    font-size: 0.9rem;
    margin-top: 0.5rem;
}

/* Auth Button */
.auth-btn {
    background: var(--deep-slate-gray);
    color: var(--white);
    padding: 1rem;
    border: none;
    border-radius: 8px;
    font-size: 1rem;
    cursor: pointer;
    transition: background-color 0.3s ease;
    margin-top: 1rem;
}

.auth-btn:hover {
    background: #2a3b4d;
}

/* Auth Switch */
.auth-switch {
    text-align: center;
    margin-top: 2rem;
    color: var(--deep-slate-gray);
}

.auth-switch a {
    color: var(--deep-slate-gray);
    text-decoration: underline;
    font-weight: 500;
}

/* Loader */
.loader-container {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(255, 255, 255, 0.8);
    display: none;
    justify-content: center;
    align-items: center;
    z-index: 9999;
}

.loader {
    width: 40px;
    height: 40px;
    border: 3px solid var(--blush-rose);
    border-top: 3px solid var(--deep-slate-gray);
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* Error Message */
.error-message {
    color: #ff4444;
    font-size: 0.9rem;
    margin-top: 0.3rem;
}

/* Responsive Design */
@media (max-width: 768px) {
    .auth-container {
        padding: 1rem;
    }

    .auth-card {
        padding: 2rem;
        max-width: 600px;
    }

    .auth-card h2 {
        font-size: 2rem;
    }

    .form-row {
        flex-direction: column;
        gap: 1.5rem;
    }

    .password-requirements ul {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 480px) {
    .auth-card {
        padding: 1.5rem;
        max-width: 100%;
    }

    .auth-card h2 {
        font-size: 1.8rem;
    }

    .form-group input,
    .form-group select {
        padding: 0.7rem;
    }
}

/* User Profile Styles */
.user-profile {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.user-name {
    font-weight: 500;
    color: #333;
}

.logout-btn {
    background: none;
    border: 1px solid #ddd;
    padding: 0.5rem 1rem;
    border-radius: 4px;
    cursor: pointer;
    transition: all 0.3s ease;
}

.logout-btn:hover {
    background-color: #f5f5f5;
    border-color: #ccc;
}

/* Loading state for buttons */
.auth-btn.loading {
    position: relative;
    color: transparent;
}

.auth-btn.loading::after {
    content: '';
    position: absolute;
    width: 20px;
    height: 20px;
    top: 50%;
    left: 50%;
    margin: -10px 0 0 -10px;
    border: 2px solid #fff;
    border-top: 2px solid transparent;
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

/* Disable form during loading */
.auth-form.loading {
    pointer-events: none;
    opacity: 0.7;
}