/* landing.css — Disciplineo public site: "a quieter way to keep your promises
   to yourself." Warm paper palette (cream/ink/sage/terracotta), a humanist
   serif for headlines (Fraunces) paired with a soft grotesk body (Karla),
   Vazirmatn for Farsi. The signature is "the desk" — a small, honest stack of
   handwritten-feeling notes (a goal, a habit, a check-in), not a dashboard. */

/* All color values come from colors.css (loaded before this file) — edit the
   palette there, never here. */
:root {
  color-scheme: light;
  --bg: var(--c-paper);
  --bg-soft: var(--c-paper-soft);
  --surface: color-mix(in srgb, var(--c-card) 86%, transparent);
  --surface-strong: var(--c-card);
  --surface-hover: var(--c-card-max);
  --text: var(--c-ink);
  --muted: var(--c-ink-soft);
  --muted-2: var(--c-ink-faint);
  --border: color-mix(in srgb, var(--c-ink) 12%, transparent);
  --border-strong: color-mix(in srgb, var(--c-ink) 20%, transparent);
  --sage: var(--c-success);
  --sage-strong: var(--c-success-strong);
  --terracotta: var(--c-accent);
  --terracotta-strong: var(--c-accent-strong);
  --gold: var(--c-gold);
  --danger: var(--c-danger);
  --shadow: 0 26px 60px color-mix(in srgb, var(--c-shadow-ink) 14%, transparent);
  --shadow-sm: 0 12px 30px color-mix(in srgb, var(--c-shadow-ink) 10%, transparent);
  --radius-xl: 28px;
  --radius-lg: 20px;
  --radius-md: 14px;
  --container: 1140px;
  --font-fa: "Vazirmatn", Tahoma, Arial, sans-serif;
  --font-en: "Karla", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  --font-display-en: "Fraunces", "Vazirmatn", Georgia, serif;
}

html[lang="fa"] { --font-display: var(--font-fa); }
html[lang="en"] { --font-display: var(--font-display-en); }

html[data-theme="dark"] {
  color-scheme: dark;
  --bg: var(--c-night);
  --bg-soft: var(--c-night-soft);
  --surface: color-mix(in srgb, var(--c-cream) 6%, transparent);
  --surface-strong: color-mix(in srgb, var(--c-night-card) 92%, transparent);
  --surface-hover: color-mix(in srgb, var(--c-night-card-hover) 96%, transparent);
  --text: var(--c-night-ink);
  --muted: var(--c-night-ink-soft);
  --muted-2: var(--c-night-ink-faint);
  --border: color-mix(in srgb, var(--c-cream) 10%, transparent);
  --border-strong: color-mix(in srgb, var(--c-cream) 16%, transparent);
  --sage: var(--c-success-dk);
  --sage-strong: var(--c-success-dk-strong);
  --terracotta: var(--c-accent-dk);
  --terracotta-strong: var(--c-accent-dk-strong);
  --gold: var(--c-gold-dk);
  --shadow: 0 26px 60px color-mix(in srgb, var(--c-shadow-night) 40%, transparent);
  --shadow-sm: 0 12px 30px color-mix(in srgb, var(--c-shadow-night) 30%, transparent);
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

html[lang="fa"] body,
html[dir="rtl"] body { font-family: var(--font-fa); direction: rtl; }

html[lang="en"] body,
html[dir="ltr"] body { font-family: var(--font-en); direction: ltr; }

body {
  margin: 0;
  min-height: 100vh;
  color: var(--text);
  background: var(--bg);
  font-size: 16px;
  line-height: 1.7;
  overflow-x: hidden;
  text-rendering: optimizeLegibility;
  -webkit-font-smoothing: antialiased;
}

/* Subtle paper grain — a warm, physical texture instead of a tech grid. */
body::before {
  content: "";
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 0;
  opacity: 0.05;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='140' height='140'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.85' numOctaves='2' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
  mix-blend-mode: multiply;
}

html[data-theme="dark"] body::before { opacity: 0.08; mix-blend-mode: overlay; }

a { color: inherit; text-decoration: none; }
button, a { -webkit-tap-highlight-color: transparent; }
img { max-width: 100%; display: block; }

.no-select,
.site-header,
.hero h1,
.hero-subtitle,
.trust-row,
.hero-visual,
.logo-strip,
.section-heading,
.feature-card,
.step-card,
.screen-card,
.stats-grid,
.compare-card,
.article-card,
.faq-list summary,
.final-cta h2,
.final-cta p,
.footer-card,
.footer-brand,
.footer-copy,
.footer-action,
.footer-label {
  -webkit-user-select: none;
  user-select: none;
}

.container {
  width: min(var(--container), calc(100% - 40px));
  margin-inline: auto;
}

.section {
  position: relative;
  z-index: 1;
  padding: 88px 0;
}

.skip-link {
  position: fixed;
  top: 14px;
  inset-inline-start: 14px;
  transform: translateY(-140%);
  z-index: 100;
  padding: 10px 14px;
  border-radius: 999px;
  background: var(--surface-strong);
  border: 1px solid var(--border-strong);
  color: var(--text);
  transition: transform 0.2s ease;
}

.skip-link:focus { transform: translateY(0); }

/* Brand-consistent focus ring for every interactive element (native browser
   outlines were the only visible-focus signal before this). Scoped to
   :focus-visible so mouse/touch users see no ring, only keyboard users do. */
a:focus-visible,
button:focus-visible,
summary:focus-visible,
input:focus-visible,
[tabindex]:focus-visible {
  outline: 2px solid var(--terracotta-strong);
  outline-offset: 3px;
  border-radius: var(--radius-md);
}

/* ---- ambient light pools: soft, warm, slow — daylight through a window,
   not neon under-glow. ---- */
.page-shell {
  position: fixed;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  overflow: hidden;
}

.orb {
  position: absolute;
  width: 26rem;
  height: 26rem;
  border-radius: 999px;
  filter: blur(90px);
  opacity: 0.22;
  animation: floatOrb 16s ease-in-out infinite alternate;
}

.orb-one { top: 2rem; inset-inline-start: -10rem; background: var(--gold); }
.orb-two { top: 18rem; inset-inline-end: -11rem; background: var(--terracotta); animation-delay: 2s; opacity: 0.16; }
.orb-three { bottom: -10rem; inset-inline-start: 40%; background: var(--sage); opacity: 0.16; animation-delay: 4s; }

html[data-theme="dark"] .orb { opacity: 0.14; }

.grid-glow {
  position: absolute;
  inset: 0;
  background: radial-gradient(circle at 50% 12%, color-mix(in srgb, var(--c-cream) 50%, transparent), transparent 40rem);
}

html[data-theme="dark"] .grid-glow {
  background: radial-gradient(circle at 50% 12%, color-mix(in srgb, var(--c-gold) 5%, transparent), transparent 40rem);
}

@keyframes floatOrb {
  to { transform: translate3d(20px, -16px, 0) scale(1.05); }
}

/* ---- header ---- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 20;
  padding: 16px 0;
  transition: background 0.25s ease, border-color 0.25s ease, box-shadow 0.25s ease;
}

.site-header.is-scrolled {
  background: color-mix(in srgb, var(--c-paper) 82%, transparent);
  backdrop-filter: blur(14px);
  border-bottom: 1px solid var(--border);
  box-shadow: 0 8px 24px color-mix(in srgb, var(--c-shadow-ink) 6%, transparent);
}

html[data-theme="dark"] .site-header.is-scrolled {
  background: color-mix(in srgb, var(--c-night) 82%, transparent);
}

.nav {
  height: 62px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  border: 1px solid var(--border);
  border-radius: 999px;
  padding: 8px 8px 8px 18px;
  background: var(--surface-strong);
  box-shadow: var(--shadow-sm);
}

html[dir="rtl"] .nav { padding: 8px 18px 8px 8px; }

.brand {
  font-family: var(--font-display);
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-weight: 700;
  letter-spacing: -0.01em;
  white-space: nowrap;
  font-size: 1.05rem;
}

.brand img { width: 34px; height: 34px; border-radius: 11px; box-shadow: 0 8px 18px color-mix(in srgb, var(--c-accent) 28%, transparent); }

.nav-panel {
  display: flex;
  align-items: center;
  gap: 2px;
  padding: 3px;
  border-radius: 999px;
}

.nav-panel a {
  padding: 9px 13px;
  border-radius: 999px;
  color: var(--muted);
  font-size: 0.92rem;
  font-weight: 600;
  white-space: nowrap;
  transition: color 0.2s ease, background 0.2s ease;
}

.nav-panel a:hover { color: var(--text); background: var(--bg-soft); }

.nav-actions { display: flex; align-items: center; gap: 8px; }

.nav-toggle {
  display: none;
  width: 40px;
  height: 40px;
  border: 1px solid var(--border);
  border-radius: 13px;
  background: var(--surface);
  color: var(--text);
  cursor: pointer;
}

.nav-toggle span { display: block; width: 17px; height: 2px; margin: 4px auto; border-radius: 99px; background: currentColor; }

.icon-btn,
.lang-switch {
  height: 38px;
  min-width: 38px;
  border: 1px solid var(--border);
  border-radius: 999px;
  background: var(--bg-soft);
  color: var(--text);
  font: inherit;
  font-weight: 700;
  cursor: pointer;
  transition: transform 0.2s ease, border-color 0.2s ease, background 0.2s ease;
}

.icon-btn:hover, .lang-switch:hover { border-color: var(--border-strong); background: var(--surface-hover); }

.icon-btn { display: inline-grid; place-items: center; position: relative; overflow: hidden; }
.icon-btn .sun, .icon-btn .moon { grid-area: 1 / 1; transition: transform 0.25s ease, opacity 0.25s ease; }
html[data-theme="light"] .icon-btn .moon,
html[data-theme="dark"] .icon-btn .sun { opacity: 0; transform: scale(0.5) rotate(90deg); }

/* ---- buttons ---- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  border: 1px solid transparent;
  border-radius: 999px;
  padding: 11px 20px;
  font-weight: 700;
  line-height: 1;
  cursor: pointer;
  transition: transform 0.2s ease, box-shadow 0.2s ease, border-color 0.2s ease, background 0.2s ease;
  white-space: nowrap;
}

.btn:hover { transform: translateY(-1px); }

.btn-primary {
  color: #fffaf3;
  background: var(--terracotta);
  box-shadow: 0 12px 26px color-mix(in srgb, var(--c-accent) 32%, transparent);
}
.btn-primary:hover { background: var(--terracotta-strong); box-shadow: 0 16px 34px color-mix(in srgb, var(--c-accent) 40%, transparent); }

.btn-ghost { color: var(--text); background: var(--surface); border-color: var(--border); }
.btn-ghost:hover { border-color: var(--border-strong); background: var(--surface-hover); }

.btn-sm { padding: 10px 14px; font-size: 0.9rem; }
.btn-lg { min-height: 52px; padding: 14px 24px; font-size: 1rem; }

/* ═══════════════════════════════════════════════════════════════════════════
   HERO
═══════════════════════════════════════════════════════════════════════════ */
.hero { padding-top: 76px; }

.hero-grid {
  display: grid;
  grid-template-columns: minmax(0, 0.98fr) minmax(380px, 1.02fr);
  gap: 48px;
  align-items: center;
}

.hero-copy { position: relative; z-index: 2; }

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  color: var(--sage-strong);
  font-weight: 700;
  font-size: 0.92rem;
  margin-bottom: 18px;
}

.pulse-dot {
  width: 9px;
  height: 9px;
  border-radius: 999px;
  background: var(--sage);
  box-shadow: 0 0 0 0 color-mix(in srgb, var(--c-success) 45%, transparent);
  animation: pulse 2.6s infinite;
}

@keyframes pulse {
  70% { box-shadow: 0 0 0 10px color-mix(in srgb, var(--c-success) 0%, transparent); }
  100% { box-shadow: 0 0 0 0 color-mix(in srgb, var(--c-success) 0%, transparent); }
}

.hero h1 {
  font-family: var(--font-display);
  margin: 0;
  max-width: 620px;
  font-size: clamp(2.5rem, 5vw, 3.85rem);
  line-height: 1.12;
  letter-spacing: -0.01em;
  font-weight: 600;
}

html[lang="fa"] .hero h1,
html[dir="rtl"] .hero h1 { line-height: 1.5; font-size: clamp(2.15rem, 4.4vw, 3.2rem); font-weight: 700; }

.hero-subtitle {
  max-width: 540px;
  margin: 20px 0 0;
  color: var(--muted);
  font-size: 1.08rem;
  line-height: 1.85;
}

.hero-actions { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 32px; }

.trust-row { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 26px; }

.trust-row span,
.logo-strip span {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 8px 13px;
  border: 1px solid var(--border);
  border-radius: 999px;
  background: var(--surface);
  color: var(--muted);
  font-size: 0.87rem;
  font-weight: 600;
}

.trust-row span::before {
  content: "";
  width: 6px;
  height: 6px;
  border-radius: 999px;
  background: var(--sage);
}

/* ═══════════════════════════════════════════════════════════════════════════
   THE DESK — the hero's signature: a small, honest stack of handwritten-
   feeling notes (a goal, a habit, a check-in), resting under soft daylight.
   Real paper depth (perspective + gentle per-card rotation + soft warm
   shadow), not glowing instrumentation. Motion is minimal on purpose —
   "calm" means less movement, not more: a one-time settle on load, then a
   very small pointer-parallax and an idle breathing drift.
═══════════════════════════════════════════════════════════════════════════ */
.hero-visual { perspective: 1400px; }

.scene3d {
  --mx: 0;
  --my: 0;
  position: relative;
  min-height: 340px;
  transform-style: preserve-3d;
}

.desk-light {
  position: absolute;
  inset: -20% 0; /* no horizontal bleed — it widens the page scroll area and shifts RTL layouts */
  z-index: 0;
  pointer-events: none;
  background: radial-gradient(
    50% 45% at calc(38% + var(--mx) * 30px) calc(28% + var(--my) * 20px),
    rgba(255, 246, 224, 0.9),
    transparent 68%
  );
  opacity: 0.9;
}

html[data-theme="dark"] .desk-light {
  background: radial-gradient(
    50% 45% at calc(38% + var(--mx) * 30px) calc(28% + var(--my) * 20px),
    color-mix(in srgb, var(--c-gold-dk) 14%, transparent),
    transparent 68%
  );
}

.desk-cards {
  position: relative;
  z-index: 1;
  width: min(88%, 380px);
  margin-inline: auto;
  transform-style: preserve-3d;
}

.desk-card {
  position: absolute;
  inset-inline-start: 0;
  top: 0;
  width: 100%;
  padding: 22px 24px;
  border-radius: var(--radius-lg);
  background: var(--surface-strong);
  border: 1px solid var(--border);
  box-shadow: var(--shadow);
  display: flex;
  align-items: center;
  gap: 14px;
  opacity: 0;
  transform:
    translateZ(var(--z, 0px))
    translateY(var(--dy, 0px))
    rotate(calc(var(--r, 0deg) + var(--mx) * 1.4deg))
    translateY(0);
  animation: cardSettle 0.9s var(--delay, 0s) cubic-bezier(.22,.68,0,1.15) forwards;
}

@keyframes cardSettle {
  from { opacity: 0; transform: translateZ(var(--z, 0px)) translateY(calc(var(--dy, 0px) - 26px)) rotate(0deg) scale(0.96); }
  to   { opacity: 1; transform: translateZ(var(--z, 0px)) translateY(var(--dy, 0px)) rotate(var(--r, 0deg)) scale(1); }
}

.dc-1 { --z: 0px;  --dy: 176px; --r: -3.2deg; --delay: 0.05s; z-index: 1; }
.dc-2 { --z: 26px; --dy: 88px;  --r: 2.4deg;  --delay: 0.22s; z-index: 2; }
.dc-3 { --z: 52px; --dy: 0px;   --r: -1.1deg; --delay: 0.4s;  z-index: 3; }

.dc-icon {
  flex: none;
  width: 40px;
  height: 40px;
  border-radius: 12px;
  display: grid;
  place-items: center;
  font-size: 1.1rem;
  background: var(--bg-soft);
}

.dc-1 .dc-icon { color: var(--terracotta-strong); }
.dc-2 .dc-icon { color: var(--sage-strong); }
.dc-3 .dc-icon { color: var(--gold); }

.dc-body { min-width: 0; flex: 1; }
.dc-title {
  display: block;
  font-family: var(--font-display);
  font-size: 1.02rem;
  font-weight: 600;
  line-height: 1.3;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.dc-meta { display: block; margin-top: 3px; font-size: 0.82rem; color: var(--muted); }

@media (hover: hover) and (pointer: fine) {
  .scene3d:hover .desk-card { transition: transform 0.5s cubic-bezier(.22,.68,0,1); }
}

@media (prefers-reduced-motion: reduce) {
  .desk-card {
    animation: none;
    opacity: 1;
    transform: translateZ(var(--z, 0px)) translateY(var(--dy, 0px)) rotate(var(--r, 0deg));
  }
}

/* ═══════════════════════════════════════════════════════════════════════════
   Logos / qualities strip
═══════════════════════════════════════════════════════════════════════════ */
.logos { padding-top: 0; }

.logo-strip {
  display: flex;
  align-items: center;
  justify-content: center;
  flex-wrap: wrap;
  gap: 10px;
  padding: 16px;
}

/* ═══════════════════════════════════════════════════════════════════════════
   Section heading
═══════════════════════════════════════════════════════════════════════════ */
.section-heading {
  max-width: 720px;
  margin: 0 auto 40px;
  text-align: center;
}

.section-heading.align-start { margin-inline: 0; text-align: start; }

.section-heading h2 {
  font-family: var(--font-display);
  margin: 0;
  font-size: clamp(1.7rem, 3.2vw, 2.5rem);
  line-height: 1.28;
  letter-spacing: -0.005em;
  font-weight: 600;
}

.section-heading p { margin: 14px 0 0; color: var(--muted); font-size: 1rem; }

/* ═══════════════════════════════════════════════════════════════════════════
   Feature / step / article / compare / stat cards — one shared material:
   warm paper, soft shadow, no glass blur, no neon.
═══════════════════════════════════════════════════════════════════════════ */
.screen-card,
.feature-card,
.step-card,
.compare-card,
.article-card,
.faq-list details,
.stats-grid {
  border: 1px solid var(--border);
  background: var(--surface-strong);
  box-shadow: var(--shadow-sm);
}

.feature-grid,
.article-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 16px;
}

.feature-card,
.article-card {
  position: relative;
  min-height: 232px;
  padding: 24px;
  border-radius: var(--radius-lg);
  transition: transform 0.2s ease, border-color 0.2s ease, box-shadow 0.2s ease;
}

.feature-card:hover,
.article-card:hover,
.screen-card:hover,
.step-card:hover {
  transform: translateY(-4px);
  border-color: var(--border-strong);
  box-shadow: var(--shadow);
}

.feature-icon {
  width: 48px;
  height: 48px;
  display: grid;
  place-items: center;
  border-radius: 14px;
  background: var(--bg-soft);
  font-size: 1.3rem;
}

.feature-card h3,
.article-card h3,
.step-card h3 {
  font-family: var(--font-display);
  position: relative;
  margin: 20px 0 8px;
  line-height: 1.35;
  font-size: 1.12rem;
  font-weight: 600;
}

.feature-card p,
.article-card p,
.step-card p {
  position: relative;
  margin: 0;
  color: var(--muted);
}

/* ═══════════════════════════════════════════════════════════════════════════
   Workflow
═══════════════════════════════════════════════════════════════════════════ */
.workflow-grid,
.why-grid,
.faq-grid {
  display: grid;
  grid-template-columns: 0.88fr 1.12fr;
  gap: 32px;
  align-items: start;
}

.steps { display: grid; gap: 14px; }

.step-card {
  position: relative;
  min-height: 140px;
  padding: 22px;
  border-radius: var(--radius-lg);
}

.step-card span {
  display: inline-grid;
  place-items: center;
  width: 38px;
  height: 38px;
  border-radius: 12px;
  color: var(--terracotta-strong);
  background: var(--bg-soft);
  font-family: var(--font-display);
  font-weight: 600;
}

.step-card h3 { margin-top: 15px; }

/* ═══════════════════════════════════════════════════════════════════════════
   Stats
═══════════════════════════════════════════════════════════════════════════ */
.stats { padding: 26px 0 66px; }

.stats-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 1px;
  border-radius: var(--radius-xl);
  padding: 0;
  overflow: hidden;
}

.stats-grid article {
  min-height: 140px;
  display: grid;
  place-items: center;
  text-align: center;
  padding: 20px;
  background: var(--surface-strong);
}

.stats-grid strong {
  font-family: var(--font-display);
  font-size: clamp(1.9rem, 4vw, 3rem);
  line-height: 1;
  letter-spacing: -0.01em;
  font-weight: 600;
}

.stats-grid span { display: block; margin-top: 8px; color: var(--muted); font-weight: 600; font-size: 0.92rem; }

/* ═══════════════════════════════════════════════════════════════════════════
   Why / compare
═══════════════════════════════════════════════════════════════════════════ */
.compare-card { overflow: hidden; border-radius: var(--radius-xl); }

.compare-row {
  display: grid;
  grid-template-columns: 1.1fr 0.72fr 0.72fr;
  gap: 10px;
  align-items: center;
  padding: 17px 20px;
  border-block-end: 1px solid var(--border);
}

.compare-row:last-child { border-block-end: 0; }

.compare-row.head {
  color: var(--muted-2);
  background: var(--bg-soft);
  font-size: 0.86rem;
  font-weight: 700;
}

.compare-row b { color: var(--sage-strong); font-size: 1.1rem; }
.compare-row em { color: var(--muted-2); font-style: normal; }

/* ═══════════════════════════════════════════════════════════════════════════
   FAQ
═══════════════════════════════════════════════════════════════════════════ */
.faq-list { display: grid; gap: 10px; }

.faq-list details { border-radius: var(--radius-lg); overflow: hidden; }

.faq-list summary {
  cursor: pointer;
  padding: 18px 20px;
  font-weight: 600;
  list-style: none;
  font-family: var(--font-display);
}

.faq-list summary::-webkit-details-marker { display: none; }
.faq-list summary::after { content: "+"; float: inline-end; font-weight: 700; color: var(--terracotta); }
.faq-list details[open] summary::after { content: "\2212"; }
.faq-list p { margin: 0; padding: 0 20px 20px; color: var(--muted); }

/* ═══════════════════════════════════════════════════════════════════════════
   Final CTA
═══════════════════════════════════════════════════════════════════════════ */
.final-cta { padding-top: 70px; }

.final-cta .container {
  text-align: center;
  padding: 58px 28px;
  border-radius: var(--radius-xl);
  border: 1px solid var(--border);
  background: var(--surface-strong);
  box-shadow: var(--shadow);
}

.final-cta h2 {
  font-family: var(--font-display);
  max-width: 640px;
  margin: 0 auto;
  font-size: clamp(1.9rem, 4vw, 2.7rem);
  line-height: 1.28;
  font-weight: 600;
}

.final-cta p { max-width: 560px; margin: 16px auto 26px; color: var(--muted); font-size: 1.02rem; }

/* ═══════════════════════════════════════════════════════════════════════════
   Footer
═══════════════════════════════════════════════════════════════════════════ */
.footer { position: relative; z-index: 1; padding: 22px 0 38px; color: var(--muted); }

.footer-card {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  padding: 22px;
  border: 1px solid var(--border);
  border-radius: 26px;
  background: var(--surface-strong);
  box-shadow: var(--shadow-sm);
}

.footer-brand { display: flex; align-items: center; gap: 14px; min-width: 0; }

.footer-logo {
  display: grid;
  width: 48px;
  height: 48px;
  flex: 0 0 48px;
  place-items: center;
  border: 1px solid var(--border);
  border-radius: 16px;
  background: var(--bg-soft);
}

.footer-logo img { width: 32px; height: 32px; }

.footer-copy strong { font-family: var(--font-display); display: block; color: var(--text); font-size: 1.02rem; font-weight: 600; }
.footer-copy p { max-width: 480px; margin: 4px 0 0; color: var(--muted); font-size: 0.93rem; line-height: 1.7; }

.footer-action { display: flex; align-items: center; gap: 12px; flex: 0 0 auto; }

.footer-label {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 0.8rem;
  font-weight: 700;
  color: var(--muted);
  white-space: nowrap;
}

.footer-label::before { content: ""; width: 7px; height: 7px; border-radius: 999px; background: var(--sage); }

.footer-email {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  direction: ltr;
  unicode-bidi: isolate;
  font-weight: 700;
  color: var(--text);
  padding: 11px 16px;
  border: 1px solid var(--border);
  border-radius: 999px;
  background: var(--bg-soft);
  transition: transform 0.2s ease, border-color 0.2s ease, background 0.2s ease;
  -webkit-user-select: text;
  user-select: text;
}

.footer-email span {
  display: grid;
  width: 24px;
  height: 24px;
  place-items: center;
  border-radius: 999px;
  background: var(--terracotta);
  color: #fffaf3;
  font-size: 0.78rem;
}

.footer-email:hover { transform: translateY(-1px); border-color: var(--border-strong); background: var(--surface-hover); }

.footer-nav {
  display: flex;
  flex-wrap: wrap;
  gap: 1rem 1.4rem;
  justify-content: center;
  margin-top: 1.4rem;
  padding-top: 1.2rem;
  border-top: 1px solid var(--border);
}

.footer-nav a { opacity: 0.8; text-decoration: none; color: inherit; font-size: 0.95rem; }
.footer-nav a:hover { opacity: 1; }

/* ═══════════════════════════════════════════════════════════════════════════
   Reveal-on-scroll, reduced motion
═══════════════════════════════════════════════════════════════════════════ */
.reveal { opacity: 0; transform: translateY(18px); transition: opacity 0.7s ease, transform 0.7s ease; }
.reveal.is-visible { opacity: 1; transform: translateY(0); }
.delay-1 { transition-delay: 0.08s; }
.delay-2 { transition-delay: 0.16s; }

.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;
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    scroll-behavior: auto !important;
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
  .reveal { opacity: 1; transform: none; }
}

/* bilingual show/hide */
[lang="en"] .lang-fa { display: none !important; }
[lang="fa"] .lang-en { display: none !important; }

/* text-selection policy: chrome stays non-selectable, real content stays selectable */
.sidebar, .sidebar *, .topbar, .topbar *, .nav, .nav *, .site-header, .site-header *,
.footer, .footer *, button, .btn, .tab, .badge, .status, .eyebrow, .plan-tag,
.nav-panel, .nav-actions, .brand, .footer-nav, .footer-nav *, label,
.tier-badge, .pr-tier, .sidebar-brand, .lang-switch, .icon-btn {
  -webkit-user-select: none; -moz-user-select: none; user-select: none;
}
input, textarea, select, [contenteditable="true"],
.prose, .prose *, .selectable, .selectable *,
.footer-email, .footer-email *, .contact-list, .contact-list *,
.msg-body, .ticket-body, .notif-body, .notification-body {
  -webkit-user-select: text; -moz-user-select: text; user-select: text;
}

/* ═══════════════════════════════════════════════════════════════════════════
   PUBLIC SUBPAGES — about / products / guide / contact / terms / privacy.
   Same paper material as the landing sections: a quiet centered hero, a
   readable prose measure, and cards that match the landing card idiom.
═══════════════════════════════════════════════════════════════════════════ */
.page-hero {
  position: relative;
  z-index: 1;
  padding: 136px 0 10px;
  text-align: center;
}

.page-hero h1 {
  font-family: var(--font-display);
  margin: 6px 0 14px;
  font-size: clamp(2.1rem, 1.5rem + 2.6vw, 3rem);
  line-height: 1.15;
  letter-spacing: -0.01em;
  font-weight: 600;
}

html[lang="fa"] .page-hero h1,
html[dir="rtl"] .page-hero h1 { line-height: 1.5; font-weight: 700; }

.page-hero p {
  max-width: 44rem;
  margin: 0 auto;
  color: var(--muted);
  font-size: 1.05rem;
  line-height: 1.85;
}

.page-body { position: relative; z-index: 1; padding: 30px 0 84px; }

.section-title {
  font-family: var(--font-display);
  text-align: center;
  margin: 3.2rem 0 1.1rem;
  font-size: clamp(1.45rem, 1.2rem + 1vw, 1.8rem);
  font-weight: 600;
}

.prose { max-width: 46rem; margin: 0 auto; line-height: 1.95; }
.prose h2 { font-family: var(--font-display); margin: 2.4rem 0 0.7rem; font-size: 1.4rem; font-weight: 600; }
.prose p { margin: 0.55rem 0; color: var(--text); opacity: 0.88; }
.prose ul { margin: 0.55rem 0; padding-inline-start: 1.35rem; }
.prose li { margin: 0.35rem 0; color: var(--text); opacity: 0.88; }
.prose a { color: var(--terracotta-strong); text-decoration: underline; text-underline-offset: 3px; }

.cards-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 16px;
  max-width: 62rem;
  margin: 1.2rem auto 0;
}

.info-card {
  border: 1px solid var(--border);
  background: var(--surface-strong);
  box-shadow: var(--shadow-sm);
  border-radius: var(--radius-lg);
  padding: 24px;
  transition: transform 0.2s ease, border-color 0.2s ease, box-shadow 0.2s ease;
}

.info-card:hover { transform: translateY(-4px); border-color: var(--border-strong); box-shadow: var(--shadow); }
.info-card h3 { font-family: var(--font-display); margin: 2px 0 8px; font-size: 1.1rem; font-weight: 600; }
.info-card p { margin: 0; color: var(--muted); line-height: 1.75; }

/* guide: numbered how-to steps (container scoped — the landing workflow owns bare .steps) */
.page-body .steps { max-width: 48rem; margin: 1.2rem auto 0; }

.step {
  display: flex;
  gap: 16px;
  align-items: flex-start;
  border: 1px solid var(--border);
  background: var(--surface-strong);
  box-shadow: var(--shadow-sm);
  border-radius: var(--radius-lg);
  padding: 20px 22px;
}

.step .num {
  flex: none;
  width: 38px;
  height: 38px;
  border-radius: 12px;
  display: grid;
  place-items: center;
  background: var(--bg-soft);
  color: var(--terracotta-strong);
  font-family: var(--font-display);
  font-weight: 600;
}

.step h3 { font-family: var(--font-display); margin: 2px 0 6px; font-size: 1.06rem; font-weight: 600; }
.step p { margin: 0; color: var(--muted); line-height: 1.75; }

/* guide: FAQ — same material as the landing .faq-list */
.faq { max-width: 48rem; margin: 1.2rem auto 0; display: grid; gap: 10px; }

.faq details {
  border: 1px solid var(--border);
  background: var(--surface-strong);
  box-shadow: var(--shadow-sm);
  border-radius: var(--radius-lg);
  overflow: hidden;
}

.faq summary { cursor: pointer; padding: 16px 20px; font-weight: 600; list-style: none; font-family: var(--font-display); }
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: "+"; float: inline-end; font-weight: 700; color: var(--terracotta); }
.faq details[open] summary::after { content: "\2212"; }
.faq .ans { padding: 0 20px 18px; color: var(--muted); line-height: 1.8; }
.faq .ans a { color: var(--terracotta-strong); text-decoration: underline; text-underline-offset: 3px; }

/* products: plan cards */
.plans {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 16px;
  max-width: 720px;
  margin: 1.2rem auto 0;
}

.plan {
  position: relative;
  border: 1px solid var(--border);
  background: var(--surface-strong);
  box-shadow: var(--shadow-sm);
  border-radius: var(--radius-xl);
  padding: 26px 24px;
  text-align: center;
}

.plan.featured { border-color: var(--terracotta); box-shadow: 0 0 0 1px var(--terracotta) inset, var(--shadow); }
.plan .plan-name { font-family: var(--font-display); font-size: 1.35rem; font-weight: 600; margin: 4px 0; }

.plan .plan-tag {
  display: inline-block;
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  color: #fffdf9;
  background: var(--terracotta-strong);
  border-radius: 999px;
  padding: 3px 12px;
  margin-bottom: 6px;
}

html[data-theme="dark"] .plan .plan-tag { color: #221d17; }

.plan ul { list-style: none; padding: 0; margin: 16px 0 0; display: grid; gap: 8px; text-align: start; }
.plan li { position: relative; padding-inline-start: 1.6rem; color: var(--text); opacity: 0.88; line-height: 1.65; }
.plan li::before { content: "\2713"; position: absolute; inset-inline-start: 0; color: var(--sage-strong); font-weight: 700; }

.plan .soon {
  margin-top: 18px;
  padding: 9px 12px;
  font-size: 0.85rem;
  font-weight: 700;
  color: var(--gold);
  background: color-mix(in srgb, var(--c-gold) 12%, transparent);
  border: 1px solid color-mix(in srgb, var(--c-gold) 35%, transparent);
  border-radius: 12px;
}

/* contact / terms / privacy: contact channel list */
.contact-list {
  list-style: none;
  padding: 0;
  max-width: 40rem;
  margin: 1.2rem auto 0;
  display: grid;
  gap: 12px;
}

.contact-list li {
  display: flex;
  align-items: center;
  gap: 12px;
  border: 1px solid var(--border);
  background: var(--surface-strong);
  box-shadow: var(--shadow-sm);
  border-radius: var(--radius-md);
  padding: 15px 18px;
}

.contact-list a { color: var(--terracotta-strong); }
.ph { color: var(--muted-2); font-style: italic; }

/* ═══════════════════════════════════════════════════════════════════════════
   Responsive
═══════════════════════════════════════════════════════════════════════════ */
@media (max-width: 1240px) {
  .nav { gap: 10px; }
  .nav-panel a { padding: 9px 10px; font-size: 0.88rem; }
}

@media (max-width: 1080px) {
  .hero-grid,
  .workflow-grid,
  .why-grid,
  .faq-grid {
    grid-template-columns: 1fr;
  }

  .hero-copy,
  .section-heading.align-start {
    text-align: center;
    margin-inline: auto;
  }

  .hero-actions,
  .trust-row { justify-content: center; }

  .hero-visual { width: 100%; max-width: 460px; margin-inline: auto; }

  .feature-grid,
  .article-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }

  .footer-card { flex-direction: column; align-items: stretch; text-align: start; }
  .footer-action { justify-content: space-between; flex-wrap: wrap; }

  /* the full inline nav (7 links + actions) needs ~1100px to fit on one line;
     below that, collapse to the hamburger panel */
  .nav { border-radius: 22px; height: auto; min-height: 62px; align-items: center; flex-wrap: wrap; }
  .brand { order: 1; }
  .nav-actions { order: 2; margin-inline-start: auto; }
  .nav-toggle { display: block; order: 3; }
  .nav-panel {
    order: 4; width: 100%; display: none; flex-direction: column;
    align-items: stretch; border-radius: 18px; padding: 8px; margin-top: 4px;
    background: var(--bg-soft);
  }
  .nav-panel.is-open { display: flex; }
  .nav-panel a { text-align: center; }
  .login-entry { display: none; }
}

@media (max-width: 860px) {
  .screen-grid, .stats-grid { grid-template-columns: 1fr; }
  .stats-grid article { padding: 22px; }
}

@media (max-width: 640px) {
  .container { width: min(100% - 26px, var(--container)); }
  .section { padding: 64px 0; }
  .site-header { padding: 10px 0; }

  /* keep the collapsed top bar a single compact row: brand — actions — hamburger */
  .nav { gap: 6px; padding: 8px; min-height: 56px; }
  html[dir="rtl"] .nav { padding: 8px 12px 8px 8px; }
  html[dir="ltr"] .nav { padding: 8px 8px 8px 12px; }
  .nav-actions { gap: 6px; }
  .nav-actions .btn-sm { padding: 9px 12px; font-size: 0.82rem; }
  .icon-btn, .lang-switch { height: 34px; min-width: 34px; font-size: 0.85rem; }
  .nav-toggle { width: 38px; height: 38px; border-radius: 12px; }

  .hero { padding-top: 50px; }
  .hero-subtitle { font-size: 1rem; }
  .btn-lg { width: 100%; }

  .page-hero { padding-top: 112px; }
  .cards-grid { grid-template-columns: 1fr; }
  .step { padding: 16px; }
  .plan { padding: 22px 18px; }

  .hero-visual { max-width: 320px; }
  .scene3d { min-height: 290px; }

  .feature-grid, .article-grid { grid-template-columns: 1fr; }
  .feature-card, .article-card { min-height: auto; }

  .compare-row { grid-template-columns: 1fr; gap: 4px; }
  .compare-row.head { display: none; }

  .final-cta .container { padding: 40px 18px; }

  .footer-card { padding: 18px; border-radius: 22px; }
  .footer-brand { align-items: flex-start; }
  .footer-action { align-items: stretch; gap: 10px; }
  .footer-email { width: 100%; justify-content: center; }
}

@media (max-width: 480px) {
  .section { padding: 50px 0; }
  .hero { padding-top: 40px; }
  .hero-actions .btn { flex: 1 1 auto; justify-content: center; }
  .brand { font-size: 0.95rem; gap: 8px; }
  .brand img { width: 30px; height: 30px; }
  .nav-actions .btn-sm { padding: 8px 10px; }

  .section-heading h2 { font-size: 1.5rem; }
  .section-heading p { font-size: 0.95rem; }

  .feature-card, .article-card { padding: 18px; }
  .step-card { padding: 18px; min-height: auto; }

  .stats-grid article { min-height: 108px; padding: 14px; }

  .compare-card { border-radius: 18px; }
  .compare-row { padding: 12px 14px; }

  .final-cta .container { padding: 30px 16px; border-radius: 20px; }
  .final-cta h2 { font-size: 1.55rem; }

  .footer-logo { width: 40px; height: 40px; flex-basis: 40px; }
  .footer-logo img { width: 26px; height: 26px; }
  .footer-email { padding: 10px 13px; font-size: 0.88rem; }
  .footer-nav { gap: 0.7rem 1rem; }
}

/* Very narrow phones: the icon alone carries the brand so the actions and
   hamburger keep comfortable tap targets on one row. */
@media (max-width: 384px) {
  .brand span { display: none; }
}
