/* ── فونت ─────────────────────────────────────────────────────
   Vazirmatn به‌صورت self-host (Google Fonts از ایران کند/مسدود است).
   فایل‌ها در public/fonts/ قرار می‌گیرند — راهنما در public/fonts/README.md
   ───────────────────────────────────────────────────────────── */

@font-face {
  font-family: 'Vazirmatn';
  src: url('/fonts/Vazirmatn-Regular.woff2') format('woff2');
  font-weight: 400;
  font-display: swap;
}
@font-face {
  font-family: 'Vazirmatn';
  src: url('/fonts/Vazirmatn-Medium.woff2') format('woff2');
  font-weight: 500;
  font-display: swap;
}
@font-face {
  font-family: 'Vazirmatn';
  src: url('/fonts/Vazirmatn-Bold.woff2') format('woff2');
  font-weight: 700;
  font-display: swap;
}
@font-face {
  font-family: 'Vazirmatn';
  src: url('/fonts/Vazirmatn-ExtraBold.woff2') format('woff2');
  font-weight: 800;
  font-display: swap;
}

/* ── ریست ─────────────────────────────────────────────────── */

*,
*::before,
*::after {
  box-sizing: border-box;
}

* {
  margin: 0;
  padding: 0;
}

html {
  -webkit-text-size-adjust: 100%;
  scroll-behavior: smooth;
  scroll-padding-top: calc(var(--header-h) + var(--space-4));
}

body {
  font-family: var(--font-sans);
  font-size: var(--fs-base);
  line-height: var(--lh-normal);
  color: var(--text-body);
  background: var(--bg-body);
  direction: rtl;
  text-align: right;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

img,
picture,
svg,
video {
  display: block;
  max-width: 100%;
  height: auto;
}

a {
  color: inherit;
  text-decoration: none;
}

button,
input,
select,
textarea {
  font: inherit;
  color: inherit;
}

button {
  background: none;
  border: none;
  cursor: pointer;
}

ul,
ol {
  list-style: none;
}

table {
  border-collapse: collapse;
  width: 100%;
}

:focus-visible {
  outline: 2px solid var(--orange-500);
  outline-offset: 2px;
  border-radius: var(--radius-sm);
}

h1, h2, h3, h4, h5, h6 {
  color: var(--text-strong);
  line-height: var(--lh-tight);
  font-weight: var(--fw-bold);
}

/* ── ابزارهای چیدمان ───────────────────────────────────────── */

.container {
  width: 100%;
  max-width: var(--container);
  margin-inline: auto;
  padding-inline: var(--space-5);
}

.section {
  padding-block: var(--space-9);
}

.section--tight {
  padding-block: var(--space-7);
}

.section--subtle {
  background: var(--bg-subtle);
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

.skip-link {
  position: absolute;
  inset-inline-start: var(--space-4);
  top: -100px;
  z-index: 1000;
  padding: var(--space-3) var(--space-5);
  background: var(--orange-500);
  color: var(--white);
  border-radius: var(--radius);
  transition: top var(--transition);
}
.skip-link:focus {
  top: var(--space-4);
}

/* عنوان بخش با زیرخط نارنجی — الگوی تکرارشونده در همه‌ی پروتوتایپ‌ها */
.section-title {
  text-align: center;
  margin-bottom: var(--space-7);
}

.section-title h2 {
  font-size: var(--fs-2xl);
  font-weight: var(--fw-black);
  position: relative;
  display: inline-block;
  padding-bottom: var(--space-3);
}

.section-title h2::after {
  content: '';
  position: absolute;
  bottom: 0;
  inset-inline-start: 50%;
  transform: translateX(50%);
  width: 56px;
  height: 3px;
  background: var(--orange-500);
  border-radius: var(--radius-full);
}

.section-title p {
  margin-top: var(--space-3);
  color: var(--text-muted);
  font-size: var(--fs-md);
  max-width: 640px;
  margin-inline: auto;
}

@media (max-width: 768px) {
  :root {
    --fs-2xl: 1.4rem;
    --fs-3xl: 1.75rem;
    --fs-4xl: 2rem;
    --space-9: 2.5rem;
  }
  .container {
    padding-inline: var(--space-4);
  }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }
}
