@font-face {
  font-family: Vazirmatn;
  src: url("assets/fonts/Vazirmatn-Regular.woff2") format("woff2");
  font-weight: 400;
  font-display: swap;
}
@font-face {
  font-family: Vazirmatn;
  src: url("assets/fonts/Vazirmatn-Medium.woff2") format("woff2");
  font-weight: 500;
  font-display: swap;
}
@font-face {
  font-family: Vazirmatn;
  src: url("assets/fonts/Vazirmatn-SemiBold.woff2") format("woff2");
  font-weight: 600;
  font-display: swap;
}
@font-face {
  font-family: Vazirmatn;
  src: url("assets/fonts/Vazirmatn-Bold.woff2") format("woff2");
  font-weight: 700;
  font-display: swap;
}

:root {
  color-scheme: light;
  --navy: #26356e;
  --deep: #1a2552;
  --ink: #202b40;
  --muted: #4a576a;
  --line: #cfd6e1;
  --surface: #f1f4f8;
  --paper: #fff;
  --blue-light: #c9d9ff;
  --gutter: clamp(1.125rem, 4.8vw, 5.25rem);
  --width: 78rem;
}
* { box-sizing: border-box; }
html { scroll-padding-block-start: 1rem; }
body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: Vazirmatn, Tahoma, sans-serif;
  font-size: 1rem;
  line-height: 1.9;
}
img { display: block; max-inline-size: 100%; }
a { color: var(--navy); text-underline-offset: .32em; text-decoration-thickness: 1px; }
a:hover { text-decoration-thickness: 2px; }
button, input, select { font: inherit; }
button, summary { cursor: pointer; }
:focus-visible { outline: 3px solid #3469bf; outline-offset: 4px; }
[hidden] { display: none !important; }
h1, h2, h3, p, dl, dd, figure { margin: 0; }
h1, h2, h3 { color: var(--deep); line-height: 1.5; text-wrap: pretty; }
h1 { font-size: clamp(2rem, 4vw, 3.35rem); }
h2 { font-size: clamp(1.5rem, 2.6vw, 2.35rem); }
h3 { font-size: clamp(1.125rem, 1.56vw, 1.4rem); }
p { color: var(--muted); }
.wrap { width: min(calc(100% - var(--gutter) * 2), var(--width)); margin-inline: auto; }
.button {
  display: inline-flex; align-items: center; justify-content: center; gap: .6rem;
  min-height: 3rem; padding: .48rem 1.35rem; border: 1px solid transparent; border-radius: .4rem;
  background: var(--navy); color: #fff; font-weight: 600; text-align: center; text-decoration: none;
}
.button:hover { background: var(--deep); }
.button svg, .menu-toggle svg { inline-size: 1.15rem; block-size: 1.15rem; }
.text-link {
  display: inline-flex; align-items: center; gap: .45rem; min-height: 2.75rem;
  font-weight: 600; color: var(--navy); text-decoration: underline; text-decoration-color: #8a99bb;
}
.text-link:hover { text-decoration-color: currentColor; }
.actions { display: flex; flex-wrap: wrap; align-items: center; gap: .75rem 1.4rem; margin-block-start: 1.65rem; }
.skip { position: absolute; inset: -10rem auto auto 1rem; z-index: 10; padding: .45rem .85rem; background: var(--deep); color: #fff; border-radius: .3rem; }
.skip:focus-visible { top: .35rem; }

#site-header { position: relative; z-index: 2; background: #fff; border-bottom: 1px solid var(--line); }
.header-inner { display: flex; align-items: center; min-height: 4.4rem; gap: .75rem; }
.brand { display: inline-flex; align-items: center; min-height: 2.75rem; flex: none; text-decoration: none; }
.brand img { width: clamp(5.85rem, 10vw, 8.8rem); height: auto; }
.desktop-nav, .nojs-menu { display: none; }
.header-actions { margin-inline-start: auto; display: flex; align-items: center; gap: 1.1rem; }
.header-contact, .desktop-nav a { color: var(--ink); font-size: .94rem; white-space: nowrap; font-weight: 500; text-decoration: none; }
.header-contact { display: none; }
#portal-entry { min-height: 2.75rem; padding-inline: .9rem; font-size: .94rem; white-space: nowrap; }
.menu-toggle {
  width: 2.75rem; height: 2.75rem; flex: none; display: flex; align-items: center; justify-content: center; flex-direction: column;
  gap: 4px; border: 1px solid var(--line); border-radius: .4rem; background: white; color: var(--navy);
}
.menu-toggle span { width: 17px; height: 2px; background: currentColor; }
.menu-toggle[aria-expanded="true"] { background: var(--surface); border-color: var(--navy); }
#small-nav { padding: .5rem var(--gutter) 1rem; border-top: 1px solid var(--line); background: white; }
#small-nav a, .nojs-menu nav a { display: block; text-decoration: none; min-height: 2.75rem; padding: .45rem .65rem; border-radius: .25rem; }
#small-nav a[aria-current], .nojs-menu a[aria-current] { color: var(--deep); background: var(--surface); font-weight: 700; }
.nojs-menu { display: block; background: white; }
.nojs-menu summary { padding: .5rem 0; font-weight: 600; color: var(--navy); }
#portal-dialog { width: min(24rem, calc(100% - 2.5rem)); border: 1px solid var(--line); border-radius: .65rem; padding: 1.5rem; color: var(--ink); background: white; }
#portal-dialog h2 { margin-block-end: .5rem; font-size: 1.5rem; }
#portal-dialog form { margin-block-start: 1.25rem; display: flex; justify-content: flex-end; }
#portal-dialog::backdrop { background: rgb(15 23 48 / 60%); }

.landing-hero { display: grid; margin-inline: auto; max-width: 105rem; color: white; background: var(--deep); }
.hero-copy { position: relative; padding: 1.75rem var(--gutter) 1.85rem; background: linear-gradient(135deg, #2a3a78, var(--deep) 72%); }
.hero-copy::before {
  content: ""; display: block; width: 3.25rem; height: 3px; margin-block-end: 1.25rem;
  background: linear-gradient(to left, var(--blue-light) 68%, transparent 68%, transparent 76%, #738dc3 76%);
}
.hero-copy h1 { color: white; font-size: clamp(2.75rem, 8vw, 4.5rem); line-height: 1.32; }
.hero-copy h1 span { color: var(--blue-light); }
.hero-intro { max-width: 39ch; margin-block-start: 1rem; color: #edf1fb; line-height: 1.95; font-size: clamp(1rem, 1.25vw, 1.125rem); }
.hero-copy .actions { gap: .35rem 1.2rem; margin-block-start: 1.35rem; }
.hero-copy .button { background: white; color: var(--deep); }
.hero-copy .button:hover { background: #e5edff; }
.hero-copy .text-link { color: #fff; text-decoration-color: #9eafd1; }
.hero-copy :focus-visible, #site-footer :focus-visible { outline-color: #c9dcff; }
.hero-photo { position: relative; min-width: 0; background: #a1aab4; }
.hero-photo img { width: 100%; height: auto; aspect-ratio: 1.73; object-fit: cover; object-position: center 62%; }
.hero-photo figcaption {
  position: absolute; inset-inline-start: .85rem; bottom: .75rem; max-width: calc(100% - 1.7rem); margin: 0;
  color: #fff; background: rgb(23 32 52 / 86%); font-size: .75rem; padding: .12rem .55rem; border-radius: .18rem;
}

.home-directory { display: grid; gap: 1.35rem; padding-block: clamp(2.65rem, 5vw, 5rem); }
.directory-heading h2, .reading-heading h2 { line-height: 1.5; }
.directory-heading p { max-width: 32ch; margin-block: .55rem .35rem; }
.directory-links { display: grid; }
.directory-links > a { display: block; border-block-start: 1px solid var(--line); padding-block: .95rem 1.1rem; text-decoration: none; }
.directory-links h3, .reading-feature h3 a, .reading-list h3 a { color: var(--navy); text-decoration: none; }
.directory-links > a:hover h3, .reading-feature h3 a:hover, .reading-list h3 a:hover { text-decoration: underline; text-underline-offset: .25em; }
.directory-links p, .reading-list p { margin-block-start: .2rem; }
.home-reading { border-block: 1px solid #e1e5ec; padding-block: clamp(2.6rem, 5vw, 4.8rem); background: var(--surface); }
.reading-heading { display: flex; align-items: baseline; justify-content: space-between; flex-wrap: wrap; gap: .35rem 1rem; margin-block-end: 1.3rem; }
.reading-grid { display: grid; gap: 1.4rem; }
.reading-feature { overflow: hidden; background: white; border: 1px solid #dce2ec; border-radius: .5rem; }
.reading-feature img { width: 100%; height: auto; aspect-ratio: 2.2; object-fit: cover; object-position: 50% 58%; }
.reading-feature > div { padding: 1rem 1.2rem 1.25rem; }
.reading-feature h3 { font-size: clamp(1.25rem, 2vw, 1.8rem); }
.reading-feature p { margin-block-start: .45rem; }
.reading-list { display: grid; align-content: start; }
.reading-list article { padding-block: 1.2rem 1.35rem; border-top: 1px solid var(--line); }
.reading-list article:first-child { border-color: var(--navy); }
.home-owner { padding-block: clamp(2.5rem, 5vw, 5rem); display: grid; align-items: center; gap: 1rem; }
.home-owner img { width: 6.5rem; height: auto; }
.home-owner p { margin-block: .6rem .3rem; max-width: 63ch; }

#site-footer { background: var(--deep); color: white; }
#site-footer p { color: #dce4f8; }
#site-footer a { color: white; }
.foot { display: flex; align-items: flex-start; justify-content: space-between; flex-wrap: wrap; gap: 1.4rem 3rem; padding-block: 2.4rem 1.9rem; }
.foot-title { display: inline-flex; align-items: center; min-height: 2.75rem; font-size: 1.6rem; font-weight: 700; text-decoration: none; }
.foot p { max-width: 38ch; }
.foot nav { display: flex; flex-wrap: wrap; gap: .2rem 1.2rem; }
.foot nav a { min-height: 2.75rem; display: inline-flex; align-items: center; font-size: .95rem; text-decoration: none; }
.foot nav a:hover, .header-contact:hover, .desktop-nav a:hover { text-decoration: underline; }
.owner { margin-inline: auto; padding-block: .85rem; border-top: 1px solid #53638a; color: #d7dff1; font-size: .875rem; }

.crumb { margin-block: 1.25rem 1.65rem; color: #556379; font-size: .9rem; line-height: 2; }
.crumb a { color: var(--navy); }
.crumb span[aria-hidden] { color: #7b879d; margin-inline: .4rem; }
.lede { max-width: 60ch; color: var(--muted); font-size: clamp(1.05rem, 1.5vw, 1.2rem); margin-block-start: .85rem; }
.service-lead { display: grid; align-items: center; gap: 1.6rem; padding-block: .3rem 2.5rem; }
.service-lead h1 { color: var(--navy); }
.document-panel { border-radius: .5rem; padding: 1.35rem 1.5rem; background: var(--deep); color: white; }
.document-panel h2 { padding-bottom: 1rem; color: white; font-size: 1.4rem; }
.document-panel dl div { padding-block: .6rem; border-top: 1px solid #5f7098; }
.document-panel dt { color: #d5e0fa; font-size: .9rem; }
.document-panel dd { font-size: 1.125rem; }
.service-body { border-block: 1px solid var(--line); background: var(--surface); }
.guide-grid { display: grid; gap: 1.75rem; padding-block: 2.3rem 3.5rem; }
.section-menu { align-self: start; border-top: 3px solid var(--navy); }
.section-menu h2 { padding-block: .7rem .35rem; font-size: 1.18rem; }
.section-menu a { display: block; padding: .5rem 0; border-bottom: 1px solid var(--line); text-decoration: none; }
.section-menu a:hover { text-decoration: underline; }
.guide-sections { max-width: 75ch; }
.guide-sections section + section { border-top: 1px solid var(--line); margin-top: 1.65rem; padding-top: 1.65rem; }
.guide-sections h2, .editorial h2 { font-size: clamp(1.3rem, 2.1vw, 1.8rem); }
.guide-sections p + p { margin-block-start: .6rem; }

.editorial { max-width: 56rem; min-height: 65vh; padding-bottom: clamp(3rem, 6vw, 5rem); }
.editorial h1, .catalog h1 { color: var(--navy); }
.editorial h2 { margin: 2rem 0 .6rem; }
.editorial h3 { margin: .85rem 0 .4rem; }
.editorial .lede { margin-block: .75rem 1.8rem; }
.panel, .note { margin-block: 1.35rem; padding: 1.15rem 1.3rem; border-radius: .4rem; }
.panel { background: #fff; border: 1px solid var(--line); }
.note { background: var(--surface); border-inline-start: 3px solid var(--navy); }
.editorial :is(.panel, .note) h2:first-child { margin-top: 0; }
.editorial :is(p, li) .text-link { display: inline; min-height: auto; }
.article-list { margin-top: 1.5rem; }
.editorial details { border-block-start: 1px solid var(--line); }
.editorial details:not(.panel) { padding-block: .25rem; }
.editorial summary { padding-block: .5rem; min-height: 2.75rem; color: var(--navy); font-size: 1.125rem; font-weight: 600; }
.editorial summary::marker, .flow-list li::marker { color: var(--navy); }
.editorial details[open] summary { margin-block-end: .5rem; }
.editorial details p { margin-block: .6rem; }
.flow-list { padding-inline-start: 1.5rem; }
.flow-list li + li { margin-block-start: .55rem; }
.fine { font-size: .9rem; }
.divider { border: 0; border-top: 1px solid var(--line); margin-block: 1.75rem; }
.catalog { padding-block-end: clamp(3rem, 6vw, 5rem); }
.catalog .lede { max-width: 65ch; }
.catalog-grid { display: grid; gap: 0 3rem; margin-block: 2rem; }
.catalog-grid section { border-top: 1px solid var(--line); padding-block: 1.1rem 1.35rem; }
.catalog-grid h2, .catalog .note h2 { font-size: 1.35rem; margin-block-end: .4rem; }
.catalog-grid h2 a { text-decoration-color: #a2aec6; }
.catalog-grid p { max-width: 54ch; }

@media (max-width: 369px) {
  .header-inner { gap: .5rem; }
  #portal-entry { font-size: .875rem; padding-inline: .55rem; }
}
@media (max-width: 760px) {
  .hero-photo { grid-row: 1; }
  .hero-copy::before { display: none; }
  .hero-copy .actions { margin-block-start: 1rem; gap: .25rem 1rem; }
  .hero-copy .button { padding-inline: 1rem; }
}
@media (min-width: 520px) {
  .header-contact { display: inline-flex; min-height: 2.75rem; align-items: center; }
  .directory-links, .catalog-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .directory-links { gap: 0 1.8rem; }
  .home-owner { grid-template-columns: 8rem 1fr; gap: 2rem; }
  .home-owner img { width: 100%; }
}
@media (min-width: 761px) {
  .landing-hero { grid-template-columns: minmax(0, .86fr) minmax(0, 1.14fr); }
  .hero-copy {
    min-height: clamp(26rem, 33vw, 35rem); display: flex; align-items: start; justify-content: center; flex-direction: column;
    padding-block: clamp(2.7rem, 4vw, 4.5rem);
    padding-inline: max(var(--gutter), calc((100% / .43 - var(--width)) / 2)) clamp(1.5rem, 3.4vw, 3.8rem);
  }
  .hero-copy h1 { font-size: clamp(2.75rem, 4.55vw, 4.85rem); }
  .hero-photo img { position: absolute; inset: 0; height: 100%; width: 100%; aspect-ratio: auto; object-position: 50% 57%; }
  .hero-photo figcaption { inset-inline-start: auto; inset-inline-end: 1.25rem; bottom: 1.15rem; }
  .home-directory { grid-template-columns: minmax(0, .8fr) minmax(0, 1.55fr); align-items: center; gap: clamp(2.5rem, 5.8vw, 6rem); }
  .directory-links a { padding-block: 1.3rem 1.45rem; }
  .reading-grid { grid-template-columns: minmax(0, 1.35fr) minmax(0, 1fr); gap: 2.8rem; }
  .reading-heading { margin-block-end: 1.9rem; }
  .reading-feature { display: grid; grid-template-columns: .77fr 1fr; }
  .reading-feature img { height: 100%; min-height: 14rem; aspect-ratio: auto; }
  .reading-feature > div { align-self: center; padding: 1.35rem; }
  .home-owner { grid-template-columns: minmax(10rem, .56fr) minmax(0, 1.44fr); }
  .home-owner img { width: 10rem; justify-self: center; }
  .service-lead { grid-template-columns: 1.2fr .8fr; gap: clamp(2.5rem, 6vw, 6rem); padding-block: 1rem 3.5rem; }
  .guide-grid { grid-template-columns: .34fr 1fr; gap: 3.5rem; }
  .crumb { margin-block: 1.9rem 2rem; }
  .panel, .note, .document-panel { padding: 1.55rem 1.85rem; }
}
@media (min-width: 1001px) {
  .header-inner { gap: clamp(1.35rem, 2.6vw, 3rem); min-height: 5.25rem; }
  .desktop-nav { display: flex; align-self: stretch; align-items: stretch; gap: clamp(.85rem, 1.55vw, 1.8rem); }
  .desktop-nav a { display: flex; align-items: center; position: relative; }
  .desktop-nav a[aria-current], .header-contact[aria-current] { color: var(--navy); font-weight: 700; }
  .desktop-nav a[aria-current]::after { position: absolute; content: ""; inset-inline: 0; bottom: 0; height: 3px; background: var(--navy); }
  #small-nav, .menu-toggle, .nojs-menu { display: none; }
}
@media (min-width: 761px) and (max-width: 900px) {
  .landing-hero { grid-template-columns: minmax(0, 1fr) minmax(0, 1.05fr); }
  .hero-copy { min-height: 25rem; padding: 1.85rem var(--gutter) 1.85rem 1.65rem; }
  .hero-copy h1 { font-size: 2.65rem; }
}
@media print {
  #site-header, #site-footer, .section-menu, .hero-copy .actions { display: none; }
  body { color: #000; }
  .wrap, .editorial { width: 100%; max-width: none; }
  .note, .panel, .document-panel, .editorial details { break-inside: avoid; }
}
