/*
 * ایران‌فونت — طرح «فیروزه و انار» (چت ۲۲)، رنگی و پرجان با زعفران (چت ۲۹: بخش ۱۳ آخر فایل). بدون Node/Vite: CSS ساده.
 * جهت: فقط ویژگی‌های منطقی (margin-inline، inset-inline…) تا همین فایل برای fa (rtl) و en (ltr) کار کند.
 * فونت رابط: «FB UI» = وزیرمتن از فایل‌های خود بانک (@font-face در layout، Support/UiFonts)، بعد Tahoma.
 *
 * بخش‌ها: ۱ توکن‌ها · ۲ پایه · ۳ دکمه و فرم · ۴ سربرگ · ۵ پانویس · ۶ چیپ، نشان، کارت فونت · ۷ صفحه اصلی
 *          ۸ کاتالوگ و صفحه‌های فرود · ۹ صفحه فونت · ۱۰ بلاگ و صفحه‌ها · ۱۱ حساب، طراح، فروش · ۱۲ موبایل
 *          ۱۳ طرح رنگی (چت ۲۹): سربرگ و هیروی فیروزه تیره، نوار سه‌رنگ، رنگ‌های ملایم کارت‌ها؛ روی قاعده‌های بالا می‌نشیند
 */

/* ۱ توکن‌ها */
:root {
  --bg: #F4F8F7; --surface: #FFFFFF; --ink: #0B2E33; --muted: #4E6468;
  --line: #D9E5E3; --line-2: #C9D8D5; --divider: #E6EFED; --sample-bg: #F7FAF9; --field: #E8F0EE;
  --brand: #D7263D; --brand-dark: #A61B2E; --brand-soft: #FFE3E6;
  --gold: #F6C445; --mint: #DDF3F0; --mint-ink: #0F6B63; --rose: #FDE4E7; --cream: #FFF1D6; --cream-ink: #8A5300;
  --on-ink: #B9D3D0; --on-ink-line: #1C4A50; --aqua: #5ED1C5;
  /* چت ۲۹ */
  --deep: #0B3B40; --saffron: var(--gold); --teal: #1FA79A; --on-deep-nav: #CFE3E0; --veil: rgba(255, 255, 255, .10);
  --rose-ink: #9E1B2E; --cream-ink-2: #7A4A00; --mint-ink-2: #0F5F58; --lilac: #E9E4FB; --lilac-ink: #4B3A9A; --sky: #E2EEF8; --sky-ink: #1F4F7A;
  --card-shadow: 0 1px 2px rgba(11, 46, 51, .06), 0 8px 24px rgba(11, 46, 51, .06);
  --stripe: linear-gradient(90deg, var(--brand) 0 33.34%, var(--saffron) 33.34% 66.67%, var(--teal) 66.67%);
  --text: var(--ink);
  --radius: 16px; --radius-lg: 24px; --radius-sm: 12px;
  --shadow: 0 20px 50px rgba(11, 46, 51, .10);
  --font: "FB UI", Vazirmatn, Tahoma, sans-serif;
  --gap: 18px;
}

/* ۲ پایه */
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; background: var(--bg); color: var(--ink); font-family: var(--font); font-size: 15px; line-height: 1.7; }
a { color: var(--brand); text-decoration: none; }
a:hover { color: var(--brand-dark); }
img { max-width: 100%; }
h1, h2, h3 { line-height: 1.45; }
:focus-visible { outline: 3px solid rgba(215, 38, 61, .45); outline-offset: 2px; }
.container { max-width: 1240px; margin: 0 auto; padding-inline: 32px; }
.site-main { padding-top: 28px; padding-bottom: 64px; }
.page-title { margin: 0 0 16px; font-size: 32px; font-weight: 900; }
h2 { font-size: 20px; font-weight: 800; margin: 0 0 12px; }
.muted { color: var(--muted); }
.skip-link { position: absolute; inset-inline-start: 8px; top: -60px; z-index: 50; background: var(--ink); color: #fff; padding: 8px 14px; border-radius: 10px; }
.skip-link:focus { top: 8px; color: #fff; }
[hidden] { display: none !important; }
.only-mobile { display: none; }
.pre-line { white-space: pre-line; }

/* ۳ دکمه و فرم */
button, .button {
  font: inherit; font-weight: 700; cursor: pointer; border: 1px solid transparent; border-radius: var(--radius-sm);
  min-height: 44px; padding: 0 20px; background: var(--brand); color: #fff;
  display: inline-flex; align-items: center; justify-content: center; gap: 8px; text-decoration: none; line-height: 1.3;
}
button:hover, .button:hover { background: var(--brand-dark); color: #fff; }
.button-brand { background: var(--brand); color: #fff; }
.button-ink { background: var(--ink); color: #fff; }
.button-ink:hover { background: #164249; color: #fff; }
.button-light { background: #fff; color: var(--ink); }
.button-light:hover { background: var(--mint); color: var(--ink); }
.button-outline { background: transparent; color: var(--ink); border-color: var(--line-2); font-weight: 600; }
.button-outline:hover { background: #fff; color: var(--ink); border-color: var(--ink); }
.button-ghost { background: transparent; color: #fff; border-color: rgba(255, 255, 255, .5); font-weight: 600; }
.button-ghost:hover { background: rgba(255, 255, 255, .12); color: #fff; }
.button-small { min-height: 36px; padding: 0 14px; font-size: 14px; }
.button-secondary { background: #fff; color: #b42318; border-color: #f1c0bb; }
.button-secondary:hover { background: #fff3f2; color: #b42318; }
.button-row { display: flex; flex-wrap: wrap; gap: 10px; }
.link-button { background: none; border: 0; color: var(--brand); padding: 0; min-height: 0; border-radius: 0; font-weight: 500; }
.link-button:hover { background: none; color: var(--brand-dark); text-decoration: underline; }
.icon-button {
  width: 44px; height: 44px; flex: none; border-radius: 10px; border: 1px solid var(--line); background: #fff; color: var(--ink);
  display: inline-flex; align-items: center; justify-content: center; padding: 0; position: relative;
}
.icon-button:hover { background: var(--bg); color: var(--ink); }
.more-link { font-size: 14px; font-weight: 600; white-space: nowrap; }
.more-link::after { content: " ←"; }
[dir="ltr"] .more-link::after { content: " →"; }

input[type="search"], input[type="text"], input[type="email"], input[type="tel"], input[type="password"], input[type="url"], input[type="number"], select, textarea {
  font: inherit; font-size: 15px; min-height: 44px; padding: 8px 14px; border: 1px solid var(--line-2); border-radius: 10px;
  background: #fff; color: var(--ink);
}
textarea { min-height: 96px; line-height: 1.8; }
input:focus, select:focus, textarea:focus { outline: none; border-color: var(--ink); box-shadow: 0 0 0 3px rgba(11, 46, 51, .12); }
input::placeholder, textarea::placeholder { color: #6B7F82; }
input[type="email"], input[type="tel"], input[type="password"] { direction: ltr; text-align: start; }
input[type="checkbox"], input[type="radio"] { accent-color: var(--brand); width: 18px; height: 18px; }
input[type="range"] { accent-color: var(--brand); }
.input-icon { display: flex; align-items: center; gap: 10px; background: #fff; border: 1px solid var(--line-2); border-radius: var(--radius-sm); padding-inline: 16px; color: var(--muted); }
.input-icon:focus-within { border-color: var(--ink); box-shadow: 0 0 0 3px rgba(11, 46, 51, .12); }
.input-icon input { border: 0; background: transparent; padding: 0; flex: 1; min-width: 0; box-shadow: none; }
.input-icon input:focus { box-shadow: none; }
.form-row { display: flex; flex-direction: column; gap: 6px; margin-bottom: 16px; }
.form-row label { font-size: 14px; font-weight: 600; }
.form-row .check { flex-direction: row; align-items: center; gap: 8px; display: inline-flex; color: var(--muted); font-weight: 400; }
.form-row input[type="text"], .form-row input[type="email"], .form-row input[type="tel"], .form-row input[type="password"], .form-row input[type="url"], .form-row select, .form-row textarea { width: 100%; }
.field-error { color: #b42318; font-size: 13px; }
.form-links { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 8px; font-size: 14px; margin-top: 14px; }
.flash { background: var(--mint); border: 1px solid #b3e3dc; color: var(--mint-ink); border-radius: var(--radius-sm); padding: 12px 16px; margin-bottom: 18px; }
.flash-error { background: #fef2f2; border-color: #fecaca; color: #991b1b; }

/* ۴ سربرگ */
.site-header { background: var(--surface); border-bottom: 1px solid var(--line); position: sticky; top: 0; z-index: 20; }
.header-inner { min-height: 72px; display: flex; align-items: center; gap: 28px; }
.brand { display: inline-flex; align-items: center; gap: 10px; color: var(--ink); flex: none; }
.brand:hover { color: var(--ink); }
.brand-mark {
  width: 40px; height: 40px; border-radius: 10px; background: var(--ink); color: #fff; display: inline-flex; align-items: center; justify-content: center;
  font-family: "FB Logo", var(--font); font-size: 26px; font-weight: 900; line-height: 1;
}
.brand-name { font-weight: 800; font-size: 21px; }
.brand-light { color: #fff; }
.brand-light:hover { color: #fff; }
.brand-light .brand-mark { background: #fff; color: var(--ink); }
.menu-toggle { display: none; border: 0; }
.site-menu { display: flex; align-items: center; gap: 24px; flex: 1; min-width: 0; }
.header-nav { display: flex; gap: 22px; font-size: 15px; font-weight: 500; white-space: nowrap; }
.header-nav a { color: var(--muted); padding: 6px 0; border-bottom: 2px solid transparent; }
.header-nav a:hover { color: var(--ink); }
.header-nav a.is-active { color: var(--ink); border-bottom-color: var(--brand); }
.header-search {
  margin-inline-start: auto; display: flex; align-items: center; gap: 8px; background: var(--field); border-radius: 10px;
  padding-inline: 14px; height: 44px; width: 260px; color: var(--muted);
}
.header-search input { border: 0; background: transparent; min-height: 0; padding: 0; flex: 1; min-width: 0; font-size: 14px; }
.header-search input:focus { box-shadow: none; }
.header-search:focus-within { box-shadow: 0 0 0 2px var(--ink); }
.header-account { display: flex; align-items: center; gap: 10px; white-space: nowrap; flex: none; }
.header-account form { margin: 0; }
.account-link { min-height: 44px; font-size: 14px; font-weight: 600; padding: 0 16px; }
.account-link svg { display: none; }
.logout-form .link-button { color: var(--muted); font-size: 13px; }
.cart-count {
  position: absolute; top: -6px; inset-inline-end: -6px; min-width: 20px; height: 20px; padding: 0 5px; border-radius: 999px;
  background: var(--brand); color: #fff; font-size: 11px; font-weight: 700; display: inline-flex; align-items: center; justify-content: center;
}

/* ۵ پانویس */
.site-footer { background: var(--ink); color: var(--on-ink); font-size: 14px; }
.footer-grid { display: grid; grid-template-columns: 2fr repeat(3, minmax(0, 1fr)); gap: 32px; padding-top: 48px; padding-bottom: 28px; }
.footer-about p { margin: 12px 0 0; line-height: 2; max-width: 36ch; }
.footer-nav { display: flex; flex-direction: column; gap: 8px; }
.footer-nav h2 { color: #fff; font-size: 15px; font-weight: 700; margin: 0 0 4px; }
.footer-nav a { color: var(--on-ink); }
.footer-nav a:hover { color: #fff; }
.footer-nav p { margin: 0; line-height: 1.9; font-size: 13px; }
.footer-bottom { border-top: 1px solid var(--on-ink-line); padding-top: 18px; padding-bottom: 28px; font-size: 13px; }

/* ۶ چیپ، نشان، کارت فونت */
.chip {
  display: inline-flex; align-items: center; gap: 6px; min-height: 36px; padding: 0 14px; border-radius: 999px;
  background: #fff; border: 1px solid var(--line); color: var(--ink); font-size: 14px; font-weight: 500; text-decoration: none; cursor: pointer;
}
button.chip { font-weight: 500; }
.chip:hover { border-color: var(--ink); background: #fff; color: var(--ink); }
.chip small { color: var(--muted); font-size: 12px; }
.chip.is-active, .chip[aria-pressed="true"] { background: var(--ink); border-color: var(--ink); color: #fff; font-weight: 700; }
.chip.is-active small, .chip[aria-pressed="true"] small { color: var(--on-ink); }
.chip-row, .tag-links, .hero-links { display: flex; flex-wrap: wrap; gap: 8px; }
.chip-link small { color: var(--muted); font-size: 12px; }
.pill { display: inline-flex; align-items: center; font-size: 11px; font-weight: 700; padding: 2px 10px; border-radius: 999px; white-space: nowrap; line-height: 1.7; }
.pill-free { background: var(--mint); color: var(--mint-ink); }
.pill-sale { background: var(--gold); color: var(--ink); }
.badges { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 10px; }
.badge { display: inline-flex; align-items: center; background: var(--mint); color: var(--mint-ink); border-radius: 999px; padding: 1px 12px; font-size: 13px; font-weight: 600; }
a.badge:hover { background: #c8ebe6; color: var(--mint-ink); }
.badge-muted { background: var(--field); color: var(--muted); font-weight: 500; }

.grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: var(--gap); margin-bottom: 28px; }
.grid-4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.card {
  background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); color: var(--ink);
  display: flex; flex-direction: column; overflow: hidden; transition: box-shadow .15s, transform .15s, border-color .15s;
}
.card:hover { color: var(--ink); border-color: var(--line-2); box-shadow: 0 10px 30px rgba(11, 46, 51, .10); transform: translateY(-2px); }
.card-sample {
  height: max(150px, calc(var(--sample-size, 30px) * 3)); padding: 16px 18px; display: flex; align-items: center; justify-content: center; text-align: center;
  font-size: var(--sample-size, 30px); line-height: 1.5; background: var(--sample-bg); border-bottom: 1px solid var(--divider); color: var(--ink);
  overflow: hidden; overflow-wrap: anywhere; opacity: .45; transition: opacity .25s;
}
.card-sample.is-ready { opacity: 1; }
.card-image { padding: 0; opacity: 1; display: block; }
.card-image img { display: block; width: 100%; height: 100%; object-fit: cover; }
.card-body { padding: 14px 16px 16px; display: flex; flex-direction: column; gap: 2px; }
.card-head { display: flex; align-items: center; justify-content: space-between; gap: 8px; }
.card-title { font-size: 16px; font-weight: 700; margin: 0; line-height: 1.6; }
.card-meta { color: var(--muted); font-size: 13px; }
.card-meta-small { font-size: 12px; }
.empty { background: var(--surface); border: 1px dashed var(--line-2); border-radius: var(--radius); padding: 40px; text-align: center; color: var(--muted); }

/* ۷ صفحه اصلی */
.kicker { margin: 0 0 12px; font-size: 14px; font-weight: 600; color: var(--brand); }
.hero { display: flex; flex-wrap: wrap; gap: 48px; align-items: center; padding: 36px 0 40px; }
.hero-text { flex: 1 1 420px; min-width: 0; }
.hero-title { margin: 0 0 18px; font-size: 54px; font-weight: 900; line-height: 1.35; letter-spacing: -.5px; }
.hero-lead { margin: 0 0 28px; font-size: 18px; color: var(--muted); max-width: 46ch; }
.hero-search { display: flex; gap: 10px; max-width: 520px; margin: 0 0 20px; }
.hero-search .input-icon { flex: 1; height: 54px; }
.hero-search input { font-size: 16px; }
.hero-search .button { height: 54px; padding: 0 26px; font-size: 16px; }

.tester-card { flex: 1 1 520px; min-width: 0; background: #fff; border: 1px solid var(--line); border-radius: 20px; box-shadow: var(--shadow); overflow: hidden; }
.tester-card-input { padding: 18px 22px; border-bottom: 1px solid var(--divider); display: flex; align-items: center; gap: 12px; }
.tester-card-input label { font-size: 13px; color: var(--muted); white-space: nowrap; }
.tester-card-input input { flex: 1; min-width: 0; background: var(--sample-bg); }
.tester-card-preview { padding: 30px 28px; min-height: 230px; display: flex; align-items: center; }
.tester-card-preview p { margin: 0; width: 100%; font-size: clamp(34px, 4.4vw, 58px); line-height: 1.6; overflow-wrap: anywhere; }
.tester-card-fonts { padding: 14px 22px 20px; border-top: 1px solid var(--divider); display: flex; flex-wrap: wrap; gap: 8px; align-items: center; }
.tester-card-fonts .chip { border-color: var(--line-2); font-size: 13px; }
.tester-card-fonts .more-link { margin-inline-start: auto; font-size: 13px; }

.home-section { margin-bottom: 56px; }
.home-section:last-child { margin-bottom: 8px; }
.section-head { display: flex; align-items: baseline; justify-content: space-between; gap: 16px; margin-bottom: 18px; flex-wrap: wrap; }
.section-head h2 { margin: 0; font-size: 26px; font-weight: 800; }
.section-tabs { display: flex; flex-wrap: wrap; gap: 6px; align-items: center; }
.section-tabs .chip { min-height: 32px; font-size: 13px; }
.section-tabs .more-link { margin-inline-start: 10px; }

.style-grid { display: grid; grid-template-columns: repeat(6, minmax(0, 1fr)); gap: 14px; }
.style-tile { background: #fff; border: 1px solid var(--line); border-radius: var(--radius); padding: 18px 16px 16px; color: var(--ink); display: flex; flex-direction: column; gap: 4px; }
.style-tile:hover { color: var(--ink); border-color: var(--ink); }
.style-sample { height: 92px; display: flex; align-items: center; justify-content: center; font-size: 46px; line-height: 1.2; opacity: .45; transition: opacity .25s; overflow: hidden; }
.style-sample.is-ready { opacity: 1; }
.style-name { font-weight: 700; font-size: 16px; }
.style-count { font-size: 12px; color: var(--muted); }

.feature-banner { background: var(--ink); border-radius: var(--radius-lg); padding: 48px 52px; display: flex; flex-wrap: wrap; gap: 32px; align-items: center; color: #fff; overflow: hidden; }
.feature-text { flex: 1 1 340px; min-width: 0; }
.feature-text .pill { font-size: 13px; padding: 3px 12px; }
.feature-text h2 { margin: 12px 0; font-size: 38px; font-weight: 900; line-height: 1.4; color: #fff; }
.feature-text p { margin: 0 0 24px; font-size: 16px; color: var(--on-ink); max-width: 42ch; }
.feature-words { flex: 1 1 480px; min-width: 0; display: flex; flex-direction: column; align-items: flex-start; gap: 4px; }
.feature-word { line-height: 1.25; white-space: nowrap; max-width: 100%; overflow: hidden; text-overflow: clip; opacity: .5; transition: opacity .25s; }
.feature-word.is-ready { opacity: 1; }
.feature-word-1 { font-size: 84px; color: #fff; }
.feature-word-2 { font-size: 62px; color: var(--gold); margin-inline-start: 120px; }
.feature-word-3 { font-size: 76px; color: var(--aqua); margin-inline-start: 30px; }

.week-card { background: #fff; border: 1px solid var(--line); border-radius: var(--radius-lg); padding: 40px 44px; display: flex; flex-wrap: wrap; gap: 40px; }
.week-text { flex: 1 1 300px; min-width: 0; display: flex; flex-direction: column; gap: 8px; }
.week-text .kicker { margin: 0; font-size: 13px; font-weight: 700; }
.week-text h2 { margin: 0; font-size: 44px; font-weight: 800; line-height: 1.35; }
.week-text .muted { margin: 0; }
.week-desc { margin: 6px 0 12px; font-size: 16px; line-height: 2; max-width: 40ch; }
.week-text .button-row { margin-top: 10px; }
.week-ladder { flex: 2 1 560px; min-width: 0; display: flex; flex-direction: column; }
.ladder-row { display: flex; align-items: baseline; gap: 18px; padding: 6px 0; border-bottom: 1px solid var(--divider); }
.ladder-row:last-child { border-bottom: 0; }
.ladder-label { width: 48px; flex: none; font-size: 12px; color: var(--muted); font-family: var(--font); }
.ladder-sample { font-size: 30px; line-height: 1.5; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; opacity: .5; transition: opacity .25s; }
.ladder-sample.is-ready { opacity: 1; }

.collection-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: var(--gap); }
.collection-card { border-radius: 20px; padding: 26px; color: var(--ink); display: flex; flex-direction: column; gap: 10px; transition: transform .15s; }
.collection-card:hover { color: var(--ink); transform: translateY(-2px); }
.collection-samples { display: flex; flex-direction: column; min-height: 150px; justify-content: center; }
.collection-sample { font-size: 38px; line-height: 1.5; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; opacity: .5; transition: opacity .25s; }
.collection-sample.is-ready { opacity: 1; }
.collection-sample + .collection-sample { font-size: 30px; }
.collection-name { font-weight: 800; font-size: 19px; }
.collection-count { font-size: 13px; color: #35514F; }
.tone-rose { background: var(--rose); }
.tone-cream { background: var(--cream); }
.tone-mint { background: var(--mint); }
.tone-sand { background: var(--field); }
.tone-ink { background: var(--ink); color: var(--gold); }
.tone-rose .collection-sample + .collection-sample { color: var(--brand); }
.tone-cream .collection-sample + .collection-sample { color: var(--cream-ink); }
.tone-mint .collection-sample + .collection-sample { color: var(--mint-ink); }

.designer-card { background: #fff; border: 1px solid var(--line); border-radius: var(--radius); padding: 20px; color: var(--ink); display: flex; align-items: center; gap: 14px; }
.designer-card:hover { color: var(--ink); border-color: var(--ink); }
.designer-initial { width: 56px; height: 56px; flex: none; border-radius: 50%; display: flex; align-items: center; justify-content: center; font-family: "FB Logo", var(--font); font-size: 26px; font-weight: 800; color: var(--ink); }
.designer-info { display: flex; flex-direction: column; min-width: 0; }
.designer-name { font-weight: 700; font-size: 16px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.designer-info .muted { font-size: 13px; }
.designer-grid { margin-bottom: 0; }

.cta-band { background: var(--brand); border-radius: var(--radius-lg); padding: 44px 52px; display: flex; flex-wrap: wrap; gap: 28px; align-items: center; justify-content: space-between; color: #fff; }
.cta-band > div:first-child { flex: 1 1 420px; min-width: 0; }
.cta-band h2 { margin: 0 0 8px; font-size: 32px; font-weight: 900; color: #fff; }
.cta-band p { margin: 0; font-size: 17px; color: var(--brand-soft); max-width: 52ch; }
.cta-band .button { min-height: 50px; padding: 0 24px; }

/* ۸ کاتالوگ و صفحه‌های فرود */
.filters { display: flex; flex-wrap: wrap; gap: 10px; align-items: center; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 16px; margin-bottom: 16px; }
.filters input[type="search"] { flex: 1 1 220px; }
.filters .check { display: inline-flex; align-items: center; gap: 6px; color: var(--muted); }
.filters .reset { color: var(--muted); font-size: 14px; }
.filters-compact { padding: 12px 16px; }
.sample-bar { display: flex; flex-wrap: wrap; align-items: center; gap: 12px; margin: 0 0 16px; }
.sample-bar label { font-size: 13px; color: var(--muted); white-space: nowrap; }
.sample-bar input { flex: 1; min-width: 0; background: #fff; }
.tag-filters { flex: 1 1 100%; border-top: 1px solid var(--divider); padding-top: 12px; }
.tag-filters summary { cursor: pointer; font-weight: 700; }
.tag-filters .tag-count { background: var(--brand); color: #fff; border-radius: 999px; padding: 0 8px; font-size: 12px; margin-inline-start: 6px; }
.tag-hint { color: var(--muted); font-size: 13px; margin: 6px 0 4px; }
.tag-group { border: 0; padding: 0; margin: 10px 0 0; display: flex; flex-wrap: wrap; gap: 6px 8px; align-items: center; }
.tag-group legend { font-size: 13px; color: var(--muted); padding: 0; margin-bottom: 4px; float: inline-start; width: 100%; }
.tag-option { display: inline-flex; align-items: center; gap: 6px; border: 1px solid var(--line); border-radius: 999px; padding: 4px 12px; font-size: 14px; cursor: pointer; background: #fff; }
.tag-option:has(input:checked) { border-color: var(--ink); background: var(--ink); color: #fff; }
.tag-option:has(input:checked) small { color: var(--on-ink); }
.tag-option input { margin: 0; width: 15px; height: 15px; }
.tag-option small { color: var(--muted); font-size: 12px; }
.active-filters { display: flex; flex-wrap: wrap; gap: 6px; align-items: center; margin: -4px 0 14px; font-size: 14px; color: var(--muted); }
.active-filters .chip, .chip-remove { background: var(--ink); border-color: var(--ink); color: #fff; min-height: 30px; font-size: 13px; }
.result-count { color: var(--muted); margin: 0 0 14px; }

.pagination { display: flex; flex-wrap: wrap; gap: 6px; justify-content: center; margin: 8px 0 28px; }
.pagination a, .pagination span { min-width: 44px; min-height: 44px; display: inline-flex; align-items: center; justify-content: center; padding: 0 12px; border: 1px solid var(--line); border-radius: 10px; background: var(--surface); color: var(--ink); }
.pagination .current { background: var(--ink); border-color: var(--ink); color: #fff; font-weight: 700; }
.pagination .disabled, .pagination .gap { color: var(--muted); background: transparent; }
.pagination a:hover { border-color: var(--ink); }

.breadcrumb { color: var(--muted); font-size: 14px; margin-bottom: 14px; }
.breadcrumb a { color: var(--muted); }
.breadcrumb a:hover { color: var(--brand); }
.landing-head { margin-bottom: 18px; }
.landing-head .result-count { margin: -8px 0 8px; }
.landing-intro { max-width: 75ch; color: var(--ink); }
.landing-lead { margin: -6px 0 18px; }
.hub-list { list-style: none; margin: 0 0 28px; padding: 0; display: grid; grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); gap: 10px 16px; }
.hub-list li { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius-sm); padding: 12px 16px; display: flex; justify-content: space-between; gap: 8px; align-items: baseline; }
.hub-list li:hover { border-color: var(--ink); }
.hub-list a { color: var(--ink); font-weight: 600; }
.hub-list small { color: var(--muted); white-space: nowrap; }

/* ۹ صفحه فونت */
.panel { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 22px 24px; margin-bottom: 20px; }
.panel > h2:first-child { margin-top: 0; }
.font-head { display: flex; flex-wrap: wrap; gap: 20px; justify-content: space-between; align-items: flex-start; margin-bottom: 20px; }
.font-head .page-title { font-size: 34px; }
.download-box { text-align: center; background: #fff; border: 1px solid var(--line); border-radius: var(--radius); padding: 18px 20px; min-width: 220px; }
.download-box .button { width: 100%; min-height: 50px; }
.download-box small { display: block; color: var(--muted); margin-top: 8px; }
.tester { box-shadow: var(--shadow); border-radius: 20px; }
.tester-controls { display: flex; flex-wrap: wrap; gap: 12px; align-items: center; margin-bottom: 12px; padding-bottom: 14px; border-bottom: 1px solid var(--divider); }
.tester-controls input[type="text"] { flex: 1 1 260px; background: var(--sample-bg); }
.tester-controls label { display: inline-flex; align-items: center; gap: 8px; color: var(--muted); font-size: 14px; }
.tester-preview { min-height: 160px; font-size: 56px; line-height: 1.5; overflow-wrap: anywhere; padding: 16px 4px; }
.weight-row { padding: 8px 0; border-bottom: 1px solid var(--divider); }
.weight-row:last-child { border-bottom: 0; }
.weight-row small { color: var(--muted); }
.weight-sample { font-size: 30px; line-height: 1.5; opacity: .5; transition: opacity .25s; overflow-wrap: anywhere; }
.weight-sample.is-ready { opacity: 1; }
.glyph-label { font-size: 15px; color: var(--muted); margin: 16px 0 8px; font-weight: 500; }
.glyphs { display: flex; flex-wrap: wrap; gap: 6px; font-size: 32px; line-height: 1.3; }
.glyphs span { width: 56px; height: 56px; display: inline-flex; align-items: center; justify-content: center; border: 1px solid var(--divider); border-radius: 10px; background: var(--sample-bg); }
.details dl { display: grid; grid-template-columns: 170px 1fr; gap: 8px 16px; margin: 0; }
.details dt { color: var(--muted); }
.details dd { margin: 0; }
.source-desc { margin-top: 14px; color: var(--muted); }
.gallery { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 12px; }
.gallery img { display: block; width: 100%; height: auto; border-radius: 10px; border: 1px solid var(--line); }
.lead { margin: 8px 0 0; color: var(--muted); max-width: 70ch; line-height: 1.9; font-size: 16px; }
.prose { line-height: 2; }
.prose h2, .prose h3 { margin: 1.2em 0 .5em; }
.prose p, .prose ul, .prose ol { margin: 0 0 1em; }
.prose ul, .prose ol { padding-inline-start: 1.4em; }
.prose img { max-width: 100%; height: auto; border-radius: 10px; }
.prose blockquote { margin: 0 0 1em; padding: 4px 16px; border-inline-start: 3px solid var(--brand); color: var(--muted); }
.prose pre, .prose code { direction: ltr; text-align: left; }
.prose a { text-decoration: underline; text-underline-offset: 3px; }
.faq details { border-top: 1px solid var(--divider); padding: 12px 0; }
.faq details:first-of-type { border-top: 0; }
.faq summary { cursor: pointer; font-weight: 700; }
.faq p { margin: 8px 0 0; line-height: 1.9; color: var(--muted); }
.release-list { list-style: none; margin: 0; padding: 0; }
.release-list > li { border-top: 1px solid var(--divider); padding: 12px 0; }
.release-list > li:first-child { border-top: 0; padding-top: 0; }
.release-list h3 { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; margin: 0 0 4px; font-size: 16px; }
.release-list time { color: var(--muted); font-size: 14px; }
.release-list ul, .release-list .prose { margin: 6px 0 0; line-height: 1.9; }
.release-list .prose > :first-child { margin-top: 0; }

/* خرید فونت فروشی (چت ۱۷–۱۸) */
.buy .muted, .buy-type .muted { color: var(--muted); }
.buy-packages { display: flex; flex-wrap: wrap; gap: 10px; margin: 12px 0; }
.buy-package { border: 1px solid var(--line); border-radius: var(--radius-sm); padding: 12px 16px; min-width: 150px; background: var(--sample-bg); }
.buy-package small { display: block; color: var(--muted); }
.buy-type { border-top: 1px solid var(--divider); padding: 12px 0; }
.buy-type summary { cursor: pointer; font-weight: 600; }
.buy-table .price { font-weight: 700; white-space: nowrap; }
.buy-table del { display: block; font-size: .85em; color: var(--muted); }
.buy-actions { margin-top: 12px; display: flex; gap: 12px; align-items: center; flex-wrap: wrap; }
.buy-actions .button[disabled] { opacity: .55; cursor: not-allowed; }
.buy-add { margin-top: 4px; }
.buy-add .button, .buy-add button { min-height: 36px; font-size: 13px; padding: 0 12px; }
.license-body { white-space: pre-line; line-height: 2; }
.price-form .price-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(180px, 1fr)); gap: 10px; }

/* ۱۰ بلاگ و صفحه‌های ثابت */
.post-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: var(--gap); margin-bottom: 28px; }
.post-card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; display: flex; flex-direction: column; }
.post-cover { display: block; }
.post-cover img { display: block; width: 100%; aspect-ratio: 16 / 9; object-fit: cover; }
.post-cover-type { aspect-ratio: 16 / 9; display: flex; align-items: center; justify-content: center; padding: 16px; text-align: center; font-size: clamp(32px, 4vw, 52px); font-weight: 900; line-height: 1.3; overflow: hidden; white-space: nowrap; }
.post-cover-type.tone-rose { color: var(--brand); }
.post-cover-type.tone-cream { color: var(--cream-ink); }
.post-card-body { padding: 16px 18px 20px; display: flex; flex-direction: column; gap: 4px; }
.post-card-body time { font-size: 12px; }
.post-card-body p { margin: 4px 0 0; color: var(--muted); line-height: 1.9; font-size: 14px; }
.post-card-title { font-size: 17px; font-weight: 700; line-height: 1.7; margin: 0; }
.post-card-title a { color: var(--ink); }
.post-card-title a:hover { color: var(--brand); }
.article { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius-lg); padding: 32px clamp(18px, 4vw, 48px); margin-bottom: 28px; }
/* ستون متن در وسط کادر؛ بدون margin-inline متن به راست می‌چسبید و سمت چپ خالی می‌ماند */
.article-head, .article-cover, .article .prose { max-width: 720px; margin-inline: auto; }
.article .prose { font-size: 16px; }
.article-head .muted { margin: -8px 0 16px; }
.article-cover { display: block; width: 100%; height: auto; border-radius: var(--radius); margin-bottom: 20px; }

/* ۱۱ حساب کاربری، پنل طراح، فروش */
.auth-box { max-width: 440px; margin: 16px auto 32px; }
.account-grid { display: grid; grid-template-columns: 2fr 1fr; gap: 20px; align-items: start; }
.download-list { list-style: none; margin: 0; padding: 0; }
.download-list li { display: flex; align-items: center; gap: 14px; padding: 12px 0; border-bottom: 1px solid var(--divider); }
.download-list li:last-child { border-bottom: 0; }
.download-list img { width: 120px; height: 48px; object-fit: cover; border-radius: 8px; border: 1px solid var(--line); flex: none; }
.download-list .info { flex: 1; min-width: 0; }
.download-list small { display: block; color: var(--muted); }
.download-list .chip-update { background: var(--cream); border-color: var(--cream); color: var(--cream-ink); }
.contract-text { white-space: pre-line; background: var(--sample-bg); border: 1px solid var(--line); border-radius: 10px; padding: 12px 14px; margin: 10px 0 14px; line-height: 1.9; max-height: 340px; overflow: auto; }
.designer-pending { border-color: var(--gold); background: #fffaf0; }
.share-big { font-size: 18px; font-weight: 700; margin: 0 0 4px; }
.terms-list { margin: 6px 0 14px; padding-inline-start: 20px; line-height: 1.9; }
.table-wrap { overflow-x: auto; }
.data-table { width: 100%; border-collapse: collapse; font-size: 14px; }
.data-table th, .data-table td { text-align: start; padding: 10px 8px; border-bottom: 1px solid var(--divider); vertical-align: top; }
.data-table th { color: var(--muted); font-weight: 600; font-size: 13px; }
.data-table small { display: block; }
.payout-list { list-style: none; margin: 0 0 12px; padding: 0; }
.payout-list li { display: flex; flex-direction: column; gap: 4px; padding: 12px 0; border-bottom: 1px solid var(--divider); }
.payout-list small { color: var(--muted); }
.payout-list form { margin-top: 8px; display: flex; flex-wrap: wrap; gap: 8px; align-items: flex-end; }
.payout-list form .form-row { flex-basis: 100%; margin-bottom: 4px; }
.add-account summary, .reject-box summary, .payout-list summary { cursor: pointer; color: var(--brand); font-weight: 600; }
.add-account form { margin-top: 12px; }
.designer-form textarea, .designer-pending textarea, .add-account select, .designer-form input[type="url"] { width: 100%; }
.sub-status { font-size: 12px; vertical-align: middle; }
.sub-status-approved, .sub-status-paid { background: var(--mint); color: var(--mint-ink); }
.sub-status-rejected, .sub-status-withdrawn, .sub-status-cancelled { background: #fdecee; color: #991b1b; }
.sub-status-changes_requested, .sub-status-pending { background: var(--cream); color: var(--cream-ink); }
.sub-status-refunded, .sub-status-partially_refunded, .sub-status-expired, .sub-status-failed { background: var(--field); color: var(--muted); }
.level-error { color: #b42318; }
.level-warning { color: var(--cream-ink); }
.check-list { list-style: none; margin: 0 0 12px; padding: 0; display: grid; gap: 8px; }
.check-item { border: 1px solid var(--line); border-inline-start-width: 4px; border-radius: 10px; padding: 10px 14px; background: #fff; }
.check-item.level-error { border-inline-start-color: #d92d20; color: inherit; }
.check-item.level-warning { border-inline-start-color: #f79009; color: inherit; }
.check-item.level-info { border-inline-start-color: #98a2b3; }
.check-item textarea { width: 100%; margin-top: 4px; }
.check-level { font-size: 12px; }
.sub-preview-row { border-top: 1px solid var(--divider); padding: 8px 0; }
.sub-preview { font-size: 30px; line-height: 1.6; overflow-wrap: anywhere; }
.sub-decision-ok { border-color: #a6e2b6; }
.sub-decision-bad { border-color: #f4b7b2; }
.sub-comments .from-admin { background: var(--mint); }
.cart-list { list-style: none; margin: 0; padding: 0; }
.cart-list > li { display: flex; gap: 16px; align-items: center; justify-content: space-between; padding: 14px 0; border-bottom: 1px solid var(--divider); flex-wrap: wrap; }
.cart-list > li:last-child { border-bottom: 0; }
.cart-list > li.is-blocked { opacity: .75; }
.cart-list .line-info { flex: 1 1 260px; display: flex; flex-direction: column; gap: 2px; }
.cart-list .line-info small { color: var(--muted); }
.cart-list .line-price { text-align: end; white-space: nowrap; display: flex; flex-direction: column; font-weight: 700; }
.cart-list-compact > li { padding: 8px 0; }
.cart-total { font-size: 18px; font-weight: 800; margin: 16px 0 6px; }
.checkout-grid { display: grid; grid-template-columns: 1.2fr 1fr; gap: 20px; align-items: start; }
.checkout-grid fieldset { border: 0; padding: 0; margin: 0 0 14px; }
.checkout-grid legend { font-weight: 700; margin-bottom: 6px; }
.checkout-grid .check { display: inline-flex; align-items: center; gap: 6px; margin-inline-end: 16px; }
.checkout-grid input[type="text"] { width: 100%; }
.totals { display: grid; grid-template-columns: 1fr auto; gap: 6px 12px; margin: 12px 0; }
.totals dd { margin: 0; text-align: end; }
.doc-links { margin: 12px 0 0; padding-inline-start: 18px; }
.pay-again { display: flex; gap: 12px; align-items: center; flex-wrap: wrap; margin-top: 12px; }
.pay-again p { flex-basis: 100%; margin: 0; }
.rename-box { flex-basis: 100%; }
.rename-box form { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; margin-top: 8px; }
.rename-box p { flex-basis: 100%; margin: 0; }
.verify-status { font-size: 20px; }
.verify-valid strong { color: var(--mint-ink); }
.verify-revoked strong, .verify-superseded strong { color: #991b1b; }
.details-list { display: grid; grid-template-columns: max-content 1fr; gap: 6px 16px; }
.details-list dd { margin: 0; }
.verify-form { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; margin-top: 16px; }
.earnings-balances { display: grid; grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); gap: 0 18px; }
.facts { display: grid; grid-template-columns: max-content 1fr; gap: 6px 14px; margin: 0 0 12px; }
.facts dt { color: var(--muted); }
.facts dd { margin: 0; }
.inline-form { margin-bottom: 10px; }

/* ۱۲ واکنش‌گرا */

/* بلاک‌های صفحه اصلی از پنل (چت ۲۳) */
.section-lead { margin: 4px 0 0; color: var(--muted); font-size: 15px; }
.preview-notice { margin: 16px 0 0; padding: 10px 16px; border-radius: 12px; background: var(--gold); color: var(--ink); font-weight: 700; font-size: 14px; }
.image-banner { display: block; border-radius: var(--radius-lg); overflow: hidden; background: var(--field); }
.image-banner img { display: block; width: 100%; height: auto; aspect-ratio: 4 / 1; object-fit: cover; }
.feature-banner.theme-pomegranate { background: var(--brand); }
.feature-banner.theme-pomegranate .feature-text p { color: #FFE3E6; }
.feature-banner.theme-teal-light { background: var(--mint); color: var(--ink); }
.feature-banner.theme-cream { background: var(--cream); color: var(--ink); }
.feature-banner.theme-teal-light .feature-text h2, .feature-banner.theme-cream .feature-text h2 { color: var(--ink); }
.feature-banner.theme-teal-light .feature-text p, .feature-banner.theme-cream .feature-text p { color: var(--muted); }
.feature-banner.theme-teal-light .button-light, .feature-banner.theme-cream .button-light { background: var(--ink); color: #fff; }
.collection-hero { border-radius: var(--radius-lg); padding: 32px 36px; margin-bottom: 20px; }
.collection-hero .page-title { margin-top: 0; }
.collection-item { display: flex; flex-direction: column; gap: 8px; }
.collection-item > .card { flex: none; }
.collection-note { margin: 0; font-size: 14px; color: var(--muted); padding-inline: 4px; }

@media (max-width: 1180px) {
  .header-nav { gap: 16px; }
  .header-search { width: 200px; }
  .style-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .grid-4 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}
@media (max-width: 960px) {
  .container { padding-inline: 20px; }
  .menu-toggle { display: inline-flex; }
  .header-inner { gap: 10px; min-height: 64px; }
  .site-menu {
    display: none; position: absolute; inset-inline: 0; top: 100%; background: #fff; border-bottom: 1px solid var(--line);
    flex-direction: column; align-items: stretch; gap: 14px; padding: 16px 20px 20px; box-shadow: 0 16px 30px rgba(11, 46, 51, .10);
  }
  .menu-open .site-menu { display: flex; }
  .header-nav { flex-direction: column; gap: 0; font-size: 16px; }
  .header-nav a { padding: 10px 0; border-bottom: 1px solid var(--divider); }
  .header-nav a.is-active { border-bottom-color: var(--divider); color: var(--brand); }
  .header-search { width: auto; margin: 0; }
  .header-account { margin-inline-start: auto; gap: 4px; }
  .header-account .icon-button { border: 0; }
  .account-link { width: 44px; padding: 0; background: transparent; color: var(--ink); }
  .account-link:hover { background: var(--bg); color: var(--ink); }
  .account-link span { display: none; }
  .account-link svg { display: block; }
  .logout-form { display: none; }
  .footer-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .footer-about { grid-column: 1 / -1; }
  .collection-grid { grid-template-columns: 1fr; }
  .collection-card { flex-direction: row; flex-wrap: wrap; align-items: center; justify-content: space-between; padding: 18px 20px; }
  .collection-samples { min-height: 0; order: 2; }
  .collection-sample + .collection-sample { display: none; }
  .collection-count { flex-basis: 100%; order: 3; }
  .account-grid, .checkout-grid { grid-template-columns: 1fr; }
  .post-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 640px) {
  body { font-size: 15px; }
  .container { padding-inline: 16px; }
  .site-main { padding-top: 16px; padding-bottom: 40px; }
  .page-title, .font-head .page-title { font-size: 26px; }
  .brand-mark { width: 34px; height: 34px; font-size: 22px; border-radius: 9px; }
  .brand-name { font-size: 18px; }
  .only-mobile { display: block; }
  .hide-mobile { display: none; }
  .hero { padding: 16px 0 8px; gap: 24px; }
  .hero-title { font-size: 34px; line-height: 1.4; }
  .hero-lead { font-size: 15px; margin-bottom: 20px; }
  .hero-search .input-icon { height: 50px; }
  .hero-search .button { width: 50px; height: 50px; padding: 0; flex: none; }
  .chip-row { flex-wrap: nowrap; overflow-x: auto; scrollbar-width: none; }
  .chip-row .chip { flex: none; }
  .tester-card { border-radius: 18px; box-shadow: 0 12px 30px rgba(11, 46, 51, .10); }
  .tester-card-input { padding: 12px 14px; }
  .tester-card-input label { display: none; }
  .tester-card-preview { min-height: 140px; padding: 22px 18px; }
  .tester-card-preview p { font-size: 40px; }
  .tester-card-fonts { padding: 10px 14px 14px; flex-wrap: nowrap; overflow-x: auto; scrollbar-width: none; }
  .tester-card-fonts .chip { flex: none; }
  .tester-card-fonts .more-link { display: none; }
  .home-section { margin-bottom: 32px; }
  .section-head { margin-bottom: 12px; }
  .section-head h2 { font-size: 20px; }
  .section-tabs .chip { display: none; }
  .scroll-mobile { display: flex; overflow-x: auto; gap: 10px; margin-inline: -16px; padding-inline: 16px; scrollbar-width: none; }
  .scroll-mobile > * { flex: none; width: 118px; }
  .style-tile { padding: 12px; border-radius: 14px; }
  .style-sample { height: 64px; font-size: 32px; }
  .style-name { font-size: 14px; }
  .feature-banner { padding: 26px 22px; border-radius: 20px; gap: 18px; }
  .feature-text { display: contents; }
  .feature-text .pill { order: 1; }
  .feature-text h2 { order: 2; margin: 0; font-size: 24px; flex-basis: 100%; }
  .feature-text p { display: none; }
  .feature-words { order: 3; flex-basis: 100%; }
  .feature-text .button { order: 4; flex-basis: 100%; min-height: 48px; }
  .feature-word-1 { font-size: 54px; }
  .feature-word-2 { font-size: 40px; margin-inline-start: 60px; }
  .feature-word-3 { font-size: 50px; margin-inline-start: 0; }
  .image-banner img { aspect-ratio: 2 / 1; }
  .image-banner.has-mobile img { aspect-ratio: 4 / 5; }
  .collection-hero { padding: 22px 18px; }
  .grid, .grid-4 { grid-template-columns: 1fr; gap: 12px; }
  .card-sample { height: max(110px, calc(var(--sample-size, 26px) * 3)); font-size: var(--sample-size, 26px); padding: 12px 16px; }
  .home-section .grid-4 > .card:nth-child(n+6) { display: none; }
  .week-card { padding: 22px 18px; border-radius: 20px; gap: 16px; }
  .week-text h2 { font-size: 30px; }
  .week-desc { display: none; }
  .week-text .button-row { flex-direction: column; }
  .week-text .button { width: 100%; min-height: 48px; }
  .week-ladder { flex-basis: 100%; }
  .ladder-row:nth-child(even) { display: none; }
  .ladder-label { display: none; }
  .ladder-sample { font-size: 24px; }
  .designer-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .designer-card { padding: 14px; flex-direction: column; text-align: center; gap: 8px; }
  .designer-name { white-space: normal; }
  .cta-band { padding: 24px 20px; border-radius: 20px; gap: 16px; }
  .cta-band h2 { font-size: 22px; }
  .cta-band p { font-size: 14px; }
  .cta-band .button-row { width: 100%; flex-direction: column; }
  .cta-band .button { width: 100%; min-height: 48px; }
  .post-grid { grid-template-columns: 1fr; }
  .home-section .post-grid .post-card:nth-child(n+2) { display: none; }
  .footer-grid { padding-top: 28px; gap: 20px 16px; }
  .panel { padding: 16px; }
  .tester-preview { font-size: 36px; }
  .details dl { grid-template-columns: 1fr; gap: 2px 0; }
  .details dd { margin-bottom: 8px; }
  .download-box { width: 100%; }
  .filters { padding: 12px; }
  .filters select { flex: 1 1 calc(50% - 10px); min-width: 0; }
}
@media (prefers-reduced-motion: reduce) {
  * { transition: none !important; }
}
[dir="ltr"] .hero-title { font-size: 50px; letter-spacing: -1px; }
@media (max-width: 640px) { [dir="ltr"] .hero-title { font-size: 32px; } }

/* ۲۵ پسند، امتیاز و نظر */
.visually-hidden { position: absolute !important; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0; }
.like-form { margin-top: 12px; }
.like-button {
  width: 100%; min-height: 42px; background: #fff; color: var(--ink); border: 1px solid var(--line-2); font-weight: 600; font-size: 14px;
}
.like-button:hover { background: var(--brand-soft); color: var(--brand-dark); border-color: var(--brand-soft); }
.like-icon { fill: none; stroke: currentColor; stroke-width: 2; transition: transform .15s ease; }
.like-button.is-liked { background: var(--brand-soft); color: var(--brand-dark); border-color: #f6b9c1; }
.like-button.is-liked .like-icon { fill: var(--brand); stroke: var(--brand); transform: scale(1.08); }
.like-count { background: var(--bg); border-radius: 999px; padding: 0 9px; font-size: 13px; min-width: 28px; }
.like-button.is-liked .like-count { background: #fff; }

.reviews h3 { font-size: 17px; margin: 0 0 12px; }
.rating-box { display: grid; grid-template-columns: minmax(160px, 200px) minmax(180px, 1fr) minmax(220px, 1fr); gap: 24px; align-items: start;
  padding-bottom: 22px; margin-bottom: 22px; border-bottom: 1px solid var(--divider); }
.rating-summary { display: flex; flex-direction: column; gap: 6px; }
.rating-big { font-size: 40px; font-weight: 900; line-height: 1; }
.rating-big small { font-size: 16px; color: var(--muted); font-weight: 600; }
.stars { position: relative; display: inline-block; font-size: 22px; line-height: 1; letter-spacing: 2px; color: var(--line-2); width: max-content; }
.stars::before { content: "★★★★★"; }
.stars-fill { position: absolute; inset-block: 0; inset-inline-start: 0; overflow: hidden; color: var(--gold); white-space: nowrap; }
.stars-fill::before { content: "★★★★★"; }
.rating-bars { list-style: none; margin: 0; padding: 0; display: grid; gap: 6px; font-size: 13px; }
.rating-bars li { display: grid; grid-template-columns: 34px 1fr 36px; gap: 8px; align-items: center; }
.rating-bars .bar { height: 8px; background: var(--field); border-radius: 99px; overflow: hidden; }
.rating-bars .bar span { display: block; height: 100%; background: var(--gold); border-radius: 99px; }
.star-input { border: 0; margin: 0 0 10px; padding: 0; }
.star-input legend { font-weight: 700; font-size: 14px; margin-bottom: 4px; padding: 0; }
.star-input-row { display: inline-flex; flex-direction: row-reverse; gap: 2px; }
.star-input-row input { position: absolute; opacity: 0; width: 1px; height: 1px; }
.star-input-row label { font-size: 32px; line-height: 1; color: var(--line-2); cursor: pointer; padding: 2px; transition: color .1s; }
.star-input-row input:checked ~ label, .star-input-row label:hover, .star-input-row label:hover ~ label { color: var(--gold); }
.star-input-row input:focus-visible + label { outline: 3px solid rgba(215, 38, 61, .45); border-radius: 6px; }

.comment-form textarea, .reply-box textarea { width: 100%; }
.comment-form-foot { display: flex; flex-wrap: wrap; gap: 10px; justify-content: space-between; align-items: center; margin-top: 8px; }
.comment-list, .comment-replies { list-style: none; margin: 18px 0 0; padding: 0; display: grid; gap: 14px; }
.comment-replies { margin-top: 10px; padding-inline-start: 22px; border-inline-start: 2px solid var(--divider); }
.comment { background: var(--sample-bg); border: 1px solid var(--divider); border-radius: var(--radius-sm); padding: 14px 16px; }
.comment.is-staff { background: var(--mint); border-color: #b3e3dc; }
.comment.is-hidden-for-others { border-style: dashed; opacity: .85; }
.comment-head { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; font-size: 14px; margin-bottom: 6px; }
.comment-head time { font-size: 13px; }
.comment-body { overflow-wrap: anywhere; }
.comment-reason { font-size: 13px; margin: 6px 0 0; }
.comment-actions { display: flex; gap: 14px; margin-top: 6px; font-size: 13px; }
.comment-actions .link-button { font-size: 13px; }
.comment .chip { min-height: 26px; padding: 0 10px; font-size: 12px; cursor: default; }
.chip-designer, .chip-admin { background: var(--ink); color: #fff; border-color: var(--ink); }
.chip-buyer { background: var(--cream); color: var(--cream-ink); border-color: var(--cream); }
.chip-pending { background: var(--cream); color: var(--cream-ink); border-color: var(--cream); font-size: 12px; }
.chip-rejected { background: #fef2f2; color: #991b1b; border-color: #fecaca; font-size: 12px; }
.reply-box { margin-top: 8px; }
.reply-box summary { cursor: pointer; color: var(--brand); font-size: 14px; font-weight: 600; width: max-content; }
.reply-box form { margin-top: 8px; display: grid; gap: 8px; justify-items: start; }
.favorites-grid { margin-top: 8px; }

@media (max-width: 900px) {
  .rating-box { grid-template-columns: 1fr; gap: 16px; }
}

/* ورود پیامکی و کپچا (چت ۲۶) */
.hp-field { position: absolute !important; inset-inline-start: -10000px; width: 1px; height: 1px; overflow: hidden; }
.captcha-box { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; }
.captcha-box img { border: 1px solid var(--line); border-radius: var(--radius-sm); background: #f6f1e8; max-width: 100%; height: auto; }
.button-link { background: none; border: 0; padding: 0; min-height: 0; font-weight: 400; display: inline; color: var(--brand); font-family: inherit; font-size: 14px; cursor: pointer; text-decoration: underline; text-underline-offset: 3px; box-shadow: none; }
.button-link:hover { background: none; color: var(--brand-dark); }
.button-link:disabled { color: var(--muted); cursor: default; text-decoration: none; }
.otp-input { font-size: 22px; letter-spacing: .4em; text-align: center; font-variant-numeric: tabular-nums; }
.resend-form { margin-top: 14px; }
.login-alt { margin-top: 22px; border-top: 1px solid var(--line); padding-top: 14px; }
.login-alt > summary { cursor: pointer; color: var(--muted); font-size: 14px; margin-bottom: 12px; }
.login-alt[open] > summary { margin-bottom: 16px; }
.download-note { color: var(--muted); font-size: 13px; margin-top: 6px; }

/* ---- نمای فهرست فونت‌ها: شبکه‌ای/فهرستی، اندازه نمونه، دکمه «بیشتر» (_sample-bar، _font-list، catalog.js) ---- */
.sample-bar input.js-sample-input { flex: 1 1 260px; }
.list-controls { display: flex; align-items: center; gap: 14px; }
.size-control { display: flex; align-items: center; gap: 8px; font-size: 13px; color: var(--muted); white-space: nowrap; }
.size-control input[type="range"] { flex: none; width: 120px; padding: 0; background: transparent; border: 0; accent-color: var(--ink); }
.view-toggle { display: inline-flex; gap: 4px; }
.view-toggle button {
  background: transparent; color: var(--muted); border: 1px solid var(--line); border-radius: 10px;
  min-width: 40px; min-height: 40px; padding: 0; display: inline-flex; align-items: center; justify-content: center;
}
.view-toggle button:hover { background: var(--surface); color: var(--ink); border-color: var(--ink); }
.view-toggle button[aria-pressed="true"] { background: var(--ink); border-color: var(--ink); color: #fff; }
.view-icon { display: block; width: 18px; height: 18px; }
.view-grid-btn .view-icon {
  background:
    linear-gradient(currentColor, currentColor) 0 0 / 7px 7px no-repeat,
    linear-gradient(currentColor, currentColor) 11px 0 / 7px 7px no-repeat,
    linear-gradient(currentColor, currentColor) 0 11px / 7px 7px no-repeat,
    linear-gradient(currentColor, currentColor) 11px 11px / 7px 7px no-repeat;
}
.view-list-btn .view-icon {
  background:
    linear-gradient(currentColor, currentColor) 0 2px / 100% 3px no-repeat,
    linear-gradient(currentColor, currentColor) 0 8px / 100% 3px no-repeat,
    linear-gradient(currentColor, currentColor) 0 14px / 100% 3px no-repeat;
}

/* فهرستی: هر فونت یک ردیف تمام‌عرض؛ نام کنار نمونه بزرگ */
.grid.view-list { grid-template-columns: minmax(0, 1fr); gap: 12px; }
.view-list .card { flex-direction: row; }
.view-list .card:hover { transform: none; }
.view-list .card-body { order: -1; flex: 0 0 240px; justify-content: center; border-inline-end: 1px solid var(--divider); }
.view-list .card-sample {
  flex: 1; min-width: 0; height: auto; min-height: max(110px, calc(var(--sample-size, 30px) * 2.2));
  justify-content: flex-start; text-align: start; border-bottom: 0; padding: 12px 22px;
}
.view-list .card-image img { width: auto; max-width: 100%; height: 110px; object-fit: contain; }
.view-list .collection-item { display: flex; flex-direction: column; }

.list-previous { text-align: center; margin: 0 0 16px; }
.load-more { display: flex; justify-content: center; margin: 0 0 28px; }
.load-more .button[aria-busy="true"] { opacity: .7; cursor: progress; }

@media (max-width: 640px) {
  /* در موبایل هر دو نما یک ستون‌اند؛ فهرستی همان کارت عمودی می‌شود */
  .view-toggle { display: none; }
  .view-list .card { flex-direction: column; }
  .view-list .card-body { order: 0; flex: none; border-inline-end: 0; }
  .view-list .card-sample { justify-content: center; text-align: center; border-bottom: 1px solid var(--divider); }
  .size-control input[type="range"] { width: 90px; }
}


/* ۱۳ طرح رنگی و پرجان (چت ۲۹؛ طرح مرجع: artifact 80f278f4 → Vivid.dc.html / VividMobile.dc.html)
   فیروزه تیره برای سربرگ (همه صفحه‌ها)، هیروی صفحه اصلی و دعوت طراحان؛ زعفران برای لوگو و تأکید؛ انار برای دکمه اصلی و لینک‌ها. */

/* نوار سه‌رنگ امضای برند: بالای سربرگ و بالای پانویس */
.site-header::before, .site-footer::before { content: ""; display: block; height: 5px; background: var(--stripe); }

/* سربرگ تیره */
.site-header { background: var(--deep); border-bottom: 0; color: #fff; }
.header-inner { min-height: 76px; }
.site-header .brand, .site-header .brand:hover { color: #fff; }
.brand-mark { background: var(--saffron); color: var(--ink); border-radius: 12px; }
.header-nav a { color: var(--on-deep-nav); }
.header-nav a:hover { color: #fff; }
.header-nav a.is-active { color: #fff; font-weight: 700; border-bottom-color: var(--saffron); }
.header-search { background: var(--veil); color: var(--on-deep-nav); border-radius: 12px; }
.header-search input { color: #fff; }
.header-search input::placeholder { color: var(--on-deep-nav); opacity: .85; }
.header-search:focus-within { box-shadow: 0 0 0 2px var(--saffron); }
.site-header .icon-button { background: var(--veil); border-color: transparent; color: #fff; border-radius: 12px; }
.site-header .icon-button:hover { background: rgba(255, 255, 255, .18); color: #fff; }
.site-header .account-link { background: #fff; color: var(--ink); border-radius: 12px; }
.site-header .account-link:hover { background: var(--mint); color: var(--ink); }
.site-header .logout-form .link-button { color: var(--on-deep-nav); }
.site-header .cart-count { box-shadow: 0 0 0 2px var(--deep); }
.site-header :focus-visible { outline-color: var(--saffron); }

/* پایه: کارت‌ها بی‌قاب با سایه نرم، گوشه‌های گردتر، تیترها پررنگ‌تر */
.card, .designer-card, .post-card, .style-tile { border-color: transparent; box-shadow: var(--card-shadow); }
.card { border-radius: 20px; }
.card:hover { border-color: transparent; box-shadow: 0 2px 4px rgba(11, 46, 51, .06), 0 14px 34px rgba(11, 46, 51, .12); }
.card-sample { margin: 8px 8px 0; border-radius: 14px; border-bottom: 0; background: var(--mint); color: var(--mint-ink-2); }
.card-image { margin: 0; border-radius: 0; }
.card-title { font-weight: 800; }
.section-head h2 { font-size: 28px; font-weight: 900; }
.section-tabs { background: #fff; border: 1px solid var(--line); border-radius: 999px; padding: 4px; gap: 4px; }
.section-tabs .chip { border: 0; background: transparent; color: var(--muted); min-height: 38px; padding: 0 16px; }
.section-tabs .chip:hover { color: var(--ink); background: var(--bg); }
.section-tabs .chip.is-active { background: var(--ink); color: #fff; }
.section-tabs .more-link { padding-inline: 10px 12px; margin-inline-start: 4px; }

/* نمونه هر کارت فونت رنگ ملایم خودش را دارد (به نوبت؛ در کاتالوگ، صفحه اصلی و مجموعه‌ها) */
:is(.grid > .card, .grid > .collection-item, .rail-track > .card):nth-child(5n+1) .card-sample { background: var(--rose); color: var(--rose-ink); }
:is(.grid > .card, .grid > .collection-item, .rail-track > .card):nth-child(5n+2) .card-sample { background: var(--cream); color: var(--cream-ink-2); }
:is(.grid > .card, .grid > .collection-item, .rail-track > .card):nth-child(5n+3) .card-sample { background: var(--mint); color: var(--mint-ink-2); }
:is(.grid > .card, .grid > .collection-item, .rail-track > .card):nth-child(5n+4) .card-sample { background: var(--lilac); color: var(--lilac-ink); }
:is(.grid > .card, .grid > .collection-item, .rail-track > .card):nth-child(5n+5) .card-sample { background: var(--sky); color: var(--sky-ink); }
.view-list .card-sample { margin: 8px; border-radius: 14px; }
.view-list .card-body { border-inline-end: 0; }

/* صفحه اصلی: هیروی تمام‌عرض روی فیروزه تیره، چسبیده به سربرگ */
.is-home .site-main { padding-top: 0; }
.hero {
  position: relative; isolation: isolate; color: #fff; background: var(--deep);
  /* زمینه تا لبه‌های صفحه، بی‌اسکرول افقی: سایه ۱۰۰vmax رنگ را پهن می‌کند و clip-path فقط بالا و پایین را می‌برد */
  box-shadow: 0 0 0 100vmax var(--deep); clip-path: inset(0 -100vmax);
  padding: 56px 0 96px; margin-bottom: 64px; gap: 56px;
}
.hero-deco { position: absolute; inset: 0; z-index: -1; pointer-events: none; }
.hero-deco-mark {
  position: absolute; inset-inline-end: -60px; top: -150px; font-family: "FB Logo", var(--font); font-size: 640px; line-height: 1;
  color: rgba(255, 255, 255, .05); user-select: none;
}
.hero-deco .dot { position: absolute; border-radius: 50%; }
.dot-saffron { width: 26px; height: 26px; background: var(--saffron); inset-inline-start: 46%; top: 72px; }
.dot-brand { width: 14px; height: 14px; background: var(--brand); inset-inline-end: 47%; bottom: 120px; }
.dot-ring { width: 64px; height: 64px; border: 3px solid var(--aqua); inset-inline-start: 41%; bottom: 60px; }
.hero .kicker {
  display: inline-flex; align-items: center; margin: 0 0 18px; padding: 5px 14px; border-radius: 999px;
  background: rgba(246, 196, 69, .16); color: var(--saffron); font-weight: 700;
}
.hero-title { color: #fff; font-size: 50px; line-height: 1.45; letter-spacing: 0; }
.hero-title .hl, .hl { color: var(--saffron); }
.hero-lead { color: var(--on-ink); max-width: 44ch; }
.hero-search { background: #fff; border-radius: 16px; padding: 6px; gap: 6px; max-width: 540px; margin-bottom: 22px; }
.hero-search .input-icon { border: 0; height: 52px; padding-inline: 12px; }
.hero-search .input-icon:focus-within { box-shadow: none; }
.hero-search:focus-within { box-shadow: 0 0 0 3px var(--saffron); }
.hero-search .button { height: 52px; font-weight: 800; }
.hero .chip-row .chip { background: var(--veil); border-color: transparent; color: #fff; padding-inline: 14px 16px; }
.hero .chip-row .chip:hover { background: rgba(255, 255, 255, .18); color: #fff; }
.hero .chip-row .chip small { color: #fff; font-weight: 700; font-size: 13px; }
.hero .chip-row .chip::before { content: ""; width: 8px; height: 8px; border-radius: 50%; background: var(--brand); flex: none; }
.hero .chip-row .chip:nth-child(3n+2)::before { background: var(--saffron); }
.hero .chip-row .chip:nth-child(3n+3)::before { background: var(--aqua); }
.hero :focus-visible { outline-color: var(--saffron); }

/* کارت تست‌کننده: سفید روی تیره؛ زمینه نمونه با فونت انتخاب‌شده عوض می‌شود (catalog.js → data-tone) */
.tester-card { border: 0; border-radius: 24px; box-shadow: 0 30px 70px rgba(0, 0, 0, .28); color: var(--ink); }
.tester-card-input { padding: 16px 20px; }
.tester-card-input label { font-weight: 600; }
.tester-card-preview { min-height: 220px; background: var(--cream); color: var(--cream-ink-2); transition: background-color .25s, color .25s; }
.tester-card[data-tone="1"] .tester-card-preview { background: var(--mint); color: var(--mint-ink-2); }
.tester-card[data-tone="2"] .tester-card-preview { background: var(--rose); color: var(--rose-ink); }
.tester-card[data-tone="3"] .tester-card-preview { background: var(--lilac); color: var(--lilac-ink); }
.tester-card[data-tone="4"] .tester-card-preview { background: var(--sky); color: var(--sky-ink); }
.tester-card-fonts { border-top: 0; padding: 14px 20px 18px; }
.tester-card-fonts .chip { background: var(--bg); border-color: var(--line); color: var(--ink); }
.tester-card-fonts .chip[aria-pressed="true"] { background: var(--brand); border-color: var(--brand); color: #fff; }
.tester-card-fonts .more-link { font-weight: 700; }

/* بر اساس سبک: کاشی رنگی بی‌قاب با دایره کم‌رنگ در گوشه */
.style-grid { grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: 16px; }
.style-tile { position: relative; overflow: hidden; border: 0; border-radius: 22px; padding: 22px 20px 20px; box-shadow: none; }
.style-tile::before { content: ""; position: absolute; inset-inline-start: -18px; top: -18px; width: 72px; height: 72px; border-radius: 50%; background: currentColor; opacity: .14; }
.style-tile:hover { border: 0; transform: translateY(-2px); }
.style-tile { transition: transform .15s; }
.style-sample { height: 100px; justify-content: flex-start; font-size: 52px; }
.style-name { font-weight: 800; font-size: 15px; color: var(--ink); }
.style-count { font-size: 13px; color: #35514F; }
.tile-mint { background: var(--mint); color: var(--mint-ink-2); }
.tile-cream { background: var(--cream); color: var(--cream-ink-2); }
.tile-rose { background: var(--rose); color: var(--rose-ink); }
.tile-sky { background: var(--sky); color: var(--sky-ink); }
.tile-lilac { background: var(--lilac); color: var(--lilac-ink); }
.tile-mint:hover { color: var(--mint-ink-2); } .tile-cream:hover { color: var(--cream-ink-2); } .tile-rose:hover { color: var(--rose-ink); }
.tile-sky:hover { color: var(--sky-ink); } .tile-lilac:hover { color: var(--lilac-ink); }

/* بنر ساخته‌شده و تصویری */
.feature-banner, .image-banner { border-radius: 28px; }
.feature-banner { position: relative; overflow: hidden; }
.feature-text .pill-sale { background: var(--saffron); }

/* فونت هفته: بلوک فیروزه روشن، نردبان وزن در کارت سفید با شماره‌های رنگی */
.week-card { position: relative; overflow: hidden; isolation: isolate; background: var(--mint); border: 0; border-radius: 28px; padding: 48px 52px; align-items: center; }
.week-card::before { content: ""; position: absolute; z-index: -1; inset-inline-start: -40px; top: -40px; width: 160px; height: 160px; border-radius: 50%; background: var(--saffron); opacity: .35; }
.week-text .kicker { align-self: flex-start; background: var(--brand); color: #fff; padding: 3px 14px; border-radius: 999px; font-weight: 800; }
.week-text h2 { font-size: 60px; color: var(--deep); }
.week-text .muted { color: #35514F; }
.week-text .button-outline { background: #fff; border-color: #fff; }
.week-ladder { background: #fff; border-radius: 22px; padding: 10px 28px; }
.ladder-label { font-weight: 700; font-size: 13px; color: var(--teal); }
.ladder-row:nth-child(5n+2) .ladder-label { color: var(--sky-ink); }
.ladder-row:nth-child(5n+3) .ladder-label { color: var(--lilac-ink); }
.ladder-row:nth-child(5n+4) .ladder-label { color: #B8860B; }
.ladder-row:nth-child(5n+5) .ladder-label { color: var(--brand); }
.ladder-sample { font-size: 32px; }

/* مجموعه‌های دستچین */
.collection-card { border-radius: 24px; }

/* طراحان: مربع گرد با رنگ پر */
.designer-card { border: 0; border-radius: 20px; }
.designer-card:hover { border: 0; box-shadow: 0 2px 4px rgba(11, 46, 51, .06), 0 14px 34px rgba(11, 46, 51, .12); }
.designer-initial { border-radius: 18px; font-family: var(--font); font-weight: 900; font-size: 22px; }
.solid-brand { background: var(--brand); color: #fff; }
.solid-saffron { background: var(--saffron); color: var(--ink); }
.solid-teal { background: var(--teal); color: #fff; }
.solid-violet { background: var(--lilac-ink); color: #fff; }
.designer-name { font-weight: 800; }

/* دعوت طراحان: فیروزه تیره با «ابجد» بزرگ کم‌رنگ، دکمه زعفرانی */
.cta-band { position: relative; overflow: hidden; isolation: isolate; background: var(--deep); border-radius: 28px; padding: 48px 56px; }
.cta-band p { color: var(--on-ink); }
.cta-band h2 { font-size: 34px; }
.cta-deco {
  position: absolute; z-index: -1; inset-inline-start: 22%; top: -70px; font-family: "FB Logo", var(--font); font-size: 260px; line-height: 1;
  color: rgba(255, 255, 255, .05); pointer-events: none; user-select: none; white-space: nowrap;
}
.cta-band::after { content: ""; position: absolute; z-index: -1; inset-inline-end: 30%; bottom: 26px; width: 18px; height: 18px; border-radius: 50%; background: var(--brand); }
.button-saffron { background: var(--saffron); color: var(--ink); font-weight: 800; }
.button-saffron:hover { background: #FFD66B; color: var(--ink); }
.cta-band :focus-visible { outline-color: var(--saffron); }
/* حرکت آرام حروف تزئینی و نقطه (فقط transform/opacity: روی GPU، بدون جاوااسکریپت). کلمه یک‌جا حرکت می‌کند تا اتصال حروف فارسی نشکند. */
.cta-deco { transform-origin: 30% 60%; animation: fb-cta-drift 16s ease-in-out infinite alternate; will-change: transform; transition: color .6s ease; }
.cta-band:hover .cta-deco { color: rgba(255, 255, 255, .085); }
.cta-band::after { animation: fb-cta-bob 5s ease-in-out infinite; }
@keyframes fb-cta-drift {
  0%   { transform: translate3d(0, 0, 0) scale(1) rotate(0deg); }
  50%  { transform: translate3d(-24px, 10px, 0) scale(1.09) rotate(-2deg); }
  100% { transform: translate3d(14px, -8px, 0) scale(.95) rotate(1.5deg); }
}
@keyframes fb-cta-bob {
  0%, 100% { transform: translateY(0) scale(1); }
  50%      { transform: translateY(-14px) scale(1.15); }
}
@media (prefers-reduced-motion: reduce) {
  .cta-deco, .cta-band::after { animation: none; }
}

/* بلاگ */
.post-card { border: 0; border-radius: 22px; }
.post-cover-type.tone-ink { background: var(--deep); color: var(--saffron); }
.post-cover-type.tone-rose { background: var(--brand); color: #fff; }
.post-cover-type.tone-cream { background: var(--saffron); color: var(--ink); }

/* پانویس */
.site-footer .brand-mark { background: var(--saffron); color: var(--ink); }

@media (max-width: 960px) {
  .site-menu { background: var(--deep); border-bottom: 0; box-shadow: 0 16px 30px rgba(0, 0, 0, .25); }
  .header-nav a { border-bottom-color: rgba(255, 255, 255, .10); }
  .header-nav a.is-active { color: var(--saffron); border-bottom-color: rgba(255, 255, 255, .10); }
  .site-header .account-link { background: transparent; color: #fff; }
  .site-header .account-link:hover { background: var(--veil); color: #fff; }
  .site-header .icon-button { background: transparent; }
  .hero-deco .dot { display: none; }
}
@media (max-width: 640px) {
  .header-inner { min-height: 64px; }
  .hero { padding: 28px 0 40px; margin-bottom: 36px; }
  .hero-deco-mark { font-size: 360px; top: 30px; inset-inline-end: auto; inset-inline-start: -70px; }
  .hero-title, [dir="ltr"] .hero-title { font-size: 31px; line-height: 1.5; }
  .hero-search { padding: 5px; border-radius: 14px; }
  .hero-search .input-icon { height: 48px; }
  .hero-search .button { width: 48px; height: 48px; }
  .hero .chip-row .chip { min-height: 32px; font-size: 13px; }
  /* تست‌کننده در موبایل کمی روی لبه پایین هیرو می‌نشیند */
  .tester-card { border-radius: 20px; }
  .tester-card-preview { min-height: 130px; }
  .section-head h2 { font-size: 22px; }
  .section-tabs { display: none; }
  .style-grid { display: flex; }
  .style-tile { padding: 16px 14px 14px; border-radius: 18px; }
  .style-sample { height: 70px; font-size: 40px; }
  .week-card { padding: 26px 20px; border-radius: 22px; }
  .week-text h2 { font-size: 44px; }
  .week-ladder { padding: 6px 16px; border-radius: 16px; }
  .ladder-sample { font-size: 24px; }
  .designer-card { padding: 12px; }
  .designer-initial { width: 44px; height: 44px; border-radius: 13px; font-size: 18px; }
  .cta-band { padding: 30px 22px; border-radius: 22px; }
  .cta-band h2 { font-size: 24px; }
  .cta-deco { font-size: 150px; top: auto; bottom: -40px; inset-inline-start: -10px; }
  .cta-band::after { display: none; }
  .card { border-radius: 18px; }
  .card-sample { margin: 6px 6px 0; border-radius: 13px; }
}

/* ۱۴ منوی بزرگ «همه فونت‌ها» (چت ۳۰؛ fontbank/_mega-menu، Catalog/NavMenu، catalog.js) */
.header-inner { position: relative; }
.nav-item { display: inline-flex; align-items: center; gap: 2px; }
.mega-toggle {
  min-height: 32px; width: 28px; padding: 0; border: 0; border-radius: 8px; background: transparent; color: var(--on-deep-nav);
}
.mega-toggle:hover, .has-mega.is-open .mega-toggle { background: var(--veil); color: #fff; }
.mega-toggle svg { transition: transform .15s; }
.has-mega.is-open .mega-toggle svg { transform: rotate(180deg); }
.mega { display: none; position: absolute; z-index: 30; top: 100%; inset-inline: 32px; white-space: normal; }
/* پل نامرئی بین پیوند و پنل تا ماوس در راه پایین آمدن منو را نبندد */
.mega::before { content: ""; position: absolute; inset-inline: 0; bottom: 100%; height: 24px; }
.has-mega.is-open .mega { display: block; }
@media (hover: hover) and (min-width: 961px) {
  .has-mega:hover .mega { display: block; }
  .has-mega:hover .mega-toggle svg { transform: rotate(180deg); }
}
.mega-inner {
  background: #fff; color: var(--ink); border-radius: 0 0 24px 24px; box-shadow: 0 24px 60px rgba(11, 46, 51, .22);
  padding: 28px 32px 30px; display: grid; grid-template-columns: minmax(0, 1.5fr) minmax(0, 1.2fr) minmax(0, 1fr); gap: 36px;
  border-top: 1px solid var(--divider);
}
.mega-col { display: flex; flex-direction: column; align-items: flex-start; min-width: 0; }
.mega-col h2 { margin: 0 0 12px; font-size: 13px; font-weight: 800; color: var(--muted); }
.mega-col .mega-sub { margin-top: 18px; }
.mega ul { list-style: none; margin: 0; padding: 0; }
.header-nav .mega a { color: var(--ink); padding: 0; border-bottom: 0; font-weight: 500; }
.header-nav .mega a:hover { color: var(--brand); }
.header-nav .mega .more-link { margin-top: 12px; color: var(--brand); font-size: 13px; font-weight: 700; }

.mega-tiles { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; width: 100%; }
.header-nav .mega .mega-tile { display: flex; flex-direction: column; padding: 10px 14px 10px; border-radius: 14px; transition: transform .15s; }
.header-nav .mega .mega-tile:hover { color: var(--ink); transform: translateY(-1px); }
.mega-sample { font-size: 30px; line-height: 1.35; height: 42px; overflow: hidden; opacity: .5; transition: opacity .25s; }
.mega-sample.is-ready { opacity: 1; }
.mega-tile-name { font-size: 13px; font-weight: 800; }
.mega-tile small { font-size: 12px; color: #35514F; }
.header-nav .mega .tile-mint .mega-sample { color: var(--mint-ink-2); }
.header-nav .mega .tile-cream .mega-sample { color: var(--cream-ink-2); }
.header-nav .mega .tile-rose .mega-sample { color: var(--rose-ink); }
.header-nav .mega .tile-sky .mega-sample { color: var(--sky-ink); }
.header-nav .mega .tile-lilac .mega-sample { color: var(--lilac-ink); }

.mega-chips { display: flex; flex-wrap: wrap; gap: 6px; }
.header-nav .mega .chip { min-height: 34px; padding: 0 12px; background: var(--bg); border-color: transparent; font-size: 13px; }
.header-nav .mega .chip:hover { background: var(--ink); color: #fff; }
.header-nav .mega .chip:hover small { color: var(--on-ink); }

.mega-list { width: 100%; }
.header-nav .mega .mega-list a { display: flex; align-items: center; gap: 10px; padding: 7px 0; font-size: 14px; }
.mega-list small { margin-inline-start: auto; color: var(--muted); font-size: 12px; }
.lang-dot, .collection-dot { width: 10px; height: 10px; border-radius: 50%; flex: none; }
.lang-0 { background: var(--brand); } .lang-1 { background: var(--saffron); } .lang-2 { background: var(--teal); }
.collection-dot.tone-rose { background: #F3A7B1; } .collection-dot.tone-cream { background: var(--saffron); } .collection-dot.tone-mint { background: var(--aqua); }
.header-nav .mega .mega-all { margin-top: 18px; width: 100%; color: #fff; font-weight: 800; min-height: 46px; }
.header-nav .mega .mega-all:hover { color: #fff; }

@media (max-width: 1180px) {
  .mega-inner { grid-template-columns: minmax(0, 1.4fr) minmax(0, 1fr); }
  .mega-languages { grid-column: 1 / -1; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); column-gap: 36px; align-items: start; }
}
@media (max-width: 960px) {
  .nav-item { display: flex; flex-wrap: wrap; align-items: center; border-bottom: 1px solid rgba(255, 255, 255, .10); }
  .nav-item > a { flex: 1; border-bottom: 0 !important; }
  .mega-toggle { width: 44px; min-height: 44px; }
  .mega { position: static; flex-basis: 100%; padding-bottom: 12px; }
  .mega::before { display: none; }
  .mega-inner { border-radius: 16px; box-shadow: none; border-top: 0; padding: 16px; grid-template-columns: 1fr; gap: 18px; }
  .mega-languages { display: flex; }
  .mega-sample { font-size: 24px; height: 34px; }
}

/* ۱۵ کارت مجموعه (چت ۳۰): نام مجموعه درشت و اول؛ زیرش «ابجد» با چند فونت مختلف مجموعه، بی نام فونت */
.collection-card { gap: 14px; padding: 26px 26px 22px; justify-content: space-between; min-height: 230px; }
.collection-card .collection-name { font-size: 24px; font-weight: 900; line-height: 1.5; }
.collection-glyphs { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 8px; }
.collection-glyph {
  display: flex; align-items: center; justify-content: center; min-width: 0; height: 64px; padding: 0 6px; overflow: hidden;
  border-radius: 14px; background: rgba(255, 255, 255, .7); font-size: 26px; line-height: 1; white-space: nowrap;
  opacity: .5; transition: opacity .25s;
}
.collection-glyph.is-ready { opacity: 1; }
.tone-rose .collection-glyph { color: var(--rose-ink); }
.tone-cream .collection-glyph { color: var(--cream-ink-2); }
.tone-mint .collection-glyph { color: var(--mint-ink-2); }
.tone-ink .collection-glyph { background: rgba(255, 255, 255, .1); color: var(--gold); }
.tone-ink .collection-name { color: #fff; }
@media (max-width: 960px) {
  .collection-card { flex-direction: column; flex-wrap: nowrap; align-items: stretch; min-height: 0; padding: 20px; }
  .collection-card .collection-name { font-size: 20px; }
  .collection-glyph { height: 52px; font-size: 22px; }
}

/* ۱۶ تماس با ما (چت ۳۱) */
.contact-lead { margin: -4px 0 24px; }
.contact-grid { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 2fr); gap: 24px; align-items: start; margin-bottom: 24px; }
.contact-ways { background: var(--deep); color: #fff; border-radius: 24px; padding: 26px; position: relative; overflow: hidden; isolation: isolate; }
.contact-ways::after { content: ""; position: absolute; inset-inline-end: -30px; bottom: -30px; width: 120px; height: 120px; border-radius: 50%; background: var(--saffron); opacity: .2; z-index: -1; }
.contact-ways h2 { color: #fff; font-size: 18px; margin: 0 0 16px; }
.contact-way { display: flex; align-items: center; gap: 12px; margin: 0 0 14px; }
.contact-way > span:last-child { display: flex; flex-direction: column; min-width: 0; }
.contact-way small { color: var(--on-ink); font-size: 12px; }
.contact-way a { color: #fff; font-weight: 700; overflow-wrap: anywhere; }
.contact-way a:hover { color: var(--saffron); }
.contact-icon { width: 42px; height: 42px; flex: none; border-radius: 12px; background: var(--veil); color: var(--saffron); display: inline-flex; align-items: center; justify-content: center; }
.contact-designers { margin: 20px 0 0; padding-top: 16px; border-top: 1px solid var(--on-ink-line); color: var(--on-ink); font-size: 14px; position: relative; z-index: 1; }
.contact-designers .more-link { color: var(--saffron); display: inline-block; margin-top: 4px; }
.contact-form { border: 0; box-shadow: var(--card-shadow); border-radius: 24px; padding: 26px 28px; }
.contact-form h2 { font-size: 18px; }
.contact-fields { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 0 16px; }
.contact-form textarea { min-height: 160px; }
@media (max-width: 860px) {
  .contact-grid { grid-template-columns: 1fr; }
  .contact-fields { grid-template-columns: 1fr; }
  .contact-form { padding: 20px 18px; }
}

/* ۱۷ طراحان (چت ۳۲؛ fontbank/designers/*): کارت طاق‌نما، فهرست الفبایی زبان‌های دیگر، سربرگ پروفایل و آیکون‌های ارتباطی */
.tone-0 { --tone-bg: var(--rose); --tone-arch: #F7CDD3; --tone-ink: var(--rose-ink); }
.tone-1 { --tone-bg: var(--mint); --tone-arch: #BDE6E0; --tone-ink: var(--mint-ink-2); }
.tone-2 { --tone-bg: var(--cream); --tone-arch: #FBE0A4; --tone-ink: var(--cream-ink-2); }
.tone-3 { --tone-bg: var(--lilac); --tone-arch: #D5CCF6; --tone-ink: var(--lilac-ink); }
.tone-4 { --tone-bg: var(--sky); --tone-arch: #C9DDF0; --tone-ink: var(--sky-ink); }

.designers-head { display: flex; flex-wrap: wrap; align-items: flex-end; justify-content: space-between; gap: 18px 32px; margin-bottom: 28px; }
.designers-head .page-title { margin-bottom: 8px; }
.designers-head .lead { margin: 0; color: var(--muted); }
.designer-langs { display: flex; flex-wrap: wrap; gap: 8px; }
.lang-pill { display: inline-flex; align-items: center; gap: 8px; padding: 9px 16px; border-radius: 999px; background: var(--surface); border: 1px solid var(--line); color: var(--ink); font-weight: 700; font-size: 14px; box-shadow: var(--card-shadow); }
.lang-pill small { background: var(--field); color: var(--muted); border-radius: 999px; padding: 1px 8px; font-size: 12px; }
.lang-pill:hover { color: var(--ink); border-color: var(--ink); }
.lang-pill.is-active { background: var(--deep); border-color: var(--deep); color: #fff; }
.lang-pill.is-active small { background: var(--veil); color: var(--on-deep-nav); }

.designer-search { margin: 0 0 24px; }
.designer-search input { width: 100%; max-width: 380px; border-radius: 999px; padding-inline: 20px; }

.dcard-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(210px, 1fr)); gap: 26px 22px; margin-bottom: 40px; }
.dcard-grid-home { grid-template-columns: repeat(4, minmax(0, 1fr)); margin-bottom: 0; }
.dcard { display: flex; flex-direction: column; background: var(--tone-bg); border-radius: 30px; padding: 16px 16px 20px; color: var(--ink); box-shadow: var(--card-shadow); transition: transform .2s ease, box-shadow .2s ease; }
.dcard[hidden] { display: none; }
.dcard:hover, .dcard:focus-visible { color: var(--ink); transform: translateY(-4px); box-shadow: 0 2px 4px rgba(11, 46, 51, .06), 0 18px 40px rgba(11, 46, 51, .14); }

/* طاق: بالا نیم‌دایره، پایین گوشه نرم؛ قاب نازک سفید درون آن مثل درگاه دوجداره */
.dcard-arch, .designer-hero-arch { position: relative; display: block; aspect-ratio: 3 / 4; border-radius: 999px 999px 20px 20px; overflow: hidden; background: var(--tone-arch); isolation: isolate; }
.dcard-arch::after, .designer-hero-arch::after { content: ""; position: absolute; inset: 8px; border: 1.5px solid rgba(255, 255, 255, .75); border-radius: 999px 999px 14px 14px; pointer-events: none; z-index: 2; }
.dcard-arch img, .designer-hero-arch img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; filter: saturate(.82) contrast(1.02); transition: filter .3s ease, transform .4s ease; }
.dcard:hover .dcard-arch img, .dcard:focus-visible .dcard-arch img { filter: none; transform: scale(1.04); }
.dcard-mono { position: absolute; inset: 0; display: grid; place-items: center; font-family: "FB Logo", var(--font); font-weight: 900; font-size: clamp(64px, 9vw, 104px); line-height: 1; color: var(--tone-ink); opacity: .9;
  background: radial-gradient(circle at 50% 38%, rgba(255, 255, 255, .55) 0 34%, transparent 35%); }
.dcard-count { position: absolute; inset-block-end: 16px; inset-inline: 0; margin-inline: auto; width: max-content; z-index: 3; white-space: nowrap; background: rgba(255, 255, 255, .94); color: var(--ink); border-radius: 999px; padding: 4px 12px; font-size: 12.5px; font-weight: 800; box-shadow: 0 2px 8px rgba(11, 46, 51, .12); }

.dcard-body { display: flex; flex-direction: column; align-items: center; gap: 3px; margin-top: 14px; text-align: center; }
.dcard-name { font-size: 19px; font-weight: 800; line-height: 1.4; }
.dcard-alt { font-size: 12.5px; color: var(--muted); }
.dcard-fonts { display: flex; justify-content: center; margin-top: 10px; padding-inline-start: 8px; }
.fchip { width: 38px; height: 38px; margin-inline-start: -8px; border-radius: 30%; display: inline-grid; place-items: center; border: 2.5px solid var(--tone-bg); font-size: 19px; line-height: 1; color: #fff; background: var(--brand); overflow: hidden; }
.fchip.is-ready { padding-bottom: .08em; }
.fchip-more, .fchip-more:nth-child(n) { background: #fff; color: var(--ink); font-size: 12px; font-weight: 800; }

/* زبان‌های دیگر: فهرست ساده الفبایی در چند ستون */
.letter-list { columns: 4 220px; column-gap: 32px; margin-bottom: 40px; }
.letter-group { break-inside: avoid; margin-bottom: 22px; }
.letter-head { margin: 0 0 6px; padding-bottom: 6px; border-bottom: 2px solid var(--line); font-size: 22px; font-weight: 900; color: var(--brand); }
.letter-group ul { list-style: none; margin: 0; padding: 0; }
.letter-group li { display: flex; justify-content: space-between; align-items: baseline; gap: 10px; padding: 6px 0; border-bottom: 1px dashed var(--divider); }
.letter-group a { color: var(--ink); font-weight: 600; }
.letter-group a:hover { color: var(--brand); }
.letter-group small { color: var(--muted); white-space: nowrap; font-size: 12.5px; }

/* سربرگ پروفایل طراح */
.designer-hero { display: grid; grid-template-columns: minmax(200px, 280px) 1fr; gap: 44px; align-items: center; background: var(--surface); border-radius: 32px; padding: 32px; margin-bottom: 36px; box-shadow: var(--card-shadow); position: relative; overflow: hidden; }
.designer-hero::before { content: ""; position: absolute; inset-inline: 0; inset-block-start: 0; height: 6px; background: var(--stripe); }
.designer-hero-arch { width: 100%; box-shadow: 0 18px 40px rgba(11, 46, 51, .14); }
.designer-hero-arch img { filter: none; }
.designer-hero-text .page-title { margin: 0; font-size: clamp(28px, 4vw, 40px); }
.designer-hero-alt { margin: 4px 0 0; color: var(--muted); font-size: 15px; }
.designer-stats { list-style: none; display: flex; flex-wrap: wrap; gap: 8px; margin: 16px 0 0; padding: 0; }
.designer-stats li { background: var(--field); border-radius: 999px; padding: 6px 14px; font-size: 13.5px; font-weight: 700; }
.designer-stats li:first-child { background: var(--deep); color: #fff; }
.designer-hero .landing-intro { margin-top: 18px; max-width: 64ch; }
.social-links { list-style: none; display: flex; flex-wrap: wrap; gap: 10px; margin: 22px 0 0; padding: 0; }
.social { width: 44px; height: 44px; border-radius: 50%; display: grid; place-items: center; background: var(--field); color: var(--ink); transition: background .15s ease, color .15s ease, transform .15s ease; }
.social:hover, .social:focus-visible { background: var(--deep); color: #fff; transform: translateY(-2px); }
.social svg { width: 21px; height: 21px; }
.designer-fonts-title { margin: 0 0 16px; font-size: 22px; font-weight: 800; }

/* فرم پروفایل عمومی در پنل طراح */
.profile-photo-row { display: flex; gap: 20px; align-items: flex-start; flex-wrap: wrap; }
.profile-photo-row .dcard-arch { width: 120px; flex: none; }
.profile-photo-row .dcard-mono { font-size: 54px; }
.profile-photo-row > div { flex: 1 1 260px; display: flex; flex-direction: column; align-items: flex-start; gap: 8px; }
.profile-photo-row > div p { margin: 0; }
.links-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 4px 18px; }
.links-grid label { display: inline-flex; align-items: center; gap: 6px; }
.links-grid label svg { width: 17px; height: 17px; color: var(--muted); }
.links-grid input { direction: ltr; text-align: left; }

@media (max-width: 960px) {
  .dcard-grid-home { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 700px) {
  .designer-hero { grid-template-columns: 1fr; gap: 22px; padding: 26px 20px; text-align: center; }
  .designer-hero-arch { max-width: 210px; margin-inline: auto; }
  .designer-stats, .social-links { justify-content: center; }
  .designer-hero .landing-intro { margin-inline: auto; text-align: start; }
  .links-grid { grid-template-columns: 1fr; }
}
@media (max-width: 600px) {
  .dcard-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px 12px; }
  .dcard { padding: 10px 10px 14px; border-radius: 22px; }
  .dcard-name { font-size: 16px; }
  .fchip { width: 30px; height: 30px; font-size: 15px; margin-inline-start: -7px; }
  .dcard-count { font-size: 11px; padding: 3px 9px; inset-block-end: 12px; }
}

/* ۱۸ آیکون فونت (چت ۳۳؛ fontbank/_font-icon): مربع رنگی با حرف خوش‌نقش به خط خود فونت.
   جفت رنگ‌ها عمداً جدا از رنگ‌های قالب سایت‌اند؛ شماره از Fonts/FontIconRules::palette (PALETTE_COUNT = 12). */
.pal-0 { background: #F0846E; color: #FFF4E8; }
.pal-1 { background: #2B2725; color: #F26A3D; }
.pal-2 { background: #1F3A5F; color: #F5C451; }
.pal-3 { background: #1E5B47; color: #BDEBD4; }
.pal-4 { background: #5B2A4E; color: #F7B6CF; }
.pal-5 { background: #E9B949; color: #4A2C17; }
.pal-6 { background: #CDE6F7; color: #23307A; }
.pal-7 { background: #B9573A; color: #F6E3C6; }
.pal-8 { background: #DCD3F7; color: #4B2E9A; }
.pal-9 { background: #6B7F2A; color: #F4F1DC; }
.pal-10 { background: #F7EFE1; color: #7A1F2B; }
.pal-11 { background: #3A4552; color: #C9F27A; }

.ficon { display: inline-grid; place-items: center; flex: none; overflow: hidden; line-height: 1; font-weight: 400; user-select: none; }
.ficon-card { width: 44px; height: 44px; border-radius: 12px; font-size: 27px; }
.ficon-page { width: 96px; height: 96px; border-radius: 24px; font-size: 60px; }

/* کارت: آیکون کنار نام (نمای شبکه‌ای)؛ در نمای فهرستی بزرگ‌تر، مثل ردیف فروشگاه */
.card-body { flex-direction: row; align-items: flex-start; gap: 12px; }
.card-info { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 2px; }
.view-list .card-body { align-items: center; flex-basis: 330px; }
.view-list .ficon-card { width: 76px; height: 76px; border-radius: 18px; font-size: 46px; }

.font-head-main { display: flex; align-items: flex-start; gap: 20px; min-width: 0; }
@media (max-width: 600px) {
  .ficon-page { width: 68px; height: 68px; border-radius: 18px; font-size: 42px; }
  .font-head-main { gap: 14px; }
  .view-list .ficon-card { width: 56px; height: 56px; border-radius: 14px; font-size: 34px; }
}

/* ۱۹ لوگو (public/fontbank/brand) */
.brand-logo { display: block; height: 52px; width: auto; }
.site-footer .brand-logo { height: 60px; }
@media (max-width: 640px) {
  .brand-logo { height: 38px; }
  .site-footer .brand-logo { height: 48px; }
}

/* ۲۰ پیشنهاد هنگام تایپ (چت ۳۴؛ fontbank/search/_suggestions): پنل سفید زیر کادر جست‌وجو، حتی در سربرگ تیره.
   anchor = .header-search / .hero-search، یا .suggest-wrap که catalog.js دور ورودی فیلترها می‌کشد. */
.suggest-anchor { position: relative; }
.suggest-wrap { display: block; flex: 1 1 220px; }
.suggest-wrap input { width: 100%; }
.suggest-panel {
  position: absolute; top: calc(100% + 8px); inset-inline: 0; min-width: min(340px, 92vw); max-height: min(70vh, 520px); overflow-y: auto;
  background: var(--surface); color: var(--ink); border-radius: 18px; padding: 8px; z-index: 80;
  box-shadow: 0 2px 6px rgba(11, 46, 51, .10), 0 18px 48px rgba(11, 46, 51, .18); text-align: start;
}
.header-search .suggest-panel { inset-inline-start: auto; inset-inline-end: 0; width: max(100%, 360px); }
.suggest-head { margin: 8px 10px 4px; font-size: 12px; font-weight: 800; color: var(--muted); }
.suggest-note, .suggest-empty { margin: 6px 10px 8px; font-size: 13px; color: var(--muted); line-height: 1.7; }
.suggest-note { background: var(--sample-bg); border-radius: 10px; padding: 8px 10px; margin-inline: 4px; }
.suggest-item { display: flex; align-items: center; gap: 12px; padding: 8px 10px; border-radius: 12px; color: var(--ink); text-decoration: none; }
.suggest-item:hover, .suggest-item.is-active { background: var(--field); }
.suggest-item .ficon-chip { width: 40px; height: 40px; border-radius: 11px; font-size: 25px; flex: none; }
.suggest-text { display: flex; flex-direction: column; min-width: 0; line-height: 1.5; }
.suggest-title { font-weight: 700; font-size: 15px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.suggest-sub { font-size: 12.5px; color: var(--muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.suggest-all { margin-top: 4px; border-top: 1px solid var(--divider); border-radius: 0 0 12px 12px; font-weight: 700; font-size: 14px; color: var(--deep); justify-content: center; padding-block: 11px; }
.savatar {
  width: 40px; height: 40px; border-radius: 50%; overflow: hidden; flex: none; display: grid; place-items: center;
  background: var(--tone-bg, var(--field)); color: var(--tone-ink, var(--ink)); font-weight: 800; font-size: 17px;
}
.savatar img { width: 100%; height: 100%; object-fit: cover; object-position: 50% 20%; }

/* کادر «طراحان» بالای نتیجه جست‌وجو */
.search-corrected { background: var(--surface); border-radius: 14px; padding: 10px 16px; margin: 0 0 14px; color: var(--muted); box-shadow: var(--card-shadow); }
.search-designers { margin: 0 0 18px; }
.search-designers-title { font-size: 15px; margin: 0 0 10px; color: var(--muted); }
.search-designers-list { display: flex; flex-wrap: wrap; gap: 10px; }
.search-designer {
  display: flex; align-items: center; gap: 12px; background: var(--surface); border-radius: 18px; padding: 10px 14px; min-width: 260px;
  color: var(--ink); text-decoration: none; box-shadow: var(--card-shadow);
}
.search-designer .savatar { width: 48px; height: 48px; font-size: 20px; }
.search-designer-go { margin-inline-start: auto; font-size: 13px; font-weight: 700; color: var(--deep); padding-inline-start: 12px; }
.search-designer:hover { box-shadow: 0 2px 6px rgba(11, 46, 51, .10), 0 12px 30px rgba(11, 46, 51, .14); }
@media (max-width: 600px) {
  .search-designer { min-width: 0; width: 100%; }
  .header-search .suggest-panel { position: fixed; top: 64px; inset-inline: 10px; width: auto; }
}

/* ۲۱ حروف شناور پس‌زمینه پانویس (catalog.js: .js-footer-glyphs). فقط transform، و فقط وقتی پانویس دیده می‌شود. */
.site-footer { position: relative; overflow: hidden; isolation: isolate; }
.site-footer > .container { position: relative; z-index: 1; }
.footer-glyphs { position: absolute; inset: 5px 0 0; z-index: 0; pointer-events: none; user-select: none; }
.footer-glyph {
  position: absolute; line-height: 1; color: #fff; opacity: var(--o, .06); white-space: nowrap;
  transform: translate(-50%, -50%) rotate(var(--r, 0deg));
  animation: fb-glyph-float var(--t, 16s) ease-in-out var(--d, 0s) infinite alternate;
  animation-play-state: paused;
}
.footer-glyph.tint-saffron { color: var(--saffron); }
.footer-glyph.tint-teal { color: var(--teal); }
.site-footer.glyphs-live .footer-glyph { animation-play-state: running; }
/* حرکت ترکیبی: جابه‌جایی + چرخش + بزرگ و کوچک شدن + کم و زیاد شدن رنگ، در سه مرحله تا یکنواخت نباشد */
@keyframes fb-glyph-float {
  0%   { opacity: var(--o, .06); transform: translate(-50%, -50%) rotate(var(--r, 0deg)) scale(var(--s0, 1)); }
  50%  { opacity: calc(var(--o, .06) * 1.5); transform: translate(calc(-50% + var(--dx, 0px)), calc(-50% + var(--dy, 0px))) rotate(calc(var(--r, 0deg) + var(--rr, 0deg))) scale(var(--s, 1)); }
  100% { opacity: calc(var(--o, .06) * .7); transform: translate(calc(-50% - var(--dx, 0px) * .6), calc(-50% + var(--dy2, 0px))) rotate(calc(var(--r, 0deg) - var(--rr, 0deg) * .6)) scale(var(--s2, 1)); }
}
@media (prefers-reduced-motion: reduce) {
  .footer-glyph { animation: none; }
}

/* ۲۲ فرم صورتحساب حقیقی/حقوقی (sales/checkout، catalog.js .js-billing) */
.billing-label-person, .billing-label-company { display: none; }
.billing-live .billing-label-both { display: none; }
.billing-live[data-kind="person"] .billing-label-person, .billing-live[data-kind="company"] .billing-label-company { display: inline; }
.billing-live[data-kind="person"] [data-only="company"] { display: none; }

/* ۲۳ منوی حساب و پنل طراح (account/_nav) + اعلان‌های طراح (account/notices) */
.account-nav { display: flex; align-items: center; justify-content: space-between; gap: 12px; flex-wrap: wrap;
  background: var(--surface); border-radius: var(--radius); box-shadow: var(--card-shadow); padding: 8px; margin: 4px 0 18px; }
.account-tabs { display: flex; flex-wrap: wrap; gap: 4px; list-style: none; margin: 0; padding: 0; }
.account-tabs a { display: block; padding: 9px 16px; border-radius: 999px; color: var(--muted); font-weight: 600; font-size: .95rem; text-decoration: none; white-space: nowrap; }
.account-tabs a:hover { background: var(--sample-bg); color: var(--ink); }
.account-tabs a.is-active { background: var(--mint); color: var(--mint-ink-2); }
.designer-cta { display: inline-flex; align-items: center; gap: 8px; padding: 10px 18px; border-radius: 999px; text-decoration: none; font-weight: 700;
  background: var(--deep); color: #fff; box-shadow: inset 0 -3px 0 var(--saffron); white-space: nowrap; }
.designer-cta:hover, .designer-cta.is-active { background: var(--ink); color: #fff; }
.designer-cta-icon { color: var(--saffron); flex: none; }
.nav-badge { display: inline-grid; place-items: center; min-width: 20px; height: 20px; padding: 0 6px; border-radius: 999px; background: var(--brand); color: #fff; font-size: .75rem; font-weight: 700; line-height: 1; }
.designer-nav { display: flex; flex-wrap: wrap; gap: 6px; margin: -6px 0 20px; padding: 0 4px 10px; border-bottom: 2px solid var(--divider); }
.designer-nav a { display: inline-flex; align-items: center; gap: 6px; padding: 7px 14px; border-radius: var(--radius-sm); color: var(--muted); text-decoration: none; font-size: .92rem; font-weight: 600; }
.designer-nav a:hover { background: var(--surface); color: var(--ink); }
.designer-nav a.is-active { background: var(--cream); color: var(--cream-ink-2); }
@media (max-width: 700px) {
  .account-nav { flex-direction: column; align-items: stretch; min-width: 0; max-width: 100%; }
  .account-tabs { flex-wrap: nowrap; overflow-x: auto; scrollbar-width: none; min-width: 0; max-width: 100%; }
  .designer-cta { justify-content: center; }
  .designer-nav { flex-wrap: nowrap; overflow-x: auto; scrollbar-width: none; }
  .designer-nav a { white-space: nowrap; }
}
.notice-list { list-style: none; margin: 0; padding: 0; }
.notice-item { display: flex; align-items: flex-start; gap: 12px; padding: 14px 4px; border-bottom: 1px solid var(--divider); }
.notice-item:last-child { border-bottom: 0; }
.notice-item p { margin: 0 0 4px; }
.notice-body { flex: 1; min-width: 0; }
.notice-dot { width: 10px; height: 10px; border-radius: 50%; background: var(--line-2); margin-top: 8px; flex: none; }
.notice-item.is-unread .notice-dot { background: var(--brand); }
.notice-item.is-unread p { font-weight: 600; }
.notice-font_sold .notice-dot, .notice-payout_paid .notice-dot { background: var(--teal); }

/* ۲۴ مجموعه‌های دستچین در منوی «همه فونت‌ها»: نوار جدا با ستاره، متفاوت با کاشی‌های دسته‌ها */
.mega-collections { grid-column: 1 / -1; border-top: 1px dashed var(--line-2); padding-top: 18px; display: flex; flex-wrap: wrap; align-items: center; gap: 10px 18px; }
.mega-collections h2 { display: flex; align-items: center; gap: 8px; margin: 0; font-size: 13px; font-weight: 800; color: var(--cream-ink-2); }
.mega-collections h2 svg { color: var(--saffron); }
.mega-collections h2 small { font-weight: 500; color: var(--muted); }
.mega-picks { display: flex; flex-wrap: wrap; gap: 8px; flex: 1; }
.header-nav .mega .mega-pick { display: inline-flex; align-items: center; gap: 8px; padding: 8px 14px; border-radius: 999px; border: 1px solid transparent; font-size: 14px; font-weight: 700; }
.mega-pick small { font-weight: 500; color: var(--muted); font-size: 12px; }
.mega-pick-star { color: var(--saffron); font-size: 14px; }
.header-nav .mega .pick-rose { background: var(--rose); } .header-nav .mega .pick-cream { background: var(--cream); } .header-nav .mega .pick-mint { background: var(--mint); }
.header-nav .mega .mega-pick:hover { border-color: var(--ink); color: var(--ink); }
.header-nav .mega .mega-collections .more-link { margin-top: 0; }
@media (max-width: 1180px) { .mega-collections { grid-column: 1 / -1; } }
@media (max-width: 960px) { .mega-collections { flex-direction: column; align-items: flex-start; } }

/* ۲۵ صفحه اصلی در عرض‌های میانه: بی کاشی یتیم در «بر اساس سبک» و کارت طراح بی‌اندازه بزرگ نشود */
@media (min-width: 1101px) {
  .style-grid { grid-template-columns: repeat(var(--tiles, 5), minmax(0, 1fr)); }
}
@media (min-width: 601px) and (max-width: 1100px) {
  /* ۵ کاشی → ۳ + ۲ وسط‌چین؛ ۴ کاشی → ۲ + ۲ */
  .style-grid { display: flex; flex-wrap: wrap; justify-content: center; }
  .style-grid > .style-tile { flex: 0 1 calc((100% - 32px) / 3); }
  .style-grid.tiles-4 > .style-tile, .style-grid.tiles-2 > .style-tile { flex-basis: calc((100% - 16px) / 2); }
}
@media (max-width: 960px) {
  /* طراحان صفحه اصلی: ردیف افقی با اسکرول به‌جای دو ستون غول‌پیکر */
  .dcard-grid-home { display: flex; overflow-x: auto; gap: 16px; scroll-snap-type: x mandatory; padding: 4px 2px 12px; scrollbar-width: thin; }
  .dcard-grid-home > .dcard { flex: 0 0 210px; scroll-snap-align: start; }
}
@media (max-width: 600px) {
  .dcard-grid-home > .dcard { flex-basis: 160px; }
}

/* ۲۶ قیمت «از …» روی کارت فونت فروشی */
.card-price { display: inline-flex; align-items: baseline; gap: 6px; font-size: 13px; font-weight: 800; color: var(--brand-dark); }
.card-price-old { font-weight: 500; color: var(--muted); font-size: 12px; }

/* ۲۷ سربرگ صفحه فونت (طرح مرجع، بی زمینه زرد زیر نام): کارت با نوار تیره بالا + جعبه دانلود کنار آن */
.font-hero { display: grid; grid-template-columns: minmax(0, 1fr) 290px; gap: 22px; align-items: start; margin-bottom: 22px; }
.font-hero-card { position: relative; background: var(--surface); border-radius: var(--radius-lg); box-shadow: var(--card-shadow); padding: 30px 30px 26px; border-top: 8px solid var(--deep); }
.font-hero-top { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 18px 24px; }
.font-hero-id { display: flex; align-items: center; gap: 20px; min-width: 0; }
.font-hero-titles { min-width: 0; }
.font-hero-name { margin: 0; font-size: clamp(34px, 4.6vw, 58px); line-height: 1.25; font-weight: 400; color: var(--ink); overflow-wrap: anywhere; opacity: .55; transition: opacity .25s; }
.font-hero-name.is-ready { opacity: 1; }
.font-hero-sub { margin: 6px 0 0; color: var(--muted); font-size: 15px; }
.font-hero-designers { display: flex; flex-wrap: wrap; gap: 8px; }
.designer-pill { display: inline-flex; align-items: center; gap: 10px; padding: 6px 8px 6px 16px; border-radius: 999px; background: var(--bg); color: var(--ink); text-decoration: none; }
[dir="ltr"] .designer-pill { padding: 6px 16px 6px 8px; }
.designer-pill:hover { background: var(--mint); color: var(--ink); }
.designer-pill .savatar { width: 54px; height: 54px; font-size: 22px; }
.designer-pill-text { display: flex; flex-direction: column; line-height: 1.4; }
.designer-pill-text small { color: var(--muted); font-size: 12px; }
.designer-pill-text strong { font-size: 15px; }
.font-hero-body { margin-top: 22px; padding-top: 20px; border-top: 1px solid var(--divider); }
.font-hero-body .lead { margin: 0 0 14px; max-width: none; }
.font-hero-tags { display: flex; flex-wrap: wrap; gap: 8px; list-style: none; margin: 0; padding: 0; }
.font-hero-tags a { display: inline-flex; gap: 3px; padding: 6px 14px; border-radius: 999px; background: var(--mint); color: var(--mint-ink-2); font-size: 13px; font-weight: 700; text-decoration: none; }
.font-hero-tags a span { opacity: .55; }
.font-hero-tags a:hover { background: var(--deep); color: #fff; }
.font-hero-side { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius-lg); padding: 18px 20px 20px; display: flex; flex-direction: column; gap: 10px; }
.font-hero-cta { width: 100%; min-height: 52px; font-size: 16px; font-weight: 800; }
.font-hero-note { display: block; color: var(--muted); font-size: 13px; text-align: center; line-height: 1.8; }
.font-hero-facts { display: grid; grid-template-columns: auto 1fr; gap: 10px 12px; margin: 6px 0 4px; padding-top: 14px; border-top: 1px solid var(--divider); font-size: 14px; }
.font-hero-facts dt { color: var(--muted); }
.font-hero-facts dd { margin: 0; text-align: end; font-weight: 800; }
.font-hero-side .like-form, .font-hero-side .like-button { width: 100%; justify-content: center; }
@media (max-width: 900px) {
  .font-hero { grid-template-columns: 1fr; }
  .font-hero-card { padding: 22px 18px 20px; }
  .font-hero-id { gap: 14px; }
}

/* ۲۸ خرید با مدل لایسنس ساده: کارت‌های شخصی / تجاری / تجاری گسترده (fontbank/_buy) */
.buy-options { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 16px; margin: 16px 0; }
.buy-option { position: relative; display: flex; flex-direction: column; gap: 8px; padding: 22px 20px 18px; border-radius: var(--radius); background: var(--sample-bg); border: 2px solid transparent; }
.buy-option.is-featured { background: #fff; border-color: var(--brand); box-shadow: var(--card-shadow); }
.buy-option h3 { margin: 0; font-size: 20px; }
.buy-option p { margin: 0; font-size: 14px; line-height: 1.8; }
.buy-option-flag { position: absolute; top: -12px; inset-inline-start: 18px; background: var(--brand); color: #fff; font-size: 12px; font-weight: 800; padding: 3px 12px; border-radius: 999px; }
.buy-option-list { margin: 4px 0; padding-inline-start: 18px; font-size: 14px; line-height: 1.9; }
.buy-option-price { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 8px; padding-top: 10px; border-top: 1px solid var(--divider); margin-top: auto; }
.buy-option-price small { width: 100%; color: var(--muted); }
.buy-option-price .price { font-size: 18px; }
.buy-option-license { font-size: 13px; }

/* ۲۹ نمادهای اعتماد (اینماد، ساماندهی) در پایین پانویس */
.footer-bottom { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 12px; }
.trust-badges { display: inline-flex; gap: 10px; }
.trust-badges a { display: inline-grid; place-items: center; width: 84px; height: 84px; background: #fff; border-radius: 14px; padding: 2px; }
.trust-badges img { width: 80px; height: 80px; object-fit: contain; }

/* ۳۰ تست‌کننده صفحه اصلی به شکل پنجره ویرایشگر (home/blocks/hero، catalog.js) */
.tester-card.editor { display: flex; flex-direction: column; background: #EEF3F2; }
.editor-titlebar { display: flex; align-items: center; gap: 12px; padding: 10px 16px; background: linear-gradient(#F7FAF9, #E9F0EE); border-bottom: 1px solid var(--line); }
.editor-dots { display: inline-flex; gap: 7px; direction: ltr; }
.editor-dots i { width: 12px; height: 12px; border-radius: 50%; background: #FF5F57; box-shadow: inset 0 0 0 1px rgba(0, 0, 0, .12); }
.editor-dots i:nth-child(2) { background: #FEBC2E; } .editor-dots i:nth-child(3) { background: #28C840; }
.editor-doc { flex: 1; text-align: center; font-size: 13px; color: var(--muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; padding-inline-end: 50px; }
.editor-toolbar { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; padding: 8px 12px; background: #fff; border-bottom: 1px solid var(--line); }
.editor-picker { position: relative; }
.editor-picker-button { display: inline-flex; align-items: center; justify-content: space-between; gap: 10px; min-width: 150px; min-height: 36px; padding: 0 12px; border: 1px solid var(--line-2); border-radius: 10px; background: var(--sample-bg); color: var(--ink); font-weight: 700; font-size: 14px; }
.editor-picker-button:hover { border-color: var(--ink); }
.editor-picker-panel { position: absolute; z-index: 20; top: calc(100% + 6px); inset-inline-start: 0; width: 260px; background: #fff; border: 1px solid var(--line); border-radius: 14px; box-shadow: var(--shadow); padding: 8px; }
.editor-picker-panel input { width: 100%; min-height: 38px; margin-bottom: 6px; }
.editor-picker-panel ul { list-style: none; margin: 0; padding: 0; max-height: 260px; overflow-y: auto; }
.editor-picker-panel li { padding: 8px 10px; border-radius: 8px; cursor: pointer; font-size: 18px; line-height: 1.5; }
.editor-picker-panel li:hover, .editor-picker-panel li:focus { background: var(--mint); outline: none; }
.editor-picker-panel li[aria-selected="true"] { background: var(--ink); color: #fff; }
.editor-size { display: inline-flex; align-items: center; gap: 6px; color: var(--muted); padding: 0 6px; }
.editor-size input { width: 110px; accent-color: var(--brand); }
.editor-group { display: inline-flex; gap: 2px; padding: 2px; border-radius: 10px; background: var(--sample-bg); }
.editor-tool { display: inline-flex; align-items: center; gap: 6px; min-height: 32px; min-width: 32px; padding: 0 8px; border: 0; border-radius: 8px; background: transparent; color: var(--muted); }
.editor-tool:hover { background: #fff; color: var(--ink); }
.editor-tool[aria-pressed="true"] { background: #fff; color: var(--ink); box-shadow: 0 1px 2px rgba(11, 46, 51, .15); }
.editor-swatch { width: 24px; height: 24px; margin: 4px; border-radius: 50%; border: 2px solid transparent; padding: 0; box-shadow: 0 0 0 1px var(--line-2); }
.editor-swatch[aria-pressed="true"] { border-color: var(--brand); }
.swatch-white { background: #fff; } .swatch-cream { background: #FFF6E2; } .swatch-dark { background: #102A2E; }
.editor-dice { margin-inline-start: auto; background: var(--brand-soft); color: var(--brand-dark); font-weight: 700; font-size: 13px; }
.editor-dice:hover { background: var(--brand); color: #fff; }
.editor-desk { padding: 22px 22px 6px; background: #E4ECEA; background-image: radial-gradient(rgba(11, 46, 51, .06) 1px, transparent 1px); background-size: 14px 14px; }
.editor-paper { position: relative; background: #fff; border-radius: 6px 6px 0 0; box-shadow: 0 -1px 0 rgba(11, 46, 51, .04), 0 10px 30px rgba(11, 46, 51, .12); padding: 34px 38px; min-height: 210px; display: flex; align-items: center; transition: background-color .25s, color .25s; }
.editor-desk[data-paper="cream"] .editor-paper { background: #FFF6E2; color: #4A3200; }
.editor-desk[data-paper="dark"] .editor-paper { background: #102A2E; color: #E8F5F3; }
.editor-text { margin: 0; width: 100%; font-size: clamp(34px, 4.4vw, 54px); line-height: 1.6; overflow-wrap: anywhere; outline: none; caret-color: var(--brand); opacity: .6; transition: opacity .3s; }
.editor-text.is-ready { opacity: 1; }
.editor-text:focus { opacity: 1; }
.editor-caret { position: absolute; inset-block: 30%; inset-inline-end: 24px; width: 2px; background: var(--brand); animation: editor-blink 1.1s steps(1) infinite; }
.editor-paper:focus-within .editor-caret { display: none; }
@keyframes editor-blink { 50% { opacity: 0; } }
.editor-statusbar { display: flex; align-items: center; gap: 10px; padding: 12px 16px 14px; background: #fff; border-top: 1px solid var(--line); }
.editor-statusbar .tester-card-fonts { flex: 1; min-width: 0; padding: 0; border: 0; }
.editor-statusbar #home-tester-link { flex: none; }
@media (prefers-reduced-motion: reduce) { .editor-caret { animation: none; } }
@media (max-width: 700px) {
  .editor-doc { padding-inline-end: 0; }
  .editor-toolbar { gap: 6px; padding: 8px; }
  .editor-picker-button { min-width: 120px; }
  .editor-size input { width: 80px; }
  .editor-align-group { display: none; }
  .editor-desk { padding: 12px 10px 4px; }
  .editor-paper { padding: 22px 18px; min-height: 150px; }
  .editor-text { font-size: 38px; }
  .editor-statusbar { flex-wrap: wrap; }
  .editor-statusbar .tester-card-fonts { flex-wrap: nowrap; overflow-x: auto; }
}
.editor-swatch { min-height: 0; min-width: 0; width: 22px; height: 22px; flex: none; }
.editor-tool { min-height: 32px; }

/* ۳۱ ردیف اسلایدی «فونت‌های مشابه»، گالری با نمایش اسلایدی (lightbox) و تصویر داخل متن صفحه فونت — از برنچ fix/font-page-byline */

.rail { margin-bottom: 28px; }
.rail-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; flex-wrap: wrap; margin-bottom: 12px; }
.rail-head h2 { margin: 0; }
.rail-tools { display: flex; align-items: center; gap: 8px; }
.rail-more { font-size: 14px; font-weight: 700; color: var(--deep); margin-inline-end: 6px; }
.rail-btn {
  width: 40px; height: 40px; border-radius: 50%; border: 0; display: inline-grid; place-items: center; cursor: pointer;
  background: var(--surface); color: var(--ink); box-shadow: var(--card-shadow); transition: background .15s ease, opacity .15s ease;
}
.rail-btn:hover:not(:disabled) { background: var(--deep); color: #fff; }
.rail-btn:disabled { opacity: .35; cursor: default; }
html[dir="ltr"] .rail-btn svg { transform: scaleX(-1); }
.rail-track {
  --rail-gap: var(--gap, 20px);
  display: grid; grid-auto-flow: column; grid-auto-columns: calc((100% - 3 * var(--rail-gap)) / 4); gap: var(--rail-gap);
  overflow-x: auto; scroll-snap-type: x mandatory; scroll-behavior: smooth; overscroll-behavior-x: contain;
  padding: 6px 4px 14px; margin: -6px -4px 0; scrollbar-width: thin;
}
.rail-track > * { scroll-snap-align: start; min-width: 0; }
.rail-track:focus-visible { outline: 2px solid var(--saffron); outline-offset: 4px; border-radius: 12px; }
@media (max-width: 960px) { .rail-track { grid-auto-columns: calc((100% - var(--rail-gap)) / 2); } }
@media (max-width: 600px) { .rail-track { grid-auto-columns: 80%; } }

/* ۲۳ نمایش بزرگ گالری تصاویر صفحه فونت (catalog.js، <dialog class="lightbox">) */
.gallery .js-lightbox-item { display: block; cursor: zoom-in; border-radius: 10px; }
.gallery .js-lightbox-item:focus-visible { outline: 2px solid var(--saffron); outline-offset: 3px; }
html.has-lightbox { overflow: hidden; }
.lightbox {
  width: 100vw; height: 100dvh; max-width: none; max-height: none; margin: 0; padding: 0; border: 0;
  background: transparent; color: #fff; display: grid; grid-template-columns: 72px 1fr 72px; align-items: center;
}
.lightbox:not([open]) { display: none; }
.lightbox::backdrop { background: rgba(6, 26, 29, .96); }
.lightbox-figure { grid-column: 2; grid-row: 1; }
.lightbox button:focus-visible { outline: 2px solid var(--saffron); outline-offset: 2px; }
.lightbox button:focus:not(:focus-visible) { outline: none; }
.lightbox-figure { margin: 0; height: 100dvh; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 14px; padding: 56px 0 24px; min-width: 0; }
.lightbox-figure img { max-width: 100%; max-height: calc(100dvh - 140px); width: auto; height: auto; border-radius: 12px; box-shadow: 0 20px 60px rgba(0, 0, 0, .45); background: #fff; }
.lightbox-figure figcaption { display: flex; gap: 14px; align-items: center; font-size: 14px; color: var(--on-deep-nav); text-align: center; }
.lightbox-count { padding: 2px 10px; border-radius: 999px; background: rgba(255, 255, 255, .12); white-space: nowrap; }
.lightbox-nav, .lightbox-close {
  border: 0; cursor: pointer; display: inline-grid; place-items: center; border-radius: 50%;
  background: rgba(255, 255, 255, .12); color: #fff; transition: background .15s ease;
}
.lightbox-nav { width: 52px; height: 52px; justify-self: center; }
.lightbox-nav:hover, .lightbox-close:hover { background: var(--saffron); color: var(--deep); }
.lightbox-close { position: absolute; top: 14px; inset-inline-end: 14px; width: 44px; height: 44px; }
html[dir="ltr"] .lightbox-nav svg { transform: scaleX(-1); }
@media (max-width: 600px) {
  .lightbox { grid-template-columns: 0 1fr 0; }
  .lightbox-nav { position: absolute; bottom: 18px; width: 46px; height: 46px; }
  .lightbox-prev { inset-inline-start: 18px; }
  .lightbox-next { inset-inline-end: 18px; }
  .lightbox-figure { padding: 60px 10px 84px; }
  .lightbox-figure img { max-height: calc(100dvh - 190px); }
}

/* ۲۴ تصویر داخل متن معرفی فونت (fontbank/_inline-image) */
.about-figure { margin: 22px auto; max-width: 760px; }
.about-figure a { display: block; border-radius: 16px; overflow: hidden; cursor: zoom-in; box-shadow: var(--card-shadow); }
.about-figure img { display: block; width: 100%; height: auto; }
.about-figure figcaption { margin-top: 8px; font-size: 13px; color: var(--muted); text-align: center; }
.panel > .about-figure:only-child { margin: 0; }


/* ۳۲ اندازه ثابت پنجره تست‌کننده: با عوض شدن خودکار فونت قد و پهنای هیچ بخشی تغییر نکند */

.editor-picker-button { width: 180px; min-width: 0; }
.editor-picker-button .js-editor-font { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; text-align: start; }
.editor-paper { height: 230px; min-height: 0; overflow: hidden; }
.editor-text { max-height: 100%; overflow: hidden; line-height: 1.5; display: -webkit-box; -webkit-box-orient: vertical; -webkit-line-clamp: 2; }
.editor-text:focus { display: block; overflow-y: auto; }
.editor-statusbar .tester-card-fonts { flex-wrap: nowrap; overflow-x: auto; scrollbar-width: none; }
.editor-statusbar .tester-card-fonts .chip { flex: none; }
@media (max-width: 700px) {
  .editor-picker-button { width: 140px; }
  .editor-paper { height: 160px; }
}

/* ۳۳ بخش خرید (_buy): ۱. بسته‌ها زیر هم با نوار وزن‌ها ۲. نردبان لایسنس‌ها (پله‌های پایین «در لایسنس انتخابی هست») + باکس خرید کناری.
   catalog.js .js-buy قیمت‌ها، تیک‌ها و حساب جمع را عوض می‌کند. */
.buy-config { display: grid; grid-template-columns: minmax(0, 1fr) 360px; gap: 28px; align-items: start; margin-top: 8px; }
.buy-steps { display: flex; flex-direction: column; gap: 22px; min-width: 0; }
.buy-step { border: 0; padding: 0; margin: 0; min-width: 0; }
.buy-step legend { display: flex; align-items: center; gap: 10px; font-weight: 800; font-size: 17px; margin-bottom: 10px; padding: 0; }
.buy-step-no { display: inline-grid; place-items: center; width: 28px; height: 28px; border-radius: 50%; background: var(--brand); color: #fff; font-size: 14px; }
.buy-hint { margin: -4px 0 10px; font-size: 13px; }
.buy-pkgs, .buy-ladder { display: flex; flex-direction: column; gap: 8px; }
.buy-pkg, .buy-rung { position: relative; display: grid; grid-template-columns: 22px minmax(0, 1fr) auto; gap: 12px; align-items: center; padding: 12px 16px; border-radius: var(--radius-sm); background: var(--sample-bg); border: 2px solid transparent; cursor: pointer; transition: border-color .15s, background .15s; }
.buy-pkg:has(input:checked), .buy-rung:has(input:checked) { background: #fff; border-color: var(--brand); box-shadow: var(--card-shadow); }
.buy-pkg input, .buy-rung input { position: absolute; opacity: 0; width: 1px; height: 1px; }
.buy-pkg:has(input:focus-visible), .buy-rung:has(input:focus-visible) { outline: 3px solid var(--saffron, #f2b134); outline-offset: 2px; }
.buy-dot { width: 20px; height: 20px; border-radius: 50%; background: #fff; border: 2px solid var(--line); }
:checked ~ .buy-dot { border-color: var(--brand); background: var(--brand); box-shadow: inset 0 0 0 4px #fff; }
.buy-pkg-body, .buy-rung-body { display: flex; flex-direction: column; gap: 3px; min-width: 0; }
.buy-pkg-body strong, .buy-rung-head strong { font-size: 16px; }
.buy-pkg-body .muted { font-size: 13px; margin-inline-start: 4px; }
.buy-strip { display: flex; flex-wrap: wrap; gap: 4px; justify-content: flex-end; }
.buy-strip i { font-style: normal; font-size: 11px; font-weight: 700; line-height: 1.7; padding: 0 6px; border-radius: 5px; background: var(--teal-tint, #e3f4f2); color: var(--teal-ink, #0b5f5c); }
.buy-strip i.is-off { background: transparent; color: var(--muted); text-decoration: line-through; font-weight: 400; opacity: .7; }
.buy-pkg-price, .buy-rung-price { display: flex; flex-direction: column; align-items: flex-end; text-align: end; white-space: nowrap; gap: 1px; }
.buy-pkg-price strong, .buy-rung-price strong { font-size: 16px; }
.buy-pkg-price del { font-size: 12px; }

.buy-rung-wrap { position: relative; }
.buy-rung { padding-inline-end: 46px; }
.buy-rung-head { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.buy-rung-body small { font-size: 13px; line-height: 1.8; }
.buy-included { display: none; font-size: 11px; font-weight: 700; padding: 1px 9px; border-radius: 999px; background: var(--teal, #0f8b8d); color: #fff; }
.buy-free { font-size: 12px; font-weight: 700; padding: 2px 10px; border-radius: 999px; background: var(--teal-tint, #e3f4f2); color: var(--teal-ink, #0b5f5c); }
.buy-free[hidden] { display: none; }
.buy-rung.is-included { background: var(--teal-tint, #e3f4f2); }
.buy-rung.is-included .buy-included { display: inline-block; }
.buy-rung.is-included .buy-dot { border-color: var(--teal, #0f8b8d); background: var(--teal, #0f8b8d); display: grid; place-items: center; }
.buy-rung.is-included .buy-dot::before { content: "✓"; color: #fff; font-size: 11px; font-weight: 800; }
.buy-rung.is-included .js-buy-addon { text-decoration: line-through; color: var(--muted); font-weight: 400; }
.buy-rung.is-included .buy-free { opacity: .6; }
.buy-info { position: absolute; inset-inline-end: 12px; top: 50%; transform: translateY(-50%); width: 24px; height: 24px; border-radius: 50%; display: grid; place-items: center;
    border: 1.5px solid var(--brand); color: var(--brand); font: italic 700 13px/1 Georgia, serif; text-decoration: none; background: #fff; }
.buy-info:hover, .buy-info.is-open { background: var(--brand); color: #fff; }
.buy-rung-wrap:has(.buy-rung-info:not([hidden])) .buy-info { top: 26px; transform: none; }
.buy-rung-info { margin: 4px 0 4px; padding: 10px 16px; border-radius: var(--radius-sm); border: 1px dashed var(--line); font-size: 13px; line-height: 1.9; }
.buy-rung-info ul { margin: 0 0 4px; padding-inline-start: 18px; }
.buy-ladder-group { display: flex; flex-direction: column; padding-top: 8px; }
.buy-rung-quote { cursor: default; background: transparent; border: 2px dashed var(--line); padding-inline-end: 16px; }
.buy-rung-quote .buy-dot { border-style: dashed; }
.buy-contact { background: transparent; color: var(--brand); border: 1px solid var(--brand); }
.buy-contact:hover { background: var(--brand); color: #fff; }

.buy-licensee { display: grid; grid-template-columns: 1fr 1fr; gap: 10px 14px; padding: 16px; border-radius: var(--radius-sm); background: var(--sample-bg); }
.buy-field { display: flex; flex-direction: column; gap: 4px; }
.buy-field label { font-size: 13px; font-weight: 700; }
.buy-field label small { font-weight: 400; color: var(--muted); }
.buy-field.is-required label small { color: var(--brand); font-weight: 700; }
.buy-field input { width: 100%; }
.buy-licensee > small { grid-column: 1 / -1; font-size: 12px; }

.buy-box { position: sticky; top: 90px; border-radius: var(--radius); border: 1px solid var(--line); background: #fff; overflow: hidden; }
.buy-contents { padding: 18px 18px 14px; }
.buy-contents h3 { margin: 0 0 10px; font-size: 15px; }
.buy-contents h4 { margin: 0 0 8px; font-size: 13px; color: var(--muted); }
.buy-weights, .buy-formats { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 4px; }
.buy-weights li { display: grid; grid-template-columns: 18px minmax(0, 1fr) auto; gap: 8px; align-items: center; transition: opacity .15s; }
.buy-weights li small { color: var(--muted); font-size: 11px; }
.buy-weight-sample { font-size: 17px; line-height: 1.7; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.buy-formats-wrap { margin-top: 14px; padding-top: 14px; border-top: 1px solid var(--divider); }
.buy-formats { flex-direction: row; flex-wrap: wrap; gap: 6px 14px; }
.buy-formats li { display: flex; align-items: center; gap: 6px; transition: opacity .15s; }
.buy-check { flex: none; display: inline-grid; place-items: center; width: 18px; height: 18px; border-radius: 50%; background: var(--teal, #0f8b8d); color: #fff; font-size: 11px; font-weight: 800; }
.buy-check::before { content: "✓"; }
.buy-weights .is-off, .buy-formats .is-off { opacity: .4; }
.is-off .buy-check { background: var(--line); color: var(--muted); }
.is-off .buy-check::before { content: "✕"; }
.is-off .buy-weight-sample, .buy-formats .is-off bdi { text-decoration: line-through; text-decoration-thickness: 1px; }
.buy-checkout { display: flex; flex-direction: column; gap: 8px; padding: 0 18px 16px; }
.buy-summary { display: flex; flex-direction: column; gap: 10px; padding: 14px 16px; border-radius: var(--radius-sm); background: var(--deep, #1d2a3a); color: #fff; }
.buy-lines { margin: 0; display: flex; flex-direction: column; gap: 2px; font-size: 13px; }
.buy-lines div { display: flex; justify-content: space-between; gap: 10px; }
.buy-lines dt { opacity: .8; } .buy-lines dd { margin: 0; white-space: nowrap; }
.buy-total { display: flex; justify-content: space-between; align-items: baseline; gap: 10px; padding-top: 8px; border-top: 1px solid rgba(255, 255, 255, .2); }
.buy-total small { opacity: .8; font-size: 13px; }
.buy-total span { display: flex; flex-direction: column; align-items: flex-end; }
.buy-total strong { font-size: 21px; }
.buy-total del { color: rgba(255, 255, 255, .6); font-size: 12px; }
.buy-total del:empty { display: none; }
.buy-summary .button { width: 100%; }
.buy-summary .button[disabled] { opacity: .55; cursor: not-allowed; }
.buy-note { margin: 0; font-size: 12px; color: var(--muted); line-height: 1.8; }

@media (max-width: 960px) {
    /* ترتیب موبایل: بسته‌ها ← «در این بسته» ← کاربرد ← نام دارنده ← جمع چسبان */
    .buy-config { grid-template-columns: minmax(0, 1fr); gap: 18px; }
    .buy-box, .buy-steps { display: contents; }
    .buy-step:first-child { order: 1; }
    .buy-contents { order: 2; border: 1px solid var(--line); border-radius: var(--radius); }
    .buy-step + .buy-step { order: 3; }
    .buy-licensee { order: 4; }
    .buy-checkout { order: 5; position: sticky; bottom: 10px; z-index: 5; padding: 0; }
    .buy-summary { box-shadow: 0 8px 30px rgba(0, 0, 0, .25); }
    .buy-lines { display: none; }
    .buy-summary { flex-direction: row; align-items: center; }
    .buy-total { flex: 1; border: 0; padding: 0; flex-direction: column; align-items: flex-start; gap: 0; }
    .buy-total span { align-items: flex-start; }
    .buy-summary .button { width: auto; white-space: nowrap; }
    .buy-checkout .buy-note { display: none; }
}
@media (max-width: 600px) {
    .buy-licensee { grid-template-columns: 1fr; }
    .buy-pkg, .buy-rung { grid-template-columns: 22px minmax(0, 1fr); }
    .buy-pkg-price, .buy-rung-price { grid-column: 2; flex-direction: row; align-items: baseline; gap: 8px; justify-content: flex-start; }
    .buy-strip { justify-content: flex-start; }
    .buy-info { top: 14px; transform: none; }
}
.license-css pre { white-space: pre-wrap; font-size: 12px; line-height: 1.7; background: var(--sample-bg); padding: 12px; border-radius: var(--radius-sm); text-align: left; overflow-x: auto; }
.preview-note summary { cursor: pointer; }
.preview-note ul { margin: 8px 0; padding-inline-start: 20px; line-height: 2; font-size: 14px; }

/* ۳۴ حالت تعمیر (PublicMaintenance): صفحه بازدیدکننده + نوار هشدار مدیر */
.maintenance-page { min-height: 100vh; display: grid; place-items: center; background: var(--deep, #0B3B40); margin: 0; padding: 24px; }
.maintenance-box { max-width: 520px; width: 100%; text-align: center; background: #fff; border-radius: var(--radius); padding: 40px 28px; box-shadow: 0 20px 60px rgba(0, 0, 0, .25); }
.maintenance-box h1 { margin: 18px 0 8px; font-size: 24px; }
.maintenance-box p { margin: 0; color: var(--muted); line-height: 2; white-space: pre-line; }
.maintenance-bar { background: var(--saffron, #F2B134); color: #3a2a00; text-align: center; font-size: 13px; font-weight: 700; padding: 6px 12px; }

/* ۳۵ فرم ارسال فونت طراح (account/submissions): ردیف‌های چندستونی، انتخاب نوع به شکل دکمه، جای فایل */
.designer-form { padding: 24px 26px; }
.form-grid { display: grid; gap: 0 18px; }
.form-grid.cols-2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.form-grid.cols-3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.form-grid[hidden] { display: none; }
.form-grid > .form-row { min-width: 0; }
.form-row-narrow { max-width: 320px; }
.form-row small.muted { font-size: 12px; line-height: 1.8; }
.seg { display: inline-flex; flex-wrap: wrap; gap: 6px; padding: 4px; border-radius: 12px; background: var(--sample-bg); width: fit-content; }
.seg-item { position: relative; cursor: pointer; }
.seg-item input { position: absolute; opacity: 0; width: 1px; height: 1px; }
.seg-item span { display: block; padding: 8px 16px; border-radius: 9px; font-size: 14px; font-weight: 600; color: var(--muted); transition: background .15s, color .15s; }
.seg-item input:checked + span { background: #fff; color: var(--ink, #10302e); box-shadow: var(--card-shadow); }
.seg-item input:focus-visible + span { outline: 3px solid var(--saffron, #F2B134); }
.seg-item input:disabled + span { opacity: .45; cursor: not-allowed; }
.file-drop { padding: 18px; border: 2px dashed var(--line); border-radius: var(--radius-sm); background: var(--sample-bg); }
.file-drop input[type="file"] { font: inherit; font-size: 14px; }
.file-drop input[type="file"]::file-selector-button { font: inherit; font-weight: 700; margin-inline-end: 12px; padding: 8px 16px; border: 0; border-radius: 999px; background: var(--brand); color: #fff; cursor: pointer; }
.form-actions { display: flex; justify-content: flex-end; margin-top: 8px; }
@media (max-width: 760px) {
    .form-grid.cols-2, .form-grid.cols-3 { grid-template-columns: minmax(0, 1fr); }
    .form-row-narrow { max-width: none; }
    .designer-form { padding: 18px 16px; }
    .form-actions .button { width: 100%; }
}
