/* Starchan — imageboard component styles */

/* Board header */
.board-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: var(--gap-md);
  flex-wrap: wrap;
  border-bottom: 1px solid var(--border);
  padding-bottom: var(--gap-md);
  margin-bottom: var(--gap-md);
}
.board-header-text { flex: 1 1 0; min-width: 0; }
.board-header h1 {
  font-size: var(--font-size-lg);
  color: var(--text);
}
.board-desc {
  font-size: var(--font-size-sm);
  color: var(--text);
  margin-top: var(--gap-xs);
}
.board-actions {
  display: flex;
  gap: var(--gap-xs);
  align-items: center;
  flex-shrink: 0;
  flex-wrap: wrap;
}
.board-action-btn {
  display: inline-block;
  padding: 5px 14px;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  font-size: var(--font-size-sm);
  font-weight: var(--font-weight-medium);
  color: var(--text);
  text-decoration: none;
  background: var(--bg-post);
  transition: border-color var(--transition-fast), color var(--transition-fast), background var(--transition-fast);
}
.board-action-btn:hover {
  border-color: var(--gold);
  color: var(--gold);
  background: var(--gold-alpha);
}
.board-action-btn--primary {
  background: var(--gold);
  color: var(--navy);
  border-color: var(--gold);
  font-weight: var(--font-weight-bold);
}
.board-action-btn--primary:hover {
  background: var(--gold-light);
  border-color: var(--gold-light);
  color: var(--navy);
}

/* Thread container */
.thread,
.thread-summary {
  border-bottom: 1px solid var(--border);
  padding: var(--gap-md) 0;
  overflow: hidden;
}

.thread:last-child,
.thread-summary:last-child {
  border-bottom: none;
}

/* OP post */
.op-post {
  background: var(--bg-post);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  padding: var(--gap-md);
  margin-bottom: var(--gap-sm);
  overflow: hidden;
}

/* Reply post */
.reply-post,
.post {
  background: var(--bg-post);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  padding: var(--gap-sm) var(--gap-md);
  margin-bottom: var(--gap-sm);
  margin-left: 24px;
  overflow: hidden;
  content-visibility: auto;
  contain-intrinsic-size: 0 200px;
}

@media (min-width: 768px) {
  .reply-post {
    margin-left: 32px;
  }
}

/* Post header */
.post-header {
  display: flex;
  flex-wrap: wrap;
  gap: var(--gap-sm);
  align-items: baseline;
  margin-bottom: var(--gap-xs);
  font-size: var(--font-size-sm);
}

.post-id,
.post-author,
.post-time {
  color: var(--text);
}

.post-author {
  color: var(--gold);
  font-weight: var(--font-weight-semibold);
}

.post-time {
  color: var(--text-dim);
  font-size: var(--font-size-xs);
}

.post-id {
  font-weight: bold;
}

/* Post image thumbnail */
.post-image,
.thread-thumb {
  float: left;
  margin: 0 var(--gap-md) var(--gap-sm) 0;
  max-width: 250px;
}

.post-image img,
.thread-thumb img {
  max-width: 250px;
  max-height: 250px;
  width: auto;
  height: auto;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  cursor: pointer;
}

/* Post body */
.post-body,
.thread-preview {
  font-size: var(--font-size-base);
  line-height: var(--line-height);
  word-break: break-word;
  overflow-wrap: break-word;
}

/* Greentext */
.post-body .gt,
.gt {
  color: var(--greentext);
}

/* Quote links */
.post-body a[href^="#"],
.post-body .quotelink {
  color: var(--link);
}

/* Thread info / meta */
.thread-info {
  overflow: hidden;
}

.thread-title {
  font-weight: bold;
  font-size: var(--font-size-base);
  display: block;
  margin-bottom: var(--gap-xs);
}

.thread-meta {
  font-size: var(--font-size-sm);
  color: var(--text);
  margin-left: var(--gap-sm);
}

/* Reply form — full column width (2026-07-21 owner feedback: the old
   inline-block shrink-to-fit box read as "alpha"; the form should use the
   screen). */
.reply-form {
  background: var(--bg-post);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  padding: var(--gap-md);
  margin-top: var(--gap-lg);
  display: block;
  width: 100%;
  box-sizing: border-box;
}

.reply-form h3 {
  font-size: var(--font-size-base);
  margin-bottom: var(--gap-md);
  color: var(--text);
  border-bottom: 1px solid var(--border);
  padding-bottom: var(--gap-sm);
}

.reply-form label {
  font-size: var(--font-size-sm);
  color: var(--text);
  display: block;
  margin-bottom: var(--gap-xs);
}

.reply-textarea,
.reply-form textarea {
  background: var(--bg);
  color: var(--text);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  padding: var(--gap-sm);
  font-family: var(--font-main);
  font-size: var(--font-size-base);
  width: 100%;
  min-height: 160px;
  box-sizing: border-box;
  resize: vertical;
}

.reply-form > div {
  margin-bottom: var(--gap-sm);
}

.submit-btn,
.reply-form button[type="submit"] {
  background: var(--bg);
  color: var(--text);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  padding: var(--gap-xs) var(--gap-md);
  cursor: pointer;
  font-size: var(--font-size-sm);
}

.submit-btn:hover,
.reply-form button[type="submit"]:hover {
  color: var(--hover);
  border-color: var(--hover);
}

/* Sage label */
.sage-label,
.reply-form label:has(input[type="checkbox"]) {
  display: flex;
  align-items: center;
  gap: var(--gap-sm);
  flex-direction: row;
}

/* Search form */
.search-form {
  display: flex;
  flex-wrap: wrap;
  gap: var(--gap-sm);
  align-items: center;
  margin-bottom: var(--gap-lg);
}

.search-form .form-input {
  flex: 1 1 180px;
  min-width: 0;
}

.search-form .submit-btn {
  flex: 0 0 auto;
}

/* Catalog grid */
.catalog-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: var(--gap-md);
  margin-top: var(--gap-md);
}

@media (max-width: 768px) {
  .catalog-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 480px) {
  .catalog-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: var(--gap-sm);
  }
}

/* Catalog card */
.catalog-card {
  background: var(--bg-post);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  padding: var(--gap-sm);
  text-align: center;
  overflow: hidden;
}

.catalog-card img {
  max-width: 100%;
  max-height: 150px;
  width: auto;
  height: auto;
  margin: 0 auto var(--gap-xs);
}

.catalog-card .card-title {
  font-weight: bold;
  font-size: var(--font-size-sm);
  display: block;
  margin-bottom: var(--gap-xs);
}

.catalog-card .card-stats {
  font-size: var(--font-size-sm);
  color: var(--text);
}

/* Pagination */
.page-nav,
.pagination {
  margin-top: var(--gap-md);
  text-align: center;
  font-size: var(--font-size-sm);
}

.page-nav a,
.pagination a {
  margin: 0 var(--gap-xs);
}

/* Empty state */
.empty-state {
  color: var(--text);
  font-size: var(--font-size-sm);
  padding: var(--gap-md) 0;
}

/* Thread archived notice */
.thread-archived {
  color: var(--text);
  font-size: var(--font-size-sm);
  font-style: italic;
  margin-top: var(--gap-md);
  padding: 0.75rem 1rem;
  margin-bottom: 1rem;
  font-weight: bold;
  text-align: center;
  border: 2px solid var(--color-accent);
}

/* Catalog no-image placeholder */
.catalog-no-image {
  height: 80px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--text);
  font-size: var(--font-size-sm);
}

/* Thread breadcrumb */
.thread-breadcrumb {
  font-size: var(--font-size-sm);
  margin-bottom: var(--gap-md);
  color: var(--text);
}

/* Board list on landing page */
.board-list {
  list-style: none;
  line-height: 1.8;
  margin: var(--gap-md) 0;
}

.welcome-blurb {
  margin-bottom: var(--gap-md);
  font-size: var(--font-size-base);
  line-height: var(--line-height);
}

.welcome-heading {
  font-size: var(--font-size-lg);
  color: var(--text);
  border-bottom: 1px solid var(--border);
  padding-bottom: var(--gap-sm);
  margin-bottom: var(--gap-md);
}

.board-nav-item {
  font-size: var(--font-size-base);
}

.nav-sep {
  color: var(--border);
  margin: 0 var(--gap-xs);
}

/* Lightbox overlay */
.lightbox-overlay {
  position: fixed; inset: 0;
  background: rgba(0,0,0,0.85);
  display: flex; align-items: center; justify-content: center;
  z-index: 9000; cursor: zoom-out;
}
.lightbox-overlay img {
  max-width: 95vw; max-height: 95vh;
  width: auto; height: auto;
  border: 2px solid var(--border); border-radius: var(--radius-sm);
  cursor: default; box-shadow: 0 4px 32px rgba(0,0,0,0.7);
}

/* Post highlight (quote scroll target) */
.post-highlight {
  background: var(--post-highlight, #fffacd) !important;
  transition: background var(--transition-speed, 0.3s) ease;
}

/* Quote hover preview tooltip */
.post-preview {
  position: fixed; z-index: 8000;
  background: var(--bg-post); border: 1px solid var(--border);
  border-radius: var(--radius-sm); padding: var(--gap-sm) var(--gap-md);
  max-width: 300px; max-height: 200px; overflow: hidden;
  font-size: var(--font-size-sm); pointer-events: none;
  box-shadow: 2px 2px 6px rgba(0, 0, 0, 0.2);

  /* Entry animation via @starting-style */
  opacity: 1;
  transform: translateY(0) scale(1);
  transition:
    opacity  120ms ease-out,
    transform 120ms var(--spring-snappy),
    display  120ms allow-discrete;

  @starting-style {
    opacity: 0;
    transform: translateY(-4px) scale(0.97);
  }
}

/* Hidden state */
.post-preview.is-hidden {
  display: none;
}

/* Form inputs */
.form-input,
.form-select,
.form-textarea {
  background: var(--bg);
  color: var(--text);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  padding: var(--gap-sm);
  font-size: var(--font-size-base);
  font-family: var(--font-main);
  width: 100%;
  box-sizing: border-box;
}

.form-input:focus,
.form-select:focus,
.form-textarea:focus {
  outline: 1px solid var(--link);
}

/* Global keyboard focus ring — WCAG 2.4.7 (Focus Visible, AA)
   Covers: .submit-btn, .upvote-btn, .watch-btn, .sort-btn, .btn-mod,
           .nav-btn-login, .nav-btn-register, .auth-btn, .new-thread-link,
           and all other interactive elements not already styled above. */
:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
}

.form-input.error {
  border-color: var(--color-error);
  outline: none;
}
.form-input.error:focus {
  box-shadow: 0 0 0 2px color-mix(in srgb, var(--color-error) 25%, transparent);
}

/* Deleted post placeholder */
.post-deleted .post-body {
  color: var(--text-dim);
  font-style: italic;
}

/* Unread notification highlight */
.notif-unread {
  background: var(--bg-highlight, #fffbe6);
  border-left: 3px solid var(--accent);
  transition: background var(--transition-speed, 0.3s) ease;
}

/* Skip-to-content link for keyboard users */
.skip-to-content {
  position: absolute;
  top: -100%;
  left: var(--gap-sm);
  z-index: 9999;
  background: var(--accent);
  color: #fff;
  padding: var(--gap-xs) var(--gap-md);
  border-radius: 0 0 var(--radius-sm) var(--radius-sm);
  text-decoration: none;
  font-weight: var(--font-weight-bold);
  transition: top var(--transition-fast);
}
.skip-to-content:focus {
  top: 0;
}

/* Visually hidden but accessible to screen readers */
.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;
}

/* Password strength meter */
.pw-strength-bar {
  height: 4px;
  border-radius: 2px;
  margin-top: 4px;
  transition: width var(--transition-fast, 0.15s), background var(--transition-fast, 0.15s);
  width: 0%;
  background: transparent;
}
.pw-strength-label {
  font-size: 11px;
  margin-top: 2px;
  min-height: 14px;
  color: var(--text);
  opacity: 0.7;
}

/* ─── Phase 1: Thread view upgrades ─────────────────────────────── */

/* OP post: gold-tinted gradient background + header bar */
.op-post {
  background: linear-gradient(135deg, var(--bg-post) 0%, color-mix(in srgb, var(--bg-post) 88%, var(--gold)) 100%);
  box-shadow: var(--shadow-card);
  position: relative;
  overflow: visible;
  /* flow-root contains the floated .post-image WITHOUT clipping the card
     shadow (2026-07-21: overflow:visible let the OP image spill out of the
     card and replies crowded up beside the float). */
  display: flow-root;
}

/* Reply posts: deeper card depth */
.reply-post {
  box-shadow: var(--shadow-card);
  transition:
    border-left-color  var(--transition-fast),
    box-shadow         var(--transition-fast),
    background-color   var(--transition-fast);
}

.reply-post:target,
.reply-post:hover {
  border-left-color: var(--gold-light);
  box-shadow: 0 1px 4px rgba(0, 0, 0, 0.05),
              0 0 0 1px rgba(200, 146, 58, 0.08);
  background-color: rgba(200, 146, 58, 0.02);
}

/* Compositor hint — only active during hover, prevents repaint jank on low-end hardware */
.reply-post:hover {
  will-change: box-shadow;
}

/* Thread title: serif upgrade */
.thread-title {
  font-family: Georgia, 'Times New Roman', serif;
  font-size: 1.08em;
  letter-spacing: 0.01em;
}

/* Post number: anchor badge */
.post-id-link {
  display: inline-flex;
  align-items: center;
  padding: 1px 5px;
  background: rgba(200,146,58,0.12);
  border-radius: 4px;
  color: var(--link);
  text-decoration: none;
  font-size: 0.88em;
  font-weight: 700;
  font-family: var(--font-mono);
  transition: background var(--transition-fast);
  min-height: 24px;
  min-width: 24px;
}
.post-id-link:hover {
  background: rgba(200,146,58,0.25);
}

/* Greentext: slightly larger, italic */
.gt {
  font-style: italic;
  font-size: 1.03em;
}

/* Sage checkbox redesign: pill button */
.sage-label {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 3px 10px;
  border: 1px solid var(--border);
  border-radius: 20px;
  cursor: pointer;
  font-size: var(--font-size-sm);
  transition: background var(--transition-fast), border-color var(--transition-fast);
  user-select: none;
}
.sage-label:hover { background: var(--bg-post); border-color: var(--accent); }
.sage-label input[type="checkbox"] { margin: 0; accent-color: var(--accent); }

/* Character counter */
.char-counter {
  font-size: var(--font-size-sm);
  color: var(--text-dim);
  text-align: right;
  margin-top: 2px;
  transition: color var(--transition-fast);
}
.char-counter.warn { color: #e07d00; opacity: 1; }
.char-counter.limit { color: var(--color-error); opacity: 1; }

/* Drag-and-drop upload zone */
.drop-zone {
  border: 2px dashed var(--border);
  border-radius: 6px;
  padding: var(--gap-sm) var(--gap-md);
  text-align: center;
  color: var(--text);
  opacity: 0.6;
  cursor: pointer;
  transition: border-color var(--transition-fast), opacity var(--transition-fast);
  position: relative;
}
.drop-zone.drag-over {
  border-color: var(--accent);
  opacity: 1;
  background: rgba(200,146,58,0.06);
}
.drop-zone input[type="file"] {
  position: absolute; inset: 0; opacity: 0; cursor: pointer; width: 100%; height: 100%;
}

/* Reply form is static in-flow (2026-07-21): it was position:sticky, which
   made sense when the form was a small inline-block card, but the form is
   now full-column-width — sticky would blanket the posts while scrolling. */

/* ─── Phase 1: Board index upgrades ─────────────────────────────── */

/* Thread preview: 3-line clamp */
.thread-preview-text {
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

/* Reply count pill badge */
.reply-badge {
  display: inline-flex;
  align-items: center;
  padding: 1px 8px;
  background: rgba(200,146,58,0.14);
  border: 1px solid rgba(200,146,58,0.25);
  border-radius: 20px;
  font-size: var(--font-size-sm);
  font-weight: 600;
  color: var(--accent);
}

/* Thumbnail hover zoom */
.thread-thumb {
  overflow: hidden;
  border-radius: 3px;
  flex-shrink: 0;
}
.thread-thumb img {
  display: block;
  transition: transform 0.25s ease;
}
.thread-thumb img:hover {
  transform: scale(1.08);
}

/* Humanized time */
.human-time {
  font-size: var(--font-size-sm);
  color: var(--text-dim);
}

/* ─── Phase 1: Catalog upgrades ─────────────────────────────── */

.catalog-card {
  position: relative;
  transition: transform var(--transition-fast) var(--spring-snappy),
              box-shadow var(--transition-fast) ease-out;
}
.catalog-card:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-md);
}

/* Hover overlay */
.catalog-card-overlay {
  position: absolute;
  inset: 0;
  background: rgba(26,37,53,0.82);
  color: #fff;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 6px;
  font-size: var(--font-size-sm);
  border-radius: inherit;
  opacity: 0;
  transition: opacity 0.2s ease;
  pointer-events: none;
}
.catalog-card:hover .catalog-card-overlay { opacity: 1; }
.catalog-card-overlay .overlay-replies { font-size: 1.2em; font-weight: 700; color: var(--gold-light, #e0a84a); }
.catalog-card-overlay .overlay-time { opacity: 0.75; }

/* ─── Phase 30: Thread Redesign ─────────────────────────────── */

/* THR-01 — OP post gradient header bar (::before pseudo) */
.op-post::before {
  content: "";
  display: block;
  height: 4px;
  background: linear-gradient(90deg, var(--gold) 0%, var(--navy) 100%);
  border-radius: var(--radius-sm) var(--radius-sm) 0 0;
  margin: calc(-1 * var(--gap-md)) calc(-1 * var(--gap-md)) var(--gap-sm) calc(-1 * var(--gap-md));
}

/* THR-02 — Reply post always-on gold left border + tinted background */
.reply-post {
  border-left: 3px solid var(--gold);
  background: color-mix(in srgb, var(--bg-post) 96%, var(--gold));
}

/* Phase 42: Saged post indicator */
.post-saged .post-id-link::after {
  content: " \2193";
  color: var(--text-dim);
  font-size: 0.75em;
}

/* Phase 42: Pinned thread */
.thread-pinned {
  background: var(--surface-sticky);
  border-top: 2px solid var(--gold);
  border-radius: var(--radius-sm);
  padding: var(--gap-sm) var(--gap-md);
}
.thread-pinned::before {
  content: "\1F4CC ";
  font-size: 0.75em;
}

/* THR-05 — Quote links: gold color, hover underline */
a.quote-link {
  color: var(--gold);
  text-decoration: none;
}
a.quote-link:hover {
  color: var(--gold-light);
  text-decoration: underline;
}

/* ── Board unlock: locked/coming-soon state ───────────────────── */
.board-card-locked {
  opacity: 0.65;
}

.board-card-locked .board-card-v2-header {
  background: var(--bg-alt);
}

.board-coming-soon {
  cursor: not-allowed;
  color: var(--text-muted);
  font-style: italic;
  user-select: none;
}

.board-lock-badge {
  display: inline-block;
  font-size: 0.7rem;
  padding: 0.1rem 0.4rem;
  border-radius: 3px;
  background: var(--bg-alt);
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.05em;
  margin-left: 0.4rem;
  vertical-align: middle;
}

/* ─── Mobile layout fixes (≤480px) ──────────────────────────────────────── */
@media (max-width: 480px) {
  .reply-form {
    display: block;
    width: 100%;
    min-width: 0;
    box-sizing: border-box;
  }
  .post-image,
  .thread-thumb {
    float: none;
    max-width: 100%;
    margin: 0 0 var(--gap-sm) 0;
  }
  .post-image img,
  .thread-thumb img {
    max-width: 100%;
    max-height: 200px;
    height: auto;
  }
  .reply-post {
    margin-left: var(--gap-md);
  }
  .search-form {
    flex-direction: column;
    align-items: stretch;
  }
}

/* ─── Phase 38: Toast notifications ─────────────────────────────────────── */
#toast-container {
  position: fixed;
  bottom: var(--gap-lg);
  right: var(--gap-md);
  z-index: 9999;
  display: flex;
  flex-direction: column;
  gap: var(--gap-xs);
  pointer-events: none;
}

.toast {
  background: var(--navy);
  color: var(--text-on-dark);
  padding: var(--gap-sm) var(--gap-md);
  border-radius: var(--radius-md);
  border-left: 4px solid var(--gold);
  font-size: var(--font-size-sm);
  opacity: 0;
  transform: translateY(12px);
  transition: opacity var(--transition-fast), transform var(--transition-fast);
  max-width: 320px;
  pointer-events: auto;
}
.toast.toast-show {
  opacity: 1;
  transform: translateY(0);
}
.toast.toast-success { border-left-color: #2a9d5c; }
.toast.toast-error   { border-left-color: var(--color-error); }
.toast.toast-warn    { border-left-color: #e07d00; }
.toast.toast-info    { border-left-color: var(--gold); }

/* ─── Phase 38: Empty state block ────────────────────────────────────────── */
.empty-state-block {
  text-align: center;
  padding: var(--gap-xl) var(--gap-lg);
  color: var(--text-dim);
}
.empty-state-block .empty-glyph {
  font-size: 2.5rem;
  margin-bottom: var(--gap-sm);
  display: block;
  opacity: 0.5;
}
.empty-state-block h3 {
  font-size: var(--font-size-lg);
  color: var(--text);
  margin-bottom: var(--gap-xs);
}
.empty-state-block p {
  font-size: var(--font-size-sm);
  margin-bottom: var(--gap-md);
}
.empty-state-block .empty-cta {
  display: inline-block;
  padding: var(--gap-xs) var(--gap-md);
  background: var(--gold-alpha);
  border: 1px solid var(--gold);
  border-radius: var(--radius-sm);
  color: var(--gold);
  text-decoration: none;
  font-size: var(--font-size-sm);
  transition: background var(--transition-fast);
}
.empty-state-block .empty-cta:hover {
  background: rgba(200,146,58,0.25);
}

/* ─── Phase 38: Enhanced error pages ─────────────────────────────────────── */
.error-page {
  text-align: center;
  padding: var(--gap-xl) var(--gap-lg);
  max-width: 500px;
  margin: 0 auto;
}
.error-code {
  font-size: 5rem;
  font-weight: 900;
  color: var(--gold);
  opacity: 0.35;
  line-height: 1;
  margin-bottom: var(--gap-sm);
  font-family: var(--font-display);
}
.error-nav {
  display: flex;
  gap: var(--gap-md);
  justify-content: center;
  flex-wrap: wrap;
  margin-top: var(--gap-lg);
}
.error-nav a {
  padding: var(--gap-xs) var(--gap-md);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  font-size: var(--font-size-sm);
}

/* ─── Phase 38: Honeypot field (visually hidden) ─────────────────────────── */
.form-extra-fields {
  position: absolute;
  left: -9999px;
  top: -9999px;
  width: 1px;
  height: 1px;
  overflow: hidden;
}

/* ─── Phase 33: Catalog Improvements ────────────────────────────────────── */
.catalog-controls {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: var(--gap-sm);
  margin-bottom: var(--gap-md);
  padding: var(--gap-sm) var(--gap-md);
  background: var(--bg-post);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
}
.catalog-sort {
  display: flex;
  align-items: center;
  gap: var(--gap-xs);
  flex-wrap: wrap;
}
.catalog-sort-label {
  font-size: var(--font-size-sm);
  color: var(--text-dim);
}
.sort-btn {
  font-size: var(--font-size-sm);
  padding: 2px 8px;
  border: 1px solid var(--border);
  border-radius: 4px;
  color: var(--link);
  text-decoration: none;
  background: transparent;
  cursor: pointer;
  transition: border-color var(--transition-fast), background var(--transition-fast);
}
.sort-btn:hover {
  border-color: var(--accent);
  background: var(--gold-alpha, rgba(200,146,58,0.12));
}
.sort-btn.sort-active {
  border-color: var(--accent);
  background: var(--gold-alpha, rgba(200,146,58,0.12));
  color: var(--text);
  font-weight: 600;
  cursor: default;
}
.catalog-filter-wrap {
  flex: 1 1 160px;
  min-width: 0;
}
.catalog-filter-input {
  width: 100%;
  padding: 3px 8px;
  font-size: var(--font-size-sm);
  border: 1px solid var(--border);
  border-radius: 4px;
  background: var(--bg-input, var(--bg-post));
  color: var(--text);
}
.catalog-card-preview {
  display: none;
  font-size: var(--font-size-sm);
  color: var(--text-dim);
  margin: 2px 0 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.catalog-grid.catalog-list-mode {
  grid-template-columns: 1fr;
}
.catalog-grid.catalog-list-mode .catalog-card {
  display: grid;
  grid-template-columns: 120px 1fr;
  text-align: left;
  gap: var(--gap-sm);
  align-items: start;
}
.catalog-grid.catalog-list-mode .catalog-card img {
  max-height: 100px;
  width: 100%;
  object-fit: cover;
}
.catalog-grid.catalog-list-mode .catalog-card-preview {
  display: block;
  white-space: normal;
}

/* Phase 42: Featured pricing card shadow + lift */
.pricing-card.featured {
  box-shadow: var(--shadow-glow);
  transform: translateY(-6px);
}

/* ─── Phase 47: Upvote button ────────────────────────────────────────── */
.post-footer {
  display: flex;
  gap: var(--gap-sm);
  align-items: center;
  margin-top: var(--gap-xs);
  padding-top: var(--gap-xs);
}
.upvote-btn {
  display: inline-flex;
  align-items: center;
  gap: 3px;
  padding: 2px 8px;
  background: transparent;
  border: 1px solid var(--border);
  border-radius: 20px;
  cursor: pointer;
  font-size: var(--font-size-sm);
  color: var(--text-dim);
  transition: border-color var(--transition-fast), color var(--transition-fast), background var(--transition-fast);
}
.upvote-btn:hover {
  border-color: var(--gold);
  color: var(--gold);
  background: var(--gold-alpha);
}
.upvote-btn.upvoted {
  border-color: var(--gold);
  color: var(--gold);
  background: var(--gold-alpha);
}


/* --- Phase 48: User flair ------------------------------------------------ */
.user-flair {
  font-size: var(--font-size-sm);
  opacity: 0.85;
  font-style: italic;
}

/* Phase 48: Inline markdown styles in post body */
.post-body strong {
  font-weight: 700;
  color: var(--text);
}

.post-body em {
  font-style: italic;
  /* color intentionally omitted — inherits post body color, avoids clash with .gt italic */
}

.post-body code {
  font-family: var(--font-mono);
  font-size: 0.88em;
  background: var(--bg-post);
  padding: 1px 5px;
  border-radius: 3px;
  border: 1px solid var(--border);
}

/* ─── Phase 50: Watch button ────────────────────────────────────────── */
.thread-actions {
  margin-bottom: var(--gap-sm);
  display: flex;
  gap: var(--gap-sm);
  align-items: center;
}
.watch-btn {
  padding: 3px 12px;
  border: 1px solid var(--border);
  border-radius: 20px;
  background: transparent;
  cursor: pointer;
  font-size: var(--font-size-sm);
  color: var(--text-dim);
  transition: border-color var(--transition-fast), color var(--transition-fast), background var(--transition-fast);
}
.watch-btn:hover,
.watch-btn.watching {
  border-color: var(--gold);
  color: var(--gold);
  background: var(--gold-alpha);
}

/* ─── Redesign: OP identity badge ───────────────────────────────────── */
.post-op-tag {
  display: inline-flex;
  align-items: center;
  padding: 1px 6px;
  background: var(--gold-alpha);
  border: 1px solid rgba(200,146,58,0.35);
  border-radius: 3px;
  font-size: 10px;
  font-weight: 700;
  color: var(--gold);
  text-transform: uppercase;
  letter-spacing: 0.08em;
  line-height: 1.4;
  vertical-align: middle;
  margin-left: 2px;
}

/* ─── User ID pill (post header) ────────────────────────────────────── */
.post-uid-pill {
  display: inline-block;
  font-family: monospace;
  font-size: 10px;
  font-weight: 600;
  padding: 1px 5px;
  border-radius: 3px;
  margin-left: 3px;
  vertical-align: middle;
  text-decoration: none;
  background: var(--post-bg);
  border: 1px solid var(--border);
  color: var(--text-dim);
  letter-spacing: 0.02em;
  transition: border-color 0.15s, color 0.15s;
}
.post-uid-pill:hover {
  color: var(--text-primary);
  border-color: var(--text-dim);
}
.post-uid-pill.uid-founder {
  background: rgba(200, 146, 58, 0.1);
  border-color: rgba(200, 146, 58, 0.45);
  color: var(--gold, #c8923a);
}
.post-uid-pill.uid-founder:hover {
  background: rgba(200, 146, 58, 0.18);
}

/* ─── Redesign: Pricing popular badge (left-aligned variant) ─────────── */
.pricing-popular-badge {
  position: absolute;
  top: -13px;
  left: 16px;
  background: linear-gradient(135deg, var(--gold) 0%, #d4a040 100%);
  color: #fff;
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  padding: 4px 14px;
  border-radius: 20px;
  white-space: nowrap;
  box-shadow: 0 2px 12px rgba(200,146,58,0.35);
}

/* ─── Redesign: Board card status badges ────────────────────────────── */
.badge-board-active {
  display: inline-flex;
  align-items: center;
  padding: 2px 8px;
  background: rgba(107,149,119,0.18);
  border: 1px solid rgba(107,149,119,0.40);
  border-radius: 20px;
  font-size: 10px;
  font-weight: 700;
  color: var(--color-success);
  text-transform: uppercase;
  letter-spacing: 0.06em;
}

.badge-board-locked {
  display: inline-flex;
  align-items: center;
  padding: 2px 8px;
  background: rgba(107,107,107,0.15);
  border: 1px solid rgba(107,107,107,0.30);
  border-radius: 20px;
  font-size: 10px;
  font-weight: 700;
  color: var(--text-dim);
  text-transform: uppercase;
  letter-spacing: 0.06em;
}

/* ─── Redesign: Board identity color accents ─────────────────────────── */
.board-card--b .board-card-v2-header          { border-bottom: 2px solid #c8923a; }
.board-card--astrology .board-card-v2-header  { border-bottom: 2px solid #7ab8d0; }
.board-card--charts .board-card-v2-header     { border-bottom: 2px solid #9b8fd0; }
.board-card--library .board-card-v2-header    { border-bottom: 2px solid #7ab857; }

/* ─── Redesign: Catalog pin star ─────────────────────────────────────── */
.catalog-pin-star {
  position: absolute;
  top: 6px;
  right: 6px;
  width: 20px;
  height: 20px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(200,146,58,0.85);
  border-radius: 50%;
  font-size: 10px;
  color: #fff;
  line-height: 1;
  z-index: 2;
  pointer-events: none;
}

/* ══ Forum Index — Full-Width Table Layout ══════════════════════════ */

/* Page wrapper — full width, no centering cap */
.fi-wrap {
  width: 100%;
  /* Cap + center so board rows don't stretch full-bleed into dead beige, and
     trim the top gap so the boards sit higher (2026-06-28 GPT review). */
  max-width: 1080px;
  margin: 0 auto;
  padding: 28px var(--gap-lg) var(--gap-xl);
  box-sizing: border-box;
}

/* Header */
.fi-header {
  margin-bottom: var(--gap-md);
  padding-bottom: var(--gap-md);
  border-bottom: 1px solid var(--navy-border);
}

.fi-title {
  font-family: var(--font-display);
  font-style: italic;
  font-size: 26px;
  /* /forum is a light (beige) page — was var(--text-on-dark) (#dde8f4),
     i.e. light-on-light = a near-invisible ghost H1. --text is theme-aware
     (navy on beige, flips in dark mode), restoring it as the loudest line. */
  color: var(--text);
  margin: 0 0 4px;
}

.fi-sub {
  font-size: var(--font-size-sm);
  color: var(--text-muted-dark);
  margin: 0;
}

/* ── Table shell ─────────────────────────────────────────────────── */
.fi-table {
  display: flex;
  flex-direction: column;
  width: 100%;
}

/* Column grid: board-info fills space, 3 fixed right columns */
.fi-thead,
.fi-row {
  display: grid;
  grid-template-columns: minmax(300px, 1fr) 90px 90px 240px;
  align-items: stretch;
}

/* Column header row */
.fi-thead {
  border-bottom: 2px solid var(--navy-border);
  margin-bottom: 3px;
}

.fi-th {
  padding: 6px 16px 8px;
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: rgba(221,232,244,0.30);
  font-family: var(--font-mono);
}

.fi-th--board { padding-left: 0; }

.fi-th--num {
  text-align: center;
  border-left: 1px solid rgba(255,255,255,0.04);
}

.fi-th--last {
  text-align: left;
  border-left: 1px solid rgba(255,255,255,0.04);
  padding-left: 18px;
}

/* ── Active board rows ────────────────────────────────────────────── */
.fi-row--active {
  background: var(--navy);
  border: 1px solid var(--navy-border);
  border-left: 3px solid var(--gold);
  border-radius: var(--radius-sm);
  margin-bottom: 2px;
  text-decoration: none;
  color: inherit;
  overflow: hidden;
  box-shadow: 0 1px 3px rgba(0,0,0,0.20);
  transition: background 150ms ease, box-shadow 200ms ease;
  min-height: 80px;
}

.fi-row--active:hover {
  background: #1d2d42;
  box-shadow: 0 3px 16px rgba(200,146,58,0.12), 0 1px 6px rgba(0,0,0,0.25);
}

.fi-row--active:focus-visible {
  outline: 2px solid var(--gold);
  outline-offset: 2px;
}

/* Board identity column */
.fi-board-col {
  padding: 14px 18px 14px 0;
  display: flex;
  flex-direction: column;
  gap: 5px;
  min-width: 0;
}

.fi-board-head {
  display: flex;
  align-items: baseline;
  gap: 9px;
  flex-wrap: wrap;
}

.fi-slug {
  font-family: var(--font-mono);
  font-size: 11px;
  color: var(--gold);
  letter-spacing: 0.05em;
  white-space: nowrap;
  flex-shrink: 0;
}

.fi-slug--dim { color: rgba(200,146,58,0.62); }

.fi-name {
  font-weight: 700;
  font-size: 15px;
  color: var(--text-on-dark);
  line-height: 1.2;
}

.fi-name--dim { color: rgba(221,232,244,0.58); }

.fi-desc {
  font-size: 12.5px;
  color: var(--text-muted-dark);
  line-height: 1.45;
  margin: 0;
}

.fi-desc--dim { color: rgba(170,190,210,0.55); }

/* Thread bullet previews inside board column */
.fi-bullets {
  list-style: none;
  margin: 4px 0 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 3px;
}

.fi-bullet {
  display: flex;
  align-items: baseline;
  gap: 5px;
  font-size: 12px;
  min-width: 0;
}

.fi-bullet-dot {
  color: var(--gold);
  font-size: 11px;
  flex-shrink: 0;
  opacity: 0.6;
}

.fi-bullet-title {
  color: rgba(221,232,244,0.60);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  flex: 1;
  transition: color 120ms ease;
}

.fi-row--active:hover .fi-bullet-title { color: rgba(221,232,244,0.85); }

.fi-bullet-replies {
  font-size: 10px;
  font-family: var(--font-mono);
  color: rgba(221,232,244,0.22);
  flex-shrink: 0;
}

/* Stat columns (threads + posts) */
.fi-stat-col {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 14px 8px;
  border-left: 1px solid rgba(255,255,255,0.04);
}

.fi-stat-num {
  font-family: var(--font-mono);
  font-size: 18px;
  font-weight: 600;
  color: rgba(221,232,244,0.65);
  line-height: 1;
  letter-spacing: -0.02em;
}

.fi-stat-num--dim { font-size: 14px; color: rgba(221,232,244,0.18); }

/* Last post column */
.fi-last-col {
  padding: 14px 16px 14px 18px;
  border-left: 1px solid rgba(255,255,255,0.04);
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 5px;
  min-width: 0;
}

.fi-last-title {
  font-size: 12.5px;
  color: rgba(221,232,244,0.65);
  line-height: 1.35;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  transition: color 120ms ease;
}

.fi-row--active:hover .fi-last-title { color: var(--text-on-dark); }

.fi-last-time {
  font-size: 11px;
  font-family: var(--font-mono);
  color: rgba(221,232,244,0.28);
}

.fi-last-empty {
  font-size: 12px;
  color: rgba(221,232,244,0.20);
  font-style: italic;
}

/* ── Section label (Coming Soon divider) ──────────────────────────── */
.fi-section-label {
  padding: var(--gap-md) 0 6px;
  display: flex;
  align-items: center;
  gap: 12px;
}

.fi-section-label span {
  font-size: 10px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  color: rgba(200,146,58,0.35);
  white-space: nowrap;
}

.fi-section-label::after {
  content: '';
  flex: 1;
  height: 1px;
  background: rgba(200,146,58,0.10);
}

/* ── Locked rows ──────────────────────────────────────────────────── */
/* Locked rows read as intentionally dormant, not accidentally broken
   (2026-06-28 critique: the old 0.45 bg + 0.55 opacity double-faded these
   to near-invisible on the beige page). More solid surface + a single,
   gentler opacity step keeps them clearly secondary but legible. */
.fi-row--locked {
  background: rgba(26,37,53,0.85);
  border: 1px solid rgba(37,59,82,0.55);
  border-left: 3px solid rgba(37,59,82,0.85);
  border-radius: var(--radius-sm);
  margin-bottom: 2px;
  opacity: 0.8;
  min-height: 60px;
}

.fi-lock-icon {
  font-size: 11px;
  color: rgba(221,232,244,0.25);
}

.fi-soon-badge {
  font-size: 9px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  padding: 3px 8px;
  border: 1px solid rgba(200,146,58,0.30);
  border-radius: 20px;
  color: rgba(200,146,58,0.60);
  white-space: nowrap;
}

/* Next-wave rows (General + Feedback lead the Coming Soon list): still locked
   and greyed, but visibly first in line — full opacity, gold left rule,
   brighter text, and an "Opening first" badge. */
.fi-row--next {
  opacity: 1;
  background: rgba(26,37,53,0.95);
  border-left-color: rgba(200,146,58,0.55);
}

.fi-row--next .fi-slug--dim { color: rgba(200,146,58,0.85); }
.fi-row--next .fi-name--dim { color: rgba(221,232,244,0.80); }
.fi-row--next .fi-desc--dim { color: rgba(170,190,210,0.70); }

.fi-soon-badge--next {
  border-color: rgba(200,146,58,0.55);
  color: rgba(200,146,58,0.95);
  background: rgba(200,146,58,0.08);
}

/* ── Mobile (≤ 720px): each board row becomes a stacked card ─────────
   The desktop 4-column grid does not survive a phone width. The previous
   approach kept a squeezed grid and tried to hide the Posts column with
   `.fi-stat-col:last-of-type` — but `:last-of-type` is TYPE-based and the
   last <div> in the row is `.fi-last-col`, so that selector matched nothing,
   Posts never hid, and a 3rd item wrapped into a 2-col grid (the "two
   floating zeros" from the 2026-06-28 critique). Replaced with an explicit
   grid-areas card: board on top, a labelled Threads/Posts footer below. */
@media (max-width: 720px) {
  .fi-wrap { padding: var(--gap-md); }

  .fi-thead { display: none; }

  .fi-row {
    grid-template-columns: 1fr 1fr;
    grid-template-areas:
      "board board"
      "thr   pst";
  }

  .fi-board-col {
    grid-area: board;
    padding: 14px 16px;
  }

  /* Stat columns → a labelled footer strip */
  .fi-row > .fi-stat-col:nth-of-type(2) { grid-area: thr; }
  .fi-row > .fi-stat-col:nth-of-type(3) {
    grid-area: pst;
    border-left: 1px solid rgba(255,255,255,0.06);
  }
  .fi-stat-col {
    flex-direction: row;
    align-items: baseline;
    justify-content: flex-start;
    gap: 7px;
    border-left: none;
    border-top: 1px solid rgba(255,255,255,0.06);
    padding: 9px 16px;
  }
  .fi-stat-col::before {
    font-family: var(--font-mono);
    font-size: 10px;
    font-weight: 700;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: rgba(221,232,244,0.38);
  }
  .fi-row > .fi-stat-col:nth-of-type(2)::before { content: "Threads"; }
  .fi-row > .fi-stat-col:nth-of-type(3)::before { content: "Posts"; }
  .fi-stat-num { font-size: 15px; }

  /* Last-post column hidden until there is real content worth a row */
  .fi-last-col { display: none; }

  /* Bullet previews are noise on a phone */
  .fi-bullets { display: none; }
}

/* ── Reduced motion ───────────────────────────────────────────────── */
@media (prefers-reduced-motion: reduce) {
  .fi-row--active,
  .fi-bullet-title,
  .fi-last-title { transition: none; }
}

/* ─── Forum Thread List (board_index.html redesign) ─────────────────────── */

/* Forum thread list container */
.forum-thread-list {
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  overflow: hidden;
  background: var(--bg-post);
  margin-bottom: var(--gap-md);
}

/* Column headers */
.ftl-header {
  display: grid;
  grid-template-columns: 1fr 76px 110px;
  padding: 6px var(--gap-md);
  background: var(--bg-alt);
  border-bottom: 2px solid var(--border);
  font-size: var(--font-size-xs);
  font-weight: var(--font-weight-bold);
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--text-dim);
}
.ftl-col-stats,
.ftl-col-activity {
  text-align: center;
  border-left: 1px solid var(--border);
}

/* Thread row */
.ftl-row {
  display: grid;
  grid-template-columns: 1fr 76px 110px;
  border-bottom: 1px solid var(--border);
  transition: background var(--transition-fast);
  min-height: 64px;
}
.ftl-row:last-child { border-bottom: none; }
.ftl-row:hover { background: color-mix(in srgb, var(--bg-post) 94%, var(--gold)); }

.ftl-row--pinned {
  background: var(--surface-sticky);
  border-left: 3px solid var(--gold);
}
.ftl-row--pinned:hover { background: color-mix(in srgb, var(--surface-sticky) 90%, var(--gold)); }

/* Row with thumbnail: extra column on left */
.ftl-row--has-thumb {
  grid-template-columns: 72px 1fr 76px 110px;
}

/* Thumbnail */
.ftl-thumb {
  padding: var(--gap-sm);
  display: flex;
  align-items: center;
  justify-content: center;
}
.ftl-thumb img {
  width: 56px;
  height: 56px;
  object-fit: cover;
  border-radius: var(--radius-sm);
  border: 1px solid var(--border);
}

/* Main content */
.ftl-main {
  padding: var(--gap-sm) var(--gap-md);
  min-width: 0;
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 4px;
}

/* Title row */
.ftl-title-row {
  display: flex;
  align-items: center;
  gap: var(--gap-xs);
}
.ftl-pin-icon {
  font-size: 11px;
  flex-shrink: 0;
  opacity: 0.7;
}
.ftl-title {
  font-family: var(--font-display);
  font-size: var(--font-size-base);
  font-weight: var(--font-weight-semibold);
  color: var(--text);
  text-decoration: none;
  line-height: 1.3;
  transition: color var(--transition-fast);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.ftl-title:hover { color: var(--gold); }

/* Meta row: author + tags */
.ftl-meta {
  display: flex;
  align-items: center;
  gap: var(--gap-xs);
  flex-wrap: wrap;
  font-size: var(--font-size-xs);
  color: var(--text-dim);
}
.ftl-author {
  color: var(--gold);
  font-weight: var(--font-weight-medium);
}

/* Preview text */
.ftl-preview {
  font-size: var(--font-size-sm);
  color: var(--text-dim);
  line-height: 1.4;
  margin: 0;
  overflow: hidden;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
}

/* Stats column */
.ftl-stats {
  padding: var(--gap-xs) var(--gap-sm);
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  border-left: 1px solid var(--border);
  gap: 2px;
}
.ftl-reply-count {
  font-family: var(--font-mono);
  font-size: var(--font-size-md);
  font-weight: var(--font-weight-bold);
  color: var(--text);
  line-height: 1;
}
.ftl-reply-label {
  font-size: var(--font-size-xs);
  color: var(--text-dim);
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

/* Activity column */
.ftl-activity {
  padding: var(--gap-xs) var(--gap-sm);
  display: flex;
  align-items: center;
  justify-content: center;
  border-left: 1px solid var(--border);
}
.ftl-time {
  font-size: var(--font-size-xs);
  color: var(--text-dim);
  text-align: center;
  font-family: var(--font-mono);
}

/* Empty state inside list */
.ftl-empty {
  grid-column: 1 / -1;
}

/* ─── Forum Pagination ───────────────────────────────────────────────────── */
.forum-pagination {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: var(--gap-sm);
  margin-top: var(--gap-md);
  padding: var(--gap-sm) 0;
}
.pg-btn {
  display: inline-flex;
  align-items: center;
  padding: 6px var(--gap-md);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  background: var(--bg-post);
  color: var(--link);
  font-size: var(--font-size-sm);
  text-decoration: none;
  transition: border-color var(--transition-fast), background var(--transition-fast), color var(--transition-fast);
}
.pg-btn:hover {
  border-color: var(--gold);
  background: var(--gold-alpha);
  color: var(--gold);
}
.pg-current {
  font-size: var(--font-size-sm);
  color: var(--text-dim);
  padding: 6px var(--gap-sm);
  border: 1px solid transparent;
}

/* ─── Mobile: collapse stats columns on small screens ───────────────────── */
@media (max-width: 600px) {
  .ftl-header { display: none; }
  .ftl-row,
  .ftl-row--has-thumb {
    grid-template-columns: 1fr;
    grid-template-rows: auto;
  }
  .ftl-row--has-thumb {
    grid-template-columns: 60px 1fr;
  }
  .ftl-stats,
  .ftl-activity {
    display: none;
  }
  .ftl-title {
    white-space: normal;
  }
}

/* ─── 2026-07-21: 4chan interaction suite (quote-click / backlinks / hover preview) ─── */

/* Backlink chips in the post header: "who replied to this post" */
.post-backlinks {
  margin-left: var(--gap-sm);
  font-size: var(--font-size-sm);
}
.post-backlinks a {
  color: var(--gold);
  text-decoration: none;
  margin-right: 6px;
}
.post-backlinks a:hover {
  color: var(--gold-light);
  text-decoration: underline;
}

/* Floating quoted-post preview (shown on quote-link / backlink hover) */
.post-hover-preview {
  position: fixed;
  z-index: 500;
  max-width: min(600px, 60vw);
  max-height: 50vh;
  overflow: hidden;
  pointer-events: none;
  box-shadow: 0 6px 24px rgba(0, 0, 0, 0.35);
  border-radius: var(--radius-sm);
}
.post-hover-preview .op-post,
.post-hover-preview .reply-post {
  margin: 0;
}
.post-hover-preview .post-image img {
  max-width: 160px;
  max-height: 160px;
}
