/* Auth Widget Styles - Base and Structural */
.al3ode-auth-wrapper {
    max-width: 450px;
    margin: 0 auto;
    background: #000;
    border-radius: 20px;
    padding: 40px;
    color: #fff;
    font-family: 'Tajawal', sans-serif;
    box-shadow: 0 15px 35px rgba(0, 0, 0, 0.5);
    direction: rtl;
    position: relative;
    z-index: 1;
    overflow: hidden;
    /* Ensure border radius works with pseudo-element if needed */
}

.al3ode-auth-message {
    padding: 12px;
    border-radius: 10px;
    margin-bottom: 20px;
    text-align: center;
    font-size: 14px;
}

.al3ode-auth-message.error {
    background: rgba(255, 0, 0, 0.1);
    border: 1px solid rgba(255, 0, 0, 0.2);
    color: #ff4d4d;
}

.al3ode-auth-message.success {
    background: rgba(0, 255, 0, 0.1);
    border: 1px solid rgba(0, 255, 0, 0.2);
    color: #2ed573;
}


.al3ode-auth-wrapper::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 3px;
    background: linear-gradient(270deg, rgba(184, 134, 11, 0) 0%, #B8860B 50%, rgba(184, 134, 11, 0) 100%);
    z-index: 2;
}

.al3ode-auth-header {
    text-align: center;
    margin-bottom: 30px;
}

.al3ode-auth-brand {
    font-size: 32px;
    font-weight: 800;
    color: #c18e1d;
    letter-spacing: 2px;
    margin: 0 0 5px 0;
}

.al3ode-auth-subtitle {
    font-size: 16px;
    color: #e0e0e0;
    margin: 0;
}

.al3ode-auth-form-group {
    margin-bottom: 20px;
    position: relative;
    text-align: right;
}

.al3ode-auth-form-group label {
    display: block;
    margin-bottom: 8px;
    font-size: 14px;
    color: #c18e1d;
    font-weight: 500;
}

.al3ode-auth-input-wrapper {
    position: relative;
}

.al3ode-auth-input-wrapper .al3ode-svg-icon {
    position: absolute;
    left: 15px;
    top: 50%;
    transform: translateY(-50%);
    color: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
    pointer-events: none;
    z-index: 2;
}

.al3ode-auth-input-wrapper .al3ode-svg-icon svg {
    width: 18px;
    height: 18px;
    fill: none;
    stroke: currentColor;
}

.al3ode-auth-input-wrapper input {
    width: 100%;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 30px;
    padding: 12px 15px 12px 45px;
    color: #fff;
    font-size: 14px;
    outline: none;
    transition: all 0.3s ease;
    font-family: 'Tajawal', sans-serif;
    position: relative;
    z-index: 1;
}

.al3ode-auth-input-wrapper input:focus {
    border-color: #c18e1d;
    background: rgba(255, 255, 255, 0.1);
}

.al3ode-pass-toggle {
    position: absolute;
    right: 15px;
    top: 50%;
    transform: translateY(-50%);
    cursor: pointer;
    color: #a8a8a8;
    z-index: 5;
    display: flex;
    align-items: center;
    transition: color 0.3s ease;
}

.al3ode-pass-toggle:hover {
    color: #c18e1d;
}

.al3ode-pass-toggle svg {
    width: 16px;
    height: 16px;
}


.al3ode-auth-forgot-pass {
    position: absolute;
    left: 0;
    top: 0;
    font-size: 12px;
    color: #777;
    text-decoration: none;
    transition: color 0.3s ease;
    z-index: 5;
}

.al3ode-auth-forgot-pass:hover {
    color: #c18e1d;
}

.al3ode-auth-options {
    display: flex;
    justify-content: flex-start;
    align-items: center;
    margin-bottom: 25px;
}

.al3ode-auth-remember {
    display: flex;
    align-items: center;
    gap: 8px;
    cursor: pointer;
    font-size: 14px;
    color: #a8a8a8;
}

.al3ode-auth-remember input {
    width: 16px;
    height: 16px;
    accent-color: #c18e1d;
}

.al3ode-auth-submit-btn {
    width: 100%;
    background: #c18e1d;
    color: #000;
    border: none;
    border-radius: 30px;
    padding: 15px;
    font-size: 18px;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.3s ease;
    margin-bottom: 25px;
    font-family: 'Tajawal', sans-serif;
    box-shadow: 0 5px 15px rgba(193, 142, 29, 0.3);
}

.al3ode-auth-submit-btn:hover {
    background: #d4a02d;
    transform: translateY(-2px);
}

.al3ode-auth-divider {
    text-align: center;
    position: relative;
    margin: 30px 0;
    display: flex;
    align-items: center;
    justify-content: center;
}

.al3ode-auth-divider::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 0;
    width: 100%;
    height: 1px;
    background: rgba(255, 255, 255, 0.1);
    z-index: 1;
}

.al3ode-auth-divider span {
    position: relative;
    z-index: 2;
    background: inherit;
    /* This will work if parent has background control set locally */
    background-color: transparent;
    padding: 0 15px;
    color: #777;
    font-size: 14px;
}

/* Fallback background for divider span to make text readable over line */
.al3ode-auth-wrapper>div.active .al3ode-auth-divider span {
    background-color: #000;
    /* Default matching wrapper */
}

/* When user sets a background in Elementor, we can't easily sync this. 
   But by using a background-color: inherit or transparent combined with 
   an overlay effect, we can manage. Let's stick to a clean look. */

.al3ode-auth-social {
    display: flex;
    gap: 15px;
    margin-bottom: 30px;
}

.al3ode-auth-social-btn {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    background: transparent;
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 30px;
    padding: 12px;
    color: #fff;
    text-decoration: none;
    font-size: 14px;
    transition: all 0.3s ease;
    font-weight: 500;
}

.al3ode-auth-social-btn:hover {
    background: rgba(255, 255, 255, 0.05);
    border-color: #c18e1d;
}

.al3ode-auth-social-btn svg {
    width: 18px;
    height: 18px;
}

.al3ode-auth-footer {
    text-align: center;
    font-size: 14px;
    color: #a8a8a8;
}

.al3ode-auth-footer a {
    color: #c18e1d;
    text-decoration: none;
    font-weight: 700;
    margin-right: 5px;
    transition: 0.3s;
}

.al3ode-auth-footer a:hover {
    text-decoration: underline;
}

/* Tabs Animation */
.al3ode-auth-tabs-content {
    display: none;
}

.al3ode-auth-tabs-content.active {
    display: block;
    animation: fadeIn 0.4s ease forwards;
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(10px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@media (max-width: 480px) {
    .al3ode-auth-wrapper {
        padding: 25px 20px;
    }

    .al3ode-auth-brand {
        font-size: 26px;
    }
}

/* Logged In State Styles */
.al3ode-auth-logged-in {
    text-align: center;
}

.al3ode-auth-logged-in .al3ode-auth-header {
    margin-bottom: 40px;
}

.al3ode-auth-logout {
    display: inline-flex;
    align-items: center;
    color: #ff4d4d;
    text-decoration: none;
    font-size: 14px;
    margin-top: 20px;
    transition: 0.3s;
    font-weight: 500;
}

.al3ode-auth-logout:hover {
    color: #ff3333;
    text-decoration: underline;
}

.al3ode-auth-logged-in-actions .al3ode-auth-submit-btn {
    display: block;
    text-align: center;
    text-decoration: none;
    margin-bottom: 15px;
}