/* Daghigh Sayesh — brand site. Colours sampled from ds-branding (logo PDF + posters). */

@font-face {
  font-family: "Vazirmatn";
  src: url("/fonts/Vazirmatn-wght.woff2") format("woff2");
  font-weight: 100 900;
  font-display: swap;
}

@font-face {
  font-family: "Dima Barf";
  src: url("/fonts/DimaBarf2.ttf") format("truetype");
  font-display: swap;
}

:root {
  --green: #283f23;
  --green-deep: #1b2b17;
  --green-soft: #e7ebe2;
  --yellow: #ffbe00;
  --yellow-deep: #e6ab00;
  /* Darkened yellow that passes 4.5:1 on cream/white, for small text. */
  --gold-ink: #8a6400;
  --cream: #f8f6ef;
  --paper: #ffffff;
  --ink: #1b2219;
  --muted: #5a6555;
  --line: rgb(40 63 35 / 0.12);

  --font-body: "Vazirmatn", system-ui, -apple-system, "Segoe UI", sans-serif;
  --font-display: "Dima Barf", "Vazirmatn", system-ui, sans-serif;

  --ease-out: cubic-bezier(0.23, 1, 0.32, 1);
  --radius: 20px;
  --gutter: clamp(16px, 4vw, 40px);
  --max: 1160px;

  color-scheme: light;
}

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

html {
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
  scroll-behavior: smooth;
  scroll-padding-top: 80px;
}

body {
  margin: 0;
  background: var(--cream);
  color: var(--ink);
  font-family: var(--font-body);
  font-size: 1rem;
  line-height: 1.8;
  -webkit-font-smoothing: antialiased;
  -webkit-tap-highlight-color: transparent;
  overflow-x: clip;
}

[lang="en"] body {
  line-height: 1.65;
}

img {
  display: block;
  max-width: 100%;
  height: auto;
}

h1,
h2,
h3,
p,
figure,
ul,
ol {
  margin: 0;
}

ul,
ol {
  padding: 0;
  list-style: none;
}

a {
  color: inherit;
}

:focus-visible {
  outline: 2px solid var(--yellow);
  outline-offset: 3px;
  border-radius: 6px;
}

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

.skip {
  position: absolute;
  inset-inline-start: 16px;
  top: -100px;
  z-index: 100;
  padding: 10px 16px;
  border-radius: 10px;
  background: var(--green);
  color: #fff;
}

.skip:focus {
  top: 12px;
}

/* ---------- Brand mark ---------- */

.mark {
  width: 40px;
  height: 40px;
  flex: none;
}

.mark .y {
  fill: var(--yellow);
}

.mark .g {
  fill: var(--green);
}

.mark--mono .y,
.mark--mono .g {
  fill: currentColor;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  text-decoration: none;
  color: var(--green);
}

.brand-name {
  font-family: var(--font-display);
  font-size: 1.35rem;
  line-height: 1;
  letter-spacing: 0.01em;
  white-space: nowrap;
}

/* Dima Barf's Persian glyphs sit small on the em box. */
[lang="fa"] .brand-name {
  font-size: 1.6rem;
}

.eyebrow:lang(fa),
.brand-name:lang(fa) {
  letter-spacing: 0;
}

.brand--light {
  color: #fff;
}

/* ---------- Header ---------- */

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgb(248 246 239 / 0.82);
  backdrop-filter: saturate(1.4) blur(14px);
  -webkit-backdrop-filter: saturate(1.4) blur(14px);
  border-bottom: 1px solid var(--line);
  padding-top: env(safe-area-inset-top);
}

.header-inner {
  display: flex;
  align-items: center;
  gap: 24px;
  height: 68px;
}

.nav {
  display: flex;
  gap: 4px;
  margin-inline-start: auto;
}

.nav a,
.lang {
  padding: 8px 14px;
  border-radius: 999px;
  font-size: 0.95rem;
  font-weight: 500;
  text-decoration: none;
  color: var(--muted);
  transition: color 150ms ease, background-color 150ms ease;
}

.lang {
  border: 1px solid var(--line);
  color: var(--green);
  font-weight: 600;
}

@media (hover: hover) and (pointer: fine) {
  .nav a:hover {
    color: var(--green);
    background: var(--green-soft);
  }

  .lang:hover {
    background: var(--green);
    color: #fff;
  }
}

@media (max-width: 720px) {
  .nav {
    display: none;
  }

  .lang {
    margin-inline-start: auto;
  }

  .brand-name {
    font-size: 1.15rem;
  }

  [lang="fa"] .brand-name {
    font-size: 1.4rem;
  }
}

/* ---------- Buttons ---------- */

.actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  min-height: 48px;
  padding: 12px 22px;
  border-radius: 999px;
  border: 1px solid transparent;
  font: inherit;
  font-weight: 700;
  font-size: 0.98rem;
  line-height: 1.2;
  text-decoration: none;
  cursor: pointer;
  user-select: none;
  -webkit-user-select: none;
  transition:
    transform 160ms var(--ease-out),
    background-color 200ms ease,
    color 200ms ease,
    border-color 200ms ease;
}

.btn:active {
  transform: scale(0.97);
}

.btn .arrow {
  width: 16px;
  height: 16px;
  transition: transform 200ms var(--ease-out);
}

.btn--primary {
  background: var(--yellow);
  color: var(--green-deep);
}

.btn--ghost {
  border-color: rgb(40 63 35 / 0.24);
  color: var(--green);
}

.btn--dark {
  background: var(--green);
  color: #fff;
}

.btn--ghost-dark {
  border-color: rgb(27 43 23 / 0.35);
  color: var(--green-deep);
}

.btn-meta {
  font-weight: 400;
  opacity: 0.7;
  font-size: 0.88rem;
}

@media (hover: hover) and (pointer: fine) {
  .btn--primary:hover {
    background: var(--yellow-deep);
  }

  .btn--ghost:hover {
    border-color: var(--green);
    background: var(--green-soft);
  }

  .btn--dark:hover {
    background: var(--green-deep);
  }

  .btn--ghost-dark:hover {
    border-color: var(--green-deep);
    background: rgb(27 43 23 / 0.06);
  }

  /* Nudge arrow toward reading direction. */
  .btn:hover .arrow {
    transform: translateX(3px);
  }

  [dir="rtl"] .btn:hover .arrow {
    transform: translateX(-3px);
  }
}

/* ---------- Typography ---------- */

.eyebrow {
  font-family: var(--font-display);
  font-size: 1.2rem;
  line-height: 1.2;
  letter-spacing: 0.08em;
  color: var(--gold-ink);
  margin-bottom: 14px;
}

h1,
h2 {
  font-weight: 800;
  color: var(--green);
  text-wrap: balance;
}

h1 {
  font-size: clamp(2.1rem, 5.2vw, 3.6rem);
  line-height: 1.25;
  letter-spacing: -0.01em;
}

h2 {
  font-size: clamp(1.6rem, 3.4vw, 2.4rem);
  line-height: 1.3;
}

[lang="en"] h1,
[lang="en"] h2 {
  letter-spacing: -0.025em;
  line-height: 1.12;
}

h3 {
  font-size: 1.15rem;
  font-weight: 700;
  color: var(--green);
}

.lead {
  font-size: clamp(1.02rem, 1.6vw, 1.15rem);
  color: var(--muted);
  max-width: 54ch;
  text-wrap: pretty;
}

/* ---------- Hero ---------- */

.hero {
  padding-block: clamp(40px, 7vw, 96px) clamp(48px, 7vw, 88px);
}

.hero-inner {
  display: grid;
  grid-template-columns: minmax(0, 1.1fr) minmax(0, 0.9fr);
  align-items: center;
  gap: clamp(32px, 5vw, 72px);
}

.hero-copy h1 {
  margin-bottom: 20px;
}

.hero-copy .lead {
  margin-bottom: 32px;
}

.hero-media {
  position: relative;
  aspect-ratio: 1;
  border-radius: calc(var(--radius) + 8px);
  overflow: hidden;
  background: var(--green);
  box-shadow:
    0 1px 0 rgb(255 255 255 / 0.6) inset,
    0 30px 60px -30px rgb(27 43 23 / 0.45);
}

.hero-media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

@media (max-width: 860px) {
  .hero-inner {
    grid-template-columns: 1fr;
  }

  .hero-media {
    max-width: 520px;
  }
}

/* ---------- Pattern band ---------- */

/* Lattice motif from ds-branding/پترن.jpg: 4×4 cells, corners removed, rows staggered. */
.band {
  height: 95.0px;
  background-color: var(--green);
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='62' height='95.0'%3E%3Cdefs%3E%3Cg id='m' fill='%23ffbe00'%3E%3Crect x='12.5' y='12.5' width='10' height='10'/%3E%3Crect x='12.5' y='25.0' width='10' height='10'/%3E%3Crect x='25.0' y='12.5' width='10' height='10'/%3E%3Crect x='25.0' y='25.0' width='10' height='10'/%3E%3Crect x='12.5' y='5.0' width='10' height='5.0'/%3E%3Ccircle cx='17.5' cy='5.0' r='5.0'/%3E%3Crect x='12.5' y='37.5' width='10' height='5.0'/%3E%3Ccircle cx='17.5' cy='42.5' r='5.0'/%3E%3Crect x='25.0' y='5.0' width='10' height='5.0'/%3E%3Ccircle cx='30.0' cy='5.0' r='5.0'/%3E%3Crect x='25.0' y='37.5' width='10' height='5.0'/%3E%3Ccircle cx='30.0' cy='42.5' r='5.0'/%3E%3Crect x='5.0' y='12.5' width='5.0' height='10'/%3E%3Ccircle cx='5.0' cy='17.5' r='5.0'/%3E%3Crect x='37.5' y='12.5' width='5.0' height='10'/%3E%3Ccircle cx='42.5' cy='17.5' r='5.0'/%3E%3Crect x='5.0' y='25.0' width='5.0' height='10'/%3E%3Ccircle cx='5.0' cy='30.0' r='5.0'/%3E%3Crect x='37.5' y='25.0' width='5.0' height='10'/%3E%3Ccircle cx='42.5' cy='30.0' r='5.0'/%3E%3C/g%3E%3C/defs%3E%3Cuse href='%23m' x='7.25'/%3E%3Cuse href='%23m' x='-23.75' y='47.5'/%3E%3Cuse href='%23m' x='38.25' y='47.5'/%3E%3C/svg%3E");
  background-size: 62px 95.0px;
  background-position: center top;
}

/* ---------- Sections ---------- */

.section {
  padding-block: clamp(64px, 9vw, 120px);
}

.section h2 {
  margin-bottom: clamp(28px, 4vw, 48px);
  max-width: 22ch;
}

/* Products */

.cards {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: clamp(16px, 2vw, 24px);
}

.card {
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  overflow: hidden;
}

.card-media {
  /* Posters are square with a baked-in wordmark; keep them whole. */
  aspect-ratio: 1;
  overflow: hidden;
  background: #f1f1ee;
}

.card-media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 500ms var(--ease-out);
}

.card-body {
  padding: 20px 22px 24px;
}

.card-body h3 {
  margin-bottom: 6px;
}

.card-body p {
  color: var(--muted);
  font-size: 0.96rem;
}

@media (hover: hover) and (pointer: fine) {
  .card:hover .card-media img {
    transform: scale(1.03);
  }
}

@media (max-width: 860px) {
  .cards {
    grid-template-columns: 1fr;
  }
}

/* About */

.section--green {
  background: var(--green);
  color: #fff;
}

.section--green h2,
.section--green h3 {
  color: #fff;
}

.section--green .lead,
.section--green p {
  color: rgb(255 255 255 / 0.74);
}

.section--green .eyebrow {
  color: var(--yellow);
}

.about {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  gap: clamp(32px, 5vw, 64px);
  align-items: center;
}

.about-media {
  border-radius: var(--radius);
  overflow: hidden;
  border: 1px solid rgb(255 255 255 / 0.1);
}

.pillars {
  grid-column: 1 / -1;
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 0;
  border-top: 1px solid rgb(255 255 255 / 0.14);
}

.pillar {
  padding: 28px 0 0;
  padding-inline-end: 24px;
}

.pillar + .pillar {
  padding-inline-start: 24px;
  border-inline-start: 1px solid rgb(255 255 255 / 0.14);
}

.pillar-index {
  display: block;
  color: var(--yellow);
  font-size: 0.9rem;
  font-weight: 700;
  font-variant-numeric: tabular-nums;
  margin-bottom: 8px;
}

.pillar h3 {
  margin-bottom: 4px;
}

.pillar p {
  font-size: 0.96rem;
}

@media (max-width: 860px) {
  .about {
    grid-template-columns: 1fr;
  }

  .pillars {
    grid-template-columns: 1fr;
  }

  .pillar,
  .pillar + .pillar {
    padding: 20px 0;
    border-inline-start: 0;
    border-bottom: 1px solid rgb(255 255 255 / 0.14);
  }
}

/* Contact CTA */

.cta {
  background: var(--yellow);
}

.cta h2,
.cta .lead {
  color: var(--green-deep);
}

.cta h2 {
  margin-bottom: 12px;
}

.cta .lead {
  margin-bottom: 28px;
  opacity: 0.85;
}

/* ---------- Footer ---------- */

.site-footer {
  background: var(--green-deep);
  color: rgb(255 255 255 / 0.6);
  padding-block: 32px calc(32px + env(safe-area-inset-bottom));
  font-size: 0.9rem;
}

.footer-inner {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}

.site-footer .mark {
  width: 32px;
  height: 32px;
  color: var(--yellow);
}

.footer-nav {
  display: flex;
  gap: 20px;
}

.footer-nav a {
  text-decoration: none;
  color: rgb(255 255 255 / 0.8);
}

@media (hover: hover) and (pointer: fine) {
  .footer-nav a:hover {
    color: var(--yellow);
  }
}

/* ---------- Journal ---------- */

.section-head {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-end;
  justify-content: space-between;
  gap: 16px 24px;
  margin-bottom: clamp(28px, 4vw, 48px);
}

.section-head h2 {
  margin-bottom: 0;
}

.band--thin {
  height: 47.5px;
}

.crumbs ol {
  display: flex;
  flex-wrap: wrap;
  gap: 4px 8px;
  margin-bottom: 20px;
  font-size: 0.88rem;
  color: var(--muted);
}

.crumbs li + li::before {
  content: "/";
  margin-inline-end: 8px;
  opacity: 0.5;
}

.crumbs a {
  text-decoration: none;
}

.crumbs [aria-current] {
  color: var(--ink);
  /* Long titles shouldn't push the trail onto many lines. */
  max-width: 40ch;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

@media (hover: hover) and (pointer: fine) {
  .crumbs a:hover {
    color: var(--green);
  }
}

.journal-head {
  padding-block: clamp(40px, 6vw, 72px) clamp(32px, 5vw, 56px);
}

.journal-head h1 {
  margin-bottom: 12px;
}

.journal-list {
  padding-top: clamp(40px, 6vw, 64px);
}

.journal-list .card-body h2 {
  font-size: 1.15rem;
  line-height: 1.5;
  margin-bottom: 6px;
}

.post-link {
  display: flex;
  flex-direction: column;
  height: 100%;
  text-decoration: none;
}

.post .card-body h3 {
  line-height: 1.5;
}

.post-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 4px 8px;
  margin-bottom: 8px;
  font-size: 0.85rem;
  color: var(--muted);
}

.post-meta span:first-child {
  color: var(--gold-ink);
  font-weight: 600;
}

.card-media--contain {
  background: var(--green);
}

.card-media--contain img {
  object-fit: contain;
}

/* Article */

.article-head,
.article-cover,
.article-layout {
  max-width: calc(1000px + 2 * var(--gutter));
}

.article-head {
  padding-top: clamp(32px, 5vw, 64px);
}

.article-head h1 {
  font-size: clamp(1.9rem, 4.2vw, 2.9rem);
  margin-bottom: 16px;
  max-width: 24ch;
}

.article-head .lead {
  margin-bottom: 16px;
  max-width: 62ch;
}

.article-cover {
  margin-block: clamp(24px, 4vw, 40px);
}

.article-cover-frame {
  aspect-ratio: 16 / 9;
  border-radius: var(--radius);
  overflow: hidden;
  background: #f4f4f2;
  border: 1px solid var(--line);
}

.article-cover-frame img {
  width: 100%;
  height: 100%;
  /* A 16:9 centre crop of the square posters keeps their wordmark band intact. */
  object-fit: cover;
}

.article-layout {
  display: grid;
  grid-template-columns: 220px minmax(0, 1fr);
  gap: clamp(32px, 5vw, 64px);
  align-items: start;
  padding-bottom: clamp(48px, 7vw, 96px);
}

.article-layout--solo {
  grid-template-columns: minmax(0, 1fr);
}

.toc {
  position: sticky;
  top: 96px;
  padding: 18px 20px;
  border: 1px solid var(--line);
  border-radius: 16px;
  background: var(--paper);
  font-size: 0.9rem;
}

.toc-title {
  font-weight: 700;
  color: var(--green);
  margin-bottom: 8px;
}

.toc ol {
  display: grid;
  gap: 6px;
  counter-reset: toc;
}

.toc li {
  counter-increment: toc;
  display: flex;
  gap: 8px;
  line-height: 1.5;
}

.toc li::before {
  content: counter(toc, var(--toc-style, decimal));
  color: var(--gold-ink);
  font-weight: 700;
  font-variant-numeric: tabular-nums;
}

[lang="fa"] .toc {
  --toc-style: persian;
}

.toc a {
  color: var(--muted);
  text-decoration: none;
}

@media (hover: hover) and (pointer: fine) {
  .toc a:hover {
    color: var(--green);
  }
}

.prose {
  max-width: 68ch;
  font-size: 1.06rem;
  line-height: 2;
}

[lang="en"] .prose {
  line-height: 1.75;
}

.prose > * + * {
  margin-top: 1.1em;
}

.prose h2 {
  font-size: clamp(1.3rem, 2.4vw, 1.6rem);
  line-height: 1.45;
  margin-top: 2em;
  scroll-margin-top: 96px;
}

.prose h3 {
  margin-top: 1.6em;
}

.prose ul,
.prose ol {
  padding-inline-start: 1.4em;
}

.prose ul {
  list-style: disc;
}

.prose ol {
  list-style: decimal;
}

[lang="fa"] .prose ol {
  list-style: persian;
}

.prose li + li {
  margin-top: 0.45em;
}

.prose li::marker {
  color: var(--gold-ink);
}

.prose strong {
  color: var(--green);
}

.prose a:not(.btn) {
  color: var(--green);
  text-decoration-color: var(--yellow);
  text-decoration-thickness: 2px;
  text-underline-offset: 3px;
}

.callout {
  padding: 16px 20px;
  border-radius: 14px;
  border-inline-start: 4px solid var(--yellow);
  background: #fff5d1;
}

.callout p {
  color: var(--green-deep);
}

.prose .article-cta {
  margin-top: 3em;
  padding: clamp(24px, 4vw, 36px);
  border-radius: var(--radius);
  background: var(--yellow);
  line-height: 1.7;
}

.article-cta h2 {
  margin: 0 0 6px;
  color: var(--green-deep);
}

.article-cta p {
  color: var(--green-deep);
  opacity: 0.85;
  margin-bottom: 20px;
}

.related {
  border-top: 1px solid var(--line);
}

@media (max-width: 860px) {
  .article-layout {
    grid-template-columns: minmax(0, 1fr);
  }

  .toc {
    position: static;
  }

  .crumbs [aria-current] {
    max-width: 24ch;
  }
}

/* ---------- Products ---------- */

.chips {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 24px;
}

.chips a {
  padding: 6px 14px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: var(--paper);
  font-size: 0.9rem;
  text-decoration: none;
}

@media (hover: hover) and (pointer: fine) {
  .chips a:hover {
    border-color: var(--green);
  }
}

.product-group + .product-group {
  border-top: 1px solid var(--line);
}

.product-group h2 {
  margin-bottom: 8px;
}

.group-lead {
  margin-bottom: clamp(24px, 3vw, 36px);
  color: var(--muted);
  max-width: 60ch;
}

.empty-state {
  display: grid;
  justify-items: start;
  gap: 20px;
}

.card-body .price,
.product-price {
  color: var(--green);
  font-weight: 700;
}

.product-price {
  font-size: clamp(1.25rem, 2.4vw, 1.6rem);
  margin-bottom: 4px;
}

/* Overrides the gold first-span colour .post-meta uses for categories. */
.post-meta .stock,
.stock {
  color: var(--green);
  font-weight: 500;
}

.post-meta .stock--out,
.stock--out {
  color: var(--muted);
}

.product-detail {
  padding-top: clamp(32px, 5vw, 64px);
}

.product-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  gap: clamp(28px, 5vw, 64px);
  align-items: start;
}

.product-main {
  aspect-ratio: 1;
  border-radius: var(--radius);
  overflow: hidden;
  border: 1px solid var(--line);
  background: #f1f1ee;
}

.product-main img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.product-thumbs {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(72px, 1fr));
  gap: 8px;
  margin-top: 12px;
}

.product-thumbs img {
  aspect-ratio: 1;
  width: 100%;
  object-fit: cover;
  border-radius: 10px;
  border: 1px solid var(--line);
}

.product-info h1 {
  font-size: clamp(1.7rem, 3.6vw, 2.5rem);
  margin-bottom: 12px;
}

.product-info .eyebrow a {
  text-decoration: none;
}

.specs {
  display: grid;
  margin-block: 24px;
  border-top: 1px solid var(--line);
}

.specs div {
  display: grid;
  grid-template-columns: minmax(0, 9rem) minmax(0, 1fr);
  gap: 16px;
  padding-block: 10px;
  border-bottom: 1px solid var(--line);
}

.specs dt {
  color: var(--muted);
}

.specs dd {
  margin: 0;
  overflow-wrap: anywhere;
}

[dir="rtl"] .specs dd[dir="ltr"] {
  text-align: right;
}

.product-description {
  margin-bottom: 28px;
}

@media (max-width: 860px) {
  .product-layout {
    grid-template-columns: minmax(0, 1fr);
  }
}

/* ---------- 404 ---------- */

.nf {
  min-height: 100dvh;
  display: grid;
  place-items: center;
  text-align: center;
  padding: 24px;
}

.nf-inner {
  display: grid;
  justify-items: center;
  gap: 16px;
}

.nf .mark {
  width: 72px;
  height: 72px;
  margin-bottom: 8px;
}

.nf p {
  color: var(--muted);
}

.nf-en {
  margin-top: 16px;
  font-size: 0.9rem;
}

/* ---------- Motion ----------
   Seen once per visit, so a short entrance is earned. Everything frequent
   (nav, language switch, anchors) stays instant. */

@keyframes rise {
  from {
    opacity: 0;
    transform: translateY(12px);
  }
}

.hero-copy > * {
  animation: rise 600ms var(--ease-out) both;
}

.hero-copy > :nth-child(2) {
  animation-delay: 60ms;
}

.hero-copy > :nth-child(3) {
  animation-delay: 120ms;
}

.hero-copy > :nth-child(4) {
  animation-delay: 180ms;
}

.hero-media {
  animation: rise 700ms var(--ease-out) 120ms both;
}

/* Scroll reveal: only armed once JS confirms it can un-hide things. */
.js .reveal {
  opacity: 0;
  transform: translateY(16px);
  transition:
    opacity 600ms var(--ease-out),
    transform 600ms var(--ease-out);
}

.js .reveal.is-in {
  opacity: 1;
  transform: none;
}

.js .cards .reveal:nth-child(2),
.js .pillars .reveal:nth-child(2) {
  transition-delay: 70ms;
}

.js .cards .reveal:nth-child(3),
.js .pillars .reveal:nth-child(3) {
  transition-delay: 140ms;
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  .hero-copy > *,
  .hero-media {
    animation-name: fade;
    animation-duration: 300ms;
  }

  .js .reveal {
    transform: none;
    transition: opacity 300ms ease;
  }

  .btn,
  .btn .arrow,
  .card-media img {
    transition-property: background-color, color, border-color;
  }

  .btn:active,
  .btn:hover .arrow,
  .card:hover .card-media img {
    transform: none !important;
  }
}

@keyframes fade {
  from {
    opacity: 0;
  }
}
