/* salehiali theme. Layout: dark hero with a giant moving name over an arched portrait, then alternating light/dark bands: statement, three colour cards, work list, writing, big contact footer. Deliberately one visual world, so colours are fixed. */
:root {
  --ink: #141518;
  --ink-2: #1e2024;
  --ink-line: #2c2f35;
  --paper: #f4f0ea;
  --white: #ffffff;
  --muted: #6b707a;
  --muted-dark: #9aa0ab;
  --saffron: #ffb000;
  --turquoise: #0fa3a3;
  --pomegranate: #e8384f;
  --sand: #e4d4be;
  --fa: "Vazirmatn", Tahoma, system-ui, sans-serif;
  --en-display: "Unbounded", "Vazirmatn", system-ui, sans-serif;
  --en-body: "DM Sans", "Vazirmatn", system-ui, sans-serif;
  --display: var(--fa);
  --body: var(--fa);
  color-scheme: dark;
}
.site[lang="en"] { --display: var(--en-display); --body: var(--en-body); }

* { box-sizing: border-box; }
[hidden] { display: none !important; }
html { scroll-behavior: smooth; }
body { background: var(--ink); color: var(--white); margin: 0; }
.site { font-family: var(--body); font-size: 17px; line-height: 1.8; overflow-x: clip; }
h1, h2, h3, p { margin: 0; }
h1, h2, h3 { text-wrap: balance; }
a { color: inherit; text-decoration: none; }
button { font: inherit; }
.wrap { max-width: 1240px; margin: 0 auto;
  padding-left: max(20px, env(safe-area-inset-left, 0px));
  padding-right: max(20px, env(safe-area-inset-right, 0px)); }
:focus-visible { outline: 2px solid var(--saffron); outline-offset: 3px; border-radius: 6px; }

/* ---------- nav ---------- */
.nav { position: absolute; inset: 0 0 auto; z-index: 20; padding-top: calc(env(safe-area-inset-top, 0px) + 22px); }
.nav .wrap { display: flex; align-items: center; justify-content: space-between; gap: 16px; }
.logo { font-family: var(--display); font-weight: 800; font-size: 1.05rem; display: inline-flex; align-items: center; gap: 8px; color: var(--hero-fg); }
.logo i { width: 9px; height: 9px; border-radius: 50%; background: var(--hero-accent); display: block; }
.links { display: flex; align-items: center; gap: clamp(12px, 2.4vw, 30px); font-size: .95rem; font-weight: 500; color: var(--hero-fg); }
.links a { position: relative; }
.links a::after { content: ""; position: absolute; inset-inline: 0; bottom: -2px; height: 2px; background: currentColor; transform: scaleX(0); transition: transform .3s ease; }
.links a:hover::after { transform: scaleX(1); }
.links .lang { border: 1.5px solid currentColor; border-radius: 999px; padding: 0 12px; line-height: 1.9; font-size: .85rem; font-weight: 700; transition: background .25s, color .25s; }
.links .lang[lang="en"] { font-family: var(--en-body); }
.links .lang[lang="fa"] { font-family: var(--fa); }
.links .lang::after { display: none; }
.links .lang:hover { background: var(--hero-fg); color: var(--ink); }
.links a[aria-current]::after { transform: scaleX(1); }

/* ---------- hero ---------- */
/* Hero tokens: dark charcoal, chosen by the owner. */
.site { --hero-bg: #141518; --hero-fg: #ffffff; --hero-sub: rgb(255 255 255 / .7); --hero-accent: var(--saffron); --hero-pill: #2a2d33; }
.hero { position: relative; overflow: hidden; color: var(--hero-fg); background: var(--hero-bg); transition: background .4s; }
/* Soft ambient light behind the portrait: wide and faint, so its edge never shows around the shoulders. */
.hero::before { content: ""; position: absolute; inset: 0; background: radial-gradient(ellipse 60% 95% at 50% 88%, rgb(255 255 255 / .085), rgb(255 255 255 / .035) 45%, transparent 75%); pointer-events: none; }
.hero-grid { position: relative; display: grid; grid-template-columns: 1.35fr minmax(300px, 520px) .65fr; gap: clamp(16px, 2vw, 32px); padding-top: 104px; }
.lede { position: relative; z-index: 3; display: grid; gap: 18px; justify-self: start; align-self: center; padding-bottom: 6%; }
.lede h1 { font-family: var(--display); font-size: clamp(2rem, 3vw, 2.9rem); font-weight: 900; line-height: 1.35; }
.site[lang="en"] .lede h1 { font-weight: 800; line-height: 1.12; letter-spacing: -.01em; }
.lede p { color: var(--hero-sub); font-size: 1rem; font-weight: 500; }
.portrait { align-self: end; position: relative; z-index: 2; }
.portrait img { display: block; width: 100%; height: auto; will-change: transform; filter: drop-shadow(0 30px 40px rgb(0 0 0 / .28)); }
.locate { position: relative; z-index: 3; display: inline-flex; align-items: center; gap: 12px; background: var(--hero-pill); color: var(--white); border-radius: 999px; padding: 10px 12px 10px 18px; font-size: .9rem; line-height: 1.5; justify-self: end; align-self: center; margin-bottom: 6%; }
.site[dir="rtl"] .locate { padding: 10px 18px 10px 12px; }
.locate span { white-space: nowrap; }
@media (max-width: 1200px) and (min-width: 861px) { .locate { font-size: .78rem; gap: 8px; } .globe { width: 30px; height: 30px; } }
.globe { width: 38px; height: 38px; border-radius: 50%; background: var(--saffron); display: grid; place-items: center; flex: none; }
.globe svg { width: 22px; height: 22px; animation: spin 9s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }
.spark { position: relative; color: var(--hero-accent); white-space: nowrap; }
.spark svg { position: absolute; fill: var(--hero-accent); animation: twinkle 2.6s ease-in-out infinite; pointer-events: none; }
.spark svg:nth-of-type(1) { width: 26px; height: 26px; top: -18px; inset-inline-end: -22px; }
.spark svg:nth-of-type(2) { width: 16px; height: 16px; bottom: -6px; inset-inline-start: -20px; animation-delay: .9s; fill: var(--hero-fg); }
.spark svg:nth-of-type(3) { width: 12px; height: 12px; top: -20px; inset-inline-start: 35%; animation-delay: 1.6s; }
@keyframes twinkle { 0%, 100% { transform: scale(.3) rotate(0); opacity: 0; } 50% { transform: scale(1) rotate(90deg); opacity: 1; } }

/* ---------- statement ---------- */
.light { background: var(--paper); color: var(--ink); }
.statement { padding-block: clamp(72px, 10vw, 140px); display: grid; grid-template-columns: 1.6fr 1fr; gap: clamp(28px, 6vw, 90px); align-items: start; }
.statement h2 { font-family: var(--display); font-size: clamp(1.6rem, 3.3vw, 2.7rem); font-weight: 700; line-height: 1.5; }
.site[lang="en"] .statement h2 { font-weight: 400; line-height: 1.3; }
.statement h2 em { font-style: normal; background: linear-gradient(transparent 62%, color-mix(in srgb, var(--saffron) 70%, transparent) 0); }
.statement aside { display: grid; gap: 28px; color: #3d4048; font-size: 1rem; }

/* ---------- services ---------- */
.services { padding-bottom: clamp(72px, 10vw, 140px); display: grid; gap: 28px; }
.eyebrow { font-size: .8rem; letter-spacing: .08em; text-transform: uppercase; color: var(--muted); display: flex; align-items: center; gap: 12px; }
.eyebrow::after { content: ""; flex: 1; height: 1px; background: #c9ccd3; }
.dark .eyebrow { color: var(--muted-dark); }
.dark .eyebrow::after { background: var(--ink-line); }
.cards { display: grid; grid-template-columns: repeat(3, 1fr); gap: 18px; }
.card { border-radius: 28px; padding: clamp(22px, 3vw, 34px); min-height: 330px; display: grid; grid-template-rows: auto 1fr auto; gap: 18px; color: var(--ink); transition: transform .35s cubic-bezier(.2, .9, .3, 1.4); }
.card:nth-child(1) { background: var(--saffron); }
.card:nth-child(2) { background: var(--turquoise); color: var(--white); }
.card:nth-child(3) { background: var(--pomegranate); color: var(--white); }
.card:nth-child(1):hover { transform: rotate(-2deg) translateY(-6px); }
.card:nth-child(2):hover { transform: rotate(1.5deg) translateY(-6px); }
.card:nth-child(3):hover { transform: rotate(-1.5deg) translateY(-6px); }
.card h3 { font-family: var(--display); font-size: clamp(1.9rem, 3.4vw, 2.8rem); font-weight: 900; line-height: 1.2; }
.site[lang="en"] .card h3 { font-weight: 800; }
.card p { font-size: .98rem; }
.card .tags { display: flex; flex-wrap: wrap; gap: 6px; }
.card .tags span { border: 1.5px solid currentColor; border-radius: 999px; padding: 0 10px; font-size: .8rem; font-weight: 500; }
.card .shape { width: 54px; height: 54px; }

/* ---------- work ---------- */
.dark { background: var(--ink); color: var(--white); }
.work { padding-block: clamp(72px, 10vw, 140px); display: grid; gap: 22px; position: relative; }
.rows { list-style: none; margin: 0; padding: 0; }
.row { display: grid; grid-template-columns: 1fr auto auto auto; gap: 24px; align-items: center; padding: clamp(22px, 3vw, 38px) 6px; border-bottom: 1px solid var(--ink-line); transition: padding .35s ease, opacity .3s; }
.rows:hover .row { opacity: .45; }
.rows .row:hover, .rows .row:focus-visible { opacity: 1; padding-inline-start: 22px; }
.row .go { width: 44px; height: 44px; border-radius: 50%; border: 1px solid var(--ink-line); display: grid; place-items: center; transition: background .3s, border-color .3s, transform .3s; }
.row .go svg { width: 18px; height: 18px; }
.site[dir="rtl"] .row .go svg { transform: scaleX(-1); }
.row:hover .go, .row:focus-visible .go { background: var(--saffron); border-color: var(--saffron); color: var(--ink); transform: rotate(-8deg); }
.row h3 { font-family: var(--display); font-size: clamp(1.5rem, 3.6vw, 3rem); font-weight: 800; line-height: 1.2; }
.site[lang="en"] .row h3 { font-weight: 600; }
.row .kind { color: var(--muted-dark); font-size: .95rem; }
.row .year { color: var(--muted-dark); font-size: .95rem; font-variant-numeric: tabular-nums; min-width: 6.5em; text-align: end; }

/* ---------- writing ---------- */
.writing { padding-block: clamp(72px, 10vw, 140px); display: grid; gap: 28px; }
.writing-head { display: flex; justify-content: space-between; align-items: end; gap: 16px; flex-wrap: wrap; }
.writing-head h2 { font-family: var(--display); font-size: clamp(1.8rem, 4vw, 3rem); font-weight: 900; }
.site[lang="en"] .writing-head h2 { font-weight: 800; }
.draft { font-size: .82rem; color: var(--muted); border: 1px dashed #b7bbc4; border-radius: 999px; padding: 2px 12px; }
.posts { display: grid; grid-template-columns: repeat(3, 1fr); gap: 18px; }
.post { background: var(--white); border-radius: 22px; padding: 26px; display: grid; gap: 14px; align-content: start; transition: transform .3s ease, box-shadow .3s ease; }
.post:hover { transform: translateY(-6px); box-shadow: 0 22px 40px -26px rgb(20 21 24 / .5); }
.post .dot { width: 12px; height: 12px; border-radius: 50%; }
.post h3 { font-size: 1.2rem; font-weight: 800; line-height: 1.55; }
.site[lang="en"] .post h3 { font-family: var(--en-body); font-weight: 700; line-height: 1.35; }
.post p { color: var(--muted); font-size: .95rem; }

/* ---------- footer ---------- */
.contact { padding-block: clamp(80px, 11vw, 150px) 40px; display: grid; gap: clamp(36px, 6vw, 70px); }
.contact-top { display: flex; align-items: center; gap: clamp(16px, 3vw, 28px); flex-wrap: wrap; }
.avatar { width: clamp(64px, 8vw, 96px); aspect-ratio: 1; border-radius: 50%; overflow: hidden; background: var(--saffron); flex: none; }
.avatar img { width: 100%; height: 100%; object-fit: cover; object-position: 50% 0; display: block; transform: scale(1.9) translateY(22%); }
.contact h2 { font-family: var(--display); font-size: clamp(2.2rem, 7vw, 6rem); font-weight: 900; line-height: 1.2; }
.site[lang="en"] .contact h2 { font-weight: 800; line-height: 1.05; }
.contact-mid { position: relative; border-top: 1px solid var(--ink-line); padding-top: 40px; display: flex; flex-wrap: wrap; gap: 14px; align-items: center; }
.pill { border: 1px solid #3a3e46; border-radius: 999px; padding: 12px 22px; color: var(--white); background: transparent; cursor: pointer; font-family: var(--en-body); font-size: 1rem; direction: ltr; transition: background .25s, color .25s; }
.pill:hover { background: var(--white); color: var(--ink); }
.contact-foot { display: flex; justify-content: space-between; gap: 16px; flex-wrap: wrap; color: var(--muted-dark); font-size: .85rem; padding-top: 30px; }
.contact-foot nav { display: flex; gap: 20px; }


@media (max-width: 860px) {
  .hero-grid { grid-template-columns: 1fr; justify-items: center; text-align: center; padding-top: 88px; gap: 18px; }
  .locate { order: 1; margin: 0; justify-self: center; font-size: .8rem; }
  .lede { order: 2; padding: 0; justify-self: center; justify-items: center; }
  .portrait { order: 3; width: min(100%, 460px); }
  .statement, .cards, .posts { grid-template-columns: 1fr; }
  .card { min-height: 0; }
  .row { grid-template-columns: 1fr auto auto; gap: 14px; }
  .row .go { width: 36px; height: 36px; }
  .row .kind { display: none; }
  .links a:not(.lang) { display: none; }
}
@media (prefers-reduced-motion: reduce) {
  .globe svg, .spark svg { animation: none; }
  .card, .post, .row, .talk, .toast { transition: none; }
  html { scroll-behavior: auto; }
}

/* ---------- links that look like buttons/cards ---------- */
a.post { color: inherit; }

/* ---------- generic pages (until they get their own design) ---------- */
.page-shell { background: var(--paper); color: var(--ink); padding-block: calc(env(safe-area-inset-top, 0px) + 140px) 100px; }
.page-content { max-width: 760px; display: grid; gap: 24px; }
.page-content h1 { font-family: var(--display); font-size: clamp(2rem, 5vw, 3.2rem); font-weight: 900; line-height: 1.3; }
.page-content .entry { font-size: 1.05rem; line-height: 2; }
.page-content .entry a { text-decoration: underline; }
body:not(.home) .nav { background: var(--ink); position: absolute; }

/* ---------- project page ---------- */
/* ---------- project views ---------- */
.p-hero { padding-block: calc(env(safe-area-inset-top, 0px) + 120px) clamp(48px, 6vw, 72px); }
.crumb { font-size: .9rem; color: var(--muted-dark); display: flex; gap: 8px; margin-bottom: 28px; }
.crumb a:hover { color: var(--white); }
.p-grid { display: grid; grid-template-columns: 1fr minmax(280px, 360px); gap: clamp(28px, 5vw, 72px); align-items: end; }
.p-head { display: grid; gap: 18px; min-width: 0; }
.badge { justify-self: start; border-radius: 999px; padding: 2px 14px; font-size: .85rem; font-weight: 700; color: var(--ink); }
.badge.product { background: var(--saffron); } .badge.service { background: var(--turquoise); color: var(--white); }
.p-head h1 { font-family: var(--display); font-size: clamp(2.8rem, 7vw, 5.6rem); font-weight: 900; line-height: 1.15; }
.site[lang="en"] .p-head h1 { font-weight: 800; line-height: 1.02; letter-spacing: -.02em; }
.pitch { font-size: clamp(1.05rem, 1.6vw, 1.3rem); color: #d4d7dd; max-width: 46ch; }
.meta { display: flex; flex-wrap: wrap; gap: 8px; }
.meta span { border: 1px solid var(--ink-line); border-radius: 999px; padding: 2px 12px; font-size: .85rem; color: var(--muted-dark); }
.action { background: var(--white); color: var(--ink); border-radius: 24px; padding: 26px; display: grid; gap: 16px; }
.price { font-family: var(--display); font-size: 1.9rem; font-weight: 900; line-height: 1.3; }
.site[lang="en"] .price { font-weight: 800; font-size: 1.6rem; }
.price-note { font-size: .85rem; color: var(--muted); margin-top: -10px; }
.cta { display: inline-flex; justify-content: center; align-items: center; gap: 10px; background: var(--ink); color: var(--white); border: 0; border-radius: 999px; padding: 14px 22px; font-weight: 700; cursor: pointer; transition: background .25s, transform .25s; }
.cta:hover { background: var(--pomegranate); transform: translateY(-2px); }
.cta svg { width: 18px; height: 18px; }
.site[dir="rtl"] .cta svg { transform: scaleX(-1); }
.points { list-style: none; margin: 0; padding: 0; display: grid; gap: 8px; font-size: .92rem; }
.points li { display: flex; gap: 10px; align-items: baseline; }
.points li::before { content: ""; width: 8px; height: 8px; border-radius: 50%; background: var(--turquoise); flex: none; transform: translateY(-1px); }
.stats { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.stats div { display: grid; gap: 2px; }
.stats b { font-family: var(--display); font-size: 1.7rem; font-weight: 900; line-height: 1.3; }
.stats span { font-size: .82rem; color: var(--muted); line-height: 1.5; }
.shot-band { background: linear-gradient(var(--ink) 0 45%, var(--paper) 45% 100%); padding-bottom: clamp(48px, 7vw, 96px); }
.frame { border-radius: 18px; overflow: hidden; background: var(--white); box-shadow: 0 40px 80px -40px rgb(0 0 0 / .6); border: 1px solid #2c2f35; }
.frame-bar { display: flex; gap: 6px; padding: 10px 14px; background: #ecebe8; direction: ltr; }
.frame-bar i { width: 10px; height: 10px; border-radius: 50%; background: #cfcac2; display: block; }
.frame img { display: block; width: 100%; height: auto; }
img[data-zoom] { cursor: zoom-in; }
.zoom { border: 0; padding: 0; background: transparent; max-width: none; max-height: none; width: 100vw; height: 100vh; margin: 0; }
.zoom::backdrop { background: rgb(10 11 13 / .88); }
.zoom-inner { width: 100%; height: 100%; overflow: auto; display: grid; place-items: center; padding: max(16px, env(safe-area-inset-top, 0px)) max(16px, env(safe-area-inset-right, 0px)) max(16px, env(safe-area-inset-bottom, 0px)) max(16px, env(safe-area-inset-left, 0px)); cursor: zoom-out; }
.zoom img { display: block; max-width: none; width: min(1360px, 100%); height: auto; border-radius: 10px; box-shadow: 0 30px 80px -20px rgb(0 0 0 / .7); }
.zoom-close { position: fixed; top: calc(14px + env(safe-area-inset-top, 0px)); inset-inline-end: max(14px, env(safe-area-inset-right, 0px)); width: 44px; height: 44px; border-radius: 50%; border: 0; background: var(--white); color: var(--ink); font-size: 1.4rem; line-height: 1; cursor: pointer; }

.next { padding-block: clamp(64px, 9vw, 120px); }
.next a { display: grid; gap: 6px; justify-items: start; }
.next small { color: var(--muted-dark); font-size: .95rem; }
.next span { font-family: var(--display); font-size: clamp(2.6rem, 8vw, 6rem); font-weight: 900; line-height: 1.15; display: inline-flex; align-items: center; gap: .3em; transition: color .3s; }
.site[lang="en"] .next span { font-weight: 800; }
.next a:hover span { color: var(--saffron); }
.next svg { width: .6em; height: .6em; flex: none; }
.site[dir="rtl"] .next svg { transform: scaleX(-1); }
@media (prefers-reduced-motion: reduce) { .cta, .next span { transition: none; } }
.p-grid.no-action { grid-template-columns: 1fr; }
.cta.is-soon { background: #e9e5de; color: var(--muted); cursor: default; }
.cta.is-soon:hover { background: #e9e5de; transform: none; }
.soon-note { font-size: .82rem; color: var(--muted); margin-top: -6px; }
.shot-band .frame img { cursor: zoom-in; }

/* ---------- project body (block editor content) ---------- */
.project-body { padding-bottom: clamp(64px, 8vw, 110px); }
.pj-content { display: grid; gap: clamp(56px, 7vw, 96px); }
/* Classic themes get an extra inner wrapper inside group blocks; let the grids see the real items. */
.pj-content .wp-block-group__inner-container { display: contents; }
.pj-content > .wp-block-heading, .pj-content .pj-title { font-family: var(--display); font-size: clamp(1.8rem, 4vw, 2.8rem); font-weight: 900; line-height: 1.3; }
.site[lang="en"] .pj-content > .wp-block-heading, .site[lang="en"] .pj-content .pj-title { font-weight: 800; }
.pj-content p { margin: 0; }
.pj-story { display: grid; grid-template-columns: repeat(3, 1fr); gap: clamp(24px, 4vw, 56px); }
.pj-story-item { display: grid; gap: 10px; align-content: start; }
.pj-story h2 { font-size: .85rem; letter-spacing: .06em; color: var(--muted); font-weight: 700; }
.pj-story p { font-size: 1.08rem; line-height: 1.9; }
.pj-section { display: grid; gap: 28px; }
.pj-feat-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; }
.pj-feat { background: var(--white); border-radius: 20px; padding: 24px; display: grid; gap: 8px; align-content: start; }
.pj-feat-grid h3 { font-size: 1.12rem; font-weight: 800; display: flex; align-items: center; gap: 10px; }
.pj-feat-grid h3::before { content: ""; width: 12px; height: 12px; border-radius: 4px; flex: none; background: var(--saffron); }
.pj-feat:nth-child(3n+2) h3::before { background: var(--turquoise); }
.pj-feat:nth-child(3n) h3::before { background: var(--pomegranate); }
.pj-feat-grid p { color: var(--muted); font-size: .95rem; }
.pj-shots, .pj-gallery { display: grid; gap: 18px; grid-template-columns: 1fr 1fr; }
.pj-gallery { grid-template-columns: repeat(3, 1fr); }
.pj-content .wp-block-image { margin: 0; display: grid; gap: 10px; }
.pj-content .wp-block-image img { width: 100%; height: auto; border-radius: 14px; border: 1px solid #ddd8cf; box-shadow: 0 20px 40px -30px rgb(0 0 0 / .4); cursor: zoom-in; }
.pj-content .wp-block-image figcaption { font-size: .9rem; color: var(--muted); margin: 0; text-align: start; }
.pj-content > .wp-block-image { max-width: 960px; }
.pj-facts { display: grid; grid-template-columns: 1fr 1.6fr; gap: clamp(24px, 5vw, 72px); align-items: start; }
.pj-facts-body { display: grid; gap: 10px; }
.pj-content .wp-block-table { margin: 0; }
.pj-content .wp-block-table table { width: 100%; border-collapse: collapse; }
.pj-content .wp-block-table td { padding: 14px 0; border: 0; border-top: 1px solid #ddd8cf; vertical-align: top; color: #3d4048; }
.pj-content .wp-block-table td:first-child { font-weight: 700; color: var(--ink); width: 9em; padding-inline-end: 16px; }
.pj-content .wp-block-details { background: var(--white); border-radius: 16px; padding: 16px 20px; margin: 0; }
.pj-content .wp-block-details summary { cursor: pointer; font-weight: 700; }
.pj-content .wp-block-details p { margin-top: 8px; color: #3d4048; }

/* ---------- zoomed screenshot ---------- */
.zoom { border: 0; padding: 0; background: transparent; max-width: none; max-height: none; width: 100vw; height: 100vh; margin: 0; }
.zoom::backdrop { background: rgb(10 11 13 / .88); }
.zoom-inner { width: 100%; height: 100%; overflow: auto; display: grid; place-items: center; padding: 16px; cursor: zoom-out; }
.zoom img { display: block; max-width: none; width: min(1360px, 100%); height: auto; border-radius: 10px; box-shadow: 0 30px 80px -20px rgb(0 0 0 / .7); }
.zoom-close { position: fixed; top: calc(14px + env(safe-area-inset-top, 0px)); inset-inline-end: 14px; width: 44px; height: 44px; border-radius: 50%; border: 0; background: var(--white); color: var(--ink); font-size: 1.4rem; line-height: 1; cursor: pointer; }

@media (max-width: 860px) {
  .p-grid, .pj-story, .pj-feat-grid, .pj-facts, .pj-shots, .pj-gallery { grid-template-columns: 1fr; }
  .pj-content .wp-block-table td:first-child { width: 7em; }
  .zoom img { width: 1100px; }
  .zoom-inner { place-items: start; }
}

/* ---------- blog ---------- */
.writing-head .more { display: inline-flex; align-items: center; gap: 8px; font-weight: 700; border-bottom: 2px solid var(--saffron); padding-bottom: 2px; }
.writing-head .more svg { width: 16px; height: 16px; }
.site[dir="rtl"] .writing-head .more svg, .site[dir="rtl"] .b-row .go svg { transform: scaleX(-1); }

.b-hero { padding-block: calc(env(safe-area-inset-top, 0px) + 130px) clamp(56px, 8vw, 100px); }
.b-hero .wrap { display: grid; gap: 20px; justify-items: start; }
.b-hero .crumb { margin: 0; }
.b-hero h1 { font-family: var(--display); font-size: clamp(2.6rem, 7vw, 5.4rem); font-weight: 900; line-height: 1.2; max-width: 18ch; }
.site[lang="en"] .b-hero h1 { font-weight: 800; line-height: 1.05; letter-spacing: -.02em; }
/* a post's header lines up with its reading column */
.b-hero.is-post .wrap { max-width: calc(720px + 40px); }
.b-hero.is-post h1 { font-size: clamp(2rem, 4.4vw, 3.3rem); max-width: none; line-height: 1.35; }
.site[lang="en"] .b-hero.is-post h1 { line-height: 1.12; }
.b-intro { font-size: clamp(1.05rem, 1.6vw, 1.25rem); color: #c9ccd3; max-width: 52ch; }
.b-byline { display: flex; flex-wrap: wrap; align-items: center; gap: 10px; color: var(--muted-dark); font-size: .92rem; margin-top: 6px; }
.b-avatar { width: 40px; height: 40px; border-radius: 50%; overflow: hidden; background: var(--saffron); display: block; flex: none; }
.b-avatar img { width: 100%; height: 100%; object-fit: cover; object-position: 50% 0; transform: scale(1.9) translateY(22%); display: block; }
.b-byline span:nth-child(2) { color: var(--white); font-weight: 700; }

.b-list { padding-block: clamp(40px, 6vw, 80px) clamp(72px, 10vw, 130px); min-height: 40vh; }
.b-rows { list-style: none; margin: 0; padding: 0; }
.b-row { display: grid; grid-template-columns: 9.5em 1fr auto auto; gap: clamp(16px, 3vw, 40px); align-items: center; padding: clamp(24px, 3vw, 36px) 4px; border-bottom: 1px solid #ddd8cf; transition: padding .35s ease, opacity .3s; }
.b-rows:hover .b-row { opacity: .5; }
.b-rows .b-row:hover, .b-rows .b-row:focus-visible { opacity: 1; padding-inline-start: 18px; }
.b-row time, .b-meta { color: var(--muted); font-size: .9rem; white-space: nowrap; }
.b-text { display: grid; gap: 6px; min-width: 0; }
.b-text h2 { font-family: var(--display); font-size: clamp(1.3rem, 2.4vw, 1.9rem); font-weight: 800; line-height: 1.45; }
.site[lang="en"] .b-text h2 { font-weight: 600; line-height: 1.25; }
.b-text p { color: #50545d; font-size: .98rem; max-width: 70ch; }
.b-row .go { width: 44px; height: 44px; border-radius: 50%; border: 1px solid #cfcac2; display: grid; place-items: center; transition: background .3s, border-color .3s, transform .3s; }
.b-row .go svg { width: 18px; height: 18px; }
.b-row:hover .go, .b-row:focus-visible .go { background: var(--ink); border-color: var(--ink); color: var(--white); transform: rotate(-8deg); }
.b-empty { display: grid; gap: 24px; justify-items: start; padding-block: 20px; font-size: 1.15rem; color: #3d4048; }

.pagination { margin-top: 40px; }
.pagination .nav-links { display: flex; flex-wrap: wrap; gap: 8px; }
.pagination .page-numbers { min-width: 44px; height: 44px; padding: 0 14px; border-radius: 999px; border: 1px solid #cfcac2; display: grid; place-items: center; font-weight: 700; }
.pagination .page-numbers.current { background: var(--ink); border-color: var(--ink); color: var(--white); }
.pagination a.page-numbers:hover { border-color: var(--ink); }
.screen-reader-text { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }

/* cover image straddles the dark band and the light body */
.b-cover .wrap { max-width: 1040px; }
.b-cover img { display: block; width: 100%; height: auto; border-radius: 22px; box-shadow: 0 40px 80px -40px rgb(0 0 0 / .6); }

/* the reading column */
.b-body { padding-block: clamp(40px, 6vw, 72px) clamp(64px, 9vw, 120px); }
.prose { max-width: calc(720px + 40px); font-size: 1.12rem; line-height: 2.05; color: #2a2c31; }
.site[lang="en"] .prose { font-size: 1.15rem; line-height: 1.75; }
.prose > * { margin: 0 0 1.3em; }
.prose > :last-child { margin-bottom: 0; }
.prose h2, .prose h3, .prose h4 { font-family: var(--display); color: var(--ink); line-height: 1.45; margin-top: 2em; margin-bottom: .6em; }
.site[lang="en"] .prose h2, .site[lang="en"] .prose h3 { line-height: 1.2; }
.prose h2 { font-size: clamp(1.5rem, 3vw, 2rem); font-weight: 900; }
.site[lang="en"] .prose h2 { font-weight: 700; }
.prose h3 { font-size: 1.3rem; font-weight: 800; }
.site[lang="en"] .prose h3 { font-weight: 600; }
.prose a { color: var(--ink); text-decoration: underline; text-decoration-color: var(--saffron); text-decoration-thickness: 2px; text-underline-offset: 4px; }
.prose a:hover { background: color-mix(in srgb, var(--saffron) 30%, transparent); }
.prose strong { color: var(--ink); }
.prose ul, .prose ol { padding-inline-start: 1.3em; }
.prose li { margin-bottom: .4em; }
.prose li::marker { color: var(--turquoise); font-weight: 700; }
.prose blockquote { border-inline-start: 4px solid var(--saffron); padding: 4px 0; padding-inline-start: 22px; margin-inline: 0; font-size: 1.2rem; color: var(--ink); }
.prose blockquote p { margin: 0; }
.prose blockquote cite { display: block; font-size: .9rem; color: var(--muted); font-style: normal; margin-top: 8px; }
.prose code { font-family: ui-monospace, "SFMono-Regular", Menlo, Consolas, monospace; font-size: .86em; background: #e9e4dc; border-radius: 6px; padding: .1em .4em; direction: ltr; unicode-bidi: isolate; }
.prose pre { direction: ltr; text-align: left; background: var(--ink); color: #e8e6e3; border-radius: 16px; padding: 20px 22px; overflow-x: auto; font-size: .92rem; line-height: 1.7; }
.prose pre code { background: none; padding: 0; font-size: inherit; color: inherit; }
.prose figure { margin-inline: 0; }
.prose img { max-width: 100%; height: auto; border-radius: 14px; display: block; }
.prose figcaption { font-size: .9rem; color: var(--muted); margin-top: 10px; text-align: center; }
.prose .wp-block-image.alignwide, .prose .wp-block-image.alignfull { margin-inline: min(0px, calc((720px - min(1040px, 100vw - 40px)) / 2)); }
.prose hr { border: 0; height: 1px; background: #ddd8cf; margin-block: 2.4em; }
.prose table { width: 100%; border-collapse: collapse; font-size: .95rem; }
.prose th, .prose td { border-bottom: 1px solid #ddd8cf; padding: 10px 8px; text-align: start; vertical-align: top; }
.prose th { color: var(--ink); }
.prose .wp-block-table { overflow-x: auto; }
.b-tags { display: flex; flex-wrap: wrap; gap: 8px; padding-top: 1em; }
.b-tags a { border: 1px solid #cfcac2; border-radius: 999px; padding: 0 12px; font-size: .85rem; text-decoration: none; color: #50545d; }
.b-tags a:hover { border-color: var(--ink); background: none; }

.b-adjacent { max-width: calc(720px + 40px); display: grid; grid-template-columns: 1fr 1fr; gap: 16px; margin-top: clamp(48px, 7vw, 80px); }
.b-adjacent a { background: var(--white); border-radius: 20px; padding: 22px 24px; display: grid; gap: 4px; transition: transform .3s ease, box-shadow .3s ease; }
.b-adjacent a:hover { transform: translateY(-4px); box-shadow: 0 22px 40px -26px rgb(20 21 24 / .5); }
.b-adjacent a:last-child { text-align: end; }
.b-adjacent small { color: var(--muted); font-size: .85rem; }
.b-adjacent span { font-weight: 800; line-height: 1.5; }

/* 404 */
.b-hero.is-404 { min-height: 70vh; display: grid; align-items: center; }
.big-404 { font-family: var(--en-display); font-size: clamp(5rem, 18vw, 12rem); font-weight: 800; line-height: 1; color: var(--saffron); }
.site[lang="fa"] .big-404 { font-family: var(--fa); font-weight: 900; }

@media (max-width: 860px) {
  .b-row { grid-template-columns: 1fr auto; gap: 8px 14px; }
  .b-row time { grid-column: 1 / -1; }
  .b-row .b-meta { display: none; }
  .b-row .go { width: 36px; height: 36px; }
  .b-adjacent { grid-template-columns: 1fr; }
  .b-adjacent a:last-child { text-align: start; }
}
@media (prefers-reduced-motion: reduce) { .b-row, .b-adjacent a { transition: none; } }

/* ---------- statement button ---------- */
.statement .to-work { justify-self: start; padding: 14px 20px 14px 24px; }
.site[dir="rtl"] .statement .to-work { padding: 14px 24px 14px 20px; }
.site .statement .to-work svg { transform: none; transition: transform .25s; }
.site .statement .to-work:hover svg { transform: translateY(3px); }

/* ---------- reading progress (blog posts) ---------- */
.read-progress { position: fixed; inset: 0 0 auto; height: 3px; z-index: 50; pointer-events: none; }
.read-progress i { display: block; height: 100%; background: var(--saffron); transform: scaleX(0); transform-origin: left; }
.site[dir="rtl"] .read-progress i { transform-origin: right; }

/* ---------- contact actions ---------- */
.talk { display: inline-flex; align-items: center; gap: 12px; background: var(--saffron); color: var(--ink); border-radius: 999px; padding: 14px 18px 14px 28px; font-size: 1.15rem; font-weight: 800; transition: background .25s, transform .25s; }
.site[dir="rtl"] .talk { padding: 14px 28px 14px 18px; }
.talk svg { width: 34px; height: 34px; padding: 8px; border-radius: 50%; background: var(--ink); color: var(--saffron); transition: transform .3s; }
.site[dir="rtl"] .talk svg { transform: scaleX(-1); }
.talk:hover { background: var(--white); transform: translateY(-2px); }
.talk:hover svg { transform: rotate(45deg); }
.site[dir="rtl"] .talk:hover svg { transform: scaleX(-1) rotate(45deg); }
.pill.copy { display: inline-flex; align-items: center; gap: 10px; }
.pill.copy svg { width: 18px; height: 18px; opacity: .7; }
.toast { position: fixed; z-index: 60; left: 50%; bottom: max(24px, env(safe-area-inset-bottom, 0px)); transform: translate(-50%, 20px); opacity: 0; pointer-events: none; background: var(--white); color: var(--ink); border-radius: 999px; padding: 12px 22px; font-size: .95rem; font-weight: 600; box-shadow: 0 20px 40px -16px rgb(0 0 0 / .5); width: max-content; max-width: calc(100vw - 32px); text-align: center; line-height: 1.6; transition: opacity .25s, transform .25s; }
.toast::before { content: "✓"; display: inline-grid; place-items: center; width: 22px; height: 22px; border-radius: 50%; background: var(--turquoise); color: var(--white); font-size: .8rem; margin-inline-end: 10px; vertical-align: middle; }
.toast b { font-family: var(--en-body); direction: ltr; unicode-bidi: isolate; white-space: nowrap; }
@media (max-width: 600px) { .toast { border-radius: 18px; } }
.toast.is-on { opacity: 1; transform: translate(-50%, 0); }
