/* ==========================================
   Make.com-Inspired Login Page Styles
   ========================================== */

/* Import Inter font */
@import url('https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700;800&display=swap');

/* ---- Left Panel (Form Side) ---- */
.login-form-panel {
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 100vh;
    padding: 40px 30px;
    background: #ffffff;
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
}

.auth-full-page-content {
    min-height: 100vh;
}

.login-form-inner {
    width: 100%;
    max-width: 380px;
    margin: 0 auto;
}

/* ---- Header (Back + Title) ---- */
.login-header {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 36px;
}

.back-arrow {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 32px;
    height: 32px;
    border-radius: 50%;
    color: #1a1a2e;
    text-decoration: none;
    transition: all 0.2s ease;
}

.back-arrow:hover {
    background: #f0f0f5;
    color: #1a1a2e;
}

.login-title {
    font-size: 28px;
    font-weight: 700;
    color: #1a1a2e;
    margin: 0;
    letter-spacing: -0.5px;
}

/* ---- Form Styling ---- */
.login-form {
    margin-top: 0;
}

/* Override crispy forms styling */
.login-form label,
.login-form-panel label {
    font-size: 14px;
    font-weight: 500;
    color: #1a1a2e;
    margin-bottom: 6px;
    font-family: 'Inter', sans-serif;
}

.login-form .form-control,
.login-form-panel .form-control {
    height: 48px;
    padding: 12px 16px;
    border: 1.5px solid #d4d4d8;
    border-radius: 8px;
    font-size: 15px;
    font-family: 'Inter', sans-serif;
    color: #1a1a2e;
    background: #ffffff;
    transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.login-form .form-control:focus,
.login-form-panel .form-control:focus {
    border-color: #9333ea;
    box-shadow: 0 0 0 3px rgba(147, 51, 234, 0.1);
    outline: none;
}

.login-form .form-control::placeholder {
    color: #a1a1aa;
}

/* ---- Forgot Password ---- */
.forgot-password-row {
    display: flex;
    justify-content: flex-end;
    margin-top: -4px;
    margin-bottom: 20px;
}

.forgot-password-link {
    font-size: 13px;
    color: #71717a;
    text-decoration: none;
    font-weight: 500;
    transition: color 0.2s ease;
}

.forgot-password-link:hover {
    color: #9333ea;
}

/* ---- Sign In Button (Gradient) ---- */
.btn-signin {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    height: 50px;
    border: none;
    border-radius: 10px;
    background: linear-gradient(135deg, #e91e92, #9333ea);
    color: #ffffff;
    font-size: 16px;
    font-weight: 600;
    font-family: 'Inter', sans-serif;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 4px 15px rgba(147, 51, 234, 0.3);
    letter-spacing: 0.2px;
}

.btn-signin:hover {
    background: linear-gradient(135deg, #d6187f, #7c28c8);
    transform: translateY(-1px);
    box-shadow: 0 6px 20px rgba(147, 51, 234, 0.4);
    color: #ffffff;
}

.btn-signin:active {
    transform: translateY(0);
    box-shadow: 0 2px 10px rgba(147, 51, 234, 0.3);
}

/* ---- Divider ---- */
.login-divider {
    display: flex;
    align-items: center;
    margin: 24px 0;
}

.login-divider::before,
.login-divider::after {
    content: '';
    flex: 1;
    height: 1px;
    background: #e4e4e7;
}

.login-divider span {
    padding: 0 16px;
    color: #a1a1aa;
    font-size: 13px;
    font-weight: 500;
    font-family: 'Inter', sans-serif;
}

/* ---- Social Login Buttons ---- */
.social-login-buttons {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.btn-social-login {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    width: 100%;
    height: 48px;
    border: 1.5px solid #e4e4e7;
    border-radius: 10px;
    background: #ffffff;
    font-size: 14px;
    font-weight: 500;
    color: #1a1a2e;
    text-decoration: none;
    font-family: 'Inter', sans-serif;
    cursor: pointer;
    transition: all 0.2s ease;
}

.btn-social-login:hover {
    background: #f9fafb;
    border-color: #d1d5db;
    transform: translateY(-1px);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.06);
    color: #1a1a2e;
    text-decoration: none;
}

.btn-social-login:active {
    transform: translateY(0);
}

.social-icon {
    width: 20px;
    height: 20px;
    flex-shrink: 0;
}

.social-icon-fb {
    font-size: 20px;
    color: #1877f2;
    flex-shrink: 0;
}

/* ---- Signup Prompt ---- */
.signup-prompt {
    text-align: center;
    margin-top: 28px;
}

.signup-prompt p {
    font-size: 14px;
    color: #71717a;
    margin: 0;
    font-family: 'Inter', sans-serif;
}

.signup-link {
    color: #9333ea;
    font-weight: 600;
    text-decoration: none;
    transition: color 0.2s ease;
}

.signup-link:hover {
    color: #7c28c8;
    text-decoration: underline;
}

/* ---- Footer ---- */
.login-footer {
    text-align: center;
    margin-top: 32px;
    padding-top: 20px;
    border-top: 1px solid #f0f0f5;
}

.login-footer p {
    font-size: 12px;
    color: #a1a1aa;
    margin: 0;
    font-family: 'Inter', sans-serif;
}

/* ---- Alerts Override ---- */
.login-form-panel .alert {
    border-radius: 8px;
    font-size: 13px;
    padding: 10px 16px;
    font-family: 'Inter', sans-serif;
}

/* ---- Override crispy form container spacing ---- */
.login-form-panel .form-group,
.login-form-panel div[id*="div_id_"] {
    margin-bottom: 16px;
}

/* ---- Password field with eye toggle ---- */
.login-form-panel .input-group {
    position: relative;
}

.login-form-panel .input-group .form-control {
    border-radius: 8px !important;
    padding-right: 44px;
}

/* ---- Responsive ---- */
@media (max-width: 767px) {
    .login-form-panel {
        padding: 24px 20px;
    }
    
    .login-title {
        font-size: 24px;
    }
    
    .login-form-inner {
        max-width: 100%;
    }
}

/* ---- Override base template btn styles for login page ---- */
.login-form-panel .btn-primary,
.login-form-panel .btn {
    width: auto;
    height: auto;
    line-height: normal;
    border-radius: 8px;
    display: inline-flex;
}

/* ---- Allauth Crispy Form Specific Styling ---- */

/* "Forgot your password?" link from allauth */
.login-form-panel a[href*="password/reset"],
.login-form-panel .text-muted a,
.login-form-panel .helptext a {
    font-size: 13px;
    color: #71717a;
    text-decoration: none;
    font-weight: 500;
    transition: color 0.2s ease;
}

.login-form-panel a[href*="password/reset"]:hover,
.login-form-panel .text-muted a:hover,
.login-form-panel .helptext a:hover {
    color: #9333ea;
}

/* Remember Me checkbox styling */
.login-form-panel .form-check {
    display: flex;
    align-items: center;
    gap: 8px;
}

.login-form-panel .form-check-input {
    width: 16px;
    height: 16px;
    border: 1.5px solid #d4d4d8;
    border-radius: 4px;
    margin-top: 0;
}

.login-form-panel .form-check-input:checked {
    background-color: #9333ea;
    border-color: #9333ea;
}

.login-form-panel .form-check-label {
    font-size: 14px;
    color: #52525b;
    font-weight: 400;
}

/* Hide allauth help_text if needed */
.login-form-panel .helptext {
    font-size: 12px;
    color: #a1a1aa;
    margin-top: 4px;
}

/* Password input container */
.login-form-panel .input-group-append,
.login-form-panel .input-group-text {
    background: transparent;
    border: none;
    cursor: pointer;
}
