@counter-style story-persian {
  system: numeric;
  symbols: "۰" "۱" "۲" "۳" "۴" "۵" "۶" "۷" "۸" "۹";
  pad: 2 "۰";
}

.story-page {
  --story-navy: var(--c-obsidian);
  --story-navy-soft: var(--c-obsidian-2);
  --story-gold: var(--c-gold);
  --story-ivory: var(--c-cream);
  --story-ivory-deep: var(--c-cream-2);
  --story-blue: var(--c-mist-pale);
  --story-ink: var(--c-ink);
  --story-muted: #4f5563;
  --story-border: rgba(11, 19, 43, .1);
  --story-shadow: 0 16px 48px rgba(11, 19, 43, .07);
  background: var(--story-ivory);
  color: var(--story-ink);
  overflow: hidden;
}

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

.story-wrap {
  width: min(1160px, calc(100% - 64px));
  margin-inline: auto;
}

.story-readable { max-width: 760px; margin-inline: auto; }

.story-section { padding: 96px 0; position: relative; }

.story-page h1,
.story-page h2,
.story-page h3,
.story-page h4 { color: var(--story-navy); line-height: 1.45; }

.story-page h1 { font-family: var(--f-bold); font-weight: 700; }
.story-page h2 { font-family: var(--f-semibold); font-size: clamp(30px, 4vw, 48px); font-weight: 650; margin: 0 0 24px; }
.story-page h3 { font-family: var(--f-semibold); font-weight: 600; }
.story-page h4 { font-family: var(--f-medium); font-weight: 550; }
.story-page p,
.story-page li { font-size: 17px; line-height: 1.95; }

.story-page p + p { margin-top: 16px; }

.story-index {
  display: inline-block;
  margin-bottom: 12px;
  color: var(--c-gold-dim);
  font-family: var(--f-medium);
  font-size: 13px;
  letter-spacing: normal;
}

.story-index::after {
  content: "";
  display: inline-block;
  width: 32px;
  height: 1px;
  margin-right: 12px;
  vertical-align: middle;
  background: var(--story-gold);
}

.story-section-head { max-width: 520px; }
.story-centered-head { max-width: 760px; margin: 0 auto 48px; text-align: center; }
.story-centered-head .story-index::after { display: block; margin: 8px auto 0; }
.story-subtitle { color: var(--story-muted); font-size: 19px !important; }

.story-page .story-hero {
  min-height: 560px;
  padding: 160px 0 88px;
  display: flex;
  align-items: center;
  position: relative;
  isolation: isolate;
  overflow: hidden;
  color: #fff;
  /* Required to override the legacy `.hero { background: none !important; }`. */
  background:
    radial-gradient(ellipse at 78% 36%, rgba(42,62,105,.32) 0%, transparent 48%),
    radial-gradient(ellipse at 18% 92%, rgba(212,175,55,.055) 0%, transparent 42%),
    linear-gradient(145deg, #091229 0%, #101a38 54%, #0b1530 100%) !important;
}

.story-page .story-hero::before,
.story-page .story-hero::after {
  content: "";
  position: absolute;
  z-index: 1;
  pointer-events: none;
}

.story-page .story-hero::before {
  inset: 0;
  background:
    radial-gradient(ellipse at 72% 26%, rgba(142,154,175,.13) 0%, rgba(142,154,175,.045) 30%, transparent 62%),
    radial-gradient(ellipse at 34% 58%, rgba(255,255,255,.035) 0%, transparent 52%);
}

.story-page .story-hero::after {
  inset: 0;
  opacity: .42;
  background:
    linear-gradient(110deg, rgba(255,255,255,.025), transparent 32%, rgba(142,154,175,.035) 68%, transparent),
    radial-gradient(ellipse at center, transparent 38%, rgba(4,10,25,.22) 100%);
}

.story-page .story-hero-inner { display: block; position: relative; z-index: 2 !important; padding-top: 0; text-align: right; }
.story-hero h1 { color: #fff; font-size: clamp(40px, 5vw, 62px); margin: 0; max-width: 800px; text-wrap: balance; }
.story-hero h1::after { content: ""; display: block; width: 64px; height: 2px; margin-top: 32px; background: var(--story-gold); }
.story-hero-copy { max-width: 760px; margin-top: 32px; color: rgba(255,255,255,.86); }
.story-hero-copy p { font-size: 18px; }

.story-why { background: var(--story-ivory); }
.story-narrative-grid { display: grid; grid-template-columns: .72fr 1.28fr; gap: 64px; align-items: start; }
.story-prose { max-width: 720px; }
.story-quote {
  margin: 40px 0 0;
  padding: 32px;
  border: 0;
  border-right: 3px solid var(--story-gold);
  border-radius: 18px;
  background: var(--story-ivory-deep);
  box-shadow: none;
}
.story-quote strong,
.story-quote span { display: block; line-height: 2; }
.story-quote strong { color: var(--story-navy); font-family: var(--f-semibold); font-weight: 600; }
.story-quote span { margin-top: 4px; color: var(--story-muted); }

.story-what { background: var(--story-blue); }
.story-what .story-readable { margin-inline: 0; }
.story-steps { list-style: none; display: grid; grid-template-columns: repeat(4, 1fr); gap: 24px; padding: 0; margin: 48px 0 0; counter-reset: story-step; }
.story-steps li { counter-increment: story-step; position: relative; min-height: 200px; padding: 72px 24px 24px; border-top: 1px solid rgba(11,19,43,.16); }
.story-steps li::before {
  content: counter(story-step, story-persian);
  position: absolute;
  right: 24px;
  top: -24px;
  width: 48px;
  height: 48px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  color: var(--story-navy);
  background: var(--story-ivory);
  border: 1px solid rgba(212,175,55,.38);
  font-family: var(--f-medium);
  font-size: 13px;
}
.story-steps li:not(:last-child)::after { content: ""; position: absolute; top: -1px; right: 72px; width: calc(100% - 24px); height: 1px; background: rgba(212,175,55,.38); }
.story-steps li span { display: block; padding: 0; font-size: 16px; }

.story-approach { background: #fff; }
.story-approach-grid { display: grid; grid-template-columns: 1fr 80px 1fr; align-items: stretch; }
.story-approach-pane { min-height: 320px; padding: 40px; border: 1px solid var(--story-border); background: var(--story-ivory); }
.story-approach-human { border-radius: 20px 20px 20px 0; }
.story-approach-ai { border-radius: 20px 0 20px 20px; background: var(--story-blue); }
.story-line-icon { width: 48px; height: 48px; display: block; margin-bottom: 32px; color: var(--c-gold-dim); }
.story-line-icon svg { width: 100%; height: 100%; fill: none; stroke: currentColor; stroke-width: 1.5; stroke-linecap: round; stroke-linejoin: round; }
.story-approach-pane p { color: var(--story-muted); }
.story-complement { display: grid; place-items: center; }
.story-complement span { position: relative; width: 100%; height: 1px; background: rgba(212,175,55,.5); }
.story-complement span::after { content: ""; position: absolute; left: calc(50% - 5px); top: -5px; width: 10px; height: 10px; border-radius: 50%; background: var(--story-gold); box-shadow: 0 0 0 8px var(--story-ivory); }

.story-journey { background: var(--story-ivory-deep); }
.story-journey .story-readable { margin-inline: 0; }
.story-journey h3 { margin-top: 40px; font-size: 22px; }
.story-process { list-style: none; padding: 0; margin: 48px 0 0; counter-reset: journey; }
.story-process li { counter-increment: journey; width: calc(50% + 1px); position: relative; padding: 0 0 32px 48px; border-left: 1px solid rgba(11,19,43,.22); }
.story-process li:nth-child(even) { margin-right: 50%; padding: 0 48px 32px 0; border-left: 0; border-right: 1px solid rgba(11,19,43,.22); }
.story-process li::before { content: counter(journey, story-persian); position: absolute; left: -28px; top: 24px; width: 56px; height: 56px; display: grid; place-items: center; border-radius: 50%; background: var(--story-navy); color: var(--story-gold); font-family: var(--f-medium); font-size: 15px; box-shadow: 0 0 0 8px var(--story-ivory-deep); }
.story-process li:nth-child(even)::before { left: auto; right: -28px; }
.story-process li > div { min-height: 176px; padding: 32px; border-radius: 18px; background: rgba(255,255,255,.72); border: 1px solid rgba(11,19,43,.08); box-shadow: 0 10px 32px rgba(11,19,43,.04); }
.story-process h4 { font-size: 21px; margin: 0 0 8px; }
.story-process p { color: var(--story-muted); font-size: 16px; }

.story-founders { background: #fff; }
.story-founders-list { display: grid; gap: 48px; }
.story-founder { display: grid; grid-template-columns: minmax(280px, .72fr) 1.28fr; gap: 48px; align-items: center; padding: 32px; border: 1px solid var(--story-border); border-radius: 20px; background: var(--story-ivory); box-shadow: none; }
.story-founder-reverse { grid-template-columns: 1.28fr minmax(280px, .72fr); }
.story-founder-reverse .story-founder-photo { order: 2; }
.story-founder-photo { aspect-ratio: 1; overflow: hidden; border-radius: 18px; background: var(--story-blue); box-shadow: 0 16px 40px rgba(11,19,43,.1); }
.story-founder-photo img { width: 100%; height: 100%; display: block; object-fit: cover; object-position: center; filter: saturate(.94); }
.story-founder-content { align-self: center; padding: 24px; }
.story-founder-content h3 { font-size: 32px; margin: 0; }
.story-founder-role { margin: 4px 0 28px !important; color: var(--c-gold-dim); font-family: var(--f-medium); }
.story-founder-content ul { margin: 0; padding: 0 22px 0 0; color: var(--story-muted); }
.story-founder-content li { padding-right: 8px; font-size: 17px; line-height: 1.95; }
.story-founder-content li::marker { color: var(--story-gold); }
.story-founder-hours { margin-top: 32px !important; padding-top: 24px; border-top: 1px solid var(--story-border); color: var(--story-navy); font-family: var(--f-semibold); font-weight: 600; }

.story-values { background: var(--story-blue); }
.story-values .story-section-head { margin-bottom: 48px; }
.story-values-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 24px; }
.story-value { min-height: 240px; padding: 40px; border: 1px solid rgba(11,19,43,.09); border-radius: 18px; background: rgba(255,255,255,.66); box-shadow: 0 10px 32px rgba(11,19,43,.035); }
.story-value:nth-child(3),
.story-value:nth-child(4) { grid-column: auto; grid-row: auto; }
.story-value:nth-child(even) { background: rgba(247,243,235,.72); }
.story-value-featured { color: var(--story-ink); }
.story-value h3 { font-size: 22px; margin: 0 0 12px; }
.story-value h3::before { content: ""; display: block; width: 24px; height: 2px; margin-bottom: 16px; background: var(--story-gold); }
.story-value p { color: inherit; font-size: 16px; }

.story-change { background: var(--story-ivory); }
.story-change-grid { display: grid; grid-template-columns: 1fr 64px 1fr; gap: 0; max-width: 1060px; margin-inline: auto; align-items: stretch; }
.story-change-grid > div { padding: 48px; border-radius: 20px; }
.story-change-before { grid-column: 1; color: var(--story-muted); background: var(--story-ivory-deep); border: 1px solid var(--story-border); }
.story-change-after { grid-column: 3; color: var(--story-navy); background: #fff; border: 1px solid rgba(212,175,55,.32); box-shadow: var(--story-shadow); }
.story-change-grid::before { content: ""; grid-column: 2; grid-row: 1; align-self: center; width: 100%; height: 1px; background: linear-gradient(to left, rgba(11,19,43,.18), var(--story-gold)); }
.story-change-grid::after { content: ""; grid-column: 2; grid-row: 1; align-self: center; justify-self: end; width: 8px; height: 8px; border-top: 1px solid var(--story-gold); border-left: 1px solid var(--story-gold); transform: rotate(-45deg); }

.story-mission { padding-block: 96px; text-align: center; color: rgba(255,255,255,.88); background: radial-gradient(ellipse at 50% 0, rgba(142,154,175,.2), transparent 52%), linear-gradient(145deg, var(--story-navy), var(--story-navy-soft)); }
.story-mission h2 { color: #fff; }
.story-mission .story-index { color: var(--story-gold); }
.story-mission p { font-size: clamp(20px, 2.2vw, 25px); line-height: 2; }

.story-cta { padding-block: 96px; text-align: center; background: var(--story-ivory-deep); }
.story-cta-lead { color: var(--story-navy); font-family: var(--f-semibold); font-size: clamp(26px, 3.6vw, 36px) !important; font-weight: 600; line-height: 1.65 !important; }
.story-cta .story-readable > p:not(.story-cta-lead) { color: var(--story-muted); }
.story-final-actions { display: flex; justify-content: center; flex-wrap: wrap; gap: 16px; margin-top: 40px; }
.story-cta-button { min-height: 56px; display: inline-flex; align-items: center; justify-content: center; padding: 14px 40px; border: 1px solid var(--story-gold); border-radius: 14px; font-family: var(--f-medium); font-weight: 500; transition: transform 280ms var(--ease), box-shadow 280ms var(--ease), background-color 280ms var(--ease), color 280ms var(--ease), border-color 280ms var(--ease); }
.story-cta-primary { color: var(--story-navy); background: var(--story-gold); box-shadow: 0 10px 28px rgba(156,127,40,.18); }
.story-cta-primary:hover { transform: translateY(-2px); background: var(--c-gold-light); box-shadow: 0 14px 32px rgba(156,127,40,.24); }
.story-cta-secondary { color: var(--story-navy); background: transparent; border-color: rgba(11,19,43,.32); }
.story-cta-secondary:hover { transform: translateY(-2px); color: #fff; background: var(--story-navy); border-color: var(--story-navy); }
.story-cta-button:focus-visible { outline: 3px solid rgba(212,175,55,.35); outline-offset: 4px; }

@media (max-width: 980px) {
  .story-page .story-hero { min-height: auto; padding: 152px 0 88px; }
  .story-hero-inner,
  .story-narrative-grid { grid-template-columns: 1fr; gap: 48px; }
  .story-hero-copy { max-width: 720px; }
  .story-approach-grid { grid-template-columns: 1fr; gap: 0; }
  .story-complement { height: 64px; }
  .story-complement span { width: 1px; height: 100%; }
  .story-complement span::after { left: -5px; top: calc(50% - 5px); }
  .story-approach-human,
  .story-approach-ai { border-radius: 20px; }
  .story-steps { grid-template-columns: repeat(2, 1fr); row-gap: 48px; }
  .story-steps li:nth-child(2)::after { display: none; }
  .story-founder,
  .story-founder-reverse { grid-template-columns: 300px 1fr; gap: 32px; }
  .story-founder-reverse .story-founder-photo { order: 0; }
}

@media (max-width: 760px) {
  .story-wrap { width: min(100% - 40px, 1160px); }
  .story-section { padding: 64px 0; }
  .story-page p,
  .story-page li { font-size: 16px; line-height: 1.95; }
  .story-page h2 { margin-bottom: 20px; }
  .story-centered-head { margin-bottom: 40px; }
  .story-page .story-hero { padding: 136px 0 72px; }
  .story-hero h1 { font-size: clamp(34px, 10vw, 48px); }
  .story-hero-copy p { font-size: 16px; }
  .story-quote,
  .story-approach-pane,
  .story-value,
  .story-change-grid > div { padding: 24px; }
  .story-steps { display: block; margin-top: 48px; }
  .story-steps li { min-height: 88px; padding: 0 64px 32px 0; border-top: 0; }
  .story-steps li::before { right: 0; top: 0; width: 48px; height: 48px; }
  .story-steps li:not(:last-child)::after,
  .story-steps li:nth-child(2)::after { display: block; top: 48px; right: 23px; width: 1px; height: calc(100% - 48px); }
  .story-steps li span { padding-top: 6px; }
  .story-process li,
  .story-process li:nth-child(even) { width: 100%; margin-right: 0; padding: 0 56px 32px 0; border: 0; border-right: 1px solid rgba(11,19,43,.18); }
  .story-process li::before,
  .story-process li:nth-child(even)::before { left: auto; right: -20px; width: 40px; height: 40px; }
  .story-process li > div { padding: 24px; }
  .story-founder,
  .story-founder-reverse { grid-template-columns: 1fr; padding: 16px; gap: 16px; }
  .story-founder-photo { min-height: 380px; }
  .story-founder-content { padding: 16px 8px 24px; }
  .story-founder-content h3 { font-size: 28px; }
  .story-values-grid,
  .story-change-grid { grid-template-columns: 1fr; }
  .story-change-grid { gap: 32px; }
  .story-change-before,
  .story-change-after { grid-column: 1; }
  .story-change-before { grid-row: 1; }
  .story-change-after { grid-row: 3; }
  .story-change-grid::before { grid-column: 1; grid-row: 2; justify-self: center; width: 1px; height: 32px; background: linear-gradient(to bottom, rgba(11,19,43,.18), var(--story-gold)); }
  .story-change-grid::after { grid-column: 1; grid-row: 2; align-self: end; justify-self: center; transform: rotate(-135deg); }
  .story-value:nth-child(3),
  .story-value:nth-child(4) { grid-column: auto; grid-row: auto; }
}

@media (max-width: 430px) {
  .story-wrap { width: calc(100% - 32px); }
  .story-page .story-hero { padding-top: 128px; }
  .story-hero h1 { font-size: 32px; }
  .story-founder-photo { min-height: 320px; }
  .story-steps li { padding-right: 64px; }
  .story-cta-button { width: 100%; padding-inline: 24px; }
  .story-final-actions { flex-direction: column; }
}

@media (prefers-reduced-motion: reduce) {
  .story-page *,
  .story-page *::before,
  .story-page *::after { scroll-behavior: auto !important; animation: none !important; transition-duration: .01ms !important; }
  .story-cta-button:hover { transform: none; }
}
