:root {
  color-scheme: light;
  --page: #e7d8df;
  --ink: #371e3c;
  --primary: #9425ab;
  --accent: #0a595a;
  --paper: #fbf5f8;
  --soft: #f3e7ee;
  --tint: #eadbee;
  --mint: #d8e9e5;
  --muted: #654b68;
  --rule: #aa8eaa;
  --shadow: 0 6px 18px #371e3c12;
  --shadow-hover: 0 9px 24px #371e3c29;
  --shadow-time: 250ms;
  --section-gap: 52px;
}

html {
  box-sizing: border-box;
}

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

html:has(dialog:modal) {
  overflow: hidden;
}

body {
  margin: 0;
  background: var(--page);
  color: var(--ink);
  font-size: 16px;
  font-weight: 400;
  line-height: 1.4;
  overflow-wrap: anywhere;
}

button {
  color: inherit;
  font-size: inherit;
  font-weight: 600;
  line-height: inherit;
  cursor: pointer;
}

strong, b, th {
  font-weight: 700;
}

em, i, cite, address {
  font-style: normal;
}

a {
  color: var(--primary);
  text-underline-offset: 0.2em;
}

:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 4px;
}

.read-main, .visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip-path: inset(50%);
  white-space: nowrap;
}

.read-main:focus {
  position: fixed;
  z-index: 5;
  top: 12px;
  left: 16px;
  width: auto;
  height: auto;
  padding: 10px 16px;
  clip-path: none;
  border-radius: 10px;
  background: var(--paper);
  color: var(--accent);
  font-weight: 700;
}

.brand-row, .navigation-row, .main-content-frame, .credits-row {
  width: calc(100% - 32px);
  max-width: 1244px;
  margin-inline: auto;
  padding-inline: 0;
}

.edition-head {
  position: sticky;
  z-index: 3;
  top: 0;
  border-bottom: 1px dotted var(--rule);
  background: var(--paper);
}

.brand-row {
  display: grid;
  min-height: 90px;
  padding-block: 12px;
  place-items: center;
}

.edition-home {
  display: flex;
  max-width: 100%;
  align-items: center;
  gap: 10px;
  color: var(--ink);
  text-decoration: none;
}

.edition-home img {
  display: block;
  width: 40px;
  height: 40px;
  flex: none;
}

.edition-title {
  min-width: 0;
  font-size: 22px;
  font-weight: 700;
  letter-spacing: -0.035em;
}

.navigation-row {
  position: relative;
}

.navigation-row > #edition-nav {
  position: absolute;
  top: 30px;
  left: 0;
  width: 244px;
  max-width: 100%;
  max-height: max(56px, calc(100dvh - 130px));
  padding: 16px;
  overflow: auto;
  border-radius: 20px;
  background: var(--paper);
  box-shadow: var(--shadow);
}

.nav-caption {
  display: flex;
  align-items: center;
  gap: 8px;
  margin: 0 0 12px;
  color: var(--accent);
  font-weight: 700;
}

.mark {
  display: block;
  width: 30px;
  height: 30px;
  flex: none;
}

.nav-list, .credit-list, .topic-list {
  margin: 0;
  padding: 0;
  list-style: none;
}

.nav-list a, .credit-list a {
  display: block;
  padding: 10px 14px;
  border-radius: 10px;
  background: var(--tint);
  color: var(--ink);
  font-weight: 600;
  text-decoration: none;
}

.nav-list a[aria-current], .credit-list a[aria-current] {
  color: var(--primary);
}

.nav-dot {
  display: block;
  color: var(--accent);
  font-weight: 700;
  line-height: 12px;
  text-align: center;
}

.nav-switch, .dialog-close, .slide-link, .slide-arrow, .slide-dot {
  display: inline-grid;
  width: 44px;
  height: 44px;
  flex: none;
  padding: 0;
  place-items: center;
  border: 0;
  border-radius: 12px;
  background: var(--primary);
  color: #fff;
  text-decoration: none;
}

.nav-switch {
  display: none;
}

.nav-dialog {
  width: 100%;
  max-width: none;
  height: 100%;
  max-height: none;
  margin: 0;
  padding: 20px 22px 32px;
  overflow: auto;
  overscroll-behavior: contain;
  border: 0;
  background: var(--paper);
  color: var(--ink);
}

.dialog-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 24px;
  padding-bottom: 16px;
  border-bottom: 1px dotted var(--rule);
}

.dialog-top h2 {
  margin: 0;
  font-size: 24px;
  font-weight: 700;
}

.nav-dialog .nav-list a {
  min-height: 48px;
  padding: 13px 16px;
}

.main-content-frame, .credits-row {
  display: grid;
  grid-template-columns: 244px minmax(0, 1fr);
  column-gap: 38px;
}

.main-content-frame {
  padding-block-start: 30px;
  scroll-margin-top: 104px;
}

.content-column, .credits {
  min-width: 0;
  grid-column: 2;
}

.home-flow {
  display: grid;
  gap: var(--section-gap);
}

.opening {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 26%);
  align-items: center;
  gap: 24px;
  padding-block: 18px 26px;
  border-bottom: 1px dotted var(--rule);
}

.opening h1, .story-heading h1 {
  margin: 0;
  font-size: 62px;
  font-weight: 700;
  letter-spacing: -0.055em;
  line-height: 1.06;
}

.opening p {
  max-width: 50ch;
  margin: 16px 0 0;
  color: var(--muted);
}

.opening-art {
  display: block;
  width: 100%;
  max-width: 256px;
  height: auto;
  justify-self: end;
}

.section-title {
  display: flex;
  align-items: center;
  gap: 10px;
  margin: 0 0 17px;
  font-size: 30px;
  font-weight: 700;
  letter-spacing: -0.035em;
  line-height: 1.16;
}

.section-title .mark {
  color: var(--accent);
}

.ruled-section {
  padding-block-start: 20px;
  border-top: 1px dotted var(--rule);
}

.post-list {
  display: grid;
  grid-template-columns: minmax(0, 1.08fr) minmax(0, 0.92fr);
  gap: 26px;
}

.post {
  --preview-height: 101.25px;
  --preview-limit: 440px;
  display: grid;
  min-width: 0;
  grid-template-columns: 180px minmax(0, 1fr);
  align-items: center;
  gap: 20px;
  padding: 20px;
  border-radius: 20px;
  background: var(--paper);
  box-shadow: var(--shadow);
  text-align: center;
}

.post:first-child {
  grid-column: 1 / -1;
}

.post:nth-child(2) {
  --preview-height: 81px;
  --preview-limit: 352px;
  grid-template-columns: minmax(0, 1fr) 180px;
  background: #f7edf4;
}

.post:nth-child(2) .post-preview {
  grid-column: 2;
  grid-row: 1;
}

.post:nth-child(2) .post-copy {
  grid-column: 1;
  grid-row: 1;
}

.post:nth-child(3) {
  --preview-height: 90px;
  --preview-limit: 396px;
}

.post-preview {
  display: grid;
  width: 100%;
  min-width: 0;
  place-items: center;
}

.post-preview img {
  display: block;
  width: auto;
  max-width: 100%;
  height: var(--preview-height);
  aspect-ratio: 16 / 9;
  border-radius: 12px;
  background: var(--tint);
  object-fit: cover;
}

.post-copy {
  min-width: 0;
}

.post h3 {
  margin: 0;
  font-size: 22px;
  font-weight: 700;
  letter-spacing: -0.02em;
  line-height: 1.22;
}

.post h3 a {
  display: -webkit-box;
  overflow: hidden;
  color: var(--ink);
  text-decoration: none;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 3;
}

.post h3 a:focus-visible {
  text-decoration: underline;
}

.abstract {
  display: -webkit-box;
  max-width: 64ch;
  margin: 10px auto 0;
  overflow: hidden;
  color: var(--muted);
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 4;
}

.post-meta {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  gap: 6px 10px;
  margin: 13px 0 0;
  color: var(--muted);
  font-size: 14px;
}

.post-label {
  display: inline-block;
  padding: 4px 10px;
  border-radius: 100px;
  background: var(--mint);
  color: var(--accent);
  font-weight: 600;
}

.read-note {
  margin: 0;
}

.slider {
  min-width: 0;
  overflow: hidden;
  border: 1px solid var(--rule);
  border-radius: 20px;
  background: var(--paper);
}

.slide {
  display: grid;
  grid-template-columns: minmax(0, 35fr) minmax(0, 65fr);
  align-items: center;
}

.slide-preview {
  display: block;
  width: 100%;
  height: auto;
  aspect-ratio: 1;
  background: var(--tint);
  object-fit: cover;
}

.slide-copy {
  display: grid;
  min-width: 0;
  justify-items: start;
  gap: 20px;
  padding: 28px;
}

.slide-copy h3 {
  margin: 0;
  font-size: clamp(22px, 3vw, 36px);
  font-weight: 700;
  letter-spacing: -0.03em;
  line-height: 1.15;
}

.slide-controls {
  display: grid;
  justify-items: center;
  gap: 12px;
  padding: 14px 10px 16px;
  border-top: 1px dotted var(--rule);
  background: var(--soft);
}

.slide-buttons, .slide-dots {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 4px;
}

.slide-arrow[aria-disabled='true'] {
  background: var(--tint);
  color: var(--muted);
  cursor: default;
}

.slide-dot {
  width: 36px;
  background: var(--paper);
  color: var(--primary);
}

.slide-dot[aria-pressed='true'] {
  background: var(--accent);
  color: #fff;
}

.slide-position {
  display: block;
  width: min(100%, 252px);
  height: 6px;
  appearance: none;
  overflow: hidden;
  border: 0;
  border-radius: 6px;
  background: var(--tint);
  color: var(--accent);
  accent-color: var(--accent);
}

.slide-position::-webkit-progress-bar {
  background: var(--tint);
}

.slide-position::-webkit-progress-value {
  border-radius: 6px;
  background: var(--accent);
}

.slide-position::-moz-progress-bar {
  border-radius: 6px;
  background: var(--accent);
}

.slide[hidden], .slide-controls[hidden], .nav-switch[hidden] {
  display: none;
}

.topic-list {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.topic-list .post-label {
  padding: 8px 14px;
}

.post-page {
  max-width: 638px;
  margin-left: auto;
  margin-right: auto;
}

.story-heading {
  padding-block: 10px 22px;
  border-bottom: 1px dotted var(--rule);
}

.story-heading .post-meta {
  justify-content: flex-start;
  margin-top: 18px;
}

.post-page p, .post-page ul, .post-page ol {
  margin-block: 0 16px;
}

.post-page .read-note {
  margin: 0;
}

.post-page > :nth-child(2) {
  margin-top: 22px;
}

.post-page h2, .post-page h3 {
  margin-block: 28px 12px;
  font-weight: 700;
  line-height: 1.18;
}

.post-page h2 {
  font-size: 30px;
  letter-spacing: -0.035em;
}

.post-page h3 {
  font-size: 22px;
}

.post-page ul, .post-page ol {
  padding-inline-start: 24px;
}

.post-page ul {
  list-style-type: square;
}

.post-page li + li {
  margin-top: 6px;
}

.post-page li::marker {
  color: var(--accent);
}

.post-page blockquote {
  margin: 24px 0;
  padding: 18px 20px;
  border-radius: 16px;
  background: var(--paper);
  box-shadow: var(--shadow);
}

.post-page blockquote p:last-child {
  margin-bottom: 0;
}

.post-page cite {
  color: var(--accent);
  font-weight: 600;
}

.post-page img {
  max-width: 100%;
  height: auto;
}

.post-page table {
  width: 100%;
  min-width: 360px;
  margin: 0 0 16px;
  border-collapse: collapse;
  background: var(--paper);
}

.post-page caption {
  padding: 8px 0;
  color: var(--muted);
  font-weight: 600;
  text-align: start;
}

.post-page th, .post-page td {
  padding: 10px 12px;
  text-align: start;
  vertical-align: top;
}

.post-page thead th {
  background: var(--accent);
  color: #fff;
}

.post-page tbody tr:nth-child(even) {
  background: var(--soft);
}

.edition-foot {
  margin-block-start: var(--section-gap);
  border-top: 1px dotted var(--rule);
  background: var(--soft);
}

.credits {
  display: grid;
  gap: 10px;
  padding-block: 22px;
}

.credits p {
  margin: 0;
  color: var(--muted);
  font-size: 14px;
  font-weight: 600;
}

.credit-list {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.credit-list li {
  display: flex;
  align-items: center;
  gap: 8px;
}

.credit-list a {
  padding: 8px 12px;
}

:is(.post, .nav-switch, .dialog-close, .nav-list a, .credit-list a, .slide-link, .slide-arrow, .slide-dot) {
  transition: box-shadow var(--shadow-time) ease;
}

@media (hover: hover) {
  :is(.post, .nav-switch, .dialog-close, .nav-list a, .credit-list a, .slide-link, .slide-arrow:not([aria-disabled='true']), .slide-dot):hover {
    box-shadow: var(--shadow-hover);
  }
}

html[data-reduce-motion] :is(.post, .nav-switch, .dialog-close, .nav-list a, .credit-list a, .slide-link, .slide-arrow, .slide-dot) {
  transition: none;
}

@media (prefers-reduced-motion: reduce) {
  :is(.post, .nav-switch, .dialog-close, .nav-list a, .credit-list a, .slide-link, .slide-arrow, .slide-dot) {
    transition: none;
  }
}

@media (max-width: 1160px) {
  .post-list {
    grid-template-columns: minmax(0, 1fr);
  }
}

@media (max-width: 1020px) {
  .opening h1, .story-heading h1 {
    font-size: clamp(36px, 5.5vw, 54px);
  }
}

@media (max-width: 820px) {
  .post, .post:nth-child(2) {
    grid-template-columns: minmax(0, 1fr);
  }

  .post:nth-child(2) .post-preview, .post:nth-child(2) .post-copy {
    grid-column: auto;
    grid-row: auto;
  }

  .post-preview img {
    width: min(100%, var(--preview-limit));
    height: auto;
  }
}

@media (max-width: 656px) {
  :root {
    --section-gap: 36px;
  }

  body {
    font-size: 16px;
  }

  .brand-row {
    min-height: 64px;
    padding-block: 10px;
  }

  .edition-home {
    max-width: calc(100% - 94px);
    gap: 7px;
  }

  .edition-home img {
    width: 30px;
    height: 30px;
  }

  .edition-title {
    font-size: 16px;
  }

  .navigation-row > #edition-nav {
    display: none;
  }

  .nav-switch {
    position: absolute;
    right: 0;
    bottom: 10px;
    display: inline-grid;
  }

  .main-content-frame, .credits-row {
    grid-template-columns: minmax(0, 1fr);
  }

  .main-content-frame {
    padding-block-start: 22px;
    scroll-margin-top: 82px;
  }

  .content-column, .credits {
    grid-column: 1;
  }

  .opening {
    grid-template-columns: minmax(0, 1fr);
    gap: 16px;
    padding-block: 8px 18px;
  }

  .opening h1, .story-heading h1 {
    font-size: clamp(32px, 8.6vw, 40px);
  }

  .opening-art {
    max-width: 168px;
  }

  .section-title, .post-page h2 {
    font-size: 26px;
  }

  .post-list {
    gap: 20px;
  }

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

  .slide-copy {
    gap: 16px;
    padding: 20px;
  }

  .story-heading {
    padding-block-start: 4px;
  }
}

@media (max-width: 480px) {
  .brand-row, .navigation-row, .main-content-frame, .credits-row {
    width: calc(100% - 44px);
  }

  .read-main:focus {
    left: 22px;
  }
}

/* Article additions */
.breadcrumbs{font-size:13px;line-height:1.55;color:var(--muted);margin:0 0 10px}.breadcrumbs a,.related-reading a{color:var(--accent);text-decoration:underline}.story-cover{margin:22px 0 20px}.story-cover img{display:block;width:100%;height:auto;border-radius:12px}.medical-disclaimer{font-size:14px;color:var(--muted);border-top:1px dotted var(--rule);padding-top:16px}.post-label{text-decoration:none}.post-label:hover{text-decoration:underline}.slide-copy .post-meta{justify-content:flex-start;margin:0}.post-preview>a{display:block;max-width:100%}.post-preview img{aspect-ratio:3/2}.slide-preview{object-fit:cover}
