:root {
    --tab-margin: 20px;
    --primary-color: #205fff;
    --error-color: #FB0808;
    --success-color: #28a745;
    --border-radius: 15px;
    --transition: all 0.3s ease;
}

.jamilweb-modal-container {
    position: fixed;
    left: 0;
    top: 0;
    right: 0;
    bottom: 0;
    background-image: url('../images/jamilweb.jpg');
    z-index: 9999;
    visibility: hidden; /* مخفی بودن مودال */
    opacity: 0; /* مخفی بودن مودال */
    align-items: center;
    justify-content: center;
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    display: flex; /* استفاده از display: flex برای مرکز کردن */
    transition: opacity 0.3s ease, visibility 0.3s ease; /* انیمیشن برای opacity و visibility */
}

.jamilweb-modal-container.open {
    visibility: visible; /* نمایش مودال */
    opacity: 1; /* نمایش مودال */
}
.jamilweb-modal {
    background: white;
    border-radius: var(--border-radius);
    text-align: center;
    position: relative;
    padding: 15px;
    width: 400px;
    border: 1px solid #e1e1e1;
}
button.jamilweb-close-modal {
    border: none;
    border-radius: 50px !important;
    box-shadow: 0 3px 6px rgba(0,0,0, .16);
    width: 35px;
    height: 35px;
    display: flex;
    align-items: center;
    justify-content: center;
    position: absolute;
    left: 5px;
    top: 5px;
    cursor: pointer;
    background: red !important;
    padding: 0 !important;
}
form#jamilweb-login {
    text-align: right;
}
.jamilweb-modal-title {
    display: inline-block;
    font-size: 16px;
    font-weight: 700;
    margin-bottom: 30px;
    color: #3a3a3a !important;
    border-bottom: 2px solid var(--primary-color) !important;
    padding-bottom: 10px;
}
.jamilweb-login-field label {
    width: 100%;
    text-align: center;
    font-size: 13px;
    display: block;
    font-weight: bold;
    margin-bottom: 15px;
}
.jamilweb-login-field {
    text-align: right;
    margin: 24px 0 0;
}
p.jamilweb-subtitle {
    width: 100%;
    text-align: center;
    margin-bottom: 10px;
    font-size: 13px;
    display: block;
}
.jamilweb-cols {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    padding: 10px 0;
    border-radius: 10px;
    gap: 10px;
    margin-bottom: 10px;
}
.jamilweb-cols span {
    font-weight: 600;
}
.jamilweb-cols input {
    border-radius: 8px !important;
    border: 1px solid #0656df08 !important;
    width: 100% !important;
    padding: 5px 10px !important;
    box-sizing: border-box !important;
    background-color: #0656df08 !important;
    direction: ltr !important;
    height: inherit !important;
}
.jamilweb-form button {
    background: #205fff !important;
    width: 100%;
    display: flex;
    justify-content: center;
    align-items: center;
    color: #fff !important;
    fill: #fff !important;
    border: none;
    outline: none;
    border-radius: 10px;
    gap: 10px;
    padding: 12px 24px;
    transition: 0.3s;
}
.jamilweb-form form button[disabled]{
    filter: grayscale(1);
    opacity: .4;
}
.jamilweb-modal form button svg {
    display: none;
}
.jamilweb-modal form.loading button svg {
    display: inline;
}
.jamilweb-cols input:focus {
    outline: none;
}
p.jamilweb-message {
    border: 1px solid #fb0808 !important;
    padding: 8px;
    border-radius: 8px;
    color: #fb0808 !important;
    background: lab(63 60.41 32.99 / 0.09);
    margin-bottom: 10px;
    display: none;
}
p.jamilweb-message.active {
    display: flex;
    align-items: center;
    gap: 10px;
}
.jamilweb-box-code {
    display: flex;
    justify-content: center;
    gap: 10px;
    margin: 20px 0;
}
.jamilweb-box-code input {
    width: 52px !important;
    height: 50px !important;
    border-radius: 8px !important;
    background: #f6f6f6 !important;
    border: 1px solid #e1e1e1 !important;
    outline: none !important;
    text-align: center !important;
    color: #2e47ea !important;
    font-size: 30px !important;
    font-weight: bold !important;
    direction: ltr !important;
}
.jamilweb-box-code {
    display: flex;
    justify-content: center;
    gap: 10px;
    margin: 20px 0;
    direction: ltr;
}

.jamilweb-resendbox {
    margin: 20px 0;
}
a.jamilweb-resend {
    font-size: 14px;
    color: #0000004f !important;
    font-weight: 600;
    text-decoration: none;
}
a.jamilweb-resend.active {
    opacity: 1;
    color: #000000c2 !important;
}
span.jamilweb-countdown {
    color: #2e47ea !important;
    font-weight: 600;
}
.jamilweb-confirm-box {
    display: grid;
    grid-template-columns: repeat(2,1fr);
    gap: 15px;
    margin: 0 15px;
}
button.jamilweb-confirm-code {
    padding: 15px;
    background: #2e47ea !important;
    color: #fff !important;
    border: 0;
    border-radius: 8px;
    outline: none;
}
button#jamilweb-change-number {
    border: 2px solid #2e47ea !important;
    border-radius: 8px;
    background: none;
}

.jamilweb-modal form#jamilweb-verify {
    display: none;
}
.jamilweb-modal.verify form#jamilweb-verify {
    display: block;
}
.jamilweb-modal.verify form#jamilweb-login {
    display: none;
}
.jamilweb-phone {
	color: #205FFF !important;
}
button#jamilweb-edit-number {
    border: 2px solid #2e47ea !important;
    border-radius: 8px !important;
    background-color: #0000ff00 !important;
    color: #000000 !important;
}
.jamilweb-success {
    position: fixed;
    background-color: #ffffffe6;
    -webkit-backdrop-filter: blur(5px);
    backdrop-filter: blur(10px);
    position: fixed;
    display: block;
    top: 0;
    z-index: 99999999;
    width: 100%;
    right: 0;
    height: 100%;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
}
p.jamilweb-success-title {
    font-size: 20px;
    color: #00cf30;
    background-color: #00cf301c;
    padding: 10px 24px;
    border-radius: 10px;
    font-weight: bold;
    margin-bottom: 25px;
}
p.jamilweb-success-subtitle {
    display: flex;
    flex-direction: column-reverse;
    align-items: center;
    color: #00a827;
    fill: #00a827;
    
}
/*  استایل طرح زرین پال */

.jamilwebmodal {
    display: flex;
    background-color: #ffffff;
    border-radius: 15px;
    overflow: hidden;
    box-shadow: 0 5px 15px 0 rgba(31, 32, 35, .07);
}

.jamilwebmodal .jamilweb-modal-right img {
    width: auto;
    height: 500px;
    display: flex;
}
.jamilwebmodal .jamilweb-modal {
    background: white;
    text-align: center;
    position: relative;
    padding: 15px;
    width: 400px;
    align-items: center;
    border: 0;
}
.jamilweb-modal-container.jamil-web {
    background-color: #f1f1f1;
    background-image: none;
}
button.jamilweb-close-modal.zarin {
    display: none;
}

/* Header styles for modal */
.jamilweb-modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
    position: relative;
}

/* Back to home button */
.jamilweb-back-to-home {
    background: var(--primary-color);
    color: white;
    border: none;
    border-radius: 25px;
    padding: 8px 16px;
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    transition: var(--transition);
    box-shadow: 0 2px 8px rgba(32, 95, 255, 0.3);
}

.jamilweb-back-to-home:hover {
    background: #1a4fd9;
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(32, 95, 255, 0.4);
}

.jamilweb-back-to-home svg {
    width: 18px;
    height: 18px;
}

/* استایل‌های صفحات ورود و ثبت نام */
.jamilweb-login-page,
.jamilweb-register-page {
    max-width: 600px;
    margin: 50px auto;
    padding: 20px;
    background: white;
    border-radius: 15px;
    box-shadow: 0 5px 15px rgba(0,0,0,0.1);
}

.jamilweb-login-page h2,
.jamilweb-register-page h2 {
    text-align: center;
    color: #3a3a3a;
    margin-bottom: 10px;
    font-size: 24px;
    font-weight: 700;
}

.jamilweb-login-page p,
.jamilweb-register-page p {
    text-align: center;
    color: #666;
    margin-bottom: 30px;
    font-size: 14px;
}

/* استایل دکمه ورود در منو */
.jamilweb-login-menu-item {
    list-style: none;
}

.jamilweb-open-login-modal {
    display: inline-block;
    padding: 8px 16px;
    background: #205fff;
    color: white !important;
    text-decoration: none;
    border-radius: 5px;
    font-size: 14px;
    font-weight: 600;
    transition: background 0.3s ease;
}

.jamilweb-open-login-modal:hover {
    background: #1a4fd9;
    color: white !important;
    text-decoration: none;
}

/* استایل‌های ووکامرس */
.jamilweb-woocommerce-login,
.jamilweb-woocommerce-register {
    text-align: center;
    padding: 20px;
}

.jamilweb-woocommerce-login h2,
.jamilweb-woocommerce-register h2 {
    color: #3a3a3a;
    margin-bottom: 10px;
    font-size: 20px;
    font-weight: 700;
}

.jamilweb-woocommerce-login p,
.jamilweb-woocommerce-register p {
    color: #666;
    margin-bottom: 20px;
    font-size: 14px;
}

/* مخفی کردن فرم‌های پیشفرض ووکامرس */
.woocommerce-form-login__submit,
.woocommerce-form-login .form-row,
.woocommerce-form-login .woocommerce-form-login__username,
.woocommerce-form-login .woocommerce-form-login__password,
.woocommerce-form-register__submit,
.woocommerce-form-register .form-row,
.woocommerce-form-register .woocommerce-form-register__email,
.woocommerce-form-register .woocommerce-form-register__password {
    display: none !important;
}

/* استایل فیلد شماره تلفن در پروفایل ووکامرس */
.woocommerce-form-row input[name="phone"] {
    background-color: #f9f9f9 !important;
    cursor: not-allowed !important;
}

.woocommerce-form-row input[name="phone"]:focus {
    outline: none !important;
    box-shadow: none !important;
}
.jamilweb-form button:hover {
    color: white !important;
}

/* Tab Navigation Styles */
.jamilweb-tab-nav {
    display: flex;
    margin: 35px auto;
    border-radius: 0;
    gap: 10px;
}

.jamilweb-tab-btn {
    flex: 1;
    border: 1px solid #205fff !important;
    background: none;
    cursor: pointer !important;
    color: #666 !important;
    transition: all 0.3s ease !important;
}
.jamilweb-tab-btn:hover {
    border: 1px solid #205fff !important;
    background: none !important;
    cursor: pointer !important;
    transition: all 0.3s ease !important;
}
.jamilweb-tab-btn.active {
    color: #ffffff !important;
    border: 1px solid #205fff !important;
    background-color: #205fff !important;
}
.jamilweb-tab-btn.active:hover {
    color: #ffffff;
    border: 1px solid #205fff;
    background-color: #205fff;
}
.jamilweb-tab-content {
    display: none;
}

.jamilweb-tab-content.active {
    display: block;
}

/* Email Form Styles */
.jamilweb-form-field {
    margin-bottom: 10px;
    text-align: right;
}

.jamilweb-form-field label {
    display: block;
    margin-bottom: 8px;
    font-size: 14px;
    font-weight: 600;
    color: #333;
    text-align: right;
}

.jamilweb-form-field input {
    width: 100%;
    padding: 12px 15px;
    border: 2px solid #e1e1e1;
    border-radius: 8px;
    font-size: 14px;
    transition: border-color 0.3s ease;
    box-sizing: border-box;
}

.jamilweb-form-field input:focus {
    outline: none;
    border-color: #205fff;
}

.jamilweb-form-row {
    display: flex;
    gap: 15px;
}

.jamilweb-form-row .jamilweb-form-field {
    flex: 1;
}

.jamilweb-form-links {
    margin: 10px 0;
    text-align: center;
    display: flex;
    justify-content: space-between;
}

.jamilweb-form-links a {
    color: #205fff;
    text-decoration: none !important;
    font-size: 14px;
    transition: color 0.3s ease;
    background: #205fff1a;
    padding: 5px 10px;
    border-radius: 8px;
}

.jamilweb-form-links a:hover {
    color: #1545b3;
    text-decoration: underline;
}

/* Google Login Button */
.jamilweb-google-login {
    margin-top: 20px;
    padding-top: 20px;
    border-top: 1px solid #e1e1e1;
}

.jamilweb-google-btn {
    width: 100%;
    padding: 12px 20px;
    background: #fff;
    border: 2px solid #e1e1e1;
    border-radius: 8px;
    color: #333;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
}

.jamilweb-google-btn:hover {
    background: #f8f9ff;
    border-color: #205fff;
    box-shadow: 0 2px 8px rgba(32, 95, 255, 0.2);
}

.jamilweb-google-btn svg {
    width: 20px;
    height: 20px;
}

/* Form Switching Animation */
.jamilweb-form {
    transition: opacity 0.3s ease, transform 0.3s ease;
    text-align: right;
}

.jamilweb-form[style*="display: none"] {
    opacity: 0;
    transform: translateY(10px);
}

.jamilweb-form:not([style*="display: none"]) {
    opacity: 1;
}

/* Success Message Styles */
.jamilweb-message.success {
    background-color: #d4edda;
    border-color: #c3e6cb;
    color: #155724;
}

.jamilweb-message.success svg {
    stroke: #155724;
}

/* Responsive Design */
@media (max-width: 480px) {
    .jamilweb-modal {
        width: 90%;
        margin: 20px;
    }
    
    .jamilweb-form-row {
        flex-direction: column;
        gap: 0;
    }
    
    .jamilweb-tab-nav {
        flex-direction: column;
    }
    
    .jamilweb-tab-btn {
        border-bottom: none;
        border-right: 3px solid transparent;
    }
    
    .jamilweb-tab-btn.active {
        border-right-color: #205fff;
        border-bottom-color: transparent;
    }
}

/* Global Message System */
.jamilweb-global-message {
    position: fixed;
    top: 20px;
    right: 20px;
    padding: 15px 20px;
    border-radius: 8px;
    color: white;
    font-weight: 500;
    z-index: 10000;
    max-width: 400px;
    box-shadow: 0 4px 12px rgba(0,0,0,0.15);
    animation: slideInRight 0.3s ease;
}

.jamilweb-message-success {
    background-color: var(--success-color);
}

.jamilweb-message-error {
    background-color: var(--error-color);
}

.jamilweb-message-info {
    background-color: var(--primary-color);
}

@keyframes slideInRight {
    from {
        transform: translateX(100%);
        opacity: 0;
    }
    to {
        transform: translateX(0);
        opacity: 1;
    }
}

/* Spinner for Google button */
.jamilweb-google-btn .spinner {
    animation: spin 1s linear infinite;
}

@keyframes spin {
    from { transform: rotate(0deg); }
    to { transform: rotate(360deg); }
}
button#jamilweb-google-login {
    background: white !important;
    border: 1px solid #205fff82;
    color: #205fff !important;
}
.jamilweb-form-field input {
    border: 1px solid #e1e1e1 !important;
}
button.jamilweb-back-to-home {
    background: #205fff1c;
    color: #0748ed;
    border: 0;
    box-shadow: unset;
    border-radius: 8px;
}
button.jamilweb-back-to-home:hover {
    background: #205fff1c;
    color: #0748ed;
    border: 0;
    box-shadow: unset;
    border-radius: 8px;
}