/* ============================================================
   bahamfilm — Home Hero (فقط صفحه اصلی)
   زیپ نشده، بدون وابستگی به style.css های جدید — فقط با توکن‌های
   موجود در style.css ساخته شده (--accent, --bg-surface, ...)
   ============================================================ */

:root {
  --hero-ease: cubic-bezier(.22, 1, .36, 1);
  --hero-ink:  #f0ece6;
  --hero-dim:  #9a9fad;
}

/* ── لایه سایتوئن پشت hero ─────────────────────────────────── */
.hero-vignette {
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 0;
  background:
    radial-gradient(ellipse 90% 55% at 50% -10%, rgba(224,92,92,.13), transparent 65%),
    radial-gradient(ellipse 60% 40% at 50% 110%, rgba(64,50,150,.15), transparent 70%);
}

/* نور پروژکتور که آرام تکان میخوره */
.hero-beam {
  position: fixed;
  top: -30vh;
  left: 50%;
  width: 140vw;
  height: 90vh;
  transform: translateX(-50%) rotate(-6deg);
  pointer-events: none;
  z-index: 0;
  background: linear-gradient(180deg, rgba(240,236,230,.055), transparent 75%);
  clip-path: polygon(42% 0, 58% 0, 100% 100%, 0% 100%);
  animation: beam-sway 14s ease-in-out infinite alternate;
  opacity: .9;
}
@keyframes beam-sway {
  from { transform: translateX(-52%) rotate(-6deg); opacity: .55; }
  to   { transform: translateX(-48%) rotate(5deg);  opacity: .95; }
}

.home-wrap { max-width: 720px; gap: 30px; padding-bottom: 56px; }

/* ── Brand ─────────────────────────────────────────────────── */
.brand { display: flex; flex-direction: column; align-items: center; gap: 2px; }

.brand-name {
  font-size: clamp(2.4rem, 7vw, 3.4rem);
  background: linear-gradient(180deg, var(--hero-ink) 55%, rgba(240,236,230,.55));
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
}

.brand-sub { font-size: clamp(.95rem, 2.5vw, 1.05rem); letter-spacing: .01em; }

/* آیکون بیلبورد کوچک فیلم؟ حالا کاست VHS */
.brand-reel {
  color: var(--accent);
  filter: drop-shadow(0 0 14px var(--accent-glow));
}

/* نسخهٔ تصویری (لوگوی VHS) — نسبت عکس ۱٫۶۶:۱ */
.brand-reel-img {
  width: auto;
  height: clamp(46px, 9vw, 62px);
  filter: drop-shadow(0 6px 14px rgba(0,0,0,.55)) drop-shadow(0 0 20px rgba(224,92,92,.30));
}

/* ── Hero kinetic ──────────────────────────────────────────── */
.hero-kinetic {
  width: 100%;
  text-align: center;
  user-select: none;
}

.hero-line { display: block; }

.hero-rotator {
  display: inline-flex;
  align-items: baseline;
  gap: .34em;
  font-weight: 800;
  font-size: clamp(1.25rem, 4.6vw, 1.9rem);
  line-height: 1.55;
}

.hero-rotator .frase {
  display: inline-block;
  color: var(--accent);
  min-width: 5.2ch;
  text-align: center;
  text-shadow: 0 0 26px var(--accent-glow);
}

/* هر لهجه‌ام فقط کلمه کامل — چون شکل‌دادن حروف فارسی با split خراب میشه */
.hero-rotator .frase.swapping { animation: frase-in .62s var(--hero-ease) both; }
.hero-rotator .frase.leaving  { animation: frase-out .34s cubic-bezier(.7,0,.84,0) both; }

@keyframes frase-in {
  from { opacity: 0; transform: translateY(.42em) scaleX(1.15); filter: blur(9px); }
  55%  { filter: blur(0); }
  to   { opacity: 1; transform: translateY(0) scaleX(1); filter: blur(0); }
}
@keyframes frase-out {
  from { opacity: 1; transform: translateY(0); filter: blur(0); }
  to   { opacity: 0; transform: translateY(-.4em); filter: blur(7px); }
}

.hero-sub {
  font-size: clamp(.92rem, 2.4vw, 1.05rem);
  color: var(--hero-dim);
  max-width: 34em;
  margin: 10px auto 0;
  line-height: 1.9;
}

/* ── دکمه‌های CTA — هم‌تراز، اندازه بزرگ ───────────────────── */
.home-actions {
  width: 100%;
  display: flex;
  flex-direction: row;
  gap: 14px;
  justify-content: center;
  flex-wrap: wrap;
}

.home-actions .btn {
  flex: 1 1 200px;
  max-width: 260px;
  padding: 16px 26px;
  font-size: 1.08rem;
}

/* ورود به اتاق — حالت outline رفیق اصلی */
.home-actions .btn-ghost { backdrop-filter: blur(4px); }

.btn-rec-suggest { margin-top: 4px; }

/* ── نوار feature marquee (بخش دیدنی وسط) ──────────────────── */
.features-strip {
  width: 100%;
  overflow: hidden;
  position: relative;
  padding: 14px 0;
  border-block: 1px solid var(--border);
  -webkit-mask-image: linear-gradient(90deg, transparent, #000 12%, #000 88%, transparent);
          mask-image: linear-gradient(90deg, transparent, #000 12%, #000 88%, transparent);
}

.features-track {
  display: flex;
  gap: 2.6rem;
  width: max-content;
  animation: marquee 26s linear infinite;
}

@keyframes marquee {
  from { transform: translateX(0); }
  to   { transform: translateX(50%); }  /* RTL: جهت حرکت به راست */
}

.feature-chip {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  font-size: .9rem;
  font-weight: 600;
  color: var(--hero-dim);
  white-space: nowrap;
}

.feature-chip svg { width: 17px; height: 17px; color: var(--accent); flex-shrink: 0; }
.feature-chip b { color: var(--hero-ink); font-weight: 700; }

/* ── سه‌قدمی «چطور کار میکنه» ──────────────────────────────── */
.how {
  width: 100%;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 12px;
}

.how-step {
  background: linear-gradient(180deg, rgba(28,31,43,.85), rgba(21,24,32,.85));
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 20px 16px 18px;
  text-align: center;
  transition: transform .35s var(--hero-ease), border-color .25s ease;
  position: relative;
}
.how-step:hover { transform: translateY(-4px); border-color: rgba(224,92,92,.4); }

.how-num {
  display: inline-grid;
  place-items: center;
  width: 34px; height: 34px;
  border-radius: 50%;
  border: 1px solid rgba(224,92,92,.5);
  color: var(--accent);
  font-size: .95rem;
  font-weight: 800;
  margin-bottom: 10px;
  background: rgba(224,92,92,.08);
}

.how-step h3 { font-size: .98rem; font-weight: 700; margin-bottom: 6px; color: var(--hero-ink); }
.how-step p  { font-size: .82rem; color: var(--hero-dim); line-height: 1.8; }

/* ورود پلکانی عناصر هیرو */
.reveal { opacity: 0; transform: translateY(16px); }
.reveal.in {
  animation: rise .8s var(--hero-ease) forwards;
}
@keyframes rise {
  to { opacity: 1; transform: translateY(0); }
}

/* ── ریاضت‌های آماری قبل footer ───────────────────────────── */
.hero-stats {
  display: flex;
  justify-content: center;
  gap: 2.4rem;
  flex-wrap: wrap;
}
.hero-stat { text-align: center; }
.hero-stat b { display: block; font-size: 1.35rem; font-weight: 800; color: var(--hero-ink); letter-spacing: -.02em; }
.hero-stat span { font-size: .78rem; color: var(--text-muted); }

/* ── SEO intro بازطراحی‌شده ──────────────────────────────── */
.seo-intro { text-align: right; padding: 26px 24px; }
.seo-title { font-size: 1.15rem; font-weight: 800; margin-bottom: 10px; }
.seo-text  { font-size: .9rem; color: var(--hero-dim); line-height: 2; }
.seo-text strong { color: var(--hero-ink); }

.seo-features {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 8px 18px;
  margin: 18px 0;
}
.seo-feature {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: .85rem;
  color: var(--hero-dim);
}

/* جایگزین ایموجی‌ها با دایره نقطه‌ای اکسنت — چون ایموجی روی
   فونت‌های مختلف موبایل، شکل‌های مختلفی میگیره و amateurs look میده */
.seo-feature::before {
  content: '';
  width: 6px; height: 6px;
  border-radius: 50%;
  background: var(--accent);
  flex-shrink: 0;
  opacity: .85;
}
.seo-feature span { flex: 1; }

.seo-subtitle { font-size: 1rem; font-weight: 700; margin: 6px 0 10px; }
.seo-steps { padding-right: 18px; color: var(--hero-dim); font-size: .87rem; line-height: 2.2; }
.seo-steps li::marker { color: var(--accent); font-weight: 700; }

/* ── هشدار «بالای ۲ گیگ» زیر فایل‌دراپ در فرم ساخت اتاق ──── */
.upload-cap-warn {
  margin-top: 10px;
  font-size: .84rem;
  color: var(--text-secondary);
  text-align: center;
}
.cap-warn-link {
  color: var(--accent);
  font-weight: 700;
  text-decoration: none;
  border-bottom: 1px dashed rgba(224,92,92,.5);
  transition: var(--transition);
}
.cap-warn-link:hover { color: var(--accent-dim); border-bottom-color: var(--accent-dim); }

/* ── reduced motion ───────────────────────────────────────── */
@media (prefers-reduced-motion: reduce) {
  .hero-beam { animation: none; opacity: .7; }
  .features-track { animation: none; width: auto; flex-wrap: wrap; justify-content: center; }
  .frase.swapping, .frase.leaving { animation: none; }
  .reveal { opacity: 1; transform: none; }
}

/* ── Responsive ───────────────────────────────────────────── */
@media (max-width: 640px) {
  /* دکمه‌ها ستونی و «باریک» — بلوک‌های عظیم نه، action فشرده */
  .home-actions { flex-direction: column; align-items: stretch; gap: 10px; }
  .home-actions .btn {
    flex: 0 0 auto;             /* ریشهٔ دکمه‌های غول‌پیکر حذف شد: flex-basis 200px در ستون = قد ۲۰۰px */
    max-width: none; width: 100%;
    min-height: 48px;           /* هدف لمسی استاندارد، نه بلوک سینمایی */
    padding: 11px 18px;
    font-size: 0.97rem;
  }
  .home-actions .btn-icon { width: 18px; height: 18px; }
  .home-actions .btn-3d-tag { font-size: .72rem; padding: 2px 7px; }

  .how { grid-template-columns: 1fr; }
  .how-step { text-align: right; display: flex; align-items: flex-start; gap: 12px; padding: 12px 16px; }
  .how-step .how-text { text-align: right; }
  .how-num { margin-bottom: 0; width: 28px; height: 28px; font-size: .85rem; }
  .how-step h3 { font-size: .92rem; }
  .how-step p { font-size: .8rem; }

  .hero-sub { max-width: 100%; font-size: .9rem; }
  .hero-stats { gap: 1rem; }
  .hero-stat b { font-size: 1.05rem; }
  .hero-stat span { font-size: .72rem; }
  .features-strip { padding: 10px 0; }
  .feature-chip { font-size: .82rem; }
  .seo-intro { padding: 18px 16px; }

  /* مارکی رو آروم‌تر کن که روی گوشی چشم‌آزار نشه */
  .features-track { animation-duration: 40s; }
}

/* صفحه‌های خیلی باریک (iPhone SE / Android کوچک) */
@media (max-width: 380px) {
  .hero-rotator { font-size: clamp(1.1rem, 5.4vw, 1.6rem); }
  .brand-name { font-size: 2.1rem; }
  .hero-stats { flex-direction: column; gap: .7rem; }
  .btn-rec-suggest { font-size: .82rem; }
  .home-actions { gap: 8px; }
  .home-actions .btn { padding: 10px 14px; font-size: .93rem; min-height: 44px; }
}

/* لینک‌های راهنما داخل بخش سئو */
.seo-steps a { color: var(--accent); text-decoration: none; }
.seo-steps a:hover { text-decoration: underline; }
