:root {
  color-scheme: light;
  --paper: #fbf8f2;
  --paper-warm: #f3eadc;
  --ink: #182f2a;
  --ink-soft: #31524b;
  --muted: #6f7d75;
  --line: rgba(24, 47, 42, 0.16);
  --line-strong: rgba(24, 47, 42, 0.28);
  --green: #2f604f;
  --green-dark: #173b34;
  --sage: #88a987;
  --coral: #d96f67;
  --blue: #7895b7;
  --violet: #8b7aa8;
  --amber: #d99b43;
  --white: #fffdf8;
  --max: 1232px;
  --mono: "SFMono-Regular", "Menlo", "Monaco", "Consolas", monospace;
  --serif: "Songti SC", "STSong", "Iowan Old Style", "Georgia", serif;
  font-family: var(--serif);
  background: var(--paper);
  color: var(--ink);
}

* {
  box-sizing: border-box;
}

html {
  background: var(--paper);
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-width: 320px;
  background:
    linear-gradient(180deg, rgba(120, 149, 183, 0.14), transparent 360px),
    repeating-linear-gradient(90deg, rgba(24, 47, 42, 0.024) 0 1px, transparent 1px 84px),
    var(--paper);
}

body.gate-open {
  overflow: hidden;
}

button,
input {
  font: inherit;
}

button {
  cursor: pointer;
}

a {
  color: inherit;
  text-decoration: none;
}

img {
  display: block;
  max-width: 100%;
}

[hidden] {
  display: none !important;
}

.site-shell {
  min-height: 100vh;
  overflow-x: hidden;
}

.topbar {
  position: sticky;
  top: 0;
  z-index: 30;
  background: rgba(251, 248, 242, 0.9);
  border-bottom: 1px solid var(--line);
  backdrop-filter: blur(18px);
}

.topbar-main {
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  min-height: 72px;
  padding: 0 24px;
}

.brand-mark {
  justify-self: start;
  width: 40px;
  height: 40px;
  border: 1px solid rgba(24, 47, 42, 0.12);
  border-radius: 8px;
  overflow: hidden;
  box-shadow: 0 8px 20px rgba(24, 47, 42, 0.08);
}

.brand-mark img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.site-title {
  justify-self: center;
  color: var(--ink);
  font-family: var(--serif);
  font-size: 1.55rem;
  font-weight: 900;
  letter-spacing: 0;
}

.top-actions {
  justify-self: end;
  display: flex;
  align-items: center;
  gap: 12px;
}

.icon-button,
.plain-button,
.subscribe-button,
.section-heading button,
.section-heading a,
.primary-button,
.footer-actions button,
.footer-actions a,
.no-thanks {
  border: 0;
}

.icon-button {
  display: inline-grid;
  place-items: center;
  width: 38px;
  height: 38px;
  border-radius: 50%;
  color: var(--ink);
  background: transparent;
}

.icon-button span {
  display: block;
  font-family: var(--mono);
  font-size: 1.15rem;
  line-height: 1;
}

.icon-button:hover,
.icon-button:focus-visible {
  background: rgba(47, 96, 79, 0.1);
  outline: none;
}

.subscribe-button,
.primary-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 38px;
  padding: 0 18px;
  border-radius: 8px;
  color: var(--white);
  background: var(--green);
  font-family: var(--mono);
  font-weight: 700;
}

.subscribe-button:hover,
.primary-button:hover,
.input-row button:hover {
  background: var(--green-dark);
}

.plain-button {
  color: var(--ink);
  background: transparent;
  font-family: var(--mono);
  font-weight: 700;
}

.plain-button:hover {
  color: var(--coral);
}

.mobile-menu {
  display: none;
}

.nav-row {
  display: flex;
  justify-content: center;
  gap: 8px;
  min-height: 48px;
}

.nav-row button {
  position: relative;
  border: 0;
  color: var(--ink-soft);
  background: transparent;
  padding: 0 13px;
  font-family: var(--mono);
  font-size: 0.92rem;
  font-weight: 700;
  white-space: nowrap;
}

.nav-row button::after {
  position: absolute;
  right: 12px;
  bottom: 0;
  left: 12px;
  height: 3px;
  background: transparent;
  content: "";
}

.nav-row button.active {
  color: var(--ink);
}

.nav-row button.active::after {
  background: var(--coral);
}

.nav-row button:hover {
  color: var(--coral);
}

main {
  padding-bottom: 84px;
}

.content-wrap {
  width: min(calc(100% - 48px), var(--max));
  margin: 0 auto;
  padding-top: 26px;
}

.hero {
  position: relative;
  min-height: 400px;
  overflow: hidden;
  border: 1px solid rgba(24, 47, 42, 0.12);
  border-radius: 8px;
  background: var(--green-dark);
  box-shadow: 0 22px 70px rgba(24, 47, 42, 0.13);
}

.hero-image {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.hero-shade {
  position: absolute;
  inset: 0;
  background:
    linear-gradient(90deg, rgba(21, 51, 43, 0.82), rgba(21, 51, 43, 0.34) 52%, transparent),
    linear-gradient(180deg, transparent, rgba(21, 51, 43, 0.18));
}

.hero-copy {
  position: relative;
  z-index: 1;
  display: flex;
  flex-direction: column;
  justify-content: center;
  width: min(540px, 88%);
  min-height: 400px;
  padding: 54px 48px;
  color: var(--white);
}

.hero-kicker {
  width: fit-content;
  margin-bottom: 16px;
  border-bottom: 1px solid rgba(255, 253, 248, 0.55);
  font-family: var(--mono);
  font-size: 0.78rem;
  font-weight: 700;
}

.hero h1 {
  margin: 0 0 12px;
  font-family: var(--serif);
  font-size: 2.65rem;
  font-weight: 900;
  line-height: 1.12;
  letter-spacing: 0;
}

.hero p {
  max-width: 32rem;
  margin: 0 0 34px;
  color: rgba(255, 253, 248, 0.88);
  font-size: 1.06rem;
  line-height: 1.75;
}

.hero-link {
  display: inline-flex;
  align-items: center;
  gap: 18px;
  width: fit-content;
  border: 0;
  color: var(--white);
  background: transparent;
  font-family: var(--mono);
  font-size: 0.8rem;
  font-weight: 700;
}

.hero-link span {
  display: inline-grid;
  place-items: center;
  width: 42px;
  height: 42px;
  color: var(--green-dark);
  background: var(--white);
  border-radius: 50%;
  transition: transform 180ms ease;
}

.hero-link:hover span {
  transform: translateX(4px);
}

.section-heading {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  margin: 30px 0 18px;
}

.section-heading h2 {
  margin: 0;
  font-family: var(--mono);
  font-size: 1rem;
  font-weight: 800;
  letter-spacing: 0;
}

.section-heading button,
.section-heading a {
  color: var(--ink-soft);
  background: transparent;
  font-family: var(--mono);
  font-size: 0.78rem;
  font-weight: 700;
}

.section-heading button:hover,
.section-heading a:hover {
  color: var(--coral);
}

.popular-section {
  padding-bottom: 44px;
  border-bottom: 1px solid var(--line);
}

.popular-strip {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 18px;
}

.popular-item {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 70px;
  gap: 14px;
  min-height: 92px;
  padding-right: 18px;
  border-right: 1px solid var(--line);
}

.popular-item:hover h3,
.article-row:hover h3,
.tab-grid a:hover h3,
.archive-card:hover h2,
.related-list a:hover span {
  color: var(--coral);
}

.popular-item:last-child {
  border-right: 0;
  padding-right: 0;
}

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

.popular-item h3,
.article-row h3,
.tab-grid h3 {
  margin: 0;
  color: var(--ink);
  font-family: var(--serif);
  font-weight: 900;
  letter-spacing: 0;
}

.popular-item h3 {
  display: -webkit-box;
  min-height: 47px;
  overflow: hidden;
  font-size: 1rem;
  line-height: 1.46;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
}

.thumb {
  position: relative;
  align-self: start;
  width: 70px;
  aspect-ratio: 1;
  overflow: hidden;
  border-radius: 7px;
  background: var(--paper-warm);
  box-shadow: 0 10px 22px rgba(24, 47, 42, 0.08);
}

.thumb.large {
  width: 168px;
  aspect-ratio: 16 / 9;
}

.thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.play-badge {
  position: absolute;
  top: 50%;
  left: 50%;
  display: grid;
  place-items: center;
  width: 38px;
  height: 38px;
  color: var(--white);
  background: rgba(24, 47, 42, 0.56);
  border-radius: 50%;
  transform: translate(-50%, -50%);
}

.play-badge::before {
  width: 0;
  height: 0;
  margin-left: 3px;
  border-top: 7px solid transparent;
  border-bottom: 7px solid transparent;
  border-left: 11px solid currentColor;
  content: "";
}

.meta {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 6px;
  margin-top: 9px;
  color: var(--muted);
  font-family: var(--mono);
  font-size: 0.72rem;
  font-weight: 700;
  text-transform: uppercase;
}

.meta.compact {
  font-size: 0.68rem;
}

.lock {
  position: relative;
  display: inline-grid;
  place-items: center;
  width: 18px;
  height: 18px;
  border: 1px solid var(--line-strong);
  border-radius: 5px;
}

.lock::before {
  position: absolute;
  top: 4px;
  width: 7px;
  height: 5px;
  border: 1.5px solid currentColor;
  border-bottom: 0;
  border-radius: 5px 5px 0 0;
  content: "";
}

.lock::after {
  position: absolute;
  bottom: 4px;
  width: 8px;
  height: 6px;
  border-radius: 1px;
  background: currentColor;
  content: "";
}

.likes {
  color: var(--ink-soft);
}

.article-section {
  display: grid;
  grid-template-columns: 0.68fr 1fr;
  gap: 82px;
  padding: 36px 0 54px;
  border-bottom: 1px solid var(--line);
}

.article-heading {
  align-items: flex-start;
  margin: 0;
}

.article-heading h2 {
  color: var(--green-dark);
  font-size: 1.52rem;
}

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

.article-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 28px;
  padding: 26px 0;
  border-bottom: 1px solid var(--line);
}

.article-row:first-child {
  padding-top: 0;
}

.article-row:last-child {
  border-bottom: 0;
}

.article-row h3 {
  font-size: 1.22rem;
  line-height: 1.42;
}

.article-row p {
  display: -webkit-box;
  margin: 8px 0 0;
  overflow: hidden;
  color: #344a45;
  font-size: 1rem;
  line-height: 1.68;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
}

.tab-panel {
  padding: 74px 0 84px;
}

.tab-panel > div:first-child {
  max-width: 660px;
}

.eyebrow {
  color: var(--coral);
  font-family: var(--mono);
  font-size: 0.78rem;
  font-weight: 800;
  text-transform: uppercase;
}

.tab-panel h1 {
  margin: 12px 0 10px;
  color: var(--green-dark);
  font-family: var(--serif);
  font-size: 3.1rem;
  line-height: 1.1;
}

.tab-panel p {
  margin: 0;
  color: var(--muted);
  font-size: 1.12rem;
  line-height: 1.7;
}

.tab-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 24px;
  margin-top: 42px;
}

.tab-grid a {
  min-width: 0;
}

.tab-grid img {
  width: 100%;
  aspect-ratio: 16 / 10;
  object-fit: cover;
  border-radius: 8px;
}

.tab-grid h3 {
  margin-top: 14px;
  font-size: 1.05rem;
  line-height: 1.42;
}

.subscribe-block {
  display: grid;
  justify-items: center;
  width: min(calc(100% - 48px), 540px);
  margin: 118px auto 72px;
  text-align: center;
}

.subscribe-block img,
.subscribe-modal img,
.floating-subscribe img {
  width: 88px;
  height: 88px;
  border-radius: 8px;
  object-fit: cover;
}

.subscribe-block h2,
.subscribe-modal h2,
.floating-subscribe h2 {
  margin: 20px 0 6px;
  color: var(--ink);
  font-family: var(--serif);
  font-size: 1.72rem;
  letter-spacing: 0;
}

.subscribe-block p,
.subscribe-modal p,
.floating-subscribe p {
  margin: 0 0 8px;
  color: var(--muted);
}

.subscribe-block span {
  color: var(--muted);
  font-family: var(--mono);
  font-size: 0.78rem;
  line-height: 1.55;
}

.subscribe-form {
  width: 100%;
  margin-top: 26px;
}

.input-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  overflow: hidden;
  border: 1px solid var(--green);
  border-radius: 8px;
  background: rgba(255, 253, 248, 0.76);
}

.input-row:focus-within {
  box-shadow: 0 0 0 3px rgba(47, 96, 79, 0.18);
}

.input-row input {
  min-width: 0;
  height: 46px;
  border: 0;
  color: var(--ink);
  background: transparent;
  padding: 0 15px;
  outline: none;
}

.input-row button {
  min-width: 112px;
  border: 0;
  color: var(--white);
  background: var(--green);
  padding: 0 18px;
  font-family: var(--mono);
  font-weight: 800;
}

.notice {
  min-height: 34px;
  margin: 12px auto 0;
  color: var(--muted);
  font-family: var(--mono);
  font-size: 0.72rem;
  line-height: 1.55;
}

.notice.visible {
  color: var(--coral);
}

.floating-subscribe {
  position: fixed;
  right: 0;
  bottom: 0;
  left: 0;
  z-index: 25;
  display: grid;
  grid-template-columns: 220px minmax(280px, 390px) auto;
  align-items: center;
  justify-content: center;
  gap: 30px;
  min-height: 184px;
  padding: 24px 68px;
  background: rgba(251, 248, 242, 0.94);
  border-top: 1px solid var(--line);
  box-shadow: 0 -22px 60px rgba(24, 47, 42, 0.16);
  backdrop-filter: blur(20px);
}

.floating-subscribe > div {
  display: grid;
  justify-items: center;
  text-align: center;
}

.floating-subscribe img {
  width: 64px;
  height: 64px;
}

.floating-subscribe h2 {
  margin-top: 12px;
  font-size: 1.25rem;
}

.floating-subscribe .subscribe-form {
  margin-top: 0;
}

.close-button,
.modal-close {
  position: absolute;
  display: inline-grid;
  place-items: center;
  border: 0;
  color: var(--ink);
  background: transparent;
  font-size: 1.8rem;
  line-height: 1;
}

.close-button {
  top: 20px;
  right: 22px;
}

.close-button:hover,
.modal-close:hover {
  color: var(--coral);
}

.no-thanks {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  color: var(--ink);
  background: transparent;
  font-family: var(--mono);
  font-weight: 800;
}

.entry-gate {
  position: fixed;
  inset: 0;
  z-index: 90;
  display: grid;
  place-items: start center;
  min-height: 100vh;
  padding: 132px 24px 64px;
  color: var(--white);
  background:
    linear-gradient(180deg, rgba(21, 59, 52, 0.96), rgba(19, 49, 43, 0.98)),
    var(--green-dark);
}

.entry-gate::after {
  position: fixed;
  right: 0;
  bottom: 0;
  left: 0;
  height: 42vh;
  pointer-events: none;
  background: linear-gradient(180deg, transparent, rgba(217, 111, 103, 0.16));
  content: "";
}

.entry-close {
  position: fixed;
  top: 28px;
  right: 34px;
  z-index: 1;
  display: inline-grid;
  place-items: center;
  width: 36px;
  height: 36px;
  border: 0;
  color: var(--white);
  background: transparent;
  font-size: 2rem;
  line-height: 1;
}

.entry-close:hover,
.entry-no-thanks:hover {
  color: #f4b3aa;
}

.entry-card {
  position: relative;
  z-index: 1;
  display: grid;
  justify-items: center;
  width: min(100%, 460px);
  text-align: center;
}

.entry-card img {
  width: 88px;
  height: 88px;
  border: 1px solid rgba(255, 253, 248, 0.18);
  border-radius: 8px;
  object-fit: cover;
}

.entry-card h1 {
  margin: 28px 0 8px;
  color: var(--white);
  font-family: var(--serif);
  font-size: 2rem;
  line-height: 1.1;
  letter-spacing: 0;
}

.entry-card p {
  margin: 0 0 12px;
  color: rgba(255, 253, 248, 0.82);
  font-size: 1.02rem;
}

.entry-card strong {
  max-width: 390px;
  color: rgba(255, 253, 248, 0.82);
  font-family: var(--mono);
  font-size: 0.78rem;
  line-height: 1.55;
}

.entry-card .subscribe-form {
  margin-top: 32px;
}

.entry-card .input-row {
  border-color: var(--coral);
  background: rgba(255, 253, 248, 0.08);
}

.entry-card .input-row input {
  color: var(--white);
}

.entry-card .input-row button {
  background: var(--coral);
}

.entry-card .input-row button:hover {
  background: #c85e57;
}

.entry-card .notice {
  max-width: 390px;
  color: rgba(255, 253, 248, 0.68);
}

.entry-no-thanks {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  margin-top: 18px;
  border: 0;
  color: var(--white);
  background: transparent;
  font-family: var(--mono);
  font-weight: 800;
}

.entry-no-thanks span {
  font-size: 1.5rem;
  line-height: 1;
}

.modal-backdrop {
  position: fixed;
  inset: 0;
  z-index: 60;
  display: grid;
  place-items: center;
  min-height: 100vh;
  padding: 24px;
  background: rgba(21, 43, 38, 0.58);
  backdrop-filter: blur(14px);
}

.modal-close {
  top: 28px;
  right: 34px;
  color: var(--white);
}

.modal-card {
  width: min(100%, 540px);
  max-height: min(680px, calc(100vh - 96px));
  overflow: auto;
  padding: 34px;
  background: var(--white);
  border: 1px solid rgba(24, 47, 42, 0.2);
  border-radius: 8px;
  box-shadow: 0 24px 80px rgba(24, 47, 42, 0.26);
}

.search-modal label {
  display: block;
  margin-bottom: 12px;
  font-family: var(--mono);
  font-weight: 800;
}

.search-field {
  display: flex;
  align-items: center;
  gap: 10px;
  height: 48px;
  border: 1px solid var(--line-strong);
  border-radius: 8px;
  padding: 0 14px;
  background: rgba(47, 96, 79, 0.05);
}

.search-field span {
  color: var(--muted);
  font-family: var(--mono);
  font-size: 1.1rem;
}

.search-field input {
  flex: 1;
  min-width: 0;
  border: 0;
  color: var(--ink);
  background: transparent;
  outline: none;
}

.search-results {
  display: grid;
  gap: 8px;
  margin-top: 18px;
}

.search-result {
  display: grid;
  gap: 4px;
  width: 100%;
  border: 1px solid transparent;
  border-radius: 8px;
  color: var(--ink);
  background: rgba(47, 96, 79, 0.06);
  padding: 13px 14px;
  text-align: left;
}

.search-result:hover {
  border-color: var(--line-strong);
  background: rgba(47, 96, 79, 0.1);
}

.search-result small,
.empty-state,
.sign-in-modal p {
  color: var(--muted);
}

.subscribe-modal {
  display: grid;
  justify-items: center;
  text-align: center;
}

.sign-in-modal h2 {
  margin: 0 0 8px;
  color: var(--green-dark);
  font-family: var(--serif);
}

.sign-in-modal p {
  margin: 0 0 22px;
  line-height: 1.75;
}

.article-topbar .topbar-main {
  width: min(calc(100% - 48px), var(--max));
  margin: 0 auto;
  padding: 0;
}

.archive-page,
.article-page {
  width: min(calc(100% - 48px), var(--max));
  margin: 0 auto;
  padding-top: 64px;
}

.archive-hero {
  max-width: 820px;
  padding: 10px 0 48px;
}

.archive-hero p,
.article-meta-line,
.article-back,
.archive-card span,
.related-list small,
.archive-link {
  color: var(--muted);
  font-family: var(--mono);
  font-size: 0.78rem;
  font-weight: 800;
}

.archive-hero p {
  margin: 0 0 14px;
  color: var(--coral);
}

.archive-hero h1 {
  margin: 0;
  color: var(--green-dark);
  font-size: clamp(2.2rem, 6vw, 5.2rem);
  line-height: 1.02;
}

.archive-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 28px 24px;
}

.archive-card {
  display: grid;
  align-content: start;
  min-width: 0;
  border-bottom: 1px solid var(--line);
  padding-bottom: 22px;
}

.archive-card img {
  width: 100%;
  aspect-ratio: 16 / 10;
  object-fit: cover;
  border-radius: 8px;
  margin-bottom: 14px;
}

.archive-card h2 {
  margin: 8px 0 8px;
  color: var(--ink);
  font-size: 1.18rem;
  line-height: 1.38;
}

.archive-card p {
  display: -webkit-box;
  margin: 0;
  overflow: hidden;
  color: var(--ink-soft);
  font-size: 0.98rem;
  line-height: 1.68;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 3;
}

.article-page {
  display: grid;
  grid-template-columns: minmax(0, 760px) 300px;
  gap: 82px;
  align-items: start;
}

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

.article-back {
  display: inline-flex;
  margin-bottom: 28px;
}

.article-back:hover,
.archive-link:hover {
  color: var(--coral);
}

.article-meta-line {
  color: var(--coral);
}

.article-detail h1 {
  margin: 18px 0 18px;
  color: var(--green-dark);
  font-size: clamp(2rem, 4.7vw, 4.35rem);
  line-height: 1.08;
}

.article-lede {
  margin: 0 0 34px;
  color: var(--ink-soft);
  font-size: 1.18rem;
  line-height: 1.82;
}

.article-content {
  color: #223b35;
  font-size: 1.08rem;
  line-height: 1.92;
}

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

.article-content p,
.article-content ul,
.article-content ol,
.article-content blockquote {
  margin: 0 0 1.26em;
}

.article-content h2,
.article-content h3,
.article-content h4 {
  margin: 2.05em 0 0.72em;
  color: var(--green-dark);
  line-height: 1.25;
}

.article-content h2 {
  font-size: 1.62rem;
}

.article-content h3,
.article-content h4 {
  font-size: 1.28rem;
}

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

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

.article-content blockquote {
  border-left: 3px solid var(--coral);
  color: var(--ink-soft);
  padding: 4px 0 4px 18px;
}

.article-content hr {
  height: 1px;
  border: 0;
  background: var(--line);
  margin: 34px 0;
}

.article-content a {
  color: var(--green);
  text-decoration: underline;
  text-underline-offset: 3px;
}

.article-aside {
  position: sticky;
  top: 116px;
  border-top: 1px solid var(--line);
  padding-top: 18px;
}

.article-aside h2 {
  margin: 0 0 10px;
  color: var(--green-dark);
  font-family: var(--mono);
  font-size: 0.9rem;
}

.related-list {
  display: grid;
  gap: 0;
}

.related-list a {
  display: grid;
  gap: 5px;
  border-bottom: 1px solid var(--line);
  padding: 14px 0;
}

.related-list span {
  color: var(--ink);
  font-weight: 900;
  line-height: 1.45;
}

.about-copy {
  display: grid;
  gap: 22px;
  max-width: 720px;
  margin-top: 30px;
}

.about-copy p {
  color: var(--ink-soft);
  font-size: 1.08rem;
}

.about-copy .primary-button {
  width: fit-content;
}

.archive-link {
  display: inline-flex;
  margin-top: 28px;
  color: var(--green);
}

footer {
  display: grid;
  justify-items: center;
  gap: 22px;
  padding: 42px 24px 54px;
  color: rgba(255, 253, 248, 0.68);
  background: var(--green-dark);
  border-top: 1px solid rgba(255, 253, 248, 0.12);
  text-align: center;
}

footer p {
  margin: 0;
}

.footer-actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 10px;
}

.footer-actions button,
.footer-actions a {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  min-height: 37px;
  border-radius: 8px;
  color: var(--green-dark);
  background: var(--white);
  padding: 0 18px;
  font-family: var(--mono);
  font-weight: 800;
}

footer a {
  text-decoration: underline;
}

@media (max-width: 980px) {
  .topbar-main {
    grid-template-columns: auto 1fr auto;
  }

  .mobile-menu {
    display: inline-grid;
    justify-self: start;
  }

  .brand-mark {
    display: none;
  }

  .site-title {
    justify-self: center;
  }

  .top-actions {
    gap: 6px;
  }

  .top-actions .plain-button,
  .top-actions .icon-button:nth-child(2) {
    display: none;
  }

  .nav-row {
    display: none;
    justify-content: flex-start;
    overflow-x: auto;
    padding: 0 18px 14px;
  }

  .nav-row.is-open {
    display: flex;
  }

  .popular-strip {
    display: flex;
    overflow-x: auto;
    scroll-snap-type: x mandatory;
    padding-bottom: 8px;
  }

  .popular-item {
    flex: 0 0 286px;
    scroll-snap-align: start;
  }

  .article-section {
    grid-template-columns: 1fr;
    gap: 22px;
  }

  .article-heading {
    align-items: center;
  }

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

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

  .article-page {
    grid-template-columns: 1fr;
    gap: 42px;
  }

  .article-aside {
    position: static;
  }

  .floating-subscribe {
    grid-template-columns: minmax(0, 440px);
    padding: 52px 24px 28px;
  }

  .floating-subscribe .close-button {
    top: 10px;
    right: 16px;
  }

  .floating-subscribe > div {
    display: none;
  }
}

@media (max-width: 640px) {
  .topbar-main {
    min-height: 62px;
    padding: 0 12px;
  }

  .site-title {
    font-size: 1.22rem;
  }

  .top-actions .icon-button {
    width: 34px;
    height: 34px;
  }

  .subscribe-button {
    min-height: 34px;
    padding: 0 12px;
    font-size: 0.82rem;
  }

  .content-wrap {
    width: min(calc(100% - 28px), var(--max));
    padding-top: 14px;
  }

  .hero,
  .hero-copy {
    min-height: 330px;
  }

  .hero-copy {
    padding: 34px 24px;
  }

  .hero h1 {
    font-size: 2rem;
  }

  .hero p {
    font-size: 0.98rem;
  }

  .hero-shade {
    background: linear-gradient(90deg, rgba(21, 51, 43, 0.88), rgba(21, 51, 43, 0.58));
  }

  .article-row {
    grid-template-columns: minmax(0, 1fr);
    gap: 14px;
  }

  .thumb.large {
    width: 100%;
  }

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

  .archive-page,
  .article-page {
    width: min(calc(100% - 28px), var(--max));
    padding-top: 38px;
  }

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

  .archive-hero {
    padding-bottom: 34px;
  }

  .archive-hero h1 {
    font-size: 2.32rem;
  }

  .article-topbar .topbar-main {
    width: min(calc(100% - 28px), var(--max));
  }

  .article-topbar .top-actions {
    gap: 8px;
  }

  .article-detail h1 {
    font-size: 2.18rem;
  }

  .article-lede,
  .article-content {
    font-size: 1rem;
  }

  .tab-panel h1 {
    font-size: 2.25rem;
  }

  .input-row {
    grid-template-columns: 1fr;
  }

  .input-row button {
    height: 42px;
  }

  .floating-subscribe {
    max-height: 82vh;
    overflow: auto;
  }

  .modal-card {
    padding: 26px 18px;
  }

  .entry-gate {
    padding: 104px 24px 48px;
  }

  .entry-close {
    top: 24px;
    right: 22px;
  }

  .entry-card h1 {
    font-size: 1.82rem;
  }
}
