:root {
  --bg: #ffffff;
  --text: #1a1a1a;
  --muted: #737373;
  --border: #e5e5e5;
  --surface-muted: #fafafa;
  --surface-hover: #f5f5f5;
  --surface-active: #f0f0f0;
  --search-focus-border: #d4d4d4;
  --placeholder: #a3a3a3;
  --body-text: #404040;
  --action-accent: #a63d3d;
  --rail-w: 132px;
  --main-gap: 20px;
  --column-max: 420px;
  --font: "Source Sans 3", ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  --font-headline: "Newsreader", Georgia, "Times New Roman", Times, serif;
  --frame-nudge: 72px;
  --img-bw-filter: grayscale(1) contrast(1.02) brightness(1.32);
  --invite-arrow: color-mix(in srgb, var(--action-accent) 36%, var(--muted));
  --invite-text: color-mix(in srgb, var(--muted) 40%, var(--placeholder));
  --post-hash-flash-bg: color-mix(in srgb, var(--text) 7%, transparent);
}

html[data-theme="dark"] {
  color-scheme: dark;
  --bg: #0a0a0a;
  --text: #fafafa;
  --muted: #b0b0b0;
  --border: rgba(255, 255, 255, 0.1);
  --surface-muted: #141414;
  --surface-hover: #1f1f1f;
  --surface-active: #262626;
  --search-focus-border: #4a4a4a;
  --placeholder: #8a8a8a;
  --body-text: #c4c4c4;
  --action-accent: #d67a7a;
  --img-bw-filter: grayscale(1) contrast(1.04) brightness(1.38);
  --invite-arrow: color-mix(in srgb, var(--action-accent) 30%, var(--muted));
  --invite-text: color-mix(in srgb, var(--muted) 38%, var(--body-text));
  --post-hash-flash-bg: color-mix(in srgb, var(--text) 14%, transparent);
}

html[data-theme="light"] {
  color-scheme: light;
}

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

html {
  -webkit-text-size-adjust: 100%;
  color-scheme: light dark;
  /* Sticky topbar: align hash / scrollIntoView so post meta isn’t hidden under it */
  scroll-padding-top: 96px;
}

/* Dashboard: hide UI until auth guard finishes (prevents flash / redirect ping-pong) */
html.dashboard-auth-pending body {
  visibility: hidden;
}

html.dashboard-auth-pending body * {
  animation: none !important;
}

@media (prefers-reduced-motion: no-preference) {
  html {
    scroll-behavior: smooth;
  }
}

body {
  margin: 0;
  min-height: 100dvh;
  background: var(--bg);
  color: var(--text);
  font-family: var(--font);
  font-size: 15px;
  line-height: 1.65;
  letter-spacing: -0.01em;
}

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

.icon {
  width: 22px;
  height: 22px;
  flex-shrink: 0;
}

.icon--inline {
  width: 16px;
  height: 16px;
  opacity: 0.45;
}

/* Centered page frame: topbar + rail + column (nudged slightly left of center) */
.frame {
  width: 100%;
  /* Include horizontal padding so inner row still fits rail + gap + column */
  max-width: calc(var(--rail-w) + var(--main-gap) + var(--column-max) + 32px + 88px);
  margin-inline: auto;
  padding: 0 16px;
  min-height: 100dvh;
  display: flex;
  flex-direction: column;
  box-sizing: border-box;
}

@media (min-width: 640px) {
  .frame {
    transform: translateX(calc(-1 * var(--frame-nudge)));
  }
}

.main-row {
  display: flex;
  align-items: flex-start;
  gap: var(--main-gap);
  flex: 1;
}

/* Left nav: icon + label (beside column, not viewport edge) */
.rail {
  flex-shrink: 0;
  width: var(--rail-w);
  display: flex;
  flex-direction: column;
  align-items: stretch;
  gap: 2px;
  padding: 24px 10px 40px 0;
  border-right: 1px solid var(--border);
  background: var(--bg);
}

.rail__link {
  display: flex;
  align-items: center;
  justify-content: flex-start;
  gap: 10px;
  min-height: 40px;
  padding: 7px 8px;
  border-radius: 8px;
  color: var(--muted);
  text-decoration: none;
  transition: color 0.15s ease, background 0.15s ease;
}

.rail__label {
  font-size: 12.5px;
  font-weight: 500;
  letter-spacing: 0.02em;
  white-space: nowrap;
}

.rail__link:hover {
  color: var(--text);
  background: var(--surface-hover);
}

.rail__link--active {
  color: var(--text);
  background: var(--surface-active);
}

.topbar {
  position: sticky;
  top: 0;
  z-index: 5;
  display: flex;
  justify-content: center;
  padding: 14px 0 18px;
  background: var(--bg);
  border-bottom: 1px solid var(--border);
}

.topbar__inner {
  display: flex;
  align-items: center;
  justify-content: center;
  flex-wrap: wrap;
  gap: 16px;
  width: 100%;
}

.topbar__tools {
  display: flex;
  align-items: center;
  gap: 10px;
  flex: 1 1 300px;
  max-width: min(440px, 100%);
  min-width: 0;
}

.weather {
  flex-shrink: 0;
  display: flex;
  align-items: center;
  gap: 8px;
  min-width: 0;
  max-width: 100px;
  padding: 2px 0;
}

.weather__icon {
  width: 34px;
  height: 34px;
  flex-shrink: 0;
  color: var(--muted);
}

.weather__icon svg {
  width: 100%;
  height: 100%;
  display: block;
}

.weather__text {
  display: flex;
  flex-direction: column;
  gap: 2px;
  min-width: 0;
  line-height: 1.15;
}

.weather__temp {
  font-size: 14px;
  font-weight: 600;
  color: var(--text);
  font-variant-numeric: tabular-nums;
}

.weather__place {
  font-size: 10px;
  font-weight: 500;
  letter-spacing: 0.07em;
  color: var(--muted);
  text-transform: uppercase;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.weather--muted .weather__temp {
  font-size: 12px;
  font-weight: 500;
  color: var(--muted);
}

.weather--muted .weather__place {
  letter-spacing: 0.05em;
}

.theme-toggle {
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  padding: 0;
  border: 1px solid var(--border);
  border-radius: 8px;
  background: var(--surface-muted);
  color: var(--muted);
  cursor: pointer;
  transition: color 0.15s ease, background 0.15s ease, border-color 0.15s ease;
}

.theme-toggle:hover {
  color: var(--text);
  background: var(--surface-hover);
}

.theme-toggle:focus-visible {
  outline: 2px solid var(--text);
  outline-offset: 2px;
}

.icon--theme {
  width: 18px;
  height: 18px;
}

.theme-icon--sun {
  display: none;
}

.theme-icon--moon {
  display: block;
}

html[data-theme="dark"] .theme-icon--moon {
  display: none;
}

html[data-theme="dark"] .theme-icon--sun {
  display: block;
}

.brand {
  flex-shrink: 0;
  font-family: var(--font-headline);
  font-size: 16px;
  font-weight: 700;
  letter-spacing: 0.02em;
  color: var(--text);
  text-decoration: none;
}

a.brand:hover {
  color: var(--muted);
}

.brand-stack {
  flex-shrink: 0;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 2px;
  line-height: 1.2;
}

.brand-row {
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

.icon--brand-cursor {
  width: 18px;
  height: 18px;
  flex-shrink: 0;
  color: var(--muted);
  opacity: 0.72;
  pointer-events: none;
  translate: 0 0.5px;
  transition: opacity 0.2s ease, translate 0.2s ease;
}

.brand-row:hover .icon--brand-cursor {
  opacity: 1;
  translate: 0 -1px;
}

.tagline {
  margin: 0;
  font-family: var(--font-body);
  font-size: 10px;
  font-weight: 500;
  letter-spacing: 0.05em;
  color: var(--muted);
  opacity: 0.82;
}

.search-wrap {
  flex: 1;
  min-width: 0;
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 0 12px;
  height: 36px;
  border: 1px solid var(--border);
  border-radius: 8px;
  background: var(--surface-muted);
  transition: border-color 0.15s ease, background 0.15s ease;
}

.search-wrap:focus-within {
  border-color: var(--search-focus-border);
  background: var(--bg);
}

.search {
  flex: 1;
  min-width: 0;
  border: 0;
  background: transparent;
  font: inherit;
  font-size: 13px;
  color: var(--text);
  outline: none;
}

.search::placeholder {
  color: var(--placeholder);
}

.search::-webkit-search-cancel-button {
  display: none;
}

/* Narrow column */
.content {
  flex: 1;
  min-width: 0;
  max-width: var(--column-max);
  padding: 40px 0 56px;
}

.feed__empty {
  margin: 0 0 24px;
  font-size: 14px;
  color: var(--muted);
  letter-spacing: 0.02em;
}

.feed-search-results {
  margin: 0 0 28px;
}

.feed-search-results__heading {
  margin: 0 0 12px;
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--muted);
}

.feed-search-results .archive-item--review .archive-item__thumb {
  filter: var(--img-bw-filter) brightness(1.16);
}

.feed-search-results .archive-item__thumb--placeholder {
  display: block;
  flex-shrink: 0;
  width: 72px;
  height: 48px;
  border-radius: 6px;
  background: var(--surface-muted);
}

/* Static pages (about, archive) */
.page__lede {
  margin: 0 0 20px;
  color: var(--body-text);
  font-size: 15px;
}

.archive-list {
  list-style: none;
  margin: 0;
  padding: 0;
}

.archive-item {
  border-bottom: 1px solid var(--border);
  padding: 16px 0;
}

.archive-item:last-child {
  border-bottom: 0;
}

.archive-item__link {
  display: flex;
  align-items: flex-start;
  gap: 14px;
  text-decoration: none;
  color: inherit;
  transition: color 0.15s ease;
}

.archive-item__link:hover .archive-item__title {
  color: var(--muted);
}

.archive-item__thumb {
  flex-shrink: 0;
  width: 72px;
  height: 48px;
  object-fit: cover;
  object-position: center;
  border-radius: 6px;
  background: var(--surface-muted);
  filter: var(--img-bw-filter);
}

.archive-item__body {
  flex: 1;
  min-width: 0;
}

.archive-item time {
  display: block;
  font-size: 12px;
  color: var(--muted);
  margin-bottom: 6px;
  letter-spacing: 0.02em;
}

.archive-item__title {
  display: block;
  font-family: var(--font-headline);
  font-size: 15px;
  font-weight: 600;
  letter-spacing: 0.01em;
  line-height: 1.35;
}

/* Auth (login / sign up) */
.auth-block {
  margin-bottom: 36px;
  padding-bottom: 32px;
  border-bottom: 1px solid var(--border);
}

.auth-block:last-of-type {
  margin-bottom: 0;
  padding-bottom: 0;
  border-bottom: 0;
}

.auth-block__title {
  margin: 0 0 16px;
  font-family: var(--font);
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--muted);
}

.auth-form {
  display: flex;
  flex-direction: column;
  gap: 14px;
  max-width: 280px;
}

.auth-field {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.auth-field__label {
  font-size: 12px;
  font-weight: 500;
  color: var(--muted);
  letter-spacing: 0.02em;
}

.auth-input {
  height: 36px;
  padding: 0 12px;
  border: 1px solid var(--border);
  border-radius: 8px;
  background: var(--surface-muted);
  font: inherit;
  font-size: 14px;
  color: var(--text);
  transition: border-color 0.15s ease, background 0.15s ease;
}

.auth-input::placeholder {
  color: var(--placeholder);
}

.auth-input:focus {
  outline: none;
  border-color: var(--search-focus-border);
  background: var(--bg);
}

.auth-feedback {
  margin: 0;
  font-size: 13px;
  line-height: 1.45;
  letter-spacing: 0.01em;
}

.auth-feedback--error {
  color: var(--action-accent);
}

.auth-feedback--success {
  color: var(--body-text);
}

.auth-submit:disabled {
  opacity: 0.65;
  cursor: not-allowed;
}

.auth-password-wrap {
  display: flex;
  align-items: center;
  height: 36px;
  width: 100%;
  border: 1px solid var(--border);
  border-radius: 8px;
  background: var(--surface-muted);
  transition: border-color 0.15s ease, background 0.15s ease;
}

.auth-password-wrap:focus-within {
  border-color: var(--search-focus-border);
  background: var(--bg);
}

.auth-password-wrap .auth-input--password {
  flex: 1;
  min-width: 0;
  height: 100%;
  padding: 0 10px 0 12px;
  border: 0;
  border-radius: 0;
  background: transparent;
}

.auth-password-wrap .auth-input--password:focus {
  border-color: transparent;
  background: transparent;
}

.auth-password-toggle {
  flex-shrink: 0;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 100%;
  margin: 0;
  padding: 0;
  border: none;
  border-radius: 0 7px 7px 0;
  background: transparent;
  color: var(--muted);
  cursor: pointer;
  transition: color 0.18s ease, background 0.18s ease, box-shadow 0.18s ease;
}

.auth-password-toggle__icon {
  width: 18px;
  height: 18px;
  opacity: 0.72;
  transition: opacity 0.18s ease;
}

.auth-password-toggle:hover {
  color: var(--text);
  background: color-mix(in srgb, var(--surface-hover) 70%, transparent);
  box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--border) 65%, transparent);
}

.auth-password-toggle:hover .auth-password-toggle__icon {
  opacity: 1;
}

.auth-password-toggle:active {
  background: color-mix(in srgb, var(--surface-active) 55%, transparent);
}

.auth-password-toggle[aria-pressed="true"] {
  color: var(--text);
}

.auth-password-toggle[aria-pressed="true"] .auth-password-toggle__icon {
  opacity: 1;
}

.auth-password-toggle:focus-visible {
  outline: 2px solid color-mix(in srgb, var(--action-accent) 45%, var(--muted));
  outline-offset: -2px;
}

@media (pointer: coarse) {
  .auth-password-wrap {
    min-height: 44px;
    height: auto;
  }

  .auth-password-toggle {
    min-width: 44px;
    width: auto;
    padding: 0 6px;
  }
}

.auth-submit {
  align-self: flex-start;
  margin-top: 4px;
  height: 36px;
  padding: 0 16px;
  border: 1px solid var(--border);
  border-radius: 8px;
  background: var(--surface-muted);
  font: inherit;
  font-size: 13px;
  font-weight: 600;
  color: var(--text);
  cursor: pointer;
  transition: background 0.15s ease, color 0.15s ease;
}

.auth-submit:hover {
  background: var(--surface-hover);
}

.auth-logout {
  height: 36px;
  padding: 0 16px;
  border: 1px solid var(--border);
  border-radius: 8px;
  background: var(--surface-muted);
  font: inherit;
  font-size: 13px;
  font-weight: 600;
  color: var(--muted);
  cursor: pointer;
  transition: background 0.15s ease, color 0.15s ease;
}

.auth-logout:hover {
  color: var(--text);
  background: var(--surface-hover);
}

.site-footer {
  display: flex;
  flex-direction: column;
  align-items: stretch;
  gap: 16px;
  margin-top: auto;
  padding: 20px 0 28px;
  border-top: 1px solid var(--border);
  font-size: 12px;
  color: var(--muted);
  letter-spacing: 0.02em;
}

.site-footer__tagline {
  margin: 0;
  text-align: center;
  align-self: center;
  max-width: 100%;
  font-size: 13px;
  font-weight: 500;
  color: var(--muted);
  letter-spacing: 0.03em;
}

.site-footer__bar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 12px 20px;
  width: 100%;
}

.site-footer__copy {
  margin: 0;
}

.site-footer__top {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  color: var(--muted);
  text-decoration: none;
  font-weight: 500;
  transition: color 0.15s ease;
}

.site-footer__top:hover {
  color: var(--text);
}

.icon--footer-up {
  width: 14px;
  height: 14px;
  flex-shrink: 0;
}

.post {
  padding-bottom: 48px;
  margin-bottom: 48px;
  border-bottom: 1px solid var(--border);
  background-color: transparent;
}

.post.post--hash-flash {
  animation: post-hash-flash 1.4s ease-out forwards;
}

@keyframes post-hash-flash {
  0%,
  18% {
    background-color: var(--post-hash-flash-bg);
  }

  100% {
    background-color: transparent;
  }
}

@media (prefers-reduced-motion: reduce) {
  .post.post--hash-flash {
    animation: none;
  }
}

.post:last-child {
  margin-bottom: 0;
  padding-bottom: 0;
  border-bottom: 0;
}

.post__meta {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  margin: 0 0 16px;
  font-size: 12px;
  font-weight: 500;
  letter-spacing: 0.04em;
  color: var(--muted);
  line-height: 1.45;
}

.post__meta-type {
  text-transform: uppercase;
  font-size: 10px;
  font-weight: 600;
  letter-spacing: 0.12em;
}

.post__meta-type::after,
.post__meta-date::after {
  content: "·";
  margin: 0 6px;
  opacity: 0.55;
  font-weight: 500;
  letter-spacing: 0.04em;
}

.post__meta-date {
  font-weight: 500;
  letter-spacing: 0.02em;
}

.post__meta-by {
  font-weight: 500;
  letter-spacing: 0.02em;
}

.post__meta a {
  color: inherit;
  font-weight: 600;
  text-decoration: underline;
  text-decoration-color: var(--border);
  text-decoration-thickness: 1px;
  text-underline-offset: 2px;
  transition: color 0.15s ease, text-decoration-color 0.15s ease;
}

.post__meta a:hover {
  color: var(--text);
  text-decoration-color: var(--muted);
}

.post__title {
  margin: 0 0 22px;
  font-family: var(--font-headline);
  font-size: 1.4rem;
  font-weight: 600;
  line-height: 1.3;
  letter-spacing: 0.01em;
  color: var(--text);
}

.post__cover {
  margin: 0 0 22px;
  width: 100%;
  max-width: 100%;
  min-width: 0;
}

/* Supporting visual after opinion text: shorter crop, lighter presence */
.post__cover--support {
  margin: 18px 0 20px;
}

.post__cover-img {
  display: block;
  width: 100%;
  max-width: 100%;
  height: auto;
  aspect-ratio: 3 / 2;
  object-fit: cover;
  object-position: center;
  border-radius: 10px;
  background: var(--surface-muted);
  filter: var(--img-bw-filter);
}

.post__cover--support .post__cover-img {
  aspect-ratio: 12 / 5;
  border-radius: 8px;
}

.post--review .post__cover-img {
  filter: var(--img-bw-filter) brightness(1.16);
}

.archive-list > .archive-item:first-child .archive-item__thumb {
  filter: var(--img-bw-filter) brightness(1.16);
}

.post__cover-credit {
  margin: 3px 0 0;
  font-size: 10px;
  font-weight: 400;
  font-style: italic;
  letter-spacing: 0.03em;
  color: var(--placeholder);
  line-height: 1.4;
}

.post__cover-credit a {
  color: inherit;
  font-weight: 500;
  font-style: italic;
  text-decoration: underline;
  text-decoration-color: color-mix(in srgb, var(--placeholder) 55%, transparent);
  text-underline-offset: 2px;
  transition: color 0.15s ease, text-decoration-color 0.15s ease;
}

.post__cover-credit a:hover {
  color: var(--muted);
  text-decoration-color: var(--border);
}

.post__body {
  margin: 0 0 14px;
  color: var(--body-text);
  font-size: 15px;
}

.post__body a {
  color: var(--text);
  font-weight: 500;
  text-decoration: underline;
  text-decoration-color: var(--muted);
  text-decoration-thickness: 1px;
  text-underline-offset: 3px;
  transition: text-decoration-color 0.15s ease, color 0.15s ease;
}

.post__body a:hover {
  text-decoration-color: var(--text);
  color: var(--text);
}

/* “Escape hatch” lookups: your take stays plain text; dotted underline = look it up elsewhere */
.post__body a.discovery-link {
  text-decoration-style: dotted;
  text-decoration-color: var(--muted);
  text-decoration-thickness: 1px;
  text-underline-offset: 3px;
}

.post__body a.discovery-link:hover {
  text-decoration-style: solid;
  text-decoration-color: var(--text);
  color: var(--text);
}

.post__body a.discovery-link::after {
  content: "\00a0↗";
  font-size: 0.68em;
  font-weight: 600;
  text-decoration: none;
  opacity: 0;
  transition: opacity 0.15s ease;
}

.post__body a.discovery-link:hover::after {
  opacity: 0.55;
}

.post__body:last-child {
  margin-bottom: 0;
}

/* Short-form post shapes: review, take, link */
.post__verdict-wrap {
  margin: 0 0 20px;
  padding: 14px 0 12px 14px;
  border-left: 3px solid var(--text);
}

.post__verdict {
  margin: 0;
  font-family: var(--font-headline);
  font-size: clamp(1.05rem, 2.5vw, 1.2rem);
  font-weight: 700;
  line-height: 1.35;
  color: var(--text);
  letter-spacing: 0.02em;
}

.post__rating-group {
  display: inline-flex;
  align-items: center;
  vertical-align: baseline;
  white-space: nowrap;
}

.post__rating-stars {
  display: inline-flex;
  align-items: center;
  gap: 0;
  font-family: var(--font);
  font-size: 0.62em;
  font-weight: 500;
  line-height: 1;
  letter-spacing: -0.14em;
  color: color-mix(in srgb, var(--text) 68%, var(--muted));
  translate: 0 0.04em;
}

.post__star--off {
  color: color-mix(in srgb, var(--muted) 75%, var(--border));
  opacity: 0.95;
}

.post__block {
  margin: 0 0 16px;
}

.post__list-label {
  margin: 0 0 8px;
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--muted);
}

.post__bullets {
  margin: 0;
  padding-left: 1.15em;
  color: var(--body-text);
  font-size: 15px;
  line-height: 1.55;
}

.post__bullets li {
  margin-bottom: 6px;
}

.post__bullets li:last-child {
  margin-bottom: 0;
}

.post__invite {
  margin: 26px 0 10px;
  font-size: 14px;
  font-weight: 400;
  color: var(--invite-text);
  font-style: italic;
  line-height: 1.55;
  letter-spacing: 0.01em;
}

.post__invite::before {
  content: "→";
  color: var(--invite-arrow);
  font-family: var(--font);
  font-style: normal;
  font-weight: 500;
  font-size: 0.95em;
  margin-right: 0.45em;
  letter-spacing: 0;
  opacity: 0.88;
}

html[data-theme="dark"] .post__invite {
  font-weight: 500;
}

html[data-theme="dark"] .post__invite::before {
  opacity: 0.8;
}

.post__friction-hint {
  margin: 0 0 8px;
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.03em;
  color: var(--muted);
}

.post__link-target {
  margin: 0 0 12px;
  font-size: 14px;
  line-height: 1.45;
  word-break: break-word;
}

.post__external {
  color: var(--text);
  font-weight: 500;
  text-decoration: underline;
  text-decoration-color: var(--border);
  text-underline-offset: 3px;
  transition: text-decoration-color 0.15s ease;
}

.post__external:hover {
  text-decoration-color: var(--muted);
}

.post__take {
  margin: 0 0 14px;
  color: var(--body-text);
  font-size: 15px;
  line-height: 1.55;
}

.post__actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 4px 20px;
  margin-top: 0;
  padding-top: 14px;
}

.post__action {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  padding: 4px 0;
  font-size: 12px;
  font-weight: 500;
  letter-spacing: 0.02em;
  color: var(--muted);
  text-decoration: none;
  transition: color 0.15s ease;
}

.post__action:hover {
  color: color-mix(in srgb, var(--action-accent) 38%, var(--muted));
}

.post__action:focus-visible {
  color: color-mix(in srgb, var(--action-accent) 48%, var(--muted));
  outline: 2px solid color-mix(in srgb, var(--action-accent) 42%, var(--muted));
  outline-offset: 2px;
  border-radius: 2px;
}

button.post__action {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  padding: 4px 0;
  font: inherit;
  font-size: 12px;
  font-weight: 500;
  letter-spacing: 0.02em;
  line-height: inherit;
  color: inherit;
  background: none;
  border: none;
  margin: 0;
  cursor: pointer;
  text-align: left;
}

.post__action--copy {
  margin-inline-start: 1.35rem;
}

.post__action--copy.is-copied {
  color: var(--text);
}

.post__action--copy.is-copied:hover {
  color: var(--text);
}

.icon--post-action {
  width: 18px;
  height: 18px;
  flex-shrink: 0;
  opacity: 0.85;
}

.post__action:hover .icon--post-action {
  opacity: 1;
}

@media (max-width: 520px) {
  html {
    scroll-padding-top: 132px;
  }

  .topbar {
    padding: 12px 0 14px;
  }

  .topbar__tools {
    flex: 1 1 100%;
    max-width: none;
  }

  .search-wrap {
    flex: 1;
    min-width: 0;
  }

  .main-row {
    flex-direction: column;
  }

  .rail {
    flex-direction: row;
    flex-wrap: wrap;
    justify-content: center;
    align-items: center;
    width: 100%;
    padding: 10px 4px;
    border-right: none;
    border-bottom: 1px solid var(--border);
  }

  .rail__link {
    width: auto;
    min-height: 36px;
    padding: 6px 8px;
  }

  .content {
    padding-top: 24px;
    max-width: none;
  }

  .site-footer {
    padding-bottom: 24px;
  }

  .site-footer__bar {
    flex-direction: column;
    align-items: flex-start;
  }
}
