/* استایل‌های تکمیلی پروژه bestseo — روی قالب app.min.css اعمال می‌شود و از متغیرهای رنگ همان قالب استفاده می‌کند. */

:root {
    --color-orange: #8a5300;
    --color-bg-orange: #fde9c8;
    --color-gray-status: #606060;
    --color-bg-gray-status: #ebebeb;
}

html.dark-theme {
    --color-orange: #fde9c8;
    --color-bg-orange: #5a3b0c;
    --color-gray-status: #c2c2c2;
    --color-bg-gray-status: #333333;
}

/* لوگو متنی */
.brand-logo {
    display: inline-flex;
    align-items: baseline;
    font-family: Arial, sans-serif;
    font-size: 1.6rem;
    font-weight: bold;
    letter-spacing: -0.5px;
    line-height: 45px;
}
.brand-logo-best { color: var(--primary-color); }
.brand-logo-seo { color: var(--secondary-color); }
.login-form-box .brand-logo { font-size: 2rem; line-height: 50px; }

/* وضعیت‌های اضافه */
.status.orange { color: var(--color-orange); background-color: var(--color-bg-orange); }
.status.gray { color: var(--color-gray-status); background-color: var(--color-bg-gray-status); }

/* پیام‌ها */
.app-alert {
    border-radius: 8px;
    padding: 12px 16px;
    margin-bottom: 16px;
    font-size: 0.87rem;
    border: 1px solid transparent;
}
.app-alert.success { color: var(--color-green); background-color: var(--color-bg-green); }
.app-alert.error { color: var(--color-red); background-color: var(--color-bg-red); }
.app-alert.info { color: var(--color-bg-info); background-color: var(--color-info); }
.app-alert ul { margin: 0; list-style: none; }
.validation-summary-valid { display: none; }
html.dark-theme .app-alert.error { color: #f1cfcc; background-color: #4a1f1b; }
html.dark-theme .app-alert.success { color: #d6f3e5; background-color: #11402a; }

.field-validation,
.field-validation-error {
    display: block;
    color: var(--color-red);
    font-size: 0.73rem;
    margin: -10px 4px 12px;
}
.field-validation-valid { display: none; }
.input-validation-error { color: var(--color-red); }
.floatingInpuBox:has(.input-validation-error) { border-color: var(--color-red); }

/* کارت‌های آمار پیشخوان */
.stats-row .cell { margin-bottom: 16px; }
.stat-card {
    display: flex;
    flex-direction: column;
    gap: 8px;
    padding: 20px;
    color: var(--primary-color);
    border-right: 4px solid var(--secondary-color);
    height: 100%;
}
.stat-card:hover { color: var(--secondary-color); }
.stat-card.green { border-right-color: var(--color-green); }
.stat-card.orange { border-right-color: #e0a100; }
.stat-card.blue { border-right-color: var(--color-bg-info); }
.stat-title { font-size: 0.8rem; color: var(--color-gray-level-600); }
.stat-value { font-size: 1.7rem; }

/* پنجره‌های SweetAlert2 (راست‌چین، هماهنگ با قالب و تم تیره) */
.bs-swal { direction: rtl; font-family: inherit; border-radius: 18px; background: var(--white-color); color: var(--primary-color); }
.bs-swal .swal2-title { font-size: 1.2rem; color: var(--primary-color); }
.bs-swal .swal2-html-container { color: var(--color-gray-level-700); font-size: 0.9rem; }
.bs-swal .swal2-actions { gap: 10px; }
.bs-swal .swal2-actions .button { margin: 0; min-width: 110px; }
.bs-swal .swal2-validation-message { background: var(--color-bg-red); color: var(--color-red); }
.bs-swal-form { display: flex; flex-direction: column; gap: 14px; text-align: right; margin-top: 8px; }
.bs-swal-form .floatingInpuBox { margin: 0; }
.bs-swal-check { align-self: flex-start; }
.bs-swal .app-alert { margin-bottom: 10px; text-align: right; }
/* تقویم شمسی روی پنجره SweetAlert هم دیده شود */
jdp-container, jdp-overlay { z-index: 3000 !important; }

/* پیشخوان */
.dash { display: flex; flex-direction: column; gap: 24px; }

/* خوشامد */
.dash-hero {
    position: relative;
    overflow: hidden;
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
    padding: 28px 32px;
    border-radius: 24px;
    color: #fff;
    background: linear-gradient(120deg, #5b35ad 0%, #7c5ee0 55%, #a58bff 100%);
    box-shadow: 0 16px 40px rgba(91, 53, 173, .28);
}
.dash-hero::before, .dash-hero::after {
    content: "";
    position: absolute;
    border-radius: 50%;
    background: rgba(255, 255, 255, .10);
    pointer-events: none;
}
.dash-hero::before { width: 260px; height: 260px; left: -70px; top: -120px; }
.dash-hero::after { width: 180px; height: 180px; left: 180px; bottom: -110px; background: rgba(255, 255, 255, .07); }
.dash-hero-text { position: relative; z-index: 1; max-width: 640px; }
.dash-hero-date { display: inline-block; padding: 4px 12px; border-radius: 20px; background: rgba(255, 255, 255, .18); font-size: .78rem; }
.dash-hero h1 { color: #fff; font-size: 1.6rem; margin: 12px 0 6px; }
.dash-hero p { margin: 0; opacity: .92; font-size: .9rem; line-height: 1.9; }
.dash-hero p strong { font-size: 1.05rem; }
.dash-hero-actions { position: relative; z-index: 1; display: flex; flex-wrap: wrap; gap: 10px; }
.dash-hero-btn {
    display: inline-flex; align-items: center; gap: 6px;
    padding: 10px 18px; border-radius: 12px;
    color: #fff; font-size: .85rem;
    background: rgba(255, 255, 255, .16);
    border: 1px solid rgba(255, 255, 255, .28);
    transition: background .15s ease, transform .15s ease;
}
.dash-hero-btn:hover { color: #fff; background: rgba(255, 255, 255, .26); transform: translateY(-2px); }
.dash-hero-btn.primary { background: #fff; color: #5b35ad; border-color: #fff; font-weight: bold; }
.dash-hero-btn.primary:hover { color: #5b35ad; background: #f3efff; }
.dash-hero-btn svg { fill: currentColor; }

/* شاخص‌ها */
.dash-kpis { display: grid; gap: 16px; grid-template-columns: repeat(3, 1fr); }
.dash-kpi {
    --accent: #7c5ee0;
    position: relative;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    gap: 4px;
    min-height: 150px;
    padding: 20px 22px;
    border-radius: 20px;
    background: var(--white-color);
    border: 1px solid var(--color-border-3);
    color: var(--primary-color);
    transition: transform .15s ease, box-shadow .15s ease;
}
.dash-kpi::after {
    content: "";
    position: absolute;
    width: 140px; height: 140px;
    left: -40px; bottom: -60px;
    border-radius: 50%;
    background: color-mix(in srgb, var(--accent) 10%, transparent);
}
.dash-kpi:hover { color: var(--primary-color); transform: translateY(-4px); box-shadow: 0 14px 30px color-mix(in srgb, var(--accent) 18%, transparent); }
/* آیکن‌ها: رنگ تند و براق با هاله رنگی */
.dash-kpi-icon {
    width: 50px; height: 50px; border-radius: 15px;
    display: flex; align-items: center; justify-content: center;
    color: #fff;
    background:
        radial-gradient(circle at 30% 20%, rgba(255, 255, 255, .45), transparent 55%),
        linear-gradient(145deg, color-mix(in srgb, var(--accent) 75%, #fff), var(--accent) 55%, color-mix(in srgb, var(--accent) 80%, #000));
    box-shadow: 0 10px 22px color-mix(in srgb, var(--accent) 55%, transparent), 0 0 0 5px color-mix(in srgb, var(--accent) 14%, transparent);
    margin-bottom: 10px;
}
.dash-kpi-icon svg { fill: currentColor; stroke: currentColor; }
.dash-kpi-label { font-size: .82rem; color: var(--color-gray-level-600); }
.dash-kpi-value { position: relative; z-index: 1; font-size: 2rem; line-height: 1.2; color: var(--accent); }
.dash-kpi-value.money { font-size: 1.45rem; }
.dash-kpi-value small { font-size: .75rem; margin-right: 4px; color: var(--color-gray-level-600); font-weight: normal; }
.dash-kpi-note { position: relative; z-index: 1; font-size: .74rem; color: var(--color-gray-level-600); }
.dash-kpi-note.danger { color: var(--color-red); }

/* عنوان بخش‌ها */
.dash-section-title { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: -8px; }
.dash-section-title h2 { display: flex; align-items: center; gap: 8px; margin: 0; font-size: 1.05rem; color: var(--primary-color); }
.dash-section-title .dot { width: 10px; height: 10px; border-radius: 50%; background: var(--accent); box-shadow: 0 0 0 4px color-mix(in srgb, var(--accent) 20%, transparent); }
.dash-section-title .count { padding: 1px 10px; border-radius: 12px; font-size: .75rem; background: var(--color-gray-level-100); color: var(--color-gray-level-700); }

/* دسته بندی‌ها */
.dash-cats { display: grid; gap: 14px; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); }
.dash-cat {
    --accent: #7c5ee0;
    display: flex; flex-direction: column; gap: 6px;
    padding: 16px;
    border-radius: 18px;
    background: var(--white-color);
    border: 1px solid var(--color-border-3);
    border-top: 4px solid var(--accent);
}
.dash-cat-count { font-size: 1.6rem; font-weight: bold; color: var(--accent); line-height: 1.2; }
.dash-cat-title { font-size: .8rem; color: var(--primary-color); }
.dash-cat-bar { height: 6px; border-radius: 6px; background: var(--color-gray-level-100); overflow: hidden; }
.dash-cat-bar span { display: block; height: 100%; border-radius: 6px; background: var(--accent); }

/* کارت آگهی */
.dash-ads { display: grid; gap: 16px; grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); }
.ad-tile {
    --tone: #7c5ee0;
    position: relative;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 3px;
    padding: 34px 14px 0;
    border-radius: 20px;
    background: var(--white-color);
    border: 1px solid var(--color-border-3);
    color: var(--primary-color);
    text-align: center;
    overflow: hidden;
    transition: transform .15s ease, box-shadow .15s ease;
}
.ad-tile.tone-red { --tone: #d2463a; }
.ad-tile.tone-orange { --tone: #e08a00; }
.ad-tile.tone-green { --tone: #1f9d63; }
.ad-tile.tone-blue { --tone: #3f6fd8; }
.ad-tile.tone-gray { --tone: #8a8a8a; }
.ad-tile:hover { color: var(--primary-color); transform: translateY(-4px); box-shadow: 0 14px 30px color-mix(in srgb, var(--tone) 20%, transparent); }
.ad-tile-top { position: absolute; top: 0; right: 0; left: 0; height: 58px; background: linear-gradient(120deg, #3fa92b 0%, #5cc631 50%, #a8e063 100%); }
.ad-tile-badge { position: absolute; top: 10px; left: 10px; right: auto; width: auto; min-width: 0; padding: 2px 10px; font-size: .7rem; z-index: 1; }
.ad-tile-logo {
    position: relative; z-index: 1;
    width: 64px; height: 64px; border-radius: 50%; overflow: hidden; margin-bottom: 6px;
    background: var(--white-color);
    border: 3px solid var(--white-color);
    box-shadow: 0 6px 16px rgba(0, 0, 0, .12);
}
.ad-tile-logo img { width: 100%; height: 100%; object-fit: cover; }
.ad-tile-title { font-size: .92rem; max-width: 100%; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.ad-tile-site { font-size: .8rem; color: var(--tone); max-width: 100%; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.ad-tile-meta { font-size: .72rem; color: var(--color-gray-level-600); }
.ad-tile-footer {
    display: flex; justify-content: space-between; gap: 6px;
    align-self: stretch;
    margin: 12px -14px 0;
    padding: 10px 14px;
    border-top: 1px dashed var(--color-border-3);
    font-size: .75rem;
    font-weight: bold;
}
.ad-tile-footer small { font-weight: normal; color: var(--color-gray-level-600); }

.dash-empty {
    padding: 28px;
    border-radius: 20px;
    text-align: center;
    color: var(--color-gray-level-600);
    background: var(--white-color);
    border: 1px dashed var(--color-border-3);
}

@media (max-width: 1100px) { .dash-kpis { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 640px) {
    .dash-hero { padding: 22px 18px; }
    .dash-hero h1 { font-size: 1.25rem; }
    .dash-kpis, .dash-ads { grid-template-columns: repeat(2, 1fr); gap: 10px; }
    .dash-kpi { min-height: 130px; padding: 14px; }
    .dash-kpi-value { font-size: 1.5rem; }
    .dash-kpi-value.money { font-size: 1.05rem; }
    .dash-cats { grid-template-columns: repeat(2, 1fr); }
}

/* فرم‌ها و دکمه‌ها */
.price-preview { margin: 0 0 16px; font-size: 0.87rem; }
.price-preview strong { color: var(--secondary-color); font-size: 1rem; }
.inline-form { display: inline-block; margin: 0; }
.detail-actions { display: flex; justify-content: flex-end; flex-wrap: wrap; gap: 8px; }
.detail-actions .button { margin: 0; }
.renew-actions { margin-bottom: 16px; }
.renew-select { margin: 0; min-width: 220px; }
.extra-placements { padding: 14px; border: 1px dashed var(--color-border-3); border-radius: 14px; margin-bottom: 16px; }
.sites-city-filter { width: 200px; margin: 0; }
.extra-actions { display: flex; flex-wrap: wrap; align-items: center; gap: 10px; margin: 6px 0 10px; }
.extra-actions .button { margin: 0; }
.bulk-sites { padding: 16px; margin: 6px 0 14px; border: 1px solid #e3ddf5; }
.bulk-sites-controls { display: flex; flex-wrap: wrap; gap: 10px; }
.bulk-sites-controls .floatingInpuBox { flex: 1; min-width: 200px; margin: 0; }
.bulk-sites-toolbar { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: center; gap: 8px; margin: 12px 0 6px; }
.bulk-sites-list { max-height: 340px; overflow-y: auto; border: 1px solid #eee; border-radius: 8px; padding: 6px 10px; display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 2px 14px; }
.bulk-site { display: flex; flex-wrap: wrap; align-items: center; gap: 2px 6px; padding: 6px 25px 6px 0; margin: 0; font-size: 13px; }
.bulk-sites-toolbar .custom_check { margin: 0; }
.bulk-site .page-description { font-size: 11px; }
.bulk-site.taken { opacity: .55; }
.bulk-site .status { font-size: 10px; padding: 1px 6px; }
.bulk-total { margin: 10px 0 4px; }
.order-summary { border: 1px solid #e3ddf5; border-radius: 10px; padding: 10px 14px; margin-bottom: 14px; background: #faf8ff; max-width: 460px; }
.order-summary-row { display: flex; justify-content: space-between; gap: 12px; padding: 4px 0; font-size: 14px; }
.order-summary-row.discount { color: #c0392b; }
.order-summary-row.total { border-top: 1px dashed #d8d0f0; margin-top: 4px; padding-top: 8px; font-size: 15px; }
.order-summary-row.total strong { color: #6f42d8; }
.bulk-total .page-description { display: block; font-size: 12px; margin-top: 2px; }
.extra-placement-row { display: flex; flex-wrap: wrap; align-items: center; gap: 10px; margin-bottom: 10px; }
.extra-placement-row .floatingInpuBox { flex: 1; min-width: 200px; margin: 0; }
.extra-placement-row .extra-price { flex: 0.8; min-width: 170px; }
.extra-placement-note { display: block; margin: -4px 0 12px; color: #b26a00; }
.monopoly-supervip { display: inline-flex; align-items: center; gap: 6px; margin: 6px 0 2px; font-size: 13px; cursor: pointer; }
.monopoly-supervip input { margin: 0; }
.extra-placement-note .floatingInpuBoxNote { color: inherit; display: block; }
.order-total { margin: 10px 0 0; }
.order-total strong { font-size: 1.1rem; }
.extra-placements .button { margin: 0; }
.extra-placements .floatingInpuBoxNote { display: block; margin-top: 10px; position: static; }
.renew-form { display: flex; flex-wrap: wrap; align-items: center; gap: 10px; }
.renew-form .floatingInpuBox { margin: 0; min-width: 170px; flex: 1; }
.renew-form .button { margin: 0; }
.review-form .floatingInpuBox { margin-bottom: 12px; }
.add-form-card + .add-form-card { margin-top: 24px; }
.page-description { color: var(--color-gray-level-600); font-size: 0.8rem; margin: 4px 0 0; }
.empty-text { color: var(--color-gray-level-600); font-size: 0.8rem; padding: 16px 0; }
.empty-state { text-align: center; padding: 32px 16px; }

.row-actions { display: inline-flex; gap: 12px; align-items: center; }
.link-button {
    background: none;
    border: 0;
    padding: 0;
    color: var(--color-red);
    cursor: pointer;
    font: inherit;
}
.tag { cursor: pointer; color: inherit; }
.filter-sidebar .footer { margin-top: 16px; }
.floatingInpuBox input[dir="ltr"] { text-align: left; direction: ltr; }
.detail-actions .button,
.renew-actions .button,
.review-form .button,
.add-form-card .button.secondary { border-radius: 50px; white-space: nowrap; }

/* Blazor: کلاس‌های اعتبارسنجی EditForm */
.floatingInpuBox:has(.invalid) { border-color: var(--color-red); }
.floatingInpuBox .invalid { color: var(--color-red); }

/* جستجوی سایت در فرم آگهی */
.site-autocomplete { position: relative; }
.site-suggestions {
    position: absolute;
    top: calc(100% - 12px);
    right: 0;
    left: 0;
    z-index: 30;
    max-height: 320px;
    overflow-y: auto;
    margin: 0;
    padding: 4px 0;
    list-style: none;
    background: var(--white-color);
    border: 1px solid var(--color-gray-level-300);
    border-radius: 8px;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.12);
}
.site-suggestions li {
    display: flex;
    justify-content: space-between;
    gap: 12px;
    padding: 8px 12px;
    cursor: pointer;
    font-size: 0.85rem;
}
.site-suggestions li.active,
.site-suggestions li:hover { background: var(--bg-light-purple); }
.site-suggestions li .url { color: var(--color-gray-level-600); font-size: 0.75rem; }
.site-suggestions li.empty { color: var(--color-gray-level-600); cursor: default; }

/* لوگوی BestSEO */
.brand-logo-img { display: inline-block; vertical-align: middle; border-radius: 50%; }
.login-logo { display: inline-block; margin-bottom: 12px; }

/* پس‌زمینه شفاف برای بستن سایدبار/منوی کاربر با کلیک بیرون */
.panel-backdrop { position: fixed; inset: 0; z-index: 9; background: transparent; }
/* زیر innerSidebar (z-index: 12) و rightSidebar (400) تا کلیک روی منوها به پس‌زمینه نرسد */
.panel-backdrop.sidebar { z-index: 11; }
#user-dropdown.is-open { top: calc(100% + 6px); right: 0; }
.accordion-item.is-active > .accordion-content { display: block; }

/* فیلدهای گذرواژه: متن و نقطه‌ها سمت راست، دکمه چشم سمت چپ */
.floatingInpuBox.passwordBox input { text-align: right; padding-left: 40px; }
.floatingInpuBox.passwordBox .eye { right: auto; left: 10px; }

/* صفحه ورود فشرده‌تر */
.login-form-box { padding-top: 24px; padding-bottom: 20px; }
.login-form-box .login-logo { margin-bottom: 4px; }
.login-form-box .title { margin-bottom: 16px; }
.login-form-box .floatingInpuBox { margin-bottom: 12px; }
.login-form-box .forget { margin: 4px 0 12px; }
.login-form-box .register { margin-top: 12px; }
.login-form-box .register p { margin-bottom: 0; }

/* نحوه پرداخت و اقساط در فرم آگهی */
.payment-type { display: flex; align-items: center; gap: 16px; flex-wrap: wrap; min-height: 56px; margin-bottom: 16px; }
.payment-type-label { color: var(--color-gray-level-600); font-size: 0.85rem; }
.payment-type .custom_radio { margin: 0; }
.installment-row { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.installment-line + .installment-line { margin-top: 4px; }

/* صفحه زمان تمدید: بازه تاریخ */
.renewal-range { align-items: flex-start; }
.renewal-shortcuts { display: flex; gap: 8px; flex-wrap: wrap; padding-top: 8px; }
.renewal-shortcuts .button { margin: 0; border-radius: 50px; }
.renewal-summary { font-size: 0.87rem; color: var(--color-gray-level-600); margin: 0 0 12px; }
.renewal-summary strong { color: var(--secondary-color); }

/* امور مالی: فیلترها در سربرگ کارت */
.finance-filters { display: flex; flex-wrap: wrap; align-items: center; gap: 10px; }
.finance-filters .search-box { flex: 1 1 240px; }
.finance-filters .floatingInpuBox { margin-bottom: 0; flex: 0 1 180px; }
.finance-action { margin: 0; border-radius: 50px; white-space: nowrap; }
.finance-actions { display: inline-flex; flex-wrap: wrap; gap: 8px; justify-content: flex-end; }
.payment-edit-actions { display: inline-flex; gap: 10px; margin-inline-start: 8px; white-space: nowrap; }
.payment-edit-actions .link-button { font-size: 13px; }

/* کدهای تخفیف */
.discount-code { font-family: Consolas, "Courier New", monospace; letter-spacing: 2px; font-size: 1rem; color: var(--primary-color); }
.new-discount-code { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 8px; margin-top: 16px; padding: 12px; border-radius: 8px; background: var(--bg-light-purple); font-size: 0.85rem; }
.new-discount-code .discount-code { font-size: 1.3rem; }
.new-discount-code .button { margin: 0; border-radius: 50px; }
.row-actions .link-button.purple { color: var(--secondary-color); }

/* پنجره ثبت پرداخت */
.payment-dialog-backdrop { position: fixed; inset: 0; z-index: 500; background: rgba(0, 0, 0, 0.35); }
.payment-dialog { position: fixed; z-index: 501; top: 50%; left: 50%; transform: translate(-50%, -50%); width: min(420px, calc(100% - 32px)); padding: 20px; margin: 0; }
.payment-dialog-summary { font-size: 0.85rem; color: var(--color-gray-level-600); margin-bottom: 16px; }
.payment-dialog-summary strong { color: var(--secondary-color); font-size: 1rem; }
.payment-methods { display: flex; flex-wrap: wrap; align-items: center; gap: 12px; margin-bottom: 16px; }
.payment-methods .custom_radio { margin: 0; }
.payment-dialog-actions { gap: 10px; }
.payment-dialog-actions .button { margin: 0; border-radius: 50px; }
.income-by-method { display: flex; flex-wrap: wrap; justify-content: center; gap: 4px 12px; margin: 8px 0 0; font-size: 0.75rem; color: var(--color-gray-level-600); }
.installment-line { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; }
.installment-line .finance-action { padding: 4px 12px; }

/* لیست مشتریان */
.customer-actions { display: flex; align-items: center; justify-content: flex-end; gap: 12px; white-space: nowrap; }
.title-autocomplete { position: relative; }

/* تب‌های وضعیت فهرست آگهی */
.ad-status-tabs { display: flex; gap: 8px; flex-wrap: wrap; padding: 0 1.25rem 0.75rem; }
.ad-status-tabs a { display: inline-flex; align-items: center; gap: 6px; padding: 6px 14px; border-radius: 999px; border: 1px solid var(--color-gray-level-300, #ddd); color: inherit; font-size: 0.85rem; }
.ad-status-tabs a .count { background: var(--bg-light-purple, #f1ecff); border-radius: 999px; padding: 0 8px; font-size: 0.75rem; }
.ad-status-tabs a.active { background: #6f42d8; border-color: #6f42d8; color: #fff; }
.ad-status-tabs a.green.active { background: #22a35a; border-color: #22a35a; }
.ad-status-tabs a.red.active { background: #e0414b; border-color: #e0414b; }
.ad-status-tabs a.active .count { background: rgba(255,255,255,.25); color: #fff; }

/* فیلدهای پرشده خودکار مرورگر (مثلاً ایمیل ذخیره‌شده در صفحه ورود): برچسب از همان لحظه اول بالا برود و روی متن نیفتد.
   هر انتخاب‌گر جدا نوشته شده چون مرورگری که یکی را نشناسد کل قانون را نادیده می‌گیرد. */
.floatingInpuBox input:-webkit-autofill ~ label { top: 0px; font-size: 0.6rem; transition: none; }
.floatingInpuBox input:autofill ~ label { top: 0px; font-size: 0.6rem; transition: none; }
.floatingInpuBox input:-webkit-autofill ~ label::before { position: absolute; background-color: var(--white-color); height: 2px; width: 100%; content: ""; left: 0; right: 0; top: 50%; transform: translateY(-50%); z-index: -1; }
.floatingInpuBox input:autofill ~ label::before { position: absolute; background-color: var(--white-color); height: 2px; width: 100%; content: ""; left: 0; right: 0; top: 50%; transform: translateY(-50%); z-index: -1; }

/* دکمه‌های تمدید: هم‌اندازه، در یک ردیف */
.renew-form { margin-bottom: 12px; }
.renew-buttons { display: flex; gap: 12px; }
.renew-btn {
    flex: 1; display: inline-flex; align-items: center; justify-content: center; gap: 8px;
    height: 48px; border-radius: 14px; font: inherit; font-weight: 700; font-size: 0.9rem;
    cursor: pointer; transition: transform .15s ease, box-shadow .15s ease, background .15s ease;
}
.renew-btn svg { fill: currentColor; }
.renew-btn.primary { border: 0; color: #fff; background: linear-gradient(135deg, #8b2cf5, #6f42d8); box-shadow: 0 6px 16px rgba(111, 66, 216, .35); }
.renew-btn.primary:hover { transform: translateY(-1px); box-shadow: 0 8px 20px rgba(111, 66, 216, .45); }
.renew-btn.cancel { border: 1.5px solid #ff4d5e; color: #e0313f; background: rgba(255, 77, 94, .06); }
.renew-btn.cancel:hover { background: rgba(255, 77, 94, .14); transform: translateY(-1px); }
@media (max-width: 480px) { .renew-buttons { flex-direction: column; } }
.renew-order-note { margin: 0 0 12px; line-height: 1.8; }

/* تمدید اقساطی */
.renew-paytype { display: flex; align-items: center; flex-wrap: wrap; gap: 16px; margin: 0 0 12px; }
.renew-installments { border: 1px dashed var(--color-border-3, #d9d9e3); border-radius: 14px; padding: 12px; margin-bottom: 12px; }
.renew-installment-row { display: flex; align-items: center; gap: 10px; margin-bottom: 10px; flex-wrap: wrap; }
.renew-installment-row .floatingInpuBox { flex: 1; min-width: 140px; margin: 0; }
.renew-installment-number { min-width: 48px; font-weight: 700; font-size: 0.85rem; }
.renew-installments-footer { display: flex; justify-content: space-between; align-items: center; flex-wrap: wrap; gap: 8px; }
.renew-installments-box p { margin: 0 0 8px; }
.renew-installments-box table { margin: 0; background: transparent; }
.debt-amount { color: #e0313f; font-weight: 700; }
.status.debt { color: #e0313f; background-color: rgba(255, 77, 94, .14); }

/* امور مالی: بازه سریع و گزارش یک مشتری */
.finance-quick-range { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; padding: 0 1.25rem 10px; }
.finance-quick-range .button { margin: 0; border-radius: 50px; }
.customer-finance-summary { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 20px; margin: 0 1.25rem 12px; padding: 12px 16px;
    border-radius: 14px; background: var(--bg-light-purple, #f3eeff); font-size: 0.85rem; }
.customer-finance-summary .paid b { color: #18a058; }
.customer-finance-summary .unpaid b { color: #e0313f; }

/* گزارش سیستم */
.syslog-stats { display: flex; gap: 12px; flex-wrap: wrap; margin-bottom: 16px; }
.syslog-stats > div { flex: 1; min-width: 120px; display: flex; flex-direction: column; gap: 4px; padding: 14px 18px; border-radius: 14px;
    background: var(--white-color, #fff); border: 1px solid var(--color-border-3, #e6e6ee); }
.syslog-stats span { font-size: 0.8rem; color: var(--color-gray-level-600); }
.syslog-stats strong { font-size: 1.4rem; }
.syslog-stats .ok strong { color: #18a058; }
.syslog-stats .fail strong { color: #e0313f; }
.syslog-paging { display: flex; justify-content: center; align-items: center; gap: 12px; }
.syslog-paging .button { margin: 0; }

/* لیست رزرو */
.reservation-help { margin-bottom: 14px; font-size: 13px; line-height: 1.9; }
.reservation-sites { max-width: 260px; font-size: 13px; }
.reservation-actions { white-space: nowrap; }
.reservation-actions .link-button { margin-inline-start: 8px; font-size: 13px; }
.d-block { display: block; }

/* همه دکمه‌ها (نه فقط primary) مثل «رزرو جدید» گرد با همان اندازه؛ دکمه مستطیلی نداریم */
.button.secondary,
.button.alert,
.button.success,
.button.warning {
    border-radius: 30px;
    font-weight: 700;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 0;
}
.button.secondary:not(.small),
.button.alert:not(.small),
.button.success:not(.small),
.button.warning:not(.small) {
    font-size: 0.933rem;
    height: 48px;
}
.button.secondary svg,
.button.alert svg { margin: 0 0 0 7px; }
.button.secondary.hollow,
.button.secondary.hollow:focus {
    border: 1px solid var(--secondary-color);
    color: var(--secondary-color);
    background: transparent;
}
.button.secondary.hollow:hover {
    border-color: var(--secondary-color);
    color: var(--secondary-color);
    background: rgba(111, 66, 216, 0.08);
}
.button.small { border-radius: 30px; }
/* بدون اسکرول داخلی: همه سایت‌های فیلترشده (مثلاً همه تهران) یکجا دیده شوند */
.reservation-sites-list { max-height: none; overflow: visible; }
.reservation-save { margin-top: 32px; padding-top: 20px; border-top: 1px solid var(--color-border-3, #eee); }
.secondary-site-star { color: #e53935; font-size: 14px; margin-inline-start: 3px; }
.reservation-form-card { padding: 32px 24px 24px; }
.reservation-form-card .floatingInpuBox { margin-bottom: 22px; }

/* ارسال شماره کارت */
.sms-preview { white-space: pre-wrap; font-family: inherit; background: #f6f4fb; border: 1px dashed #d8d0f0; border-radius: 10px; padding: 12px 16px; max-width: 420px; line-height: 1.9; font-size: 14px; }
.send-card-link { margin-inline-end: 10px; font-size: 13px; }
.send-card-btn { margin: 0 10px 0 0; }
.ad-tile-wrap { display: flex; flex-direction: column; gap: 8px; }
.ad-tile-wrap .ad-tile { flex: 1; }
.ad-tile-action { margin: 0; width: 100%; }
