/* ==========================================================================
   پیوند نیک — تم «فیروزه و زعفران»
   طراحی اپ‌مانند، RTL. تمام کلاس‌های قبلی حفظ شده‌اند.
   ========================================================================== */

/* ---------- فونت ---------- */
@font-face { font-family:'Vazirmatn'; src:url('../fonts/Vazirmatn-Regular.woff2') format('woff2'); font-weight:400; font-style:normal; font-display:swap; }
@font-face { font-family:'Vazirmatn'; src:url('../fonts/Vazirmatn-Medium.woff2') format('woff2'); font-weight:500; font-style:normal; font-display:swap; }
@font-face { font-family:'Vazirmatn'; src:url('../fonts/Vazirmatn-SemiBold.woff2') format('woff2'); font-weight:600; font-style:normal; font-display:swap; }
@font-face { font-family:'Vazirmatn'; src:url('../fonts/Vazirmatn-Bold.woff2') format('woff2'); font-weight:700; font-style:normal; font-display:swap; }
@font-face { font-family:'Vazirmatn'; src:url('../fonts/Vazirmatn-ExtraBold.woff2') format('woff2'); font-weight:800; font-style:normal; font-display:swap; }

/* ---------- توکن‌ها ---------- */
:root {
    /* برند (از تنظیمات ادمین بازنویسی می‌شود) */
    --primary: #0F6E73;
    --primary-dark: #08393E;
    --primary-light: #2AA3A5;
    --secondary: #BFE3DE;
    --accent: #8FD3CB;
    --gold: #F4A81D;          /* زعفرانی — رنگ اقدام اصلی */
    --on-gold: #1B2B2E;

    /* معنایی */
    --success: #1F8A4C;
    --error: #C93A3A;
    --warning: #D98A00;
    --info: #1F6FB5;

    /* سطوح و متن */
    --ink: #0E2428;
    --text: #17363A;
    --text-muted: #5B7679;
    --bg: #EEF5F4;
    --bg-card: #FFFFFF;
    --surface-2: #F6FAF9;
    --border: #D3E3E0;
    --line: #E3EEEC;
    --tint: rgba(15, 110, 115, .08);
    --tint-2: rgba(15, 110, 115, .14);

    --male: #2F6FD0;
    --female: #D6457B;

    /* شعاع‌ها */
    --radius: 22px;
    --radius-md: 16px;
    --radius-sm: 12px;
    --radius-pill: 999px;

    /* سایه‌ها (سایه‌ی سبز‌آبی) */
    --shadow-xs: 0 1px 2px rgba(8, 57, 62, .06);
    --shadow: 0 6px 24px -8px rgba(8, 57, 62, .16), 0 2px 6px rgba(8, 57, 62, .05);
    --shadow-lg: 0 24px 60px -20px rgba(8, 57, 62, .35), 0 8px 20px -10px rgba(8, 57, 62, .15);

    --ease: cubic-bezier(.22, 1, .36, 1);
    --transition: all .28s var(--ease);
    --font: 'Vazirmatn', Tahoma, sans-serif;

    --safe-top: env(safe-area-inset-top, 0px);
    --safe-bottom: env(safe-area-inset-bottom, 0px);
    --header-h: 72px;
    --tabbar-h: 68px;

    /* الگوی هندسی خاتم (۸پر) */
    --khatam: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='64' height='64' viewBox='0 0 64 64' fill='none' stroke='%23ffffff' stroke-opacity='.07' stroke-width='1.2'%3E%3Crect x='14' y='14' width='36' height='36'/%3E%3Crect x='14' y='14' width='36' height='36' transform='rotate(45 32 32)'/%3E%3Ccircle cx='32' cy='32' r='5'/%3E%3C/svg%3E");
}

/* ---------- ریست ---------- */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; font-size: 16px; -webkit-text-size-adjust: 100%; scroll-padding-top: calc(var(--header-h) + 12px); }
body {
    font-family: var(--font);
    background: var(--bg);
    color: var(--text);
    line-height: 1.75;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    -webkit-font-smoothing: antialiased;
    -webkit-tap-highlight-color: transparent;
    overscroll-behavior-y: none;
}
a { color: var(--primary); text-decoration: none; transition: color .2s, background .2s, opacity .2s; }
a:hover { color: var(--primary-dark); }
img, video { max-width: 100%; height: auto; }
iframe { max-width: 100%; }
button { font-family: inherit; }
h1, h2, h3, h4 { color: var(--ink); line-height: 1.4; }
::selection { background: var(--primary); color: #fff; }
:focus-visible { outline: 3px solid var(--gold); outline-offset: 2px; border-radius: 6px; }

.container { width: 100%; max-width: 1200px; margin: 0 auto; padding: 0 24px; }

/* ==========================================================================
   هدر دسکتاپ
   ========================================================================== */
.main-header {
    position: sticky; top: 0; z-index: 1000;
    background: rgba(255, 255, 255, .82);
    -webkit-backdrop-filter: saturate(1.6) blur(18px);
    backdrop-filter: saturate(1.6) blur(18px);
    border-bottom: 1px solid var(--line);
    transition: box-shadow .25s, background .25s;
}
.main-header.scrolled { box-shadow: 0 8px 30px -14px rgba(8, 57, 62, .28); background: rgba(255, 255, 255, .94); }

.navbar { display: flex; align-items: center; justify-content: space-between; gap: 16px; min-height: var(--header-h); }

.logo { display: flex; align-items: center; gap: 12px; color: var(--ink) !important; font-weight: 800; font-size: 1.3rem; flex-shrink: 0; }
.logo-img { width: 44px; height: 44px; object-fit: contain; border-radius: 13px; box-shadow: 0 4px 12px -4px rgba(8, 57, 62, .5); }
.logo-text { color: var(--primary-dark); letter-spacing: -.2px; }

.nav-menu { display: flex; list-style: none; gap: 2px; align-items: center; }
.nav-menu a {
    color: var(--text);
    padding: 9px 15px;
    border-radius: var(--radius-pill);
    font-weight: 500; font-size: .93rem;
    display: flex; align-items: center; gap: 8px;
    white-space: nowrap;
}
.nav-menu a i { color: var(--primary); opacity: .75; font-size: .92em; }
.nav-menu a:hover { background: var(--tint); color: var(--primary-dark); }
.nav-menu a.active { background: var(--primary); color: #fff; }
.nav-menu a.active i { color: #fff; opacity: 1; }
.nav-menu .btn-nav { background: var(--gold); color: var(--on-gold) !important; font-weight: 700; margin-right: 6px; box-shadow: 0 6px 16px -6px rgba(244, 168, 29, .8); }
.nav-menu .btn-nav i { color: var(--on-gold); opacity: 1; }
.nav-menu .btn-nav:hover { background: #E89B0C; transform: translateY(-1px); }

.nav-toggle { display: none; flex-direction: column; gap: 5px; background: var(--tint); border: none; cursor: pointer; padding: 12px; border-radius: 14px; }
.nav-toggle span { width: 20px; height: 2.5px; background: var(--primary-dark); border-radius: 3px; transition: var(--transition); }

.appbar-actions { display: none; }

/* منو و مگامنو */
.nav-item { position: relative; }
.sub-menu {
    display: none; position: absolute; top: calc(100% + 6px); right: 0; min-width: 210px;
    background: #fff; border-radius: var(--radius-md); box-shadow: var(--shadow-lg);
    padding: 8px; list-style: none; z-index: 1100; border: 1px solid var(--line);
}
.nav-item.has-sub:hover > .sub-menu, .nav-item.has-sub:focus-within > .sub-menu { display: block; animation: popIn .22s var(--ease); }
.sub-menu a { color: var(--text) !important; padding: 10px 14px; display: block; border-radius: 10px; }
.sub-menu a:hover { background: var(--tint); color: var(--primary) !important; }
.mega-panel {
    display: none; position: absolute; top: calc(100% + 6px); right: 0; left: auto;
    width: min(680px, 90vw); background: #fff; border-radius: var(--radius);
    box-shadow: var(--shadow-lg); padding: 26px; z-index: 1100; border: 1px solid var(--line); color: var(--text);
}
.nav-item.has-mega:hover > .mega-panel, .nav-item.has-mega:focus-within > .mega-panel { display: block; animation: popIn .22s var(--ease); }
@keyframes popIn { from { opacity: 0; transform: translateY(6px) scale(.98); } to { opacity: 1; transform: none; } }

.notif-badge {
    display: inline-flex; align-items: center; justify-content: center;
    min-width: 19px; height: 19px; padding: 0 5px; border-radius: var(--radius-pill);
    background: #E5484D; color: #fff; font-size: .68rem; font-weight: 700;
    margin-right: 2px; line-height: 1;
}
.nav-menu a.active .notif-badge { background: var(--gold); color: var(--on-gold); }

.nav-overlay { display: none; position: fixed; inset: 0; background: rgba(8, 30, 34, .55); -webkit-backdrop-filter: blur(4px); backdrop-filter: blur(4px); z-index: 1090; opacity: 0; transition: opacity .25s; }
.nav-overlay.active { display: block; opacity: 1; }
body.nav-open { overflow: hidden; }
.nav-toggle.active span:nth-child(1) { transform: translateY(7.5px) rotate(45deg); }
.nav-toggle.active span:nth-child(2) { opacity: 0; }
.nav-toggle.active span:nth-child(3) { transform: translateY(-7.5px) rotate(-45deg); }

/* ==========================================================================
   پیام‌های فلش (Toast)
   ========================================================================== */
.flash-container { position: fixed; top: calc(var(--header-h) + 14px); left: 50%; transform: translateX(-50%); z-index: 2000; width: 92%; max-width: 480px; }
.flash {
    display: flex; align-items: center; gap: 12px; padding: 14px 18px;
    border-radius: var(--radius-md); box-shadow: var(--shadow-lg);
    animation: toastIn .45s var(--ease); font-weight: 500; font-size: .95rem; background: #fff; border: 1px solid transparent;
}
.flash i { font-size: 1.15rem; }
.flash-success { background: #E7F6EC; color: #176B3B; border-color: #B7E3C6; }
.flash-error { background: #FDECEC; color: #A62B2B; border-color: #F2BDBD; }
.flash-info { background: #E6F1FA; color: #1A5C94; border-color: #BCD8F0; }
.flash-close { margin-right: auto; background: none; border: none; font-size: 1.4rem; cursor: pointer; opacity: .55; color: inherit; line-height: 1; }
@keyframes toastIn { from { opacity: 0; transform: translateY(-16px) scale(.97); } to { opacity: 1; transform: none; } }

/* ==========================================================================
   دکمه‌ها
   ========================================================================== */
.btn {
    display: inline-flex; align-items: center; justify-content: center; gap: 9px;
    padding: 12px 26px; border-radius: var(--radius-pill);
    font-family: var(--font); font-weight: 700; font-size: .98rem; line-height: 1.4;
    border: 2px solid transparent; cursor: pointer; transition: var(--transition);
    text-decoration: none; user-select: none; -webkit-user-select: none;
}
.btn:active { transform: scale(.96); }
.btn[disabled] { opacity: .5; cursor: not-allowed; }

.btn-primary { background: var(--gold); color: var(--on-gold); box-shadow: 0 8px 22px -8px rgba(244, 168, 29, .9); }
.btn-primary:hover { background: #E89B0C; color: var(--on-gold); transform: translateY(-2px); box-shadow: 0 14px 28px -10px rgba(244, 168, 29, .95); }
.btn-primary:active { transform: scale(.96); }

.btn-secondary { background: rgba(255, 255, 255, .16); color: #fff; border-color: rgba(255, 255, 255, .45); }
.btn-secondary:hover { background: rgba(255, 255, 255, .26); color: #fff; }

.btn-outline { background: transparent; color: var(--primary); border-color: var(--border); }
.btn-outline:hover { background: var(--primary); color: #fff; border-color: var(--primary); }

.btn-ghost { background: rgba(255, 255, 255, .08); color: #fff; border-color: rgba(255, 255, 255, .4); -webkit-backdrop-filter: blur(6px); backdrop-filter: blur(6px); }
.btn-ghost:hover { background: rgba(255, 255, 255, .18); color: #fff; border-color: #fff; }

.btn-success { background: var(--success); color: #fff; }
.btn-success:hover { background: #197641; color: #fff; }
.btn-danger { background: var(--error); color: #fff; }
.btn-danger:hover { background: #AE2E2E; color: #fff; }
.btn-sm { padding: 8px 16px; font-size: .85rem; }
.btn-lg { padding: 16px 34px; font-size: 1.05rem; }
.btn-block { width: 100%; }

/* ==========================================================================
   محتوا
   ========================================================================== */
.main-content { flex: 1; padding: 36px 0 24px; animation: pageIn .4s ease both; }
@keyframes pageIn { from { opacity: 0; } to { opacity: 1; } }

.section-title { text-align: right; margin-bottom: 28px; }
.section-title h2 { font-size: clamp(1.4rem, 3vw, 1.9rem); font-weight: 800; color: var(--ink); margin-bottom: 6px; display: flex; align-items: center; gap: 12px; }
.section-title h2 i { width: 44px; height: 44px; border-radius: 14px; background: var(--tint); color: var(--primary); display: inline-flex; align-items: center; justify-content: center; font-size: 1.1rem; flex-shrink: 0; }
.section-title p { color: var(--text-muted); font-size: .95rem; }

.empty-state { text-align: center; padding: 56px 20px; color: var(--text-muted); background: var(--bg-card); border: 1.5px dashed var(--border); border-radius: var(--radius); }
.empty-state i { font-size: 3.2rem; color: var(--accent); margin-bottom: 16px; display: block; }
.empty-state h3 { color: var(--ink); margin-bottom: 4px; }

.text-center { text-align: center; }
.mt-20 { margin-top: 20px; }
.mb-20 { margin-bottom: 20px; }
.d-none { display: none; }

/* ==========================================================================
   صفحه اصلی — هیرو
   ========================================================================== */
.hero-pro {
    position: relative; overflow: hidden; color: #fff;
    margin-top: -36px;
    padding: 72px 0 0;
    border-radius: 0 0 44px 44px;
    background:
        radial-gradient(900px 420px at 12% 0%, rgba(42, 163, 165, .55), transparent 60%),
        radial-gradient(700px 380px at 100% 100%, rgba(244, 168, 29, .16), transparent 60%),
        linear-gradient(160deg, var(--primary-dark) 0%, var(--primary) 100%);
}
.hero-bg { position: absolute; inset: 0; background-image: var(--khatam); background-size: 64px 64px; opacity: .9; pointer-events: none;
    -webkit-mask-image: linear-gradient(180deg, #000 20%, transparent 95%); mask-image: linear-gradient(180deg, #000 20%, transparent 95%); }
.hero-inner { position: relative; z-index: 1; display: grid; grid-template-columns: 1.1fr .9fr; gap: 48px; align-items: center; }
.hero-content { order: 1; max-width: 640px; text-align: right; padding-bottom: 28px; }
.hero-badge {
    display: inline-flex; align-items: center; gap: 8px;
    background: rgba(255, 255, 255, .12); border: 1px solid rgba(255, 255, 255, .22);
    padding: 7px 16px 7px 14px; border-radius: var(--radius-pill);
    font-size: .86rem; font-weight: 600; margin-bottom: 22px;
    -webkit-backdrop-filter: blur(10px); backdrop-filter: blur(10px);
}
.hero-badge i { color: var(--gold); }
.hero-pro h1 { color: #fff; font-size: clamp(2.1rem, 5vw, 3.5rem); font-weight: 800; line-height: 1.28; margin-bottom: 18px; letter-spacing: -.5px; }
.hero-lead { font-size: 1.1rem; color: rgba(255, 255, 255, .86); line-height: 2; margin-bottom: 30px; max-width: 54ch; }
.hero-btns { display: flex; gap: 12px; flex-wrap: wrap; }

.hero-art { order: 2; position: relative; display: flex; justify-content: center; align-self: stretch; align-items: center; }
.hero-art svg { width: 100%; max-width: 380px; height: auto; overflow: visible; filter: drop-shadow(0 30px 40px rgba(0, 0, 0, .25)); }
.hero-ring-a, .hero-ring-b { transform-box: fill-box; transform-origin: center; }
.hero-ring-a { animation: ringA 1.5s var(--ease) both .15s; }
.hero-ring-b { animation: ringB 1.5s var(--ease) both .15s; }
.hero-knot { animation: knotIn .8s var(--ease) both 1.25s; transform-box: fill-box; transform-origin: center; }
@keyframes ringA { from { transform: translateX(-70px); opacity: 0; } to { transform: none; opacity: 1; } }
@keyframes ringB { from { transform: translateX(70px); opacity: 0; } to { transform: none; opacity: 1; } }
@keyframes knotIn { from { transform: scale(.2); opacity: 0; } to { transform: none; opacity: 1; } }

.hero-stats {
    order: 3; grid-column: 1 / -1;
    display: grid; grid-template-columns: repeat(3, 1fr);
    margin: 0 0 -1px; padding: 0;
    background: rgba(255, 255, 255, .08);
    border: 1px solid rgba(255, 255, 255, .14); border-bottom: 0;
    border-radius: 26px 26px 0 0;
    -webkit-backdrop-filter: blur(14px); backdrop-filter: blur(14px);
}
.hero-stat { text-align: center; padding: 20px 12px; position: relative; }
.hero-stat + .hero-stat::before { content: ''; position: absolute; right: 0; top: 24%; bottom: 24%; width: 1px; background: rgba(255, 255, 255, .18); }
.hero-stat strong { display: block; font-size: clamp(1.4rem, 3vw, 2rem); font-weight: 800; color: #fff; line-height: 1.3; }
.hero-stat span { font-size: .84rem; color: rgba(255, 255, 255, .72); }

/* هیرو قدیمی */
.hero { background: linear-gradient(160deg, var(--primary-dark), var(--primary)); border-radius: var(--radius); padding: 56px 36px; text-align: center; color: #fff; margin-bottom: 44px; }
.hero h1 { font-size: 2.6rem; font-weight: 800; margin-bottom: 14px; color: #fff; }
.hero p { font-size: 1.15rem; opacity: .92; max-width: 600px; margin: 0 auto 26px; }
.hero-btns { position: relative; }

/* ==========================================================================
   ویژگی‌ها
   ========================================================================== */
.section-features { padding: 64px 0 24px; }
.features-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(230px, 1fr)); gap: 18px; }
.feature-card {
    background: var(--bg-card); border-radius: var(--radius); padding: 28px 24px;
    text-align: right; border: 1px solid var(--line); box-shadow: var(--shadow-xs); transition: var(--transition);
    position: relative; overflow: hidden;
}
.feature-card::after { content: ''; position: absolute; left: -30px; bottom: -30px; width: 110px; height: 110px; border-radius: 50%; border: 18px solid var(--tint); opacity: .7; transition: var(--transition); }
.feature-card:hover { transform: translateY(-5px); box-shadow: var(--shadow); border-color: var(--accent); }
.feature-card:hover::after { transform: scale(1.15); }
.feature-icon {
    width: 58px; height: 58px; margin: 0 0 18px; border-radius: 18px;
    background: var(--tint-2); color: var(--primary);
    display: flex; align-items: center; justify-content: center; font-size: 1.4rem;
}
.feature-card:nth-child(4n+2) .feature-icon { background: rgba(244, 168, 29, .2); color: #A86A00; }
.feature-card:nth-child(4n+3) .feature-icon { background: rgba(47, 111, 208, .13); color: var(--male); }
.feature-card:nth-child(4n+4) .feature-icon { background: rgba(214, 69, 123, .12); color: var(--female); }
.feature-card h3 { color: var(--ink); margin-bottom: 8px; font-size: 1.08rem; font-weight: 700; }
.feature-card p { color: var(--text-muted); font-size: .92rem; line-height: 1.9; position: relative; z-index: 1; }

/* ==========================================================================
   چطور کار می‌کند — مراحل
   ========================================================================== */
.section-how { padding: 56px 0 24px; }
.section-how .section-title { text-align: center; }
.section-how .section-title h2 { justify-content: center; }
.how-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 28px; counter-reset: step; }
.how-step { text-align: center; padding: 8px 10px; position: relative; }
.how-num {
    width: 52px; height: 52px; margin: 0 auto 16px; border-radius: 50%;
    background: var(--primary); color: #fff; font-weight: 800; font-size: 1.2rem;
    display: flex; align-items: center; justify-content: center;
    box-shadow: 0 0 0 6px var(--tint-2), 0 10px 22px -8px rgba(15, 110, 115, .7);
    position: relative; z-index: 1;
}
.how-step:not(:last-child)::after { content: ''; position: absolute; top: 34px; right: calc(50% + 40px); left: calc(-50% + 12px); border-top: 2px dashed var(--accent); }
.how-step h3 { color: var(--ink); margin-bottom: 6px; font-size: 1.05rem; }
.how-step p { color: var(--text-muted); font-size: .9rem; line-height: 1.85; }

/* ==========================================================================
   درباره
   ========================================================================== */
.section-about { padding: 40px 0; }
.about-box {
    position: relative; overflow: hidden;
    background: var(--bg-card); border: 1px solid var(--line);
    border-radius: var(--radius); padding: 44px 44px 44px 180px; text-align: right;
}
.about-box::before { content: ''; position: absolute; left: -50px; top: 50%; width: 220px; height: 220px; margin-top: -110px; border-radius: 50%; border: 26px solid var(--tint-2); }
.about-box::after { content: ''; position: absolute; left: 34px; top: 50%; width: 220px; height: 220px; margin-top: -110px; border-radius: 50%; border: 26px solid rgba(244, 168, 29, .28); }
.about-box h2 { color: var(--ink); margin-bottom: 12px; font-size: 1.6rem; position: relative; z-index: 1; }
.about-box p { max-width: 68ch; color: var(--text-muted); font-size: 1.02rem; line-height: 2.1; position: relative; z-index: 1; }

/* ==========================================================================
   اعضا — جستجو و کارت‌ها
   ========================================================================== */
.section-members { padding: 48px 0 32px; }
.members-search {
    display: flex; gap: 6px; align-items: center;
    max-width: 560px; margin: 0 0 28px;
    background: var(--bg-card); border: 1.5px solid var(--border); border-radius: var(--radius-pill);
    padding: 6px 6px 6px 6px; box-shadow: var(--shadow-xs); transition: var(--transition);
}
.members-search:focus-within { border-color: var(--primary); box-shadow: 0 0 0 5px var(--tint); }
.members-search .form-control { border: 0; background: transparent; box-shadow: none !important; padding: 10px 18px; min-height: 0; flex: 1; min-width: 0; }
.members-search .btn { padding: 11px 18px; flex-shrink: 0; }
.members-search .btn-outline { border-color: var(--border); }

.profiles-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(250px, 1fr)); gap: 22px; }
.profile-card {
    background: var(--bg-card); border-radius: var(--radius); overflow: hidden;
    border: 1px solid var(--line); box-shadow: var(--shadow-xs);
    transition: var(--transition); cursor: pointer; display: flex; flex-direction: column;
}
.profile-card:hover { transform: translateY(-6px); box-shadow: var(--shadow-lg); border-color: transparent; }
.profile-card:active { transform: scale(.985); }
.profile-photo-wrap { position: relative; aspect-ratio: 4 / 4.6; overflow: hidden; background: var(--secondary); }
.profile-photo-wrap::after { content: ''; position: absolute; inset: 40% 0 0 0; background: linear-gradient(180deg, transparent, rgba(6, 36, 40, .82)); pointer-events: none; }
.profile-photo {
    width: 100%; height: 100%; object-fit: cover; display: block;
    background: linear-gradient(110deg, #d3e6e2 8%, #e9f3f1 18%, #d3e6e2 33%); background-size: 200% 100%;
    transition: transform .7s var(--ease);
}
.profile-card:hover .profile-photo { transform: scale(1.06); }
.profile-overlay { position: absolute; z-index: 2; right: 16px; left: 16px; bottom: 14px; color: #fff; }
.profile-overlay .profile-name { color: #fff; margin: 0; text-shadow: 0 2px 10px rgba(0, 0, 0, .35); }
.profile-badge-gender {
    position: absolute; top: 12px; right: 12px; z-index: 3;
    width: 34px; height: 34px; border-radius: 50%;
    display: flex; align-items: center; justify-content: center; color: #fff; font-size: .9rem;
    border: 2px solid rgba(255, 255, 255, .85); box-shadow: 0 4px 12px rgba(0, 0, 0, .25);
}
.gender-male { background: var(--male); }
.gender-female { background: var(--female); }

.profile-body { padding: 14px 16px 16px; display: flex; flex-direction: column; gap: 8px; flex: 1; }
.profile-name { font-size: 1.15rem; font-weight: 800; color: var(--ink); margin: 0; }
.profile-meta { display: flex; flex-wrap: wrap; gap: 6px; font-size: .8rem; color: var(--text-muted); }
.profile-meta span { display: inline-flex; align-items: center; gap: 6px; background: var(--surface-2); border: 1px solid var(--line); padding: 3px 10px; border-radius: var(--radius-pill); }
.profile-meta span i { color: var(--primary); font-size: .85em; }
.profile-about { font-size: .9rem; color: var(--text-muted); display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.profile-card .btn-view { width: 100%; margin-top: auto; justify-content: center; }

.pagination { display: flex; justify-content: center; gap: 8px; margin-top: 40px; flex-wrap: wrap; }
.pagination a, .pagination span {
    min-width: 44px; height: 44px; padding: 0 14px; display: inline-flex; align-items: center; justify-content: center;
    border-radius: 14px; background: var(--bg-card); border: 1px solid var(--line); color: var(--text); font-weight: 600;
}
.pagination a:hover { background: var(--tint); border-color: var(--accent); color: var(--primary-dark); }
.pagination .active { background: var(--primary); color: #fff; border-color: var(--primary); box-shadow: 0 8px 18px -8px rgba(15, 110, 115, .8); }

/* ==========================================================================
   دعوت به اقدام
   ========================================================================== */
.section-cta { padding: 28px 0 56px; }
.cta-box {
    position: relative; overflow: hidden; text-align: right;
    background: linear-gradient(135deg, #FFF3D6 0%, #FFE5AE 100%);
    border: 1px solid #F3D48A; border-radius: var(--radius);
    padding: 48px 48px 48px 220px; color: var(--ink);
}
.cta-box::before, .cta-box::after { content: ''; position: absolute; width: 200px; height: 200px; border-radius: 50%; top: 50%; margin-top: -100px; border: 24px solid; }
.cta-box::before { left: -40px; border-color: rgba(15, 110, 115, .2); }
.cta-box::after { left: 40px; border-color: rgba(244, 168, 29, .55); }
.cta-box h2 { font-size: clamp(1.4rem, 3vw, 1.9rem); color: var(--ink); margin-bottom: 8px; position: relative; z-index: 1; }
.cta-box p { color: #4B5A42; margin-bottom: 24px; font-size: 1.02rem; position: relative; z-index: 1; }
.cta-box .btn { position: relative; z-index: 1; }
.cta-box .btn-primary { background: var(--primary-dark); color: #fff; box-shadow: 0 12px 24px -10px rgba(8, 57, 62, .8); }
.cta-box .btn-primary:hover { background: var(--primary); color: #fff; }

/* ==========================================================================
   فرم‌ها
   ========================================================================== */
.form-container {
    max-width: 560px; margin: 0 auto; background: var(--bg-card);
    padding: 40px 36px; border-radius: 30px; box-shadow: var(--shadow-lg); border: 1px solid var(--line);
    position: relative; overflow: hidden;
}
.form-container::before { content: ''; position: absolute; top: 0; right: 0; left: 0; height: 6px; background: linear-gradient(90deg, var(--primary), var(--primary-light) 55%, var(--gold)); }
.form-container h1 { text-align: center; color: var(--ink); margin-bottom: 6px; font-size: 1.7rem; font-weight: 800; }
.form-container h1 i { color: var(--primary); margin-left: 6px; }
.form-container .subtitle { text-align: center; color: var(--text-muted); margin-bottom: 28px; font-size: .95rem; }
.auth-mark { display: block; width: 68px; height: 68px; margin: 0 auto 14px; border-radius: 20px; box-shadow: 0 14px 28px -12px rgba(8, 57, 62, .7); }

.form-group { margin-bottom: 18px; }
.form-group label, .form-container label { display: block; font-weight: 600; margin-bottom: 7px; color: var(--ink); font-size: .92rem; }
.form-group label .required { color: var(--error); }
.form-control {
    width: 100%; min-height: 52px; padding: 13px 16px;
    border: 1.5px solid var(--border); border-radius: 14px;
    font-family: var(--font); font-size: 1rem; background: var(--surface-2); color: var(--text);
    transition: border-color .2s, box-shadow .2s, background .2s;
}
.form-control::placeholder { color: #93AAAD; }
.form-control:hover { border-color: #B7D0CC; }
.form-control:focus { outline: none; border-color: var(--primary); background: #fff; box-shadow: 0 0 0 5px var(--tint-2); }
.form-control.error, .form-control:user-invalid { border-color: var(--error); }
textarea.form-control { min-height: 120px; resize: vertical; line-height: 1.9; }
select.form-control {
    appearance: none; -webkit-appearance: none; cursor: pointer;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='14' height='14' fill='%230F6E73' viewBox='0 0 16 16'%3E%3Cpath d='M3.2 5.8a1 1 0 0 1 1.4 0L8 9.2l3.4-3.4a1 1 0 1 1 1.4 1.4L8.7 11.3a1 1 0 0 1-1.4 0L3.2 7.2a1 1 0 0 1 0-1.4z'/%3E%3C/svg%3E");
    background-repeat: no-repeat; background-position: left 16px center; padding-left: 42px;
}
input[type="checkbox"], input[type="radio"] { accent-color: var(--primary); width: 18px; height: 18px; }
input[type="file"].form-control { padding: 10px; cursor: pointer; }
input[type="file"]::file-selector-button { font-family: var(--font); margin-left: 12px; padding: 8px 16px; border: 0; border-radius: 10px; background: var(--primary); color: #fff; font-weight: 600; cursor: pointer; }

.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.form-hint { font-size: .8rem; color: var(--text-muted); margin-top: 6px; line-height: 1.8; }
.form-error { color: var(--error); font-size: .85rem; margin-top: 6px; }
.form-footer { text-align: center; margin-top: 22px; color: var(--text-muted); font-size: .94rem; }
.form-footer a { font-weight: 700; }

.pw-wrap { position: relative; }
.pw-wrap .form-control { padding-left: 50px; }
.pw-toggle { position: absolute; left: 6px; top: 50%; transform: translateY(-50%); width: 40px; height: 40px; border: 0; background: transparent; color: var(--text-muted); border-radius: 12px; cursor: pointer; font-size: 1rem; }
.pw-toggle:hover { background: var(--tint); color: var(--primary); }

/* ثبت‌نام مرحله‌ای (با جاوااسکریپت فعال می‌شود) */
.reg-progress { display: flex; align-items: center; gap: 8px; margin: 0 0 26px; }
.reg-progress .dot { flex: 1; height: 6px; border-radius: 6px; background: var(--line); position: relative; overflow: hidden; }
.reg-progress .dot::after { content: ''; position: absolute; inset: 0; background: var(--primary); transform: scaleX(0); transform-origin: right; transition: transform .45s var(--ease); }
.reg-progress .dot.done::after, .reg-progress .dot.current::after { transform: scaleX(1); }
.reg-progress .dot.current::after { background: var(--gold); }
.reg-step-label { display: flex; justify-content: space-between; align-items: baseline; margin-bottom: 18px; }
.reg-step-label strong { font-size: 1.05rem; color: var(--ink); }
.reg-step-label span { font-size: .85rem; color: var(--text-muted); }
form.js-stepper .reg-step { display: none; }
form.js-stepper .reg-step.is-active { display: block; animation: stepIn .4s var(--ease); }
@keyframes stepIn { from { opacity: 0; transform: translateX(-24px); } to { opacity: 1; transform: none; } }
.reg-nav { display: flex; gap: 10px; margin-top: 8px; }
.reg-nav .btn { flex: 1; }
.reg-nav .btn-outline { flex: 0 0 auto; }

/* ==========================================================================
   پروفایل کاربر
   ========================================================================== */
.profile-panel { display: grid; grid-template-columns: 310px 1fr; gap: 26px; align-items: start; }
.profile-sidebar {
    background: var(--bg-card); border-radius: var(--radius); padding: 28px 24px;
    box-shadow: var(--shadow); border: 1px solid var(--line); text-align: center;
    position: sticky; top: calc(var(--header-h) + 16px);
}
.profile-sidebar h3 { font-size: 1.2rem; font-weight: 800; }
.profile-avatar {
    width: 148px; height: 148px; border-radius: 50%; object-fit: cover; margin: 0 auto 18px; display: block;
    border: 4px solid #fff; box-shadow: 0 0 0 4px var(--primary-light), 0 0 0 9px var(--tint-2), var(--shadow);
}
.profile-status { display: inline-block; padding: 5px 16px; border-radius: var(--radius-pill); font-size: .82rem; font-weight: 700; margin-bottom: 14px; }
.status-pending { background: #FFF3D6; color: #8A5A00; }
.status-approved { background: #E3F5EA; color: #176B3B; }
.status-rejected { background: #FCE7E7; color: #A62B2B; }

.profile-main { background: var(--bg-card); border-radius: var(--radius); padding: 30px; box-shadow: var(--shadow); border: 1px solid var(--line); }
.profile-main h2, .profile-form-card h2 { color: var(--ink); margin-bottom: 20px; padding-bottom: 14px; border-bottom: 1px solid var(--line); font-size: 1.2rem; display: flex; align-items: center; gap: 10px; }
.profile-main h2 i { color: var(--primary); }
.profile-form-card { background: var(--surface-2); border: 1px solid var(--line); border-radius: var(--radius-md); padding: 22px; }

.completion { text-align: right; margin: 18px 0 4px; padding: 14px; border-radius: var(--radius-md); background: var(--surface-2); border: 1px solid var(--line); }
.completion-head { display: flex; justify-content: space-between; font-size: .85rem; font-weight: 700; color: var(--ink); margin-bottom: 8px; }
.completion-bar { height: 8px; border-radius: 8px; background: var(--line); overflow: hidden; }
.completion-bar i { display: block; height: 100%; width: 0; border-radius: 8px; background: linear-gradient(90deg, var(--primary), var(--gold)); transition: width .8s var(--ease); }

.info-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(190px, 1fr)); gap: 14px; margin-bottom: 24px; }
.info-item { background: var(--surface-2); border: 1px solid var(--line); border-radius: 14px; padding: 12px 14px; }
.info-item label { font-size: .76rem; color: var(--text-muted); display: block; margin-bottom: 2px; font-weight: 500; }
.info-item span { font-weight: 700; color: var(--ink); }

.photo-upload-area { border: 2px dashed var(--accent); border-radius: var(--radius-md); padding: 22px 16px; text-align: center; transition: var(--transition); cursor: pointer; background: var(--surface-2); }
.photo-upload-area:hover, .photo-upload-area.dragover { border-color: var(--primary); background: var(--tint); }
.photo-upload-area i { font-size: 2.2rem; color: var(--primary); margin-bottom: 8px; display: block; }
.photo-upload-area p { font-weight: 600; font-size: .92rem; }

.gallery-item-manage { border-radius: 14px !important; transition: var(--transition); }
.gallery-item-manage:hover { transform: translateY(-2px); box-shadow: var(--shadow); }
.checkbox-label { cursor: pointer; }

#cropperModal { display: none; position: fixed; inset: 0; background: rgba(6, 28, 31, .82); -webkit-backdrop-filter: blur(6px); backdrop-filter: blur(6px); z-index: 3000; align-items: center; justify-content: center; padding: 16px; }
#cropperModal.active { display: flex; }
.cropper-container-modal { background: #fff; border-radius: 26px; padding: 22px; max-width: 94vw; max-height: 92vh; overflow: auto; width: 520px; animation: sheetUp .35s var(--ease); }
.cropper-container-modal img { max-width: 100%; }
.cropper-actions { display: flex; gap: 10px; justify-content: center; margin-top: 16px; }

/* ==========================================================================
   مودال پروفایل (Bottom Sheet روی موبایل)
   ========================================================================== */
.modal-overlay {
    display: none; position: fixed; inset: 0; background: rgba(6, 28, 31, .66);
    -webkit-backdrop-filter: blur(8px); backdrop-filter: blur(8px);
    z-index: 5000; align-items: center; justify-content: center; padding: 20px; animation: fadeIn .25s ease;
}
.modal-overlay.active { display: flex; }
@keyframes fadeIn { from { opacity: 0; } to { opacity: 1; } }
.modal-box {
    background: var(--bg-card); border-radius: 30px; max-width: 540px; width: 100%; max-height: 92vh;
    overflow-y: auto; overscroll-behavior: contain; box-shadow: var(--shadow-lg); animation: sheetUp .38s var(--ease); position: relative;
}
@keyframes sheetUp { from { opacity: 0; transform: translateY(40px) scale(.98); } to { opacity: 1; transform: none; } }
.sheet-handle { display: none; position: absolute; top: 8px; left: 50%; transform: translateX(-50%); width: 44px; height: 5px; border-radius: 5px; background: rgba(255, 255, 255, .85); z-index: 3; box-shadow: 0 1px 4px rgba(0, 0, 0, .3); }
.modal-close {
    position: absolute; top: 14px; left: 14px; width: 42px; height: 42px; border-radius: 50%; border: none;
    background: rgba(255, 255, 255, .9); color: var(--ink); font-size: 1.4rem; cursor: pointer; z-index: 4;
    display: flex; align-items: center; justify-content: center; transition: var(--transition); box-shadow: var(--shadow);
    -webkit-backdrop-filter: blur(6px); backdrop-filter: blur(6px);
}
.modal-close:hover { background: var(--error); color: #fff; }
.modal-photo { width: 100%; height: 360px; object-fit: cover; background: var(--secondary); display: block; }
.modal-body { padding: 26px 26px 30px; position: relative; margin-top: -26px; background: var(--bg-card); border-radius: 26px 26px 0 0; }
.modal-name { font-size: 1.6rem; font-weight: 800; color: var(--ink); margin-bottom: 2px; }
.modal-id { font-size: .82rem; color: var(--text-muted); font-family: ui-monospace, monospace; margin-bottom: 16px; direction: rtl; }
.modal-tags { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 20px; }
.modal-tag { background: var(--tint); color: var(--primary-dark); padding: 6px 14px; border-radius: var(--radius-pill); font-size: .84rem; font-weight: 600; display: inline-flex; gap: 6px; align-items: center; }
.modal-tag i { color: var(--primary); }
.modal-section { margin-bottom: 18px; padding: 16px; background: var(--surface-2); border: 1px solid var(--line); border-radius: var(--radius-md); }
.modal-section h4 { font-size: .9rem; color: var(--primary-dark); margin-bottom: 6px; font-weight: 700; display: flex; gap: 8px; align-items: center; }
.modal-section p { color: var(--text-muted); line-height: 2; font-size: .95rem; }

#modalGallerySection { display: block; margin-top: 16px; }
.modal-gallery { display: grid !important; grid-template-columns: repeat(auto-fill, minmax(88px, 1fr)); gap: 8px; margin-top: 8px; min-height: 40px; }
.modal-gallery-item { display: block !important; border-radius: 14px; overflow: hidden; aspect-ratio: 1 / 1; background: var(--secondary); border: 0; transition: transform .2s var(--ease); position: relative; }
.modal-gallery-item:hover { transform: scale(1.04); }
.modal-gallery-item img { width: 100% !important; height: 100% !important; object-fit: cover !important; display: block !important; }
button.modal-gallery-item { padding: 0 !important; margin: 0 !important; border: none !important; background: transparent !important; cursor: pointer !important; font: inherit; appearance: none; -webkit-appearance: none; width: 100%; height: auto; overflow: hidden; border-radius: 14px; display: block; position: relative; }
button.modal-gallery-item img { pointer-events: none; width: 100%; height: 100%; object-fit: cover; display: block; }
.gallery-item-manage img { cursor: zoom-in; }

/* لایت‌باکس */
body.lightbox-open { overflow: hidden !important; }
.lightbox-overlay { display: none; position: fixed !important; inset: 0 !important; width: 100% !important; height: 100% !important; z-index: 99999 !important; background: rgba(4, 20, 23, .95) !important; -webkit-backdrop-filter: blur(12px); backdrop-filter: blur(12px); margin: 0; padding: 0; box-sizing: border-box; }
.lightbox-overlay.active { display: flex !important; align-items: center; justify-content: center; flex-direction: column; }
.lightbox-stage { display: flex; align-items: center; justify-content: center; max-width: 94vw; max-height: 80vh; max-height: 80dvh; pointer-events: none; }
.lightbox-img { max-width: 94vw; max-height: 80vh; max-height: 80dvh; width: auto; height: auto; object-fit: contain; border-radius: 16px; box-shadow: 0 20px 60px rgba(0, 0, 0, .6); user-select: none; -webkit-user-select: none; pointer-events: auto; transition: opacity .15s ease; background: #0a1f22; }
.lightbox-close, .lightbox-nav { position: fixed !important; border: none; border-radius: 50%; background: rgba(255, 255, 255, .14); color: #fff; cursor: pointer; z-index: 100001 !important; display: flex; align-items: center; justify-content: center; padding: 0; -webkit-backdrop-filter: blur(8px); backdrop-filter: blur(8px); transition: background .2s; }
.lightbox-close { top: max(14px, env(safe-area-inset-top)); left: 14px; width: 48px; height: 48px; font-size: 2rem; line-height: 1; }
.lightbox-nav { top: 50%; transform: translateY(-50%); width: 48px; height: 48px; font-size: 1.15rem; }
.lightbox-close:hover, .lightbox-nav:hover { background: rgba(255, 255, 255, .3); }
.lightbox-prev { right: 12px; }
.lightbox-next { left: 12px; }
.lightbox-counter { position: fixed; bottom: max(18px, env(safe-area-inset-bottom)); left: 50%; transform: translateX(-50%); color: #fff; font-size: .92rem; background: rgba(0, 0, 0, .45); padding: 6px 16px; border-radius: 20px; z-index: 100001; pointer-events: none; }

/* ==========================================================================
   تیکت (گفتگو)، اطلاع‌رسانی، سوالات متداول
   ========================================================================== */
.page-narrow { max-width: 760px; margin-left: auto; margin-right: auto; }
.page-head { display: flex; align-items: center; gap: 14px; margin-bottom: 22px; }
.page-head h1 { font-size: 1.5rem; font-weight: 800; color: var(--ink); display: flex; align-items: center; gap: 12px; margin: 0; }
.page-head h1 i { width: 46px; height: 46px; border-radius: 15px; background: var(--tint-2); color: var(--primary); display: inline-flex; align-items: center; justify-content: center; font-size: 1.1rem; }

#ticketMessages { display: flex; flex-direction: column; gap: 10px; max-height: 58vh; overflow-y: auto; padding: 16px; background: var(--surface-2); border: 1px solid var(--line); border-radius: var(--radius); scroll-behavior: smooth; }
.ticket-msg { max-width: 86%; padding: 11px 15px; border-radius: 20px 20px 6px 20px; background: var(--primary); color: #fff; align-self: flex-start; box-shadow: var(--shadow-xs); animation: msgIn .3s var(--ease); }
.ticket-msg strong { font-size: .8rem; opacity: .9; }
.ticket-msg small { opacity: .7; margin-right: 8px; font-size: .72rem; }
.ticket-msg p { margin: 4px 0 0; line-height: 1.9; font-size: .95rem; }
.ticket-msg.is-admin { align-self: flex-end; background: #fff; color: var(--text); border: 1px solid var(--line); border-radius: 20px 20px 20px 6px; }
.ticket-msg.is-admin strong { color: var(--primary); }
@keyframes msgIn { from { opacity: 0; transform: translateY(10px) scale(.98); } to { opacity: 1; transform: none; } }
#replyForm { display: flex; gap: 10px; align-items: flex-end; margin-top: 12px; }
#replyForm textarea { min-height: 52px; flex: 1; }
#replyForm .btn { margin-top: 0 !important; height: 52px; }

.notif-item { position: relative; background: var(--bg-card); border: 1px solid var(--line); border-radius: var(--radius-md); padding: 16px 20px; margin-bottom: 12px; }
.notif-item.unread { background: linear-gradient(90deg, var(--tint), #fff 40%); border-color: var(--accent); }
.notif-item.unread::before { content: ''; position: absolute; top: 20px; right: -5px; width: 10px; height: 10px; border-radius: 50%; background: var(--gold); box-shadow: 0 0 0 4px rgba(244, 168, 29, .25); }
.notif-item strong { color: var(--ink); }
.notif-item small { display: block; color: var(--text-muted); margin: 3px 0 8px; font-size: .78rem; }
.notif-item p { margin: 0; color: var(--text-muted); line-height: 1.9; }

.faq-item { background: var(--bg-card); border: 1px solid var(--line); border-radius: var(--radius-md); margin-bottom: 10px; overflow: hidden; transition: border-color .2s, box-shadow .2s; }
.faq-item[open] { border-color: var(--accent); box-shadow: var(--shadow-xs); }
.faq-item summary { list-style: none; cursor: pointer; padding: 16px 20px; font-weight: 700; color: var(--ink); display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.faq-item summary::-webkit-details-marker { display: none; }
.faq-item summary::after { content: '\f078'; font-family: 'Font Awesome 6 Free'; font-weight: 900; font-size: .75rem; color: var(--primary); width: 30px; height: 30px; border-radius: 50%; background: var(--tint); display: inline-flex; align-items: center; justify-content: center; transition: transform .3s var(--ease); flex-shrink: 0; }
.faq-item[open] summary::after { transform: rotate(180deg); }
.faq-item p { padding: 0 20px 18px; color: var(--text-muted); line-height: 2; }

/* ==========================================================================
   بلاگ
   ========================================================================== */
.blog-layout { display: grid; grid-template-columns: 1fr 300px; gap: 28px; align-items: start; }
.blog-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); gap: 22px; }
.blog-card { background: var(--bg-card); border-radius: var(--radius); overflow: hidden; border: 1px solid var(--line); box-shadow: var(--shadow-xs); transition: var(--transition); display: flex; flex-direction: column; }
.blog-card:hover { transform: translateY(-5px); box-shadow: var(--shadow); }
.blog-card > a { display: block; overflow: hidden; }
.blog-card img { width: 100%; aspect-ratio: 16 / 10; height: auto; object-fit: cover; display: block; transition: transform .6s var(--ease); background: var(--secondary); }
.blog-card:hover img { transform: scale(1.05); }
.blog-card-body { padding: 18px 20px 22px; }
.blog-card h2 { font-size: 1.1rem; color: var(--ink); margin-bottom: 8px; line-height: 1.7; }
.blog-card h2 a { color: inherit; }
.blog-card h2 a:hover { color: var(--primary); }
.blog-meta { font-size: .78rem; color: var(--text-muted); margin-bottom: 8px; }
.blog-excerpt { color: var(--text-muted); font-size: .9rem; line-height: 1.9; }
.blog-side-box { background: var(--bg-card); border: 1px solid var(--line); border-radius: var(--radius-md); padding: 18px; margin-bottom: 16px; }
.blog-side-box h3 { color: var(--ink); font-size: 1rem; margin-bottom: 10px; display: flex; gap: 8px; align-items: center; }
.blog-side-box h3 i { color: var(--gold); }
.blog-side-box a { display: block; padding: 9px 0; border-bottom: 1px solid var(--line); color: var(--text); font-size: .9rem; }
.blog-side-box a:last-child { border-bottom: 0; }
.blog-side-box a:hover { color: var(--primary); padding-right: 4px; }
.blog-single { max-width: 800px; margin: 0 auto; background: var(--bg-card); border: 1px solid var(--line); border-radius: var(--radius); padding: 32px; }
.blog-single h1 { color: var(--ink); font-size: clamp(1.5rem, 3.4vw, 2.1rem); line-height: 1.6; }
.blog-single img.featured { width: 100%; border-radius: var(--radius-md); margin-bottom: 24px; max-height: 420px; object-fit: cover; }
.blog-single .content, .content { line-height: 2.1; font-size: 1.04rem; color: var(--text); }
.blog-extra { max-width: 800px; margin-left: auto; margin-right: auto; }
.related-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; }
.related-grid a { display: block; background: var(--bg-card); border: 1px solid var(--line); border-radius: var(--radius-md); padding: 14px; color: var(--text); font-size: .9rem; font-weight: 600; }
.related-grid a:hover { border-color: var(--accent); color: var(--primary); }
.comment-item { background: var(--bg-card); border: 1px solid var(--line); border-radius: var(--radius-md); padding: 14px 16px; margin-bottom: 10px; }
.comment-item small { color: var(--text-muted); margin-right: 6px; }
.comment-form { margin-top: 20px; background: var(--surface-2); padding: 18px; border-radius: var(--radius-md); border: 1px solid var(--line); }
.seo-box { background: #F1FAF5; border: 1px solid #BFE5CD; border-radius: var(--radius-md); padding: 20px; margin: 20px 0; }
.seo-box h3 { color: var(--success); margin-bottom: 12px; font-size: 1rem; }
.seo-score { display: inline-block; padding: 4px 12px; border-radius: var(--radius-pill); font-weight: 700; font-size: .85rem; }
.seo-score.good { background: #C9EBD6; color: #12602F; }
.seo-score.ok { background: #FFEFC2; color: #8A5A00; }
.seo-score.bad { background: #F8CFCF; color: #9A2323; }

/* ==========================================================================
   اسلایدر (۲۰ سبک)
   ========================================================================== */
.pn-slider { position: relative; overflow: hidden; width: 100%; margin: 0 auto 30px; border-radius: var(--radius); direction: ltr; background: var(--primary-dark); }
.pn-slider-track { display: flex !important; flex-direction: row !important; flex-wrap: nowrap !important; height: 100%; width: 100%; margin: 0; padding: 0; transition: transform .6s var(--ease); will-change: transform; direction: ltr; }
.pn-slide { flex: 0 0 100% !important; width: 100% !important; max-width: 100% !important; min-width: 100% !important; height: 100% !important; position: relative; background-color: #0B4A50; background-size: cover !important; background-position: center center !important; background-repeat: no-repeat !important; display: flex; align-items: center; justify-content: center; box-sizing: border-box; overflow: hidden; }
.pn-slide-overlay { position: absolute; inset: 0; background: linear-gradient(135deg, rgba(8, 57, 62, .6), rgba(15, 110, 115, .3)); pointer-events: none; z-index: 1; }
.pn-slide-content { position: relative; z-index: 2; text-align: center; color: #fff; padding: 40px 24px; max-width: 700px; direction: rtl; }
.pn-slide-content h2 { font-size: clamp(1.5rem, 4vw, 2.5rem); margin-bottom: 12px; font-weight: 800; color: inherit; }
.pn-slide-content p { font-size: 1.05rem; opacity: .95; margin-bottom: 20px; line-height: 1.9; }
.pn-slider-nav { position: absolute; top: 50%; transform: translateY(-50%); z-index: 5; width: 44px; height: 44px; border-radius: 50%; border: none; background: rgba(255, 255, 255, .25); color: #fff; cursor: pointer; font-size: 1.2rem; -webkit-backdrop-filter: blur(6px); backdrop-filter: blur(6px); line-height: 1; transition: background .2s; }
.pn-slider-nav:hover { background: var(--gold); color: var(--on-gold); }
.pn-slider-prev { right: 16px; }
.pn-slider-next { left: 16px; }
.pn-slider-dots { position: absolute; bottom: 16px; left: 0; right: 0; display: flex; justify-content: center; gap: 8px; z-index: 5; direction: ltr; }
.pn-slider-dots button { width: 9px; height: 9px; border-radius: 50%; border: none; background: rgba(255, 255, 255, .5); cursor: pointer; padding: 0; transition: all .3s var(--ease); }
.pn-slider-dots button.active { background: var(--gold); width: 26px; border-radius: 6px; }

.pn-s1 .pn-slide-overlay { background: linear-gradient(135deg, rgba(8, 57, 62, .75), rgba(15, 110, 115, .4)); }
.pn-s2 .pn-slide { animation: none; }
.pn-s2 .pn-slide-content { -webkit-backdrop-filter: blur(8px); backdrop-filter: blur(8px); background: rgba(0, 0, 0, .25); border-radius: 18px; padding: 32px; }
.pn-s3 .pn-slide { transform-origin: center; }
.pn-s4 .pn-slide-content { background: #fff; color: var(--text); border-radius: 18px; box-shadow: var(--shadow-lg); }
.pn-s4 .pn-slide-content h2 { color: var(--primary); }
.pn-s4 .pn-slide-overlay { background: rgba(0, 0, 0, .3); }
.pn-s5 .pn-slide-overlay { background: rgba(255, 255, 255, .35); }
.pn-s5 .pn-slide-content { color: var(--text); }
.pn-s5 .pn-slide-content h2 { color: var(--primary); }
.pn-s6 .pn-slide-overlay { background: linear-gradient(90deg, var(--primary), var(--primary-light)); opacity: .85; }
.pn-s7 .pn-slide-content { border-right: 4px solid var(--gold); text-align: right; padding-right: 28px; }
.pn-s8 .pn-slide-content { transform: perspective(600px) rotateY(-4deg); }
.pn-s9 .pn-slide-content { writing-mode: horizontal-tb; }
.pn-s10 .pn-slider-dots button { width: 12px; height: 12px; border: 2px solid #fff; background: transparent; }
.pn-s10 .pn-slider-dots button.active { background: #fff; }
.pn-s11 .pn-slide-overlay { background: rgba(0, 0, 0, .75); }
.pn-s12 .pn-slide-overlay { background: rgba(255, 255, 255, .3); }
.pn-s12 .pn-slide-content { color: var(--primary-dark); }
.pn-s13 .pn-slide-overlay { background: linear-gradient(135deg, rgba(244, 168, 29, .8), rgba(15, 110, 115, .6)); }
.pn-s14 .pn-slide-content { background: rgba(255, 255, 255, .15); -webkit-backdrop-filter: blur(12px); backdrop-filter: blur(12px); border: 1px solid rgba(255, 255, 255, .3); border-radius: 22px; }
.pn-s15 { border-radius: 0; }
.pn-s16 .pn-slide-content { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; text-align: right; max-width: 900px; }
.pn-s17 .pn-slide-overlay { background: linear-gradient(to top, rgba(0, 0, 0, .8), transparent); }
.pn-s17 .pn-slide-content { align-self: flex-end; text-align: right; width: 100%; max-width: none; padding: 40px; }
.pn-s18 .pn-slide { border: 6px solid var(--gold); box-sizing: border-box; }
.pn-s19 { border-radius: 40px; }
.pn-s19 .pn-slide { border-radius: 40px; }
.pn-s20 .pn-slide-content h2 { background: linear-gradient(90deg, #fff, var(--gold)); -webkit-background-clip: text; -webkit-text-fill-color: transparent; background-clip: text; }

/* ==========================================================================
   گالری (۲۰ سبک)
   ========================================================================== */
.pn-gal { margin: 40px auto; }
.pn-gal-title { text-align: center; color: var(--ink); margin-bottom: 28px; font-size: 1.8rem; }
.pn-gal-grid { display: grid; gap: 16px; }
.pn-gal-item { position: relative; overflow: hidden; border-radius: 16px; background: var(--secondary); }
.pn-gal-item img { width: 100%; height: 220px; object-fit: cover; display: block; transition: transform .5s var(--ease); }
.pn-gal-item:hover img { transform: scale(1.06); }
.pn-gal-cap { position: absolute; bottom: 0; left: 0; right: 0; padding: 22px 14px 10px; background: linear-gradient(transparent, rgba(6, 36, 40, .8)); color: #fff; font-size: .9rem; }
.pn-g1 .pn-gal-grid { grid-template-columns: repeat(3, 1fr); }
.pn-g2 { overflow: hidden; }
.pn-g2 .pn-gal-grid { display: flex; gap: 14px; overflow-x: auto; scroll-snap-type: x mandatory; padding-bottom: 12px; }
.pn-g2 .pn-gal-item { min-width: 280px; scroll-snap-align: start; flex-shrink: 0; }
.pn-g3 .pn-gal-grid { columns: 3; column-gap: 14px; display: block; }
.pn-g3 .pn-gal-item { break-inside: avoid; margin-bottom: 14px; }
.pn-g3 .pn-gal-item img { height: auto; }
.pn-g4 .pn-gal-item { background: #fff; padding: 10px 10px 36px; box-shadow: 0 8px 24px rgba(0, 0, 0, .12); transform: rotate(-1.5deg); }
.pn-g4 .pn-gal-item:nth-child(even) { transform: rotate(1.5deg); }
.pn-g4 .pn-gal-item img { height: 180px; }
.pn-g4 .pn-gal-cap { color: var(--text); background: none; bottom: 8px; }
.pn-g5 .pn-gal-item { border-radius: 50%; aspect-ratio: 1; }
.pn-g5 .pn-gal-item img { height: 100%; border-radius: 50%; }
.pn-g5 .pn-gal-cap { display: none; }
.pn-g6 .pn-gal-grid { grid-template-columns: 1fr; max-width: 700px; margin: 0 auto; }
.pn-g6 .pn-gal-item img { height: 360px; }
.pn-g7 .pn-gal-item::after { content: ''; position: absolute; inset: 0; background: rgba(15, 110, 115, 0); transition: .3s; }
.pn-g7 .pn-gal-item:hover::after { background: rgba(15, 110, 115, .35); }
.pn-g8 .pn-gal-item { border: 4px solid var(--gold); }
.pn-g9 .pn-gal-item { background: #0a1f22; }
.pn-g9 .pn-gal-item img { opacity: .9; filter: grayscale(.3); }
.pn-g10 .pn-gal-item { border: 3px solid #fff; box-shadow: 0 4px 20px rgba(0, 0, 0, .08); }
.pn-g11 .pn-gal-grid { gap: 4px; }
.pn-g11 .pn-gal-item { border-radius: 0; }
.pn-g12 .pn-gal-item:nth-child(3n+1) { grid-row: span 2; }
.pn-g12 .pn-gal-item:nth-child(3n+1) img { height: 100%; min-height: 460px; }
.pn-g13 .pn-gal-item { box-shadow: 0 12px 40px rgba(15, 110, 115, .2); border-radius: 22px; }
.pn-g14 .pn-gal-grid { gap: 0; }
.pn-g14 .pn-gal-item { border-radius: 0; }
.pn-g15 .pn-gal-item { transition: transform .3s, box-shadow .3s; }
.pn-g15 .pn-gal-item:hover { transform: translateY(-10px); box-shadow: 0 20px 40px rgba(0, 0, 0, .15); }
.pn-g16 .pn-gal-item { padding: 8px; background: #E6F1EE; border: 1px solid #C9DDD8; border-radius: 6px; }
.pn-g16 .pn-gal-item img { height: 200px; }
.pn-g17 .pn-gal-grid { grid-template-columns: repeat(6, 1fr); gap: 6px; }
.pn-g17 .pn-gal-item img { height: 120px; }
.pn-g18 .pn-gal-grid { display: flex; gap: 16px; overflow-x: auto; scroll-behavior: smooth; }
.pn-g18 .pn-gal-item { min-width: 240px; flex-shrink: 0; border-radius: 26px; }
.pn-g19 .pn-gal-item:nth-child(odd) img { height: 280px; }
.pn-g19 .pn-gal-item:nth-child(even) img { height: 180px; }
.pn-g20 .pn-gal-item { border-radius: 0; box-shadow: 0 0 0 1px var(--gold), 0 20px 50px rgba(0, 0, 0, .15); }
.pn-g20 .pn-gal-cap { background: linear-gradient(transparent, rgba(8, 57, 62, .92)); font-weight: 600; }

/* ==========================================================================
   پنل مدیریت
   ========================================================================== */
.admin-layout { display: grid; grid-template-columns: 270px 1fr; gap: 26px; min-height: 70vh; align-items: start; }
.admin-sidebar {
    background: linear-gradient(180deg, var(--primary-dark) 0%, #0A4B51 100%);
    background-image: var(--khatam), linear-gradient(180deg, var(--primary-dark) 0%, #0A4B51 100%);
    color: #fff; border-radius: var(--radius); padding: 22px 14px; box-shadow: var(--shadow-lg);
    position: sticky; top: calc(var(--header-h) + 16px); max-height: calc(100vh - var(--header-h) - 32px); overflow-y: auto;
}
.admin-sidebar::-webkit-scrollbar { width: 6px; }
.admin-sidebar::-webkit-scrollbar-thumb { background: rgba(255, 255, 255, .2); border-radius: 6px; }
.admin-sidebar h3 { color: #fff; margin: 0 8px 16px; font-size: 1.05rem; display: flex; align-items: center; gap: 10px; }
.admin-sidebar h3 i { width: 36px; height: 36px; border-radius: 12px; background: rgba(255, 255, 255, .12); display: inline-flex; align-items: center; justify-content: center; color: var(--gold); }
.admin-menu { list-style: none; }
.admin-menu a { display: flex; align-items: center; gap: 12px; padding: 11px 14px; border-radius: 14px; color: rgba(255, 255, 255, .82); font-weight: 500; font-size: .93rem; margin-bottom: 2px; position: relative; }
.admin-menu a i { width: 20px; text-align: center; color: var(--accent); opacity: .85; }
.admin-menu a:hover { background: rgba(255, 255, 255, .09); color: #fff; }
.admin-menu a.active { background: rgba(255, 255, 255, .15); color: #fff; font-weight: 700; }
.admin-menu a.active::before { content: ''; position: absolute; right: -14px; top: 22%; bottom: 22%; width: 5px; border-radius: 5px 0 0 5px; background: var(--gold); }
.admin-menu a.active i { color: var(--gold); opacity: 1; }

.admin-content { background: var(--bg-card); border-radius: var(--radius); padding: 30px; box-shadow: var(--shadow); border: 1px solid var(--line); min-width: 0; }
.admin-content h1 { color: var(--ink); margin-bottom: 22px; font-size: 1.5rem; font-weight: 800; display: flex; align-items: center; gap: 12px; }
.admin-content h1 > i { width: 46px; height: 46px; border-radius: 15px; background: var(--tint-2); color: var(--primary); display: inline-flex; align-items: center; justify-content: center; font-size: 1.1rem; flex-shrink: 0; }
.admin-content h2 { color: var(--ink) !important; font-size: 1.15rem; }
.admin-content h3 { color: var(--ink); }

.stats-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(210px, 1fr)); gap: 16px; margin-bottom: 30px; }
.stat-card, .stat-card[style] { position: relative; overflow: hidden; background: var(--surface-2) !important; color: var(--ink); padding: 22px 22px 20px; border-radius: var(--radius-md); text-align: right; border: 1px solid var(--line); }
.stat-card::before { content: ''; position: absolute; top: 0; bottom: 0; right: 0; width: 5px; background: var(--primary); }
.stat-card:nth-child(4n+2)::before { background: var(--warning); }
.stat-card:nth-child(4n+3)::before { background: var(--success); }
.stat-card:nth-child(4n+4)::before { background: var(--info); }
.stat-card .number { font-size: 2.1rem; font-weight: 800; line-height: 1.3; color: var(--ink); }
.stat-card .label { color: var(--text-muted); font-size: .88rem; font-weight: 500; }

.table-responsive { overflow-x: auto; border: 1px solid var(--line); border-radius: var(--radius-md); background: #fff; }
table { width: 100%; border-collapse: collapse; }
th, td { padding: 13px 16px; text-align: right; border-bottom: 1px solid var(--line); }
th { background: var(--surface-2); font-weight: 700; color: var(--text-muted); white-space: nowrap; font-size: .82rem; }
tbody tr { transition: background .15s; }
tbody tr:hover { background: var(--tint); }
tr:last-child td { border-bottom: 0; }
.badge { display: inline-flex; align-items: center; padding: 4px 12px; border-radius: var(--radius-pill); font-size: .78rem; font-weight: 700; }
.badge-pending { background: #FFF3D6; color: #8A5A00; }
.badge-approved { background: #E3F5EA; color: #176B3B; }
.badge-rejected { background: #FCE7E7; color: #A62B2B; }
.action-btns { display: flex; gap: 8px; flex-wrap: wrap; }
.admin-menu-fab { display: none; }
.admin-sidebar-overlay { display: none; }

/* ==========================================================================
   فوتر
   ========================================================================== */
.main-footer {
    position: relative; margin-top: 56px; padding: 56px 0 0; color: rgba(255, 255, 255, .84);
    border-radius: 44px 44px 0 0;
    background-image: var(--khatam), linear-gradient(180deg, var(--primary-dark), #062A2E);
    background-size: 64px 64px, auto;
}
.footer-grid { display: grid; grid-template-columns: 1.7fr 1fr 1fr; gap: 40px; margin-bottom: 36px; }
.footer-grid:has(.footer-enamad) { grid-template-columns: 1.7fr 1fr 1fr 1fr; }
.footer-brand { display: flex; align-items: center; gap: 12px; margin-bottom: 14px; }
.footer-brand img { width: 46px; height: 46px; border-radius: 14px; }
.footer-title { font-size: 1.3rem; margin: 0; color: #fff; font-weight: 800; }
.footer-about { color: rgba(255, 255, 255, .72); line-height: 2; font-size: .94rem; max-width: 46ch; }
.footer-col h4 { margin-bottom: 14px; color: var(--gold); font-size: .98rem; }
.footer-links, .footer-contact { list-style: none; }
.footer-links a { color: rgba(255, 255, 255, .78); display: block; padding: 6px 0; font-size: .94rem; }
.footer-links a:hover { color: #fff; padding-right: 6px; }
.footer-contact li { display: flex; align-items: center; gap: 10px; padding: 6px 0; font-size: .94rem; }
.footer-contact i { width: 32px; height: 32px; border-radius: 10px; background: rgba(255, 255, 255, .1); display: inline-flex; align-items: center; justify-content: center; color: var(--accent); font-size: .85rem; }
.footer-bottom { border-top: 1px solid rgba(255, 255, 255, .12); padding: 20px 0; text-align: center; font-size: .86rem; color: rgba(255, 255, 255, .6); }
.footer-enamad .enamad-wrap { display: flex; flex-wrap: wrap; gap: 10px; align-items: center; margin-top: 8px; background: #fff; padding: 10px; border-radius: 14px; width: fit-content; }
.footer-enamad .enamad-wrap img, .footer-enamad .enamad-wrap a img { max-height: 80px; width: auto; display: block; }
.enamad-preview img, .enamad-preview a img { max-height: 90px; width: auto; }

.mobile-bottom-nav { display: none; }

/* ==========================================================================
   واکنشگرایی
   ========================================================================== */
@media (max-width: 1100px) {
    .hero-inner { gap: 24px; }
    .footer-grid, .footer-grid:has(.footer-enamad) { grid-template-columns: 1fr 1fr; gap: 30px; }
}

/* ---------- منوی کشویی (تبلت و موبایل) ---------- */
@media (max-width: 992px) {
    :root { --header-h: 64px; }
    .main-header { z-index: 1100; background: #fff; -webkit-backdrop-filter: none; backdrop-filter: none; }
    .main-header.scrolled { background: #fff; }
    .navbar { min-height: var(--header-h); }
    .nav-toggle { display: flex; z-index: 1200; }
    .appbar-actions { display: flex; align-items: center; gap: 8px; margin-right: auto; margin-left: 8px; }

    .nav-menu {
        display: flex !important; flex-direction: column; align-items: stretch; gap: 3px;
        position: fixed; top: 0; right: 0; left: auto; width: min(84vw, 330px); height: 100vh; height: 100dvh;
        padding: calc(78px + var(--safe-top)) 14px calc(24px + var(--safe-bottom)); margin: 0; z-index: 1150;
        background-image: var(--khatam), linear-gradient(180deg, var(--primary-dark), #0A4B51);
        background-size: 64px 64px, auto;
        box-shadow: -14px 0 40px rgba(0, 0, 0, .3); border-radius: 28px 0 0 28px;
        transform: translateX(105%); transition: transform .34s var(--ease);
        overflow-y: auto; -webkit-overflow-scrolling: touch; max-height: none;
    }
    .nav-menu.active { transform: translateX(0); }
    .nav-menu .nav-item { width: 100%; }
    .nav-menu a { width: 100%; padding: 14px 16px; border-radius: 16px; font-size: 1rem; color: rgba(255, 255, 255, .9); }
    .nav-menu a i { color: var(--accent); opacity: 1; width: 22px; text-align: center; }
    .nav-menu a:hover { background: rgba(255, 255, 255, .1); color: #fff; }
    .nav-menu a.active { background: rgba(255, 255, 255, .16); color: #fff; box-shadow: inset -4px 0 0 var(--gold); }
    .nav-menu a.active i { color: var(--gold); }
    .nav-menu .btn-nav { margin: 8px 0 0; justify-content: center; }
    .nav-menu .sub-menu, .nav-menu .mega-panel { position: static; box-shadow: none; background: rgba(255, 255, 255, .08); border: 0; border-radius: 14px; margin: 4px 0 8px; padding: 6px; width: 100%; color: #fff; }
    .nav-menu .sub-menu a { color: rgba(255, 255, 255, .9) !important; }
    .nav-item.has-sub:hover > .sub-menu, .nav-item.has-mega:hover > .mega-panel { display: none; }
    .nav-item.has-sub.open > .sub-menu, .nav-item.has-mega.open > .mega-panel { display: block; }
    .nav-item.has-sub:focus-within > .sub-menu, .nav-item.has-mega:focus-within > .mega-panel { display: none; }
    .nav-item.has-sub.open:focus-within > .sub-menu, .nav-item.has-mega.open:focus-within > .mega-panel { display: block; }

    .profile-panel, .admin-layout, .blog-layout { grid-template-columns: 1fr; }
    .profile-sidebar { position: static; }
    .hero-inner { grid-template-columns: 1fr; }
    .hero-art { position: absolute; top: -16px; left: -30px; width: 230px; opacity: .35; pointer-events: none; align-self: auto; }
    .hero-content { max-width: 100%; }
    .features-grid { grid-template-columns: repeat(2, 1fr); }
    .how-grid { grid-template-columns: repeat(2, 1fr); }
    .how-step:not(:last-child)::after { display: none; }
    .about-box { padding: 36px 30px; }
    .about-box::before, .about-box::after { opacity: .5; left: -90px; }
    .cta-box { padding: 40px 30px; }
    .related-grid { grid-template-columns: 1fr 1fr; }
}

/* ---------- تجربه‌ی اپ موبایل ---------- */
@media (max-width: 768px) {
    html { font-size: 15px; }
    :root { --header-h: 60px; }
    .container { padding: 0 16px; }
    .navbar { min-height: 60px; }
    .logo-img { width: 38px; height: 38px; border-radius: 12px; }
    .logo-text { font-size: 1.08rem; }

    .appbar-btn { position: relative; width: 42px; height: 42px; border-radius: 14px; background: var(--tint); color: var(--primary-dark); display: inline-flex; align-items: center; justify-content: center; font-size: 1.05rem; }
    .appbar-btn .notif-badge { position: absolute; top: -4px; left: -4px; margin: 0; border: 2px solid #fff; }

    .main-content { padding: 16px 0 calc(var(--tabbar-h) + 34px + var(--safe-bottom)); }
    body.is-admin-page .main-content { padding: 14px 0 28px; }

    /* هیرو */
    .hero-pro { margin-top: -16px; padding: 38px 0 0; border-radius: 0 0 32px 32px; }
    .hero-pro h1 { font-size: 1.85rem; }
    .hero-lead { font-size: .98rem; line-height: 1.95; margin-bottom: 22px; }
    .hero-btns { flex-direction: column; align-items: stretch; }
    .hero-btns .btn { width: 100%; }
    .hero-stats { border-radius: 22px 22px 0 0; }
    .hero-stat { padding: 14px 4px; }
    .hero-stat span { font-size: .72rem; }
    .hero { padding: 30px 18px; }
    .hero h1 { font-size: 1.5rem; }

    /* ویژگی‌ها: اسکرول افقی */
    .section-features { padding: 36px 0 10px; }
    .features-grid { display: flex; gap: 12px; overflow-x: auto; scroll-snap-type: x mandatory; margin: 0 -16px; padding: 4px 16px 14px; scrollbar-width: none; -webkit-overflow-scrolling: touch; }
    .features-grid::-webkit-scrollbar { display: none; }
    .feature-card { flex: 0 0 76%; scroll-snap-align: center; padding: 22px 20px; }

    /* مراحل: خط زمانی عمودی */
    .section-how { padding: 36px 0 10px; }
    .how-grid { grid-template-columns: 1fr; gap: 0; }
    .how-step { display: flex; gap: 16px; text-align: right; padding: 0 0 24px; align-items: flex-start; }
    .how-step:not(:last-child)::after { display: block; top: 52px; bottom: 0; right: 25px; left: auto; width: 0; border-top: 0; border-right: 2px dashed var(--accent); }
    .how-num { margin: 0; flex-shrink: 0; width: 50px; height: 50px; }
    .how-step > div, .how-step h3, .how-step p { text-align: right; }
    .how-step h3 { margin-top: 4px; }

    .about-box { padding: 28px 22px; }
    .about-box::before, .about-box::after { display: none; }
    .section-members { padding: 32px 0 18px; }
    .section-title { margin-bottom: 18px; }
    .section-title h2 i { width: 38px; height: 38px; border-radius: 12px; }
    .members-search { max-width: none; margin-bottom: 20px; }

    .profiles-grid { grid-template-columns: 1fr 1fr; gap: 12px; }
    .profile-card { border-radius: 20px; }
    .profile-photo-wrap { aspect-ratio: 3 / 3.6; }
    .profile-overlay { right: 12px; left: 12px; bottom: 10px; }
    .profile-name { font-size: 1rem; }
    .profile-badge-gender { width: 30px; height: 30px; top: 10px; right: 10px; font-size: .8rem; }
    .profile-body { padding: 10px 12px 12px; gap: 6px; }
    .profile-meta { font-size: .7rem; gap: 4px; }
    .profile-meta span { padding: 2px 8px; }
    .profile-card .btn-view { padding: 8px; font-size: .78rem; }

    .section-cta { padding: 18px 0 30px; }
    .cta-box { padding: 30px 22px; }
    .cta-box::before, .cta-box::after { display: none; }
    .cta-box .btn { width: 100%; }

    /* فرم‌ها */
    .form-container { padding: 28px 20px 24px; border-radius: 26px; }
    .form-row { grid-template-columns: 1fr; gap: 0; }
    .form-row[style*="1fr 1fr 1fr"] { grid-template-columns: 1fr 1fr 1fr !important; gap: 8px !important; }
    .form-control { font-size: 16px; } /* جلوگیری از زوم iOS */
    .profile-main, .profile-sidebar { border-radius: 24px; padding: 20px 16px; }
    .profile-panel { gap: 14px; }
    .page-head h1 { font-size: 1.25rem; }
    #replyForm { flex-direction: column; align-items: stretch; }
    #replyForm .btn { width: 100%; }
    .blog-single { padding: 20px 16px; border-radius: 24px; }
    .blog-grid { grid-template-columns: 1fr; }

    /* مودال → Bottom Sheet */
    .modal-overlay { padding: 0; align-items: flex-end; }
    .modal-box { max-width: 100%; width: 100%; max-height: 92vh; max-height: 92dvh; border-radius: 28px 28px 0 0; margin: 0; animation: sheetMobile .42s var(--ease); transition: transform .25s var(--ease); }
    @keyframes sheetMobile { from { transform: translateY(100%); } to { transform: none; } }
    .sheet-handle { display: block; }
    .modal-photo { height: 300px; }
    .modal-gallery { grid-template-columns: repeat(3, 1fr); }
    .modal-body { padding: 22px 18px calc(28px + var(--safe-bottom)); }
    .lightbox-nav { width: 42px; height: 42px; }
    .lightbox-prev { right: 4px; }
    .lightbox-next { left: 4px; }
    .lightbox-img { max-height: 72dvh; }

    /* نوار تب پایین */
    .mobile-bottom-nav {
        display: flex; position: fixed; left: 12px; right: 12px; bottom: calc(10px + var(--safe-bottom)); z-index: 1050;
        height: var(--tabbar-h); padding: 6px; gap: 2px; align-items: stretch;
        background: rgba(255, 255, 255, .92); -webkit-backdrop-filter: saturate(1.8) blur(18px); backdrop-filter: saturate(1.8) blur(18px);
        border: 1px solid rgba(8, 57, 62, .08); border-radius: 28px;
        box-shadow: 0 20px 44px -14px rgba(8, 57, 62, .42), 0 2px 8px rgba(8, 57, 62, .08);
    }
    .mobile-bottom-nav a, .mobile-bottom-nav button {
        flex: 1; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 3px;
        padding: 6px 2px; border: none; background: none; color: var(--text-muted);
        font-size: .66rem; font-weight: 600; font-family: inherit; cursor: pointer; border-radius: 22px;
        transition: background .25s var(--ease), color .25s var(--ease), transform .15s;
    }
    .mobile-bottom-nav a i, .mobile-bottom-nav button i { font-size: 1.2rem; transition: transform .3s var(--ease); }
    .mobile-bottom-nav a:active, .mobile-bottom-nav button:active { transform: scale(.92); }
    .mobile-bottom-nav a.active { background: var(--primary); color: #fff; box-shadow: 0 8px 18px -8px rgba(15, 110, 115, .9); }
    .mobile-bottom-nav a.active i { transform: translateY(-1px) scale(1.08); }

    .flash-container { top: calc(var(--header-h) + 10px); width: calc(100% - 24px); }

    /* فوتر */
    .main-footer { margin-top: 36px; border-radius: 32px 32px 0 0; padding-top: 40px; padding-bottom: calc(var(--tabbar-h) + 28px + var(--safe-bottom)); }
    body.is-admin-page .main-footer { padding-bottom: 20px; }
    .footer-grid, .footer-grid:has(.footer-enamad) { grid-template-columns: 1fr; gap: 24px; }

    /* ادمین موبایل */
    .admin-menu-fab {
        display: flex; position: fixed; bottom: calc(18px + var(--safe-bottom)); left: 16px; z-index: 1300;
        width: 56px; height: 56px; border-radius: 20px; border: none; align-items: center; justify-content: center;
        background: var(--gold); color: var(--on-gold); font-size: 1.3rem; cursor: pointer;
        box-shadow: 0 14px 28px -10px rgba(244, 168, 29, .95);
    }
    .admin-menu-fab:active { transform: scale(.93); }
    .admin-sidebar-overlay { display: none; position: fixed; inset: 0; background: rgba(8, 30, 34, .55); -webkit-backdrop-filter: blur(4px); backdrop-filter: blur(4px); z-index: 1240; }
    .admin-sidebar-overlay.active { display: block; }
    .admin-layout { grid-template-columns: 1fr !important; gap: 0 !important; }
    .admin-sidebar {
        position: fixed !important; top: 0; right: 0; bottom: 0; width: min(86vw, 310px); max-width: 310px; max-height: none;
        z-index: 1250; transform: translateX(105%); transition: transform .34s var(--ease);
        overflow-y: auto; -webkit-overflow-scrolling: touch; border-radius: 28px 0 0 28px; padding: calc(20px + var(--safe-top)) 14px 24px;
    }
    .admin-sidebar.open { transform: translateX(0); }
    .admin-menu a.active::before { right: -14px; }
    .admin-content { width: 100%; max-width: 100%; padding: 18px 14px 80px; border-radius: 24px; }
    .admin-content h1 { font-size: 1.25rem; margin-bottom: 16px; }
    .admin-content h1 > i { width: 40px; height: 40px; }
    .admin-content table, .table-responsive { display: block; width: 100%; overflow-x: auto; -webkit-overflow-scrolling: touch; font-size: .85rem; }
    .admin-content .form-row { grid-template-columns: 1fr !important; }
    .admin-content .btn { min-height: 42px; }
    .admin-content > div > div[style*="grid-template-columns:200px"] { grid-template-columns: 1fr !important; }
    .stats-grid { grid-template-columns: 1fr 1fr; gap: 10px; }
    .stat-card { padding: 16px 16px 14px; }
    .stat-card .number { font-size: 1.6rem; }

    /* اسلایدر */
    .pn-slider { height: 280px !important; border-radius: 22px !important; }
    .pn-slide-content h2 { font-size: 1.3rem; }
    .pn-slider-nav { width: 36px; height: 36px; }
    .pn-g1 .pn-gal-grid, .pn-g12 .pn-gal-grid { grid-template-columns: 1fr 1fr !important; }
    .pn-g3 .pn-gal-grid { columns: 2; }
    .pn-g17 .pn-gal-grid { grid-template-columns: repeat(3, 1fr); }
    .pn-g5 .pn-gal-item { max-width: 160px; margin: 0 auto; }
}

@media (max-width: 480px) {
    .pn-slider { height: 240px !important; }
    .pn-g1 .pn-gal-grid { grid-template-columns: 1fr !important; }
    .stats-grid { grid-template-columns: 1fr 1fr; }
    .pagination a, .pagination span { min-width: 40px; height: 40px; padding: 0 10px; }
    .mobile-bottom-nav a span, .mobile-bottom-nav button span { font-size: .62rem; }
    .related-grid { grid-template-columns: 1fr; }
}

@media (min-width: 769px) {
    .mobile-bottom-nav { display: none !important; }
    .admin-menu-fab, .admin-sidebar-overlay { display: none !important; }
    .appbar-btn { display: none; }
}
@media (min-width: 993px) {
    .nav-overlay { display: none !important; }
}
@media (max-width: 1200px) {
    .pb-wrap { grid-template-columns: 1fr !important; }
}

/* ---------- دستگاه‌های لمسی و حرکت کاهش‌یافته ---------- */
@media (hover: none) {
    .profile-card:hover, .feature-card:hover, .blog-card:hover { transform: none; box-shadow: var(--shadow-xs); }
    .profile-card:hover .profile-photo { transform: none; }
}
@media (prefers-reduced-motion: reduce) {
    *, *::before, *::after { animation-duration: .01ms !important; animation-iteration-count: 1 !important; transition-duration: .01ms !important; scroll-behavior: auto !important; }
}

/* ---------- جزئیات تکمیلی ---------- */
input[type="search"] { -webkit-appearance: none; appearance: none; }
input[type="search"]::-webkit-search-cancel-button { -webkit-appearance: none; display: none; }

/* گفتگوی تیکت در پنل مدیریت: کارت ساده (دکمه‌ی حذف داخل پیام است) */
.admin-content #ticketMessages { display: block; max-height: none; background: transparent; border: 0; padding: 0; }
.admin-content .ticket-msg { max-width: 100%; color: var(--text); border-radius: 16px !important; border: 1px solid var(--line) !important; box-shadow: none; margin-bottom: 10px; animation: none; }
.admin-content .ticket-msg strong { opacity: 1; font-size: inherit; color: var(--ink); }
.admin-content .ticket-msg small { color: var(--text-muted) !important; opacity: 1; }
.admin-content .ticket-msg p { margin: 8px 0 0 !important; }
