:root {
  --paper: #f6f2e7;
  --paper-raised: #fffdf6;
  --ink: #0f0f0d;
  --ink-soft: #3e3e38;
  --muted: #6d6b61;
  --line: rgba(15, 15, 13, 0.2);
  --line-strong: rgba(15, 15, 13, 0.72);
  --lime: #9fc319;
  --orange: #e63b1f;
  --orange-text: #b92b16;
  --purple: #6600ce;
  --shadow: 0 18px 45px rgba(15, 15, 13, 0.08);
  --font-ui: "Golos Text", "Segoe UI", sans-serif;
  --font-reading: "Literata", Georgia, serif;
  --font-mono: "IBM Plex Mono", "Courier New", monospace;
  --shell: min(1280px, calc(100vw - 48px));
  --article-shell: min(1380px, calc(100vw - 48px));
  --header-height: 68px;
}

:root[data-theme="dark"] {
  --paper: #0f0f0d;
  --paper-raised: #181815;
  --ink: #f6f2e7;
  --ink-soft: #d8d4c8;
  --muted: #a5a195;
  --line: rgba(246, 242, 231, 0.18);
  --line-strong: rgba(246, 242, 231, 0.68);
  --lime: #add52a;
  --orange: #ff5a3d;
  --orange-text: #ff806b;
  --purple: #a668ff;
  --shadow: 0 20px 50px rgba(0, 0, 0, 0.32);
}

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

html {
  scroll-behavior: smooth;
  scroll-padding-top: calc(var(--header-height) + 28px);
  background: var(--paper);
}

body {
  margin: 0;
  color: var(--ink);
  background-color: var(--paper);
  background-image:
    linear-gradient(rgba(15, 15, 13, 0.018) 1px, transparent 1px),
    linear-gradient(90deg, rgba(15, 15, 13, 0.018) 1px, transparent 1px);
  background-size: 40px 40px;
  font-family: var(--font-ui);
  font-size: 16px;
  line-height: 1.55;
  text-rendering: optimizeLegibility;
  -webkit-font-smoothing: antialiased;
}

:root[data-theme="dark"] body {
  background-image:
    linear-gradient(rgba(246, 242, 231, 0.018) 1px, transparent 1px),
    linear-gradient(90deg, rgba(246, 242, 231, 0.018) 1px, transparent 1px);
}

img,
picture,
svg,
video {
  display: block;
  max-width: 100%;
}

button,
input,
textarea,
select {
  color: inherit;
  font: inherit;
}

button,
select {
  cursor: pointer;
}

a {
  color: inherit;
  text-decoration-thickness: 1px;
  text-underline-offset: 0.18em;
}

a,
button,
input,
textarea,
select,
summary {
  outline: none;
}

:focus-visible {
  outline: 3px solid var(--purple);
  outline-offset: 3px;
}

::selection {
  color: #0f0f0d;
  background: var(--lime);
}

[hidden] {
  display: none !important;
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

.honeypot {
  position: absolute !important;
  width: 1px !important;
  height: 1px !important;
  overflow: hidden !important;
  clip-path: inset(50%) !important;
  white-space: nowrap !important;
}

.skip-link {
  position: fixed;
  z-index: 1000;
  top: 10px;
  left: 10px;
  padding: 10px 14px;
  color: #0f0f0d;
  background: var(--lime);
  border: 2px solid #0f0f0d;
  transform: translateY(-160%);
}

.skip-link:focus {
  transform: translateY(0);
}

.library-shell {
  width: var(--shell);
  margin-inline: auto;
}

.article-shell {
  width: var(--article-shell);
  margin-inline: auto;
}

.site-header {
  position: sticky;
  z-index: 100;
  top: 0;
  height: var(--header-height);
  background: color-mix(in srgb, var(--paper) 94%, transparent);
  border-bottom: 1px solid var(--line-strong);
  backdrop-filter: blur(14px);
}

.site-header__inner {
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: center;
  width: min(1460px, calc(100vw - 32px));
  height: 100%;
  margin-inline: auto;
}

.brand-lockup {
  display: flex;
  align-items: center;
  min-width: 0;
  text-decoration: none;
}

.brand-lockup__logo {
  width: 156px;
  height: auto;
}

:root[data-theme="dark"] .brand-lockup__logo,
:root[data-theme="dark"] .site-footer img {
  filter: invert(1);
}

.brand-lockup__section {
  margin-left: 14px;
  padding-left: 14px;
  color: var(--ink-soft);
  border-left: 1px solid var(--line-strong);
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.08em;
  line-height: 24px;
  text-transform: uppercase;
}

.site-nav {
  display: flex;
  justify-content: center;
  gap: clamp(18px, 2.2vw, 34px);
}

.site-nav a,
.header-search-link,
.studio-link {
  position: relative;
  font-size: 13px;
  font-weight: 600;
  text-decoration: none;
}

.site-nav a::after {
  position: absolute;
  right: 0;
  bottom: -7px;
  left: 0;
  height: 2px;
  background: var(--lime);
  content: "";
  transform: scaleX(0);
  transform-origin: right;
  transition: transform 180ms ease;
}

.site-nav a:hover::after {
  transform: scaleX(1);
  transform-origin: left;
}

.site-actions {
  display: flex;
  align-items: center;
  gap: 9px;
}

.header-search-link {
  display: flex;
  align-items: center;
  gap: 10px;
  min-height: 36px;
  padding: 7px 9px 7px 12px;
  border: 1px solid var(--line);
}

.header-search-link:hover {
  border-color: var(--line-strong);
}

.header-search-link kbd {
  min-width: 21px;
  padding: 1px 5px;
  color: var(--muted);
  background: color-mix(in srgb, var(--ink) 5%, transparent);
  border: 1px solid var(--line);
  border-radius: 2px;
  font-family: var(--font-mono);
  font-size: 10px;
  text-align: center;
}

.theme-toggle {
  position: relative;
  display: grid;
  grid-template-columns: 1fr 1fr;
  align-items: center;
  width: 54px;
  height: 36px;
  padding: 3px;
  background: transparent;
  border: 1px solid var(--line);
}

.theme-toggle::before {
  position: absolute;
  top: 3px;
  left: 3px;
  width: 23px;
  height: 28px;
  background: var(--ink);
  content: "";
  transition: transform 180ms ease;
}

:root[data-theme="dark"] .theme-toggle::before {
  transform: translateX(24px);
}

.theme-toggle span {
  position: relative;
  z-index: 1;
  display: grid;
  place-items: center;
  font-size: 13px;
}

.theme-toggle__sun,
:root[data-theme="dark"] .theme-toggle__moon {
  color: var(--paper);
}

:root[data-theme="dark"] .theme-toggle__sun {
  color: var(--ink);
}

.studio-link {
  min-height: 36px;
  padding: 8px 12px;
  color: #0f0f0d;
  background: var(--lime);
  border: 1px solid #0f0f0d;
}

.studio-link:hover {
  background: color-mix(in srgb, var(--lime) 82%, white);
}

.menu-toggle {
  display: none;
  justify-self: end;
  min-height: 40px;
  padding: 8px 10px;
  background: transparent;
  border: 1px solid var(--line);
  font-family: var(--font-mono);
  font-size: 11px;
  text-transform: uppercase;
}

.menu-toggle__icon {
  position: relative;
  width: 17px;
  height: 10px;
  margin-left: 8px;
  border-top: 1px solid currentColor;
  border-bottom: 1px solid currentColor;
}

.library-hero {
  border-bottom: 1px solid var(--line-strong);
}

.library-hero__grid {
  display: grid;
  grid-template-columns: minmax(340px, 0.8fr) minmax(480px, 1.2fr);
  gap: clamp(34px, 6vw, 90px);
  align-items: end;
  min-height: 360px;
  padding-block: 52px 46px;
}

.library-hero__heading {
  animation: settle-in 500ms cubic-bezier(0.2, 0.75, 0.25, 1) both;
}

.eyebrow,
.section-kicker {
  margin: 0 0 14px;
  color: var(--muted);
  font-family: var(--font-mono);
  font-size: 11px;
  font-weight: 500;
  letter-spacing: 0.08em;
  line-height: 1.4;
  text-transform: uppercase;
}

.eyebrow {
  display: flex;
  gap: 9px;
  color: var(--ink);
}

.eyebrow span {
  padding: 5px 7px;
  border: 1px solid var(--line-strong);
}

.eyebrow span:first-child {
  color: #0f0f0d;
  background: var(--lime);
}

.library-hero h1 {
  max-width: 700px;
  margin: 0;
  font-family: var(--font-reading);
  font-size: clamp(44px, 5vw, 70px);
  font-weight: 600;
  letter-spacing: -0.055em;
  line-height: 0.98;
}

.library-hero__heading > p:last-child {
  max-width: 590px;
  margin: 22px 0 0;
  color: var(--ink-soft);
  font-size: clamp(16px, 1.4vw, 19px);
}

.library-search {
  position: relative;
  padding: clamp(20px, 3vw, 34px);
  color: #f6f2e7;
  background: #0f0f0d;
  border-top: 5px solid var(--orange);
  box-shadow: var(--shadow);
  animation: settle-in 500ms 80ms cubic-bezier(0.2, 0.75, 0.25, 1) both;
}

:root[data-theme="dark"] .library-search {
  color: #0f0f0d;
  background: #f6f2e7;
}

.library-search__form {
  position: relative;
}

.library-search__form > label {
  display: block;
  margin-bottom: 11px;
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.library-search__control {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  align-items: center;
  background: #f6f2e7;
  border: 2px solid #f6f2e7;
}

:root[data-theme="dark"] .library-search__control {
  border-color: #0f0f0d;
}

.library-search__icon {
  padding-left: 15px;
  color: #0f0f0d;
  font-family: var(--font-mono);
  font-size: 22px;
}

.library-search input {
  min-width: 0;
  height: 58px;
  padding: 0 14px;
  color: #0f0f0d;
  background: transparent;
  border: 0;
  font-size: 16px;
}

.library-search input::placeholder {
  color: #6d6b61;
}

.library-search__control button {
  align-self: stretch;
  min-width: 96px;
  padding: 0 18px;
  color: #0f0f0d;
  background: var(--lime);
  border: 0;
  border-left: 2px solid #0f0f0d;
  font-weight: 700;
}

.library-search__control button:hover {
  background: var(--orange);
}

.search-suggestions {
  position: absolute;
  z-index: 20;
  top: calc(100% + 7px);
  right: 0;
  left: 0;
  max-height: 380px;
  overflow: auto;
  color: var(--ink);
  background: var(--paper-raised);
  border: 1px solid var(--line-strong);
  box-shadow: var(--shadow);
}

.search-suggestion {
  display: grid;
  grid-template-columns: 92px 1fr auto;
  gap: 12px;
  align-items: center;
  padding: 13px 14px;
  border-bottom: 1px solid var(--line);
  text-decoration: none;
}

.search-suggestion:last-child {
  border-bottom: 0;
}

.search-suggestion:hover,
.search-suggestion[aria-selected="true"] {
  background: color-mix(in srgb, var(--lime) 22%, var(--paper-raised));
}

.search-suggestion small {
  color: var(--muted);
  font-family: var(--font-mono);
  font-size: 9px;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.search-suggestion strong {
  font-size: 14px;
}

.search-suggestion i {
  font-style: normal;
}

.search-suggestion--all {
  grid-template-columns: 1fr auto;
  color: #0f0f0d;
  background: var(--lime);
}

.quick-filters {
  display: flex;
  flex-wrap: wrap;
  gap: 5px 13px;
  margin-top: 15px;
  font-size: 11px;
}

.quick-filters > span {
  color: color-mix(in srgb, currentColor 68%, transparent);
  font-family: var(--font-mono);
}

.quick-filters a {
  text-decoration-style: dotted;
}

.start-section,
.activity-section,
.series-section,
.collections-section,
.subscribe-section,
.catalog-section,
.related-section {
  padding-block: 46px;
  border-bottom: 1px solid var(--line-strong);
}

.start-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.45fr) minmax(300px, 0.55fr);
  gap: clamp(42px, 6vw, 84px);
}

.section-heading {
  display: flex;
  justify-content: space-between;
  gap: 24px;
  align-items: end;
  min-height: 52px;
  margin-bottom: 22px;
}

.section-heading--compact {
  margin-bottom: 13px;
}

.section-heading h2,
.catalog-toolbar h2,
.subscribe-panel h2 {
  margin: 0;
  font-family: var(--font-reading);
  font-size: clamp(27px, 2.5vw, 38px);
  font-weight: 600;
  letter-spacing: -0.035em;
  line-height: 1.08;
}

.section-heading .section-kicker {
  margin-bottom: 6px;
}

.section-note {
  max-width: 260px;
  color: var(--muted);
  font-size: 13px;
  text-align: right;
}

.text-link {
  flex: 0 0 auto;
  font-size: 13px;
  font-weight: 700;
  text-decoration: none;
}

.text-link:hover {
  text-decoration: underline;
}

.material-list,
.ranked-list,
.category-index {
  padding: 0;
  margin: 0;
  list-style: none;
}

.material-list {
  border-top: 1px solid var(--line-strong);
}

.material-row {
  position: relative;
  border-bottom: 1px solid var(--line);
}

.material-row__link {
  display: grid;
  grid-template-columns: 42px minmax(0, 1fr) auto 18px;
  gap: 16px;
  align-items: center;
  min-height: 128px;
  padding: 15px 10px 15px 0;
  text-decoration: none;
  transition: background-color 150ms ease, padding 150ms ease;
}

.material-row__link:hover {
  padding-right: 4px;
  padding-left: 8px;
  background: color-mix(in srgb, var(--lime) 11%, transparent);
}

.material-row__index {
  align-self: start;
  padding-top: 3px;
  color: var(--muted);
  font-family: var(--font-mono);
  font-size: 11px;
}

.material-row__body {
  display: flex;
  min-width: 0;
  flex-direction: column;
}

.material-row__meta,
.material-row__details {
  display: flex;
  flex-wrap: wrap;
  gap: 5px 9px;
  color: var(--muted);
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: 0.045em;
  line-height: 1.45;
  text-transform: uppercase;
}

.material-row__meta {
  margin-bottom: 7px;
}

.material-row__title {
  max-width: 720px;
  font-family: var(--font-reading);
  font-size: clamp(18px, 1.6vw, 23px);
  font-weight: 600;
  letter-spacing: -0.02em;
  line-height: 1.18;
}

.material-row__intro {
  display: -webkit-box;
  max-width: 720px;
  margin-top: 6px;
  overflow: hidden;
  color: var(--ink-soft);
  font-size: 13px;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
}

.material-row__details {
  margin-top: 10px;
}

.material-row__details span + span::before {
  margin-right: 9px;
  content: "·";
}

.material-row__cover {
  width: 135px;
  height: 88px;
  overflow: hidden;
  background: color-mix(in srgb, var(--ink) 7%, transparent);
  border: 1px solid var(--line);
}

.material-row__cover img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  filter: saturate(0.85);
  transition: transform 220ms ease, filter 220ms ease;
}

.material-row__link:hover .material-row__cover img {
  filter: saturate(1);
  transform: scale(1.035);
}

.material-row__arrow {
  font-family: var(--font-mono);
  font-size: 14px;
}

.material-row--compact .material-row__link {
  grid-template-columns: 36px minmax(0, 1fr) 18px;
  min-height: 93px;
}

.material-row--compact .material-row__title {
  font-size: 18px;
}

.material-row--compact .material-row__cover {
  display: none;
}

.section-index {
  align-self: start;
}

.category-index {
  border-top: 1px solid var(--line-strong);
}

.category-index li {
  --tab-color: var(--lime);
  position: relative;
  border-bottom: 1px solid var(--line);
}

.category-index li:nth-child(3n + 2) {
  --tab-color: var(--orange);
}

.category-index li:nth-child(3n + 3) {
  --tab-color: var(--purple);
}

.category-index li::before {
  position: absolute;
  top: 0;
  bottom: 0;
  left: 0;
  width: 5px;
  background: var(--tab-color);
  content: "";
  transform: scaleY(0.38);
  transform-origin: bottom;
  transition: transform 180ms ease;
}

.category-index li:hover::before {
  transform: scaleY(1);
}

.category-index a {
  display: grid;
  grid-template-columns: 30px minmax(0, 1fr) auto auto;
  gap: 11px;
  align-items: center;
  min-height: 58px;
  padding: 10px 5px 10px 15px;
  text-decoration: none;
}

.category-index__number,
.category-index__count {
  color: var(--muted);
  font-family: var(--font-mono);
  font-size: 10px;
}

.category-index__name {
  font-size: 14px;
  font-weight: 600;
}

.category-index__empty {
  padding: 20px 14px;
  color: var(--muted);
}

.activity-section {
  background: color-mix(in srgb, var(--paper-raised) 66%, transparent);
}

.activity-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.25fr) minmax(300px, 0.75fr);
  gap: clamp(42px, 6vw, 84px);
}

.popular-panel {
  padding: 0 0 0 clamp(24px, 3vw, 42px);
  border-left: 1px solid var(--line-strong);
}

.ranked-list {
  counter-reset: item;
  border-top: 1px solid var(--line-strong);
}

.ranked-list li {
  display: grid;
  grid-template-columns: 31px minmax(0, 1fr);
  gap: 5px 12px;
  align-items: start;
  padding: 15px 0;
  border-bottom: 1px solid var(--line);
}

.ranked-list > li > span {
  grid-row: 1 / 3;
  padding-top: 2px;
  color: var(--orange-text);
  font-family: var(--font-mono);
  font-size: 11px;
}

.ranked-list a {
  font-family: var(--font-reading);
  font-size: 17px;
  font-weight: 600;
  line-height: 1.24;
  text-decoration: none;
}

.ranked-list a:hover {
  text-decoration: underline;
}

.ranked-list small {
  color: var(--muted);
  font-family: var(--font-mono);
  font-size: 9px;
  text-transform: uppercase;
}

.series-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  border-top: 1px solid var(--line-strong);
  border-left: 1px solid var(--line);
}

.series-card {
  position: relative;
  display: grid;
  grid-template-columns: 35px 1fr;
  gap: 12px;
  min-height: 210px;
  padding: 24px;
  overflow: hidden;
  border-right: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
  text-decoration: none;
}

.series-card::after {
  position: absolute;
  right: -30px;
  bottom: -42px;
  width: 120px;
  height: 120px;
  background: var(--lime);
  border-radius: 50%;
  content: "";
  opacity: 0.22;
  transition: transform 240ms ease, opacity 240ms ease;
}

.series-card:nth-child(3n + 2)::after {
  background: var(--orange);
}

.series-card:nth-child(3n + 3)::after {
  background: var(--purple);
}

.series-card:hover::after {
  opacity: 0.72;
  transform: scale(1.25);
}

.series-card__index {
  color: var(--muted);
  font-family: var(--font-mono);
  font-size: 10px;
}

.series-card h3 {
  max-width: 300px;
  margin: 0;
  font-family: var(--font-reading);
  font-size: 24px;
  line-height: 1.12;
}

.series-card p {
  max-width: 340px;
  margin: 13px 0 26px;
  color: var(--ink-soft);
  font-size: 13px;
}

.series-card div > span {
  position: absolute;
  bottom: 22px;
  color: var(--muted);
  font-family: var(--font-mono);
  font-size: 10px;
  text-transform: uppercase;
}

.collection-list {
  display: grid;
  grid-template-columns: 1fr 1fr;
  border-top: 1px solid var(--line-strong);
}

.collection-list > a {
  display: grid;
  grid-template-columns: 34px minmax(0, 1fr) auto;
  gap: 6px 14px;
  min-height: 118px;
  padding: 20px 18px 20px 0;
  border-bottom: 1px solid var(--line);
  text-decoration: none;
}

.collection-list > a:nth-child(odd) {
  margin-right: 24px;
}

.collection-list > a:nth-child(even) {
  padding-left: 24px;
  border-left: 1px solid var(--line);
}

.collection-list > a > span {
  grid-row: 1 / 3;
  color: var(--muted);
  font-family: var(--font-mono);
  font-size: 10px;
}

.collection-list strong {
  font-family: var(--font-reading);
  font-size: 20px;
}

.collection-list p {
  margin: 0;
  color: var(--ink-soft);
  font-size: 13px;
}

.collection-list i {
  grid-row: 1 / 3;
  font-style: normal;
}

.collection-list a:hover strong {
  text-decoration: underline;
}

.subscribe-section {
  color: #f6f2e7;
  background: #0f0f0d;
}

.subscribe-panel {
  display: grid;
  grid-template-columns: minmax(280px, 0.75fr) minmax(400px, 1.25fr);
  gap: clamp(42px, 8vw, 120px);
  align-items: end;
}

.subscribe-panel .section-kicker {
  color: var(--lime);
}

.subscribe-panel h2 {
  max-width: 460px;
  font-size: clamp(33px, 4vw, 54px);
}

.subscribe-panel__heading > p:last-child {
  max-width: 500px;
  margin: 15px 0 0;
  color: rgba(246, 242, 231, 0.68);
  font-size: 13px;
}

.subscribe-form__row {
  display: grid;
  grid-template-columns: 1fr auto;
  border-bottom: 2px solid #f6f2e7;
}

.subscribe-form__row input {
  min-width: 0;
  height: 58px;
  padding: 0 8px;
  color: #f6f2e7;
  background: transparent;
  border: 0;
  font-size: 18px;
}

.subscribe-form__row input::placeholder {
  color: rgba(246, 242, 231, 0.42);
}

.subscribe-form__row button {
  margin-bottom: 7px;
  padding: 0 20px;
  color: #0f0f0d;
  background: var(--lime);
  border: 0;
  font-size: 13px;
  font-weight: 700;
}

.consent-check {
  display: flex;
  gap: 8px;
  align-items: flex-start;
  margin-top: 12px;
  color: rgba(246, 242, 231, 0.65);
  font-size: 11px;
}

.consent-check input {
  width: 15px;
  height: 15px;
  margin: 1px 0 0;
  accent-color: var(--lime);
}

.form-status {
  min-height: 20px;
  margin: 8px 0 0;
  font-size: 12px;
}

.form-status[data-state="error"] {
  color: var(--orange-text);
}

.form-status[data-state="success"] {
  color: var(--lime);
}

.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 44px;
  padding: 9px 16px;
  border: 1px solid var(--line-strong);
  font-size: 13px;
  font-weight: 700;
  text-decoration: none;
}

.button--dark {
  color: var(--paper);
  background: var(--ink);
}

.button--dark:hover {
  color: #0f0f0d;
  background: var(--lime);
}

.button--full {
  width: 100%;
}

.empty-state {
  position: relative;
  padding: 54px 30px;
  overflow: hidden;
  background: color-mix(in srgb, var(--paper-raised) 75%, transparent);
  border: 1px solid var(--line);
}

.empty-state--inline {
  min-height: 190px;
  padding: 28px;
  border-top: 4px solid var(--lime);
}

.empty-state__mark {
  position: absolute;
  right: 18px;
  bottom: -48px;
  color: color-mix(in srgb, var(--orange) 26%, transparent);
  font-family: var(--font-reading);
  font-size: 190px;
  line-height: 1;
}

.empty-state h3 {
  position: relative;
  max-width: 520px;
  margin: 0;
  font-family: var(--font-reading);
  font-size: 27px;
}

.empty-state p {
  position: relative;
  max-width: 590px;
  margin: 10px 0 20px;
  color: var(--ink-soft);
}

.empty-state > div {
  position: relative;
  display: flex;
  gap: 18px;
  align-items: center;
}

.catalog-section {
  padding-top: 38px;
}

.catalog-toolbar {
  display: flex;
  justify-content: space-between;
  gap: 24px;
  align-items: end;
  padding-bottom: 23px;
  border-bottom: 1px solid var(--line-strong);
}

.catalog-toolbar .section-kicker {
  margin-bottom: 6px;
}

.result-count {
  margin: 0;
  color: var(--muted);
  font-family: var(--font-mono);
  font-size: 11px;
  text-transform: uppercase;
}

.result-count strong {
  color: var(--ink);
  font-size: 17px;
}

.catalog-layout {
  display: grid;
  grid-template-columns: 238px minmax(0, 1fr);
  gap: clamp(34px, 5vw, 70px);
  padding-top: 30px;
}

.catalog-filters {
  align-self: start;
  position: sticky;
  top: calc(var(--header-height) + 24px);
}

.filter-group {
  margin-bottom: 19px;
}

.filter-group label {
  display: block;
  margin-bottom: 7px;
  font-family: var(--font-mono);
  font-size: 10px;
  font-weight: 500;
  letter-spacing: 0.05em;
  text-transform: uppercase;
}

.filter-group input,
.filter-group select {
  width: 100%;
  height: 44px;
  padding: 0 11px;
  color: var(--ink);
  background: var(--paper-raised);
  border: 1px solid var(--line);
  border-radius: 0;
}

.filter-group input:focus,
.filter-group select:focus {
  border-color: var(--line-strong);
}

.filter-reset {
  display: block;
  margin-top: 13px;
  color: var(--muted);
  font-size: 12px;
  text-align: center;
}

.active-filters {
  display: flex;
  flex-wrap: wrap;
  gap: 7px;
  margin-bottom: 16px;
}

.active-filters span {
  padding: 5px 8px;
  color: #0f0f0d;
  background: var(--lime);
  border: 1px solid #0f0f0d;
  font-family: var(--font-mono);
  font-size: 9px;
  text-transform: uppercase;
}

.pagination {
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  gap: 16px;
  align-items: center;
  margin-top: 24px;
  padding: 16px 0;
  border-top: 1px solid var(--line-strong);
  border-bottom: 1px solid var(--line);
  font-size: 12px;
}

.pagination > span:last-child {
  text-align: right;
}

.pagination a {
  font-weight: 700;
  text-decoration: none;
}

.pagination a:hover {
  text-decoration: underline;
}

.pagination strong,
.pagination [aria-disabled="true"] {
  color: var(--muted);
  font-family: var(--font-mono);
  font-size: 10px;
  font-weight: 500;
  text-transform: uppercase;
}

.site-footer {
  color: var(--ink);
  background: var(--paper-raised);
  border-top: 1px solid var(--line-strong);
}

.site-footer__inner {
  display: grid;
  grid-template-columns: 1.2fr 0.8fr 0.8fr;
  gap: 50px;
  width: min(1460px, calc(100vw - 48px));
  margin-inline: auto;
  padding-block: 38px;
}

.site-footer__identity {
  display: flex;
  gap: 14px;
  align-items: flex-start;
}

.site-footer__identity img {
  width: 36px;
  height: 34px;
}

.site-footer__identity strong {
  font-family: var(--font-reading);
  font-size: 18px;
}

.site-footer__identity p {
  max-width: 440px;
  margin: 4px 0 0;
  color: var(--muted);
  font-size: 12px;
}

.site-footer__links,
.site-footer__contact {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 7px;
  font-size: 12px;
}

.site-footer__links a,
.site-footer__contact a {
  text-decoration: none;
}

.site-footer__links a:hover,
.site-footer__contact a:hover {
  text-decoration: underline;
}

.site-footer__contact > span {
  margin-bottom: 3px;
  color: var(--muted);
  font-family: var(--font-mono);
  font-size: 9px;
  text-transform: uppercase;
}

.site-footer__bottom {
  display: flex;
  justify-content: space-between;
  gap: 20px;
  padding: 13px max(24px, calc((100vw - 1460px) / 2));
  color: var(--muted);
  border-top: 1px solid var(--line);
  font-family: var(--font-mono);
  font-size: 9px;
  text-transform: uppercase;
}

.toast {
  position: fixed;
  z-index: 300;
  right: 20px;
  bottom: 20px;
  max-width: min(380px, calc(100vw - 40px));
  padding: 13px 16px;
  color: #0f0f0d;
  background: var(--lime);
  border: 1px solid #0f0f0d;
  box-shadow: var(--shadow);
  font-size: 13px;
}

.flash-messages {
  position: relative;
  z-index: 20;
  width: var(--shell);
  margin: 14px auto 0;
}

.flash-messages p {
  margin: 0;
  padding: 11px 14px;
  color: #0f0f0d;
  background: var(--lime);
  border: 1px solid #0f0f0d;
  font-size: 13px;
}

.flash-messages p[data-state="error"] {
  color: #f6f2e7;
  background: #8f2414;
}

.utility-panel {
  min-height: calc(100vh - var(--header-height) - 210px);
  padding-block: clamp(54px, 9vw, 120px);
}

.utility-panel .library-shell {
  max-width: 720px;
}

.utility-panel h1 {
  max-width: 650px;
  margin: 8px 0 16px;
  overflow-wrap: anywhere;
  font-family: var(--font-reading);
  font-size: clamp(42px, 7vw, 72px);
  letter-spacing: -0.045em;
  line-height: 1;
}

.utility-panel p:not(.section-kicker) {
  max-width: 580px;
  color: var(--ink-soft);
  font-size: 18px;
}

.utility-panel form {
  display: flex;
  flex-wrap: wrap;
  gap: 18px;
  align-items: center;
  margin-top: 28px;
}

/* Article */

.reading-progress {
  position: fixed;
  z-index: 150;
  top: var(--header-height);
  right: 0;
  left: 0;
  height: 3px;
  pointer-events: none;
}

.reading-progress span {
  display: block;
  width: 0;
  height: 100%;
  background: var(--orange);
}

.article-header {
  padding-block: 30px 36px;
  border-bottom: 1px solid var(--line-strong);
}

.breadcrumbs {
  display: flex;
  flex-wrap: wrap;
  gap: 7px;
  align-items: center;
  color: var(--muted);
  font-family: var(--font-mono);
  font-size: 11px;
  text-transform: uppercase;
}

.breadcrumbs a {
  text-decoration: none;
}

.breadcrumbs a:hover {
  color: var(--ink);
  text-decoration: underline;
}

.article-heading {
  max-width: 930px;
  margin: 47px auto 0;
}

.article-type {
  display: flex;
  gap: 8px;
  margin: 0 0 14px;
}

.article-type span {
  padding: 5px 8px;
  color: #0f0f0d;
  background: var(--lime);
  border: 1px solid #0f0f0d;
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: 0.05em;
  text-transform: uppercase;
}

.article-type span:last-child {
  color: var(--ink);
  background: transparent;
  border-color: var(--line-strong);
}

.article-heading h1 {
  max-width: 1020px;
  margin: 0;
  overflow-wrap: anywhere;
  font-family: var(--font-reading);
  font-size: clamp(44px, 6vw, 78px);
  font-weight: 600;
  letter-spacing: -0.055em;
  line-height: 0.98;
  text-wrap: balance;
}

.article-intro {
  max-width: 790px;
  margin: 24px 0 0;
  color: var(--ink-soft);
  font-size: clamp(18px, 1.8vw, 23px);
  line-height: 1.48;
}

.article-byline {
  display: flex;
  flex-wrap: wrap;
  gap: 7px 19px;
  margin-top: 24px;
  color: var(--muted);
  font-family: var(--font-mono);
  font-size: 11px;
  text-transform: uppercase;
}

.article-byline > span + span::before {
  margin-right: 19px;
  color: var(--line-strong);
  content: "/";
}

.article-authors i {
  margin-right: 4px;
  font-style: normal;
}

.article-taxonomy {
  display: flex;
  flex-wrap: wrap;
  gap: 7px;
  margin-top: 20px;
}

.article-taxonomy a {
  padding: 5px 8px;
  border: 1px solid var(--line);
  font-family: var(--font-mono);
  font-size: 10px;
  text-decoration: none;
  text-transform: uppercase;
}

.article-taxonomy a:hover {
  color: #0f0f0d;
  background: var(--lime);
  border-color: #0f0f0d;
}

.article-taxonomy .tag-link {
  color: var(--muted);
  border-style: dashed;
  text-transform: none;
}

.series-strip {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto auto;
  gap: 16px;
  align-items: center;
  max-width: 930px;
  min-height: 58px;
  margin: 34px auto 0;
  padding: 11px 14px;
  color: #0f0f0d;
  background: var(--lime);
  border: 1px solid #0f0f0d;
  text-decoration: none;
}

.series-strip__label,
.series-strip > span {
  font-family: var(--font-mono);
  font-size: 10px;
  text-transform: uppercase;
}

.series-strip strong {
  font-family: var(--font-reading);
  font-size: 17px;
}

.article-cover {
  margin-top: 34px;
}

.article-cover img {
  width: 100%;
  max-height: 670px;
  object-fit: cover;
  border: 1px solid var(--line-strong);
}

.article-layout {
  display: grid;
  grid-template-columns: minmax(150px, 210px) minmax(0, 740px) minmax(190px, 250px);
  gap: clamp(28px, 4vw, 62px);
  justify-content: center;
  align-items: start;
  padding-block: 52px 64px;
}

.article-toc,
.article-context {
  position: sticky;
  top: calc(var(--header-height) + 30px);
  max-height: calc(100dvh - var(--header-height) - 48px);
  overflow-y: auto;
  overscroll-behavior: contain;
  scrollbar-gutter: stable;
}

.article-toc details {
  border-top: 2px solid var(--line-strong);
}

.article-toc summary {
  display: flex;
  justify-content: space-between;
  gap: 8px;
  padding: 12px 0;
  font-family: var(--font-mono);
  font-size: 11px;
  font-weight: 500;
  list-style: none;
  text-transform: uppercase;
}

.article-toc summary::-webkit-details-marker {
  display: none;
}

.article-toc ol {
  padding: 0;
  margin: 3px 0 0;
  list-style: none;
}

.article-toc li {
  margin-bottom: 9px;
}

.article-toc .toc-level-3 {
  padding-left: 13px;
}

.article-toc a {
  display: block;
  color: var(--muted);
  font-size: 12px;
  line-height: 1.35;
  text-decoration: none;
}

.article-toc a:hover,
.article-toc a.is-active {
  color: var(--ink);
}

.article-toc a.is-active {
  padding-left: 8px;
  border-left: 3px solid var(--lime);
}

.article-toc__label {
  display: flex;
  flex-direction: column;
  gap: 5px;
  padding-top: 12px;
  border-top: 2px solid var(--line-strong);
  font-family: var(--font-mono);
  font-size: 10px;
  text-transform: uppercase;
}

.article-toc__label span {
  color: var(--muted);
}

.article-main {
  min-width: 0;
}

.article-content {
  color: var(--ink-soft);
  font-family: var(--font-reading);
  font-size: 18px;
  line-height: 1.76;
}

.markdown-block + .markdown-block {
  margin-top: 30px;
}

.article-content h2,
.article-content h3,
.article-content h4 {
  color: var(--ink);
  scroll-margin-top: calc(var(--header-height) + 28px);
  text-wrap: balance;
}

.article-content h2 {
  margin: 2.3em 0 0.62em;
  font-size: clamp(27px, 3vw, 38px);
  letter-spacing: -0.035em;
  line-height: 1.13;
}

.article-content h3 {
  margin: 1.8em 0 0.55em;
  font-size: 23px;
  line-height: 1.23;
}

.article-content h4 {
  margin: 1.6em 0 0.45em;
  font-family: var(--font-ui);
  font-size: 17px;
}

.article-content > .markdown-block:first-child > :first-child {
  margin-top: 0;
}

.article-content p {
  margin: 0 0 1.2em;
}

.article-content a {
  color: color-mix(in srgb, var(--purple) 82%, var(--ink));
  font-weight: 600;
  text-decoration-color: color-mix(in srgb, var(--purple) 55%, transparent);
}

.article-content a:hover {
  text-decoration-color: currentColor;
}

.article-content ul,
.article-content ol {
  padding-left: 1.35em;
  margin: 0 0 1.25em;
}

.article-content li {
  margin-bottom: 0.45em;
  padding-left: 0.2em;
}

.article-content li::marker {
  color: var(--orange);
  font-family: var(--font-mono);
}

.article-content blockquote {
  margin: 1.7em 0;
  padding: 6px 0 6px 24px;
  color: var(--ink);
  border-left: 5px solid var(--lime);
  font-size: 1.08em;
  font-style: italic;
}

.article-content blockquote p:last-child {
  margin-bottom: 0;
}

.article-content code {
  padding: 0.13em 0.3em;
  color: var(--ink);
  background: color-mix(in srgb, var(--lime) 16%, var(--paper-raised));
  border: 1px solid var(--line);
  font-family: var(--font-mono);
  font-size: 0.82em;
}

.article-content pre {
  position: relative;
  max-width: 100%;
  margin: 1.7em 0;
  padding: 19px 21px;
  overflow: auto;
  color: #f6f2e7;
  background: #0f0f0d;
  border-top: 4px solid var(--purple);
  font-size: 13px;
  line-height: 1.65;
  tab-size: 2;
}

.article-content pre code {
  padding: 0;
  color: inherit;
  background: transparent;
  border: 0;
}

.code-copy {
  position: absolute;
  top: 9px;
  right: 9px;
  padding: 5px 7px;
  color: #f6f2e7;
  background: #242420;
  border: 1px solid rgba(246, 242, 231, 0.35);
  font-family: var(--font-mono);
  font-size: 9px;
  text-transform: uppercase;
}

.article-content hr {
  margin: 2.5em 0;
  border: 0;
  border-top: 1px solid var(--line-strong);
}

.article-content table {
  width: 100%;
  margin: 1.7em 0;
  border-collapse: collapse;
  font-family: var(--font-ui);
  font-size: 13px;
}

.article-content th,
.article-content td {
  padding: 10px 12px;
  border: 1px solid var(--line);
  text-align: left;
  vertical-align: top;
}

.article-content th {
  color: #0f0f0d;
  background: var(--lime);
  border-color: #0f0f0d;
}

.article-content img {
  width: auto;
  margin: 1.8em auto;
  border: 1px solid var(--line);
}

.content-video,
.content-download {
  margin: 2em 0;
  font-family: var(--font-ui);
}

.content-video__frame {
  position: relative;
  aspect-ratio: 16 / 9;
  overflow: hidden;
  background: #0f0f0d;
}

.content-video__frame iframe {
  width: 100%;
  height: 100%;
  border: 0;
}

.content-video figcaption {
  margin-top: 8px;
  color: var(--muted);
  font-size: 12px;
}

.content-video details {
  margin-top: 12px;
  padding: 12px 0;
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
  font-size: 13px;
}

.content-video summary {
  display: flex;
  justify-content: space-between;
  cursor: pointer;
  font-weight: 700;
}

.content-video details p {
  margin: 12px 0 0;
}

.content-download {
  display: grid;
  grid-template-columns: 40px minmax(0, 1fr) auto;
  gap: 16px;
  align-items: center;
  padding: 18px;
  background: color-mix(in srgb, var(--lime) 12%, var(--paper-raised));
  border: 1px solid var(--line-strong);
}

.content-download__icon {
  display: grid;
  place-items: center;
  width: 38px;
  height: 38px;
  color: #0f0f0d;
  background: var(--lime);
  border: 1px solid #0f0f0d;
  font-family: var(--font-mono);
}

.content-download p {
  margin: 0 0 3px;
  color: var(--muted);
  font-family: var(--font-mono);
  font-size: 10px;
  text-transform: uppercase;
}

.content-download h3 {
  margin: 0;
  font-family: var(--font-reading);
  font-size: 18px;
}

.content-download div > span {
  display: block;
  margin-top: 4px;
  color: var(--muted);
  font-size: 12px;
}

.content-download > a {
  font-size: 12px;
  font-weight: 700;
}

.howto-steps {
  margin-top: 60px;
  padding-top: 28px;
  border-top: 2px solid var(--line-strong);
}

.howto-steps > h2 {
  margin-top: 0;
}

.howto-steps > ol {
  padding: 0;
  margin: 25px 0 0;
  list-style: none;
  counter-reset: none;
}

.howto-steps > ol > li {
  display: grid;
  grid-template-columns: 48px minmax(0, 1fr);
  gap: 18px;
  padding: 20px 0;
  border-top: 1px solid var(--line);
  scroll-margin-top: calc(var(--header-height) + 28px);
}

.howto-steps > ol > li > span {
  color: var(--orange-text);
  font-family: var(--font-mono);
  font-size: 12px;
}

.howto-steps h3 {
  margin: 0 0 7px;
}

.howto-steps p {
  margin: 0;
}

.cycle-card,
.contact-card {
  padding-top: 12px;
  border-top: 2px solid var(--line-strong);
}

.cycle-card > p,
.contact-card > p {
  margin: 0 0 6px;
  color: var(--muted);
  font-family: var(--font-mono);
  font-size: 10px;
  text-transform: uppercase;
}

.cycle-card h2,
.contact-card h2 {
  margin: 0;
  font-family: var(--font-reading);
  font-size: 19px;
  line-height: 1.18;
}

.cycle-card > span {
  display: inline-block;
  margin-top: 10px;
  padding: 3px 6px;
  color: #0f0f0d;
  background: var(--lime);
  font-family: var(--font-mono);
  font-size: 10px;
}

.cycle-card ol {
  padding: 0;
  margin: 16px 0 0;
  list-style: none;
}

.cycle-card li {
  border-top: 1px solid var(--line);
}

.cycle-card li:last-child {
  border-bottom: 1px solid var(--line);
}

.cycle-card li[aria-current="page"] {
  background: color-mix(in srgb, var(--lime) 15%, transparent);
}

.cycle-card a {
  display: grid;
  grid-template-columns: 24px minmax(0, 1fr);
  gap: 8px;
  padding: 9px 4px;
  font-size: 11px;
  line-height: 1.3;
  text-decoration: none;
}

.cycle-card a span {
  color: var(--muted);
  font-family: var(--font-mono);
  font-size: 9px;
}

.contact-card > span {
  display: block;
  margin: 10px 0 15px;
  color: var(--muted);
  font-size: 11px;
}

.contact-card > a {
  font-size: 11px;
  font-weight: 700;
}

.series-navigation {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 14px;
  margin-top: 54px;
}

.series-navigation > a {
  display: flex;
  min-height: 105px;
  flex-direction: column;
  justify-content: space-between;
  padding: 14px;
  border: 1px solid var(--line);
  text-decoration: none;
}

.series-navigation > a:hover {
  background: color-mix(in srgb, var(--lime) 12%, transparent);
  border-color: var(--line-strong);
}

.series-navigation span {
  color: var(--muted);
  font-family: var(--font-mono);
  font-size: 10px;
  text-transform: uppercase;
}

.series-navigation strong {
  font-family: var(--font-reading);
  font-size: 16px;
  line-height: 1.2;
}

.series-navigation__next {
  text-align: right;
}

.article-feedback {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 22px;
  align-items: center;
  margin-top: 30px;
  padding: 24px;
  background: color-mix(in srgb, var(--paper-raised) 75%, transparent);
  border: 1px solid var(--line-strong);
}

.article-feedback .section-kicker {
  margin-bottom: 5px;
}

.article-feedback h2 {
  margin: 0;
  font-family: var(--font-reading);
  font-size: 25px;
}

.article-feedback > form {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 7px;
}

.article-feedback > form button {
  min-width: 74px;
  min-height: 42px;
  background: transparent;
  border: 1px solid var(--line-strong);
  font-size: 12px;
  font-weight: 700;
}

.article-feedback > form button:hover,
.article-feedback > form button[aria-pressed="true"] {
  color: #0f0f0d;
  background: var(--lime);
  border-color: #0f0f0d;
}

.article-feedback > form p {
  grid-column: 1 / -1;
  margin: 2px 0 0;
  font-size: 11px;
}

.issue-report {
  grid-column: 1 / -1;
  padding-top: 14px;
  border-top: 1px solid var(--line);
}

.issue-report summary {
  display: flex;
  justify-content: space-between;
  gap: 14px;
  cursor: pointer;
  color: var(--muted);
  font-size: 11px;
  list-style: none;
}

.issue-report summary::-webkit-details-marker {
  display: none;
}

.issue-report summary span {
  color: var(--ink);
  font-weight: 700;
}

.issue-report form {
  display: grid;
  gap: 13px;
  margin-top: 18px;
}

.issue-report label > span {
  display: block;
  margin-bottom: 5px;
  font-family: var(--font-mono);
  font-size: 10px;
  text-transform: uppercase;
}

.issue-report label i {
  color: var(--muted);
  font-style: normal;
  text-transform: none;
}

.issue-report textarea,
.issue-report input {
  width: 100%;
  padding: 10px 11px;
  color: var(--ink);
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: 0;
}

.issue-report .button {
  justify-self: start;
}

.service-cta {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 28px;
  align-items: end;
  margin-top: 30px;
  padding: 26px;
  overflow: hidden;
  color: #0f0f0d;
  background: var(--lime);
  border: 1px solid #0f0f0d;
}

.service-cta .section-kicker {
  color: rgba(15, 15, 13, 0.65);
}

.service-cta h2 {
  margin: 0;
  font-family: var(--font-reading);
  font-size: 27px;
}

.service-cta p:not(.section-kicker) {
  max-width: 520px;
  margin: 7px 0 0;
  font-size: 13px;
}

.service-cta > a {
  padding: 10px 13px;
  background: #f6f2e7;
  border: 1px solid #0f0f0d;
  font-size: 12px;
  font-weight: 700;
  text-decoration: none;
}

.share-section {
  display: flex;
  justify-content: space-between;
  gap: 20px;
  align-items: center;
  margin-top: 30px;
  padding: 15px 0;
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
}

.share-section h2 {
  margin: 0;
  font-family: var(--font-mono);
  font-size: 11px;
  text-transform: uppercase;
}

.share-section > div {
  display: flex;
  flex-wrap: wrap;
  gap: 11px;
}

.share-section a,
.share-section button {
  padding: 0;
  color: var(--muted);
  background: transparent;
  border: 0;
  font-size: 11px;
  text-decoration: none;
}

.share-section a:hover,
.share-section button:hover {
  color: var(--ink);
  text-decoration: underline;
}

.related-section {
  background: color-mix(in srgb, var(--paper-raised) 66%, transparent);
}

@keyframes settle-in {
  from {
    opacity: 0;
    transform: translateY(10px);
  }

  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@media (max-width: 1160px) {
  .site-header__inner {
    grid-template-columns: auto 1fr auto auto;
  }

  .site-nav {
    order: 3;
    grid-column: 1 / -1;
  }

  .site-actions {
    grid-column: 4;
    justify-self: end;
  }

  .site-nav {
    position: absolute;
    top: var(--header-height);
    right: 0;
    left: 0;
    display: grid;
    justify-content: flex-start;
    gap: 0;
    padding: 14px 24px 22px;
    background: var(--paper);
    border-bottom: 1px solid var(--line-strong);
    box-shadow: var(--shadow);
  }

  .js .site-nav {
    display: none;
  }

  .js .site-nav.is-open {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
  }

  .site-nav a {
    padding: 12px;
    border-right: 1px solid var(--line);
  }

  .js .menu-toggle {
    display: flex;
    grid-column: 3;
    grid-row: 1;
    margin-right: 9px;
  }

  html:not(.js) .site-header {
    position: relative;
    height: auto;
  }

  html:not(.js) .site-header__inner {
    height: auto;
    min-height: var(--header-height);
    padding-block: 10px;
  }

  html:not(.js) .site-nav {
    position: static;
    padding-inline: 0;
    box-shadow: none;
  }

  .article-layout {
    grid-template-columns: minmax(160px, 210px) minmax(0, 740px);
  }

  .article-context {
    position: static;
    grid-column: 2;
  }

  .cycle-card,
  .contact-card {
    margin-top: 5px;
  }
}

@media (max-width: 900px) {
  :root {
    --shell: min(100% - 32px, 760px);
    --article-shell: min(100% - 32px, 780px);
  }

  .brand-lockup__logo {
    width: 132px;
  }

  .menu-toggle {
    margin-right: 6px;
  }

  .header-search-link,
  .studio-link {
    display: none;
  }

  .site-nav.is-open {
    grid-template-columns: 1fr 1fr;
  }

  .library-hero__grid {
    grid-template-columns: 1fr;
    gap: 28px;
    min-height: 0;
    padding-block: 38px;
  }

  .library-hero h1 br {
    display: none;
  }

  .start-grid,
  .activity-grid,
  .subscribe-panel {
    grid-template-columns: 1fr;
    gap: 40px;
  }

  .popular-panel {
    padding: 0;
    border-left: 0;
  }

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

  .catalog-layout {
    grid-template-columns: 1fr;
  }

  .catalog-filters {
    position: static;
    padding: 18px;
    background: color-mix(in srgb, var(--paper-raised) 75%, transparent);
    border: 1px solid var(--line);
  }

  .catalog-filters form {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 15px;
  }

  .catalog-filters .filter-group {
    margin: 0;
  }

  .catalog-filters .button,
  .catalog-filters .filter-reset {
    align-self: end;
  }

  .article-heading {
    margin-top: 34px;
  }

  .article-layout {
    grid-template-columns: 1fr;
    max-width: 760px;
  }

  .article-toc,
  .article-context {
    position: static;
    grid-column: 1;
    max-height: none;
    overflow-y: visible;
    scrollbar-gutter: auto;
  }

  .article-toc {
    padding: 0 16px;
    background: color-mix(in srgb, var(--paper-raised) 70%, transparent);
    border: 1px solid var(--line);
  }

  .article-toc details {
    border-top: 0;
  }

  .article-toc details:not([open]) nav {
    display: none;
  }

  .article-main {
    grid-row: 2;
  }

  .article-context {
    grid-row: 3;
  }

  .site-footer__inner {
    grid-template-columns: 1fr 1fr;
  }

  .site-footer__identity {
    grid-column: 1 / -1;
  }
}

@media (max-width: 640px) {
  :root {
    --shell: calc(100% - 24px);
    --article-shell: calc(100% - 24px);
    --header-height: 58px;
  }

  body {
    background-size: 28px 28px;
  }

  .site-header__inner {
    width: calc(100% - 20px);
  }

  .brand-lockup__logo {
    width: 112px;
  }

  .brand-lockup__section {
    margin-left: 8px;
    padding-left: 8px;
    font-size: 8px;
  }

  .theme-toggle {
    width: 48px;
    height: 34px;
  }

  .theme-toggle::before {
    width: 20px;
    height: 26px;
  }

  :root[data-theme="dark"] .theme-toggle::before {
    transform: translateX(21px);
  }

  .menu-toggle {
    min-height: 34px;
    padding: 6px 7px;
  }

  .menu-toggle span:first-child {
    display: none;
  }

  .menu-toggle__icon {
    margin-left: 0;
  }

  .site-actions {
    gap: 6px;
  }

  .site-nav {
    top: var(--header-height);
    padding: 8px 12px 14px;
  }

  .site-nav.is-open {
    grid-template-columns: 1fr;
  }

  .site-nav a {
    min-height: 44px;
    padding: 12px 4px;
    border-right: 0;
    border-bottom: 1px solid var(--line);
  }

  .library-hero__grid {
    gap: 24px;
    padding-block: 30px;
  }

  .library-hero h1 {
    font-size: clamp(38px, 12vw, 50px);
    line-height: 1;
  }

  .library-hero__heading > p:last-child {
    margin-top: 16px;
    font-size: 15px;
  }

  .library-search {
    padding: 17px;
  }

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

  .library-search input {
    height: 52px;
    padding-right: 8px;
    font-size: 14px;
  }

  .library-search__control button {
    grid-column: 1 / -1;
    min-height: 44px;
    border-top: 2px solid #0f0f0d;
    border-left: 0;
  }

  .search-suggestion {
    grid-template-columns: 1fr auto;
  }

  .search-suggestion small {
    grid-column: 1;
  }

  .quick-filters {
    gap: 7px 12px;
  }

  .quick-filters > span {
    width: 100%;
  }

  .start-section,
  .activity-section,
  .series-section,
  .collections-section,
  .subscribe-section,
  .catalog-section,
  .related-section {
    padding-block: 32px;
  }

  .section-heading {
    align-items: flex-start;
    min-height: 0;
    margin-bottom: 17px;
  }

  .section-heading h2,
  .catalog-toolbar h2 {
    font-size: 28px;
  }

  .section-note {
    display: none;
  }

  .material-row__link,
  .material-row--compact .material-row__link {
    grid-template-columns: 28px minmax(0, 1fr) 15px;
    gap: 10px;
    min-height: 104px;
    padding-right: 3px;
  }

  .material-row__link:hover {
    padding-left: 3px;
  }

  .material-row__cover {
    display: none;
  }

  .material-row__title,
  .material-row--compact .material-row__title {
    font-size: 18px;
  }

  .material-row__intro {
    font-size: 12px;
    -webkit-line-clamp: 2;
  }

  .material-row__details {
    gap: 4px 7px;
  }

  .material-row__details span + span::before {
    margin-right: 7px;
  }

  .category-index a {
    min-height: 56px;
  }

  .series-grid,
  .collection-list {
    grid-template-columns: 1fr;
  }

  .series-card {
    min-height: 178px;
    padding: 20px;
  }

  .collection-list > a:nth-child(odd) {
    margin-right: 0;
  }

  .collection-list > a:nth-child(even) {
    padding-left: 0;
    border-left: 0;
  }

  .subscribe-panel {
    gap: 28px;
  }

  .subscribe-panel h2 {
    font-size: 36px;
  }

  .subscribe-form__row {
    grid-template-columns: 1fr;
    border-bottom: 0;
  }

  .subscribe-form__row input {
    border-bottom: 2px solid #f6f2e7;
  }

  .subscribe-form__row button {
    min-height: 46px;
    margin-top: 10px;
    margin-bottom: 0;
  }

  .catalog-toolbar {
    align-items: flex-start;
  }

  .catalog-toolbar .result-count {
    padding-top: 4px;
  }

  .catalog-filters form {
    grid-template-columns: 1fr;
  }

  .empty-state {
    padding: 36px 21px;
  }

  .empty-state > div {
    align-items: flex-start;
    flex-direction: column;
  }

  .article-header {
    padding-block: 20px 28px;
  }

  .breadcrumbs span,
  .breadcrumbs > a:first-child {
    display: none;
  }

  .breadcrumbs > a:first-child:only-child {
    display: inline;
  }

  .breadcrumbs > a:last-child::before {
    content: "← ";
  }

  .article-heading {
    margin-top: 27px;
  }

  .article-heading h1 {
    font-size: clamp(36px, 10.8vw, 46px);
    line-height: 1.02;
  }

  .article-intro {
    margin-top: 17px;
    font-size: 17px;
  }

  .article-byline {
    gap: 6px 0;
    align-items: flex-start;
    flex-direction: column;
    margin-top: 19px;
  }

  .article-byline > span + span::before {
    display: none;
  }

  .series-strip {
    grid-template-columns: 1fr auto;
    gap: 4px 12px;
    margin-top: 25px;
  }

  .series-strip__label,
  .series-strip strong {
    grid-column: 1;
  }

  .series-strip > span:not(.series-strip__label) {
    grid-column: 1;
  }

  .series-strip i {
    grid-column: 2;
    grid-row: 1 / 4;
  }

  .article-cover {
    width: 100%;
    margin-top: 0;
  }

  .article-cover img {
    border-right: 0;
    border-left: 0;
  }

  .article-layout {
    gap: 25px;
    padding-block: 26px 40px;
  }

  .article-content {
    font-size: 17px;
    line-height: 1.72;
  }

  .article-content h2 {
    font-size: 29px;
  }

  .article-content h3 {
    font-size: 21px;
  }

  .article-content pre {
    margin-right: -12px;
    margin-left: -12px;
    padding: 46px 14px 18px;
    font-size: 12px;
  }

  .article-content table {
    display: block;
    max-width: calc(100vw - 24px);
    overflow-x: auto;
  }

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

  .pagination > strong {
    grid-column: 1 / -1;
    grid-row: 1;
    text-align: center;
  }

  .content-download {
    grid-template-columns: 36px minmax(0, 1fr);
  }

  .content-download > a {
    grid-column: 2;
  }

  .howto-steps > ol > li {
    grid-template-columns: 34px minmax(0, 1fr);
    gap: 10px;
  }

  .series-navigation {
    grid-template-columns: 1fr;
  }

  .series-navigation > span:empty {
    display: none;
  }

  .series-navigation__next {
    text-align: left;
  }

  .article-feedback {
    grid-template-columns: 1fr;
    padding: 19px;
  }

  .article-feedback > form {
    width: 100%;
  }

  .service-cta {
    grid-template-columns: 1fr;
    gap: 18px;
    padding: 21px;
  }

  .service-cta > a {
    justify-self: start;
  }

  .share-section {
    align-items: flex-start;
    flex-direction: column;
  }

  .site-footer__inner {
    grid-template-columns: 1fr;
    gap: 26px;
    width: calc(100% - 24px);
    padding-block: 30px;
  }

  .site-footer__identity {
    grid-column: 1;
  }

  .site-footer__bottom {
    padding-inline: 12px;
    align-items: flex-start;
    flex-direction: column;
    gap: 4px;
  }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    scroll-behavior: auto !important;
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
}

@media print {
  .site-header,
  .site-footer,
  .reading-progress,
  .article-toc,
  .article-context,
  .article-feedback,
  .service-cta,
  .share-section,
  .related-section {
    display: none !important;
  }

  body {
    color: #000;
    background: #fff;
  }

  .article-layout {
    display: block;
    width: auto;
    padding: 0;
  }

  .article-heading,
  .article-main {
    max-width: none;
  }

  .article-content {
    color: #000;
    font-size: 11pt;
  }
}
