:root {
  --bg: #efede7;
  --ink: #0d0d0d;
  --accent: #b5884a;
  --line: color-mix(in srgb, var(--ink) 14%, transparent);
  --soft: color-mix(in srgb, var(--ink) 55%, transparent);
  --ease: cubic-bezier(.22, 1, .36, 1);
  --fa: "Vazirmatn", system-ui, sans-serif;
  --en: -apple-system, BlinkMacSystemFont, "SF Pro Display", "SF Pro Text", "Inter Tight", "Helvetica Neue", Arial, sans-serif;
  --serif: var(--en);
  --font: var(--fa);
  --pad: clamp(16px, 4vw, 56px);
}
html[lang="en"] { --font: var(--en); }

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
html.lenis, html.lenis body { height: auto; }
.lenis.lenis-smooth { scroll-behavior: auto !important; }
body {
  margin: 0; background: var(--bg); color: var(--ink);
  font-family: var(--font); font-size: 17px; line-height: 1.8;
  -webkit-font-smoothing: antialiased; overflow-x: hidden;
}
html[lang="en"] body { line-height: 1.6; }
a { color: inherit; text-decoration: none; }
h1, h2, h3, p { margin: 0; }
img { display: block; max-width: 100%; }
::selection { background: var(--ink); color: var(--bg); }

.label {
  display: inline-flex; align-items: center; gap: 10px;
  font: 500 13px var(--en); letter-spacing: .14em; text-transform: uppercase; color: var(--soft);
}
html[lang="fa"] .label { font-family: var(--fa); letter-spacing: 0; font-size: 14px; }
.label::before { content: ""; width: 26px; height: 1px; background: currentColor; }

/* ---------- Cursor ---------- */
.cursor, .cursor-ring { position: fixed; top: 0; left: 0; pointer-events: none; z-index: 200; border-radius: 50%; display: none; }
.has-cursor .cursor, .has-cursor .cursor-ring { display: block; }
.has-cursor:not(.cursor-moved) .cursor, .has-cursor:not(.cursor-moved) .cursor-ring { opacity: 0; }
.has-cursor, .has-cursor a, .has-cursor button { cursor: none; }
.cursor { width: 6px; height: 6px; margin: -3px 0 0 -3px; background: var(--ink); }
.cursor-ring {
  width: 38px; height: 38px; margin: -19px 0 0 -19px; border: 1px solid var(--ink);
  display: none; place-items: center;
  transition: width .45s var(--ease), height .45s var(--ease), margin .45s var(--ease), background .3s, border-color .3s, opacity .3s;
}
.has-cursor .cursor-ring { display: grid; }
.cursor-ring.is-hover { width: 70px; height: 70px; margin: -35px 0 0 -35px; background: color-mix(in srgb, var(--ink) 8%, transparent); }
.cursor-ring.is-view { width: 96px; height: 96px; margin: -48px 0 0 -48px; background: var(--ink); border-color: var(--ink); }
.cursor-ring.is-hide { opacity: 0; }
.cursor-label { font: 300 26px var(--en); color: var(--bg); opacity: 0; transition: opacity .3s; }
.cursor-ring.is-view .cursor-label { opacity: 1; }

.progress { position: fixed; top: 0; inset-inline: 0; height: 2px; background: var(--ink); transform-origin: right; transform: scaleX(0); z-index: 120; }
html[dir="ltr"] .progress { transform-origin: left; }

/* ---------- Loader ---------- */
.loader { position: fixed; inset: 0; z-index: 300; background: var(--ink); color: var(--bg); display: grid; place-items: end start; padding: var(--pad); }
.loader__count { font: 200 clamp(80px, 18vw, 240px)/1 var(--font); font-variant-numeric: tabular-nums; }
.no-motion .loader { display: none; }

/* ---------- Header ---------- */
.top {
  position: fixed; inset-inline: 0; top: 0; z-index: 100; display: flex; align-items: center; justify-content: space-between;
  padding: 22px var(--pad); mix-blend-mode: difference; color: #fff;
}
.mono { font: 600 22px var(--en); letter-spacing: -.02em; }
.top__nav { display: flex; gap: 32px; font-size: 15px; }
.top__nav a { position: relative; }
.top__nav a::after { content: ""; position: absolute; inset-inline: 0; bottom: -2px; height: 1px; background: currentColor; transform: scaleX(0); transition: transform .5s var(--ease); }
.top__nav a:hover::after { transform: scaleX(1); }
.lang { background: none; border: 1px solid currentColor; color: inherit; border-radius: 99px; padding: 6px 14px; font: 500 13px var(--en); }
.lang span { opacity: .45; }
html[lang="fa"] .lang [data-lang="fa"], html[lang="en"] .lang [data-lang="en"] { opacity: 1; }
.lang [data-lang="fa"] { font-family: var(--fa); }

/* ---------- Hero ---------- */
.hero {
  position: relative; overflow: clip; min-height: 100svh;
  padding: 104px var(--pad) 32px; display: grid; grid-template-rows: auto 1fr auto; gap: 24px;
}
.hero > *:not(.hero__field) { position: relative; z-index: 1; }
.hero__field { position: absolute; inset: 0; width: 100%; height: 100%; z-index: 0; pointer-events: none; }

/* top row: role (start) · availability (end) */
.hero__top { display: flex; justify-content: space-between; align-items: center; gap: 16px; font-size: 14px; color: var(--soft); }
.hero__eyebrow, .hero__status { display: flex; align-items: center; gap: 10px; }
.dot { width: 8px; height: 8px; border-radius: 50%; background: var(--accent); }

/* middle: name on one line (wraps on small screens), rotating line under it — both flush to the start edge */
.hero__mid { display: flex; flex-direction: column; justify-content: center; gap: 3vh; }
.hero__name { display: flex; flex-wrap: wrap; column-gap: .22em; font-weight: 300; font-size: clamp(52px, 10.5vw, 184px); line-height: 1.1; letter-spacing: -.035em; }
html[lang="en"] .hero__name { font-size: clamp(48px, 8.2vw, 150px); line-height: .95; letter-spacing: -.055em; }
.hero__name .row { display: block; overflow: hidden; padding-block: .06em; }
.hero__name .w { display: inline-block; font-variation-settings: "wght" var(--wght, 300); font-weight: var(--wght, 300); will-change: transform; }
.w--accent { color: var(--accent); }
.hero__rot { font-size: clamp(20px, 2.1vw, 32px); font-weight: 300; color: var(--soft); display: flex; flex-wrap: wrap; align-items: baseline; gap: .35em; }
html[lang="en"] .hero__rot { letter-spacing: -.02em; }
.rot { display: inline-grid; color: var(--ink); font-weight: 500; }
.rot__w { grid-area: 1 / 1; white-space: nowrap; will-change: transform, opacity, filter; }
.rot__w::after { content: ""; display: inline-block; width: .5em; height: .08em; background: var(--accent); margin-inline-start: .15em; vertical-align: .2em; }

/* bottom bar: three aligned cells on one rule */
.hero__foot {
  display: grid; grid-template-columns: 1fr auto auto; align-items: center; gap: 40px;
  border-top: 1px solid var(--line); padding-top: 22px;
}
.hero__lead { font-size: clamp(15px, 1.2vw, 17px); color: var(--soft); max-width: 46ch; }
.hero__cta { display: inline-flex; align-items: center; gap: 12px; font-size: 16px; font-weight: 500; padding: 12px 22px; border: 1px solid var(--ink); border-radius: 99px; transition: background .4s var(--ease), color .4s var(--ease); }
.hero__cta { justify-self: start; white-space: nowrap; }
.hero__cta i { display: grid; transition: transform .4s var(--ease); }
html[dir="ltr"] .hero__cta i { transform: scaleX(-1); }
.hero__cta:hover { background: var(--ink); color: var(--bg); }
.hero__cta:hover i { transform: translateX(-4px); }
html[dir="ltr"] .hero__cta:hover i { transform: scaleX(-1) translateX(-4px); }
.badge { position: relative; width: 92px; height: 92px; display: grid; place-items: center; }
.badge svg { position: absolute; inset: 0; width: 100%; height: 100%; animation: spin 18s linear infinite; direction: ltr; }
.badge text { font: 500 9.5px var(--en); letter-spacing: .12em; fill: var(--ink); }
.badge__arrow { width: 38px; height: 38px; border-radius: 50%; background: var(--ink); color: var(--bg); display: grid; place-items: center; font: 400 16px var(--en); transition: transform .5s var(--ease); }
.badge:hover .badge__arrow { transform: translateY(4px) scale(1.08); }
@keyframes spin { to { transform: rotate(360deg); } }

/* ---------- Photo reveal ---------- */
.reveal { height: 190vh; position: relative; }
.reveal__sticky { position: sticky; top: 0; height: 100vh; overflow: hidden; display: flex; align-items: center; }
.reveal__grid { width: 100%; padding-inline: var(--pad); display: grid; grid-template-columns: 1fr auto; gap: 6vw; align-items: center; }
.reveal__photo { margin: 0; width: clamp(220px, 32vw, 440px); aspect-ratio: 1; border-radius: 50%; overflow: hidden; will-change: transform; background: #ccc; }
.reveal__photo img { width: 100%; height: 100%; object-fit: cover; }
.reveal__tag {
  display: inline-flex; align-items: center; gap: 10px; margin-bottom: 28px;
  font-size: 14px; padding: 7px 16px; border-radius: 99px; border: 1px solid var(--line); color: var(--soft);
}
.pulse { width: 8px; height: 8px; border-radius: 50%; background: #6fd59a; box-shadow: 0 0 0 0 rgba(111,213,154,.6); animation: ping 2s infinite; }
@keyframes ping { to { box-shadow: 0 0 0 10px rgba(111,213,154,0); } }
.reveal__quote { max-width: 20ch; font-size: clamp(24px, 3vw, 46px); font-weight: 400; line-height: 1.5; }
html[lang="en"] .reveal__quote { font: 300 clamp(32px, 4.4vw, 68px)/1.08 var(--serif); letter-spacing: -.035em; max-width: 20ch; }

/* ---------- About ---------- */
.about { padding: 12vh var(--pad) 10vh; min-height: 100vh; display: flex; flex-direction: column; justify-content: center; }
.about__grid { display: grid; grid-template-columns: 1fr 1.1fr; gap: 6vw; align-items: end; margin-top: 48px; }
.big7 b { display: block; font: 200 clamp(140px, 22vw, 340px)/.85 var(--font); letter-spacing: -.06em; }
.big7 b i { font-style: normal; font-weight: 300; font-size: .35em; vertical-align: top; color: var(--accent); }
.big7 > span { color: var(--soft); }
.about__text p { color: var(--ink); font-size: clamp(18px, 1.5vw, 22px); line-height: 1.9; margin-bottom: 40px; }
.facts { list-style: none; margin: 0; padding: 0; border-top: 1px solid var(--line); }
.facts li { display: flex; justify-content: space-between; gap: 18px; padding: 16px 0; border-bottom: 1px solid var(--line); align-items: baseline; }
.facts span { color: var(--soft); font-size: 14px; white-space: nowrap; }
.facts b { font-weight: 500; text-align: end; }

/* ---------- Horizontal expertise ---------- */
.hz { height: 100vh; overflow: hidden; display: flex; align-items: center; border-top: 1px solid var(--line); }
.hz__track { display: flex; gap: 2vw; padding-inline: var(--pad); align-items: stretch; will-change: transform; width: max-content; }
.hz__intro { flex: 0 0 min(560px, 80vw); display: flex; flex-direction: column; justify-content: space-between; padding-block: 8px; }
.hz__intro h2 { font-size: clamp(44px, 6vw, 96px); font-weight: 300; line-height: 1.15; letter-spacing: -.03em; margin-top: 24px; }
html[lang="en"] .hz__intro h2 { font: 300 clamp(52px, 7vw, 110px)/.95 var(--serif); letter-spacing: -.035em; }
.hz__hint { color: var(--soft); font-size: 14px; margin-top: 30px; }
.hz__card {
  flex: 0 0 min(400px, 78vw); height: min(62vh, 520px); padding: 32px; border-radius: 28px;
  border: 1px solid var(--line); display: flex; flex-direction: column; justify-content: flex-end; position: relative; overflow: hidden;
  transition: background .6s var(--ease), color .6s var(--ease);
}
.hz__card .n { position: absolute; top: 18px; inset-inline-end: 26px; font: 200 110px/1 var(--font); color: var(--line); transition: color .6s var(--ease); }
.hz__card h3 { font-size: clamp(22px, 2vw, 28px); font-weight: 600; line-height: 1.35; margin-bottom: 12px; }
.hz__card p { color: var(--soft); font-size: 15.5px; transition: color .6s; }
.hz__card:hover { background: var(--ink); color: var(--bg); }
.hz__card:hover p { color: color-mix(in srgb, var(--bg) 65%, transparent); }
.hz__card:hover .n { color: var(--accent); }
.no-motion .hz { height: auto; padding: 14vh 0; }
.no-motion .hz__track { flex-wrap: wrap; }

/* ---------- Ventures (stack) ---------- */
.ventures { padding: 18vh var(--pad) 10vh; }
.ventures__head { margin-bottom: 8vh; }
.stack { display: grid; grid-template-columns: repeat(3, 1fr); gap: 18px; perspective: 1200px; }
.vcard {
  position: relative; min-height: 360px; border-radius: 24px; padding: 28px;
  background: #171717; color: #ecebe7; display: flex; flex-direction: column; gap: 14px;
  border: 1px solid rgba(255,255,255,.08); transform-style: preserve-3d; will-change: transform;
  transition: border-color .5s var(--ease), background .5s var(--ease);
}
.vcard:hover { border-color: color-mix(in srgb, var(--accent) 60%, transparent); }
.vcard::before {
  content: ""; position: absolute; inset: 0; border-radius: inherit; pointer-events: none; opacity: 0; transition: opacity .5s var(--ease);
  background: radial-gradient(380px circle at var(--mx, 50%) var(--my, 0%), rgba(181,136,74,.16), transparent 60%);
}
.vcard:hover::before { opacity: 1; }
.vcard > * { position: relative; }
.vcard__meta { display: flex; justify-content: space-between; font-size: 13px; color: rgba(236,235,231,.5); margin-bottom: auto; }
.vcard h3 { font-size: clamp(32px, 3.4vw, 52px); font-weight: 300; letter-spacing: -.03em; line-height: 1.15; margin-top: 64px; }
html[lang="en"] .vcard h3 { font: 300 clamp(34px, 3.6vw, 56px)/1 var(--serif); letter-spacing: -.035em; }
.vcard p { color: rgba(236,235,231,.68); font-size: 15px; line-height: 1.75; }
.vcard__url { font: 400 15px var(--en); color: var(--accent); }

/* ---------- Journey ---------- */
.journey { padding: 16vh var(--pad); }
.journey__wrap { position: relative; margin-top: 8vh; padding-inline-start: 44px; }
.journey__line { position: absolute; inset-inline-start: 0; top: 10px; bottom: 10px; width: 1px; background: var(--line); }
.journey__line i { position: absolute; inset: 0; background: var(--accent); transform-origin: top; transform: scaleY(0); }
.no-motion .journey__line i { transform: none; }
.journey__list { list-style: none; margin: 0; padding: 0; }
.journey__list li { display: grid; grid-template-columns: 1fr 1.1fr; gap: 24px; align-items: baseline; padding: 3.2vh 0; border-bottom: 1px solid var(--line); position: relative; }
.journey__list li::before { content: ""; position: absolute; inset-inline-start: -48.5px; top: calc(3.2vh + .9em); width: 9px; height: 9px; border-radius: 50%; background: var(--bg); border: 1px solid var(--accent); }
.journey__list li.now::before { background: var(--accent); }
.journey__list b { font-size: clamp(22px, 2.6vw, 38px); font-weight: 400; letter-spacing: -.01em; }
.journey__list span { color: var(--soft); }
.journey__list li.now b { color: var(--accent); }

/* ---------- Services ---------- */
.services { padding: 8vh var(--pad) 18vh; }
.services__grid { display: grid; grid-template-columns: 1fr 1fr; gap: 6vw; margin-top: 6vh; }
.svc { border-top: 1px solid var(--line); padding-top: 28px; }
.svc h3 { font-size: clamp(36px, 4.4vw, 72px); font-weight: 300; margin-bottom: 16px; letter-spacing: -.02em; }
html[lang="en"] .svc h3 { font: 300 clamp(44px, 5vw, 84px)/1 var(--serif); letter-spacing: -.035em; }
.svc p { color: var(--soft); max-width: 42ch; }

/* ---------- Contact ---------- */
.contact { min-height: 100vh; padding: 18vh var(--pad) 0; display: flex; flex-direction: column; position: relative; overflow: hidden; }
.contact__title { font-size: clamp(48px, 9vw, 160px); font-weight: 300; line-height: 1.12; letter-spacing: -.04em; }
html[lang="en"] .contact__title { font: 300 clamp(56px, 10vw, 180px)/.92 var(--serif); letter-spacing: -.035em; }
.contact__title em { font-style: normal; color: var(--accent); }
html[lang="en"] .contact__title em { font-style: italic; }
.blob {
  align-self: flex-end; margin-top: -6vh; width: clamp(150px, 15vw, 220px); aspect-ratio: 1; border-radius: 50%;
  background: var(--accent); color: #0d0d0d; display: grid; place-items: center; text-align: center; padding: 18px;
  font-weight: 600; font-size: 16px; line-height: 1.4; will-change: transform; position: relative; z-index: 2;
}
.contact__links { list-style: none; margin: 8vh 0 0; padding: 0; display: flex; flex-wrap: wrap; gap: 14px 40px; }
.contact__links a { font: 400 clamp(17px, 1.6vw, 22px) var(--en); position: relative; }
.contact__links a::after { content: ""; position: absolute; inset-inline: 0; bottom: -3px; height: 1px; background: currentColor; transform: scaleX(.0); transform-origin: left; transition: transform .5s var(--ease); }
.contact__links a:hover::after { transform: scaleX(1); }
.ticker { margin-top: auto; padding-top: 10vh; overflow: hidden; direction: ltr; }
.ticker__t { display: flex; gap: 40px; width: max-content; align-items: center; font: 300 clamp(60px, 9vw, 150px)/1.1 var(--en); letter-spacing: -.03em; white-space: nowrap; animation: tick 40s linear infinite; color: color-mix(in srgb, var(--ink) 22%, transparent); }
.ticker__t i { font-style: normal; font-size: .35em; color: var(--accent); }
@keyframes tick { to { transform: translateX(-50%); } }
.foot { display: flex; justify-content: space-between; gap: 16px; flex-wrap: wrap; padding: 24px 0; font-size: 13px; color: var(--soft); border-top: 1px solid var(--line); }

/* ---------- Responsive ---------- */
@media (max-width: 860px) {
  body { font-size: 16px; }
  .top { padding: 14px var(--pad); mix-blend-mode: normal; color: var(--ink); background: color-mix(in srgb, var(--bg) 88%, transparent); backdrop-filter: blur(12px); -webkit-backdrop-filter: blur(12px); border-bottom: 1px solid var(--line); }
  .top__nav { display: none; }

  /* hero: big two-line name, rotating line on its own row, simple footer (no badge) */
  .hero { padding: 84px var(--pad) 28px; gap: 16px; }
  .hero__top { font-size: 12.5px; }
  .hero__mid { gap: 18px; }
  .hero__name { font-size: clamp(56px, 17vw, 96px); line-height: 1.15; flex-direction: column; }
  html[lang="en"] .hero__name { font-size: clamp(48px, 14.5vw, 84px); line-height: 1; }
  .hero__rot { display: block; font-size: 20px; line-height: 1.6; }
  .hero__rot .rot { display: grid; margin-top: 2px; }
  .hero__foot { grid-template-columns: 1fr; gap: 16px; padding-top: 18px; }
  .hero__lead { font-size: 15px; }
  .hero__cta { justify-self: stretch; justify-content: space-between; }
  .badge { display: none; }

  /* photo + quote: normal flow, no sticky pin */
  .reveal { height: auto; padding: 10vh 0 6vh; }
  .reveal__sticky { position: static; height: auto; overflow: visible; }
  .reveal__grid { grid-template-columns: 1fr; gap: 28px; }
  .reveal__photo { order: -1; width: min(70vw, 300px); justify-self: center; }
  .reveal__text { text-align: center; }
  .reveal__quote { margin-inline: auto; font-size: 24px; }

  /* about */
  .about { min-height: 0; padding: 10vh var(--pad) 8vh; }
  .about__grid, .services__grid { grid-template-columns: 1fr; gap: 32px; margin-top: 28px; }
  .big7 b { font-size: 150px; }
  .about__text p { font-size: 17px; }

  /* expertise: vertical list instead of the horizontal pinned track */
  .hz { height: auto; overflow: visible; display: block; padding: 10vh 0; }
  .hz__track { width: auto; flex-direction: column; gap: 14px; transform: none !important; }
  .hz__intro { flex: none; margin-bottom: 20px; }
  .hz__intro h2 { font-size: 40px; }
  .hz__hint { display: none; }
  .hz__card { flex: none; height: auto; min-height: 0; padding: 92px 24px 24px; border-radius: 22px; }
  .hz__card .n { font-size: 72px; top: 14px; inset-inline-end: 20px; }

  .ventures { padding: 10vh var(--pad) 6vh; }
  .ventures__head { margin-bottom: 4vh; }
  .stack { grid-template-columns: 1fr; }
  .vcard { min-height: 250px; }
  .vcard h3 { margin-top: 36px; }

  .journey { padding: 10vh var(--pad); }
  .journey__wrap { padding-inline-start: 30px; margin-top: 5vh; }
  .journey__list li { grid-template-columns: 1fr; gap: 2px; padding: 2.4vh 0; }
  .journey__list li::before { inset-inline-start: -34.5px; top: calc(2.4vh + .75em); }
  .journey__list b { font-size: 22px; }

  .services { padding: 4vh var(--pad) 10vh; }
  .svc h3 { font-size: 34px; }

  .contact { min-height: 0; padding: 12vh var(--pad) 0; }
  .contact__title { font-size: 44px; }
  .blob { margin-top: 5vh; align-self: flex-start; width: 132px; font-size: 14px; }
  .contact__links { margin-top: 6vh; flex-direction: column; gap: 14px; }
  .contact__links a { font-size: 17px; }
  .ticker { padding-top: 7vh; }
  .ticker__t { font-size: 56px; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition-duration: .01ms !important; }
}
