:root {
  --bg: #000000;
  --panel: #0b0b0b;
  --text: #ededed;
  --muted: #8a8a8a;
  --dim: #565656;
  --line: rgba(255, 255, 255, 0.13);
  --line-soft: rgba(255, 255, 255, 0.07);
  --pill: #1b1b1b;
  --pill-hover: #292929;
  --blue: #6a86ff;
  --ai-surface: #5b4fe6;
  --ai-line: rgba(124, 118, 255, 0.4);
  color-scheme: dark;
}

/* Light theme - token overrides. Most of the UI is variable-driven, so
   flipping these repaints the whole site. Persisted via localStorage. */
html.light {
  --bg: #ffffff;
  --panel: #f4f4f5;
  --text: #17181c;
  --muted: #6b6e76;
  --dim: #9b9ea6;
  --line: rgba(0, 0, 0, 0.15);
  --line-soft: rgba(0, 0, 0, 0.07);
  --pill: #ededee;
  --pill-hover: #e2e2e4;
  --blue: #3b5bff;
  --ai-surface: #5b4fe6;
  --ai-line: rgba(91, 84, 214, 0.36);
  color-scheme: light;
}

* {
  box-sizing: border-box;
}
html,
body {
  margin: 0;
  padding: 0;
}
body {
  background: var(--bg);
  color: var(--text);
  font-family: "Inter", system-ui, -apple-system, sans-serif;
  font-size: 13.5px;
  line-height: 1.5;
  font-weight: 400;
  -webkit-font-smoothing: antialiased;
}
a {
  color: inherit;
  text-decoration: none;
}
img {
  display: block;
  max-width: 100%;
}

.container {
  width: 100%;
  padding-left: 22px;
  padding-right: 22px;
}

/* ---- Top bar ---- */
.topbar {
  position: sticky;
  top: 0;
  z-index: 40;
  display: flex;
  align-items: center;
  gap: 18px;
  height: 54px;
  padding: 0 22px;
  background: var(--bg);
}
.mark {
  font-size: 16px;
  letter-spacing: -2px;
  color: var(--text);
  flex-shrink: 0;
  user-select: none;
  display: inline-flex;
  align-items: center;
}
/* Brand mark - fixed greys, one version for both themes. */
.mn-mark {
  height: 22px;
  width: 22px;
  display: inline-block;
  vertical-align: middle;
}

/* Squared, persistent light/dark toggle (injected into the topbar). */
.theme-toggle {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 34px;
  height: 34px;
  flex-shrink: 0;
  padding: 0;
  border: 1px solid var(--line);
  border-radius: 0;
  background: transparent;
  color: var(--text);
  cursor: pointer;
  transition: background 0.15s ease, border-color 0.15s ease;
  -webkit-appearance: none;
  appearance: none;
}
.theme-toggle:hover {
  background: var(--pill);
  border-color: var(--pill-hover);
}
.theme-toggle svg {
  width: 17px;
  height: 17px;
  display: block;
}
.topbar-search {
  flex: 1;
  display: flex;
  position: relative;
}
.topbar-search input {
  width: 100%;
  max-width: 520px;
  background: transparent;
  border: none;
  outline: none;
  color: var(--text);
  font-family: inherit;
  font-size: 13.5px;
  padding: 6px 0;
}
.topbar-search input::placeholder {
  color: var(--muted);
}

/* ── Search assistant panel ─────────────────────────────────────────────── */
.search-pop {
  position: absolute;
  top: calc(100% + 10px);
  left: 0;
  width: min(560px, 92vw);
  z-index: 60;
  background: var(--panel);
  border: 1px solid var(--line);
  box-shadow: 0 24px 60px rgba(0, 0, 0, 0.55);
}
.search-pop[hidden] { display: none; }
.sp-op {
  display: flex;
  align-items: center;
  gap: 14px;
  width: 100%;
  padding: 11px 16px;
  background: none;
  border: none;
  border-bottom: 1px solid var(--line-soft);
  color: var(--text);
  font-family: inherit;
  font-size: 13px;
  text-align: left;
  cursor: pointer;
  transition: background 0.12s;
}
.sp-op:hover,
.sp-op:focus-visible {
  background: var(--pill);
  outline: none;
}
.sp-op-key {
  flex-shrink: 0;
  font-family: ui-monospace, "SFMono-Regular", Menlo, monospace;
  font-size: 12px;
  color: var(--text);
  background: var(--pill);
  border: 1px solid var(--line);
  padding: 2px 8px;
}
.sp-op:hover .sp-op-key { background: var(--pill-hover); }
.sp-op-desc {
  flex: 1;
  text-align: right;
  color: var(--muted);
}
.sp-op-tips .sp-op-key {
  letter-spacing: 2px;
  background: none;
  border-color: transparent;
  color: var(--muted);
}
.sp-foot {
  padding: 12px 16px 14px;
}
.sp-id {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-bottom: 12px;
  border-bottom: 1px solid var(--line-soft);
}
.sp-id-left {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 13px;
  color: var(--text);
}
.sp-avatar {
  display: inline-grid;
  place-items: center;
  width: 22px;
  height: 22px;
  font-size: 10.5px;
  font-weight: 600;
  color: var(--bg);
  background: var(--text);
}
.sp-close {
  background: none;
  border: none;
  color: var(--muted);
  font-size: 13.5px;
  cursor: pointer;
  padding: 2px 4px;
}
.sp-close:hover { color: var(--text); }
.sp-recent {
  display: flex;
  flex-direction: column;
  padding: 8px 0 4px;
}
.sp-recent-item {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 7px 6px;
  margin: 0 -6px;
  background: none;
  border: none;
  color: var(--text);
  font-family: inherit;
  font-size: 13px;
  text-align: left;
  cursor: pointer;
}
.sp-recent-item:hover { background: var(--pill); }
.sp-recent-ic { color: var(--dim); font-size: 11px; }
.sp-shortcuts {
  display: flex;
  align-items: center;
  gap: 8px;
  padding-top: 12px;
}
.sp-sc-label {
  font-size: 10.5px;
  letter-spacing: 1px;
  color: var(--dim);
  margin-right: 2px;
}
.sp-sc {
  background: var(--pill);
  border: none;
  color: var(--text);
  font-family: inherit;
  font-size: 12px;
  font-weight: 500;
  padding: 6px 10px;
  cursor: pointer;
}
.sp-sc:hover { background: var(--pill-hover); }

/* ── Search tips sheet ──────────────────────────────────────────────────── */
.search-tips {
  position: fixed;
  inset: 0;
  z-index: 90;
}
.search-tips[hidden] { display: none; }
.search-tips-overlay {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.6);
}
.search-tips-sheet {
  position: absolute;
  top: 0;
  left: 0;
  height: 100%;
  width: min(420px, 92vw);
  overflow-y: auto;
  background: var(--bg);
  border-right: 1px solid var(--line);
  padding: 22px 26px 60px;
}
.stips-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-bottom: 14px;
  margin-bottom: 6px;
  border-bottom: 1px solid var(--line);
}
.stips-title { color: var(--muted); font-size: 13.5px; }
.stips-close {
  width: 30px;
  height: 30px;
  background: none;
  border: 1px solid var(--blue);
  color: var(--text);
  cursor: pointer;
}
.stips-close:hover { background: var(--pill); }
.stips-body h3 {
  margin: 26px 0 10px;
  font-size: 13.5px;
  font-weight: 600;
  color: var(--text);
}
.stips-body ul {
  list-style: disc;
  margin: 0;
  padding-left: 20px;
}
.stips-body li {
  margin: 7px 0;
  font-size: 13px;
  line-height: 1.5;
  color: var(--text);
}
.stips-list {
  list-style: none;
  padding-left: 0;
}
.stips-list li {
  font-family: ui-monospace, "SFMono-Regular", Menlo, monospace;
  color: var(--muted);
}
.stips-body code,
.stips-body kbd {
  font-family: ui-monospace, "SFMono-Regular", Menlo, monospace;
  font-size: 11.5px;
  background: var(--pill);
  color: var(--text);
  padding: 2px 6px;
  white-space: nowrap;
}
.topbar-actions {
  display: flex;
  align-items: center;
  gap: 14px;
}
.pill {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  height: 32px;
  padding: 0 12px;
  background: var(--pill);
  border: none;
  color: var(--text);
  font-family: inherit;
  font-size: 13px;
  font-weight: 500;
  cursor: pointer;
  transition: background 0.15s;
}
.pill:hover {
  background: var(--pill-hover);
}
.count {
  color: var(--muted);
  font-size: 13px;
  font-variant-numeric: tabular-nums;
}

/* ---- Confirmation dialog ---- */
.confirm-overlay {
  position: fixed;
  inset: 0;
  z-index: 200;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px;
  background: rgba(0, 0, 0, 0.6);
}
.confirm-box {
  width: 100%;
  max-width: 400px;
  background: var(--panel);
  border: 1px solid var(--line);
  padding: 26px 26px 22px;
}
.confirm-title {
  margin: 0 0 8px;
  font-size: 16px;
  font-weight: 600;
  color: var(--text);
}
.confirm-body {
  margin: 0 0 22px;
  font-size: 13.5px;
  line-height: 1.55;
  color: var(--muted);
}
.confirm-actions {
  display: flex;
  justify-content: flex-end;
  gap: 10px;
}
.apply-btn.danger {
  background: #d64f4f;
  border-color: #d64f4f;
  color: #fff;
}
.apply-btn.danger:hover { background: #c34242; }

/* ---- Notifications ---- */
.notif { position: relative; display: inline-flex; }
.notif-trigger {
  cursor: pointer;
  min-width: 20px;
  height: 20px;
  padding: 0 5px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 10px;
  outline: none;
}
.notif-trigger.has-unread {
  color: var(--bg);
  background: var(--text);
  font-weight: 600;
}
.notif-menu {
  position: absolute;
  top: calc(100% + 10px);
  right: 0;
  width: 300px;
  max-height: 380px;
  overflow-y: auto;
  background: var(--panel);
  border: 1px solid var(--line);
  box-shadow: 0 12px 32px rgba(0, 0, 0, 0.35);
  z-index: 60;
}
.notif-empty {
  padding: 22px 16px;
  font-size: 13px;
  color: var(--muted);
  text-align: center;
}
.notif-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 11px 14px;
  border-bottom: 1px solid var(--line);
  font-size: 12px;
  font-weight: 600;
  color: var(--text);
}
.notif-clear {
  background: none;
  border: none;
  color: var(--muted);
  font: inherit;
  font-size: 12px;
  font-weight: 400;
  cursor: pointer;
  padding: 0;
}
.notif-clear:hover { color: var(--text); }
.notif-item {
  display: flex;
  flex-direction: column;
  gap: 3px;
  padding: 11px 14px;
  border-bottom: 1px solid var(--line);
  text-decoration: none;
  color: var(--text);
}
.notif-item:last-child { border-bottom: none; }
.notif-item:hover { background: var(--pill); }
.notif-item.unread { border-left: 2px solid var(--text); }
.notif-text { font-size: 13px; line-height: 1.4; }
.notif-time { font-size: 11px; color: var(--muted); }
.avatar {
  width: 26px;
  height: 26px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: var(--pill);
  color: var(--text);
  font-size: 12px;
  font-weight: 500;
}

/* ---- Breadcrumb ---- */
.breadcrumb {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 10px;
  padding: 88px 0 40px;
  font-size: 26px;
  font-weight: 500;
  letter-spacing: -0.015em;
  /* Stay above the Jobs/Help lock veil so section links remain clickable. */
  position: relative;
  z-index: 35;
}
.crumb {
  color: var(--muted);
  transition: color 0.15s;
}
.crumb:hover {
  color: var(--text);
}
.crumb.active {
  color: var(--text);
}
.crumb.root {
  color: var(--text);
}
.sep {
  color: var(--dim);
}

/* One-line description under the section header */
.page-intro {
  margin: -24px 0 40px;
  max-width: 620px;
  color: var(--muted);
  font-size: 13.5px;
  line-height: 1.5;
}

/* ---- View / Sort controls ---- */
.controls {
  display: flex;
  gap: 64px;
  flex-wrap: wrap;
  padding-bottom: 8px;
}
.control-col {
  min-width: 260px;
}
.control-label {
  font-size: 12px;
  color: var(--muted);
  padding-bottom: 9px;
  border-bottom: 1px solid var(--line);
  margin-bottom: 12px;
}
.radio-list {
  list-style: none;
  margin: 0;
  padding: 0;
}
.radio {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 4px 0;
  color: var(--muted);
  cursor: pointer;
  transition: color 0.12s;
  width: fit-content;
}
.radio:hover {
  color: var(--text);
}
.radio .dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--text);
  opacity: 0;
  flex-shrink: 0;
}
.radio.active {
  color: var(--text);
}
.radio.active .dot {
  opacity: 1;
}

/* Column-size slider */
.size-col {
  margin-left: auto;
  min-width: 200px;
}
.size-row {
  display: flex;
  align-items: center;
  gap: 12px;
}
.col-slider {
  -webkit-appearance: none;
  appearance: none;
  width: 160px;
  height: 1px;
  background: var(--line);
  cursor: pointer;
  outline: none;
}
.col-slider::-webkit-slider-thumb {
  -webkit-appearance: none;
  appearance: none;
  width: 12px;
  height: 12px;
  background: var(--text);
  border: none;
}
.col-slider::-moz-range-thumb {
  width: 12px;
  height: 12px;
  background: var(--text);
  border: none;
  border-radius: 0;
}
.size-val {
  color: var(--muted);
  font-size: 12px;
  font-variant-numeric: tabular-nums;
  min-width: 56px;
}

/* ---- Mosaic grid (masonry) ---- */
.grid {
  display: grid;
  grid-template-columns: repeat(var(--cols, 4), minmax(0, 1fr));
  grid-auto-rows: 1px;
  grid-auto-flow: row dense;
  column-gap: 18px;
  row-gap: 0;
  padding: 60px 0 120px;
}
.grid-empty {
  grid-column: 1 / -1;
  padding: 40px 0 120px;
  color: var(--muted);
  font-size: 13px;
}
.cell {
  cursor: pointer;
  grid-row-end: span 1;
}
.cell-media {
  overflow: hidden;
  position: relative;
}
.cell-img {
  position: absolute;
  inset: 0;
  transition: opacity 0.2s;
}
img.cell-img,
video.cell-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}
.cell:hover .cell-img {
  opacity: 0.9;
}
/* Member badge - marks community work vs. external reference. */
.cell-badge {
  position: absolute;
  top: 8px;
  left: 8px;
  z-index: 2;
  padding: 3px 8px;
  font-size: 10.5px;
  font-weight: 600;
  letter-spacing: 0.02em;
  color: #fff;
  background: color-mix(in srgb, var(--blue) 82%, #000 18%);
  border-radius: 999px;
  box-shadow: 0 1px 4px rgba(0, 0, 0, 0.35);
  pointer-events: none;
}
/* Reference tiles are links out to the source - reset anchor styling and
   flag the origin (Vimeo / X / Instagram) in the top-right corner. */
a.cell {
  text-decoration: none;
  color: inherit;
  display: block;
}
.cell-source {
  position: absolute;
  top: 8px;
  right: 8px;
  z-index: 2;
  padding: 3px 8px;
  font-size: 10.5px;
  font-weight: 500;
  letter-spacing: 0.02em;
  color: #f2f2f2;
  background: rgba(0, 0, 0, 0.55);
  border-radius: 999px;
  opacity: 0;
  transform: translateY(-2px);
  transition: opacity 0.14s, transform 0.14s;
  pointer-events: none;
}
.cell:hover .cell-source,
.cell:focus-visible .cell-source {
  opacity: 1;
  transform: none;
}
@media (hover: none) {
  .cell-source { opacity: 1; transform: none; }
}
/* Play marker over video posters (grid + profile). */
.cell-play,
.work-play {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  z-index: 2;
  width: 38px;
  height: 38px;
  display: grid;
  place-items: center;
  padding-left: 3px;
  font-size: 12px;
  color: #fff;
  background: rgba(0, 0, 0, 0.5);
  border: 1px solid rgba(255, 255, 255, 0.5);
  border-radius: 999px;
  pointer-events: none;
  backdrop-filter: blur(2px);
}
/* Quick-save bookmark on the tile - just the icon, no chip. Hidden until the
   tile is hovered; a saved tile keeps its (filled) bookmark showing. White
   icon with a soft shadow so it reads on any still; black in the light theme. */
.cell-fav {
  position: absolute;
  top: 8px;
  right: 8px;
  z-index: 3;
  display: grid;
  place-items: center;
  width: 22px;
  height: 22px;
  padding: 0;
  color: #fff;
  background: none;
  border: none;
  cursor: pointer;
  opacity: 0;
  filter: drop-shadow(0 1px 3px rgba(0, 0, 0, 0.6));
  transition: opacity 0.14s;
}
.cell-fav svg {
  width: 18px;
  height: 18px;
}
.cell-fav svg path {
  fill: currentColor;
}
.cell:hover .cell-fav,
.cell-fav:focus-visible,
.cell-fav.active {
  opacity: 1;
}
/* Light theme: black icon instead of white. */
html.light .cell-fav {
  color: #000;
  filter: drop-shadow(0 1px 3px rgba(255, 255, 255, 0.6));
}
@media (hover: none) {
  .cell-fav { opacity: 1; }
}
.cell-credit {
  color: var(--dim);
}
.cell-caption {
  margin-top: 11px;
  text-align: left;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.4;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

/* ---- Detail modal (Are.na style) ---- */
.modal {
  position: fixed;
  inset: 0;
  z-index: 100;
  background: var(--bg);
  display: flex;
}
.modal[hidden] {
  display: none;
}
.modal-stage {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 56px;
  min-width: 0;
}
.modal-media {
  position: relative;
  overflow: hidden;               /* clip any rounding the embed adds → square */
  border-radius: 0;
  background: #000;
  border: 1px solid var(--line);  /* hairline frame instead of a floaty shadow */
}
.modal-player {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  display: block;
  border: 0;
  border-radius: 0;
}

/* ── Custom player chrome ────────────────────────────────────────────── */
.mp-stage {
  position: absolute;
  inset: 0;
  z-index: 0;
  background: #000;
}
/* Full-bleed click surface: toggles play, holds the centre play glyph. */
.mp-surface {
  position: absolute;
  inset: 0;
  z-index: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  border: 0;
  padding: 0;
  margin: 0;
  background: transparent;
  cursor: pointer;
  -webkit-appearance: none;
  appearance: none;
}
.mp-center {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 76px;
  height: 76px;
  color: #fff;
  background: #000;
  border: 0;
  transition: opacity 0.18s ease, background 0.18s ease;
}
.mp-center svg { width: 30px; height: 30px; margin-left: 3px; }
.mp-surface:hover .mp-center {
  background: #141414;
}
/* Hide the centre glyph while playing; the bar takes over. */
.modal-media[data-state="playing"] .mp-center { opacity: 0; }

/* Bottom control bar - fades in on hover / focus / while paused. */
.mp-bar {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 2;
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px 14px;
  color: #fff;
  background: #000;
  opacity: 0;
  transition: opacity 0.2s ease;
  pointer-events: none;
}
.modal-media:hover .mp-bar,
.modal-media[data-state="paused"] .mp-bar,
.mp-bar:focus-within {
  opacity: 1;
  pointer-events: auto;
}
.mp-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 30px;
  height: 30px;
  flex-shrink: 0;
  padding: 0;
  border: 0;
  background: transparent;
  color: #fff;
  cursor: pointer;
  opacity: 0.86;
  transition: opacity 0.15s ease;
  -webkit-appearance: none;
  appearance: none;
}
.mp-btn:hover { opacity: 1; }
.mp-btn svg { width: 20px; height: 20px; }

/* Scrubber - thin square track, white fill, square knob. */
.mp-track {
  position: relative;
  flex: 1;
  height: 14px;
  display: flex;
  align-items: center;
  cursor: pointer;
  touch-action: none;
}
.mp-track::before {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  height: 3px;
  background: rgba(255, 255, 255, 0.22);
}
.mp-buffered,
.mp-played {
  position: absolute;
  left: 0;
  height: 3px;
}
.mp-buffered { background: rgba(255, 255, 255, 0.34); width: 0; }
.mp-played  { background: #fff; width: 0; }
.mp-knob {
  position: absolute;
  left: 0;
  width: 10px;
  height: 10px;
  background: #fff;
  transform: translateX(-50%);
  opacity: 0;
  transition: opacity 0.15s ease;
}
.mp-track:hover .mp-knob,
.mp-track:focus-visible .mp-knob { opacity: 1; }
.mp-track:focus-visible { outline: none; }

.mp-time {
  flex-shrink: 0;
  font-size: 11px;
  font-variant-numeric: tabular-nums;
  letter-spacing: 0.01em;
  color: rgba(255, 255, 255, 0.82);
  white-space: nowrap;
}
.mp-sep { margin: 0 4px; color: rgba(255, 255, 255, 0.4); }
.modal-side {
  width: 400px;
  flex-shrink: 0;
  border-left: 1px solid var(--line);
  padding: 72px 26px 30px;
  overflow-y: auto;
  display: flex;
  flex-direction: column;
}
.m-title {
  font-size: 18.5px;
  font-weight: 500;
  letter-spacing: -0.01em;
  margin: 0 0 14px;
  line-height: 1.25;
}
.m-desc {
  color: var(--muted);
  font-size: 13.5px;
  margin: 0 0 24px;
}
.meta {
  margin: 0 0 22px;
}
.meta-row {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  padding: 11px 0;
  border-top: 1px solid var(--line-soft);
  font-size: 13px;
}
.meta-row:last-child {
  border-bottom: 1px solid var(--line-soft);
}
.meta-row .k {
  color: var(--muted);
}
.meta-row .v {
  color: var(--text);
  text-align: right;
}
.m-actions {
  display: flex;
  gap: 10px;
  margin: 22px 0 26px;
}
.fav-btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  height: 34px;
  padding: 0 14px;
  background: var(--pill);
  border: 1px solid var(--line);
  color: var(--text);
  font-family: inherit;
  font-size: 13px;
  font-weight: 500;
  cursor: pointer;
  transition: background 0.15s, color 0.15s;
}
.fav-btn:hover {
  background: var(--pill-hover);
}
.fav-btn .bookmark {
  display: inline-grid;
  place-items: center;
  line-height: 0;
  color: var(--muted);
  transition: color 0.15s;
}
.fav-btn .bookmark svg {
  width: 15px;
  height: 15px;
  fill: currentColor;
}
.fav-btn.active {
  color: var(--text);
}
.fav-btn.active .bookmark {
  color: var(--text);
}
.tabs {
  display: flex;
  gap: 22px;
  border-bottom: 1px solid var(--line);
  margin-bottom: 18px;
}
.tab {
  background: none;
  border: none;
  color: var(--muted);
  font-family: inherit;
  font-size: 13px;
  cursor: pointer;
  padding: 0 0 12px;
  margin-bottom: -1px;
  display: inline-flex;
  align-items: center;
  gap: 8px;
}
.tab .badge {
  color: var(--dim);
  font-variant-numeric: tabular-nums;
}
.tab.active {
  color: var(--text);
  border-bottom: 1px solid var(--text);
}
.m-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin: 4px 0 22px;
}
.m-desc {
  color: var(--muted);
  font-size: 15.5px;
  line-height: 1.65;
  margin: 0 0 26px;
}
/* Comments */
.comment {
  display: flex;
  gap: 11px;
  padding: 14px 0;
  border-top: 1px solid var(--line-soft);
}
.comment-av {
  width: 26px;
  height: 26px;
  flex-shrink: 0;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: var(--pill);
  color: var(--text);
  font-size: 11px;
  font-weight: 500;
  overflow: hidden;
}
.comment-av img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}
.comment-body {
  min-width: 0;
}
.comment-head {
  display: flex;
  gap: 8px;
  align-items: baseline;
  margin-bottom: 3px;
}
.comment-name {
  color: var(--text);
  font-size: 13px;
  font-weight: 500;
}
.comment-time {
  color: var(--dim);
  font-size: 12px;
}
.comment-text {
  color: var(--muted);
  font-size: 13px;
  line-height: 1.55;
}
.comment-input {
  display: flex;
  gap: 10px;
  margin-top: 16px;
}
.comment-input input {
  flex: 1;
  background: transparent;
  border: none;
  border-bottom: 1px solid var(--line);
  color: var(--text);
  font-family: inherit;
  font-size: 13px;
  padding: 8px 0;
  outline: none;
}
.comment-input input::placeholder {
  color: var(--muted);
}
.tab-panel[hidden] {
  display: none;
}
.comment-empty {
  font-size: 12px;
  color: var(--muted);
  margin: 4px 0 0;
}
/* Takedown request - sits at the foot of the Feed detail panel. */
.m-takedown {
  /* Pinned to the very bottom of the panel, out of the way of the main
     actions so it can't be clicked by accident. */
  margin-top: auto;
  padding-top: 22px;
  border-top: 1px solid var(--line);
}
.takedown-note {
  font-size: 11px;
  line-height: 1.5;
  color: var(--muted);
  margin: 0 0 10px;
}
.takedown-btn {
  height: 34px;
  padding: 0 14px;
  font-family: inherit;
  font-size: 11px;
  font-weight: 500;
  color: var(--muted);
  background: transparent;
  border: 1px solid var(--line);
  cursor: pointer;
  transition: color 0.15s, border-color 0.15s;
}
.takedown-btn:hover {
  color: #ff6a6a;
  border-color: #ff6a6a;
}
.takedown-btn[hidden] {
  display: none;
}
.modal-nav {
  position: fixed;
  top: 22px;
  right: 22px;
  display: flex;
  gap: 8px;
  z-index: 101;
}
.icon-btn[hidden] {
  display: none;
}
.icon-btn {
  width: 32px;
  height: 32px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 1px solid var(--line);
  background: var(--bg);
  color: var(--text);
  cursor: pointer;
  font-size: 13.5px;
  transition: background 0.15s;
}
.icon-btn:hover {
  background: var(--pill);
}

/* ---- Jobs ---- */
.plain-select {
  position: relative;
}
.plain-select select {
  appearance: none;
  background: transparent;
  border: none;
  border-bottom: 1px solid var(--line);
  color: var(--text);
  font-family: inherit;
  font-size: 13.5px;
  padding: 6px 24px 8px 0;
  cursor: pointer;
  outline: none;
}
.plain-select::after {
  content: "";
  position: absolute;
  right: 4px;
  top: 8px;
  width: 6px;
  height: 6px;
  border-right: 1px solid var(--muted);
  border-bottom: 1px solid var(--muted);
  transform: rotate(45deg);
  pointer-events: none;
}
.jobs-bar {
  display: flex;
  gap: 40px;
  flex-wrap: wrap;
  align-items: flex-end;
  padding-bottom: 8px;
}
.jobs-note {
  margin: 44px 0 0;
  color: var(--muted);
  font-size: 12px;
  line-height: 1.6;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.jobs-count {
  color: var(--dim);
  font-size: 12px;
  padding: 22px 0 14px;
}
.job-list {
  border-top: 1px solid var(--line);
  padding-bottom: 120px;
}
.job-row {
  display: grid;
  grid-template-columns: minmax(0, 2.3fr) minmax(0, 1.3fr) auto;
  align-items: center;
  gap: 40px;
  padding: 22px 4px;
  border-bottom: 1px solid var(--line-soft);
  cursor: pointer;
  transition: background 0.14s, padding 0.18s;
}
.job-row:hover {
  background: rgba(255, 255, 255, 0.02);
  padding-left: 12px;
}
.job-main {
  min-width: 0;
}
.job-role-line {
  display: flex;
  align-items: center;
  gap: 12px;
  min-width: 0;
}
.job-role {
  margin: 0;
  font-size: 14.5px;
  font-weight: 500;
  letter-spacing: -0.01em;
  color: var(--text);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.job-sub {
  margin: 5px 0 0;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  color: var(--muted);
  font-size: 12px;
}
.job-sub .dotsep {
  color: var(--dim);
}
.job-tags {
  display: flex;
  gap: 6px;
  flex-wrap: wrap;
  justify-content: flex-start;
}
.tag {
  font-size: 12px;
  color: var(--muted);
  border: 1px solid var(--line);
  padding: 3px 9px;
}
.job-level {
  flex-shrink: 0;
  font-size: 10.5px;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  padding: 2px 7px;
  border: 1px solid var(--line);
  color: var(--muted);
}
.job-type {
  flex-shrink: 0;
  font-size: 10.5px;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  padding: 2px 7px;
}
.job-type.freelance {
  background: var(--text);
  color: var(--bg);
}
.job-type.fulltime {
  border: 1px solid var(--line);
  color: var(--text);
}
.job-pay {
  text-align: right;
  white-space: nowrap;
}
.job-pay-val {
  display: block;
  font-size: 14.5px;
  font-weight: 500;
  color: var(--text);
  font-variant-numeric: tabular-nums;
}
.job-pay-unit {
  color: var(--dim);
  font-size: 11px;
}
.jobs-empty {
  padding: 40px 4px;
  color: var(--muted);
}

/* ---- Job detail drawer ---- */
.drawer-overlay {
  position: fixed;
  inset: 0;
  z-index: 90;
  background: rgba(0, 0, 0, 0.55);
  animation: overlayIn 0.18s ease;
}
.drawer-overlay[hidden] {
  display: none;
}
.drawer {
  position: fixed;
  top: 0;
  right: 0;
  height: 100%;
  width: 50vw;
  min-width: 440px;
  max-width: 92vw;
  z-index: 100;
  background: var(--panel);
  border-left: 1px solid var(--line);
  display: flex;
  flex-direction: column;
  animation: drawerIn 0.22s cubic-bezier(0.22, 1, 0.36, 1);
}
.drawer[hidden] {
  display: none;
}
@keyframes overlayIn {
  from { opacity: 0; }
  to { opacity: 1; }
}
@keyframes drawerIn {
  from { transform: translateX(30px); opacity: 0.4; }
  to { transform: translateX(0); opacity: 1; }
}
.drawer-top {
  display: flex;
  justify-content: flex-end;
  padding: 16px 22px 0;
  flex-shrink: 0;
}
.drawer-body {
  padding: 8px 34px 48px;
  overflow-y: auto;
}
.drawer-badges {
  display: flex;
  align-items: center;
  gap: 8px;
}
.drawer-note {
  margin: 18px 0 0;
  padding: 13px 15px;
  border: 1px solid var(--line-soft);
  background: rgba(255, 255, 255, 0.02);
  color: var(--muted);
  font-size: 12.5px;
  line-height: 1.55;
}
.drawer-role {
  margin: 14px 0 6px;
  font-size: 23px;
  font-weight: 500;
  letter-spacing: -0.02em;
  line-height: 1.2;
}
.drawer-company {
  margin: 0 0 24px;
  color: var(--muted);
  font-size: 13.5px;
}
.drawer .m-tags {
  margin: 20px 0 4px;
}
.drawer-section {
  margin-top: 28px;
}
.drawer-section h2 {
  margin: 0 0 12px;
  font-size: 15px;
  font-weight: 500;
  color: var(--text);
}
.drawer-section p {
  margin: 0;
  color: var(--muted);
  font-size: 15px;
  line-height: 1.65;
}
.drawer-section p + p {
  margin-top: 15px;
}
.drawer-section ul {
  margin: 0;
  padding-left: 18px;
}
.drawer-section li {
  color: var(--muted);
  font-size: 15px;
  line-height: 1.7;
}
.apply-btn {
  margin-top: 34px;
  width: 100%;
  height: 46px;
  background: var(--text);
  color: var(--bg);
  border: none;
  font-family: inherit;
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
  transition: opacity 0.15s;
}
.apply-btn:hover {
  opacity: 0.88;
}
@media (max-width: 1150px) {
  .jobs-note {
    white-space: normal;
    overflow: visible;
    text-overflow: clip;
  }
}
@media (max-width: 560px) {
  .job-row {
    grid-template-columns: 1fr auto;
    gap: 16px 24px;
  }
  .job-tags {
    grid-column: 1 / -1;
  }
}

/* ---- Profile ---- */
.profile {
  display: grid;
  grid-template-columns: 280px 1fr;
  gap: 72px;
  align-items: start;
  padding: 24px 0 120px;
}
.profile-side {
  position: sticky;
  top: 78px;
}
.profile-pic {
  width: 148px;
  height: 148px;
  border: 1px solid var(--line);
  margin-bottom: 22px;
}
.profile-name {
  margin: 0 0 4px;
  font-size: 21px;
  font-weight: 500;
  letter-spacing: -0.015em;
}
.profile-handle {
  margin: 0 0 18px;
  color: var(--muted);
  font-size: 13px;
}
.profile-web {
  display: inline-block;
  color: var(--text);
  font-size: 13px;
  border-bottom: 1px solid var(--line);
  padding-bottom: 2px;
  margin-bottom: 30px;
}
.profile-web:hover {
  border-color: var(--text);
}
.profile-socials {
  display: flex;
  flex-direction: column;
  gap: 11px;
}
.profile-socials a {
  color: var(--muted);
  font-size: 13px;
  width: fit-content;
}
.profile-socials a:hover {
  color: var(--text);
}
.profile-block {
  margin-bottom: 46px;
}
.profile-block:last-child {
  margin-bottom: 0;
}
.reel-media {
  aspect-ratio: 16 / 9;
  background: linear-gradient(150deg, #243b36, #0a1210);
  display: flex;
  align-items: center;
  justify-content: center;
}
.reel-play {
  width: 62px;
  height: 62px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 1px solid rgba(255, 255, 255, 0.5);
  color: rgba(255, 255, 255, 0.85);
  font-size: 17.5px;
  padding-left: 3px;
}
.reel-caption {
  margin-top: 12px;
  color: var(--muted);
  font-size: 13px;
}
/* Showreel is a link out to the hosted reel */
.reel {
  display: block;
  text-decoration: none;
  color: inherit;
}
.reel:hover .reel-play {
  border-color: rgba(255, 255, 255, 0.85);
  color: #fff;
}

/* ── Edit profile drawer: socials + awards rows ── */
.edit-socials {
  display: flex;
  flex-direction: column;
  gap: 8px;
}
.edit-social-row {
  display: grid;
  grid-template-columns: 84px 1fr;
  align-items: center;
  gap: 10px;
}
.edit-social-label {
  font-size: 12px;
  color: var(--muted);
}
.edit-awards {
  display: flex;
  flex-direction: column;
  gap: 8px;
  margin-bottom: 10px;
}
.edit-award-row {
  display: grid;
  grid-template-columns: 1fr 84px 32px;
  gap: 8px;
  align-items: center;
}
.edit-award-del {
  height: 32px;
  border: 1px solid var(--line);
  background: var(--pill);
  color: var(--muted);
  cursor: pointer;
  font-size: 12px;
  line-height: 1;
}
.edit-award-del:hover {
  color: var(--text);
  background: var(--pill-hover);
}
.edit-add {
  align-self: flex-start;
}
.profile-label {
  margin: 0 0 14px;
  padding-bottom: 9px;
  border-bottom: 1px solid var(--line);
  font-size: 13.5px;
  font-weight: 500;
  color: var(--text);
}
.profile-desc {
  margin: 0;
  max-width: 660px;
  color: var(--muted);
  font-size: 13.5px;
  line-height: 1.7;
  /* Honour the line breaks people type into their About. */
  white-space: pre-line;
}
.award-list {
  list-style: none;
  margin: 0;
  padding: 0;
}
.award {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  padding: 13px 0;
  border-top: 1px solid var(--line-soft);
  font-size: 13.5px;
}
.award:last-child {
  border-bottom: 1px solid var(--line-soft);
}
.award-name {
  color: var(--text);
}
.award-year {
  color: var(--dim);
  font-variant-numeric: tabular-nums;
}
@media (max-width: 820px) {
  .profile {
    grid-template-columns: 1fr;
    gap: 44px;
  }
  .profile-side {
    position: static;
  }
}

/* ---- Footer ---- */
.site-footer {
  border-top: 1px solid var(--line-soft);
  padding: 26px 0 34px;
}
.footer-inner {
  display: flex;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 16px;
  color: var(--dim);
  font-size: 12px;
}
.footer-inner a {
  color: var(--muted);
}
.footer-inner a:hover {
  color: var(--text);
}
.footer-links {
  display: flex;
  gap: 20px;
  flex-wrap: wrap;
}

@media (max-width: 720px) {
  .breadcrumb {
    font-size: 21px;
  }
  .modal {
    flex-direction: column;
  }
  .modal-stage {
    padding: 60px 20px 20px;
  }
  .modal-media {
    width: 78%;
  }
  .modal-side {
    width: 100%;
    border-left: none;
    border-top: 1px solid var(--line);
  }
  .job-row {
    grid-template-columns: 1fr auto;
    gap: 12px;
  }
  .job-tags,
  .job-facts {
    grid-column: 1 / -1;
  }
  .job-arrow {
    display: none;
  }
}

/* ═══════════════════════════════════════════════════════════════════
   HELP FORUM
   ═══════════════════════════════════════════════════════════════════ */

/* ---- AI assistant ---- */
.assistant {
  margin-top: 26px;
  border: none;
  background: transparent;
}
/* Collapse the log until there's a conversation so the box is just the input. */
.assistant-log:empty {
  display: none;
}
.assistant-head {
  padding: 20px 22px 16px;
  border-bottom: 1px solid var(--line-soft);
}
.assistant-title {
  display: flex;
  align-items: center;
  gap: 9px;
  font-size: 14.5px;
  font-weight: 500;
  color: var(--text);
}
.assistant-mark {
  color: var(--text);
  font-size: 13px;
}
.assistant-sub {
  display: block;
  margin-top: 6px;
  color: var(--muted);
  font-size: 12px;
  line-height: 1.55;
  max-width: 620px;
}
.assistant-log {
  padding: 20px 22px;
  display: flex;
  flex-direction: column;
  gap: 16px;
  max-height: 340px;
  overflow-y: auto;
}
.ai-msg {
  display: flex;
  gap: 11px;
  max-width: 100%;
}
.ai-msg.user {
  justify-content: flex-end;
}
.ai-avatar {
  flex-shrink: 0;
  width: 24px;
  height: 24px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 1px solid var(--line);
  font-size: 11px;
  color: var(--text);
}
.ai-bubble {
  font-size: 13px;
  line-height: 1.6;
  color: var(--text);
  max-width: 76%;
}
.ai-msg.ai .ai-bubble {
  color: var(--muted);
}
.ai-msg.user .ai-bubble {
  background: var(--pill);
  color: var(--text);
  padding: 9px 13px;
}
.ai-chip {
  font: inherit;
  font-size: 12px;
  color: var(--text);
  background: none;
  border: none;
  border-bottom: 1px solid var(--line);
  padding: 0 0 1px;
  cursor: pointer;
}
.ai-chip:hover {
  border-color: var(--text);
}
.ai-sources {
  margin-top: 12px;
  display: flex;
  flex-direction: column;
  gap: 6px;
}
.ai-sources-label {
  font-size: 10.5px;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  color: var(--dim);
}
.ai-source {
  text-align: left;
  font: inherit;
  font-size: 12px;
  color: var(--text);
  background: none;
  border: 1px solid var(--line-soft);
  padding: 7px 10px;
  cursor: pointer;
}
.ai-source:hover {
  border-color: var(--line);
  background: rgba(255, 255, 255, 0.02);
}
.ai-typing {
  display: inline-flex;
  gap: 4px;
  padding: 4px 0;
}
.ai-typing i {
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: var(--dim);
  animation: aiBlink 1s infinite ease-in-out;
}
.ai-typing i:nth-child(2) { animation-delay: 0.15s; }
.ai-typing i:nth-child(3) { animation-delay: 0.3s; }
@keyframes aiBlink {
  0%, 80%, 100% { opacity: 0.25; }
  40% { opacity: 1; }
}
.assistant-input {
  display: flex;
  gap: 10px;
  align-items: center;
  padding: 34px 22px;
  /* Fill at 20% opacity, stroke stays fully opaque. */
  background: color-mix(in srgb, var(--ai-surface) 20%, transparent);
  border: 1px solid var(--ai-surface);
}
.assistant-input input {
  flex: 1;
  background: transparent;
  border: none;
  color: #fff;
  font: inherit;
  font-size: 13.5px;
  padding: 4px 0;
  outline: none;
}
.assistant-input input::placeholder {
  color: rgba(255, 255, 255, 0.72);
}
.ai-send {
  font: inherit;
  font-size: 13px;
  font-weight: 500;
  color: var(--bg);
  background: var(--text);
  border: none;
  padding: 0 20px;
  cursor: pointer;
}
.ai-send:hover {
  opacity: 0.86;
}

/* ---- Forum controls ---- */
.forum-search {
  margin-top: 40px;
}
.forum-controls {
  margin-top: 26px;
}
.forum-search input {
  width: 100%;
  background: var(--panel);
  border: 1px solid var(--line);
  color: var(--text);
  font: inherit;
  font-size: 13px;
  padding: 10px 13px;
  outline: none;
}
.forum-search input:focus {
  border-color: rgba(255, 255, 255, 0.28);
}
.seg {
  display: inline-flex;
  list-style: none;
  margin: 0;
  padding: 0;
  border: 1px solid var(--line);
}
.seg-item {
  padding: 8px 14px;
  font-size: 12px;
  color: var(--muted);
  cursor: pointer;
  border-right: 1px solid var(--line);
}
.seg-item:last-child {
  border-right: none;
}
.seg-item:hover {
  color: var(--text);
}
.seg-item.active {
  background: var(--text);
  color: var(--bg);
}
.forum-count {
  padding: 20px 0 6px;
  color: var(--dim);
  font-size: 12px;
}

/* ---- Thread list ---- */
.thread-list {
  display: flex;
  flex-direction: column;
}
.thread-row {
  display: grid;
  grid-template-columns: 54px minmax(0, 1fr) 58px;
  gap: 18px;
  align-items: start;
  padding: 20px 4px;
  border-top: 1px solid var(--line-soft);
  cursor: pointer;
}
.thread-row:hover {
  background: rgba(255, 255, 255, 0.015);
}
.thread-stat {
  display: flex;
  flex-direction: column;
  align-items: center;
  padding-top: 2px;
  color: var(--muted);
}
.thread-row.is-solved .thread-stat {
  color: #4ade80;
}
.stat-num {
  font-size: 15.5px;
  font-weight: 500;
  font-variant-numeric: tabular-nums;
}
.stat-label {
  font-size: 10.5px;
  color: var(--dim);
}
.thread-title-line {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}
.thread-title {
  margin: 0;
  font-size: 14.5px;
  font-weight: 500;
  color: var(--text);
  letter-spacing: -0.01em;
}
.thread-snip {
  margin: 6px 0 10px;
  color: var(--muted);
  font-size: 12.5px;
  line-height: 1.5;
}
.thread-meta {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
}
.thread-tags {
  display: flex;
  gap: 6px;
  flex-wrap: wrap;
  align-items: center;
}
.prog-chip {
  font-size: 11px;
  color: var(--text);
  background: var(--pill);
  border: 1px solid var(--line);
  padding: 3px 9px;
  white-space: nowrap;
}
.cat-chip {
  font-size: 11px;
  color: #b9a5ff;
  border: 1px solid rgba(185, 165, 255, 0.35);
  padding: 3px 9px;
  white-space: nowrap;
}
.thread-by {
  color: var(--dim);
  font-size: 11.5px;
  white-space: nowrap;
}
.thread-votes {
  text-align: center;
  color: var(--muted);
  padding-top: 2px;
}
.vote-num {
  display: block;
  font-size: 13.5px;
  font-weight: 500;
  font-variant-numeric: tabular-nums;
}
.vote-label {
  font-size: 10.5px;
  color: var(--dim);
}

/* ---- Status/pills ---- */
.pill-solved,
.pill-open,
.pill-code,
.pill-file {
  flex-shrink: 0;
  font-size: 10.5px;
  letter-spacing: 0.03em;
  padding: 2px 7px;
  border: 1px solid var(--line);
  color: var(--muted);
}
.pill-solved {
  color: #4ade80;
  border-color: rgba(74, 222, 128, 0.4);
}
.pill-solved.big {
  display: inline-block;
  font-size: 11px;
  padding: 3px 10px;
  margin-bottom: 14px;
}
.pill-open {
  display: inline-block;
  margin-bottom: 14px;
  font-size: 11px;
  padding: 3px 10px;
  color: var(--muted);
}
.pill-code {
  font-family: "JetBrains Mono", monospace;
  letter-spacing: 0;
}

/* ---- Thread detail (in drawer) ---- */
.drawer.wide {
  width: 60vw;
  min-width: 520px;
}
.thread-detail-title {
  margin: 0 0 12px;
  font-size: 19.5px;
  font-weight: 500;
  line-height: 1.28;
  letter-spacing: -0.015em;
}
.thread-detail-meta {
  display: flex;
  align-items: center;
  gap: 8px;
  color: var(--muted);
  font-size: 12px;
}
.avatar.sm {
  width: 22px;
  height: 22px;
  font-size: 10.5px;
}
.question-block {
  margin: 22px 0 32px;
  padding-bottom: 28px;
  border-bottom: 1px solid var(--line);
}
.question-text {
  margin: 0 0 14px;
  color: var(--text);
  font-size: 13.5px;
  line-height: 1.68;
}
.answers-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 6px;
}
.answers-head h2 {
  margin: 0;
  font-size: 13.5px;
  font-weight: 500;
  color: var(--text);
}
.answers-hint {
  color: var(--dim);
  font-size: 11.5px;
}
.answers-list {
  display: flex;
  flex-direction: column;
}
.answer {
  display: grid;
  grid-template-columns: 40px minmax(0, 1fr);
  gap: 14px;
  padding: 20px 0;
  border-top: 1px solid var(--line-soft);
}
.answer.accepted {
  border-left: 2px solid #4ade80;
  padding-left: 16px;
  margin-left: -18px;
  background: rgba(74, 222, 128, 0.03);
}
.answer-gutter {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
  color: var(--muted);
}
.vote-btn {
  background: none;
  border: 1px solid var(--line);
  color: var(--muted);
  width: 30px;
  height: 26px;
  font-size: 10.5px;
  cursor: pointer;
}
.vote-btn:hover {
  color: var(--text);
  border-color: var(--text);
}
.answer-votes {
  font-size: 13px;
  font-weight: 500;
  font-variant-numeric: tabular-nums;
}
.accept-mark {
  color: #4ade80;
  font-size: 13.5px;
}
.answer-head {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 9px;
}
.answer-author {
  font-size: 12.5px;
  color: var(--text);
  font-weight: 500;
}
.answer-time {
  font-size: 11px;
  color: var(--dim);
}
.accepted-tag {
  margin-left: auto;
  font-size: 10.5px;
  color: #4ade80;
  border: 1px solid rgba(74, 222, 128, 0.4);
  padding: 1px 7px;
}
.answer-text {
  margin: 0 0 12px;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.65;
}
.mark-btn {
  font: inherit;
  font-size: 12px;
  color: var(--muted);
  background: none;
  border: 1px solid var(--line);
  padding: 6px 12px;
  cursor: pointer;
}
.mark-btn:hover {
  color: #4ade80;
  border-color: rgba(74, 222, 128, 0.5);
}
.no-answers {
  color: var(--dim);
  font-size: 13px;
  padding: 18px 0;
}
.answer-form {
  display: flex;
  flex-direction: column;
  gap: 10px;
  margin-top: 26px;
  padding-top: 24px;
  border-top: 1px solid var(--line);
}
.answer-form .field-label {
  margin-bottom: 2px;
}

/* ---- Code blocks & inputs ---- */
.code-block {
  margin: 0 0 14px;
  padding: 14px 16px;
  background: #060606;
  border: 1px solid var(--line);
  overflow-x: auto;
}
.code-block code {
  font-family: "JetBrains Mono", monospace;
  font-size: 12px;
  line-height: 1.6;
  color: #f2d66f; /* expressions in yellow to set them apart */
  white-space: pre;
}
.code-input {
  font-family: "JetBrains Mono", monospace !important;
  font-size: 12px !important;
  background: #060606 !important;
  color: #f2d66f !important; /* expressions in yellow */
}
.code-input::placeholder {
  color: #6b6231 !important;
}

/* ---- File chip / dropzone ---- */
.file-chip {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  padding: 9px 13px;
  border: 1px solid var(--line);
  margin-bottom: 14px;
}
.file-chip-ic {
  color: var(--muted);
}
.file-chip-name {
  font-size: 12px;
  color: var(--text);
}
.file-chip-size {
  font-size: 11px;
  color: var(--dim);
}
.file-drop {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 18px 16px;
  border: 1px dashed var(--line);
  cursor: pointer;
  color: var(--muted);
}
.file-drop:hover,
.file-drop.drag {
  border-color: rgba(255, 255, 255, 0.35);
  color: var(--text);
}
.file-drop.has-file {
  border-style: solid;
  color: var(--text);
}
.file-drop-icon {
  font-size: 16px;
}
.file-drop-text {
  font-size: 12.5px;
}

/* ---- Compose form ---- */
.drawer-eyebrow {
  font-size: 10.5px;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  color: var(--dim);
}
#composeDrawer .drawer-top {
  justify-content: space-between;
  align-items: center;
}
.compose {
  display: flex;
  flex-direction: column;
  gap: 22px;
}
.compose[hidden] {
  display: none;
}
.field {
  display: flex;
  flex-direction: column;
  gap: 8px;
}
.field-label {
  font-size: 12.5px;
  font-weight: 500;
  color: var(--text);
}
.field-hint {
  font-weight: 400;
  color: var(--dim);
  font-size: 11px;
}
.field input,
.field textarea,
.answer-form textarea {
  width: 100%;
  background: var(--panel);
  border: 1px solid var(--line);
  color: var(--text);
  font: inherit;
  font-size: 13px;
  padding: 11px 13px;
  outline: none;
  resize: vertical;
}
.field input:focus,
.field textarea:focus,
.answer-form textarea:focus {
  border-color: rgba(255, 255, 255, 0.28);
}
.compose-actions {
  display: flex;
  justify-content: flex-end;
  gap: 12px;
  margin-top: 4px;
}
.ghost-btn {
  font: inherit;
  font-size: 13px;
  color: var(--muted);
  background: none;
  border: 1px solid var(--line);
  padding: 11px 20px;
  cursor: pointer;
}
.ghost-btn:hover {
  color: var(--text);
  border-color: var(--text);
}
.compose-post {
  width: auto;
}

@media (max-width: 820px) {
  .drawer.wide {
    width: 100vw;
    min-width: 0;
    max-width: 100vw;
  }
  .thread-row {
    grid-template-columns: 44px minmax(0, 1fr);
  }
  .thread-votes {
    display: none;
  }
  .ai-bubble {
    max-width: 100%;
  }
}

/* ═══════════════════════════════════════════════════════════════════
   ACCOUNT DROPDOWN
   ═══════════════════════════════════════════════════════════════════ */
.account {
  position: relative;
}
.account-trigger {
  cursor: pointer;
}
.avatar.lg {
  width: 34px;
  height: 34px;
  font-size: 13px;
}
.account-menu {
  position: absolute;
  top: calc(100% + 10px);
  right: 0;
  width: 244px;
  z-index: 200;
  background: var(--panel);
  border: 1px solid var(--line);
  padding: 6px 0;
  box-shadow: 0 14px 44px rgba(0, 0, 0, 0.55);
  animation: menuIn 0.14s ease;
}
.account-menu[hidden] {
  display: none;
}
@keyframes menuIn {
  from { opacity: 0; transform: translateY(-5px); }
  to { opacity: 1; transform: translateY(0); }
}
.account-head {
  display: flex;
  align-items: center;
  gap: 11px;
  padding: 12px 16px 14px;
  margin-bottom: 6px;
  border-bottom: 1px solid var(--line-soft);
}
.account-head:hover .account-sub {
  color: var(--text);
}
.account-id {
  display: flex;
  flex-direction: column;
  gap: 1px;
}
.account-name {
  font-size: 13px;
  font-weight: 500;
  color: var(--text);
}
.account-sub {
  font-size: 11.5px;
  color: var(--muted);
}
.account-group {
  padding: 5px 0;
  border-bottom: 1px solid var(--line-soft);
}
.account-group:last-child {
  border-bottom: none;
}
.account-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 8px 16px;
  font-size: 12.5px;
  color: var(--text);
}
.account-item:hover {
  background: var(--pill);
}
.theme-ic {
  width: 14px;
  height: 14px;
  color: var(--muted);
  flex-shrink: 0;
}
.account-item:hover .theme-ic {
  color: var(--text);
}
.account-item.accent {
  color: #b9a5ff;
}
.account-arrow {
  color: var(--dim);
  font-size: 13.5px;
}
.account-back {
  display: flex;
  align-items: center;
  gap: 8px;
  width: 100%;
  text-align: left;
  padding: 11px 16px 13px;
  margin-bottom: 6px;
  background: none;
  border: none;
  border-bottom: 1px solid var(--line-soft);
  font: inherit;
  font-size: 13px;
  font-weight: 500;
  color: var(--text);
  cursor: pointer;
}
.account-back:hover {
  background: var(--pill);
}
.account-arrow.back {
  font-size: 15.5px;
  color: var(--muted);
}
.account-check {
  color: #b9a5ff;
  font-size: 12px;
}

/* ═══════════════════════════════════════════════════════════════════
   SETTINGS PAGE
   ═══════════════════════════════════════════════════════════════════ */
.settings {
  max-width: 640px;
  padding-bottom: 90px;
}
.settings-section {
  padding: 30px 0;
  border-bottom: 1px solid var(--line-soft);
}
.settings-section:last-child {
  border-bottom: none;
}
.settings-h {
  margin: 0 0 4px;
  font-size: 13.5px;
  font-weight: 600;
  color: var(--text);
}
.settings-desc {
  margin: 0 0 20px;
  font-size: 12px;
  color: var(--muted);
  line-height: 1.5;
}
.settings-form {
  display: flex;
  flex-direction: column;
  gap: 16px;
}
.settings-actions {
  display: flex;
  align-items: center;
  gap: 14px;
}
.apply-btn.compact {
  margin-top: 0;
  width: auto;
  padding: 0 24px;
}
.settings-saved {
  font-size: 11.5px;
  color: #74c98a;
}
.settings-saved.err {
  color: #e0965a;
}
.settings-radios .radio {
  padding: 7px 0;
}
.danger-btn {
  font: inherit;
  font-size: 13px;
  font-weight: 500;
  color: #e0965a;
  background: none;
  border: 1px solid rgba(224, 150, 90, 0.4);
  padding: 11px 22px;
  cursor: pointer;
  transition: background 0.15s, border-color 0.15s;
}
.danger-btn:hover {
  border-color: #e0965a;
  background: rgba(224, 150, 90, 0.08);
}

/* Close-account confirmation modal */
.confirm-overlay {
  position: fixed;
  inset: 0;
  z-index: 400;
  background: rgba(0, 0, 0, 0.6);
  backdrop-filter: blur(2px);
}
.confirm-overlay[hidden],
.confirm-modal[hidden] {
  display: none;
}
.confirm-modal {
  position: fixed;
  z-index: 401;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: min(640px, calc(100vw - 40px));
  background: var(--bg);
  border: 1px solid var(--line);
  padding: 26px 30px 30px;
  box-shadow: 0 30px 80px rgba(0, 0, 0, 0.6);
  animation: menuIn 0.14s ease;
}
.confirm-eyebrow {
  font-size: 13px;
  color: var(--muted);
  padding-bottom: 16px;
  margin-bottom: 26px;
  border-bottom: 1px solid var(--line);
}
.confirm-alert {
  display: flex;
  gap: 15px;
  align-items: flex-start;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid var(--line-soft);
  padding: 22px 24px;
}
.confirm-icon {
  font-size: 17.5px;
  line-height: 1.4;
  flex-shrink: 0;
  color: #e0965a;
}
.confirm-alert p {
  margin: 0;
  font-size: 15.5px;
  line-height: 1.5;
  color: #e0965a;
}
.confirm-actions {
  display: flex;
  gap: 16px;
  margin-top: 30px;
}
.confirm-cancel {
  font: inherit;
  font-size: 14.5px;
  font-weight: 600;
  color: var(--text);
  background: none;
  border: 1px solid var(--blue);
  padding: 14px 30px;
  cursor: pointer;
  transition: background 0.15s;
}
.confirm-cancel:hover {
  background: rgba(106, 134, 255, 0.12);
}
.confirm-go {
  flex: 1;
  font: inherit;
  font-size: 14.5px;
  font-weight: 600;
  color: #17181c;
  background: #c8c4e8;
  border: none;
  padding: 14px 30px;
  cursor: pointer;
  transition: background 0.15s;
}
.confirm-go:hover {
  background: #d6d3ef;
}

/* ═══════════════════════════════════════════════════════════════════
   SUBMIT VIDEO (chips, intro, confirmation)
   ═══════════════════════════════════════════════════════════════════ */
.compose-intro {
  margin: 0 0 4px;
  color: var(--muted);
  font-size: 12.5px;
  line-height: 1.6;
}
.chip-row {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}
.chip {
  font: inherit;
  font-size: 12px;
  color: var(--muted);
  background: none;
  border: 1px solid var(--line);
  padding: 8px 14px;
  cursor: pointer;
}
.chip:hover {
  color: var(--text);
  border-color: rgba(255, 255, 255, 0.3);
}
.chip.active {
  background: var(--text);
  color: var(--bg);
  border-color: var(--text);
}
.submit-done {
  text-align: center;
  padding: 28px 8px 8px;
}
.submit-done[hidden] {
  display: none;
}
.submit-done-mark {
  width: 46px;
  height: 46px;
  margin: 0 auto 18px;
  display: flex;
  align-items: center;
  justify-content: center;
  border: 1px solid rgba(74, 222, 128, 0.5);
  color: #4ade80;
  font-size: 17.5px;
}
.submit-done-title {
  margin: 0 0 10px;
  font-size: 17px;
  font-weight: 500;
  color: var(--text);
}
.submit-done-text {
  margin: 0 auto 26px;
  max-width: 380px;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.6;
}
.submit-done .compose-actions {
  justify-content: center;
}

/* ================= Onboarding / Welcome ================= */
.topbar-auth {
  margin-left: auto;
  display: flex;
  align-items: center;
  gap: 10px;
}
.auth-btn {
  display: inline-flex;
  align-items: center;
  height: 32px;
  padding: 0 14px;
  font-family: inherit;
  font-size: 13px;
  font-weight: 500;
  color: var(--text);
  background: var(--pill);
  border: none;
  cursor: pointer;
  transition: background 0.15s;
}
.auth-btn:hover {
  background: var(--pill-hover);
}
.auth-btn.ghost {
  background: transparent;
}
.auth-btn.ghost:hover {
  background: var(--pill);
}

/* ---- Legal / plain-text pages (Terms) ---- */
/* Prose body under the breadcrumb - same type as .page-intro, with room for
   paragraphs and lists (About page, etc.). */
.page-body {
  max-width: 620px;
  margin: -16px 0 90px;
  color: var(--muted);
  font-size: 13.5px;
  line-height: 1.65;
}
.page-body p { margin: 0 0 16px; }
.page-body ol { margin: 0 0 16px; padding-left: 22px; }
.page-body li { margin-bottom: 6px; }
.page-body strong { color: var(--text); font-weight: 600; }
.page-body a { color: var(--text); text-decoration: underline; text-underline-offset: 2px; }
.page-body a:hover { color: var(--muted); }

.legal {
  max-width: 680px;
  margin: 0 auto;
  padding: 72px 22px 120px;
}
.legal-h1 {
  font-size: 21px;
  font-weight: 600;
  margin: 0 0 6px;
  color: var(--text);
}
.legal-updated {
  font-size: 12px;
  color: var(--muted);
  margin: 0 0 40px;
}
.legal h2 {
  font-size: 14px;
  font-weight: 600;
  color: var(--text);
  margin: 34px 0 10px;
}
.legal p,
.legal li {
  font-size: 13.5px;
  line-height: 1.65;
  color: var(--muted);
  margin: 0 0 14px;
}
.legal ul {
  margin: 0 0 14px;
  padding-left: 20px;
}
.legal li { margin-bottom: 6px; }
.legal strong { color: var(--text); font-weight: 600; }
.legal a { color: var(--blue); text-decoration: none; }
.legal a:hover { text-decoration: underline; }

.welcome {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 56px;
  align-items: center;
  padding: 64px 22px 120px;
}
.welcome-copy {
  min-width: 0;
}
.welcome-body {
  font-size: 13.5px;
  line-height: 1.6;
  color: var(--text);
  max-width: 480px;
}
.welcome-body p {
  margin: 0 0 22px;
}
.welcome-body ol {
  margin: 0 0 22px;
  padding-left: 26px;
}
.welcome-body li {
  margin-bottom: 6px;
}
.welcome-body strong {
  font-weight: 600;
}
.welcome-body .muted {
  color: var(--muted);
}
.welcome-cta {
  margin-top: 40px;
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
}
/* Live wall of member work opposite the copy (~50/50). Each tile shows the
   piece with its title + @handle beneath; GIFs and self-hosted video play. */
.welcome-showcase {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 18px;
  min-width: 0;
}
.welcome-showcase:empty { display: none; }
.welcome-tile {
  margin: 0;
  min-width: 0;
}
.welcome-tile-media {
  aspect-ratio: 1 / 1;
  overflow: hidden;
  background: var(--panel);
  border: 1px solid var(--line);
}
.welcome-tile-media img,
.welcome-tile-media video {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}
.welcome-tile-cap {
  margin-top: 8px;
  display: flex;
  flex-direction: column;
  gap: 1px;
}
.welcome-tile-title {
  font-size: 12px;
  color: var(--text);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.welcome-tile-handle {
  font-size: 12px;
  color: var(--muted);
}
@media (max-width: 820px) {
  .welcome {
    grid-template-columns: 1fr;
    gap: 40px;
    align-items: start;
  }
  .welcome-body { max-width: none; }
}
.try-btn {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  height: 42px;
  padding: 0 22px;
  font-family: inherit;
  font-size: 13px;
  font-weight: 500;
  color: var(--bg);
  background: var(--text);
  border: none;
  cursor: pointer;
  transition: opacity 0.15s;
}
.try-btn:hover {
  opacity: 0.85;
}
.try-btn.ghost {
  background: transparent;
  color: var(--text);
  border: 1px solid var(--line);
}
.try-btn.ghost:hover {
  opacity: 1;
  border-color: var(--text);
}
.welcome-hero {
  font-size: 26px;
  font-weight: 500;
  letter-spacing: -0.01em;
  color: var(--text);
  margin: 0 0 22px;
  line-height: 1.25;
}

@media (max-width: 640px) {
  .welcome {
    padding-top: 60px;
  }
  .welcome-body {
    font-size: 13px;
  }
}

/* ================= Edit-details dialog (sits above the detail modal) === */
.editor-overlay {
  position: fixed;
  inset: 0;
  z-index: 310;
  background: rgba(0, 0, 0, 0.66);
}
.editor {
  position: fixed;
  z-index: 311;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: min(440px, calc(100vw - 40px));
  max-height: 88vh;
  overflow: auto;
  background: var(--panel);
  border: 1px solid var(--line);
}
.editor-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 15px 18px;
  border-bottom: 1px solid var(--line);
}
.editor-eyebrow {
  font-size: 12px;
  font-weight: 600;
  color: var(--muted);
}
.editor-body {
  padding: 18px;
}
.editor-row {
  display: flex;
  gap: 12px;
}
.editor-row .field {
  flex: 1;
}
.editor .compose-actions {
  display: flex;
  align-items: center;
  gap: 10px;
}
.editor-spacer {
  flex: 1;
}
.ghost-btn.danger {
  color: #e0736b;
  border-color: transparent;
}
.ghost-btn.danger:hover {
  border-color: #e0736b;
}
.editor[hidden],
.editor-overlay[hidden] {
  display: none;
}

/* ================= Auth modal (fake sign-in) ================= */
.auth-overlay {
  position: fixed;
  inset: 0;
  z-index: 300;
  background: rgba(0, 0, 0, 0.72);
  animation: overlayIn 0.15s ease;
}
.auth-overlay[hidden] {
  display: none;
}
.auth-modal {
  position: fixed;
  z-index: 301;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: min(400px, calc(100vw - 40px));
  background: var(--panel);
  border: 1px solid var(--line);
  padding: 34px 32px 30px;
  animation: authIn 0.18s ease;
}
.auth-modal[hidden] {
  display: none;
}
@keyframes authIn {
  from { opacity: 0; transform: translate(-50%, -46%); }
  to { opacity: 1; transform: translate(-50%, -50%); }
}
.auth-close {
  position: absolute;
  top: 14px;
  right: 14px;
  background: none;
  border: none;
  color: var(--muted);
  font-size: 13.5px;
  cursor: pointer;
  line-height: 1;
}
.auth-close:hover {
  color: var(--text);
}
.auth-mark {
  font-size: 17.5px;
  letter-spacing: -3px;
  color: var(--text);
  user-select: none;
}
.auth-title {
  margin: 14px 0 4px;
  font-size: 19.5px;
  font-weight: 600;
  letter-spacing: -0.01em;
}
.auth-sub {
  margin: 0 0 22px;
  font-size: 12.5px;
  color: var(--muted);
}
.auth-form {
  display: flex;
  flex-direction: column;
  gap: 16px;
}
.auth-form .apply-btn {
  width: 100%;
  justify-content: center;
  margin-top: 4px;
}
.auth-error {
  font-size: 12px;
  color: #e0736b;
}
.auth-error.ok {
  color: var(--muted);
}
.auth-error[hidden] {
  display: none;
}
.auth-forgot {
  align-self: flex-start;
  background: none;
  border: none;
  padding: 0;
  font: inherit;
  font-size: 12px;
  color: var(--muted);
  cursor: pointer;
  text-decoration: underline;
  text-underline-offset: 2px;
}
.auth-forgot:hover {
  color: var(--text);
}

/* Avatar images (uploaded profile pictures) fill the initials chip. */
.avatar img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  border-radius: inherit;
}

/* Profile picture row in the edit drawer. */
.pfp-row {
  display: flex;
  align-items: center;
  gap: 14px;
}
.pfp-preview {
  width: 64px;
  height: 64px;
  flex: 0 0 64px;
  border: 1px solid var(--line);
  background: linear-gradient(150deg, #3b2f6b, #141024);
}
.pfp-btn {
  cursor: pointer;
}

/* Post-by-link row in the submit drawer. */
.url-fetch-row {
  display: flex;
  gap: 8px;
}
.url-fetch-row input {
  flex: 1;
  min-width: 0;
}

.auth-divider {
  display: flex;
  align-items: center;
  gap: 12px;
  margin: 16px 0;
  font-size: 11px;
  color: var(--muted);
}
.auth-divider::before,
.auth-divider::after {
  content: "";
  flex: 1;
  height: 1px;
  background: var(--line);
}
.google-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  width: 100%;
  height: 40px;
  font-size: 13px;
  font-weight: 500;
  color: var(--text);
  background: var(--panel);
  border: 1px solid var(--line);
  text-decoration: none;
  transition: border-color 0.15s;
}
.google-btn:hover {
  border-color: var(--text);
}
.auth-switch {
  margin: 20px 0 0;
  font-size: 12.5px;
  color: var(--muted);
  text-align: center;
}
.auth-switch button {
  background: none;
  border: none;
  color: var(--text);
  font: inherit;
  font-size: 12.5px;
  font-weight: 500;
  cursor: pointer;
  padding: 0;
  text-decoration: underline;
  text-underline-offset: 2px;
}

/* ── Member upload: drawer preview + feedback ────────────────────────────── */
.file-drop-preview {
  display: block;
  width: 100%;
  max-height: 240px;
  object-fit: contain;
  margin-top: 12px;
  border-radius: 8px;
  background: #000;
}
.file-drop-preview[hidden] {
  display: none;
}
.compose-msg {
  margin: 0 0 4px;
  color: #e0965a;
  font-size: 12px;
}
.compose-intro strong {
  color: var(--text);
  font-weight: 600;
}

/* Per-file / quota hint under the dropzone. */
.file-quota {
  margin: 8px 0 0;
  font-size: 11px;
  color: var(--dim);
}

/* ---- Predictive tag token input ---- */
.tag-field {
  position: relative;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 6px;
  padding: 8px 10px;
  background: var(--panel);
  border: 1px solid var(--line);
}
.tag-field:focus-within {
  border-color: rgba(255, 255, 255, 0.28);
}
.tag-tokens {
  display: contents;
}
.tag-token {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 4px 6px 4px 9px;
  font-size: 11.5px;
  color: var(--text);
  background: color-mix(in srgb, var(--blue) 22%, var(--panel));
  border: 1px solid color-mix(in srgb, var(--blue) 40%, var(--line));
  border-radius: 999px;
}
.tag-token .tag-x {
  display: grid;
  place-items: center;
  width: 15px;
  height: 15px;
  padding: 0;
  font-size: 12px;
  line-height: 1;
  color: var(--dim);
  background: none;
  border: none;
  border-radius: 999px;
  cursor: pointer;
}
.tag-token .tag-x:hover {
  color: var(--text);
  background: rgba(255, 255, 255, 0.12);
}
.tag-field .tag-input {
  flex: 1;
  min-width: 90px;
  width: auto;
  padding: 3px 2px;
  background: none;
  border: none;
  outline: none;
}
.tag-field .tag-input:focus {
  border: none;
}
.tag-suggest {
  position: absolute;
  left: -1px;
  right: -1px;
  top: calc(100% + 4px);
  z-index: 5;
  margin: 0;
  padding: 4px;
  list-style: none;
  background: var(--panel);
  border: 1px solid var(--line);
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.45);
}
.tag-suggest[hidden] {
  display: none;
}
.tag-opt {
  padding: 8px 10px;
  font-size: 12.5px;
  color: var(--muted);
  cursor: pointer;
}
.tag-opt:hover,
.tag-opt.active {
  color: var(--text);
  background: rgba(255, 255, 255, 0.06);
}

/* Native player for member video posts in the modal. */
video.modal-player {
  display: block;
  width: 100%;
  height: 100%;
  max-height: 100%;
  object-fit: contain;
  background: #000;
}

/* Member byline link in the modal. */
/* "By" doubles as a filter - it's a button, styled as the link it replaced. */
.by-link {
  color: var(--text);
  text-decoration: underline;
  text-underline-offset: 2px;
  background: none;
  border: none;
  padding: 0;
  font: inherit;
  cursor: pointer;
}
.by-link:hover {
  color: var(--blue);
}

/* Chip above the grid while one artist's work is being shown. */
.artist-filter {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 8px 14px;
  margin: 0 0 18px;
  border: 1px solid var(--line);
  background: var(--panel);
  font-size: 12.5px;
  color: var(--muted);
}
.artist-filter strong {
  color: var(--text);
  font-weight: 500;
}
.artist-filter-x {
  margin-left: auto;
  background: none;
  border: 1px solid var(--line);
  color: var(--muted);
  height: 26px;
  padding: 0 10px;
  font: inherit;
  font-size: 12px;
  cursor: pointer;
}
.artist-filter-x:hover {
  color: var(--text);
  border-color: var(--text);
}
.artist-filter[hidden] {
  display: none;
}

/* ── Profile: Work gallery ───────────────────────────────────────────────── */
.profile-label-row {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 12px;
}
.profile-post-link {
  color: var(--blue);
  font-size: 12px;
  font-weight: 500;
}
.work-grid {
  margin-top: 16px;
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
}
.work-item {
  margin: 0;
}
.work-media {
  position: relative;
  overflow: hidden;
  border-radius: 8px;
  background: var(--panel);
  border: 1px solid var(--line-soft);
}
.work-img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}
.work-menu {
  position: absolute;
  top: 6px;
  right: 6px;
  z-index: 3;
}
.work-dots {
  width: 26px;
  height: 26px;
  display: grid;
  place-items: center;
  font-size: 15px;
  line-height: 1;
  color: #fff;
  background: rgba(0, 0, 0, 0.55);
  border: none;
  border-radius: 999px;
  cursor: pointer;
  opacity: 0;
  transition: opacity 0.15s;
}
.work-item:hover .work-dots,
.work-dots:focus-visible { opacity: 1; }
.work-dots:hover { background: rgba(0, 0, 0, 0.8); }
.work-menu-pop {
  position: absolute;
  top: calc(100% + 4px);
  right: 0;
  min-width: 120px;
  background: var(--panel);
  border: 1px solid var(--line);
  box-shadow: 0 8px 22px rgba(0, 0, 0, 0.4);
  padding: 4px;
}
.work-menu-pop[hidden] { display: none; }
.work-menu-item {
  width: 100%;
  text-align: left;
  padding: 8px 10px;
  font: inherit;
  font-size: 13px;
  background: none;
  border: none;
  color: var(--text);
  cursor: pointer;
}
.work-menu-item:hover { background: var(--pill); }
.work-menu-item.danger { color: #e0736b; }
.work-cap {
  margin-top: 8px;
  color: var(--muted);
  font-size: 12px;
  line-height: 1.3;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.work-empty {
  margin-top: 16px;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.5;
}
@media (max-width: 640px) {
  .work-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

/* ── Tags: squared selectable cloud, sits in the controls row ─────────────── */
/* Constrained width so the cloud wraps over several rows rather than one long
   line, occupying the column where Category used to be. */
.tags-col {
  flex: 0 1 360px;
  min-width: 220px;
}
.tags-label {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 14px;
}
.tag-clear {
  background: none;
  border: none;
  color: var(--muted);
  font: inherit;
  font-size: 11px;
  cursor: pointer;
  text-decoration: underline;
  text-underline-offset: 2px;
}
.tag-clear:hover {
  color: var(--text);
}
.tag-cloud {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}
.tag-pill {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  height: 26px;
  padding: 0 9px;
  background: var(--pill);
  border: 1px solid transparent;
  border-radius: 0;
  color: var(--muted);
  font: inherit;
  font-size: 11.5px;
  cursor: pointer;
  transition: background 0.15s, color 0.15s, border-color 0.15s;
}
.tag-pill:hover {
  background: var(--pill-hover);
  color: var(--text);
}
.tag-pill.active {
  background: color-mix(in srgb, var(--blue) 22%, var(--panel));
  border-color: color-mix(in srgb, var(--blue) 55%, var(--line));
  color: var(--text);
}
.tag-count {
  font-size: 10.5px;
  color: var(--dim);
}
.tag-pill:hover .tag-count {
  color: var(--muted);
}
.tag-pill.active .tag-count {
  color: color-mix(in srgb, var(--blue) 55%, var(--text));
}
.tag-pill.tag-more {
  background: none;
  border: 1px solid var(--line);
  color: var(--muted);
}
.tag-pill.tag-more:hover {
  color: var(--text);
  border-color: rgba(255, 255, 255, 0.3);
}

/* ── Coming-soon lock veil (Jobs / Help) ──────────────────────────────────── */
/* Fixed full-viewport layer: the real page shows through at the top and slowly
   fades to black, with a lock badge + message centred. Colours are hardcoded
   light-on-dark because the backdrop is always black in either theme. */
.lock-veil {
  position: fixed;
  /* Start below the sticky topbar (54px) so the nav stays clickable and the
     fade begins beneath it. Sits under the topbar's z-index. */
  top: 54px;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 30;
  display: grid;
  place-items: center;
  text-align: center;
  padding: 24px;
  background: linear-gradient(
    to bottom,
    rgba(0, 0, 0, 0) 0,
    rgba(0, 0, 0, 0.5) 20%,
    rgba(0, 0, 0, 0.9) 55%,
    #000 100%
  );
}
.lock-veil-inner {
  max-width: 380px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 14px;
}
.lock-badge {
  display: grid;
  place-items: center;
  width: 56px;
  height: 56px;
  border-radius: 999px;
  color: #e8e8e8;
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(255, 255, 255, 0.14);
}
.lock-badge svg {
  width: 26px;
  height: 26px;
}
.lock-title {
  margin: 0;
  font-size: 19.5px;
  font-weight: 600;
  letter-spacing: -0.01em;
  color: #f2f2f2;
}
.lock-copy {
  margin: 0;
  font-size: 13px;
  line-height: 1.5;
  color: #9a9a9a;
}
.lock-back {
  margin-top: 6px;
  padding: 9px 16px;
  font-size: 12.5px;
  color: #ededed;
  text-decoration: none;
  border: 1px solid rgba(255, 255, 255, 0.18);
  border-radius: 999px;
  transition: border-color 0.15s, background 0.15s;
}
.lock-back:hover {
  border-color: rgba(255, 255, 255, 0.4);
  background: rgba(255, 255, 255, 0.05);
}
@media (prefers-reduced-motion: reduce) {
  .lock-veil,
  .lock-veil-inner {
    animation: none;
  }
}

/* Slim email-verification prompt above the grid. */
.verify-bar {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 9px 14px;
  margin: 0 0 20px;
  border: 1px solid var(--line);
  background: var(--panel);
  font-size: 12.5px;
  color: var(--muted);
}
.verify-bar.ok { border-color: #2e6b46; }
.verify-bar.err { border-color: #7a3838; }
.verify-act {
  margin-left: auto;
  background: var(--text);
  color: var(--bg);
  border: none;
  height: 28px;
  padding: 0 12px;
  font: inherit;
  font-size: 12px;
  font-weight: 500;
  cursor: pointer;
  white-space: nowrap;
}
.verify-act:disabled { opacity: 0.7; cursor: default; }
.verify-x {
  margin-left: 4px;
  background: none;
  border: none;
  color: var(--muted);
  font-size: 13px;
  cursor: pointer;
}
.verify-bar.ok .verify-x, .verify-bar.err .verify-x { margin-left: auto; }
.verify-x:hover { color: var(--text); }

/* ───────────────────────────────────────────────────────────────────────
   Beta banner - thin black bar, white type, at the very top of every page.
   Black regardless of theme (bookends the black footer).
   ─────────────────────────────────────────────────────────────────────── */
.beta-bar {
  background: #000;
  color: #fff;
  text-align: center;
  font-size: 12px;
  line-height: 1.4;
  letter-spacing: 0.01em;
  padding: 7px 16px;
}

/* Footer is black with white text, site-wide. */
.site-footer {
  background: #000;
  border-top: none;
}
.site-footer .footer-inner { color: rgba(255, 255, 255, 0.55); }
.site-footer .footer-inner a { color: rgba(255, 255, 255, 0.82); }
.site-footer .footer-inner a:hover { color: #fff; }

/* Home page fills the window; footer sits at the bottom even when short. */
body.home-page { min-height: 100vh; display: flex; flex-direction: column; }
body.home-page > main { flex: 1 0 auto; }
body.home-page > .site-footer { flex-shrink: 0; }
