/* Agent Portal Styles */
body.agent-portal {
    background-color: var(--bg-secondary);
    display: flex;
    flex-direction: column;
    min-height: 100vh;
}

.agent-container {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 40px 20px;
}

.agent-wrapper {
    width: 100%;
    max-width: 1200px;
    min-height: 600px;

    /* Flexbox center fix */
    display: flex;
    align-items: center;
    justify-content: center;
}

.agent-wrapper .alert {
    align-items: center;
    justify-content: center;
    width: 100%;
    max-width: 500px;
    z-index:11;
    position:absolute;
    bottom:19%;
    padding:5px;
}

.agent-wrapper .alert.alert-danger {
    color:red;
    text-align:center;
    border:1px red solid;
    border-radius:8px;
}

.agent-wrapper .alert.alert-success {
    color:green;
    text-align:center;
    border:1px green solid;
    border-radius:8px;
}

.agent-form-container {
    background: var(--bg-color);
    border-radius: 15px;
    box-shadow: var(--shadow);
    padding: 40px;
    width: 100%;
    max-width: 500px;

    /* Removed absolute positioning */
}

.form-header {
    text-align: center;
    margin-bottom: 30px;
}

.form-header .form-logo {
    height: 60px;
    margin-bottom: 20px;
}

.form-header h2 {
    color: var(--primary-color);
    margin-bottom: 10px;
    font-size: 1.8rem;
}

.form-header p {
    color: var(--text-light);
    font-size: 1rem;
}

.agent-form .form-group {
    margin-bottom: 20px;
}

.agent-form .form-row {
    display: flex;
    gap: 15px;
}

.agent-form .form-row .form-group {
    flex: 1;
    margin-bottom: 15px;
}

.agent-form .input-with-icon {
    position: relative;
}

.agent-form .input-with-icon i {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    left: 15px;
    color: var(--primary-color);
}

.agent-form input {
    width: 100%;
    padding: 12px 15px 12px 45px;
    border: 1px solid var(--border-color);
    border-radius: 8px;
    font-size: 1rem;
    background-color: var(--bg-color);
    color: var(--text-color);
    transition: var(--transition);
}

body[dir="rtl"] .agent-form input {
    padding: 12px 45px 12px 15px;
}

body[dir="rtl"] .agent-form .input-with-icon i {
    left: auto;
    right: 15px;
}

.agent-form input:focus {
    border-color: var(--primary-color);
    box-shadow: 0 0 0 3px rgba(52, 152, 219, 0.2);
    outline: none;
}

.form-options {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
}

.remember-me {
    display: flex;
    align-items: center;
    cursor: pointer;
    color: var(--text-light);
    font-size: 0.9rem;
}

.remember-me input {
    width: auto;
    margin-right: 8px;
}

.forgot-password {
    color: var(--primary-color);
    text-decoration: none;
    font-size: 0.9rem;
    transition: var(--transition);
}

.forgot-password:hover {
    text-decoration: underline;
}

.agent-form .btn-primary {
    width: 100%;
    padding: 14px;
    font-size: 1rem;
    font-weight: 600;
    margin-top: 10px;
    border-radius: 8px;
}

.form-footer {
    text-align: center;
    margin-top: 25px;
    color: var(--text-light);
    font-size: 0.95rem;
}

.form-footer a {
    color: var(--primary-color);
    text-decoration: none;
    transition: var(--transition);
}

.form-footer a:hover {
    text-decoration: underline;
}

.terms-group {
    margin: 20px 0;
}

.terms-checkbox {
    display: flex;
    align-items: center;
    color: var(--text-light);
    font-size: 0.9rem;
    cursor: pointer;
}

.terms-checkbox input {
    width: auto;
    margin-right: 8px;
}

.terms-checkbox a {
    color: var(--primary-color);
    text-decoration: none;
}

.terms-checkbox a:hover {
    text-decoration: underline;
}

.agent-footer {
    margin-top: auto;
    background: var(--dark-color);
}

/* Animation classes */
.animate__fadeOutLeft {
    animation-name: fadeOutLeft;
}

.animate__fadeOutRight {
    animation-name: fadeOutRight;
}

@keyframes fadeOutLeft {
    from {
        opacity: 1;
        transform: translateX(0) translateY(0) translateZ(0);
    }
    to {
        opacity: 0;
        transform: translate3d(-100%, 0, 0);
    }
}

@keyframes fadeOutRight {
    from {
        opacity: 1;
        transform: translateX(0) translateY(0) translateZ(0);
    }
    to {
        opacity: 0;
        transform: translate3d(100%, 0, 0);
    }
}

/* Responsive Styles */
@media (max-width: 768px) {
    .agent-form-container {
        padding: 30px 20px;
    }

    .agent-form .form-row {
        flex-direction: column;
        gap: 0;
    }
}

@media (max-width: 576px) {
    .agent-container {
        padding: 20px 15px;
    }

    .form-header .form-logo {
        height: 50px;
    }

    .form-header h2 {
        font-size: 1.5rem;
    }

    .form-options {
        flex-direction: column;
        align-items: flex-start;
        gap: 10px;
    }

    .forgot-password {
        margin-left: 0;
    }
}

/* Simple Footer Styles */
.simple-footer {
    background: var(--dark-color);
    padding: 20px 0;
    margin-top: auto;
}

.simple-footer .footer-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.simple-footer .back-to-site {
    color: #fff;
    text-decoration: none;
    display: flex;
    align-items: center;
    gap: 8px;
    transition: var(--transition);
}

.simple-footer .back-to-site:hover {
    color: var(--primary-color);
}

.simple-footer .back-to-site i {
    font-size: 0.9rem;
}

.simple-footer .language-switcher select {
    padding: 8px 15px;
    border-radius: 5px;
    border: 1px solid var(--border-color);
    background: var(--bg-color);
    color: var(--text-color);
    cursor: pointer;
}

/* RTL adjustments */
body[dir="rtl"] .simple-footer .back-to-site i {
    transform: rotate(180deg);
}

@media (max-width: 576px) {
    .simple-footer .footer-content {
        flex-direction: column;
        gap: 15px;
    }
}