/* Popup Login Styles */
.popup-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.7);
    backdrop-filter: blur(5px);
    z-index: 9999;
    display: none;
    align-items: center;
    justify-content: center;
    padding: 20px;
    animation: fadeIn 0.3s ease;
}

.popup-overlay.active {
    display: flex;
}

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

.popup-login {
    background: white;
    border-radius: 20px;
    max-width: 500px;
    width: 100%;
    max-height: 90vh;
    overflow: hidden;
    position: relative;
    animation: slideUp 0.3s ease;
    box-shadow: 0 25px 50px rgba(0, 0, 0, 0.3);
}

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

.popup-header {
    background: linear-gradient(135deg, #10b981 0%, #059669 100%);
    color: white;
    padding: 30px;
    position: relative;
    text-align: center;
}

.popup-header h2 {
    font-size: 2rem;
    font-weight: 700;
    margin-bottom: 10px;
}

.popup-header p {
    font-size: 1.1rem;
    opacity: 0.9;
    margin-bottom: 0;
}

.close-popup {
    position: absolute;
    top: 20px;
    right: 20px;
    background: rgba(255, 255, 255, 0.2);
    border: none;
    color: white;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.2rem;
    transition: all 0.3s ease;
}

.close-popup:hover {
    background: rgba(255, 255, 255, 0.3);
    transform: rotate(90deg);
}

.popup-body {
    padding: 40px;
    max-height: calc(90vh - 200px);
    overflow-y: auto;
}

.popup-form-group {
    margin-bottom: 25px;
}

.popup-form-label {
    display: block;
    margin-bottom: 10px;
    font-weight: 600;
    color: #374151;
    font-size: 0.95rem;
}

.required {
    color: #ef4444;
}

.popup-form-control {
    width: 100%;
    padding: 14px 16px;
    border: 2px solid #e5e7eb;
    border-radius: 12px;
    font-size: 1rem;
    transition: all 0.3s ease;
    background: #f9fafb;
}

.popup-form-control:focus {
    outline: none;
    border-color: #10b981;
    background: white;
    box-shadow: 0 0 0 3px rgba(16, 185, 129, 0.1);
}

.popup-input-group {
    position: relative;
}

.popup-input-group i {
    position: absolute;
    left: 16px;
    top: 50%;
    transform: translateY(-50%);
    color: #6b7280;
    font-size: 1.1rem;
    z-index: 2;
}

.popup-input-group .popup-form-control {
    padding-left: 45px;
}

.popup-remember-forgot {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 25px;
}

.popup-form-check {
    display: flex;
    align-items: center;
    gap: 8px;
}

.popup-form-check-input {
    width: 18px;
    height: 18px;
    cursor: pointer;
}

.popup-form-check-label {
    font-size: 0.9rem;
    color: #6b7280;
    cursor: pointer;
}

.popup-forgot-link {
    color: #10b981;
    text-decoration: none;
    font-size: 0.9rem;
    font-weight: 500;
    transition: color 0.3s ease;
}

.popup-forgot-link:hover {
    color: #059669;
    text-decoration: underline;
}

.popup-btn {
    padding: 14px 24px;
    border: none;
    border-radius: 12px;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    width: 100%;
}

.popup-btn-login {
    background: linear-gradient(135deg, #10b981 0%, #059669 100%);
    color: white;
    font-size: 1.1rem;
}

.popup-btn-login:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 25px rgba(16, 185, 129, 0.3);
}

.popup-btn-login.loading {
    color: transparent;
    position: relative;
}

.popup-btn-login.loading::after {
    content: '';
    position: absolute;
    width: 20px;
    height: 20px;
    top: 50%;
    left: 50%;
    margin-left: -10px;
    margin-top: -10px;
    border: 2px solid #ffffff;
    border-radius: 50%;
    border-top-color: transparent;
    animation: spinner 0.8s linear infinite;
}

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

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

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

.popup-divider span {
    background: white;
    padding: 0 20px;
    color: #6b7280;
    font-size: 0.9rem;
    position: relative;
}

.popup-social-login {
    display: flex;
    gap: 15px;
    margin-bottom: 30px;
}

.popup-social-btn {
    flex: 1;
    padding: 12px;
    border: 2px solid #e5e7eb;
    border-radius: 10px;
    background: white;
    color: #6b7280;
    text-decoration: none;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    font-size: 0.9rem;
    font-weight: 500;
    transition: all 0.3s ease;
}

.popup-social-btn:hover {
    border-color: #10b981;
    color: #10b981;
    transform: translateY(-2px);
}

.popup-footer {
    text-align: center;
    padding-top: 20px;
    border-top: 1px solid #e5e7eb;
}

.popup-footer p {
    color: #6b7280;
    margin-bottom: 0;
}

.popup-footer a {
    color: #10b981;
    text-decoration: none;
    font-weight: 600;
}

.popup-footer a:hover {
    text-decoration: underline;
}

.popup-message {
    padding: 12px 16px;
    border-radius: 8px;
    margin-bottom: 20px;
    display: flex;
    align-items: center;
    gap: 10px;
}

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

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

/* Mobile Responsive */
@media (max-width: 768px) {
    .popup-overlay {
        padding: 10px;
    }
    
    .popup-login {
        max-height: 95vh;
    }
    
    .popup-header {
        padding: 25px 20px;
    }
    
    .popup-header h2 {
        font-size: 1.5rem;
    }
    
    .popup-body {
        padding: 30px 25px;
        max-height: calc(95vh - 150px);
    }
    
    .popup-social-login {
        flex-direction: column;
    }
    
    .close-popup {
        width: 35px;
        height: 35px;
        font-size: 1rem;
    }
}

/* Trigger Button Styles */
.login-trigger {
    background: linear-gradient(135deg, #10b981 0%, #059669 100%);
    color: white;
    padding: 12px 24px;
    border: none;
    border-radius: 10px;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    gap: 8px;
}

.login-trigger:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 25px rgba(16, 185, 129, 0.3);
    color: white;
    text-decoration: none;
}

.login-trigger i {
    font-size: 1.1rem;
}
