/* components.css — Facet gate overlays + reply preview
 * All Facets use CSS custom properties from styles.css.
 * Inline styles are only used in templates for dynamic values (gradient colours, avatars).
 */

/* ── Facet(nsfw_gate) ─────────────────────────────────────────────────────
 * Adult content gate — requires age verification to unlock.
 * Replaces the old inline-style NSFW block in feed_items.html.
 */
.nsfw-gate {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 6px;
  padding: 32px 20px;
  margin-top: 10px;
  border-radius: var(--r-lg);
  background: var(--panel);
  border: 1px solid var(--hairline);
  text-align: center;
}

.nsfw-gate-icon {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  border-radius: var(--radius-full);
  background: oklch(74% 0.15 75 / 0.12);
  color: var(--warn);
  margin-bottom: 2px;
}

.nsfw-gate-icon svg { width: 20px; height: 20px; }

.nsfw-gate-title {
  margin: 0;
  font-size: 14px;
  font-weight: 600;
  color: var(--ink);
}

.nsfw-gate-sub {
  margin: 0;
  font-size: 12px;
  color: var(--ink-3);
}

.nsfw-gate-unlock {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  margin-top: 6px;
  padding: 7px 18px;
  border-radius: var(--radius-full);
  background: var(--warn);
  color: #000;
  font-size: 12px;
  font-weight: 700;
  text-decoration: none;
  transition: opacity 0.15s;
}

.nsfw-gate-unlock:hover { opacity: 0.82; }

/* ── Facet(sensitive_gate) ───────────────────────────────────────────────
 * Sensitive / graphic content gate — user can reveal client-side via
 * revealSensitive(postId) without a page reload.
 */
.sensitive-gate {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 6px;
  padding: 28px 20px;
  margin-top: 10px;
  border-radius: var(--r-lg);
  background: var(--panel);
  border: 1px solid var(--hairline);
  text-align: center;
}

.sensitive-gate-icon {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 38px;
  height: 38px;
  border-radius: var(--radius-full);
  background: var(--panel-hover);
  color: var(--ink-3);
}

.sensitive-gate-icon svg { width: 18px; height: 18px; }

.sensitive-gate-title {
  margin: 0;
  font-size: 13px;
  font-weight: 600;
  color: var(--ink);
}

.sensitive-gate-sub {
  margin: 0;
  font-size: 12px;
  color: var(--ink-3);
}

.sensitive-gate-reveal {
  display: inline-flex;
  align-items: center;
  margin-top: 6px;
  padding: 5px 16px;
  border-radius: var(--radius-full);
  background: transparent;
  border: 1px solid var(--hairline-strong);
  color: var(--ink-2);
  font-size: 12px;
  font-weight: 500;
  cursor: pointer;
  transition: background 0.15s;
}

.sensitive-gate-reveal:hover { background: var(--panel-hover); }

/* ── Facet(subscriber_gate) ──────────────────────────────────────────────
 * Subscriber-only post paywall — soft fade mask with CTA to subscribe.
 */
.subscriber-gate {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 6px;
  padding: 32px 20px;
  margin-top: 10px;
  border-radius: var(--r-lg);
  background: var(--accent-soft);
  border: 1px solid var(--hairline);
  text-align: center;
}

.subscriber-gate-lock {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  border-radius: var(--radius-full);
  background: var(--accent-glow);
  color: var(--accent);
}

.subscriber-gate-lock svg { width: 18px; height: 18px; }

.subscriber-gate-title {
  margin: 0;
  font-size: 14px;
  font-weight: 600;
  color: var(--ink);
}

.subscriber-gate-sub {
  margin: 0;
  font-size: 12px;
  color: var(--ink-3);
}

.subscriber-gate-cta {
  display: inline-flex;
  align-items: center;
  margin-top: 6px;
  padding: 7px 18px;
  border-radius: var(--radius-full);
  background: var(--accent);
  color: var(--accent-ink);
  font-size: 13px;
  font-weight: 600;
  text-decoration: none;
  transition: opacity 0.15s;
}

.subscriber-gate-cta:hover { opacity: 0.85; }

/* ── Facet(reply_preview) ────────────────────────────────────────────────
 * Stacked avatar chips + reply count — shown below action bar when replies exist.
 */
.reply-preview {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-top: 10px;
  padding-top: 10px;
  border-top: 1px solid var(--hairline);
}

.reply-preview-avatars {
  display: flex;
  align-items: center;
}

.reply-preview-av {
  width: 20px;
  height: 20px;
  border-radius: 50%;
  border: 1.5px solid var(--bg-elev);
  overflow: hidden;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 7px;
  font-weight: 700;
  color: #fff;
  flex-shrink: 0;
  margin-left: -5px;
}

.reply-preview-av:first-child { margin-left: 0; }

.reply-preview-av img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.reply-preview-label {
  font-size: 12px;
  color: var(--ink-3);
  text-decoration: none;
}

a.reply-preview-label:hover { color: var(--ink); }
