.av-story {
  --ink: #151630; --copy: #373849; --accent: #5829a8; --line: #dedbe8;
  --story-tint: #f3eef9;
  width: min(1140px, calc(100% - 64px)); margin-inline: auto;
  padding-block: clamp(48px, 5.5vw, 82px) clamp(56px, 7vw, 100px);
  color: var(--ink); font-family: Urbanist, Arial, sans-serif;
}
.av-story-layout { display: grid; grid-template-columns: minmax(0, 780px) minmax(215px, 1fr); column-gap: clamp(40px, 5.6vw, 80px); }
.av-story-page, .av-story-rail { min-width: 0; }
.av-story-editor-note { margin: 24px 0; padding: 4px 0 4px 16px; border-inline-start: 3px solid var(--accent); color: var(--copy); font-size: 16px; line-height: 1.55; }
.av-story-editor-note strong { color: var(--ink); }
.av-story-editor-note p { margin: 4px 0 0; }
.av-story-editor-note a { color: var(--accent); text-decoration: underline; text-underline-offset: .16em; }
.av-story-cover { display: grid; place-items: center; background: #f7f6fa; margin: 0 0 clamp(24px, 2.6vw, 37px); }
.av-story-cover img { display: block; width: 100%; height: auto; aspect-ratio: 2 / 1; object-fit: contain; }
.av-story-header h1 { color: var(--ink); font: 700 clamp(28px, 2.45vw, 35px)/1.26 Oxanium, Arial, sans-serif; margin: 0 0 12px; overflow-wrap: break-word; }
.av-story-meta { color: #575467; display: flex; flex-wrap: wrap; align-items: baseline; gap: 4px 8px; font-size: 15px; line-height: 1.55; }
.av-story-trail { display: inline-flex; align-items: baseline; gap: 8px; }
.av-story a { color: var(--accent); }
.av-story-meta a:hover, .av-story-end a:hover, .av-story-inline a:hover { text-decoration: underline; text-underline-offset: 3px; }
.av-story-follow { display: inline-flex; align-items: center; gap: 10px; margin: 22px 0 26px; min-height: 42px; border: 1px solid var(--line); padding: 8px 15px; border-radius: 6px; font-weight: 650; background: #fff; }
.av-story-follow:hover { border-color: var(--accent); background: var(--story-tint); }
.av-story .av-story-body, .av-story .av-story-body p {
  color: var(--copy); font: 500 18px/1.72 Urbanist, Arial, sans-serif; overflow-wrap: break-word;
}
.av-story .av-story-body p { margin: 0 0 1.13em; }
.av-story-body [data-story-lead] { color: var(--ink); }
.av-story-body [data-story-lead]::first-line { background: #f0e8fb; color: var(--ink); }
.av-story-body > :first-child { margin-top: 0; }
.av-story-body img { max-width: 100%; height: auto; }
.av-story-body figure { max-width: 100%; margin: 25px 0; }
.av-story-body figcaption { color: #59596b; font-size: 15px; line-height: 1.45; margin-top: 7px; }
.av-story-body :is(ol,ul), .av-story-related ul { padding-inline-start: 1.45em; }
.av-story-body li { margin: 0 0 .45em; }
.av-story-body a:not([role=button]) { text-decoration: underline; text-decoration-thickness: 1px; text-underline-offset: .15em; }
.av-story .av-story-body :is(h2,h3,h4,h5,h6) { color: var(--ink); text-wrap: pretty; line-height: 1.35; font-family: Oxanium,Arial,sans-serif; }
.av-story-body :is([id], [data-story-level]), #article-top { scroll-margin-top: 100px; }
.av-story .av-story-body [data-story-level=chapter] { text-align: center; font-size: clamp(24px, 2.15vw, 30px); margin: 46px 0 22px; }
.av-story-body [data-story-level=chapter]::before { display: block; width: 64px; height: 2px; background: #9b8aaf; margin: 0 auto 14px; content: ""; }
.av-story .av-story-body [data-story-level=subsection] { margin: 30px 0 15px; padding: 11px 16px; background: var(--story-tint); border-inline-start: 4px solid #7c56bd; font-size: 21px; }
.av-story .av-story-body h4[data-story-level=subsection] { background: transparent; border: 0; padding: 0; font-size: 19px; }
.av-story .av-story-inline { padding: 4px 0 0; margin: 25px 0 30px; font-size: 17px; line-height: 1.55; }
.av-story .av-story-inline h2 { font-size: 18px; margin: 0 0 8px; }
.av-story-inline ul { margin: 0; }
.av-story .av-story-inline a { text-decoration: none; }
.av-story .av-story-body table { width: 100%; max-width: 100%; height: auto !important; border-collapse: collapse; margin-block: 20px 28px; font-size: 16px; line-height: 1.55; }
.av-story-body :is(td,th) { text-align: start; vertical-align: top; padding: 10px 12px; border: 1px solid var(--line); overflow-wrap: anywhere; }
.av-story .av-story-body th { background: #eae2f7; color: var(--ink); }
.av-story-body pre { white-space: pre-wrap; overflow-wrap: anywhere; max-width: 100%; }
.av-story-body pre > code.code-container { display: block; max-width: 100%; overflow-x: auto; white-space: pre; }
.av-story-body blockquote { border-left: 4px solid var(--accent); padding: 12px 20px; margin: 24px 0; background: var(--story-tint); }
.av-story-end { display: block; position: static; background: transparent; color: var(--copy); }
.av-story-end section, .av-story-related { margin-top: 40px; padding-top: 23px; border-top: 1px solid var(--line); }
.av-story-end h2 { font: 700 23px/1.35 Oxanium,Arial,sans-serif; color: var(--ink); margin: 0 0 16px; }
.av-story-publisher > div { display: flex; gap: 18px; align-items: flex-start; }
.av-story-publisher img { width: 70px; height: 70px; border-radius: 50%; border: 1px solid var(--line); padding: 10px; object-fit: contain; }
.av-story-publisher h3 { color: var(--ink); font-size: 19px; margin: 0 0 6px; }
.av-story-publisher p { color: var(--copy); font-size: 16px; line-height: 1.6; margin: 0 0 8px; }
.av-story-related li { margin-bottom: 8px; }
.av-story-endlinks { margin-top: 24px; display: flex; justify-content: space-between; gap: 16px; }
.av-story-tags { margin-top: 20px; font-size: 15px; }
.av-story-tags .tagcloud { display: flex; flex-wrap: wrap; gap: 6px 13px; padding: 12px 0; }
.av-story .av-story-tags .tagcloud a { font-size: 15px !important; }
.av-story-rail > .av-blog-sidebar { padding: 0; border: 0; grid-template-columns: 1fr; }
.av-story-rail .av-blog-sidebar h2 { font-size: 21px; }
.av-story-chapters { position: sticky; top: 96px; margin-top: 34px; border: 1px solid var(--line); border-radius: 8px; background: #faf9fc; }
.av-story summary { cursor: pointer; }
.av-story-chapters summary { padding: 12px 14px; font-weight: 700; }
.av-story-chapters summary svg { vertical-align: -.18em; margin-right: 3px; }
.av-story-chapters nav { max-height: min(65vh, 620px); overflow: auto; overscroll-behavior: contain; padding: 0 14px 12px; }
.av-story-chapters ul, .av-story-dialog ul { list-style: none; padding: 0; margin: 0; }
.av-story-chapters a, .av-story-dialog nav a { display: block; padding: 7px 7px 7px 11px; border-inline-start: 2px solid transparent; font: 600 15px/1.4 Urbanist,Arial,sans-serif; color: var(--copy); }
.av-story-subitem { padding-inline-start: 10px; }
.av-story-subitem a { font-weight: 500; }
.av-story :is(.av-story-chapters,.av-story-dialog) a:is(:hover,[aria-current=location]) { border-color: var(--accent); color: var(--accent); background: var(--story-tint); }
.av-story-toggle, .av-story-dialog:not([open]), .av-story-toggle[hidden] { display: none; }
.av-story :focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; }
.av-story :is([data-story-level]):focus:not(:focus-visible) { outline: 0; }
.av-story-dialog { width: min(370px, calc(100% - 36px)); margin: auto; max-height: 75vh; max-height: 75dvh; overflow: auto; border: 1px solid #cbc5db; border-radius: 12px; padding: 0 16px 16px; color: var(--ink); background: white; overscroll-behavior: contain; }
.av-story-dialog::backdrop { background: rgb(15 17 43 / 45%); }
.av-story-dialog > div { position: sticky; top: 0; display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 10px 0; background: white; border-bottom: 1px solid var(--line); }
.av-story-dialog h2 { font-size: 21px; margin: 0; }
.av-story-dialog button { width: 44px; height: 44px; background: var(--story-tint); border-radius: 50%; font-size: 25px; color: var(--ink); }
.av-story-dialog nav a { min-height: 44px; align-content: center; }
@media (max-width: 800px) {
  .av-story { width: calc(100% - 48px); padding-top: 32px; }
  .av-story-layout { display: block; }
  .av-story-rail { margin-top: 36px; padding-top: 28px; border-top: 1px solid var(--line); }
  .av-story-chapters { display: none; }
  .av-story-toggle:not([hidden]) { display: grid; place-items: center; position: fixed; right: 0; top: 52%; z-index: 50; width: 42px; height: 44px; color: var(--accent); border: 1px solid var(--line); border-right: 0; border-radius: 8px 0 0 8px; background: #fff; box-shadow: 0 2px 8px #24164416; }
  /* Reserve the remainder of the 48px contents-button gutter while reading a guide. */
  .av-story:has(.av-story-toggle:not([hidden])) .guide-body { margin-inline-end: 24px; }
  .av-story .av-story-body, .av-story .av-story-body p { font-size: 17px; line-height: 1.65; }
  .av-story-body :is([id], [data-story-level]) { scroll-margin-top: 88px; }
}
@media (max-width: 600px) {
  .av-story-header h1 { font-size: 27px; }
  .av-story-meta { font-size: 14px; }
  .av-story .av-story-body [data-story-level=chapter] { margin-top: 36px; }
  .av-story-body:not(.guide-body) table { table-layout: fixed; }
  .av-story-body:not(.guide-body) :is(th,td) { padding: 6px; font-size: 14px; }
  .av-story-publisher > div { gap: 12px; }
  .av-story-publisher img { width: 48px; height: 48px; padding: 6px; }
}
@media (max-width: 360px) {
  .av-story { width: calc(100% - 32px); }
  .av-story:has(.av-story-toggle:not([hidden])) .guide-body { margin-inline-end: 32px; }
}
.av-story-header .av-story-trail { font-size:14px; font-weight:750; margin:0 0 14px; }
.av-story-header .av-story-trail a { color:#652575; }
.av-story-header h1 { font-size:clamp(30px,3.25vw,44px); line-height:1.15; }
.av-story-header .av-story-deck { max-width:69ch; margin:14px 0 16px; color:var(--copy); font:500 clamp(17px,1.45vw,20px)/1.52 Urbanist,Arial,sans-serif; }
.av-story-reader,.av-story-share { display:flex; align-items:center; flex-wrap:wrap; gap:6px; }
.av-story-header .av-story-meta { margin:6px 0 20px; }
.av-story-meta strong { color:var(--ink); }
.av-read-time { font-size:14px; color:#575467; border-inline-start:1px solid var(--line); margin-inline-start:6px; padding-inline-start:14px; }
.av-story-header .av-story-cover { margin:0; border-radius:8px; overflow:hidden; }
.av-story-sources { display:flex; flex-wrap:wrap; gap:10px; margin:0 0 30px; }
.av-story-sources a { display:inline-flex; align-items:center; gap:8px; max-width:100%; box-sizing:border-box; padding:10px 20px; background:#fff; border:1px solid #dadce0; border-radius:8px; color:#3c4043; font:500 17px/1.2 Urbanist,Arial,sans-serif; letter-spacing:.025em; text-decoration:none; box-shadow:none; transition:background .2s,border-color .2s; }
.av-story-sources a:is(:hover,:focus-visible) { background:#f8f9fa; border-color:#c6c9cc; text-decoration:none; }
.av-story-sources img { flex:none; width:30px; height:30px; object-fit:contain; margin:0; }
.av-story-header .av-story-cover { margin-bottom:24px; }
.av-story-share :is(a,button) { box-sizing:border-box; display:inline-flex; align-items:center; justify-content:center; gap:7px; min-width:44px; min-height:44px; padding:7px 12px; background:white; border:1px solid var(--line); border-radius:7px; font:650 14px/1.3 Urbanist,Arial,sans-serif; color:var(--ink); cursor:pointer; }
.av-story-share :is(a,button):is(:hover,:focus-visible) { color:var(--accent); background:var(--story-tint); border-color:#c2aed8; text-decoration:none; }
.av-story-share [hidden] { display:none; }
.av-share-compact { gap:1px; }
.av-share-compact :is(a,button) { border-color:transparent; font-size:17px; padding:0; }
.av-copy-status { color:#582969; font-size:14px; }
.av-copy-status:empty { display:none; }
.av-copy-field { width:min(100%,300px); }
.av-share-end { display:flex; align-items:center; justify-content:space-between; gap:12px 18px; flex-wrap:wrap; }
.av-story-end .av-share-end h2 { margin:0; font-size:19px; }
.av-story-end .av-story-publisher { margin:24px 0; }
.av-story-adjacent { display:grid; grid-template-columns:repeat(2,minmax(0,1fr)); border-block:1px solid var(--line); padding-block:18px; gap:20px; }
.av-story-adjacent a { display:grid; align-content:start; gap:8px; min-width:0; padding:4px; }
.av-story-adjacent small { color:#625771; font-size:14px; font-weight:650; }
.av-story-adjacent a > span { display:flex; align-items:center; gap:12px; }
.av-story-adjacent img { width:82px; height:auto; aspect-ratio:2 / 1; object-fit:contain; border-radius:4px; }
.av-story-adjacent strong { color:var(--ink); font:700 17px/1.35 Urbanist,Arial,sans-serif; }
.av-adjacent-next { grid-column:2; text-align:end; }
.av-adjacent-next > span { flex-direction:row-reverse; }
:is(#article-share,#article-navigation) { scroll-margin-top:94px; }
@media (max-width:600px) {
  .av-story-adjacent { grid-template-columns:1fr; gap:8px; }
  .av-adjacent-next { grid-column:1; }
  .av-story-sources { gap:8px; }
  .av-story-sources a { padding-inline:14px; }
}
@media print {
  .av-story-layout { display:block; }
  .av-story-reader,.av-story-sources,.av-story-rail,.av-story-toggle,.av-story-end,.av-site-header { display:none !important; }
}
