/* ─── Cyber Space 77 ─── */
:root {
  --bg: #070707;
  --bg-panel: rgba(7, 7, 7, 0.75);
  --bg-panel-opaque: #070707;
  --bg-hint: #101010;
  --bg-input: #101010;
  --bg-card: rgba(0, 0, 0, 0.35);
  --bg-avatar: #12080c;
  --border: #2a1020;
  --border-hot: #e31337;
  --red: #e31337;
  --red-bright: #ff2a4d;
  --red-dim: #8b0f24;
  --dark-red: #5c0a18;
  --yellow: #ffe14a;
  --yellow-dim: #c9a91a;
  --orange: #ff6b00;
  --text: #d7d7d7;
  --text-dim: #9a9a9a;
  --text-muted: #b8b8c0;
  --gray: #d7d7d7;
  --gray-dim: #9a9a9a;
  --gray-arc: #484848;
  --gray-choice: #161616;
  --gray-result: #333333;
  --hp: #ff2a4d;
  --hive: #ffe14a;
  --glow-red: 0 0 20px rgba(227, 19, 55, 0.45);
  --glow-yellow: 0 0 16px rgba(255, 225, 74, 0.35);
  --font-display: "Orbitron", system-ui, sans-serif;
  --font-script: "Brush Script MT", cursive;
  --font-serif: "Instrument Serif", "Iowan Old Style", Palatino, Georgia, serif;
  --font-body: "Newsreader", "Iowan Old Style", Palatino, Georgia, serif;
  --font-mono: "Share Tech Mono", ui-monospace, monospace;
  --radius: 6px;
  --measure: 44rem;
}

/* Text for screen readers. Clipped, not display:none, so a focused heading stays in the tree. */
.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;
}

h1[tabindex="-1"]:focus,
h2[tabindex="-1"]:focus {
  outline: none;
}

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

html {
  font-size: 16px;
  scroll-behavior: smooth;
  overflow-x: hidden;
}

body {
  min-height: 100vh;
  min-height: 100dvh;
  display: flex;
  flex-direction: column;
  background: var(--bg);
  color: var(--text);
  font-family: var(--font-mono);
  overflow-x: hidden;
  position: relative;
  max-width: 100%;
}

img {
  max-width: 100%;
  height: auto;
}

a {
  color: var(--yellow);
  text-decoration: none;
}

a:hover {
  color: var(--yellow);
  text-shadow: var(--glow-yellow);
}

[hidden] {
  display: none !important;
}

/* Background */
.bg-hex {
  position: fixed;
  width: min(56vw, 620px);
  height: min(56vw, 620px);
  pointer-events: none;
  z-index: 0;
  background-image: url("../assets/hex-pattern.svg");
  background-repeat: no-repeat;
  background-size: cover;
  opacity: 0.28;
  filter: drop-shadow(0 0 10px rgba(227, 19, 55, 0.35));
}

.bg-hex-bl {
  left: -10%;
  bottom: -14%;
  -webkit-mask-image: radial-gradient(ellipse 72% 72% at 18% 84%, #000 0%, #000 28%, transparent 72%);
  mask-image: radial-gradient(ellipse 72% 72% at 18% 84%, #000 0%, #000 28%, transparent 72%);
}

.bg-hex-br {
  right: -10%;
  bottom: -14%;
  transform: scaleX(-1);
  -webkit-mask-image: radial-gradient(ellipse 72% 72% at 18% 84%, #000 0%, #000 28%, transparent 72%);
  mask-image: radial-gradient(ellipse 72% 72% at 18% 84%, #000 0%, #000 28%, transparent 72%);
}

/* scanlines */
.logo-wrap::before,
.btn-primary::after {
   content: "";
   position: absolute;
   inset: 0;
   background: repeating-linear-gradient(
     0deg,
     transparent,
     transparent 2px,
     rgba(0, 0, 0, 0.08) 2px,
     rgba(0, 0, 0, 0.08) 4px
   );
   pointer-events: none;
   opacity: 0.4;
   border-radius: inherit;
}

/* The 77 glow is a filter, which paints above this overlay. Keep the lines on top of it. */
.logo-wrap::before {
  z-index: 1;
}

.app {
  position: relative;
  z-index: 1;
  flex: 1 0 auto;
  width: 100%;
  max-width: 960px;
  margin: 0 auto;
  padding: 2rem 1.75rem 3rem;
  min-width: 0;
  min-height: calc(100dvh - 20rem);
  overflow-x: hidden;
}

#view {
  max-width: 600px;
  margin-left: auto;
  margin-right: auto;
}

.post-layer {
  position: relative;
  z-index: 1;
  flex: 1 0 auto;
  width: 100%;
  max-width: 960px;
  margin: 0 auto;
  padding: 2rem 1.75rem 3rem;
  min-width: 0;
  min-height: calc(100dvh - 20rem);
  overflow-x: clip;
}

.post-layer-inner {
  width: 100%;
  max-width: 600px;
  margin: 0 auto;
  padding: 0;
  min-width: 0;
}

body.is-post-open .app,
body.is-post-open .welcome-flyer {
  display: none !important;
}

.is-profile .app,
.is-profile #view {
  max-width: none;
}

.is-profile .app {
  padding-top: 0;
}

.is-profile .feed {
  max-width: 600px;
  margin-left: auto;
  margin-right: auto;
}

.app > *,
.feed > *,
.post-card > *,
.header > * {
  min-width: 0;
  max-width: 100%;
}

/* Header */
.header-slot {
  width: 100%;
}

.header {
  position: relative;
  z-index: 42;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1.5rem;
  width: 100%;
  padding: 1rem 1.75rem;
  flex-wrap: wrap;
  overflow: visible;
}

/* Blur, fade, and slide live here. Opacity or transform on .header hides the
   blur until the fade ends, and a filter on .header traps the menus. */
.header::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  background: var(--bg-panel);
  backdrop-filter: blur(8px);
  border-bottom: 1px solid var(--border);
  pointer-events: none;
}

.logo-wrap {
  display: flex;
  position: relative;
  align-items: center;
  gap: 1.25rem;
  text-decoration: none;
  color: inherit;
}

.logo-wrap:hover {
  color: inherit;
  text-shadow: none;
}

.logo-menu {
  position: relative;
  flex-shrink: 0;
}

.logo-trigger {
  display: block;
  margin: 0;
  padding: 0;
  border: 0;
  background: transparent;
  color: inherit;
  cursor: pointer;
  line-height: 0;
  font: inherit;
  appearance: none;
  -webkit-appearance: none;
  touch-action: manipulation;
}

.logo-trigger:focus {
  outline: none;
}

.logo-trigger:focus-visible {
  outline: 1px solid var(--yellow);
  outline-offset: 3px;
}

.logo-dropdown {
  display: none;
  position: absolute;
  top: 100%;
  left: 0;
  z-index: 42;
  padding-top: 0.45rem;
  min-width: 8.75rem;
}

.logo-wrap.is-open .logo-dropdown {
  display: block;
}

html.has-mouse .logo-menu:hover .logo-dropdown {
  display: block;
}

.logo-dropdown-panel {
  display: flex;
  flex-direction: column;
  background: var(--bg-panel);
  backdrop-filter: blur(8px);
  border: 1px solid var(--border-hot);
  border-radius: var(--radius);
  box-shadow: var(--glow-red), 0 12px 32px rgba(0, 0, 0, 0.45);
  max-height: min(70vh, 32rem);
  overflow-x: hidden;
  overflow-y: auto;
}

.logo-dropdown-link {
  font-family: var(--font-display);
  font-size: 0.68rem;
  font-weight: 700;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--gray);
  padding: 0.75rem 1.05rem;
  text-decoration: none;
  white-space: nowrap;
}

.logo-dropdown-link:hover,
.logo-dropdown-link:focus-visible {
  color: var(--yellow);
  background: rgba(227, 19, 55, 0.12);
  text-shadow: var(--glow-yellow);
}

/* Same 1.15rem gear as #zapSettings. No label; the link name is the aria-label.
   Orbitron at 0.68rem uses a 14px normal line box. The gear is 18.4px, so 2.2px less padding each side matches the label rows. */
.logo-settings-link {
  display: flex;
  align-items: center;
  padding-top: calc(0.75rem - 2.2px);
  padding-bottom: calc(0.75rem - 2.2px);
}

.logo-settings-link svg {
  display: block;
  width: 1.15rem;
  height: 1.15rem;
  flex: 0 0 auto;
}

.logo-settings-link:hover,
.logo-settings-link:focus-visible {
  text-shadow: none;
}

.logo-settings-link:hover svg,
.logo-settings-link:focus-visible svg {
  filter: drop-shadow(0 0 6px rgba(255, 225, 74, 0.55));
}

.logo-dropdown-favs {
  display: flex;
  flex-direction: column;
}

html.has-mouse .logo-wrap:hover .brand h1,
.logo-wrap.is-open .brand ,
#logoBrand:active  {
  color: var(--red-bright);
  text-shadow:
    0 0 6px #ff2a4d,
    0 0 16px rgba(227, 19, 55, 0.9),
    0 0 32px rgba(227, 19, 55, 0.65),
    0 0 48px rgba(227, 19, 55, 0.35);
}

html.has-mouse .logo-wrap:hover .brand-77,
.logo-wrap.is-open .brand-77,
#logoBrand:active .brand-77 {
  filter:
    drop-shadow(0 0 8px #ff2a4d)
    drop-shadow(0 0 20px rgba(255, 42, 77, 0.95))
    drop-shadow(0 0 40px rgba(227, 19, 55, 0.55));
}

html.has-mouse .logo-wrap:hover .app-logo,
.logo-wrap.is-open .app-logo {
  color: var(--red-bright);
  filter:
    drop-shadow(0 0 6px #ff2a4d)
    drop-shadow(0 0 16px rgba(227, 19, 55, 0.9))
    drop-shadow(0 0 28px rgba(227, 19, 55, 0.55));
}

.app-logo {
  width: 60px;
  height: 60px;
  flex-shrink: 0;
  display: block;
  overflow: visible;
  transform-origin: center;
  color: var(--yellow);
  pointer-events: all;
  transition: transform 0.45s ease, filter 0.25s ease, color 0.25s ease;
}

.app-logo.is-spinning {
  transition: none;
}

.brand {
  text-decoration: none;
  color: inherit;
}

.brand:hover {
  color: inherit;
  text-shadow: none;
}

.brand h1 {
  display:inline;
  text-transform: uppercase;
  font-family: var(--font-display);
  font-weight: 800;
  font-size: clamp(1.4rem, 4vw, 2rem);
  letter-spacing: 0.12em;
  color: var(--yellow);
  text-shadow: var(--glow-yellow);
  line-height: 1.2;
  margin: 0;
  transition: color 0.25s ease, text-shadow 0.25s ease;
}

.brand-keep {
  white-space: nowrap;
}

.brand-77 {
  display: inline-block;
  height: 0.78125em;
  width: auto;
  aspect-ratio: 1407 / 853;
  margin-left: 1.25rem;
  vertical-align: baseline;
  color: var(--red-bright);
  overflow: visible;
  filter: drop-shadow(0 0 12px rgba(255, 42, 77, 0.45));
  transition: filter 0.25s ease;
}

.header-right {
  display: flex;
  align-items: center;
  gap: 1rem;
  flex-wrap: wrap;
  margin-left: auto;
}

.node-menu {
  position: relative;
  flex-shrink: 0;
}

.status-pill {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  margin: 0;
  padding: 0.45rem 0.95rem;
  border: 1px solid var(--border-hot);
  border-radius: 999px;
  background: rgba(227, 19, 55, 0.08);
  font-family: var(--font-mono);
  font-size: 0.75rem;
  line-height: 1.2;
  color: var(--yellow);
  letter-spacing: 0.06em;
  max-width: 100%;
  cursor: pointer;
  appearance: none;
  -webkit-appearance: none;
}

.status-pill:hover {
  border-color: var(--red-bright);
  background: rgba(227, 19, 55, 0.16);
}

.status-pill:focus {
  outline: none;
}

.status-pill:focus-visible {
  outline: 1px solid var(--yellow);
  outline-offset: 2px;
}

.status-pill .node-label {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  max-width: 16rem;
}

.node-menu-in-menu {
  display: none;
}

.node-dropdown {
  display: none;
  position: absolute;
  top: 100%;
  right: 0;
  z-index: 40;
  padding-top: 0.45rem;
  min-width: 100%;
}

.node-menu.is-open .node-dropdown {
  display: block;
}

html.has-mouse .node-menu:hover .node-dropdown {
  display: block;
}

/* The notification panel is beside this pill. Hover must not open the node list over it. */
html.has-mouse .header-right:has(.session-menu.is-open) > .node-menu:not(.is-open):hover .node-dropdown {
  display: none;
}

.node-dropdown-panel {
  display: flex;
  flex-direction: column;
  min-width: 12rem;
  max-width: min(22rem, calc(100vw - 2rem));
  background: var(--bg-panel);
  backdrop-filter: blur(8px);
  border: 1px solid var(--border-hot);
  border-radius: var(--radius);
  box-shadow: var(--glow-red), 0 12px 32px rgba(0, 0, 0, 0.45);
  overflow: hidden;
}

.node-option {
  display: block;
  width: 100%;
  margin: 0;
  padding: 0.65rem 1.05rem;
  border: 0;
  background: transparent;
  font-family: var(--font-mono);
  font-size: 0.75rem;
  line-height: 1.2;
  letter-spacing: 0.06em;
  color: var(--gray);
  text-align: left;
  cursor: pointer;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.node-option:hover,
.node-option:focus-visible {
  color: var(--yellow);
  background: rgba(227, 19, 55, 0.12);
}

.node-option.is-active {
  color: var(--yellow);
}

.status-pill .dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--red-bright);
  box-shadow: 0 0 8px var(--red-bright);
  animation: blink 1.6s ease-in-out infinite;
  flex-shrink: 0;
}

@keyframes blink {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.35; }
}

.btn-ghost,
.btn-login {
  position: relative;
  font-family: var(--font-display);
  font-size: 0.68rem;
  font-weight: 700;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--gray);
  background: transparent;
  border: none;
  border-radius: 0;
  padding: 0.55rem 1rem;
  cursor: pointer;
  opacity: 0.85;
  transition: color 0.2s, opacity 0.2s, text-shadow 0.2s;
}

.btn-ghost::before,
.btn-ghost::after,
.btn-login::before,
.btn-login::after {
  content: "";
  position: absolute;
  width: 8px;
  height: 8px;
  pointer-events: none;
  transition: width 0.2s, height 0.2s;
}

.btn-ghost::before,
.btn-login::before {
  top: 0;
  left: 0;
  border-top: 1px solid currentColor;
  border-left: 1px solid currentColor;
}

.btn-ghost::after,
.btn-login::after {
  right: 0;
  bottom: 0;
  border-right: 1px solid currentColor;
  border-bottom: 1px solid currentColor;
}

.btn-ghost:hover,
.btn-login:hover {
  color: var(--yellow);
  opacity: 1;
  text-shadow: var(--glow-yellow);
}

.btn-ghost:hover::before,
.btn-ghost:hover::after,
.btn-login:hover::before,
.btn-login:hover::after {
  width: 12px;
  height: 12px;
}

#sessionSlot {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  position: relative;
}

.session-menu {
  position: relative;
  display: flex;
  align-items: center;
  flex-shrink: 0;
}

.session-chip {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  font-family: var(--font-mono);
  font-size: 0.8rem;
  line-height: 1;
  color: var(--yellow);
}

.session-avatar-btn {
  display: block;
  margin: -0.45rem -0.3rem -0.45rem -0.45rem;
  padding: 0.45rem 0.3rem 0.45rem 0.45rem;
  border: 0;
  background: transparent;
  color: inherit;
  cursor: pointer;
  line-height: 0;
  font: inherit;
  appearance: none;
  -webkit-appearance: none;
  touch-action: manipulation;
}

.session-avatar-btn:focus {
  outline: none;
}

.session-avatar-btn:focus-visible {
  outline: 1px solid var(--yellow);
  outline-offset: 2px;
  border-radius: 999px;
}

.session-avatar-btn:hover img,
.session-menu.is-open .session-avatar-btn img {
  box-shadow: 0 0 8px rgba(255, 225, 74, 0.55);
}

.session-avatar-wrap {
  position: relative;
  display: block;
  width: 24px;
  height: 24px;
  flex-shrink: 0;
}

.session-chip img {
  display: block;
  width: 24px;
  height: 24px;
  border-radius: 50%;
  object-fit: cover;
  flex-shrink: 0;
}

.session-badge {
  position: absolute;
  top: 0;
  right: 0;
  z-index: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  min-width: 1.05rem;
  height: 1.05rem;
  padding: 0 0.28rem;
  transform: translate(40%, -55%);
  border-radius: 999px;
  background: var(--red-bright);
  color: #fff;
  font-family: var(--font-mono);
  font-size: 0.62rem;
  line-height: 1;
  letter-spacing: 0;
  box-shadow: 0 0 8px rgba(255, 42, 77, 0.7);
  pointer-events: none;
}

.session-name {
  display: block;
  line-height: 1;
  margin: -0.45rem -0.2rem;
  padding: 0.45rem 0.2rem;
  color: var(--yellow);
  text-decoration: none;
  text-box: trim-both cap alphabetic;
}

.session-name:hover,
.session-account:hover .session-name,
.session-account.is-open .session-name,
.session-account:focus-within .session-name {
  text-shadow: var(--glow-yellow);
}

.session-name:focus {
  outline: none;
}

.session-name:focus-visible {
  outline: 1px solid var(--yellow);
  outline-offset: 3px;
}

.session-account {
  position: relative;
  align-self: stretch;
  display: flex;
  align-items: center;
}

.session-account-menu {
  display: none;
  position: absolute;
  top: 100%;
  right: 0;
  z-index: 42;
  /* Gap under the username and avatar. On desktop this also lines the menu up with the node pill menu. Mobile keeps the same gap. */
  padding-top: calc(0.5rem + 2.6px);
  min-width: 8.75rem;
}

html.has-mouse .session-account:hover .session-account-menu,
html.has-mouse .session-account:focus-within .session-account-menu {
  display: block;
}

/* Username click loads the profile. Stay closed until the pointer leaves. */
html.has-mouse .session-account.is-dismissed:hover .session-account-menu,
html.has-mouse .session-account.is-dismissed:focus-within .session-account-menu {
  display: none;
}

.session-account.is-open .session-account-menu {
  display: block;
}

.session-account-panel {
  display: flex;
  flex-direction: column;
  background: var(--bg-panel);
  backdrop-filter: blur(8px);
  border: 1px solid var(--border-hot);
  border-radius: var(--radius);
  box-shadow: var(--glow-red), 0 12px 32px rgba(0, 0, 0, 0.45);
  overflow: hidden;
}

.session-account-link {
  display: block;
  width: 100%;
  margin: 0;
  padding: 0.75rem 1.05rem;
  border: 0;
  background: transparent;
  font-family: var(--font-display);
  font-size: 0.68rem;
  font-weight: 700;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  text-align: left;
  color: var(--gray);
  text-decoration: none;
  white-space: nowrap;
  cursor: pointer;
  appearance: none;
  -webkit-appearance: none;
}

.session-account-link:hover,
.session-account-link:focus-visible {
  color: var(--yellow);
  background: rgba(227, 19, 55, 0.12);
  text-shadow: var(--glow-yellow);
  outline: none;
}

/* Icon replaces the Switch user label. 1rem keeps the stroke readable next to the 0.68rem labels. */
.session-account-switch-btn {
  display: flex;
  align-items: center;
  padding-top: calc(0.75rem - 0.16rem);
  padding-bottom: calc(0.75rem - 0.16rem);
}

.session-account-switch-btn svg {
  display: block;
  width: 1rem;
  height: 1rem;
  flex: 0 0 auto;
}

.session-account-switch-btn:hover,
.session-account-switch-btn:focus-visible {
  text-shadow: none;
}

.session-account-switch-btn:hover svg,
.session-account-switch-btn:focus-visible svg {
  filter: drop-shadow(0 0 6px rgba(255, 225, 74, 0.55));
}

.session-dropdown {
  display: none;
  position: absolute;
  top: 100%;
  right: 0;
  z-index: 42;
  /* The session chip is shorter than the node pill and centered with it, so this extra gap lines the notification panel up with the node menu. */
  padding-top: calc(0.5rem + 2.6px);
  width: min(22rem, calc(100vw - 2.2rem));
}

.session-menu.is-open .session-dropdown {
  display: block;
}

.session-dropdown-panel {
  background: var(--bg-panel);
  backdrop-filter: blur(8px);
  border: 1px solid var(--border-hot);
  border-radius: var(--radius);
  box-shadow: var(--glow-red), 0 12px 32px rgba(0, 0, 0, 0.45);
  overflow: hidden;
}

.session-dropdown-panel:focus {
  outline: none;
}

.session-account-stats {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 0.75rem;
  position: relative;
  z-index: 2;
  flex-shrink: 0;
  margin: 0;
  padding: 0.7rem 0.85rem 0.62rem;
  border-bottom: 1px solid var(--border);
  font-family: var(--font-mono);
  font-size: 0.72rem;
  line-height: 1;
  color: var(--yellow);
  white-space: nowrap;
}

.session-account-stats-main {
  display: flex;
  align-items: baseline;
  gap: 0.95rem;
  min-width: 0;
}

.session-stat {
  position: relative;
  display: inline-flex;
  align-items: baseline;
  gap: 0.32rem;
}

.session-account-stats .session-stat[hidden] {
  display: none;
}

.session-stat:focus {
  outline: none;
}

.session-stat:focus-visible {
  outline: 1px solid var(--yellow);
  outline-offset: 3px;
  border-radius: 2px;
}

.session-stat-rc:focus-visible {
  outline-color: var(--gray);
}

.session-stat.is-low:focus-visible {
  outline-color: var(--red-bright);
}

.session-stat-label {
  color: var(--yellow);
  letter-spacing: 0.04em;
}

.session-stat-value {
  color: var(--yellow);
  font-size: 0.86rem;
  letter-spacing: 0;
  text-shadow: var(--glow-yellow);
}

.session-stat-rc .session-stat-label,
.session-stat-rc .session-stat-value {
  color: var(--gray);
  text-shadow: none;
}

.session-stat.is-low .session-stat-label,
.session-stat.is-low .session-stat-value {
  color: var(--red-bright);
  text-shadow: 0 0 16px rgba(255, 42, 77, 0.45);
}

.session-stat-tip {
  position: absolute;
  left: 0;
  top: calc(100% + 0.45rem);
  z-index: 3;
  padding: 0.28rem 0.55rem;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--bg-hint);
  backdrop-filter: blur(8px);
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.45);
  color: var(--text);
  font-family: var(--font-mono);
  font-size: 0.72rem;
  font-weight: 400;
  letter-spacing: 0.02em;
  line-height: 1.2;
  white-space: nowrap;
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transition: opacity 0.12s ease, visibility 0.12s ease;
}

.session-stat-rc .session-stat-tip {
  left: auto;
  right: 0;
}

.session-stat:hover .session-stat-tip,
.session-stat:focus-visible .session-stat-tip {
  opacity: 1;
  visibility: visible;
}

.session-account-stats.is-loading .session-stat-value {
  color: var(--text-muted);
  font-size: 0.78rem;
  text-shadow: none;
}

.session-notifs {
  max-height: 18rem;
  overflow-y: auto;
  padding: 0.35rem;
  scrollbar-width: thin;
}

.session-notifs-empty {
  margin: 0;
  padding: 0.7rem 0.8rem;
  font-family: var(--font-mono);
  font-size: 0.78rem;
  color: var(--gray);
}

.session-notifs-more {
  padding: 0.45rem 0.8rem;
  text-align: center;
}

.session-notif {
  display: flex;
  align-items: flex-start;
  gap: 0.55rem;
  padding: 0.55rem 0.65rem;
  border-radius: 4px;
  color: var(--gray);
  text-decoration: none;
}

.session-notif[data-href] {
  cursor: pointer;
}

.session-notif:hover,
.session-notif:focus-within {
  background: rgba(227, 19, 55, 0.12);
  text-shadow: none;
}

.session-notif a:focus {
  outline: none;
}

.session-notif a:focus-visible {
  outline: 1px solid var(--yellow);
  outline-offset: 2px;
  border-radius: 2px;
}

.session-notif.is-unread .session-notif-msg {
  color: var(--yellow);
}

.session-notif-actor {
  display: block;
  flex-shrink: 0;
  line-height: 0;
  margin-top: 0.1rem;
  text-decoration: none;
}

.session-notif-avatar {
  display: block;
  width: 22px;
  height: 22px;
  border-radius: 50%;
  object-fit: cover;
  flex-shrink: 0;
  background: var(--bg-avatar);
}

.session-notif-user,
.session-notif-text {
  color: inherit;
  text-decoration: none;
}

.session-notif-body {
  display: flex;
  flex-direction: column;
  gap: 0.2rem;
  min-width: 0;
}

.session-notif-msg {
  font-family: var(--font-mono);
  font-size: 0.78rem;
  line-height: 1.35;
  overflow-wrap: anywhere;
}

.session-notif-time {
  font-family: var(--font-mono);
  font-size: 0.68rem;
  color: var(--text-muted);
  text-decoration: none;
}

.session-notif-time:hover {
  color: var(--text-muted);
}

.session-menu-actions {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.5rem;
  border-top: 1px solid var(--border);
}

.session-mark-read,
.session-logout {
  padding: 0.7rem 0.85rem;
  background: transparent;
  border: none;
  color: var(--gray);
  font-family: var(--font-display);
  font-size: 0.62rem;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  cursor: pointer;
  white-space: nowrap;
}

.session-logout {
  margin-left: auto;
  text-align: right;
}

.session-mark-read:focus,
.session-logout:focus {
  outline: none;
}

.session-mark-read:hover,
.session-mark-read:focus-visible,
.session-logout:hover,
.session-logout:focus-visible {
  color: var(--yellow);
  text-shadow: var(--glow-yellow);
}

.session-mark-read:disabled {
  color: var(--gray);
  opacity: 0.45;
  cursor: default;
  text-shadow: none;
}

.vote-counts {
  display: inline-flex;
  align-items: center;
  gap: 0.85rem;
}

.vote-wrap {
  display: inline-flex;
  align-items: center;
  gap: 0.85rem;
  position: relative;
  z-index: 2;
}

.vote-wrap.is-open {
  z-index: 20;
}

.vote-slider-panel:focus,
.downvote-slider-panel:focus {
  outline: none;
}

.vote-slider-panel,
.downvote-slider-panel {
  position: absolute;
  top: calc(100% + 0.45rem);
  left: 0;
  z-index: 60;
}

.article-stats .vote-slider-panel,
.article-stats .downvote-slider-panel {
  left: auto;
  right: 0;
}

.vote-weight {
  display: inline-flex;
  align-items: center;
  gap: 0.65rem;
  padding: 0.45rem 0.75rem 0.45rem 0.85rem;
  border: 1px solid var(--border-hot);
  border-radius: var(--radius);
  background: var(--bg-panel-opaque);
  backdrop-filter: blur(8px);
  box-shadow: var(--glow-red), 0 8px 24px rgba(0, 0, 0, 0.4);
  cursor: pointer;
  white-space: nowrap;
}

.vote-weight-caption {
  font-family: var(--font-display);
  font-size: 0.58rem;
  font-weight: 700;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--gray);
}

.vote-slider-slot {
  display: contents;
}

.vote-weight-value {
  font-family: var(--font-mono);
  font-size: 0.75rem;
  letter-spacing: 0.04em;
  color: var(--yellow);
  min-width: 2.6em;
  text-align: right;
  text-shadow: var(--glow-yellow);
}

.vote-slider-line {
  --vote-pct: 100%;
  --p: 1;
  --thumb: 22px;
  --tuck: 14px;
  --gap-right: calc((1 - var(--p)) * (100% - var(--thumb)));
  --track-inset-right: max(0px, var(--tuck) - var(--gap-right));
  --track-inset-left: 0px;
  position: relative;
  display: inline-flex;
  align-items: center;
  width: 7.5rem;
  margin-block: 0.7rem;
  flex: 0 0 auto;
}

.vote-slider-line::before {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  top: 50%;
  height: 8px;
  transform: translateY(-50%);
  border-radius: 999px;
  background: linear-gradient(
    90deg,
    var(--red) 0%,
    var(--yellow) var(--vote-pct),
    rgba(42, 16, 32, 0.95) var(--vote-pct)
  );
  clip-path: inset(0 var(--track-inset-right) 0 var(--track-inset-left) round 999px);
  filter: drop-shadow(0 0 6px rgba(227, 19, 55, 0.4));
  pointer-events: none;
}

.vote-slider {
  --vote-thumb: url("../assets/vote-thumb.svg");
  -webkit-appearance: none;
  appearance: none;
  position: relative;
  z-index: 1;
  width: 100%;
  height: 8px;
  margin: 0;
  border-radius: 999px;
  background: transparent;
  outline: none;
  cursor: pointer;
  box-shadow: none;
}

.vote-slider:focus-visible {
  outline: 1px solid var(--yellow);
  outline-offset: 3px;
}

.vote-slider::-webkit-slider-thumb {
  -webkit-appearance: none;
  appearance: none;
  width: 22px;
  height: 19px;
  margin-top: -5.5px;
  border: 0;
  border-radius: 0;
  background: transparent var(--vote-thumb) center / contain no-repeat;
  box-shadow: none;
  filter: drop-shadow(0 0 5px rgba(255, 225, 74, 0.95)) drop-shadow(var(--glow-yellow));
  cursor: pointer;
}

.vote-slider::-moz-range-thumb {
  width: 22px;
  height: 19px;
  border: 0;
  border-radius: 0;
  background: transparent var(--vote-thumb) center / contain no-repeat;
  box-shadow: none;
  filter: drop-shadow(0 0 5px rgba(255, 225, 74, 0.95)) drop-shadow(var(--glow-yellow));
  cursor: pointer;
}

.vote-slider::-webkit-slider-runnable-track {
  height: 8px;
  border: 0;
  border-radius: 999px;
  background: transparent;
  box-shadow: none;
}

.vote-slider::-moz-range-track {
  height: 8px;
  border: 0;
  border-radius: 999px;
  background: transparent;
  box-shadow: none;
}

.queue-slot {
  display: flex;
  align-items: center;
}

.queue-pill {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  padding: 0.4rem 0.8rem;
  border: 1px solid var(--border-hot);
  border-radius: 999px;
  background: rgba(227, 19, 55, 0.08);
  font-family: var(--font-mono);
  font-size: 0.72rem;
  letter-spacing: 0.06em;
  color: var(--yellow);
}

.queue-pill .dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--yellow);
  box-shadow: 0 0 8px var(--yellow);
  animation: blink 1.6s ease-in-out infinite;
}

.vote-pills {
  gap: 0.55rem;
}

.vote-pair {
  display: inline-flex;
  align-items: center;
  gap: 0.28rem;
}

.stat-pill {
  border: 1px solid var(--border);
  border-radius: 999px;
  background: transparent;
  line-height: 1;
  transition: border-color 0.15s, color 0.15s, text-shadow 0.15s;
}

.vote-btn,
.downvote-btn {
  appearance: none;
  position: relative;
  z-index: 1;
  display: inline-flex;
  align-items: center;
  gap: 0.25rem;
  margin: -0.2rem -0.35rem;
  padding: 0.2rem 0.35rem;
  border: none;
  border-radius: 4px;
  background: transparent;
  font: inherit;
  letter-spacing: inherit;
  color: inherit;
  cursor: pointer;
  line-height: 1;
  user-select: none;
  touch-action: manipulation;
  transition: color 0.15s, text-shadow 0.15s, opacity 0.15s;
}

.vote-btn:hover {
  color: var(--yellow);
  text-shadow: var(--glow-yellow);
}

.downvote-btn:hover {
  color: var(--red-bright);
  text-shadow: var(--glow-red);
}

.vote-btn:focus-visible,
.downvote-btn:focus-visible {
  outline: 1px solid var(--yellow);
  outline-offset: 2px;
}

.downvote-btn:focus-visible {
  outline-color: var(--red-bright);
}

.vote-btn.is-voted {
  color: var(--yellow);
  text-shadow: var(--glow-yellow);
}

.vote-btn.is-voted:hover {
  color: var(--yellow);
  text-shadow: var(--glow-yellow);
}

.downvote-btn.is-voted,
.downvote-btn.is-voted:hover {
  color: var(--red-bright);
  text-shadow: var(--glow-red);
}

.vote-btn.is-pending,
.downvote-btn.is-pending {
  opacity: 0.65;
  cursor: wait;
}

.vote-btn.stat-pill,
.downvote-btn.stat-pill,
.vote-count-btn.stat-pill {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  margin: 0;
  min-width: 2.45rem;
  height: 2.45rem;
  border: 1px solid var(--border);
  border-radius: 999px;
  background: transparent;
  font-size: 1.05rem;
  transition: color 0.15s, text-shadow 0.15s, background 0.15s, box-shadow 0.15s, border-color 0.15s, opacity 0.15s;
}

.vote-count-btn.stat-pill {
  padding: 0.45rem 0.9rem;
}

.vote-btn.is-confirming,
.vote-btn.stat-pill.is-confirming,
.vote-btn.is-confirming:hover,
.vote-btn.stat-pill.is-confirming:hover {
  border: 1px solid var(--yellow);
  border-radius: 999px;
  background-color: var(--yellow);
  color: #140f04;
  text-shadow: none;
  box-shadow: var(--glow-yellow), inset 0 1px 0 rgba(255, 255, 255, 0.45);
}

.vote-count-btn {
  appearance: none;
  font: inherit;
  letter-spacing: inherit;
  color: inherit;
  cursor: pointer;
  line-height: 1;
  touch-action: manipulation;
  user-select: none;
}

.vote-count-btn:hover {
  color: var(--yellow);
  text-shadow: var(--glow-yellow);
}

.vote-count-btn[data-vote-dir="down"]:hover {
  color: var(--red-bright);
  text-shadow: var(--glow-red);
}

.vote-count-btn[data-vote-dir="down"]:focus-visible {
  outline-color: var(--red-bright);
}

.vote-count-btn:focus-visible {
  outline: 1px solid var(--yellow);
  outline-offset: 2px;
}

.payout.stat-pill {
  appearance: none;
  display: inline-flex;
  align-items: center;
  min-height: 2.45rem;
  padding: 0.45rem 0.95rem;
  background: transparent;
  font: inherit;
  letter-spacing: inherit;
  color: inherit;
  cursor: pointer;
  line-height: 1;
  touch-action: manipulation;
  user-select: none;
}

.payout-value {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  line-height: 1;
}

.payout-mark {
  font-family: "Segoe UI Emoji", "Apple Color Emoji", "Noto Color Emoji", sans-serif;
  font-weight: 400;
  letter-spacing: 0;
  line-height: 1;
}

.payout.is-declined .payout-amount {
  text-decoration: line-through;
  text-decoration-thickness: 1.5px;
}

.payout.stat-pill:focus-visible {
  outline: 1px solid var(--yellow);
  outline-offset: 2px;
}

.payout-panel:focus {
  outline: none;
}

.payout-panel {
  width: max-content;
  min-width: 15.5rem;
  max-width: min(22rem, calc(100vw - 16px));
  overflow: auto;
  padding: 0.7rem 0.85rem 0.75rem;
  border: 1px solid var(--border-hot);
  border-radius: var(--radius);
  background: var(--bg-panel-opaque);
  backdrop-filter: blur(8px);
  box-shadow: var(--glow-red), 0 8px 24px rgba(0, 0, 0, 0.4);
  color: var(--text);
  font-family: var(--font-mono);
  font-size: 0.78rem;
  line-height: 1.35;
}

.payout-panel-caption {
  margin: 0 0 0.5rem;
  font-family: var(--font-display);
  font-size: 0.58rem;
  font-weight: 700;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--gray);
}

.payout-panel-sub {
  margin-top: 0.7rem;
}

.payout-panel-row {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 0.85rem;
  padding: 0.12rem 0;
}

.payout-panel-row a,
.payout-panel-row > span:first-child {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  color: var(--text);
}

.payout-panel-row a:hover {
  color: var(--yellow);
  text-shadow: var(--glow-yellow);
}

.payout-panel-pct {
  color: var(--gray);
}

.payout-panel-amt {
  flex-shrink: 0;
  color: var(--yellow);
  letter-spacing: 0.02em;
}

.payout-panel-note,
.payout-panel-when {
  margin: 0.55rem 0 0;
  color: var(--gray);
  font-size: 0.72rem;
}

.payout-panel-when {
  display: flex;
  flex-direction: column;
  gap: 0.15rem;
}

.payout-panel-abs {
  color: var(--gray-dim);
}

.stat-pill:hover,
.card-stats .comment-count-link:hover,
.post-stats-bar .comment-count-link:hover,
.card-stats .reblog-btn:hover,
.post-stats-bar .reblog-btn:hover {
  border-color: var(--yellow);
}

.downvote-btn.stat-pill:hover,
.vote-count-btn.stat-pill[data-vote-dir="down"]:hover {
  border-color: var(--red-bright);
}

.vote-btn.stat-pill.is-voted,
.vote-btn.stat-pill.is-voted:hover {
  border-color: var(--yellow);
}

.downvote-btn.stat-pill.is-voted,
.downvote-btn.stat-pill.is-voted:hover,
.vote-count-btn.stat-pill[data-vote-dir="down"].is-voted,
.vote-count-btn.stat-pill[data-vote-dir="down"].is-voted:hover {
  border-color: var(--red-bright);
  color: var(--red-bright);
  text-shadow: var(--glow-red);
}

.vote-btn.is-rest:not(.is-confirming),
.vote-btn.is-rest:not(.is-confirming):hover,
.downvote-btn.is-rest:not(.is-confirming),
.downvote-btn.is-rest:not(.is-confirming):hover {
  color: inherit;
  text-shadow: none;
}

.zap-stat-btn.stat-pill {
  appearance: none;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex: 0 0 auto;
  width: 2.45rem;
  min-width: 2.45rem;
  height: 2.45rem;
  margin: 0;
  padding: 0;
  color: var(--gray);
  cursor: pointer;
  touch-action: manipulation;
}

.zap-stat-btn .zap-mark {
  display: block;
  width: 1.2rem;
  height: 1.2rem;
}

.zap-stat-btn:hover,
.zap-stat-btn.is-open,
.zap-stat-btn.is-zapped {
  color: var(--yellow);
  border-color: var(--yellow);
}

.zap-stat-btn:hover .zap-mark,
.zap-stat-btn.is-open .zap-mark,
.zap-stat-btn.is-zapped .zap-mark {
  filter: drop-shadow(0 0 5px rgba(255, 225, 74, 0.95));
}

.zap-stat-btn:focus-visible {
  outline: 1px solid var(--yellow);
  outline-offset: 2px;
}

.zap-stat-btn.is-zapping,
.profile-zap-btn.is-zapping {
  color: var(--gray);
  border-color: var(--border);
}

.zap-stat-btn.is-zapping .zap-mark {
  filter: none;
}

.zap-stat-btn.is-zapping.is-zap-blink,
.profile-zap-btn.is-zapping.is-zap-blink,
.zap-stat-btn.is-zap-flash,
.profile-zap-btn.is-zap-flash {
  color: var(--yellow);
  border-color: var(--yellow);
}

.zap-stat-btn.is-zapping.is-zap-blink .zap-mark,
.profile-zap-btn.is-zapping.is-zap-blink .zap-mark,
.zap-stat-btn.is-zap-flash .zap-mark,
.profile-zap-btn.is-zap-flash .zap-mark {
  filter: drop-shadow(0 0 7px rgba(255, 225, 74, 0.95));
}

.zap-stat-btn.is-zap-strobe,
.profile-zap-btn.is-zap-strobe {
  transition: none;
}

.vote-btn.stat-pill.is-rest:not(.is-confirming),
.vote-btn.stat-pill.is-rest:not(.is-confirming):hover,
.downvote-btn.stat-pill.is-rest:not(.is-confirming),
.downvote-btn.stat-pill.is-rest:not(.is-confirming):hover,
.vote-count-btn.stat-pill[data-vote-dir="down"].is-rest,
.vote-count-btn.stat-pill[data-vote-dir="down"].is-rest:hover {
  border-color: var(--border);
  color: inherit;
  text-shadow: none;
}

.vote-count {
  display: inline-flex;
  align-items: center;
  gap: 0.25rem;
}

.downvote-weight {
  cursor: default;
}

.downvote-weight .vote-weight-value {
  color: var(--red-bright);
  text-shadow: var(--glow-red);
}

.downvote-confirm {
  appearance: none;
  flex-shrink: 0;
  margin-left: 0.15rem;
  padding: 0.28rem 0.6rem;
  border: 1px solid var(--red-bright);
  border-radius: 4px;
  background: rgba(227, 19, 55, 0.22);
  color: #fff;
  font-family: var(--font-display);
  font-size: 0.58rem;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  cursor: pointer;
  line-height: 1.2;
  box-shadow: var(--glow-red);
  transition: filter 0.15s, background 0.15s;
}

.downvote-confirm:hover {
  filter: brightness(1.12);
  background: rgba(227, 19, 55, 0.38);
  color: #fff;
  text-shadow: none;
}

.downvote-confirm:focus-visible {
  outline: 1px solid var(--yellow);
  outline-offset: 2px;
}

.vote-voters-panel {
  min-width: 12.5rem;
  max-width: 18rem;
  overflow-x: hidden;
  overflow-y: auto;
  overscroll-behavior: contain;
  touch-action: pan-y;
  padding: 0 0 0.45rem;
  border: 1px solid var(--border-hot);
  border-radius: var(--radius);
  background: var(--bg-panel-opaque);
  backdrop-filter: blur(8px);
  box-shadow: var(--glow-red), 0 8px 24px rgba(0, 0, 0, 0.4);
  scrollbar-width: thin;
}

.vote-voters-caption {
  position: sticky;
  top: 0;
  z-index: 2;
  font-family: var(--font-display);
  font-size: 0.58rem;
  font-weight: 700;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--gray);
  padding: 0.7rem 0.75rem 0.45rem;
  background: var(--bg-panel-opaque);
  box-shadow: 0 4px 0 var(--bg-panel-opaque);
}

.vote-voters-status,
.vote-voters-more {
  font-family: var(--font-mono);
  font-size: 0.72rem;
  color: var(--gray-dim);
  padding: 0.2rem 0.75rem 0.35rem;
}

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

.vote-voter {
  display: flex;
  align-items: center;
  gap: 0.45rem;
  padding: 0.28rem 0.75rem;
  color: var(--text);
  text-shadow: none;
}

.vote-voter:hover {
  color: var(--yellow);
  text-shadow: var(--glow-yellow);
  background: rgba(227, 19, 55, 0.12);
}

.vote-voters-panel.is-down .vote-voter:hover {
  color: var(--red-bright);
  text-shadow: var(--glow-red);
}

.vote-voter-name {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  font-family: var(--font-mono);
}

.vote-voter-payout {
  margin-left: auto;
  flex-shrink: 0;
  font-family: var(--font-mono);
  font-size: 0.72rem;
  letter-spacing: 0.04em;
  color: var(--yellow);
  text-shadow: var(--glow-yellow);
  white-space: nowrap;
}

.vote-voter-payout.is-pending {
  color: var(--gray-dim);
  text-shadow: none;
}

.vote-voters-panel.is-down .vote-voter-payout {
  color: var(--red-bright);
  text-shadow: var(--glow-red);
}

.zap-tips-panel:focus {
  outline: none;
}

.zap-tips-panel {
  min-width: 14rem;
  max-width: 20rem;
  overflow-x: hidden;
  overflow-y: auto;
  overscroll-behavior: contain;
  touch-action: pan-y;
  padding: 0 0 0.45rem;
  border: 1px solid var(--border-hot);
  border-radius: var(--radius);
  background: var(--bg-panel-opaque);
  backdrop-filter: blur(8px);
  box-shadow: var(--glow-red), 0 8px 24px rgba(0, 0, 0, 0.4);
  scrollbar-width: thin;
}

.zap-tips-head {
  position: sticky;
  top: 0;
  z-index: 2;
  background: var(--bg-panel-opaque);
  box-shadow: 0 4px 0 var(--bg-panel-opaque);
}

.zap-tips-accept {
  margin: 0;
  padding: 0.7rem 0.75rem 0.15rem;
  font-family: var(--font-mono);
  font-size: 0.78rem;
  color: var(--yellow);
  text-shadow: var(--glow-yellow);
}

.zap-tips-caption {
  font-family: var(--font-display);
  font-size: 0.58rem;
  font-weight: 700;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--gray);
  padding: 0.65rem 0.75rem 0.35rem;
}

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

.zap-tip {
  display: flex;
  align-items: center;
  gap: 0.45rem;
  padding: 0.28rem 0.75rem;
  color: var(--text);
}

.zap-tip-name {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  font-family: var(--font-mono);
}

.zap-tip-amount {
  margin-left: auto;
  flex-shrink: 0;
  font-family: var(--font-mono);
  font-size: 0.72rem;
  letter-spacing: 0.04em;
  color: var(--yellow);
  text-shadow: var(--glow-yellow);
  white-space: nowrap;
}

.zap-tips-status {
  font-family: var(--font-mono);
  font-size: 0.72rem;
  color: var(--gray-dim);
  padding: 0.2rem 0.75rem 0.35rem;
}

/* Nav */
.feed-nav {
  display: flex;
  gap: 0.5rem;
  margin-bottom: 1.75rem;
  flex-wrap: wrap;
}

.feed-nav a {
  font-family: var(--font-display);
  font-size: 0.68rem;
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--gray);
  padding: 0.6rem 1.05rem;
  border: 1px solid transparent;
  border-radius: var(--radius);
}

.feed-nav a:hover {
  color: var(--yellow);
  text-shadow: none;
}

.feed-nav a.is-active {
  color: var(--yellow);
  border-color: var(--border-hot);
  background: rgba(227, 19, 55, 0.1);
  text-shadow: var(--glow-yellow);
}

.feed-hint {
  font-family: var(--font-mono);
  font-size: 0.75rem;
  letter-spacing: 0.04em;
  color: var(--gray);
  margin: 0 0 1.75rem;
}

/* Panels / banners */
.panel {
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1.75rem 1.6rem;
  margin-bottom: 1.75rem;
  backdrop-filter: blur(8px);
  box-shadow:
    0 0 0 1px rgba(227, 19, 55, 0.08),
    0 12px 40px rgba(0, 0, 0, 0.45);
  position: relative;
  overflow: hidden;
}

.error-banner {
  position: fixed;
  z-index: 80;
  /* Clear the glow. A translate on this box, or a blur on it, paints the
     top edge above the viewport once the page has scrolled. */
  top: max(1.5rem, env(safe-area-inset-top, 0px));
  left: 0;
  right: 0;
  width: min(36rem, calc(100% - 2rem));
  margin-inline: auto;
  display: flex;
  align-items: flex-start;
  gap: 0.75rem;
  padding: 1.1rem 1.25rem;
  border-radius: var(--radius);
  font-family: var(--font-mono);
  font-size: 0.9rem;
  line-height: 1.45;
  text-align: left;
  color: var(--red-bright);
  cursor: pointer;
  overflow-wrap: anywhere;
  animation: error-banner-in 0.18s ease-out;
}

.error-banner::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  border-radius: inherit;
  background:
    linear-gradient(rgba(227, 19, 55, 0.18), rgba(227, 19, 55, 0.18)),
    rgba(7, 7, 7, 0.94);
  border: 1px solid var(--red);
  box-shadow: var(--glow-red), 0 16px 40px rgba(0, 0, 0, 0.55);
  backdrop-filter: blur(8px);
  pointer-events: none;
}

@keyframes error-banner-in {
  from { opacity: 0; }
  to { opacity: 1; }
}

@media (prefers-reduced-motion: reduce) {
  .error-banner {
    animation: none;
  }
}

.error-icon {
  flex-shrink: 0;
}

/* Feed cards */
.feed {
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
  min-width: 0;
}

.feed:not(:empty) {
  margin-bottom: 2rem;
}

.feed-item {
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
  min-width: 0;
  max-width: 100%;
}

.feed-share {
  display: flex;
  flex-direction: column;
  gap: 0.2rem;
  margin: 0 0.2rem;
  font-family: var(--font-mono);
  font-size: 0.82rem;
  line-height: 1.35;
  color: var(--gray-dim);
}

.feed-share-line {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  min-width: 0;
}

.feed-share-icon {
  width: 1.15em;
  height: 1.15em;
  flex: 0 0 auto;
  display: block;
  overflow: visible;
  color: inherit;
  shape-rendering: geometricPrecision;
}

.feed-share a {
  color: var(--gray);
  text-shadow: none;
  white-space: nowrap;
}

.feed-share a:hover {
  color: var(--yellow);
  text-shadow: var(--glow-yellow);
}

.post-card {
  display: flex;
  flex-direction: column;
  gap: 0.85rem;
  width: 100%;
  min-width: 0;
  padding: 1.7rem 1.55rem 1.45rem;
  border: 1px solid var(--border);
  border-radius: 12px;
  text-decoration: none;
  color: inherit;
  position: relative;
  overflow: hidden;
  transition: border-color 0.2s, box-shadow 0.2s;
}

.card-hit {
  display: flex;
  flex-direction: column;
  gap: 0.85rem;
  min-width: 0;
  width: 100%;
  text-decoration: none;
  color: inherit;
}

.card-hit:hover {
  color: inherit;
  text-shadow: none;
}

.card-hit::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 0;
}

.post-card:hover,
.post-card:focus {
  border-color: var(--red-bright);
  box-shadow: 0 0 0 1px rgba(227, 19, 55, 0.25), var(--glow-red);
  outline: none;
}

.post-card:hover::after {
  opacity: 1;
}

.post-card.is-muted {
  padding: 1.15rem 1.35rem;
  gap: 0.65rem;
}

.post-card.is-muted:hover {
  border-color: var(--border);
  box-shadow: none;
}

.post-card.is-muted:hover::after {
  opacity: 0;
}

.muted-notice {
  position: relative;
  z-index: 1;
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 0.45rem 0.75rem;
  margin: 0;
  min-width: 0;
  font-family: var(--font-body);
  font-size: 1.05rem;
  line-height: 1.5;
  color: var(--gray-dim);
}

.muted-notice > span {
  min-width: 0;
}

.show-muted {
  flex: 0 0 auto;
  margin: 0;
  padding: 0;
  border: 0;
  background: transparent;
  font: inherit;
  letter-spacing: inherit;
  color: var(--gray);
  cursor: pointer;
}

.show-muted:hover,
.show-muted:focus-visible {
  color: var(--yellow);
}

.show-muted:focus {
  outline: none;
}

.show-muted:focus-visible {
  outline: 1px solid var(--yellow);
  outline-offset: 2px;
}

.comment.is-muted {
  padding-top: 0.85rem;
}

.comment.is-muted .muted-notice {
  margin: 0;
}

.comment.is-muted:has(.comment-replies) .muted-notice {
  margin: 0 0 0.35rem;
}

.post-content {
  flex: 1;
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.card-meta {
  position: relative;
  z-index: 1;
  display: flex;
  align-items: center;
  gap: 0.55rem;
  flex-wrap: wrap;
  min-width: 0;
  font-family: var(--font-mono);
  font-size: 0.82rem;
  color: var(--gray);
  line-height: 1.2;
}

.card-meta a {
  color: var(--gray);
  text-shadow: none;
}

.card-meta .author-link:hover,
.card-meta .author-link:hover .author-name {
  color: var(--yellow);
  text-shadow: var(--glow-yellow);
}

.meta-sep {
  color: var(--red-dim);
}

.meta-time {
  position: relative;
  color: var(--gray-dim);
}

.card-meta a.meta-time,
.article-byline a.meta-time,
.comment-head a.meta-time {
  color: var(--gray-dim);
  text-shadow: none;
}

.card-meta a.meta-time:hover,
.article-byline a.meta-time:hover,
.comment-head a.meta-time:hover {
  color: var(--yellow);
  text-shadow: var(--glow-yellow);
}

.card-meta .meta-time {
  margin-left: auto;
}

.meta-time-pop {
  position: absolute;
  left: 50%;
  bottom: calc(100% + 0.45rem);
  z-index: 8;
  padding: 0.28rem 0.55rem;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--bg-hint);
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.45);
  color: var(--text);
  font-family: var(--font-mono);
  font-size: 0.72rem;
  letter-spacing: 0.02em;
  line-height: 1.2;
  white-space: nowrap;
  transform: translateX(-50%);
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transition: opacity 0.12s ease, visibility 0.12s ease;
  transition-delay: 0s;
}

.meta-time:hover .meta-time-pop {
  opacity: 1;
  visibility: visible;
  transition-delay: 1s;
}

.meta-time:focus-visible .meta-time-pop {
  opacity: 1;
  visibility: visible;
  transition-delay: 0s;
}

.post-card:has(.meta-time:hover),
.post-card:has(.meta-time:focus-visible) {
  overflow: visible;
  z-index: 8;
}

.avatar {
  display: block;
  flex-shrink: 0;
  width: 28px;
  height: 28px;
  border-radius: 50%;
  object-fit: cover;
  background: var(--bg-avatar);
}

.author-link {
  display: inline-flex;
  align-items: center;
  gap: 0.55rem;
  flex-shrink: 0;
  min-width: 0;
  color: var(--gray);
  text-shadow: none;
}

.author-link:hover,
.author-link:hover .author-name {
  color: var(--yellow);
  text-shadow: var(--glow-yellow);
}

.community {
  color: var(--gray);
  border: 1px solid rgba(211, 211, 211, 0.28);
  padding: 0.12rem 0.55rem;
  border-radius: 999px;
  font-size: 0.72rem;
  letter-spacing: 0.06em;
}

a.community {
  color: var(--gray);
  text-shadow: none;
}

a.community:hover {
  color: var(--yellow);
  border-color: var(--yellow);
  text-shadow: none;
}

.post-card h2 {
  font-family: var(--font-serif);
  font-weight: 400;
  font-size: 2rem;
  line-height: 1.28;
  letter-spacing: -0.02em;
  color: var(--yellow);
  margin: 0;
  overflow-wrap: break-word;
}

.post-card:hover h2 {
  color: var(--yellow);
  text-shadow: var(--glow-yellow);
}

.card-excerpt {
  font-family: var(--font-body);
  font-size: 1.05rem;
  line-height: 1.55;
  color: var(--gray);
  overflow-wrap: break-word;
}

.card-excerpt-clamp {
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
  position: relative;
  z-index: 1;
  cursor: pointer;
}

.card-excerpt-pre-wrap {
  white-space: pre-wrap;
}

.card-excerpt a {
  position: relative;
  z-index: 1;
}

.card-excerpt a.mention {
  color: var(--gray);
}

.card-excerpt a.mention:hover {
  color: var(--yellow);
}

/* Profile comment and reply cards. Same treatment as a link in .comment-body. */
.card-excerpt-comment a {
  color: var(--gray);
  text-decoration: none;
  text-underline-offset: 0.18em;
}

.card-excerpt-comment a:hover {
  color: var(--yellow);
  text-decoration: underline;
}

.card-thumb-link {
  display: block;
  position: relative;
  z-index: 1;
  line-height: 0;
}

.post-card > .poll {
  position: relative;
  z-index: 1;
}

.post-card.has-poll > .card-excerpt:empty {
  display: none;
}

.card-thumb-link:hover {
  text-shadow: none;
}

.card-video {
  position: relative;
  z-index: 1;
  width: 100%;
  min-width: 0;
  line-height: 0;
}

.post-card .embed {
  position: relative;
  width: 100%;
  padding-bottom: 56.25%;
  height: 0;
  margin: 0;
}

.post-card .embed iframe,
.post-card .embed video {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  border: 1px solid var(--border);
  border-radius: 8px;
}

.card-stats {
  position: relative;
  z-index: 1;
  display: flex;
  align-items: center;
  gap: 1.5rem;
  font-family: var(--font-mono);
  font-size: 1rem;
  color: var(--gray);
  margin-top: 0.25rem;
}

.card-stats .payout {
  color: var(--yellow);
  font-weight: 500;
}

.card-stats .comment-count-link,
.post-stats-bar .comment-count-link {
  display: inline-flex;
  align-items: center;
  min-height: 2.45rem;
  padding: 0.45rem 0.95rem;
  border: 1px solid var(--border);
  border-radius: 999px;
  line-height: 1;
  transition: color 0.15s, text-shadow 0.15s, border-color 0.15s;
}

.comment-count-link {
  color: inherit;
}

.comment-count-link:hover {
  color: var(--yellow);
  text-shadow: var(--glow-yellow);
}

.reblog-wrap {
  position: relative;
  z-index: 2;
  display: inline-flex;
  align-items: center;
}

.reblog-wrap.is-open {
  z-index: 20;
}

.reblog-btn {
  appearance: none;
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  margin: 0;
  min-height: 2.45rem;
  padding: 0.45rem 0.95rem;
  border: 1px solid var(--border);
  border-radius: 999px;
  background: transparent;
  font: inherit;
  letter-spacing: inherit;
  color: inherit;
  cursor: pointer;
  line-height: 1;
  touch-action: manipulation;
  user-select: none;
  transition: color 0.15s, text-shadow 0.15s, border-color 0.15s, opacity 0.15s;
}

.reblog-btn:hover {
  color: var(--yellow);
  text-shadow: var(--glow-yellow);
}

.reblog-btn:focus-visible {
  outline: 1px solid var(--yellow);
  outline-offset: 2px;
}

.reblog-btn.is-reblogged,
.reblog-btn.is-reblogged:hover {
  color: var(--yellow);
  text-shadow: var(--glow-yellow);
  border-color: var(--yellow);
}

.reblog-btn.is-pending {
  opacity: 0.65;
  cursor: wait;
}

.reblog-icon {
  width: 1.15em;
  height: 1.15em;
  flex: 0 0 auto;
  display: block;
  overflow: visible;
  color: inherit;
  shape-rendering: geometricPrecision;
}

.reblog-confirm-panel:focus {
  outline: none;
}

.reblog-confirm-panel {
  min-width: 13.5rem;
  max-width: 18rem;
  padding: 0.7rem 0.75rem 0.65rem;
  border: 1px solid var(--border-hot);
  border-radius: var(--radius);
  background: var(--bg-panel-opaque);
  backdrop-filter: blur(8px);
  box-shadow: var(--glow-red), 0 8px 24px rgba(0, 0, 0, 0.4);
}

.reblog-confirm-caption {
  font-family: var(--font-display);
  font-size: 0.58rem;
  font-weight: 700;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--gray);
  margin: 0 0 0.45rem;
}

.reblog-confirm-status {
  font-family: var(--font-mono);
  font-size: 0.72rem;
  color: var(--gray);
  line-height: 1.4;
  margin: 0 0 0.55rem;
}

.reblog-confirm-status.is-warn {
  color: var(--yellow);
}

.reblog-confirm-actions {
  display: flex;
  gap: 0.45rem;
  flex-wrap: wrap;
  align-items: center;
}

.reblog-confirm,
.reblog-cancel,
.reblog-list {
  appearance: none;
  flex-shrink: 0;
  padding: 0.28rem 0.6rem;
  border-radius: 4px;
  font-family: var(--font-display);
  font-size: 0.58rem;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  cursor: pointer;
  line-height: 1.2;
  white-space: nowrap;
  transition: filter 0.15s, background 0.15s, color 0.15s, opacity 0.15s;
}

.reblog-confirm {
  border: 1px solid var(--yellow);
  background: var(--yellow);
  color: #140f04;
  box-shadow: var(--glow-yellow);
}

.reblog-confirm:hover:not(:disabled) {
  filter: brightness(1.08);
  color: #140f04;
  text-shadow: none;
}

.reblog-confirm:disabled {
  opacity: 0.45;
  cursor: default;
  filter: none;
  box-shadow: none;
}

.reblog-cancel,
.reblog-list {
  border: 1px solid var(--border);
  background: transparent;
  color: var(--gray);
}

.reblog-list {
  display: none;
}

.reblog-cancel:hover,
.reblog-list:hover {
  color: var(--yellow);
  border-color: var(--yellow);
  text-shadow: var(--glow-yellow);
}

.reblog-confirm:focus-visible,
.reblog-cancel:focus-visible,
.reblog-list:focus-visible {
  outline: 1px solid var(--yellow);
  outline-offset: 2px;
}

.card-thumb {
  width: 100%;
  max-width: 100%;
  min-width: 0;
  height: auto;
  object-fit: contain;
  border-radius: 8px;
  border: 1px solid var(--border);
  display: block;
}

.nsfw-hold {
  position: relative;
  z-index: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 0.85rem;
  width: 100%;
  box-sizing: border-box;
  margin: 1.75rem auto;
  padding: 1.35rem 1rem;
  border: 1px solid var(--border);
  border-radius: 8px;
  text-align: center;
  min-height: 11.5rem;
}

.nsfw-hold-post {
  min-height: 12rem;
}

.post-card > .nsfw-hold {
  margin: 0;
}

.nsfw-hold.is-portrait {
  margin-left: auto;
  margin-right: auto;
}

.post-card > .nsfw-hold.is-portrait {
  margin-left: auto;
  margin-right: auto;
}

.nsfw-hold-label {
  margin: 0;
  font-family: var(--font-serif);
  font-weight: 400;
  font-size: 1.85rem;
  line-height: 1;
  letter-spacing: 0.04em;
  text-transform: none;
  color: var(--gray);
}

.nsfw-hold-actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 0.55rem 0.85rem;
}

.nsfw-reveal,
.nsfw-always {
  appearance: none;
  margin: 0;
  padding: 0.42rem 0.8rem;
  border: 1px solid var(--border);
  border-radius: 999px;
  background: transparent;
  color: var(--gray);
  font-family: var(--font-mono);
  font-size: 0.78rem;
  letter-spacing: 0.02em;
  line-height: 1.2;
  text-transform: none;
  cursor: pointer;
}

.nsfw-reveal:hover,
.nsfw-always:hover {
  color: var(--yellow);
  border-color: var(--yellow);
  text-shadow: var(--glow-yellow);
}

.nsfw-reveal:focus-visible,
.nsfw-always:focus-visible {
  outline: 1px solid var(--yellow);
  outline-offset: 2px;
}

.feed-actions {
  display: flex;
  justify-content: center;
  margin: 2.5rem 0 0.5rem;
}

.feed-actions:not(:has(button:not([hidden]))) {
  display: none;
  margin: 0;
}

.btn-primary {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.75rem;
  padding: 0.95rem 1.6rem;
  background: linear-gradient(135deg, #c4102e 0%, var(--red) 40%, #ff2a4d 100%);
  border: 1px solid var(--red-bright);
  border-radius: 999px;
  color: #fff;
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 0.8rem;
  letter-spacing: 0.2em;
  cursor: pointer;
  text-transform: uppercase;
  box-shadow: var(--glow-red), inset 0 1px 0 rgba(255, 255, 255, 0.15);
  transition: transform 0.15s, box-shadow 0.2s, filter 0.2s;
}

.btn-primary:hover:not(:disabled) {
  transform: translateY(-1px);
  filter: brightness(1.1);
  color: #fff;
  text-shadow: none;
  box-shadow: 0 0 28px rgba(255, 42, 77, 0.65), inset 0 1px 0 rgba(255, 255, 255, 0.2);
}

.btn-primary:active:not(:disabled) {
  transform: translateY(1px);
}

.btn-primary:disabled {
  opacity: 0.65;
  cursor: wait;
}

.btn-compact {
  padding: 0.55rem 1rem;
  font-size: 0.68rem;
  letter-spacing: 0.14em;
}

.btn-loader {
  width: 42px;
  height: 42px;
  flex-shrink: 0;
  background: url("../assets/logo.svg") center / contain no-repeat;
  animation: spin 1.6s linear infinite;
}

@keyframes spin {
  to { transform: rotate(360deg); }
}

@media (prefers-reduced-motion: reduce) {
  .btn-loader {
    animation: none;
  }
}

.loading-row {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.75rem;
  padding: 3rem 1rem;
  font-family: var(--font-mono);
  color: var(--yellow);
  letter-spacing: 0.08em;
}

.loading-row.is-feed-more {
  padding: 0.35rem 1rem 1rem;
}

.empty-state {
  text-align: center;
  padding: 2.5rem 1.5rem;
  margin-bottom: 1.75rem;
}

.empty-state h2 {
  font-family: var(--font-display);
  font-size: 0.9rem;
  letter-spacing: 0.12em;
  color: var(--yellow);
  margin-bottom: 0.55rem;
}

.empty-state p {
  font-family: var(--font-mono);
  font-size: 0.85rem;
  color: var(--gray);
}

/* Article */
.article {
  max-width: var(--measure);
  margin: 0 auto;
  padding: 0.5rem 0 1rem;
}

.article-community {
  display: inline-block;
  font-family: var(--font-display);
  font-size: 0.65rem;
  font-weight: 700;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--gray);
  margin-bottom: 0.85rem;
  text-shadow: none;
}

a.article-community {
  color: var(--gray);
  text-shadow: none;
}

a.article-community:hover {
  color: var(--yellow);
  text-shadow: none;
}

.article h1 {
  font-family: var(--font-serif);
  font-weight: 400;
  font-size: clamp(2.15rem, 5.4vw, 3.35rem);
  line-height: 1.12;
  letter-spacing: -0.03em;
  color: var(--yellow);
  margin-bottom: 1.5rem;
  text-shadow: 0 0 24px rgba(255, 225, 74, 0.12);
  overflow-wrap: break-word;
}

.article h1 a,
.article h1 a:hover {
  color: inherit;
  text-shadow: inherit;
}

.article-byline {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  flex-wrap: wrap;
  font-family: var(--font-mono);
  font-size: 0.85rem;
  color: var(--gray);
  margin-bottom: 1.75rem;
  padding-bottom: 1.4rem;
  border-bottom: 1px solid var(--border);
  position: relative;
  z-index: 5;
}

.article-byline .avatar {
  width: 40px;
  height: 40px;
}

.article-byline a {
  color: var(--gray);
}

.article-byline .author-link {
  gap: 0.75rem;
}

.article-stats {
  display: flex;
  align-items: center;
  gap: 1.15rem;
  margin-left: auto;
  color: var(--gray);
  position: relative;
  z-index: 6;
}

.article-stats .payout {
  appearance: none;
  display: inline-flex;
  align-items: center;
  border: none;
  background: transparent;
  padding: 0;
  font: inherit;
  letter-spacing: inherit;
  color: var(--yellow);
  cursor: pointer;
  line-height: inherit;
  touch-action: manipulation;
  user-select: none;
}

.article-stats .payout:hover {
  color: var(--yellow);
  text-shadow: var(--glow-yellow);
}

.article-stats .payout:focus-visible {
  outline: 1px solid var(--yellow);
  outline-offset: 2px;
}

.article-stats .comment-count-link {
  color: var(--gray);
}

.article-stats .comment-count-link:hover {
  color: var(--yellow);
}

.tags {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin-bottom: 2.25rem;
}

.tag {
  font-family: var(--font-mono);
  font-size: 0.72rem;
  letter-spacing: 0.06em;
  color: var(--gray);
  border: 1px solid rgba(211, 211, 211, 0.28);
  border-radius: 999px;
  padding: 0.28rem 0.75rem;
  text-decoration: none;
  transition: color 0.15s ease, border-color 0.15s ease;
}

a.tag:hover {
  color: var(--yellow);
  border-color: var(--yellow);
  background: transparent;
}

.tag-feed-head {
  margin-bottom: 0.75rem;
}

.tag-feed-title {
  font-family: var(--font-mono);
  font-size: 1.35rem;
  font-weight: 600;
  letter-spacing: 0.04em;
  color: var(--yellow);
  margin: 0 0 0.25rem;
}

.tags-page {
  padding-top: 0.15rem;
}

.tags-page-title {
  font-family: var(--font-display);
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--yellow);
  margin: 0 0 0.45rem;
}

.tags-page-title + .feed-hint {
  margin-bottom: 1rem;
}

.about,
.imprint {
  padding-top: 0.35rem;
}

.about-title,
.imprint-title,
.page-title {
  font-family: var(--font-serif);
  font-weight: 400;
  font-size: 2.4rem;
  line-height: 1.15;
  letter-spacing: -0.02em;
  color: var(--yellow);
  margin: 0 0 1.25rem;
}

.about p,
.imprint p {
  font-family: var(--font-body);
  font-size: 1.15rem;
  line-height: 1.65;
  color: var(--gray);
  margin: 0 0 1.15rem;
}

.about h3,
.imprint h3 {
  font-family: var(--font-display);
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--yellow);
  margin: 1.85rem 0;
  padding-top: 1.25rem;
  border-top: 1px solid var(--border);
}

.about h3 a {
  color: inherit;
}

.tags-fav-list,
.tags-suggest-list {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.5rem;
  margin-bottom: 1.15rem;
  min-height: 1.6rem;
}

.tags-empty {
  margin: 0;
}

.fav-tag-chip {
  display: inline-flex;
  align-items: center;
  gap: 0.15rem;
  padding: 0.12rem 0.28rem 0.12rem 0.15rem;
  border: 1px solid rgba(211, 211, 211, 0.28);
  border-radius: 999px;
}

.fav-tag-chip .tag {
  border: none;
  padding: 0.16rem 0.16rem 0.16rem 0.3rem;
}

.fav-tag-chip:hover {
  border-color: var(--yellow);
}

.fav-tag-chip:hover .tag {
  color: var(--yellow);
}

.fav-tag-remove,
.fav-tag-add {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 1.25rem;
  height: 1.25rem;
  margin-right: 0.15rem;
  padding: 0;
  border: none;
  border-radius: 50%;
  background: transparent;
  color: var(--gray-dim);
  font-size: 1rem;
  line-height: 1;
  cursor: pointer;
}

.fav-tag-remove:hover {
  color: var(--red-bright);
}

.fav-tag-add:hover {
  color: var(--yellow);
}

.tags-add {
  display: flex;
  gap: 0.6rem;
  align-items: center;
  margin-bottom: 1.75rem;
}

.tags-add input {
  flex: 1 1 auto;
  min-width: 0;
  padding: 0.7rem 0.9rem;
  background: var(--bg-input);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  color: var(--yellow);
  font-family: var(--font-mono);
  font-size: 1rem;
  outline: none;
}

.tags-add input:focus {
  border-color: var(--red-bright);
  box-shadow: 0 0 0 1px rgba(227, 19, 55, 0.35), var(--glow-red);
}

.tags-add input::placeholder {
  color: var(--gray-dim);
  opacity: 0.85;
}

.tags-add .btn-compact {
  flex-shrink: 0;
}

.search-form {
  position: relative;
  display: block;
}

.search-form input {
  width: 100%;
  padding-right: 2.85rem;
}

.tags-add.community-search-form {
  position: relative;
  display: block;
}

.community-search-form input {
  width: 100%;
  padding-right: 2.85rem;
}

.community-search-glass {
  position: absolute;
  top: 50%;
  right: 0.7rem;
  width: 1.45rem;
  height: 1.45rem;
  margin: 0;
  padding: 0;
  border: none;
  background: transparent;
  transform: translateY(-50%);
  color: var(--yellow);
  cursor: pointer;
  line-height: 0;
}

.community-search-glass:focus {
  outline: none;
}

.community-search-glass:focus-visible {
  outline: 1px solid var(--yellow);
  outline-offset: 2px;
}

.community-search-glass svg {
  display: block;
  width: 100%;
  height: 100%;
  overflow: visible;
  shape-rendering: geometricPrecision;
}

.community-search-glass .community-search-handle {
  stroke: var(--red-bright);
}

.tags-status {
  font-family: var(--font-mono);
  font-size: 0.82rem;
  color: var(--gray);
  margin: -1.15rem 0 1.5rem;
}

.tags-status.is-error {
  color: var(--red-bright);
}

.community-list {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
  margin-bottom: 1.15rem;
}

.community-list .tags-empty {
  margin: 0;
}

.community-list .loading-row {
  margin: 0.2rem 0;
}

.community-row {
  display: flex;
  align-items: center;
  gap: 0.55rem;
  padding: 0.5rem 0.55rem 0.5rem 0.5rem;
  border: 1px solid rgba(211, 211, 211, 0.28);
  border-radius: var(--radius);
}

.community-row:hover {
  border-color: var(--yellow);
}

.community-row.search-user-row,
.community-row.search-user-row:hover {
  border: none;
  border-radius: 0;
  padding-left: 0;
  padding-right: 0;
}

.community-row-main {
  display: flex;
  align-items: center;
  gap: 0.7rem;
  min-width: 0;
  flex: 1 1 auto;
  text-decoration: none;
  color: inherit;
}

.community-row-main .avatar {
  width: 32px;
  height: 32px;
  flex-shrink: 0;
}

.community-row-text {
  display: flex;
  flex-direction: column;
  min-width: 0;
  gap: 0.12rem;
}

.community-row-title {
  font-family: var(--font-serif);
  font-size: 1.05rem;
  font-weight: 400;
  letter-spacing: -0.01em;
  color: var(--yellow);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.community-row-main:hover .community-row-title {
  text-shadow: var(--glow-yellow);
}

.community-row-meta {
  font-family: var(--font-mono);
  font-size: 0.72rem;
  letter-spacing: 0.04em;
  color: var(--gray);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.community-fav-btn {
  flex-shrink: 0;
  padding: 0.38rem 0.7rem;
  border: none;
  background: transparent;
  color: var(--gray);
  font-family: var(--font-display);
  font-size: 0.62rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  white-space: nowrap;
  cursor: pointer;
}

.community-fav-btn:hover,
.community-fav-btn.is-saved {
  color: var(--yellow);
}

.tags-suggest-loading {
  padding: 0.75rem 0;
  width: 100%;
  justify-content: flex-start;
}

.post-body {
  font-family: var(--font-body);
  font-size: 1.22rem;
  line-height: 1.75;
  color: var(--gray);
  overflow-wrap: break-word;
  overflow: hidden;
  max-width: 100%;
  min-width: 0;
}

.post-body h1,
.post-body h2,
.post-body h3,
.post-body h4,
.post-body h5,
.post-body h6 {
  font-family: var(--font-serif);
  font-weight: 400;
  letter-spacing: -0.02em;
  color: var(--yellow);
  margin: 2.1rem 0 0.85rem;
  line-height: 1.2;
}

.post-body h1 { font-size: 2rem; }
.post-body h2 { font-size: 2rem; }
.post-body h3 { font-size: 1.8rem; }
.post-body h4 { font-size: 1.6rem; }
.post-body h5 { font-size: 1.4rem; }
.post-body h6 { font-size: 1.2rem; }

.post-body p,
.post-body ul,
.post-body ol,
.post-body blockquote,
.post-body pre {
  margin-bottom: 1.35rem;
}

.post-body ul,
.post-body ol {
  padding-left: 1.5rem;
}

.post-body a,
.comment-body a {
  text-decoration: none;
  text-underline-offset: 0.18em;
}

.post-body a {
  color: var(--yellow);
}

.comment-body a {
  color: var(--gray);
}

.post-body a:hover,
.comment-body a:hover {
  color: var(--yellow);
  text-decoration: underline;
}

.post-body img {
  display: block;
  margin: 1.75rem auto;
  border-radius: 6px;
  border: 1px solid var(--border);
}

.post-body blockquote {
  border-left: 3px solid var(--red-bright);
  padding: 0.35rem 0 0.35rem 1.2rem;
  color: var(--gray);
  font-style: italic;
}

.post-body hr,
.comment-body hr {
  border: none;
  height: 1px;
  width: 42%;
  max-width: 12rem;
  margin: 1.75rem auto;
  background: var(--border);
  opacity: 0.85;
}

.post-body pre,
.post-body code {
  font-family: var(--font-mono);
  font-size: 0.9em;
}

.post-body pre {
  background: var(--bg-input);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1.1rem 1.15rem;
  overflow-x: auto;
  color: var(--yellow);
}

.post-body code {
  background: rgba(255, 225, 74, 0.08);
  padding: 0.1em 0.35em;
  border-radius: 3px;
  color: var(--yellow);
}

.post-body pre code {
  background: none;
  padding: 0;
}

.post-body .md-table-scroll,
.comment-body .md-table-scroll {
  display: block;
  width: 100%;
  max-width: 100%;
  min-width: 0;
  margin: 0 0 1.5rem;
  overflow-x: auto;
  overflow-y: hidden;
  -webkit-overflow-scrolling: touch;
  overscroll-behavior-x: contain;
}

.post-body table,
.comment-body table {
  width: 100%;
  border-collapse: collapse;
  margin-bottom: 1.5rem;
  font-size: 0.95rem;
  background: transparent;
}

.post-body .md-table-scroll > table,
.comment-body .md-table-scroll > table {
  margin-bottom: 0;
}

.post-body th,
.post-body td,
.comment-body th,
.comment-body td {
  border: 1px solid var(--border);
  padding: 0.55rem 0.75rem;
  color: var(--gray);
  background: transparent;
}

.post-body th,
.comment-body th {
  color: var(--gray);
}

.post-body .embed {
  position: relative;
  padding-bottom: 56.25%;
  height: 0;
  margin: 1.75rem 0;
}

.post-body .embed.embed-portrait,
.comment-body .embed.embed-portrait,
.post-card .embed.embed-portrait {
  width: min(100%, 325px);
  height: auto;
  padding-bottom: 0;
  margin-left: auto;
  margin-right: auto;
  aspect-ratio: 9 / 16;
}

/* A phone screen is short, so a vertical video stays within the viewport.
   svh stays put when the browser chrome shows and hides. dvh tracked that
   chrome, so the frame grew and shrank while the reader scrolled past it. */
@media (max-width: 720px) {
  .post-body .embed.embed-portrait,
  .comment-body .embed.embed-portrait,
  .post-card .embed.embed-portrait {
    width: min(100%, calc(78svh * 9 / 16));
  }
}

.post-body .embed.embed-square,
.comment-body .embed.embed-square,
.post-card .embed.embed-square {
  height: auto;
  padding-bottom: 0;
  aspect-ratio: 1 / 1;
}

/* PeerTube's responsive share box. The ratio is the video's width / height. */
.post-body .embed.embed-ratio,
.comment-body .embed.embed-ratio,
.post-card .embed.embed-ratio {
  height: auto;
  padding-bottom: 0;
  aspect-ratio: var(--embed-ratio, 16 / 9);
}

.post-body .embed.embed-twitch,
.comment-body .embed.embed-twitch,
.post-card .embed.embed-twitch {
  padding-bottom: max(56.25%, 300px);
}

.post-stats-bar {
  display: flex;
  align-items: center;
  gap: 1.5rem;
  margin-top: 2.25rem;
  padding: 1rem 0;
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
  font-family: var(--font-mono);
  font-size: 1rem;
  color: var(--gray);
  position: relative;
  z-index: 5;
}

/* Same wrap on every viewport. A tight desktop column uses the same line break as a phone. */
.card-stats,
.post-stats-bar {
  flex-wrap: wrap;
  row-gap: 0.75rem;
  width: 100%;
  min-width: 0;
  max-width: 100%;
}

.card-stats > .vote-wrap,
.card-stats > .zap-stat-btn,
.card-stats > .comment-count-link,
.card-stats > .reblog-wrap,
.card-stats > .payout,
.card-stats > .content-more,
.post-stats-bar > .vote-wrap,
.post-stats-bar > .zap-stat-btn,
.post-stats-bar > .comment-count-link,
.post-stats-bar > .reblog-wrap,
.post-stats-bar > .payout,
.post-stats-bar > .content-more {
  flex-shrink: 0;
}

.post-stats-bar .payout {
  color: var(--yellow);
  font-weight: 500;
}

.post-body .embed iframe,
.comment-body .embed iframe,
.post-body .embed video,
.comment-body .embed video {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  border: 1px solid var(--border);
  border-radius: 4px;
}

.post-body .embed video,
.comment-body .embed video,
.post-card .embed video {
  object-fit: contain;
}

.comment-body .embed {
  position: relative;
  padding-bottom: 56.25%;
  height: 0;
  margin: 1rem 0;
}

.post-body .embed.embed-map,
.comment-body .embed.embed-map {
  padding-bottom: 0;
  height: 300px;
}

.post-body .tweet-embed,
.comment-body .tweet-embed {
  /* widgets.js inserts a 550px shell before the fallback blockquote and
     removes the blockquote only after the iframe paints. A flex row puts
     that shell and the fallback side by side, so "View on X" is squeezed
     into the leftover strip on the right. One grid cell stacks them. */
  display: grid;
  justify-items: center;
  width: 100%;
  margin: 1.35rem 0;
}

.post-body .tweet-embed > *,
.comment-body .tweet-embed > * {
  grid-area: 1 / 1;
  min-width: 0;
  max-width: 100%;
}

.comment-body .tweet-embed {
  margin: 1rem 0;
}

.post-body .tweet-embed blockquote.twitter-tweet,
.comment-body .tweet-embed blockquote.twitter-tweet {
  border-left: none;
  font-style: normal;
  padding: 0;
  margin: 0 auto;
  color: inherit;
}

/* widgets.js replaces the blockquote with a 550px box and only sets vertical
   margins, so a full-width column leaves the post stuck to the left edge. */
.post-body .tweet-embed > .twitter-tweet,
.comment-body .tweet-embed > .twitter-tweet,
.post-body .tweet-embed > iframe,
.comment-body .tweet-embed > iframe {
  margin-left: auto;
  margin-right: auto;
}

.post-body .tweet-embed iframe,
.comment-body .tweet-embed iframe {
  position: static;
  width: 100%;
  max-width: 550px;
  height: auto;
  border: 0;
  border-radius: 12px;
}

/* Imgur lays the post out at 540px. The wrapper clips that frame, and md.js
   scales it down when the column is narrower. */
.post-body .imgur-embed,
.comment-body .imgur-embed,
.post-card .imgur-embed {
  width: 100%;
  max-width: 540px;
  margin: 1.35rem auto;
  line-height: normal;
  overflow: hidden;
  border-radius: 8px;
}

.post-card .imgur-embed {
  position: relative;
  z-index: 1;
  margin: 0 auto;
}

.post-body .imgur-embed blockquote.imgur-embed-pub,
.comment-body .imgur-embed blockquote.imgur-embed-pub,
.post-card .imgur-embed blockquote.imgur-embed-pub {
  width: auto;
  max-width: 100%;
  margin: 0;
  padding: 0;
  border: 0;
  font-style: normal;
  color: inherit;
}

.imgur-embed iframe {
  display: block;
  width: 540px;
  max-width: none;
  border: 0;
  transform-origin: top left;
}

/* Comments */
.comments {
  margin-top: 2.25rem;
  padding-top: 0;
}

.comment {
  margin: 0 0 1.5rem;
  padding: 1.15rem 0 0.25rem;
  border-top: 1px solid rgba(42, 16, 32, 0.7);
  scroll-margin-top: 1.25rem;
}

.comment-list > .comment:first-child {
  border-top: none;
  padding-top: 0;
}

.comments > .comment-composer {
  margin-bottom: 0.4rem;
}

.comment-sort {
  position: relative;
  display: flex;
  justify-content: flex-end;
  margin: 0 0 0.85rem;
  z-index: 1;
}

.comment-sort.is-open {
  z-index: 5;
}

.comment-sort-btn {
  appearance: none;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 1.7rem;
  height: 1.7rem;
  margin: 0;
  padding: 0;
  border: none;
  background: transparent;
  color: var(--gray);
  cursor: pointer;
  line-height: 0;
}

.comment-sort-btn svg {
  width: 16px;
  height: 16px;
  display: block;
}

.comment-sort-btn:hover,
.comment-sort.is-open .comment-sort-btn {
  color: var(--yellow);
}

.comment-sort-btn:focus-visible {
  outline: 1px solid var(--yellow);
  outline-offset: 2px;
}

.comment-sort-menu {
  position: absolute;
  top: calc(100% + 0.3rem);
  right: 0;
  z-index: 2;
  display: flex;
  flex-direction: column;
  min-width: 8.5rem;
  background: var(--bg-panel);
  backdrop-filter: blur(8px);
  border: 1px solid var(--border-hot);
  border-radius: var(--radius);
  box-shadow: var(--glow-red), 0 12px 32px rgba(0, 0, 0, 0.45);
}

.comment-sort-item {
  appearance: none;
  display: flex;
  align-items: center;
  gap: 0.45rem;
  width: 100%;
  margin: 0;
  padding: 0.65rem 0.85rem;
  border: none;
  background: transparent;
  font-family: var(--font-display);
  font-size: 0.68rem;
  font-weight: 700;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  text-align: left;
  color: var(--gray);
  white-space: nowrap;
  cursor: pointer;
}

.comment-sort-item:hover,
.comment-sort-item:focus-visible,
.comment-sort-item.is-selected {
  color: var(--yellow);
  text-shadow: var(--glow-yellow);
}

.comment-sort-item:hover,
.comment-sort-item:focus-visible {
  background: rgba(227, 19, 55, 0.12);
}

.comment-sort-check {
  width: 0.85rem;
  height: 0.85rem;
  flex: 0 0 0.85rem;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.comment-sort-check svg {
  width: 0.85rem;
  height: 0.85rem;
  display: none;
}

.comment-sort-item.is-selected .comment-sort-check svg {
  display: block;
}

.comment-head {
  display: flex;
  align-items: center;
  gap: 0.55rem;
  flex-wrap: wrap;
  font-family: var(--font-mono);
  font-size: 0.8rem;
  color: var(--gray);
  margin-bottom: 0.65rem;
}

.comment-head a {
  color: var(--gray);
}

.comment-head a:hover {
  color: var(--yellow);
  text-shadow: var(--glow-yellow);
}

.comment-body {
  font-family: var(--font-body);
  font-size: 1.08rem;
  line-height: 1.62;
  color: var(--gray);
  overflow-wrap: break-word;
  /* flow-root keeps paragraph margins inside the body. overflow stays
     visible so a nested quote bar can sit on the thread line. */
  display: flow-root;
  overflow: visible;
  max-width: 100%;
  min-width: 0;
}

.comment-body p,
.comment-body ul,
.comment-body ol,
.comment-body h1,
.comment-body h2,
.comment-body h3,
.comment-body h4,
.comment-body h5,
.comment-body h6 {
  margin-bottom: 0.85rem;
}

/* A markdown heading in a comment is body copy. Title styles stay on the post. */
.comment-body h1,
.comment-body h2,
.comment-body h3,
.comment-body h4,
.comment-body h5,
.comment-body h6 {
  font: inherit;
  letter-spacing: inherit;
  color: inherit;
  text-transform: none;
  text-shadow: none;
}

.comment-body ul,
.comment-body ol {
  padding-left: 1.5rem;
}

.comment-body img {
  display: block;
  max-width: 100%;
  margin: 0.9rem 0;
  border-radius: 4px;
  border: 1px solid var(--border);
}

.comment-body pre {
  max-width: 100%;
  overflow-x: auto;
}

/* Citation bar. Gray and upright so a long reply stays readable.
   On a nested comment the bar is centered on that level's thread rule.
   A quote inside a quote stays indented and does not jump to the thread. */
.comment-body blockquote {
  --quote-bar: 3px;
  margin: 0 0 0.85rem;
  padding: 0.12rem 0 0.12rem 0.85rem;
  border-left: var(--quote-bar) solid var(--gray);
  color: var(--gray);
}

.comment-body blockquote > :first-child {
  margin-top: 0;
}

.comment-body blockquote > :last-child {
  margin-bottom: 0;
}

.comment-replies > .comment > .comment-body > blockquote {
  margin-left: calc(-1 * var(--thread-pad) - (var(--quote-bar) + 1px) / 2);
  padding-left: calc(var(--thread-pad) - (var(--quote-bar) - 1px) / 2);
}

.comment-replies {
  --thread-pad: 1.1rem;
  margin-left: 1.35rem;
  padding-left: var(--thread-pad);
  border-left: 1px solid rgba(211, 211, 211, 0.18);
}

.comment-actions {
  position: relative;
  z-index: 1;
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 1.5rem;
  margin: 0.55rem 0 0.45rem;
  font-family: var(--font-mono);
  font-size: 1rem;
  color: var(--gray);
}

.comment-actions .payout {
  color: var(--yellow);
  font-weight: 500;
}



.comment-reply-btn,
.composer-cancel {
  appearance: none;
  background: transparent;
  border: none;
  padding: 0.15rem 0;
  font-family: var(--font-display);
  font-size: 0.62rem;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--gray);
  cursor: pointer;
  opacity: 0.85;
}

.comment-reply-btn:hover,
.comment-reply-btn.is-open,
.composer-cancel:hover {
  color: var(--yellow);
  opacity: 1;
  text-shadow: var(--glow-yellow);
}

.comment-reply-slot,
.comment-edit-slot {
  margin: 0.65rem 0 0.85rem;
}

.comment-reply-slot .comment-composer,
.comment-edit-slot .comment-composer {
  margin: 0;
}

.comment-composer {
  position: relative;
  margin: 0 0 1.75rem;
  padding: 0.9rem;
  border: 1px solid var(--border);
  border-radius: var(--radius);
}

.comment-composer.is-dragover {
  border-color: var(--yellow);
  box-shadow: 0 0 0 1px rgba(255, 225, 74, 0.35), var(--glow-yellow);
}

.comment-composer.is-uploading,
.comment-composer.is-pending {
  opacity: 0.85;
}

.composer-drop-layer {
  display: none;
  position: absolute;
  inset: 0;
  z-index: 2;
  align-items: center;
  justify-content: center;
  pointer-events: none;
  border-radius: inherit;
  background: rgba(7, 7, 14, 0.82);
  border: 1px dashed var(--yellow);
  color: var(--yellow);
  font-family: var(--font-display);
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  text-shadow: var(--glow-yellow);
}

.comment-composer.is-dragover .composer-drop-layer {
  display: flex;
}

.composer-input {
  display: block;
  width: 100%;
  min-height: 6.5rem;
  resize: vertical;
  padding: 0.8rem 0.9rem;
  background: var(--bg-input);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  color: var(--text);
  font-family: var(--font-body);
  font-size: 1.05rem;
  line-height: 1.55;
  outline: none;
}

.composer-input:focus {
  border-color: var(--red-bright);
  box-shadow: 0 0 0 1px rgba(227, 19, 55, 0.35), var(--glow-red);
}

.composer-input::placeholder {
  color: var(--gray-dim);
  font-family: var(--font-mono);
  font-size: 0.85rem;
}

.composer-bar {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  flex-wrap: wrap;
  margin-top: 0.75rem;
}

.composer-attach {
  appearance: none;
  background: transparent;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 0.45rem 0.75rem;
  font-family: var(--font-display);
  font-size: 0.58rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--gray);
  cursor: pointer;
}

.composer-attach:hover {
  color: var(--yellow);
  border-color: var(--border-hot);
}

.composer-hint {
  flex: 1 1 8rem;
  font-family: var(--font-mono);
  font-size: 0.72rem;
  color: var(--gray-dim);
}

.composer-bar .composer-actions {
  margin-left: auto;
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.composer-status {
  margin-top: 0.65rem;
  font-family: var(--font-mono);
  font-size: 0.78rem;
  color: var(--gray);
}

.composer-status.is-error {
  color: var(--red-bright);
}

/* Profile */
.profile-banner {
  position: relative;
  width: 100vw;
  margin-left: calc(50% - 50vw);
  margin-bottom: 1.25rem;
  padding: 2.5rem 1.75rem 2.25rem;
  overflow: hidden;
  border-bottom: 1px solid var(--border);
}

.profile-head {
  position: relative;
  z-index: 1;
  display: flex;
  gap: 1.5rem;
  align-items: flex-start;
  width: 100%;
  max-width: 600px;
  margin: 0 auto;
}

.profile-head > div {
  flex: 1;
  min-width: 0;
}

.profile-head .avatar {
  width: 96px;
  height: 96px;
}

.profile-head h1 {
  font-family: var(--font-serif);
  font-size: clamp(1.9rem, 4vw, 2.6rem);
  font-weight: 400;
  letter-spacing: -0.02em;
  color: var(--yellow);
}

.profile-title-line {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 0.55rem;
}

.profile-handle {
  font-family: var(--font-mono);
  color: var(--red-bright);
  margin: 0.35rem 0 0.75rem;
}

.profile-handle a,
.profile-handle a:hover {
  color: inherit;
  text-shadow: none;
}

.profile-about {
  font-family: var(--font-body);
  font-size: 1.12rem;
  line-height: 1.55;
  color: var(--text);
}

.profile-website,
.profile-location {
  margin-top: 0.75rem;
  font-family: var(--font-mono);
  font-size: 0.78rem;
  line-height: 1.45;
  color: var(--gray);
  overflow-wrap: anywhere;
}

.profile-handle + .profile-website,
.profile-handle + .profile-location {
  margin-top: 0;
}

.profile-stats {
  display: flex;
  flex-wrap: wrap;
  gap: 1.25rem;
  margin-top: 1rem;
  font-family: var(--font-mono);
  font-size: 0.78rem;
  color: var(--gray);
}

.profile-stats .profile-joined {
  color: inherit;
}

.profile-stats button.profile-follower-count,
.profile-stats button.profile-following-count,
.profile-stats button.community-sub-count {
  appearance: none;
  -webkit-appearance: none;
  background: none;
  border: 0;
  padding: 0;
  font: inherit;
  letter-spacing: inherit;
  color: inherit;
  text-shadow: none;
  cursor: pointer;
}

.profile-stats button.profile-follower-count:hover,
.profile-stats button.profile-following-count:hover,
.profile-stats button.community-sub-count:hover,
.profile-stats button.profile-follower-count.is-active,
.profile-stats button.profile-following-count.is-active,
.profile-stats button.community-sub-count.is-active {
  color: var(--yellow);
  text-shadow: var(--glow-yellow);
}

.follow-list {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  column-gap: 1.25rem;
  row-gap: 0.35rem;
  max-width: 600px;
  margin: 0 auto;
}

.follow-account {
  display: flex;
  align-items: center;
  gap: 0.55rem;
  min-width: 0;
  padding: 0.28rem 0;
  color: var(--text);
  text-shadow: none;
  font-family: var(--font-mono);
  font-size: 0.82rem;
  line-height: 1.2;
}

.follow-account .avatar {
  width: 28px;
  height: 28px;
  flex: 0 0 28px;
}

.follow-account span {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.follow-account:hover {
  color: var(--yellow);
  text-shadow: var(--glow-yellow);
}

.profile-banner:has(.profile-joined:hover) {
  overflow: visible;
  z-index: 2;
}

.is-profile .feed-nav,
.is-profile .wallet-page,
.is-profile .community-about,
.is-profile .feed-actions,
.is-profile .loading-row,
.is-profile .empty-state,
.is-community .feed-nav,
.is-community .community-panel,
.is-community .feed-actions,
.is-community .loading-row,
.is-community .empty-state {
  max-width: 600px;
  margin-left: auto;
  margin-right: auto;
}

.community-banner {
  margin-bottom: 1.25rem;
}

.profile-head-actions,
.community-head-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.75rem;
  margin-top: 1.15rem;
}

.profile-more {
  position: relative;
  display: inline-flex;
  flex: 0 0 auto;
}

.profile-more-btn {
  appearance: none;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  margin: 0;
  min-height: 2.15rem;
  padding: 0.45rem 0.35rem;
  border: none;
  background: transparent;
  color: #fff;
  font-family: var(--font-mono);
  font-size: 0.77rem;
  cursor: pointer;
  touch-action: manipulation;
  user-select: none;
}

.profile-bitcoin-btn {
  appearance: none;
  box-sizing: border-box;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 2.15rem;
  margin: 0;
  padding: 0 0.15rem;
  border: none;
  background: transparent;
  color: #fff;
  font-family: var(--font-serif);
  font-size: 1.7rem;
  font-weight: 400;
  line-height: 1;
  cursor: pointer;
  touch-action: manipulation;
  user-select: none;
}

.profile-more-btn:hover,
.profile-more.is-open .profile-more-btn {
  color: var(--yellow);
  text-shadow: var(--glow-yellow);
}

.profile-bitcoin-btn:hover,
.profile-bitcoin-btn.is-open {
  color: var(--yellow);
  text-shadow: var(--glow-yellow);
}

.profile-qr-btn {
  appearance: none;
  box-sizing: border-box;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex: 0 0 auto;
  width: 1.35rem;
  height: 1.35rem;
  min-height: 1.35rem;
  margin: 0;
  padding: 0;
  border: none;
  background: transparent;
  color: #fff;
  cursor: pointer;
  touch-action: manipulation;
  user-select: none;
}

.profile-qr-btn .profile-qr-mark {
  display: block;
  width: 1.35rem;
  height: 1.35rem;
}

.profile-qr-btn:hover,
.profile-qr-btn.is-open {
  color: var(--yellow);
}

.profile-qr-btn:hover .profile-qr-mark,
.profile-qr-btn.is-open .profile-qr-mark {
  filter: drop-shadow(0 0 6px rgba(255, 225, 74, 0.55));
}

.profile-zap-btn {
  appearance: none;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex: 0 0 auto;
  width: 2.35rem;
  height: 2.35rem;
  margin: 0;
  padding: 0;
  border: none;
  background: transparent;
  color: var(--gray);
  cursor: pointer;
  touch-action: manipulation;
}

.profile-zap-btn .zap-mark {
  display: block;
  width: 1.65rem;
  height: 1.65rem;
}

.profile-zap-btn:hover,
.profile-zap-btn.is-open {
  background: transparent;
}

.profile-zap-btn:hover {
  color: var(--yellow);
}

.profile-zap-btn:hover .zap-mark {
  filter: drop-shadow(0 0 5px rgba(255, 225, 74, 0.95));
}

.profile-zap-btn.is-zapping .zap-mark {
  filter: none;
}

.profile-zap-btn.is-zapping.is-zap-blink .zap-mark,
.profile-zap-btn.is-zap-flash .zap-mark {
  filter: drop-shadow(0 0 7px rgba(255, 225, 74, 0.95));
}

.profile-zap-btn.is-zap-strobe:not(.is-zap-flash) {
  visibility: hidden;
}

.profile-more-btn:focus-visible,
.profile-bitcoin-btn:focus-visible,
.profile-qr-btn:focus-visible,
.profile-zap-btn:focus-visible {
  outline: 1px solid var(--yellow);
  outline-offset: 2px;
}

.content-more {
  position: relative;
  display: inline-flex;
  flex: 0 0 auto;
  z-index: 2;
}

.content-more-btn {
  appearance: none;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  margin: 0;
  min-height: 2.45rem;
  padding: 0.45rem 0.15rem;
  border: none;
  background: transparent;
  color: #fff;
  font-family: inherit;
  font-size: 0.77rem;
  line-height: 1;
  letter-spacing: 0;
  cursor: pointer;
  touch-action: manipulation;
  user-select: none;
}

.content-more-btn:hover,
.content-more.is-open .content-more-btn {
  color: var(--yellow);
  text-shadow: var(--glow-yellow);
}

.content-more-btn:focus-visible {
  outline: 1px solid var(--yellow);
  outline-offset: 2px;
}

.profile-more-menu:focus,
.content-more-menu:focus,
.wallet-more-menu:focus,
.dao-more-menu:focus {
  outline: none;
}

.profile-more-menu,
.content-more-menu {
  position: absolute;
  top: calc(100% + 0.35rem);
  left: 0;
  z-index: 5;
  display: flex;
  flex-direction: column;
  min-width: min(12.5rem, calc(100vw - 16px));
  max-width: calc(100vw - 16px);
  background: var(--bg-panel);
  backdrop-filter: blur(8px);
  border: 1px solid var(--border-hot);
  border-radius: var(--radius);
  box-shadow: var(--glow-red), 0 12px 32px rgba(0, 0, 0, 0.45);
}

.profile-banner:has(.profile-more.is-open) {
  overflow: visible;
  z-index: 3;
}

.profile-more-item,
.content-more-item,
.wallet-more-item {
  appearance: none;
  display: block;
  width: 100%;
  margin: 0;
  padding: 0.75rem 1.05rem;
  border: none;
  background: transparent;
  font-family: var(--font-display);
  font-size: 0.68rem;
  font-weight: 700;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  text-align: left;
  text-decoration: none;
  color: var(--gray);
  white-space: nowrap;
  cursor: pointer;
}

.profile-more-item:hover,
.profile-more-item:focus-visible,
.content-more-item:hover,
.content-more-item:focus-visible,
.wallet-more-item:hover,
.wallet-more-item:focus-visible {
  color: var(--yellow);
  background: rgba(227, 19, 55, 0.12);
  text-shadow: var(--glow-yellow);
}

.profile-more-item:disabled,
.content-more-item:disabled,
.wallet-more-item:disabled,
.dao-more-item:disabled {
  opacity: 0.65;
  cursor: wait;
}

.dao-more {
  position: relative;
  display: inline-flex;
  flex: 0 0 auto;
}

.dao-more.is-open {
  z-index: 9;
}

.dao-more-btn {
  appearance: none;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  margin: 0;
  min-height: 2.15rem;
  padding: 0.45rem 0.35rem;
  border: none;
  background: transparent;
  color: #fff;
  font-family: var(--font-mono);
  font-size: 0.77rem;
  cursor: pointer;
  touch-action: manipulation;
  user-select: none;
}

.dao-more-btn:hover,
.dao-more.is-open .dao-more-btn {
  color: var(--yellow);
  text-shadow: var(--glow-yellow);
}

.dao-more-btn:focus-visible {
  outline: 1px solid var(--yellow);
  outline-offset: 2px;
}

.dao-more-menu {
  position: absolute;
  top: calc(100% + 0.35rem);
  left: 0;
  z-index: 5;
  display: flex;
  flex-direction: column;
  min-width: min(12.5rem, calc(100vw - 16px));
  max-width: calc(100vw - 16px);
  background: var(--bg-panel);
  backdrop-filter: blur(8px);
  border: 1px solid var(--border-hot);
  border-radius: var(--radius);
  box-shadow: var(--glow-red), 0 12px 32px rgba(0, 0, 0, 0.45);
}

.dao-more-item {
  appearance: none;
  display: block;
  width: 100%;
  margin: 0;
  padding: 0.75rem 1.05rem;
  border: none;
  background: transparent;
  font-family: var(--font-display);
  font-size: 0.68rem;
  font-weight: 700;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  text-align: left;
  text-decoration: none;
  color: var(--gray);
  white-space: nowrap;
  cursor: pointer;
}

.dao-more-item:hover,
.dao-more-item:focus-visible {
  color: var(--yellow);
  background: rgba(227, 19, 55, 0.12);
  text-shadow: var(--glow-yellow);
}

@media (max-width: 720px) {
  .dao-more-menu {
    left: auto;
    right: 0;
  }
}

#contentDeleteStatus {
  margin-top: 0;
}

#contentDeleteStatus.is-error {
  color: var(--red-bright);
}

#crossPostOverlay .overlay-card {
  overflow: visible;
}

#crossPostDestBtn.is-empty span {
  color: var(--gray-dim);
}

#crossPostOverlay .label-optional {
  letter-spacing: 0;
  text-transform: none;
  font-weight: 500;
}

#crossPostMessage::placeholder {
  color: var(--gray-dim);
}

#crossPostStatus {
  margin-top: 0;
}

#crossPostStatus.is-error {
  color: var(--red-bright);
}

#crossPostOverlay .btn-primary:disabled {
  cursor: default;
}

#crossPostOverlay.is-busy .btn-primary:disabled {
  cursor: wait;
}

.community-nsfw {
  color: var(--red-bright);
}

.community-nav,
.profile-nav {
  margin-top: 0.15rem;
}

.profile-posts-slot {
  position: relative;
  display: inline-flex;
  align-items: stretch;
  border: 1px solid transparent;
  border-radius: var(--radius);
  color: var(--gray);
}

.profile-nav:has(.profile-posts-slot.is-open) {
  position: relative;
  z-index: 5;
}

.profile-posts-slot.is-open {
  z-index: 2;
}

.profile-nav .profile-posts-link {
  display: inline-flex;
  align-items: center;
  padding: 0.6rem 0.15rem 0.6rem 1.05rem;
  border-color: transparent;
  background: transparent;
  border-radius: 0;
}

.profile-nav .profile-posts-link:hover,
.profile-posts-slot.is-active .profile-posts-link,
.profile-posts-slot.is-open .profile-posts-link,
.profile-posts-slot:hover .profile-posts-link {
  color: var(--yellow);
  text-shadow: inherit;
}

.profile-posts-arrow {
  appearance: none;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  margin: 0;
  padding: 0 0.85rem 0 0.2rem;
  border: none;
  background: transparent;
  color: inherit;
  cursor: pointer;
  line-height: 0;
}

.profile-posts-arrow svg {
  width: 0.62rem;
  height: 0.62rem;
  display: block;
}

.profile-posts-slot:hover,
.profile-posts-slot.is-open,
.profile-posts-slot.is-active {
  color: var(--yellow);
}

.profile-posts-slot.is-active {
  border-color: var(--border-hot);
  background: rgba(227, 19, 55, 0.1);
  text-shadow: var(--glow-yellow);
}

.profile-posts-arrow:focus-visible,
.profile-nav .profile-posts-link:focus-visible {
  outline: 1px solid var(--yellow);
  outline-offset: 2px;
}

.profile-posts-menu.comment-sort-menu {
  right: auto;
  left: 0;
  min-width: 9.5rem;
}

.community-panel {
  padding-bottom: 1rem;
}

.community-about section {
  margin-bottom: 0;
}

.community-about .post-body > :last-child {
  margin-bottom: 0;
}

.community-about .tags {
  margin-bottom: 0;
}

/* 10:3 strip. In the 600px about column that is 180px, short of a 16:9 hero
   and tall enough that a photo cover still reads. */
.community-about-cover {
  display: block;
  width: 100%;
  aspect-ratio: 10 / 3;
  height: auto;
  object-fit: cover;
  object-position: center;
  border-radius: var(--radius);
  border: 1px solid var(--border);
  margin: 0 0 1.75rem;
}

.community-about > section > h2,
.community-about .post-body h2 {
  font-family: var(--font-serif);
  font-size: 2rem;
  font-weight: 400;
  letter-spacing: -0.02em;
  text-transform: none;
  color: var(--yellow);
  margin: 2.1rem 0 0.85rem;
  line-height: 1.2;
}

.community-about-beneficiary {
  width: max-content;
  max-width: 100%;
  border-collapse: collapse;
  font-family: var(--font-body);
  font-size: 1.08rem;
  background: transparent;
}

.community-about-beneficiary td {
  border: 1px solid var(--border);
  padding: 0.75rem;
  color: var(--gray);
  background: transparent;
}

.community-about-beneficiary + .post-body {
  margin-top: 0.85rem;
}

.profile-about-links {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.profile-about-links li {
  display: grid;
  grid-template-columns: max-content minmax(0, 1fr);
  column-gap: 0.85rem;
  row-gap: 0.15rem;
  align-items: baseline;
}

.profile-about-kind {
  max-width: 11rem;
  font-family: var(--font-mono);
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--gray);
  overflow-wrap: anywhere;
}

.profile-about-value {
  min-width: 0;
  font-family: var(--font-body);
  font-size: 1.05rem;
  line-height: 1.4;
  overflow-wrap: anywhere;
}

@media (max-width: 720px) {
  .profile-about-links li {
    grid-template-columns: 1fr;
  }
}

.community-panel h2 {
  font-family: var(--font-display);
  font-size: 0.68rem;
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--gray);
  margin: 0 0 0.85rem;
}

.community-people-section h2 {
  margin-bottom: 1.15rem;
}

.community-people-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem 1rem;
  flex-wrap: wrap;
  margin-bottom: 1.15rem;
}

.community-people-head h2 {
  margin: 0;
}

.community-people-head .btn-ghost {
  flex: 0 0 auto;
}

.community-people-head:has(+ .community-people-note) {
  margin-bottom: 0.45rem;
}

.community-people-note {
  font-family: var(--font-mono);
  font-size: 0.75rem;
  line-height: 1.45;
  color: var(--gray);
  margin: 0 0 1rem;
}

.community-people-status {
  font-family: var(--font-mono);
  font-size: 0.82rem;
  line-height: 1.45;
  color: var(--gray);
  margin: 0 0 1.15rem;
}

.community-people-status.is-error {
  color: var(--red-bright);
}

#communityMembers > .community-people-section:not([hidden]) {
  margin-top: 0;
}

#communityMembers > .community-people-section:not([hidden]) ~ .community-people-section:not([hidden]) {
  margin-top: 4.25rem;
}

.community-people-more {
  margin-top: 1.75rem;
}

.community-people-more:has(#communityMemberStatus[hidden]) {
  display: none;
}

.community-section-more {
  margin-top: 1.75rem;
}

.community-people-section .community-section-more .feed-actions,
.community-section-more .loading-row {
  margin-top: 0;
}

.community-section-more:not(:has(button:not([hidden]))):not(:has(.loading-row:not([hidden]))) {
  display: none;
}

#communityPeopleEmpty h2 {
  font-family: var(--font-display);
  font-size: 0.9rem;
  letter-spacing: 0.12em;
  text-transform: none;
  color: var(--yellow);
  margin-bottom: 0.55rem;
}

.community-table-wrap {
  width: 100%;
  overflow-x: auto;
}

/* Subscribers are one full-width name per row. */
.community-table.is-flow {
  display: block;
  width: 100%;
}

.community-table.is-flow tbody {
  display: block;
}

.community-table.is-flow tr.community-member {
  display: block;
  min-width: 0;
  border-bottom: 1px solid var(--border);
}

.community-table.is-flow td {
  border-bottom: none;
  padding: 0.2rem 0;
  text-align: left;
}

.community-table.is-flow tr.community-member td:first-child {
  padding-top: 0.7rem;
}

.community-table.is-flow tr.community-member td:last-child {
  padding-right: 0;
  padding-bottom: 0.7rem;
  text-align: left;
}

.community-table.is-flow .community-member-who:has(.community-approve-btn) {
  display: flex;
  align-items: center;
  gap: 0.55rem;
}

.community-table.is-flow .community-member-who:has(.community-approve-btn) .author-link {
  width: auto;
  flex: 1 1 auto;
}

.community-table.is-flow .community-member-title,
.community-table.is-flow .community-member-role {
  padding-top: 0;
}

.community-table.is-flow .community-member-role,
.community-table.is-flow .community-member-actions {
  text-align: right;
}

.community-table {
  width: 100%;
  border-collapse: collapse;
  table-layout: fixed;
}

.community-col-who {
  width: 42%;
}

.community-col-title {
  width: 38%;
}

.community-col-role {
  width: 20%;
}

.community-table.has-actions .community-col-who {
  width: 34%;
}

.community-table.has-actions .community-col-title {
  width: 28%;
}

.community-table.has-actions .community-col-role {
  width: 16%;
}

.community-table.has-actions .community-col-actions {
  width: 22%;
}

.community-table td {
  padding: 0.9rem 1.15rem 0.9rem 0;
  vertical-align: middle;
  text-align: left;
  border-bottom: 1px solid var(--border);
}

.community-table td:last-child {
  padding-right: 0;
  text-align: right;
}

.community-table .author-link {
  display: flex;
  width: 100%;
  max-width: 100%;
  min-width: 0;
}

.community-table .author-link .avatar {
  flex: 0 0 auto;
}

.community-member-who {
  min-width: 0;
}

.community-table .author-name {
  flex: 1 1 0;
  min-width: 0;
  overflow: visible;
  text-overflow: clip;
  white-space: normal;
  overflow-wrap: anywhere;
}

.community-member-title {
  font-family: var(--font-body);
  font-size: 0.98rem;
  color: var(--text);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.community-title-btn {
  appearance: none;
  display: block;
  width: 100%;
  max-width: 100%;
  margin: 0;
  padding: 0;
  border: none;
  background: transparent;
  font: inherit;
  color: inherit;
  text-align: left;
  cursor: pointer;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.community-title-btn:hover:not(:disabled) {
  color: var(--yellow);
}

.community-title-btn:focus-visible {
  outline: 1px solid var(--yellow);
  outline-offset: 2px;
  color: var(--yellow);
}

.community-member-role {
  font-family: var(--font-mono);
  font-size: 0.72rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--gray);
  white-space: nowrap;
  text-align: right;
}

.community-member-actions {
  white-space: nowrap;
  text-align: right;
}

.community-member-actions-inner {
  display: inline-flex;
  align-items: center;
  justify-content: flex-end;
  gap: 0.4rem;
}

.community-role-btn {
  appearance: none;
  font-family: var(--font-display);
  font-size: 0.62rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--yellow);
  background: transparent;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 0.28rem 0.55rem;
  line-height: 1.2;
  cursor: pointer;
}

.community-role-btn:hover:not(:disabled) {
  border-color: var(--yellow);
  color: var(--yellow);
}

.community-role-remove,
.community-role-edit {
  border: none;
  background: transparent;
  padding: 0.15rem 0.2rem;
}

.community-role-remove {
  color: var(--red);
}

.community-role-edit {
  color: var(--gray);
}

.community-role-remove:hover:not(:disabled) {
  border-color: transparent;
  color: var(--red-bright);
}

.community-role-edit:hover:not(:disabled) {
  border-color: transparent;
  color: var(--yellow);
}

.community-role-btn:focus-visible {
  outline: 1px solid var(--yellow);
  outline-offset: 2px;
}

.community-role-btn:disabled {
  opacity: 0.55;
  cursor: wait;
}

.community-role-remove {
  min-width: 1.7rem;
  padding-left: 0.4rem;
  padding-right: 0.4rem;
  font-size: 0.9rem;
  letter-spacing: 0;
  line-height: 1;
}

.community-table-empty td {
  border-bottom: none;
  padding: 1.25rem 0 0;
  text-align: center;
}

.community-table-empty .empty-state {
  padding: 1.75rem 0.5rem;
}

.community-table-empty .empty-state h2 {
  font-family: var(--font-display);
  font-size: 0.9rem;
  letter-spacing: 0.12em;
  text-transform: none;
  color: var(--yellow);
  margin-bottom: 0.55rem;
}

.community-people-section .feed-actions {
  margin-top: 1.75rem;
}

.wallet-page {
  padding-bottom: 2rem;
}

.wallet-section {
  margin-bottom: 2.25rem;
}

.wallet-section h2 {
  font-family: var(--font-display);
  font-size: 0.68rem;
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--gray);
  margin: 0 0 0.85rem;
}

/* Section titles keep the larger gap. Empty headings use the profile empty-state gap. */
.wallet-section .empty-state h2 {
  margin-bottom: 0.55rem;
}

p.wallet-tools-tokens {
  margin: 0 0 0.9rem;
}

p.wallet-tools-rc {
  margin: 1rem 0;
}

button.wallet-rc-link {
  margin: 0;
  padding: 0;
  border: 0;
  background: none;
  font: inherit;
  color: var(--gray);
  cursor: pointer;
  text-align: left;
}

button.wallet-rc-link:hover,
button.wallet-rc-link:focus-visible {
  color: var(--yellow);
  text-shadow: var(--glow-yellow);
}

button.wallet-rc-link:focus-visible {
  outline: 1px solid var(--yellow);
  outline-offset: 2px;
}

.wallet-tools-line {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.75rem;
}

a.wallet-tools-keys {
  display: inline-flex;
  align-items: center;
  text-decoration: none;
}

.wallet-rewards {
  border: 1px solid var(--border-hot);
  background: rgba(227, 19, 55, 0.08);
  border-radius: var(--radius);
  padding: 1.15rem 1.2rem 1.05rem;
}

.wallet-rewards h2 {
  color: var(--yellow);
}

.wallet-claim-actions {
  flex: 1 1 100%;
  margin-top: 0.85rem;
}

.wallet-claiming {
  display: inline-flex;
  align-items: center;
  box-sizing: border-box;
  margin: 0;
  padding: 0 0.15rem;
  font-family: var(--font-display);
  font-size: 0.68rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  line-height: 1;
  text-transform: none;
  color: var(--yellow);
  text-shadow: var(--glow-yellow);
  animation: wallet-claim-blink 1s ease-in-out infinite;
}

@keyframes wallet-claim-blink {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.2; }
}

@media (prefers-reduced-motion: reduce) {
  .wallet-claiming {
    animation: none;
  }
}

.wallet-table tr.is-balance-in .wallet-value {
  animation: wallet-balance-receive 900ms ease;
}

@keyframes wallet-balance-receive {
  0% {
    color: #fff8c4;
    text-shadow: 0 0 16px rgba(255, 225, 74, 0.75);
  }
  100% {
    color: var(--yellow);
    text-shadow: var(--glow-yellow);
  }
}

@media (prefers-reduced-motion: reduce) {
  .wallet-table tr.is-balance-in .wallet-value {
    animation: none;
  }
}

.wallet-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.45rem 1rem;
  padding: 0.85rem 0;
  border-bottom: 1px solid var(--border);
}

.wallet-row:last-child {
  border-bottom: none;
}

.wallet-label {
  flex: 1 1 8rem;
  min-width: 0;
  font-family: var(--font-mono);
  font-size: 0.82rem;
  letter-spacing: 0.04em;
  color: var(--gray);
}

.wallet-value {
  font-family: var(--font-mono);
  font-size: 0.95rem;
  color: var(--yellow);
  text-shadow: var(--glow-yellow);
  margin-left: auto;
}

.wallet-row-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.55rem;
}

.wallet-table-wrap {
  display: block;
  width: 100%;
}

.wallet-table {
  display: table;
  width: auto;
  margin-left: auto;
  margin-right: auto;
  border-collapse: collapse;
  table-layout: auto;
}

.wallet-col-label,
.wallet-col-amount,
.wallet-col-unit,
.wallet-col-actions {
  width: auto;
  white-space: nowrap;
}

.wallet-table td {
  padding: 0.85rem 0.65rem 0.85rem 0;
  vertical-align: middle;
  border-bottom: 1px solid var(--border);
}

.wallet-table > tbody:last-child > tr:last-child > td,
.wallet-table > tbody:last-child > tr:has(+ .wallet-actions-under:last-child) > td {
  border-bottom: none;
}

.wallet-table .wallet-label {
  flex: none;
  padding-right: 1.5rem;
  white-space: nowrap;
}

.wallet-table .wallet-value {
  margin-left: 0;
  text-align: right;
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
  padding-right: 0.75rem;
}

.wallet-table .wallet-unit {
  font-family: var(--font-mono);
  font-size: 0.82rem;
  letter-spacing: 0.04em;
  color: var(--yellow);
  white-space: nowrap;
  padding-left: 0.55rem;
}

.wallet-table .wallet-actions {
  padding-right: 0;
  text-align: right;
  white-space: nowrap;
}

.wallet-actions-under {
  display: none;
}

.wallet-actions-inner {
  display: flex;
  justify-content: flex-end;
  flex-wrap: wrap;
  gap: 0.45rem;
}

.wallet-actions-inner:has(.wallet-stake-btn),
.wallet-actions-inner:has(.wallet-delegate-btn),
.wallet-actions-inner:has(.wallet-send-btn) {
  display: grid;
  justify-content: end;
}

.wallet-actions-inner:has(.wallet-stake-btn)::before,
.wallet-actions-inner:has(.wallet-delegate-btn)::before,
.wallet-actions-inner:has(.wallet-send-btn)::before {
  content: "Delegate";
  grid-area: 1 / 1;
  visibility: hidden;
  pointer-events: none;
  box-sizing: border-box;
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 0.68rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  padding: 0.55rem 1rem;
  border: 1px solid transparent;
  white-space: nowrap;
}

.wallet-actions-inner:has(.wallet-stake-btn) > .wallet-stake-btn,
.wallet-actions-inner:has(.wallet-delegate-btn) > .wallet-delegate-btn,
.wallet-actions-inner:has(.wallet-send-btn) > .wallet-send-btn {
  grid-area: 1 / 1;
  width: 100%;
  justify-content: center;
}

/* Send is its own row so the hive and hbd text stays on the Stake line. */
.wallet-table tr:has(+ .wallet-actions-under + .wallet-send-row) > td {
  border-bottom: none;
  padding-bottom: 0.4rem;
}

.wallet-send-row > td {
  padding-top: 0.25rem;
  padding-bottom: 0.85rem;
  border-bottom: 1px solid var(--border);
}

.wallet-send-actions {
  display: flex;
  justify-content: flex-end;
  align-items: center;
  gap: 0.35rem;
}

.wallet-more {
  position: relative;
  display: inline-flex;
  flex: 0 0 auto;
}

.wallet-more-btn {
  appearance: none;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  margin: 0;
  min-height: 0;
  padding: 0.35rem 0.5rem;
  border: none;
  background: transparent;
  color: #fff;
  font-family: inherit;
  font-size: 0.77rem;
  line-height: 1;
  letter-spacing: 0;
  cursor: pointer;
  touch-action: manipulation;
  user-select: none;
}

.wallet-more-btn:hover,
.wallet-more.is-open .wallet-more-btn {
  color: var(--yellow);
  text-shadow: var(--glow-yellow);
}

.wallet-more-btn:focus-visible {
  outline: 1px solid var(--yellow);
  outline-offset: 2px;
}

/* Right edge sits on the three-dot button, so the menu grows left and stays off Send. */
.wallet-more-menu {
  position: absolute;
  top: calc(100% + 0.28rem);
  right: 0;
  left: auto;
  z-index: 8;
  display: flex;
  flex-direction: column;
  min-width: min(10rem, calc(100vw - 16px));
  max-width: calc(100vw - 16px);
  background: var(--bg-panel);
  backdrop-filter: blur(8px);
  border: 1px solid var(--border-hot);
  border-radius: var(--radius);
  box-shadow: var(--glow-red), 0 12px 32px rgba(0, 0, 0, 0.45);
}

.wallet-note {
  margin-top: 0.65rem;
  font-family: var(--font-mono);
  font-size: 0.75rem;
  color: var(--gray);
  line-height: 1.45;
}

.wallet-powerdown-note,
.wallet-hbd-unstake-note {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.45rem 0.85rem;
}

.wallet-powerdown-cancel,
.wallet-hbd-unstake-cancel {
  flex: 0 0 auto;
}

.wallet-powerdown,
.wallet-hbd-unstake,
.wallet-conversion {
  display: inline-block;
  position: relative;
  max-width: 100%;
  outline: none;
}

.wallet-powerdown:focus-visible,
.wallet-hbd-unstake:focus-visible,
.wallet-conversion:focus-visible {
  outline: 1px solid var(--gray);
  outline-offset: 3px;
  border-radius: 2px;
}

.wallet-powerdown .session-stat-tip,
.wallet-hbd-unstake .session-stat-tip,
.wallet-conversion .session-stat-tip {
  left: 0;
  right: auto;
  z-index: 8;
  width: max-content;
  max-width: min(26rem, calc(100vw - 2.4rem));
  padding: 0.5rem 0.65rem;
  white-space: normal;
  line-height: 1.45;
}

.wallet-powerdown-line {
  display: grid;
  grid-template-columns: 6.4rem minmax(0, max-content);
  column-gap: 0.75rem;
  align-items: baseline;
}

.wallet-powerdown-line + .wallet-powerdown-line {
  margin-top: 0.22rem;
}

.wallet-powerdown-k {
  color: var(--gray);
}

.wallet-powerdown:hover .session-stat-tip,
.wallet-powerdown:focus .session-stat-tip,
.wallet-powerdown:focus-visible .session-stat-tip,
.wallet-hbd-unstake:hover .session-stat-tip,
.wallet-hbd-unstake:focus .session-stat-tip,
.wallet-hbd-unstake:focus-visible .session-stat-tip,
.wallet-conversion:hover .session-stat-tip,
.wallet-conversion:focus .session-stat-tip,
.wallet-conversion:focus-visible .session-stat-tip {
  opacity: 1;
  visibility: visible;
}

.wallet-section:has(.wallet-powerdown:hover),
.wallet-section:has(.wallet-powerdown:focus),
.wallet-section:has(.wallet-powerdown:focus-visible),
.wallet-section:has(.wallet-hbd-unstake:hover),
.wallet-section:has(.wallet-hbd-unstake:focus),
.wallet-section:has(.wallet-hbd-unstake:focus-visible),
.wallet-section:has(.wallet-conversion:hover),
.wallet-section:has(.wallet-conversion:focus),
.wallet-section:has(.wallet-conversion:focus-visible) {
  position: relative;
  z-index: 8;
}

.wallet-delegated-toggle {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  margin: 0;
  padding: 0;
  border: 0;
  background: none;
  font: inherit;
  letter-spacing: inherit;
  color: inherit;
  cursor: pointer;
  appearance: none;
  -webkit-appearance: none;
}

.wallet-delegated-toggle:hover,
.wallet-delegated-toggle.is-open {
  color: var(--yellow);
}

.wallet-delegated-toggle:focus-visible {
  outline: 1px solid var(--yellow);
  outline-offset: 3px;
  border-radius: 2px;
}

.wallet-delegated-caret {
  width: 0.8rem;
  text-align: center;
}

.wallet-delegated-panel[hidden] {
  display: none;
}

.wallet-delegated-panel > tr.wallet-delegation-heading > td,
.wallet-delegated-panel > tr.wallet-delegation-direction > td,
.wallet-delegated-panel > tr.wallet-delegation-note > td {
  padding-top: 0.45rem;
  padding-bottom: 0.4rem;
  border-bottom: none;
  white-space: normal;
  text-align: left;
}

.wallet-delegated-panel > tr.wallet-delegation-row > td {
  padding-top: 0.45rem;
  padding-bottom: 0.45rem;
  border-bottom: 1px solid var(--border);
}

.wallet-delegated-panel > tr:first-child > td {
  padding-top: 0.95rem;
}

.wallet-delegated-panel > tr:last-child:not(.wallet-actions-under) > td {
  padding-bottom: 0.95rem;
}

.wallet-delegated-panel > tr.wallet-delegation-row + tr.wallet-delegation-direction > td,
.wallet-delegated-panel > tr.wallet-delegation-note + tr.wallet-delegation-direction > td,
.wallet-delegated-panel > tr.wallet-delegation-row + tr.wallet-delegation-heading > td,
.wallet-delegated-panel > tr.wallet-delegation-note + tr.wallet-delegation-heading > td,
.wallet-delegated-panel > tr.wallet-actions-under + tr.wallet-delegation-direction > td,
.wallet-delegated-panel > tr.wallet-actions-under + tr.wallet-delegation-heading > td {
  padding-top: 0.85rem;
}

.wallet-delegation-heading h3 {
  margin: 0;
  font-family: inherit;
  font-size: inherit;
  font-weight: inherit;
  letter-spacing: inherit;
  line-height: inherit;
  text-transform: none;
  color: inherit;
}

.wallet-delegation-row .wallet-label {
  font-family: var(--font-body);
  font-size: 0.98rem;
  font-weight: 400;
  letter-spacing: 0;
  color: var(--text);
  white-space: nowrap;
}

.wallet-delegation-arrow {
  display: inline-block;
  width: 1.1rem;
  margin-right: 0.35rem;
  font-family: inherit;
  color: var(--gray);
  text-align: center;
}

.wallet-delegation-row .wallet-label a.mention {
  color: inherit;
  text-shadow: none;
}

.wallet-delegation-row .wallet-label a.mention:hover,
.wallet-delegation-row .wallet-label a.mention:focus-visible {
  color: var(--yellow);
  text-shadow: var(--glow-yellow);
}

.wallet-delegation-row .wallet-undelegate-btn {
  min-width: 2.5rem;
  padding: 0.4rem 0.75rem;
}

.wallet-delegation-status {
  margin: 0;
  font-family: var(--font-mono);
  font-size: 0.75rem;
  color: var(--gray);
  line-height: 1.45;
}

.wallet-delegation-status.is-error {
  color: var(--red-bright);
}

.wallet-apr {
  display: block;
  position: relative;
  width: max-content;
  margin-top: 0.28rem;
  font-family: var(--font-mono);
  font-size: 0.72rem;
  font-weight: 400;
  letter-spacing: 0.02em;
  line-height: 1.3;
  color: var(--gray);
  white-space: nowrap;
}

.wallet-apr:focus {
  outline: none;
}

.wallet-apr:focus-visible {
  outline: 1px solid var(--gray);
  outline-offset: 3px;
  border-radius: 2px;
}

.wallet-apr .session-stat-tip {
  left: 0;
  right: auto;
  z-index: 8;
  width: min(17rem, 70vw);
  white-space: normal;
  line-height: 1.45;
}

.wallet-apr:hover .session-stat-tip,
.wallet-apr:focus .session-stat-tip,
.wallet-apr:focus-visible .session-stat-tip {
  opacity: 1;
  visibility: visible;
}

.wallet-table tr:has(.wallet-apr:hover),
.wallet-table tr:has(.wallet-apr:focus),
.wallet-table tr:has(.wallet-apr:focus-visible) {
  position: relative;
  z-index: 8;
}

.wallet-tx-list {
  display: flex;
  flex-direction: column;
}

.wallet-tx {
  display: flex;
  gap: 1rem;
  align-items: flex-start;
  justify-content: space-between;
  padding: 0.85rem 0;
  border-bottom: 1px solid var(--border);
}

.wallet-tx:last-child {
  border-bottom: none;
}

.wallet-tx-main {
  flex: 1 1 auto;
  min-width: 0;
}

.wallet-tx-type {
  display: block;
  font-family: var(--font-display);
  font-size: 0.62rem;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--yellow);
  margin-bottom: 0.25rem;
}

.wallet-tx-detail {
  font-family: var(--font-body);
  font-size: 0.98rem;
  color: var(--text);
  overflow: hidden;
  text-overflow: ellipsis;
}

.wallet-tx-detail a.mention,
.wallet-tx-memo a.mention,
.wallet-tx-field a.mention,
.wallet-tx-auth a.mention {
  color: inherit;
  text-shadow: none;
}

.wallet-tx-detail a.mention:hover,
.wallet-tx-detail a.mention:focus-visible,
.wallet-tx-memo a.mention:hover,
.wallet-tx-memo a.mention:focus-visible,
.wallet-tx-field a.mention:hover,
.wallet-tx-field a.mention:focus-visible,
.wallet-tx-auth a.mention:hover,
.wallet-tx-auth a.mention:focus-visible {
  color: var(--yellow);
  text-shadow: var(--glow-yellow);
}

.wallet-tx-auths {
  display: flex;
  flex-direction: column;
  gap: 0.22rem;
}

.wallet-tx-auth {
  display: flex;
  align-items: baseline;
  column-gap: 0.5rem;
  font-family: var(--font-body);
  font-size: 0.98rem;
  line-height: 1.35;
  color: var(--text);
}

.wallet-tx-auth-role {
  flex: 0 0 auto;
  font-family: var(--font-display);
  font-size: 0.62rem;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--gray);
}

.wallet-tx-auth-accounts {
  display: flex;
  flex: 1 1 0;
  flex-wrap: wrap;
  gap: 0.1rem 0.55rem;
  min-width: 0;
}

.wallet-tx-fields {
  display: flex;
  flex-direction: column;
  gap: 0.12rem;
  margin-top: 0.35rem;
}

.wallet-tx-field {
  font-family: var(--font-body);
  font-size: 0.86rem;
  line-height: 1.35;
  color: var(--text);
  overflow-wrap: anywhere;
}

.wallet-tx-field-key {
  color: var(--gray);
}

.wallet-tx-field-key::after {
  content: ": ";
}

.wallet-tx-memo {
  display: block;
  margin-top: 0.28rem;
  font-family: var(--font-body);
  font-size: 0.92rem;
  color: var(--text);
  white-space: pre-wrap;
  overflow-wrap: anywhere;
}

button.wallet-tx-memo {
  display: flex;
  align-items: flex-start;
  gap: 0.4rem;
  width: 100%;
  padding: 0;
  border: 0;
  background: none;
  font: inherit;
  font-family: var(--font-body);
  font-size: 0.92rem;
  line-height: 1.45;
  color: var(--text);
  text-align: left;
  cursor: pointer;
  appearance: none;
  -webkit-appearance: none;
}

button.wallet-tx-memo:hover,
button.wallet-tx-memo:focus-visible {
  color: var(--yellow);
}

button.wallet-tx-memo:focus {
  outline: none;
}

button.wallet-tx-memo:focus-visible {
  outline: 1px solid var(--yellow);
  outline-offset: 2px;
}

button.wallet-tx-memo:disabled {
  cursor: progress;
}

.wallet-tx-memo-open {
  display: flex;
  align-items: flex-start;
  gap: 0.4rem;
  width: 100%;
  line-height: 1.45;
}

.wallet-memo-lock {
  flex: 0 0 auto;
  width: 0.95em;
  height: 0.95em;
  margin-top: 0.2em;
  color: var(--yellow);
}

.wallet-memo-cipher {
  min-width: 0;
  overflow-wrap: anywhere;
  white-space: pre-wrap;
}

.wallet-tx-side {
  flex-shrink: 0;
  text-align: right;
}

.wallet-tx-amount {
  display: block;
  font-family: var(--font-mono);
  font-size: 0.82rem;
  color: var(--yellow);
}

.wallet-tx-time {
  display: block;
  position: relative;
  margin-top: 0.2rem;
  font-family: var(--font-mono);
  font-size: 0.72rem;
  color: var(--gray);
}

.wallet-tx-time .session-stat-tip {
  left: auto;
  right: 0;
  z-index: 8;
  padding: 0.28rem 0;
}

.wallet-tx-time:hover .session-stat-tip,
.wallet-tx-time:focus-visible .session-stat-tip {
  opacity: 1;
  visibility: visible;
}

.wallet-tx:has(.wallet-tx-time:hover),
.wallet-tx:has(.wallet-tx-time:focus-visible) {
  position: relative;
  z-index: 8;
}

a.wallet-tx-time {
  color: var(--gray);
}

a.wallet-tx-time:hover {
  color: var(--yellow);
  text-shadow: var(--glow-yellow);
}

.wallet-tx-status {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.65rem;
  padding: 1.1rem 0.5rem 0.25rem;
  font-family: var(--font-mono);
  font-size: 0.85rem;
  color: var(--yellow);
  letter-spacing: 0.08em;
}

.wallet-tx-status .btn-loader {
  width: 28px;
  height: 28px;
}

.wallet-page .feed-actions {
  margin-top: 1.35rem;
}

.wallet-amount-row {
  display: flex;
  align-items: center;
  gap: 0.65rem;
  margin-bottom: 0.85rem;
}

.dialog-card .wallet-amount-row input {
  flex: 1;
  min-width: 0;
  margin-bottom: 0;
}

#walletOverlay.is-confirm-only label[for="walletAmount"],
#walletOverlay.is-confirm-only .wallet-amount-row,
#walletOverlay.is-confirm-only #walletOpAvailable {
  display: none;
}

#walletOverlay .wallet-amount-row,
#sendOverlay .wallet-amount-row,
#convertOverlay .wallet-amount-row,
#claimTokensOverlay .wallet-amount-row,
#zapOverlay .wallet-amount-row {
  margin-bottom: 0.35rem;
}

#zapOverlay .wallet-amount-row {
  justify-content: flex-start;
  margin-bottom: 0.85rem;
}

#sendOverlay .send-amount-field,
#convertOverlay .send-amount-field,
#zapOverlay .send-amount-field {
  position: relative;
  flex: 1;
  min-width: 0;
}

#zapOverlay .send-amount-field {
  flex: 0 1 auto;
  width: 12.5rem;
  max-width: 100%;
}

#sendOverlay .send-amount-field input,
#convertOverlay .send-amount-field input,
#zapOverlay .send-amount-field input {
  padding-right: 4.6rem;
}

#zapOverlay .send-amount-field input {
  margin-bottom: 0;
}

#zapOverlay #zapNote {
  color: var(--gray);
}

#sendOverlay .send-amount-unit,
#convertOverlay .send-amount-unit,
#zapOverlay .send-amount-unit {
  position: absolute;
  top: 1px;
  right: 0.95rem;
  bottom: 1px;
  display: flex;
  align-items: center;
  color: var(--yellow);
  font-family: var(--font-mono);
  font-size: 1rem;
  line-height: 1;
  pointer-events: none;
}

#walletOpAvailable:empty,
#sendAvailable:empty,
#convertAvailable:empty,
#claimTokensAvailable:empty {
  display: none;
}

/* Same shape as the feed nav and the keychain switch, with the asset names left lowercase. */
#sendAsset button,
#convertAsset button,
#zapAsset button {
  text-transform: none;
}

/* The lock sits in the field. Zero the input margin so it centers on the box, not the gap under it. */
#sendOverlay .send-memo-field {
  position: relative;
  margin-bottom: 1rem;
}

#sendOverlay .send-memo-field input {
  margin-bottom: 0;
  padding-right: 2.6rem;
}

#sendOverlay .send-memo-lock {
  position: absolute;
  top: 1px;
  right: 1px;
  bottom: 1px;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 2.4rem;
  margin: 0;
  padding: 0;
  border: 0;
  border-radius: 0 5px 5px 0;
  background: transparent;
  color: var(--yellow);
  cursor: pointer;
}

#sendOverlay .send-memo-lock .wallet-memo-lock {
  width: 16px;
  height: 16px;
  margin-top: 0;
}

#sendOverlay .send-memo-lock:focus-visible {
  outline: 1px solid var(--yellow);
  outline-offset: -2px;
}

#sendOverlay .send-memo-lock:disabled {
  opacity: 0.45;
  cursor: default;
}

.wallet-available-amt {
  display: inline;
  margin: 0;
  padding: 0;
  border: 0;
  border-radius: 0;
  background: none;
  font: inherit;
  letter-spacing: inherit;
  line-height: inherit;
  color: inherit;
  text-decoration: none;
  cursor: pointer;
}

.wallet-available-amt:hover {
  color: var(--yellow);
  text-shadow: var(--glow-yellow);
}

.wallet-available-amt:disabled,
.wallet-available-amt:disabled:hover {
  color: inherit;
  text-shadow: none;
  cursor: default;
}

#delegateRcUnit {
  flex: 0 0 auto;
  width: auto;
  margin-bottom: 0;
  padding: 0.8rem 0.55rem;
  font-size: 0.82rem;
}

#walletOpStatus:empty,
#sendStatus:empty,
#convertStatus:empty,
#claimTokensStatus:empty,
#createAccountStatus:empty,
#rcStatus:empty,
#proposalCreateStatus:empty,
#proposalCancelStatus:empty,
#proxyStatus:empty,
#zapStatus:empty {
  display: none;
}

#walletOpStatus.is-error,
#sendStatus.is-error,
#convertStatus.is-error,
#claimTokensStatus.is-error,
#createAccountStatus.is-error,
#rcStatus.is-error,
#proposalCreateStatus.is-error,
#proposalCancelStatus.is-error,
#proxyStatus.is-error,
#delegateStatus.is-error,
#zapStatus.is-error {
  color: var(--red-bright);
}

#zapLnMissing {
  color: var(--gray);
  font-size: 0.82rem;
}

#zapLnMissing.is-error {
  color: var(--red-bright);
}

#zapLead:has(+ .zap-address:not([hidden])) {
  margin-bottom: 0.35rem;
}

.zap-address {
  display: flex;
  align-items: baseline;
  gap: 0.4rem;
  margin: 0 0 0.85rem;
  color: var(--text);
  font-size: 0.82rem;
  line-height: 1.35;
  word-break: break-all;
}

.zap-btc {
  flex: 0 0 auto;
  color: var(--yellow);
  font-family: var(--font-serif);
  font-size: 1.15rem;
  line-height: 1;
}

.zap-choices {
  display: flex;
  flex-wrap: wrap;
  gap: 0.45rem;
  margin: 0 0 0.9rem;
}

.zap-choice {
  appearance: none;
  margin: 0;
  padding: 0.45rem 0.7rem;
  border: 1px solid var(--border);
  border-radius: 999px;
  background: transparent;
  color: var(--text);
  font-family: var(--font-mono), "Segoe UI Emoji", sans-serif;
  font-size: 0.78rem;
  line-height: 1.35;
  cursor: pointer;
}

.zap-choice:hover,
.zap-choice.is-active {
  border-color: var(--yellow);
  color: var(--yellow);
  text-shadow: var(--glow-yellow);
}

.zap-choice:focus-visible {
  outline: 1px solid var(--yellow);
  outline-offset: 2px;
}

.zap-choice:disabled {
  opacity: 0.55;
  cursor: default;
}

.zap-fallback-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 1rem;
  align-items: center;
  margin: 0 0 0.85rem;
}

.zap-qr {
  display: flex;
  justify-content: center;
  margin: 0.15rem 0;
}

#zapWalletFallback > .zap-paid-toggle {
  align-self: center;
  align-items: center;
  width: fit-content;
  max-width: 100%;
  min-height: 2.625rem;
  margin: 0.35rem auto 0.85rem;
}

.qr-code {
  display: block;
  width: min(18rem, 100%);
  height: auto;
}

.profile-qr-nav {
  margin-bottom: 1.15rem;
}

.profile-qr-nav button {
  appearance: none;
  -webkit-appearance: none;
  background: transparent;
  cursor: pointer;
  font-family: var(--font-display);
  font-size: 0.68rem;
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--gray);
  padding: 0.6rem 1.05rem;
  border: 1px solid transparent;
  border-radius: var(--radius);
  line-height: 1.2;
}

.profile-qr-nav button:hover {
  color: var(--yellow);
  text-shadow: none;
}

.profile-qr-nav button.is-active {
  color: var(--yellow);
  border-color: var(--border-hot);
  background: rgba(227, 19, 55, 0.1);
  text-shadow: var(--glow-yellow);
}

.profile-qr-nav button:focus-visible {
  outline: 1px solid var(--yellow);
  outline-offset: 2px;
}

#profileQrOverlay {
  overflow-y: auto;
  overscroll-behavior: contain;
  align-items: safe center;
}

.profile-qr-code {
  display: flex;
  justify-content: center;
  align-items: center;
  min-height: 16rem;
}

.profile-qr-code .qr-code {
  width: min(16rem, 100%);
}

#profileQrCaption,
#settingsKeyQrCaption {
  margin: 0.15rem 0 1.15rem;
  text-align: center;
  overflow-wrap: anywhere;
}

#profileQrCaption:empty,
#settingsKeyQrCaption:empty {
  display: none;
}

#profileQrCaption.is-error,
#settingsKeyQrCaption.is-error {
  color: var(--red-bright);
}

#settingsKeyQrOverlay {
  overflow-y: auto;
  overscroll-behavior: contain;
  align-items: safe center;
}

.profile-qr-copy {
  appearance: none;
  -webkit-appearance: none;
  display: inline;
  max-width: 100%;
  margin: 0;
  padding: 0;
  border: 0;
  background: transparent;
  color: inherit;
  font: inherit;
  letter-spacing: inherit;
  text-align: inherit;
  overflow-wrap: anywhere;
  cursor: pointer;
}

.profile-qr-copy:hover,
.profile-qr-copy.is-copied {
  color: var(--yellow);
}

.profile-qr-copy:focus-visible {
  outline: 1px solid var(--yellow);
  outline-offset: 2px;
}

.zap-nwc-hint {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  justify-content: space-between;
  gap: 0.35rem 0.75rem;
}

#zapNwcClear {
  font-family: var(--font-display);
  font-size: 0.62rem;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--gray);
  background: transparent;
  border: 0;
  padding: 0;
  cursor: pointer;
}

#zapNwcClear:hover,
#zapNwcClear:focus-visible {
  color: var(--yellow);
  text-shadow: var(--glow-yellow);
}

#zapNwcClear:disabled {
  opacity: 0.55;
  cursor: default;
  text-shadow: none;
}

#zapOpenWallet {
  text-decoration: none;
}

#zapOverlay .overlay-actions {
  align-items: center;
}

.zap-settings-btn {
  appearance: none;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 2.15rem;
  height: 2.15rem;
  margin-left: auto;
  padding: 0;
  border: 0;
  border-radius: var(--radius);
  background: transparent;
  color: var(--gray);
  cursor: pointer;
}

.zap-settings-btn svg {
  display: block;
  width: 1.15rem;
  height: 1.15rem;
}

.zap-settings-btn:hover,
.zap-settings-btn:focus-visible {
  color: var(--yellow);
}

.zap-settings-btn:focus-visible {
  outline: 1px solid var(--yellow);
  outline-offset: 2px;
}

.zap-settings-btn:disabled {
  opacity: 0.45;
  cursor: default;
}

/* Above the zap dialog, under login (55) and the sign dialog (60). */
#lightningOverlay {
  z-index: 52;
}

/* Above the zap dialog and zap settings, under login.
   Stays until Yes or No. A tap on the zap dialog or the page does not answer it. */
#zapPayOverlay {
  z-index: 53;
}

html:has(#zapPayOverlay:not([hidden])) .app,
html:has(#zapPayOverlay:not([hidden])) #zapOverlay,
html:has(#zapPayOverlay:not([hidden])) #lightningOverlay {
  pointer-events: none;
}

#zapOverlay {
  overflow-y: auto;
  overscroll-behavior: contain;
  align-items: safe center;
}

#zapOverlay .overlay-card {
  overflow: visible;
}

@media (max-width: 720px) {
  /* Full viewport sheet. Border, radius, and shadow reset with the other viewport-sheet rules. */
  #zapOverlay {
    flex-direction: column;
    align-items: stretch;
    justify-content: flex-start;
    padding: 0;
  }

  #zapOverlay .overlay-card.viewport-sheet {
    flex: 1 1 auto;
    width: 100%;
    max-width: none;
    min-height: 0;
    max-height: none;
    margin: 0;
    overflow: auto;
    overscroll-behavior: contain;
  }
}

/* The card is taller than the other wallet dialogs. .panel clips overflow, so this one scrolls. */
#createAccountOverlay .overlay-card {
  margin-bottom: 0;
  max-height: calc(100dvh - 3rem);
  overflow: auto;
  overscroll-behavior: contain;
}

#rcOverlay .overlay-card {
  margin-bottom: 0;
  max-height: calc(100dvh - 3rem);
  overflow: auto;
  overscroll-behavior: contain;
}

#rcLead:empty,
#rcNote:empty,
#rcRecharge:empty {
  display: none;
}

#rcRecharge {
  margin-top: -0.45rem;
}

#rcOverlay .rc-balance-amt {
  color: var(--yellow);
  text-shadow: var(--glow-yellow);
}

#rcOverlay .rc-cost-table {
  width: 100%;
  border-collapse: collapse;
  margin: 0 0 0.85rem;
  font-family: var(--font-mono);
  font-size: 0.75rem;
  line-height: 1.35;
}

#rcOverlay .rc-cost-table th {
  font-weight: 500;
  letter-spacing: 0.04em;
  color: var(--gray);
  text-align: left;
  padding: 0 0.75rem 0.45rem 0;
}

#rcOverlay .rc-cost-table th.rc-cost-num,
#rcOverlay .rc-cost-table td.rc-cost-num {
  text-align: right;
  white-space: nowrap;
  font-variant-numeric: tabular-nums;
}

#rcOverlay .rc-cost-table td {
  padding: 0.48rem 0.75rem 0.48rem 0;
  border-top: 1px solid var(--border);
  vertical-align: baseline;
  color: var(--gray);
}

#rcOverlay .rc-cost-table td.rc-cost-amt {
  color: var(--yellow);
  text-shadow: var(--glow-yellow);
}

#rcOverlay .rc-cost-table td:last-child,
#rcOverlay .rc-cost-table th:last-child {
  padding-right: 0;
}

#createAccountOverlay .subspace-key-line {
  margin-bottom: 0.45rem;
}

#createAccountOverlay .subspace-key-line input {
  flex: 1 1 auto;
  width: auto;
  min-width: 0;
  margin-bottom: 0;
}

#createAccountOverlay #createAccountKey {
  color: var(--yellow);
  cursor: text;
  line-height: 1.45;
}

#createAccountOverlay .cyber-toggle {
  margin: 0.15rem 0 1rem;
}

@media (max-width: 720px) {
  #createAccountOverlay .overlay-card,
  #rcOverlay .overlay-card {
    max-height: calc(100dvh - 1.5rem - env(safe-area-inset-bottom, 0px));
  }
}

/* The card is taller than the viewport. .panel clips overflow, so this one scrolls. */
#proposalOverlay .dialog-card {
  width: min(36rem, 100%);
}

#proposalOverlay .overlay-card {
  margin-bottom: 0;
  max-height: calc(100dvh - 3rem);
  overflow: auto;
  overscroll-behavior: contain;
}

#proposalOverlay .overlay-card input:has(+ .dialog-hint) {
  margin-bottom: 0.35rem;
}

#proposalOverlay input[type="datetime-local"] {
  color-scheme: dark;
  min-width: 0;
}

#proposalCreateStart[readonly] {
  pointer-events: none;
}

#proposalOverlay .overlay-card input:has(+ #proposalCreateDailyHint:not([hidden])) {
  margin-bottom: 0.35rem;
}

#proposalCreateFee {
  color: var(--yellow);
}

.proposal-create-dates {
  display: grid;
  grid-template-columns: 1fr 1fr;
  column-gap: 0.85rem;
}

.proposal-create-dates > div {
  min-width: 0;
}

@media (max-width: 720px) {
  #proposalOverlay .overlay-card {
    max-height: calc(100dvh - 1.5rem - env(safe-area-inset-bottom, 0px));
  }

  .proposal-create-dates {
    grid-template-columns: 1fr;
  }
}

#delegateStatus:empty,
#delegateHint:empty {
  display: none;
}

#nodeStatus:empty {
  display: none;
}

#nodeStatus.is-error {
  color: var(--red-bright);
}

/* Login overlay */
.overlay {
  position: fixed;
  inset: 0;
  z-index: 50;
  background: rgba(7, 7, 7, 0.75);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1.5rem;
}

.overlay-card {
  width: min(28rem, 100%);
  background: var(--bg-panel);
}

.overlay-card:focus {
  outline: none;
}

.dialog-card {
  width: min(32rem, 100%);
}

/* Above login and the sign dialog so a scan can sit on either one. */
#keyQrOverlay {
  z-index: 70;
}

.auth-key-row {
  display: flex;
  align-items: stretch;
  gap: 0.45rem;
  margin-bottom: 0.85rem;
}

.dialog-card .auth-key-row input {
  flex: 1 1 auto;
  width: auto;
  min-width: 0;
  margin-bottom: 0;
}

#walletOverlay .auth-key-row,
#sendOverlay .auth-key-row,
#delegateOverlay .auth-key-row {
  margin-bottom: 1rem;
}

.auth-scan-qr {
  flex: 0 0 auto;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 2.75rem;
  margin: 0;
  padding: 0;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--bg-input);
  color: var(--gray);
  cursor: pointer;
}

.auth-scan-qr svg {
  width: 1.15rem;
  height: 1.15rem;
  display: block;
}

.auth-scan-qr:hover:not(:disabled),
.auth-scan-qr:focus-visible {
  color: var(--yellow);
  border-color: var(--red-bright);
}

.auth-scan-qr:disabled {
  opacity: 0.45;
  cursor: default;
}

.auth-scan-qr:focus-visible {
  outline: 1px solid var(--yellow);
  outline-offset: 2px;
}

.key-qr-view {
  position: relative;
  width: 100%;
  aspect-ratio: 3 / 4;
  max-height: 18rem;
  margin-bottom: 0.85rem;
  background: #000;
  border-radius: var(--radius);
  overflow: hidden;
}

.key-qr-view video {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.key-qr-view::after {
  content: "";
  position: absolute;
  left: 18%;
  top: 18%;
  width: 64%;
  height: 64%;
  border: 1px solid var(--yellow);
  border-radius: 0.35rem;
  pointer-events: none;
  box-shadow: 0 0 0 999px rgba(0, 0, 0, 0.35);
}

#keyQrStatus:empty {
  display: none;
}

#keyQrStatus.is-error {
  color: var(--red-bright);
}

/* Above the publish composer so Publish can ask for a session without closing it. */
#loginOverlay {
  z-index: 55;
}

/* Above the wallet amount dialog, which stays open underneath. */
#ownerSignOverlay {
  z-index: 60;
}

.dialog-card .dialog-lead {
  margin-bottom: 1rem;
}

.dialog-method {
  display: flex;
  gap: 0.5rem;
  margin: 0 0 1.15rem;
  flex-wrap: wrap;
}

.dialog-method button {
  font-family: var(--font-display);
  font-size: 0.68rem;
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--gray);
  padding: 0.6rem 1.05rem;
  border: 1px solid transparent;
  border-radius: var(--radius);
  background: transparent;
  cursor: pointer;
  line-height: 1.2;
  appearance: none;
  -webkit-appearance: none;
}

.dialog-method button:hover {
  color: var(--yellow);
  text-shadow: none;
}

.dialog-method button.is-active {
  color: var(--yellow);
  border-color: var(--border-hot);
  background: rgba(227, 19, 55, 0.1);
  text-shadow: var(--glow-yellow);
}

.dialog-method button:focus-visible {
  outline: 1px solid var(--yellow);
  outline-offset: 2px;
}

.dialog-label {
  display: block;
  font-family: var(--font-display);
  font-size: 0.62rem;
  font-weight: 700;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--gray);
  margin-bottom: 0.35rem;
}

.dialog-card input,
.dialog-card select {
  margin-bottom: 0.85rem;
}

.overlay-card .dialog-hint {
  margin-top: 0;
  margin-bottom: 0.85rem;
  font-size: 0.72rem;
}

#loginStatus:empty,
#ownerSignStatus:empty,
#communityRoleStatus:empty,
#communityTitleStatus:empty,
#lightningStatus:empty,
#communityRoleHint:empty {
  display: none;
}

#lightningOverlay .overlay-card {
  margin-bottom: 0;
  max-height: calc(100dvh - 3rem);
  overflow: auto;
  overscroll-behavior: contain;
}

@media (max-width: 720px) {
  /* Full viewport sheet. Border, radius, and shadow reset with the other viewport-sheet rules. */
  #lightningOverlay {
    flex-direction: column;
    align-items: stretch;
    justify-content: flex-start;
    padding: 0;
  }

  #lightningOverlay .overlay-card.viewport-sheet {
    flex: 1 1 auto;
    width: 100%;
    max-width: none;
    min-height: 0;
    max-height: none;
    margin: 0;
    overflow: auto;
    overscroll-behavior: contain;
  }
}

#lightningOverlay h2.settings-section-line {
  display: flex;
  align-items: center;
  gap: 0.85rem;
  margin: 1.75rem 0 0.45rem;
  font-family: var(--font-display);
  font-size: 0.8rem;
  font-weight: 700;
  letter-spacing: 0.03em;
  text-transform: none;
  color: var(--yellow);
  line-height: 1.45;
}

#lightningOverlay h2.settings-section-line span {
  white-space: nowrap;
}

#lightningOverlay h2.settings-section-line::after {
  content: "";
  flex: 1 1 auto;
  height: 0;
  border-top: 1px solid #fff;
}

#lightningOverlay .settings-note {
  font-family: var(--font-mono);
  font-size: 0.75rem;
  line-height: 1.45;
  color: var(--gray-dim);
  margin: 0 0 0.7rem;
}

#lightningOverlay .settings-section-line + .settings-note {
  margin: 0 0 1.25rem;
}

#lightningOverlay #lightningAddress,
#lightningOverlay #zapNwc {
  margin-bottom: 0.45rem;
}

#lightningOverlay #lightningAddressNote {
  margin: 0;
}

#lightningOverlay #lightningAddressNote a {
  color: var(--gray-dim);
  text-shadow: none;
}

#lightningOverlay #lightningAddressNote a:hover {
  color: var(--yellow);
  text-shadow: var(--glow-yellow);
}

#lightningOverlay .zap-single-tap-toggle {
  margin: 0.15rem 0 0.9rem;
}

#lightningOverlay #zapSingleTapFields[hidden] {
  display: none;
}

#lightningOverlay .zap-single-tap-amount {
  display: flex;
  align-items: center;
  gap: 0.55rem;
  margin-bottom: 0.85rem;
}

#lightningOverlay .zap-single-tap-amount input,
#lightningOverlay .zap-single-tap-amount select {
  margin-bottom: 0;
}

#lightningOverlay .zap-single-tap-amount input {
  flex: 1 1 auto;
  min-width: 0;
}

#lightningOverlay .zap-single-tap-amount select {
  flex: 0 0 6.5rem;
  width: 6.5rem;
}

#lightningOverlay #zapSingleTapNote {
  color: var(--gray);
}

#lightningOverlay #zapSingleTapNote::placeholder {
  color: var(--gray-dim);
}

#ownerSignStatus.is-error,
#communityRoleStatus.is-error,
#communityTitleStatus.is-error,
#lightningStatus.is-error {
  color: var(--red-bright);
}

#communityRoleHint {
  color: var(--text);
}

.dialog-card input[readonly] {
  color: var(--gray);
}

.overlay-card h2 {
  font-family: var(--font-display);
  font-size: 0.9rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--yellow);
  margin-bottom: 0.9rem;
}

.overlay-card p {
  font-family: var(--font-mono);
  font-size: 0.82rem;
  color: var(--gray);
  line-height: 1.5;
  margin-bottom: 1.15rem;
}

.overlay-card input,
.overlay-card select {
  width: 100%;
  padding: 0.8rem 0.95rem;
  background: var(--bg-input);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  color: var(--yellow);
  font-family: var(--font-mono);
  font-size: 1rem;
  outline: none;
  margin-bottom: 1rem;
}

.overlay-card input:focus,
.overlay-card select:focus {
  border-color: var(--red-bright);
  box-shadow: 0 0 0 1px rgba(227, 19, 55, 0.35), var(--glow-red);
}

.overlay-actions {
  display: flex;
  gap: 0.75rem;
  flex-wrap: wrap;
}

/* Room for the primary button to shift up on hover. */
.overlay-actions > *,
.publish-actions > * {
  margin-top: 0.25rem;
}

.publish-fab {
  position: fixed;
  left: 1.5rem;
  bottom: 1.75rem;
  z-index: 40;
  min-width: 9.5rem;
  text-decoration: none;
}

a.publish-fab,
a.publish-fab:hover {
  color: #fff;
  text-shadow: none;
}

.publish-fab-icon {
  display: none;
  width: 1.25rem;
  height: 1.25rem;
}

/* The page behind these dialogs stays put. Only the open layer scrolls. */
html:has(#publishOverlay:not([hidden])),
body:has(#publishOverlay:not([hidden])),
html:has(#peopleOverlay:not([hidden])),
body:has(#peopleOverlay:not([hidden])),
html:has(#pollVotesOverlay:not([hidden])),
body:has(#pollVotesOverlay:not([hidden])),
html:has(#voteVotersPanel.viewport-sheet:not([hidden])),
body:has(#voteVotersPanel.viewport-sheet:not([hidden])),
html:has(#zapOverlay:not([hidden])),
body:has(#zapOverlay:not([hidden])),
html:has(#zapPayOverlay:not([hidden])),
body:has(#zapPayOverlay:not([hidden])),
html:has(#lightningOverlay:not([hidden])),
body:has(#lightningOverlay:not([hidden])),
html:has(#editHistoryOverlay:not([hidden])),
body:has(#editHistoryOverlay:not([hidden])) {
  overflow: hidden;
}

.people-card {
  width: min(64rem, 100%);
  max-height: min(82vh, 48rem);
  display: flex;
  flex-direction: column;
  margin-bottom: 0;
}

.people-card-head {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto minmax(0, 1fr);
  align-items: center;
  column-gap: 0.75rem;
  flex: 0 0 auto;
  margin-bottom: 0.85rem;
}

.people-card-head h2 {
  margin-bottom: 0;
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.people-card .people-search {
  grid-column: 2;
  width: 16rem;
  max-width: 100%;
  margin: 0;
  justify-self: center;
}

.people-card .people-search input {
  width: 100%;
  margin: 0;
  padding: 0.7rem 2.85rem 0.7rem 0.9rem;
  background: var(--bg-input);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  color: var(--yellow);
  font-family: var(--font-mono);
  font-size: 1rem;
  outline: none;
}

.people-card .people-search input:focus {
  border-color: var(--red-bright);
  box-shadow: 0 0 0 1px rgba(227, 19, 55, 0.35), var(--glow-red);
}

.people-card .people-search input::placeholder {
  color: var(--gray-dim);
  opacity: 0.85;
}

.poll-votes-card .people-card-head {
  grid-template-columns: minmax(0, 1fr) auto;
}

.poll-votes-card .people-close {
  grid-column: 2;
}

.poll-vote-tabs {
  display: flex;
  flex-wrap: wrap;
  gap: 0.45rem 1rem;
  flex: 0 0 auto;
  margin: 0 0 0.85rem;
}

.poll-vote-tab {
  appearance: none;
  -webkit-appearance: none;
  max-width: 100%;
  margin: 0;
  padding: 0.15rem 0;
  border: 0;
  border-bottom: 1px solid transparent;
  background: none;
  color: var(--text-dim);
  font-family: var(--font-mono);
  font-size: 0.82rem;
  line-height: 1.35;
  text-shadow: none;
  cursor: pointer;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.poll-vote-tab:hover,
.poll-vote-tab.is-active {
  color: var(--yellow);
  text-shadow: var(--glow-yellow);
}

.poll-vote-tab.is-active {
  border-bottom-color: var(--yellow);
}

.poll-vote-tab:focus {
  outline: none;
}

.poll-vote-tab:focus-visible {
  outline: 1px solid var(--yellow);
  outline-offset: 3px;
}

.people-close {
  grid-column: 3;
  justify-self: end;
  appearance: none;
  -webkit-appearance: none;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex: 0 0 auto;
  width: 1.25rem;
  height: 1.25rem;
  margin: 0;
  padding: 0;
  border: 0;
  background: none;
  color: var(--gray);
  cursor: pointer;
  line-height: 0;
}

.people-close svg {
  width: 1.25rem;
  height: 1.25rem;
  display: block;
}

.people-close:hover {
  color: var(--yellow);
}

.people-close:focus {
  outline: none;
}

.people-close:focus-visible {
  outline: 1px solid var(--yellow);
  outline-offset: 3px;
}

.people-scroll {
  overflow: auto;
  overscroll-behavior: contain;
  min-height: min(22rem, 50vh);
  max-height: min(68vh, 40rem);
}

@media (min-width: 721px) {
  .people-scroll {
    scrollbar-width: none;
    -ms-overflow-style: none;
  }

  .people-scroll::-webkit-scrollbar {
    width: 0;
    height: 0;
    display: none;
  }
}

.people-card .follow-list {
  max-width: none;
  margin: 0;
}

.people-card .loading-row,
.people-card .feed-actions,
.people-card .empty-state {
  max-width: none;
}

.people-card .empty-state {
  margin-bottom: 0;
}

.people-card .empty-state h2 {
  text-transform: none;
}

.people-scroll:has(.people-empty) {
  display: flex;
  align-items: center;
  justify-content: center;
}

.people-card .people-empty {
  margin: 0;
  color: var(--gray);
  text-align: center;
  font-family: var(--font-mono);
  font-size: 0.95rem;
}

@media (min-width: 1100px) {
  .people-card .follow-list {
    grid-template-columns: repeat(4, minmax(0, 1fr));
  }
}

#publishOverlay {
  align-items: flex-start;
  overflow-y: auto;
  overscroll-behavior: contain;
}

#publishDiscard {
  z-index: 60;
}

.publish-card {
  width: min(42rem, 100%);
  margin: auto;
  overflow: visible;
}

.publish-card.is-pending {
  opacity: 0.85;
}

.publish-card.is-editing-comment .publish-title-field,
.publish-card.is-editing-comment .publish-title-input,
.publish-card.is-editing-comment .publish-title-count,
.publish-card.is-editing-comment .publish-tags-head,
.publish-card.is-editing-comment .publish-tags,
.publish-card.is-editing-comment .publish-advanced {
  display: none !important;
}

.publish-head {
  display: flex;
  align-items: center;
  margin-bottom: 0.9rem;
}

.publish-head h2 {
  margin-bottom: 0;
}

.publish-title-field {
  position: relative;
  margin: 0 0 1rem;
}

.publish-title-count {
  position: absolute;
  right: 0.7rem;
  bottom: 0.52rem;
  width: 1.4rem;
  height: 1.4rem;
  z-index: 1;
  pointer-events: none;
}

.publish-title-count svg {
  display: block;
  width: 100%;
  height: 100%;
  transform: rotate(-90deg);
}

.publish-title-count circle {
  fill: none;
  stroke-width: 1;
}

.publish-title-count-track {
  stroke: var(--gray-arc);
}

.publish-title-count-arc {
  stroke: var(--yellow);
  stroke-linecap: round;
  opacity: 0;
}

.publish-title-count.is-limit .publish-title-count-arc,
.publish-title-count.is-limit .publish-title-count-track {
  stroke: var(--red);
}

.publish-card .publish-title-input {
  display: block;
  width: 100%;
  max-width: 100%;
  min-width: 0;
  min-height: calc(1.35em + 1.6rem + 2px);
  height: calc(1.35em + 1.6rem + 2px);
  padding: 0.8rem 0.95rem;
  margin: 0;
  background: var(--bg-input);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  color: var(--yellow);
  font-family: var(--font-serif);
  font-size: 1.35rem;
  line-height: 1.35;
  outline: none;
  resize: none;
  overflow: hidden;
  white-space: pre-wrap;
  overflow-wrap: break-word;
}

.publish-card .publish-title-input:focus {
  border-color: var(--red-bright);
  box-shadow: 0 0 0 1px rgba(227, 19, 55, 0.35), var(--glow-red);
}

.publish-card .publish-title-input::placeholder {
  color: var(--gray-dim);
}

.publish-login-wrap {
  margin-top: 1.25rem;
}

.publish-dest {
  margin-bottom: 1rem;
}

.publish-dest-picker {
  position: relative;
}

.publish-dest-label {
  display: block;
  font-family: var(--font-display);
  font-size: 0.62rem;
  font-weight: 700;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--gray);
  margin-bottom: 0.45rem;
}

.publish-dest-btn {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  width: 100%;
  padding: 0.7rem 0.9rem;
  background: var(--bg-input);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  color: var(--yellow);
  font-family: var(--font-mono);
  font-size: 0.95rem;
  text-align: left;
  cursor: pointer;
}

.publish-dest-btn:hover,
.publish-dest-btn[aria-expanded="true"] {
  border-color: var(--red-bright);
  box-shadow: 0 0 0 1px rgba(227, 19, 55, 0.35), var(--glow-red);
}

.publish-dest-btn .avatar {
  width: 24px;
  height: 24px;
  border-radius: 50%;
  object-fit: cover;
}

.publish-dest-menu {
  position: absolute;
  left: 0;
  right: 0;
  top: calc(100% + 0.35rem);
  z-index: 8;
  max-height: 16rem;
  overflow-y: auto;
  padding: 0.35rem;
  background: var(--bg-input);
  border: 1px solid var(--border-hot);
  border-radius: var(--radius);
  box-shadow: var(--glow-red), 0 12px 32px rgba(0, 0, 0, 0.45);
}

.publish-dest-empty {
  padding: 0.7rem 0.8rem;
  font-family: var(--font-mono);
  font-size: 0.78rem;
  color: var(--gray);
  margin: 0;
}

.publish-dest-option {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  width: 100%;
  padding: 0.55rem 0.7rem;
  background: transparent;
  border: none;
  border-radius: 4px;
  color: var(--gray);
  font-family: var(--font-mono);
  font-size: 0.9rem;
  text-align: left;
  cursor: pointer;
}

.publish-dest-option .avatar {
  width: 24px;
  height: 24px;
  border-radius: 50%;
  object-fit: cover;
  flex-shrink: 0;
}

.publish-dest-btn span,
.publish-dest-option span {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.publish-dest-option:hover,
.publish-dest-option.is-selected {
  color: var(--yellow);
  background: rgba(227, 19, 55, 0.12);
}

.publish-dest-note {
  margin: 0.45rem 0 0;
  font-family: var(--font-mono);
  font-size: 0.78rem;
  line-height: 1.4;
  color: var(--gray);
}

.publish-card .comment-composer {
  margin: 0 0 1rem;
}

.publish-card .composer-input {
  min-height: 12rem;
  color: var(--gray);
}

.publish-card .composer-input::placeholder {
  font-family: inherit;
  font-size: inherit;
  line-height: inherit;
}

.publish-tags-head {
  display: flex;
  justify-content: space-between;
  font-family: var(--font-display);
  font-size: 0.62rem;
  font-weight: 700;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--gray);
  margin-bottom: 0.45rem;
}

.publish-tags {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.4rem;
  min-height: 2.8rem;
  padding: 0.4rem 0.55rem;
  margin-bottom: 1rem;
  background: var(--bg-input);
  border: 1px solid var(--border);
  border-radius: var(--radius);
}

.publish-tags:focus-within {
  border-color: var(--red-bright);
  box-shadow: 0 0 0 1px rgba(227, 19, 55, 0.35), var(--glow-red);
}

.publish-tag-chips {
  display: contents;
}

.publish-tag-chip {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  padding: 0.22rem 0.55rem;
  border: 1px solid rgba(211, 211, 211, 0.28);
  border-radius: 999px;
  background: transparent;
  color: var(--gray);
  font-family: var(--font-mono);
  font-size: 0.75rem;
  letter-spacing: 0.04em;
  cursor: pointer;
}

.publish-tag-chip:hover {
  color: var(--yellow);
  border-color: var(--border-hot);
}

.publish-card .publish-tags input {
  flex: 1 1 8rem;
  min-width: 7rem;
  margin: 0;
  padding: 0.35rem 0.4rem;
  border: none;
  background: transparent;
  box-shadow: none;
  color: var(--yellow);
  font-size: 0.95rem;
}

.publish-card .publish-tags input:focus {
  border: none;
  box-shadow: none;
}

.publish-advanced {
  margin: 0 0 1.25rem;
  border: none;
  border-radius: 0;
  background: none;
}

.publish-advanced summary {
  padding: 0;
  margin: 0;
  list-style: none;
  cursor: pointer;
  font-family: var(--font-display);
  font-size: 0.62rem;
  font-weight: 700;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--gray);
}

.publish-advanced summary::-webkit-details-marker {
  display: none;
}

.publish-advanced summary::marker {
  content: "";
}

.publish-advanced summary::after {
  content: "...";
  margin-left: 0.4rem;
  letter-spacing: 0;
}

.publish-advanced summary:hover,
.publish-advanced[open] summary {
  color: var(--yellow);
}

.publish-advanced summary:focus-visible {
  outline: 2px solid var(--yellow);
  outline-offset: 3px;
}

.publish-advanced-body {
  padding: 0.85rem 0 0;
}

.publish-field-label {
  display: block;
  font-family: var(--font-display);
  font-size: 0.62rem;
  font-weight: 700;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--gray);
  margin: 0.95rem 0 0.4rem;
}

.publish-advanced-body > .publish-field-label:first-child {
  margin-top: 0;
}

.publish-card .publish-advanced select {
  width: 100%;
  margin: 0 0 0.45rem;
  padding: 0.8rem 2.2rem 0.8rem 0.95rem;
  appearance: none;
  -webkit-appearance: none;
  background-color: var(--bg-input);
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 12 8'%3E%3Cpath d='M1 1.5 L6 6.5 L11 1.5' fill='none' stroke='%23d7d7d7' stroke-width='1.4'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 0.85rem center;
  background-size: 0.7rem;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  color: var(--yellow);
  font-family: var(--font-mono);
  font-size: 1rem;
  outline: none;
  cursor: pointer;
}

.publish-card .publish-advanced select:focus {
  border-color: var(--red-bright);
  box-shadow: 0 0 0 1px rgba(227, 19, 55, 0.35), var(--glow-red);
}

.publish-advanced .publish-reward-note,
.publish-advanced .publish-advanced-lock {
  margin: 0 0 0.15rem;
  font-size: 0.75rem;
  line-height: 1.45;
}

.publish-advanced .publish-advanced-lock {
  display: none;
  margin-top: 0.85rem;
}

.publish-card.is-editing:not(.is-editing-comment) .publish-reward,
.publish-card.is-editing:not(.is-editing-comment) .publish-beneficiaries {
  display: none;
}

.publish-card.is-editing:not(.is-editing-comment) .publish-advanced-lock {
  display: block;
  margin-top: 0.85rem;
  margin-bottom: 0;
}

.publish-beneficiary-row {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  margin-bottom: 0.55rem;
}

.publish-card .publish-beneficiary-row input {
  width: auto;
  margin-bottom: 0;
}

.publish-card .publish-beneficiary-user {
  flex: 1 1 auto;
  min-width: 0;
}

.publish-card .publish-beneficiary-pct {
  flex: 0 0 8.75rem;
  width: 8.75rem;
}

.publish-beneficiary-remove,
.publish-beneficiary-add {
  appearance: none;
  background: transparent;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  color: var(--gray);
  cursor: pointer;
  font-family: var(--font-display);
  font-weight: 700;
}

.publish-beneficiary-remove {
  flex: 0 0 2.55rem;
  width: 2.55rem;
  height: 2.55rem;
  font-size: 1.15rem;
  line-height: 1;
}

.publish-beneficiary-add {
  margin-top: 0.15rem;
  padding: 0.5rem 0.8rem;
  font-size: 0.58rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.publish-beneficiary-remove:hover,
.publish-beneficiary-add:hover {
  color: var(--yellow);
  border-color: var(--border-hot);
}

.publish-beneficiary-add:disabled {
  opacity: 0.45;
  cursor: default;
  color: var(--gray);
  border-color: var(--border);
}

.publish-actions {
  display: flex;
  gap: 0.75rem;
  flex-wrap: wrap;
  align-items: center;
  margin-bottom: 2rem;
}

.publish-actions .btn-ghost {
  display: inline-flex;
  align-items: center;
  text-decoration: none;
}

.publish-preview-wrap {
  margin-top: 0.5rem;
  padding-top: 1.75rem;
  border-top: 1px solid var(--border);
}

.publish-preview-wrap h2 {
  font-family: var(--font-display);
  font-size: 0.68rem;
  font-weight: 700;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--gray);
  margin-bottom: 1.15rem;
}

.publish-preview {
  background: var(--bg-panel-opaque);
  min-height: 4rem;
  padding: 1rem;
}

.publish-preview h1,
.publish-preview h2,
.publish-preview h3,
.publish-preview h4,
.publish-preview h5,
.publish-preview h6
 {
  font-family: var(--font-serif);
  font-weight: 400;
  font-size: clamp(1.7rem, 4vw, 2.3rem);
  letter-spacing: -0.02em;
  text-transform: none;
  color: var(--yellow);
  margin: 0 0 1.1rem;
}

.publish-status {
  font-family: var(--font-mono);
  font-size: 0.78rem;
  color: var(--yellow);
  margin: 0 0 1rem;
}

.publish-status.is-error {
  color: var(--red-bright);
}

.publish-status.is-publishing {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.publish-status.is-publishing::after {
  content: "";
  width: 32px;
  height: 32px;
  flex-shrink: 0;
  background-color: var(--gray);
  -webkit-mask: url("../assets/logo.svg") center / contain no-repeat;
  mask: url("../assets/logo.svg") center / contain no-repeat;
  animation: spin 1.6s linear infinite;
}

@media (prefers-reduced-motion: reduce) {
  .publish-status.is-publishing::after {
    animation: none;
  }
}

.publish-card.is-editing-comment #publishLocationBtn,
.publish-card.is-editing-comment #publishPollBtn,
.publish-card.is-editing-comment .publish-poll {
  display: none !important;
}

#publishLocationBtn.is-set,
#publishPollBtn.is-set {
  color: var(--yellow);
  border-color: var(--border-hot);
}

.publish-loc-tools {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  flex-wrap: nowrap;
}

.publish-poll-slot {
  display: contents;
}

.publish-poll {
  margin: 0 0 1rem;
}

.publish-poll > .publish-poll-choices-label {
  margin-top: 0;
}

.publish-poll-lock {
  display: none;
}

.publish-card.is-poll-locked .publish-poll-lock {
  display: block;
}

.publish-poll-lock-note {
  margin: 0 0 0.85rem;
  font-size: 0.75rem;
  line-height: 1.45;
  color: var(--gray);
}

.publish-card.is-poll-locked .publish-poll-lock .publish-field-label {
  margin-top: 0;
}

.publish-card.is-poll-locked #publishPollBtn:disabled {
  opacity: 1;
  cursor: default;
}

.publish-card.is-poll-locked .publish-poll input,
.publish-card.is-poll-locked .publish-poll select {
  cursor: default;
  opacity: 1;
  color: var(--yellow);
  -webkit-text-fill-color: var(--yellow);
}

.publish-card.is-poll-locked .publish-poll select {
  background-image: none;
  padding-right: 0.95rem;
}

.publish-card.is-poll-locked #publishPollAdd,
.publish-card.is-poll-locked .publish-poll-remove {
  display: none;
}

.publish-poll-choice {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  margin-bottom: 0.55rem;
}

.publish-poll-num {
  flex: 0 0 1.4rem;
  font-family: var(--font-mono);
  font-size: 0.95rem;
  color: var(--text-dim);
}

.publish-card .publish-poll-choice input {
  flex: 1 1 auto;
  width: auto;
  min-width: 0;
  margin-bottom: 0;
}

#publishPollAdd {
  margin-bottom: 1rem;
}

.publish-card .publish-poll input[type="number"] {
  -moz-appearance: textfield;
  appearance: textfield;
}

.publish-card .publish-poll input[type="number"]::-webkit-outer-spin-button,
.publish-card .publish-poll input[type="number"]::-webkit-inner-spin-button {
  -webkit-appearance: none;
  margin: 0;
  display: none;
}

.publish-card .publish-poll select {
  width: 100%;
  margin: 0 0 1rem;
  padding: 0.8rem 2.2rem 0.8rem 0.95rem;
  appearance: none;
  -webkit-appearance: none;
  background-color: var(--bg-input);
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 12 8'%3E%3Cpath d='M1 1.5 L6 6.5 L11 1.5' fill='none' stroke='%23d7d7d7' stroke-width='1.4'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 0.85rem center;
  background-size: 0.7rem;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  color: var(--yellow);
  font-family: var(--font-mono);
  font-size: 1rem;
  outline: none;
  cursor: pointer;
}

.publish-card .publish-poll select:focus {
  border-color: var(--red-bright);
  box-shadow: 0 0 0 1px rgba(227, 19, 55, 0.35), var(--glow-red);
}

.publish-md {
  position: relative;
  display: flex;
}

.publish-composer:has(.publish-md.is-open) {
  z-index: 6;
}

#publishMdBtn {
  letter-spacing: 0;
  min-width: 2.4rem;
  padding-left: 0.65rem;
  padding-right: 0.65rem;
}

#publishMdBtn[aria-expanded="true"] {
  color: var(--yellow);
  border-color: var(--border-hot);
}

.publish-md-menu {
  position: absolute;
  left: 0;
  top: calc(100% + 0.35rem);
  z-index: 8;
  min-width: 9.5rem;
  max-height: min(70vh, 28rem);
  overflow-y: auto;
  padding: 0.35rem;
  background: var(--bg-input);
  border: 1px solid var(--border-hot);
  border-radius: var(--radius);
  box-shadow: var(--glow-red), 0 12px 32px rgba(0, 0, 0, 0.45);
}

.publish-md-menu.is-up {
  top: auto;
  bottom: calc(100% + 0.35rem);
}

.publish-md-item {
  display: block;
  width: 100%;
  padding: 0.45rem 0.7rem;
  background: transparent;
  border: none;
  border-radius: 4px;
  color: var(--gray);
  font-family: var(--font-mono);
  font-size: 0.9rem;
  text-align: left;
  white-space: nowrap;
  cursor: pointer;
}

.publish-md-item:hover,
.publish-md-item:focus-visible {
  color: var(--yellow);
  background: rgba(227, 19, 55, 0.12);
}

#locationOverlay {
  z-index: 70;
  align-items: flex-start;
  overflow-y: auto;
  overscroll-behavior: contain;
}

.location-card {
  width: min(44rem, 100%);
  margin: auto;
  overflow: visible;
}

.location-search {
  position: relative;
  z-index: 5;
  margin-bottom: 0.75rem;
}

.location-search-row {
  display: flex;
  gap: 0.5rem;
  align-items: stretch;
  flex-wrap: wrap;
}

.location-card #locationSearch {
  flex: 1 1 12rem;
  width: auto;
  min-width: 0;
  margin-bottom: 0;
}

.location-card #locationSearch::-webkit-search-cancel-button {
  -webkit-appearance: none;
  appearance: none;
  height: 0.9rem;
  width: 0.9rem;
  margin-right: 0.1rem;
  background-color: var(--gray);
  -webkit-mask: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 12 12'><path stroke='%23000' stroke-width='1.6' d='M2.2 2.2 9.8 9.8M9.8 2.2 2.2 9.8'/></svg>") center / contain no-repeat;
  mask: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 12 12'><path stroke='%23000' stroke-width='1.6' d='M2.2 2.2 9.8 9.8M9.8 2.2 2.2 9.8'/></svg>") center / contain no-repeat;
  cursor: pointer;
}

.location-locate {
  appearance: none;
  flex: 0 0 auto;
  background: transparent;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 0.45rem 0.75rem;
  font-family: var(--font-display);
  font-size: 0.58rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--gray);
  cursor: pointer;
}

.location-locate:hover:not(:disabled) {
  color: var(--yellow);
  border-color: var(--border-hot);
}

.location-locate:disabled {
  opacity: 0.55;
  cursor: default;
}

.location-suggestions {
  position: absolute;
  left: 0;
  right: 0;
  top: calc(100% + 0.3rem);
  z-index: 2;
  max-height: 14rem;
  overflow-y: auto;
  background: var(--bg-panel-opaque);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: 0 12px 32px rgba(0, 0, 0, 0.45);
}

.location-suggestion,
.location-suggest-empty {
  display: block;
  width: 100%;
  text-align: left;
  background: transparent;
  border: 0;
  color: var(--text);
  font-family: var(--font-mono);
  font-size: 0.82rem;
  padding: 0.55rem 0.75rem;
  cursor: pointer;
}

.location-suggest-empty {
  cursor: default;
  color: var(--gray-dim);
}

.location-suggestion small {
  display: block;
  color: var(--gray-dim);
  font-size: 0.72rem;
}

.location-suggestion:hover,
.location-suggestion.is-active {
  background: rgba(227, 19, 55, 0.18);
  color: var(--yellow);
}

.location-map {
  position: relative;
  z-index: 1;
  height: 20rem;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
  background: #e8e4dc;
}

.location-map-canvas {
  position: absolute;
  inset: 0;
}

/* MapLibre's .maplibregl-map is position:relative and loads after this file.
   Two classes keep the canvas filling the frame; otherwise the box collapses
   to 0 height and clicks land on the frame instead of the map. */
.location-map-canvas.maplibregl-map {
  position: absolute;
  inset: 0;
  width: auto;
  height: auto;
}

.location-map[data-state="loading"]::before,
.location-map[data-state="error"]::before {
  content: "Loading map…";
  position: absolute;
  inset: 0;
  z-index: 2;
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: var(--font-mono);
  font-size: 0.78rem;
  color: #666;
  pointer-events: none;
}

.location-map[data-state="error"]::before {
  content: "Couldn't load the map.";
  color: var(--red-bright);
}

.location-pin {
  width: 30px;
  height: 42px;
  line-height: 0;
  pointer-events: none;
  filter: drop-shadow(0 2px 2px rgba(0, 0, 0, 0.35));
}

.location-pin svg {
  display: block;
}

.location-map .maplibregl-ctrl-bottom-left {
  z-index: 2;
}

.location-map .maplibregl-ctrl-attrib {
  font-size: 10px;
  line-height: 1.3;
  background: rgba(255, 255, 255, 0.9);
}

.location-map .maplibregl-ctrl-attrib a {
  color: #333;
}

.location-zoom {
  position: absolute;
  right: 0.6rem;
  bottom: 1.6rem;
  z-index: 3;
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
}

.location-zoom button {
  width: 2rem;
  height: 2rem;
  padding: 0;
  background: #fff;
  color: #222;
  border: 0;
  border-radius: 2px;
  font-family: var(--font-mono);
  font-size: 1.25rem;
  line-height: 1;
  cursor: pointer;
  box-shadow: 0 1px 4px rgba(0, 0, 0, 0.3);
}

.location-zoom button:hover {
  background: #f3f3f3;
}

.location-meta {
  display: flex;
  justify-content: space-between;
  gap: 0.75rem;
  margin: 0.45rem 0 0.85rem;
  font-family: var(--font-mono);
  font-size: 0.72rem;
  color: var(--gray-dim);
}

#locationCoords {
  flex: 0 0 auto;
  color: var(--yellow);
}

.location-card #locationDescription {
  margin-bottom: 0.85rem;
}

#locationSave:disabled {
  cursor: default;
}

.location-status {
  margin: 0 0 0.85rem;
}

.location-status.is-error {
  color: var(--red-bright);
}

/* Footer */
.footer {
  position: relative;
  z-index: 2;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1.25rem;
  width: 100%;
  padding: 1.75rem 1.5rem 2.25rem;
  text-align: center;
  background: transparent;
  border-top: 1px solid var(--border);
}

.social-links {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 0.85rem;
}

.about .social-links {
  justify-content: flex-start;
  margin: 0 0 0.55rem;
}

.btn-social {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0.55rem 1rem;
  background: transparent;
  border: none;
  border-radius: 0;
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 0.65rem;
  letter-spacing: 0.1em;
  text-decoration: none;
  text-transform: none;
  opacity: 0.75;
  transition: opacity 0.2s, color 0.2s, text-shadow 0.2s;
}

.btn-social::before,
.btn-social::after {
  content: "";
  position: absolute;
  width: 8px;
  height: 8px;
  pointer-events: none;
  transition: width 0.2s, height 0.2s, border-color 0.2s;
}

.btn-social::before {
  top: 0;
  left: 0;
  border-top: 1px solid currentColor;
  border-left: 1px solid currentColor;
}

.btn-social::after {
  right: 0;
  bottom: 0;
  border-right: 1px solid currentColor;
  border-bottom: 1px solid currentColor;
}

.btn-social:hover {
  opacity: 1;
}

.btn-social:hover::before,
.btn-social:hover::after {
  width: 12px;
  height: 12px;
}

.btn-social:active {
  opacity: 0.9;
}

.btn-social-red {
  color: var(--red-bright);
}

.btn-social-red:hover {
  text-shadow: 0 0 10px rgba(255, 42, 77, 0.45);
}

.btn-social-yellow {
  color: var(--yellow-dim);
}

.btn-social-gray {
  color: var(--gray);
}

.btn-social-yellow:hover,
.btn-social-gray:hover {
  color: var(--yellow);
  text-shadow: 0 0 10px rgba(255, 225, 74, 0.35);
}

.footer-meta {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 1rem;
  font-family: var(--font-mono);
  font-size: 0.65rem;
  letter-spacing: 0.16em;
  color: var(--gray);
}

.footer-link {
  color: var(--yellow);
  text-decoration: none;
}

.footer-link:hover {
  text-shadow: var(--glow-yellow);
  text-decoration: underline;
  text-underline-offset: 0.2em;
}

.footer-version {
  letter-spacing: 0.06em;
  color: var(--gray);
}

.scroll-top {
  position: fixed;
  right: 1.5rem;
  bottom: 1.75rem;
  z-index: 40;
  width: 3.25rem;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0;
  border: none;
  background: transparent;
  color: var(--yellow);
  cursor: pointer;
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transform: translateY(0.6rem);
  transition: opacity 0.2s, visibility 0.2s, transform 0.2s, color 0.2s, filter 0.2s;
}

.scroll-top.is-visible {
  opacity: 1;
  visibility: visible;
  pointer-events: auto;
  transform: none;
}

.scroll-top:hover {
  color: var(--red-bright);
  filter: drop-shadow(0 0 6px #ff2a4d) drop-shadow(0 0 16px rgba(227, 19, 55, 0.9));
}

.scroll-top:focus-visible {
  outline: 2px solid var(--yellow);
  outline-offset: 3px;
}

.scroll-top svg {
  width: 2.25rem;
  height: 2.25rem;
  display: block;
}

@media (prefers-reduced-motion: reduce) {
  .scroll-top {
    transition: none;
  }
}

@media (max-width: 720px) {
  .bg-hex {
    width: min(78vw, 420px);
    height: min(78vw, 420px);
    opacity: 0.22;
  }

  .app,
  .post-layer {
    padding: 1.5rem 1.1rem 2.5rem;
  }

  .header {
    flex-direction: column;
    align-items: stretch;
    justify-content: flex-start;
    padding: 0.85rem 1.1rem;
    gap: 0.55rem;
  }

  .header-right {
    justify-content: flex-end;
  }

  .logo-dropdown-link,
  .session-account-link {
    padding: 0.9rem 1.15rem;
  }

  .logo-settings-link {
    padding-top: calc(0.9rem - 2.2px);
    padding-bottom: calc(0.9rem - 2.2px);
  }

  .session-account-switch-btn {
    padding-top: calc(0.9rem - 0.16rem);
    padding-bottom: calc(0.9rem - 0.16rem);
  }

  .header-right > .node-menu {
    display: none;
  }

  .node-menu-in-menu {
    display: flex;
    flex-direction: column;
    align-items: stretch;
    margin: 0;
    align-self: stretch;
    max-width: 100%;
  }

  .node-menu-in-menu .status-pill {
    align-self: stretch;
    justify-content: flex-start;
    width: 100%;
    max-width: 100%;
    /* Same inset as .logo-dropdown-link in this breakpoint, so the dot lines up with those labels. */
    padding: 0.9rem 1.15rem;
    border: none;
    border-radius: 0;
    background: transparent;
    box-shadow: none;
  }

  .node-menu-in-menu .status-pill:hover {
    border-color: transparent;
    background: transparent;
    text-shadow: var(--glow-yellow);
  }

  .node-menu-in-menu .node-label {
    max-width: min(16rem, 52vw);
  }

  .node-menu-in-menu .node-dropdown {
    position: static;
    right: auto;
    padding-top: 0;
    width: 100%;
  }

  .node-menu-in-menu .node-dropdown-panel {
    min-width: 0;
    /* The logo panel already frosts the page. This list is inside that panel. */
    background: transparent;
    backdrop-filter: none;
    box-shadow: none;
    border: none;
    border-radius: 0;
  }

  .node-menu-in-menu .node-option {
    padding-left: 1.15rem;
    padding-right: 1.15rem;
  }

  #sessionSlot,
  .session-menu {
    position: static;
  }

  .session-dropdown {
    left: 1.1rem;
    right: 1.1rem;
    width: auto;
    max-width: none;
    padding-top: 0.4rem;
  }

  .session-dropdown-panel {
    max-height: calc(100dvh - 10rem - env(safe-area-inset-bottom, 0px));
    display: flex;
    flex-direction: column;
  }

  .session-notifs {
    flex: 1 1 auto;
    min-height: 0;
    max-height: none;
    overscroll-behavior: contain;
  }

  .post-card {
    padding: 1.25rem 1.1rem 1.15rem;
    gap: 0.7rem;
  }

  .card-meta {
    font-size: 0.78rem;
  }

  .card-meta .meta-time {
    margin-left: 0;
  }

  .post-card h2 {
    font-size: 2rem;
  }

  .article-stats > .content-more,
  .comment-actions > .content-more {
    flex-shrink: 0;
  }

  .reblog-list {
    display: inline-block;
  }

  .reblog-confirm-panel {
    max-width: min(22rem, calc(100vw - 16px));
  }

  .reblog-confirm-actions {
    flex-wrap: nowrap;
  }

  .card-thumb {
    height: auto;
    max-width: 100%;
    border-radius: 8px;
  }

  .article-stats {
    margin-left: 0;
  }

  .comment-replies {
    --thread-pad: 0.7rem;
    margin-left: 0.5rem;
  }

  /* One border, same width as the title and tag fields. The wrapper frame
     inset the textarea by its padding plus its own border. */
  .comment-composer,
  .comment-composer.is-dragover {
    padding: 0;
    border: none;
    border-radius: 0;
    box-shadow: none;
  }

  .comment-composer.is-dragover .composer-input {
    border-color: var(--yellow);
    box-shadow: 0 0 0 1px rgba(255, 225, 74, 0.35), var(--glow-yellow);
  }

  .composer-input {
    min-height: 8.5rem;
  }

  .publish-card .composer-input {
    min-height: 16rem;
  }

  .publish-beneficiary-row {
    flex-wrap: wrap;
  }

  .publish-card .publish-beneficiary-user {
    flex: 1 1 100%;
  }

  .publish-card .publish-beneficiary-pct {
    flex: 1 1 auto;
    width: auto;
  }

  .composer-bar .composer-actions {
    margin-left: 0;
    width: 100%;
  }

  .composer-bar .composer-actions .btn-compact {
    flex: 1;
  }

  .composer-bar .composer-actions .composer-submit {
    margin-left: 0.8rem;
    margin-right: 0.8rem;
  }

  .composer-hint {
    flex-basis: 100%;
  }

  .publish-card .publish-loc-tools {
    display: contents;
  }

  .publish-card:not(.is-editing-comment) .composer-bar {
    display: grid;
    grid-template-columns: max-content max-content max-content;
    justify-content: start;
    align-items: center;
  }

  .publish-card:not(.is-editing-comment) .composer-bar > .composer-attach {
    grid-column: 1;
    grid-row: 1;
  }

  .publish-card:not(.is-editing-comment) #publishLocationBtn {
    grid-column: 2;
    grid-row: 1;
  }

  .publish-card:not(.is-editing-comment) .publish-md {
    grid-column: 3;
    grid-row: 1;
  }

  .publish-card:not(.is-editing-comment) .publish-poll-slot {
    display: flex;
    align-items: center;
    grid-column: 1;
    grid-row: 2;
  }

  .publish-card:not(.is-editing-comment) .composer-hint {
    grid-column: 2 / 4;
    grid-row: 2;
    justify-self: end;
    align-self: center;
    flex: none;
    text-align: right;
  }

  .tags-add {
    flex-wrap: wrap;
  }

  .profile-banner {
    /* Cancel .app's 1.1rem side padding so the background is full-bleed.
       The extra 1.1rem of padding keeps the text at the same inset. */
    width: auto;
    margin-left: -1.1rem;
    margin-right: -1.1rem;
    padding-left: 2.2rem;
    padding-right: 2.2rem;
  }

  /* Account-menu comments, replies, and wallet. Cold loads keep the banner.
     The profile page clears .app's top padding, so the nav takes that 1.5rem. */
  body.is-account-sub .profile-banner:not(.community-banner) {
    display: none;
  }

  body.is-account-sub .profile-nav {
    padding-top: 1.5rem;
  }

  .profile-banner::before {
    background-size: min(78vw, 420px) min(78vw, 420px);
  }

  .profile-head {
    flex-direction: column;
    gap: 1rem;
  }

  .follow-list {
    grid-template-columns: minmax(0, 1fr);
  }

  .profile-head-actions {
    margin-top: 2.5rem;
  }

  .profile-stats .profile-joined .meta-time-pop {
    bottom: auto;
    top: calc(100% + 0.45rem);
  }

  .wallet-tx {
    flex-direction: column;
    gap: 0.35rem;
  }

  .wallet-tx-side {
    text-align: left;
  }

  .wallet-tx-time .session-stat-tip {
    left: 0;
    right: auto;
  }

  .wallet-row-actions {
    flex: 1 1 100%;
  }

  .wallet-table {
    width: 100%;
    max-width: 100%;
  }

  .wallet-delegation-row .wallet-label {
    white-space: normal;
  }

  .wallet-col-label {
    width: 100%;
  }

  .wallet-table td {
    padding: 0.75rem 0.5rem 0.75rem 0;
  }

  .wallet-table td.wallet-actions-inline {
    display: none;
  }

  .wallet-actions-under {
    display: table-row;
  }

  .wallet-table tr:has(+ .wallet-actions-under) td {
    border-bottom: none;
    padding-top: 1.15rem;
    padding-bottom: 1rem;
  }

  .wallet-delegated-panel > tr.wallet-delegation-row:has(+ .wallet-actions-under) > td {
    padding-top: 0.55rem;
    padding-bottom: 0.4rem;
  }

  .wallet-actions-under td.wallet-actions {
    padding-top: 0.35rem;
    padding-bottom: 1.25rem;
    text-align: right;
    white-space: normal;
    border-bottom: 1px solid var(--border);
  }

  .wallet-delegated-panel > tr.wallet-actions-under > td.wallet-actions {
    padding-top: 0.15rem;
    padding-bottom: 0.85rem;
  }

  .wallet-actions-under .wallet-actions-inner {
    flex-direction: column;
    align-items: flex-end;
    gap: 0.75rem;
  }

  .wallet-actions-under .wallet-actions-inner:has(.wallet-stake-btn),
  .wallet-actions-under .wallet-actions-inner:has(.wallet-delegate-btn) {
    align-items: stretch;
    justify-content: end;
  }

  .wallet-actions-under:has(+ .wallet-send-row) > td {
    border-bottom: none;
    padding-bottom: 0.45rem;
  }

  .wallet-send-row > td {
    padding-bottom: 1.25rem;
  }

  #communityMembers > .community-people-section:not([hidden]) ~ .community-people-section:not([hidden]) {
    margin-top: 3.25rem;
  }

  .community-table td {
    padding: 0.75rem 0.7rem 0.75rem 0;
  }

  .community-col-who {
    width: 46%;
  }

  .community-col-title {
    width: 32%;
  }

  .community-col-role {
    width: 22%;
  }

  .community-table,
  .community-table tbody {
    display: block;
  }

  .community-table tr.community-member {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    grid-template-areas:
      "who actions"
      "title role";
    align-items: start;
    border-bottom: 1px solid var(--border);
  }

  .community-table tr.community-member td {
    display: block;
    border-bottom: none;
    padding-top: 0.35rem;
    padding-bottom: 0.35rem;
  }

  .community-member-who {
    grid-area: who;
    padding-top: 0.75rem;
  }

  .community-member-actions {
    grid-area: actions;
    padding-top: 0.75rem;
    align-self: start;
  }

  .community-member-title {
    grid-area: title;
    padding-top: 0;
    padding-bottom: 0.75rem;
    overflow: visible;
    text-overflow: clip;
    white-space: normal;
    overflow-wrap: anywhere;
  }

  .community-title-btn {
    white-space: normal;
    overflow: visible;
    text-overflow: clip;
    overflow-wrap: anywhere;
  }

  .community-member-role {
    grid-area: role;
    justify-self: end;
    align-self: start;
    padding-top: 0;
    padding-bottom: 0.75rem;
    white-space: normal;
  }

  .community-member-title:empty,
  .community-member-role:empty {
    display: none;
  }

  .community-table:not(.is-team) tr.community-member:not(:has(.community-member-title:not(:empty))) .community-member-role {
    grid-column: 1;
    justify-self: start;
    text-align: left;
  }

  .community-table.is-team tr.community-member {
    grid-template-columns: minmax(0, 1fr) auto auto;
    grid-template-areas:
      "who role actions"
      "title title actions";
    row-gap: 0.2rem;
  }

  .community-table.is-team .community-member-who,
  .community-table.is-team .community-member-role,
  .community-table.is-team .community-member-actions {
    padding-top: 1.2rem;
    padding-bottom: 0.35rem;
  }

  .community-table.is-team .community-member-title {
    padding-top: 0;
    /* 28px avatar plus the author-link gap, so the title sits under @username. */
    padding-left: calc(28px + 0.55rem);
    padding-bottom: 1.2rem;
  }

  .community-table.is-team tr.community-member:not(:has(.community-member-title:not(:empty))) .community-member-who,
  .community-table.is-team tr.community-member:not(:has(.community-member-title:not(:empty))) .community-member-role,
  .community-table.is-team tr.community-member:not(:has(.community-member-title:not(:empty))) .community-member-actions {
    padding-bottom: 1.2rem;
  }

  /* An empty title cell stays in the grid (display:none loses to td { display:block }).
     Muted rows with no title drop that blank line. */
  .community-table.is-team tr.community-member[data-section="muted"]:not(:has(.community-member-title:not(:empty))) {
    grid-template-areas: "who role actions";
    grid-template-rows: auto;
    row-gap: 0;
  }

  .community-table.is-team tr.community-member[data-section="muted"]:not(:has(.community-member-title:not(:empty))) .community-member-title {
    display: none;
  }

  .community-table.is-team tr.community-member[data-section="muted"]:not(:has(.community-member-title:not(:empty))) .community-member-who,
  .community-table.is-team tr.community-member[data-section="muted"]:not(:has(.community-member-title:not(:empty))) .community-member-role,
  .community-table.is-team tr.community-member[data-section="muted"]:not(:has(.community-member-title:not(:empty))) .community-member-actions {
    padding-bottom: 0.75rem;
  }

  .community-table.is-team .community-member-role {
    grid-area: role;
    justify-self: end;
    align-self: center;
    text-align: right;
  }

  .community-table.is-flow,
  .community-table.is-flow tbody {
    display: block;
  }

  .community-table.is-flow tr.community-member {
    display: grid;
    height: auto;
  }

  .community-table.is-flow tr.community-member:not(:has(.community-member-title, .community-member-role, .community-member-actions)) {
    grid-template-areas: "who who";
    grid-template-rows: auto;
  }

  .community-table tr.community-table-empty {
    display: block;
  }

  .community-table tr.community-table-empty td {
    display: block;
    width: 100%;
  }

  .scroll-top {
    display: none;
  }

  .publish-fab {
    left: auto;
    right: 1.5rem;
    bottom: 1.5rem;
    width: 3.5rem;
    height: 3.5rem;
    min-width: 0;
    padding: 0;
    border-radius: 50%;
    letter-spacing: 0;
  }

  .publish-fab-label {
    display: none;
  }

  .publish-fab-icon {
    display: block;
  }

  /* Caption stays in the grid to hold its old width. The range covers that space, so the panel width does not change. */
  .vote-weight-caption {
    visibility: hidden;
    grid-area: 1 / 1;
    justify-self: start;
    align-self: center;
    box-sizing: content-box;
    width: max-content;
    max-width: none;
    white-space: nowrap;
    padding-right: calc(5.5rem + 0.65rem);
    pointer-events: none;
  }

  .vote-slider-slot {
    display: inline-grid;
    align-items: center;
    flex: 0 0 auto;
  }

  .vote-slider-line {
    grid-area: 1 / 1;
    width: 0;
    min-width: 100%;
  }

  .vote-slider {
    touch-action: none;
  }

  .vote-weight {
    max-width: 100%;
  }

  .downvote-weight {
    flex-wrap: wrap;
    white-space: normal;
  }
  
  .overlay {
    padding:1.5rem 0 0 0;
  }

  /* Publish meets the top of the screen. margin:auto would center a short card. */
  #publishOverlay {
    padding-top: 0;
  }

  #publishOverlay .publish-card {
    margin-top: 0;
  }

  #peopleOverlay,
  #pollVotesOverlay {
    flex-direction: column;
    align-items: stretch;
    justify-content: flex-start;
  }

  /* Bottom inset matches the sides so the votes panel border is not clipped. */
  #pollVotesOverlay {
    padding: 0.75rem 0.75rem max(0.75rem, env(safe-area-inset-bottom, 0px));
  }

  /* Followers, following, and subscribers fill the screen. */
  #peopleOverlay {
    padding: 0;
  }

  #peopleOverlay .people-card,
  #pollVotesOverlay .people-card {
    flex: 1 1 auto;
    width: 100%;
    min-height: 0;
    max-height: none;
    margin-bottom: 0;
  }

  #keyQrOverlay {
    flex-direction: column;
    align-items: stretch;
    justify-content: flex-start;
    padding: 0;
  }

  #keyQrOverlay .overlay-card.viewport-sheet {
    flex: 1 1 auto;
    display: flex;
    flex-direction: column;
    width: 100%;
    max-width: none;
    min-height: 0;
    max-height: none;
    margin: 0;
    overflow: hidden;
    padding-top: max(1.75rem, env(safe-area-inset-top, 0px));
    padding-bottom: max(1.25rem, env(safe-area-inset-bottom, 0px));
  }

  #keyQrOverlay .key-qr-view {
    flex: 1 1 auto;
    width: 100%;
    min-height: 12rem;
    max-height: none;
    aspect-ratio: auto;
  }

  #settingsKeyQrOverlay {
    flex-direction: column;
    align-items: stretch;
    justify-content: flex-start;
    padding: 0;
  }

  #settingsKeyQrOverlay .overlay-card.viewport-sheet {
    flex: 1 1 auto;
    display: flex;
    flex-direction: column;
    width: 100%;
    max-width: none;
    min-height: 0;
    max-height: none;
    margin: 0;
    overflow: hidden;
    padding-top: max(1.75rem, env(safe-area-inset-top, 0px));
    padding-bottom: max(1.25rem, env(safe-area-inset-bottom, 0px));
  }

  #settingsKeyQrOverlay .profile-qr-code {
    flex: 1 1 auto;
    width: 100%;
    min-height: 12rem;
  }

  #settingsKeyQrOverlay .profile-qr-code .qr-code {
    width: min(18rem, 72%);
  }

  /* A border on these sheets is a line against the viewport. Poll votes stay framed. */
  #peopleOverlay .people-card.viewport-sheet,
  #publishOverlay .publish-card.viewport-sheet,
  #zapOverlay .overlay-card.viewport-sheet,
  #lightningOverlay .overlay-card.viewport-sheet,
  #keyQrOverlay .overlay-card.viewport-sheet,
  #settingsKeyQrOverlay .overlay-card.viewport-sheet,
  #editHistoryOverlay .overlay-card.viewport-sheet,
  .vote-voters-panel.viewport-sheet {
    border: none;
    border-radius: 0;
    box-shadow: none;
  }

  .vote-voters-panel.viewport-sheet {
    position: fixed;
    z-index: 70;
    top: 0;
    right: 0;
    bottom: auto;
    left: 0;
    width: auto;
    min-width: 0;
    max-width: none;
    height: 100dvh;
    max-height: none;
    padding-bottom: max(0.45rem, env(safe-area-inset-bottom, 0px));
  }

  .vote-voters-panel.viewport-sheet .vote-voters-caption {
    padding-top: max(0.85rem, env(safe-area-inset-top, 0px));
  }

  #peopleOverlay .people-scroll,
  #pollVotesOverlay .people-scroll {
    flex: 1 1 auto;
    min-height: 0;
    max-height: none;
  }

  .people-card-head {
    grid-template-columns: minmax(0, 1fr) auto;
  }

  .people-card-head h2 {
    grid-column: 1;
    grid-row: 1;
  }

  .people-close {
    position: absolute;
    top: 1rem;
    right: 1rem;
    z-index: 2;
    grid-column: auto;
    grid-row: auto;
  }

  .people-card .people-search {
    grid-column: 1 / -1;
    grid-row: 2;
    /* Wider than the name list on the left, so the icon can sit 0.7rem
       inside the border, the same inset it uses on the right at desktop. */
    width: auto;
    max-width: none;
    margin-top: 0.7rem;
    margin-right: 0;
    margin-bottom: 0;
    margin-left: calc((28px - 1.45rem) / 2 - 0.7rem);
    justify-self: stretch;
  }

  /* Text still starts where @name starts. Padding grows by the left extension. */
  .people-card .people-search input {
    padding-left: calc(28px + 0.55rem - 1px - ((28px - 1.45rem) / 2 - 0.7rem));
    padding-right: 0.9rem;
  }

  .people-card .people-search .community-search-glass {
    right: auto;
    left: 0.7rem;
  }
}

/* Welcome flyer */
.has-welcome .hero {
min-height: 100lvh;
}

.has-welcome .hero-inner {
display: flex;
flex-direction: column;
width: 100%;
min-height: 100dvh;
}

.has-welcome .header-slot {
  flex: 0 0 auto;
}

.has-welcome .header::before {
  border-bottom-color: transparent;
}

.header.is-smart {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  width: 100%;
  z-index: 42;
  visibility: hidden;
  pointer-events: none;
  transition: visibility 0s linear 0.28s;
}

.header.is-smart.is-shown {
  visibility: visible;
  pointer-events: auto;
  transition: visibility 0s;
}

.header.is-smart::before {
  border-bottom-color: var(--border);
}

.header.is-smart::before,
.header.is-smart > * {
  opacity: 0;
  transform: translateY(-0.55rem);
  transition:
    opacity 0.28s ease,
    transform 0.28s ease;
}

.header.is-smart.is-shown::before,
.header.is-smart.is-shown > * {
  opacity: 1;
  transform: none;
}

.header.is-unhooking,
.header.is-unhooking::before,
.header.is-unhooking > * {
  transition: none !important;
}

@media (prefers-reduced-motion: reduce) {
  .header.is-smart::before,
  .header.is-smart > *,
  .header.is-smart.is-shown::before,
  .header.is-smart.is-shown > * {
    transition: none;
  }
}

.has-welcome .welcome-flyer {
flex: 1 0 auto;
min-height: 0;
}

.welcome-flyer {
  position: relative;
  z-index: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  box-sizing: border-box;
  padding: 1.25rem 1.5rem 5.5rem;
}

.welcome-title {
  max-width: 9em;
  font-family: var(--font-serif);
  font-weight: 400;
  font-size: clamp(2.75rem, 6vw, 6.75rem);
  line-height: 0.94;
  letter-spacing: -0.03em;
  color: var(--yellow);
  text-wrap: balance;
  text-shadow: 0 0 28px rgba(255, 225, 74, 0.16);
}

.welcome-lead {
  margin-top: 1.35rem;
  max-width: 28rem;
  font-family: var(--font-body);
  font-size: 0.98rem;
  font-weight: 400;
  line-height: 1.5;
  color: var(--gray-dim);
  text-wrap: balance;
}

.welcome-join {
  margin-top: 1.85rem;
  min-width: 9.5rem;
  text-decoration: none;
}

.welcome-down {
  position: absolute;
  left: 50%;
  bottom: 1.35rem;
  width: 2.25rem;
  height: 2.25rem;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0;
  border: 1px solid rgba(154, 154, 164, 0.45);
  border-radius: 999px;
  background: transparent;
  color: var(--gray-dim);
  cursor: pointer;
  animation: welcome-nudge 2.2s ease-in-out infinite;
}

.welcome-down svg {
  width: 1.15rem;
  height: 1.15rem;
  display: block;
}

.welcome-down:hover,
.welcome-down:focus-visible {
  color: var(--yellow);
  border-color: var(--yellow);
  animation-play-state: paused;
}

.welcome-down:focus-visible {
  outline: 2px solid var(--yellow);
  outline-offset: 3px;
}

@keyframes welcome-nudge {
  0%,
  100% {
    transform: translateX(-50%) translateY(0);
  }
  50% {
    transform: translateX(-50%) translateY(0.28rem);
  }
}

.has-welcome #view {
  min-height: 100vh;
  min-height: 100dvh;
}

.has-welcome #view .feed-nav {
  scroll-margin-top: 1.25rem;
}

@media (max-height: 700px) {
  .welcome-title {
    font-size: clamp(2.35rem, 9vh, 4.25rem);
  }

  .welcome-lead {
    margin-top: 0.9rem;
  }

  .welcome-join {
    margin-top: 1.15rem;
  }
}

@media (max-width: 720px) {
  .welcome-flyer {
    padding-left: 1.15rem;
    padding-right: 1.15rem;
  }

  .welcome-lead {
    font-size: 0.92rem;
  }
}

@media (prefers-reduced-motion: reduce) {
  .welcome-down {
    animation: none;
    transform: translateX(-50%);
  }
}

@media (max-width: 720px) {
  #locationOverlay {
    padding: 0.75rem;
  }

  .location-map {
    height: min(52vh, 22rem);
  }

  .location-locate {
    flex: 1 1 auto;
  }
}

.cs77-page {
  padding-top: 0.35rem;
}

.settings-form {
  max-width: 36rem;
}

.settings-field {
  margin-bottom: 1.15rem;
}

.settings-label {
  display: block;
  font-family: var(--font-display);
  font-size: 0.62rem;
  font-weight: 700;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--gray);
  margin: 0 0 0.4rem;
}

.settings-form .settings-label-white {
  color: #fff;
}

.settings-note {
  font-family: var(--font-mono);
  font-size: 0.75rem;
  line-height: 1.45;
  color: var(--gray-dim);
  margin: 0 0 0.7rem;
}

.settings-autoplay-field {
  margin-top: 1.15rem;
}

.settings-field .settings-note {
  margin-top: -0.05rem;
}

.settings-form input,
.settings-form textarea,
.settings-form select {
  display: block;
  width: 100%;
  padding: 0.8rem 0.95rem;
  background: var(--bg-input);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  color: var(--yellow);
  font-family: var(--font-mono);
  font-size: 1rem;
  line-height: 1.45;
  outline: none;
}

.settings-form textarea {
  resize: vertical;
  min-height: 6.5rem;
}

.settings-form textarea.settings-about {
  font-family: var(--font-body);
  font-size: 1.05rem;
  line-height: 1.55;
  color: var(--text);
}

.settings-form textarea.settings-custom {
  min-height: 12rem;
  font-size: 0.82rem;
}

.settings-form textarea.settings-custom[readonly] {
  cursor: default;
}

.settings-legacy-field .cyber-toggle {
  margin-top: 0.85rem;
}

.settings-form input:focus,
.settings-form textarea:focus,
.settings-form select:focus {
  border-color: var(--red-bright);
  box-shadow: 0 0 0 1px rgba(227, 19, 55, 0.35), var(--glow-red);
}

.settings-check {
  display: flex;
  align-items: center;
  gap: 0.7rem;
}

.settings-form .settings-check input[type="checkbox"] {
  width: 1.05rem;
  height: 1.05rem;
  min-width: 1.05rem;
  padding: 0;
  margin: 0;
  accent-color: var(--red);
  flex: 0 0 auto;
}

.settings-check .settings-label {
  margin: 0;
  cursor: pointer;
}

.community-panel h2.settings-section-title {
  font-family: var(--font-display);
  font-size: 0.8rem;
  font-weight: 700;
  letter-spacing: 0.03em;
  text-transform: none;
  color: var(--yellow);
  line-height: 1.45;
  margin: 0 0 1.25rem;
}

.community-panel h2.settings-section-line {
  display: flex;
  align-items: center;
  gap: 0.85rem;
  margin: 2.25rem 0 0.45rem;
}

.community-panel h2.settings-section-line::after {
  content: "";
  flex: 1 1 auto;
  height: 0;
  border-top: 1px solid #fff;
}

.settings-section-line + .settings-note {
  margin: 0 0 1.25rem;
}

.settings-form textarea.settings-custom:disabled {
  opacity: 0.5;
  cursor: default;
  color: var(--gray-dim);
  background: var(--bg-input);
  border-color: var(--border);
}

.settings-field select + .settings-note {
  margin-top: 0.55rem;
  margin-bottom: 0;
}

.settings-beneficiary {
  display: flex;
  flex-wrap: wrap;
  gap: 0.65rem;
  align-items: center;
}

.settings-form .settings-beneficiary > input {
  flex: 1 1 12rem;
  width: auto;
  min-width: 0;
}

.settings-form .community-tags {
  margin-bottom: 0;
}

.settings-form .community-tags input {
  flex: 1 1 8rem;
  width: auto;
  min-width: 7rem;
  margin: 0;
  padding: 0.35rem 0.4rem;
  border: none;
  background: transparent;
  box-shadow: none;
  color: var(--yellow);
  font-size: 0.95rem;
}

.settings-form .community-tags input:focus {
  border: none;
  box-shadow: none;
}

.settings-field .publish-tags-head .settings-label {
  margin: 0;
}

.cyber-toggle {
  position: relative;
  display: flex;
  align-items: center;
  gap: 0.85rem;
  margin: 0;
  padding: 0.7rem 0.85rem;
  background: transparent;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  cursor: pointer;
  user-select: none;
  transition: border-color 0.2s, box-shadow 0.2s, background 0.2s;
  text-transform: none;
  letter-spacing: normal;
  color: inherit;
  font-size: inherit;
}

.cyber-toggle:hover {
  border-color: var(--red-dim);
  background: rgba(227, 19, 55, 0.06);
}

.cyber-toggle:has(input:focus-visible) {
  border-color: var(--red-bright);
  box-shadow: 0 0 0 1px rgba(227, 19, 55, 0.35), var(--glow-red);
}

.cyber-toggle:has(input:checked) {
  border-color: var(--red-bright);
  background: rgba(227, 19, 55, 0.1);
  box-shadow: 0 0 16px rgba(227, 19, 55, 0.2);
}

.settings-form .cyber-toggle input,
#createAccountOverlay .cyber-toggle input,
#lightningOverlay .cyber-toggle input,
.cyber-toggle-compact input {
  position: absolute;
  opacity: 0;
  width: 1px;
  height: 1px;
  min-width: 0;
  margin: 0;
  padding: 0;
  border: none;
  box-shadow: none;
  pointer-events: none;
}

.cyber-toggle-track {
  flex-shrink: 0;
  width: 1px;
  height: 22px;
  border-radius: 4px;
  background: transparent;
  border: 1px solid var(--border);
  box-shadow: none;
  transition: border-color 0.2s, background 0.2s, box-shadow 0.2s;
}

.cyber-toggle input:checked + .cyber-toggle-track {
  background: linear-gradient(135deg, rgba(196, 16, 46, 0.55), rgba(255, 42, 77, 0.35));
  border-color: var(--red-bright);
  box-shadow:
    inset 0 0 8px rgba(0, 0, 0, 0.45),
    0 0 12px rgba(255, 42, 77, 0.35);
}

.cyber-toggle-copy {
  display: flex;
  flex-direction: column;
  gap: 0.15rem;
  min-width: 0;
}

.cyber-toggle-title {
  font-family: var(--font-display);
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--text-dim);
  transition: color 0.2s, text-shadow 0.2s;
}

.cyber-toggle input:checked ~ .cyber-toggle-copy .cyber-toggle-title {
  color: var(--yellow);
  text-shadow: var(--glow-yellow);
}

.cyber-toggle-compact {
  align-self: stretch;
  flex: 0 1 auto;
  gap: 0.5rem;
  max-width: 100%;
  height: auto;
  padding: 0 0.65rem;
}

.cyber-toggle-compact .cyber-toggle-track {
  height: 16px;
}

.cyber-toggle-compact .cyber-toggle-copy {
  gap: 0;
}

.cyber-toggle-compact .cyber-toggle-title {
  font-size: 0.64rem;
  line-height: 1;
  white-space: nowrap;
}

.subspace-create .subspace-account-start {
  padding-top: 1.35rem;
}

.subspace-create .settings-label.settings-section-line {
  display: flex;
  align-items: center;
  gap: 0.85rem;
}

.subspace-create .settings-label.settings-section-line span {
  flex: 0 0 auto;
  white-space: nowrap;
}

.subspace-create .settings-label.settings-section-line::after {
  content: "";
  flex: 1 1 auto;
  height: 0;
  border-top: 1px solid #fff;
}

.subspace-create .subspace-account-end {
  margin-bottom: 2.85rem;
}

.subspace-key-line {
  display: flex;
  align-items: center;
  gap: 0.65rem;
  margin-bottom: 0.55rem;
}

.settings-form .subspace-key-line input {
  flex: 1 1 auto;
  width: auto;
  min-width: 0;
  cursor: text;
}

.subspace-key-line .btn-compact {
  flex: 0 0 auto;
  align-self: center;
}

.subspace-name-status.is-ok {
  color: var(--yellow);
}

.subspace-name-status.is-bad {
  color: var(--red-bright);
}

.subspace-name-status:empty {
  display: none;
}

.cyber-toggle-sub {
  font-family: var(--font-mono);
  font-size: 0.68rem;
  letter-spacing: 0.04em;
  color: var(--text-muted);
  line-height: 1.3;
}

.community-edit .empty-state .btn-primary {
  margin-top: 1.15rem;
}

.settings-form input::placeholder {
  color: var(--gray-dim);
}

.settings-weight {
  display: flex;
  align-items: center;
  gap: 0.65rem;
}

.settings-weight input {
  flex: 0 0 auto;
  width: 6rem;
  min-width: 0;
  max-width: 6rem;
  -moz-appearance: textfield;
  appearance: textfield;
}

.settings-weight input::-webkit-outer-spin-button,
.settings-weight input::-webkit-inner-spin-button {
  -webkit-appearance: none;
  margin: 0;
  display: none;
}

.settings-weight-unit {
  font-family: var(--font-mono);
  color: var(--gray);
}

.settings-form select.settings-comment-sort {
  width: auto;
  min-width: 12rem;
}

#settingsGeneralForm .settings-zap-field {
  margin-top: 1.85rem;
  margin-bottom: 0;
}

#settingsGeneralForm .settings-browser-field {
  margin-top: 1.85rem;
  margin-bottom: 0;
}

#localDataStatus {
  margin-top: 0;
}

#localDataStatus.is-error {
  color: var(--red-bright);
}

#settingsGeneralForm h2.settings-section-line {
  display: flex;
  align-items: center;
  gap: 0.85rem;
  margin: 0 0 0.7rem;
  font-family: var(--font-display);
  font-size: 0.8rem;
  font-weight: 700;
  letter-spacing: 0.03em;
  text-transform: none;
  color: var(--yellow);
  line-height: 1.45;
}

#settingsGeneralForm h2.settings-section-line span {
  white-space: nowrap;
}

#settingsGeneralForm h2.settings-section-line::after {
  content: "";
  flex: 1 1 auto;
  height: 0;
  border-top: 1px solid #fff;
}

.settings-zap-gear {
  appearance: none;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 3.75rem;
  height: 3.75rem;
  margin: 0;
  padding: 0;
  border: 0;
  border-radius: 999px;
  background: transparent;
  color: var(--gray);
  cursor: pointer;
  touch-action: manipulation;
}

.settings-zap-gear svg {
  display: block;
  width: 3.15rem;
  height: 3.15rem;
}

.settings-zap-gear:hover,
.settings-zap-gear:focus-visible,
.settings-zap-gear.is-open {
  color: var(--yellow);
}

.settings-zap-gear:hover svg,
.settings-zap-gear:focus-visible svg,
.settings-zap-gear.is-open svg {
  filter: drop-shadow(0 0 6px rgba(255, 225, 74, 0.9));
}

.settings-zap-gear:focus-visible {
  outline: 1px solid var(--yellow);
  outline-offset: 3px;
}

.settings-media {
  display: flex;
  flex-wrap: wrap;
  gap: 0.85rem;
  align-items: flex-start;
}

.settings-avatar-preview {
  width: 72px;
  height: 72px;
  object-fit: cover;
  border-radius: 50%;
  border: 1px solid var(--border);
  flex: 0 0 auto;
}

.settings-media-main {
  flex: 1 1 12rem;
  min-width: 0;
}

.settings-media-actions {
  display: flex;
  gap: 0.5rem;
  margin-top: 0.55rem;
}

.settings-upload {
  appearance: none;
  background: transparent;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 0.45rem 0.75rem;
  font-family: var(--font-display);
  font-size: 0.58rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--gray);
  cursor: pointer;
}

.settings-upload:hover:not(:disabled) {
  color: var(--yellow);
  border-color: var(--border-hot);
}

.settings-upload:disabled {
  opacity: 0.45;
  cursor: default;
}

.settings-cover-preview {
  display: block;
  width: 100%;
  height: 7.5rem;
  object-fit: cover;
  border-radius: var(--radius);
  border: 1px solid var(--border);
  margin-bottom: 0.55rem;
}

.settings-cover-preview[hidden] {
  display: none;
}

.settings-social-field {
  margin-top: 1.85rem;
}

.settings-social-field h2.settings-label {
  font-family: var(--font-display);
  font-size: 0.62rem;
  font-weight: 700;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--gray);
  margin: 0 0 0.4rem;
}

.settings-social-row {
  display: flex;
  align-items: stretch;
  gap: 0.5rem;
  margin-bottom: 0.55rem;
}

.settings-form .settings-social-row .settings-social-type {
  flex: 0 0 calc(20ch + 1.9rem + 2px);
  width: calc(20ch + 1.9rem + 2px);
  min-width: 0;
}

/* Native select text starts 4px further in. Keep the 20-character box the same width. */
.settings-form .settings-social-row input.settings-social-type {
  padding-left: calc(0.95rem + 4px);
  padding-right: calc(0.95rem - 4px);
}

.settings-form .settings-social-row .settings-social-value {
  flex: 1 1 auto;
  width: auto;
  min-width: 0;
}

@media (max-width: 720px) {
  .settings-social-row {
    flex-wrap: wrap;
  }

  .settings-form .settings-social-row .settings-social-type {
    flex: 1 1 100%;
    width: 100%;
  }
}

.settings-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  align-items: center;
  margin-top: 0.35rem;
}

.settings-actions .btn-ghost:disabled {
  opacity: 0.45;
  cursor: default;
}

#settingsKeysForm h2.settings-section-line,
#settingsStoredKeys h2.settings-section-line,
#settingsApps h2.settings-section-line,
#settingsPasswordForm h2.settings-section-line,
#settingsRecoveryForm h2.settings-section-line,
#settingsRecoverRequestForm h2.settings-section-line,
#settingsRecoverConfirmForm h2.settings-section-line {
  display: flex;
  align-items: center;
  gap: 0.85rem;
  margin: 0 0 0.45rem;
  font-family: var(--font-display);
  font-size: 0.8rem;
  font-weight: 700;
  letter-spacing: 0.03em;
  text-transform: none;
  color: var(--yellow);
  line-height: 1.45;
}

#settingsKeysForm h2.settings-section-line span,
#settingsStoredKeys h2.settings-section-line span,
#settingsApps h2.settings-section-line span,
#settingsPasswordForm h2.settings-section-line span,
#settingsRecoveryForm h2.settings-section-line span,
#settingsRecoverRequestForm h2.settings-section-line span,
#settingsRecoverConfirmForm h2.settings-section-line span {
  white-space: nowrap;
}

#settingsKeysForm h2.settings-section-line::after,
#settingsStoredKeys h2.settings-section-line::after,
#settingsApps h2.settings-section-line::after,
#settingsPasswordForm h2.settings-section-line::after,
#settingsRecoveryForm h2.settings-section-line::after,
#settingsRecoverRequestForm h2.settings-section-line::after,
#settingsRecoverConfirmForm h2.settings-section-line::after {
  content: "";
  flex: 1 1 auto;
  height: 0;
  border-top: 1px solid #fff;
}

.settings-stored-keys {
  max-width: 36rem;
  margin-bottom: 2.35rem;
}

.settings-stored-list {
  list-style: none;
  margin: 0.85rem 0 0;
  padding: 0;
}

.settings-stored-key {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  margin: 0 0 0.7rem;
}

.settings-stored-key:last-child {
  margin-bottom: 0;
}

.settings-stored-key-role {
  flex: 0 0 5.5rem;
  font-family: var(--font-display);
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--gray);
}

.settings-stored-key-user {
  flex: 1 1 auto;
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  font-family: var(--font-mono);
  font-size: 0.95rem;
  color: var(--yellow);
}

.settings-stored-key-actions {
  display: inline-flex;
  flex: 0 0 auto;
  align-items: center;
  gap: 0.45rem;
}

.settings-stored-key-remove {
  appearance: none;
  flex: 0 0 auto;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 2.45rem;
  height: 2.45rem;
  margin: 0;
  padding: 0;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: transparent;
  color: var(--gray);
  font-family: var(--font-display);
  font-size: 1.15rem;
  font-weight: 700;
  line-height: 1;
  cursor: pointer;
}

.settings-stored-key-remove:hover:not(:disabled),
.settings-stored-key-remove:focus-visible {
  color: var(--yellow);
  border-color: var(--border-hot);
}

.settings-stored-key-remove:focus-visible {
  outline: 1px solid var(--yellow);
  outline-offset: 2px;
}

.settings-stored-key-remove:disabled {
  opacity: 0.45;
  cursor: default;
  color: var(--gray);
  border-color: var(--border);
}

#settingsStoredKeysList > .settings-note,
#settingsAppsList > .settings-note {
  margin-top: 0.85rem;
}

.settings-apps-weight {
  flex: 0 0 auto;
  font-family: var(--font-mono);
  font-size: 0.75rem;
  color: var(--gray-dim);
  white-space: nowrap;
}

.settings-keys-hint {
  margin: 0.85rem 0 0;
}

.settings-keys-fields {
  margin-top: 1.35rem;
  padding: 1.15rem 1.1rem 1rem;
  border: 1px solid var(--gray);
  border-radius: var(--radius);
}

#settingsKeysRows > .settings-field:last-child,
#settingsKeysRows > .settings-field:last-child .subspace-key-line {
  margin-bottom: 0;
}

.settings-keys-switch {
  display: flex;
  flex-wrap: wrap;
  gap: 0.45rem 1rem;
  margin: 0 0 1.15rem;
}

.settings-keys-switch button {
  appearance: none;
  -webkit-appearance: none;
  max-width: 100%;
  margin: 0;
  padding: 0.15rem 0;
  border: 0;
  border-bottom: 1px solid transparent;
  border-radius: 0;
  background: none;
  color: var(--text-dim);
  font-family: var(--font-mono);
  font-size: 0.82rem;
  font-weight: 400;
  letter-spacing: normal;
  text-transform: none;
  line-height: 1.35;
  text-shadow: none;
  cursor: pointer;
}

.settings-keys-switch button:hover,
.settings-keys-switch button.is-active {
  color: var(--gray);
  background: none;
  text-shadow: none;
}

.settings-keys-switch button.is-active {
  border-bottom-color: var(--gray);
}

.settings-keys-switch button:focus {
  outline: none;
}

.settings-keys-switch button:focus-visible {
  outline: 1px solid var(--yellow);
  outline-offset: 3px;
}

.settings-key-qr {
  flex: 0 0 auto;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 2.45rem;
  height: 2.45rem;
  margin: 0;
  padding: 0;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--bg-input);
  color: var(--gray);
  cursor: pointer;
}

.settings-key-qr svg {
  width: 1.15rem;
  height: 1.15rem;
  display: block;
}

.settings-key-qr:hover,
.settings-key-qr:focus-visible,
.settings-key-qr.is-open {
  color: var(--yellow);
  border-color: var(--red-bright);
}

.settings-key-qr:hover svg,
.settings-key-qr:focus-visible svg,
.settings-key-qr.is-open svg {
  filter: drop-shadow(0 0 6px rgba(255, 225, 74, 0.55));
}

.settings-key-qr:focus-visible {
  outline: 1px solid var(--yellow);
  outline-offset: 2px;
}

.settings-status {
  font-family: var(--font-mono);
  font-size: 0.78rem;
  line-height: 1.45;
  color: var(--gray);
  margin: 0.85rem 0 0;
}

.settings-status.is-error {
  color: var(--red-bright);
}

.settings-status:empty {
  display: none;
}

#settingsPasswordForm,
#settingsRecoveryForm,
#settingsRecoverRequestForm,
#settingsRecoverConfirmForm {
  margin-top: 2.35rem;
}

.settings-fold {
  margin: 0;
  padding: 0;
  border: 0;
  background: none;
}

.settings-fold > summary {
  margin: 0;
  padding: 0;
  list-style: none;
  cursor: pointer;
}

.settings-fold > summary::-webkit-details-marker {
  display: none;
}

.settings-fold > summary::marker {
  content: "";
}

.settings-fold > summary:focus {
  outline: none;
}

.settings-fold > summary:focus-visible {
  outline: 1px solid var(--yellow);
  outline-offset: 4px;
}

#settingsRecoveryForm .settings-fold > summary h2.settings-section-line,
#settingsRecoverRequestForm .settings-fold > summary h2.settings-section-line,
#settingsRecoverConfirmForm .settings-fold > summary h2.settings-section-line {
  margin-bottom: 0;
}

.settings-fold[open] > summary {
  margin-bottom: 0.45rem;
}

.settings-fold-mark {
  display: inline-block;
  width: 0.85rem;
  margin-right: 0.15rem;
  font-family: system-ui, sans-serif;
  font-weight: 400;
  color: var(--gray);
}

.settings-fold-mark::before {
  content: "\25b8";
}

.settings-fold[open] .settings-fold-mark::before {
  content: "\25be";
}

.settings-fold > summary:hover .settings-fold-mark,
.settings-fold[open] .settings-fold-mark {
  color: var(--yellow);
}

.settings-fold > .settings-note:first-of-type {
  margin: 0 0 1.25rem;
}

#settingsRecoveryCurrent {
  margin: 0.15rem 0 1rem;
  font-family: var(--font-mono);
  font-size: 0.95rem;
  line-height: 1.45;
  color: var(--text);
}

#settingsRecoveryCurrent a,
#settingsRecoveryPending a,
#settingsRecoverRequestInfo a,
#settingsRecoverConfirmInfo a {
  color: var(--yellow);
}

#settingsRecoverRequestInfo,
#settingsRecoverConfirmInfo {
  margin: 0.55rem 0 0;
  font-family: var(--font-mono);
  font-size: 0.95rem;
  line-height: 1.45;
  color: var(--text);
  overflow-wrap: anywhere;
}

#settingsRecoveryPending:not([hidden]) {
  margin-top: -0.35rem;
}

#settingsPasswordForm .settings-field > input + .settings-note,
#settingsRecoverRequestForm .settings-field > input + .settings-note,
#settingsRecoverConfirmForm .settings-field > input + .settings-note {
  margin-top: 0.55rem;
  margin-bottom: 0;
}

#settingsPasswordNext {
  margin-top: 1.15rem;
}

.settings-password-health {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  margin: 0.15rem 0 0.7rem;
}

.settings-password-health[hidden] {
  display: none;
}

.settings-password-health-track {
  flex: 1 1 auto;
  height: 0.35rem;
  overflow: hidden;
  border-radius: 999px;
  background: var(--gray-result);
}

.settings-password-health-level {
  display: block;
  height: 100%;
  width: var(--password-health, 0%);
  max-width: 100%;
  border-radius: inherit;
  background: var(--yellow);
}

.settings-password-health.is-low .settings-password-health-level {
  background: var(--red-bright);
}

.settings-password-health.is-mid .settings-password-health-level {
  background: var(--yellow-dim);
}

.settings-password-health.is-some .settings-password-health-level {
  min-width: 2px;
}

.settings-password-health-bits {
  flex: 0 0 auto;
  font-family: var(--font-mono);
  font-size: 0.75rem;
  line-height: 1.2;
  color: var(--gray-dim);
  white-space: nowrap;
}

#settingsPasswordForm .cyber-toggle {
  margin: 0.15rem 0 1.15rem;
}

#settingsPasswordWarn {
  margin: 0.85rem 0 0;
}

.settings-node-row {
  display: flex;
  align-items: stretch;
  gap: 0.5rem;
  margin-bottom: 0.55rem;
}

.settings-form .settings-node-row input {
  flex: 1 1 auto;
  width: auto;
  min-width: 0;
}

.settings-node-url[readonly] {
  cursor: default;
}

.settings-node-remove,
.settings-node-add {
  appearance: none;
  background: transparent;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  color: var(--gray);
  cursor: pointer;
  font-family: var(--font-display);
  font-weight: 700;
}

.settings-node-remove {
  flex: 0 0 2.75rem;
  width: 2.75rem;
  padding: 0;
  font-size: 1.15rem;
  line-height: 1;
}

.settings-node-add {
  margin-top: 0.15rem;
  padding: 0.5rem 0.8rem;
  font-size: 0.58rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.settings-node-remove:hover:not(:disabled),
.settings-node-add:hover:not(:disabled) {
  color: var(--yellow);
  border-color: var(--border-hot);
}

.settings-node-remove:disabled,
.settings-node-add:disabled,
.settings-node-url:disabled {
  opacity: 0.45;
  cursor: default;
  color: var(--gray);
  border-color: var(--border);
}

.settings-page .empty-state {
  max-width: 36rem;
}

.settings-page .empty-state .btn-primary {
  margin-top: 1.15rem;
}

.poll {
  margin-top: 0;
}

.poll-question {
  margin: 0 0 0.65rem;
  font-family: var(--font-body);
  font-size: 1.22rem;
  line-height: 1.75;
  color: var(--gray);
  overflow-wrap: break-word;
}

.poll-choices {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.poll-choice {
  appearance: none;
  position: relative;
  display: flex;
  align-items: center;
  width: 100%;
  min-height: 2.85rem;
  margin: 0;
  padding: 0.72rem 0.95rem;
  border: 1px solid #2a2a2a;
  border-radius: 10px;
  background: var(--gray-choice);
  color: var(--text);
  font-family: var(--font-body);
  font-size: 1.05rem;
  line-height: 1.35;
  text-align: left;
  cursor: pointer;
  overflow: hidden;
}

.poll-choice:not(.is-locked):hover {
  border-color: var(--yellow);
}

.poll-choice.is-picked {
  padding-left: 2.35rem;
}

.poll-choice.is-winner .poll-choice-label,
.poll-choice.is-winner .poll-choice-stat {
  color: var(--yellow);
  font-weight: 700;
}

.poll-choice.is-locked {
  cursor: default;
}

.poll.is-pending .poll-choice,
.poll.is-pending .poll-submit {
  cursor: progress;
}

.poll-choice:focus-visible,
.poll-results-link:focus-visible,
.poll-submit:focus-visible,
.poll-count:focus-visible {
  outline: 1px solid var(--yellow);
  outline-offset: 2px;
}

.poll-choice-fill {
  position: absolute;
  inset: 0 auto 0 0;
  width: 0;
  border-radius: inherit;
  background: var(--gray-result);
}

.poll.is-results .poll-choice-fill {
  width: var(--poll-pct, 0%);
}

.poll-choice-mark {
  position: absolute;
  left: 0.72rem;
  top: 50%;
  z-index: 1;
  display: flex;
  width: 1.15rem;
  height: 1.15rem;
  color: var(--yellow);
  opacity: 0;
  transform: translateY(-50%);
}

.poll-choice-mark svg {
  display: block;
  width: 1.15rem;
  height: 1.15rem;
}

.poll-choice.is-picked .poll-choice-mark {
  opacity: 1;
}

.poll-choice-label,
.poll-choice-stat {
  position: relative;
  z-index: 1;
}

.poll-choice-label {
  min-width: 0;
}

.poll-choice-stat {
  margin-left: auto;
  padding-left: 0.85rem;
  font-family: var(--font-mono);
  font-size: 0.92rem;
  color: var(--text);
  opacity: 0;
  font-variant-numeric: tabular-nums;
}

.poll.is-results .poll-choice-stat {
  opacity: 1;
}

.poll-results-link,
.poll-submit {
  appearance: none;
  border: 0;
  background: transparent;
  cursor: pointer;
}

.poll-results-link {
  display: block;
  width: fit-content;
  margin: 0.7rem 0 0;
  padding: 0.15rem 0;
  color: var(--yellow);
  font-family: var(--font-mono);
  font-size: 0.84rem;
}

.poll-results-link:hover {
  text-shadow: var(--glow-yellow);
}

.poll-submit {
  align-self: flex-start;
  margin: 0.75rem 0 0;
  padding: 0.48rem 0.95rem;
  border: 1px solid var(--yellow);
  border-radius: 999px;
  color: var(--yellow);
  font-family: var(--font-display);
  font-size: 0.62rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.poll-submit:hover:not(:disabled) {
  background: rgba(255, 225, 74, 0.12);
}

.poll-meta,
.poll-note {
  font-family: var(--font-mono);
  font-size: 0.78rem;
  line-height: 1.45;
  color: var(--text-dim);
}

.poll-meta {
  margin: 0.7rem 0 0;
}

.poll-meta .poll-count {
  appearance: none;
  -webkit-appearance: none;
  display: inline;
  margin: 0;
  padding: 0;
  border: 0;
  background: none;
  font: inherit;
  letter-spacing: inherit;
  line-height: inherit;
  color: inherit;
  text-shadow: none;
  cursor: pointer;
}

.poll-meta .poll-count:hover,
.poll-meta .poll-count.is-active {
  color: var(--yellow);
  text-shadow: var(--glow-yellow);
}

.poll-note {
  margin: 0.4rem 0 0;
  color: var(--gray-dim);
}

.poll-note:empty,
.poll-meta:empty {
  display: none;
}

@media (prefers-reduced-motion: no-preference) {
  .poll-choice-fill {
    transition: width 0.6s cubic-bezier(0.22, 0.8, 0.28, 1);
  }

  .poll-choice-stat {
    transition: opacity 0.35s ease 0.12s;
  }
}

/* Embed dialog and the transparent /embed/@author/permlink card. */
#embedCode {
  display: block;
  width: 100%;
  min-height: 8.5rem;
  padding: 0.8rem 0.95rem;
  margin: 0 0 1rem;
  background: var(--bg-input);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  color: var(--yellow);
  font-family: var(--font-mono);
  font-size: 0.82rem;
  line-height: 1.45;
  resize: vertical;
  outline: none;
}

#embedCode:focus {
  border-color: var(--red-bright);
  box-shadow: 0 0 0 1px rgba(227, 19, 55, 0.35), var(--glow-red);
}

#editHistoryOverlay {
  align-items: safe center;
  overflow-y: auto;
  overscroll-behavior: contain;
}

#editHistoryOverlay .edit-history-card {
  width: min(56rem, 100%);
  margin-bottom: 0;
}

.edit-history-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
  margin-bottom: 0.9rem;
}

.edit-history-head h2 {
  margin: 0;
}

#editHistoryOverlay .cyber-toggle-compact {
  align-self: center;
  flex: 0 0 auto;
  min-height: 0;
  padding: 0;
  border: none;
  background: transparent;
  box-shadow: none;
}

#editHistoryOverlay .cyber-toggle-compact:hover,
#editHistoryOverlay .cyber-toggle-compact:has(input:focus-visible),
#editHistoryOverlay .cyber-toggle-compact:has(input:checked) {
  border: none;
  background: transparent;
  box-shadow: none;
}

#editHistoryOverlay .cyber-toggle-compact:has(input:focus-visible) .cyber-toggle-track {
  border-color: var(--red-bright);
}

.edit-history-body {
  display: flex;
  align-items: stretch;
  gap: 0.85rem;
  margin-bottom: 0.85rem;
}

.edit-history-versions {
  flex: 0 0 14.5rem;
  width: 14.5rem;
  max-height: min(28rem, 58vh);
  overflow: auto;
  overscroll-behavior: contain;
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
  /* Keeps a long list's scrollbar off the version borders. */
  padding-right: 0.4rem;
}

.edit-history-version {
  appearance: none;
  display: block;
  width: 100%;
  margin: 0;
  padding: 0.55rem 0.65rem;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: transparent;
  color: var(--gray);
  font-family: var(--font-mono);
  font-size: 0.72rem;
  line-height: 1.35;
  text-align: left;
  cursor: pointer;
}

.edit-history-version:hover,
.edit-history-version:focus-visible {
  border-color: var(--red-dim);
  color: var(--yellow);
}

/* The list scrolls, so an outer ring is cut off at the edges. */
.edit-history-version:focus-visible {
  outline: 1px solid var(--yellow);
  outline-offset: -3px;
}

.edit-history-version.is-selected {
  border-color: var(--red-bright);
  background: rgba(227, 19, 55, 0.12);
  color: var(--yellow);
  box-shadow: 0 0 12px rgba(227, 19, 55, 0.2);
}

.edit-history-version-name,
.edit-history-version-time {
  display: block;
  overflow-wrap: anywhere;
}

.edit-history-version-name {
  font-family: var(--font-display);
  font-size: 0.62rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.edit-history-version-time {
  color: var(--text-dim);
  font-size: 0.68rem;
}

.edit-history-version-name + .edit-history-version-time {
  margin-top: 0.2rem;
}

.edit-history-version.is-selected .edit-history-version-time {
  color: var(--gray);
}

#editHistoryText {
  display: block;
  flex: 1 1 auto;
  width: auto;
  min-width: 0;
  height: min(28rem, 58vh);
  min-height: min(28rem, 58vh);
  margin: 0;
  padding: 0.8rem 0.95rem;
  overflow-x: hidden;
  overflow-y: scroll;
  overscroll-behavior: contain;
  scrollbar-gutter: stable;
  scrollbar-width: thin;
  background: var(--bg-input);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  color: var(--text);
  font-family: var(--font-mono);
  font-size: 0.82rem;
  line-height: 1.45;
  white-space: pre-wrap;
  overflow-wrap: anywhere;
  outline: none;
}

#editHistoryText:focus {
  border-color: var(--red-bright);
  box-shadow: 0 0 0 1px rgba(227, 19, 55, 0.35), var(--glow-red);
}

.edit-history-del,
.edit-history-add {
  padding: 0 0.12em;
  border-radius: 2px;
  box-decoration-break: clone;
  -webkit-box-decoration-break: clone;
}

.edit-history-del {
  color: #fff;
  background: var(--red);
  text-decoration-line: line-through;
  text-decoration-color: #fff;
}

.edit-history-add {
  color: #1a1204;
  background: var(--yellow);
}

@media (max-width: 720px) {
  #editHistoryOverlay {
    flex-direction: column;
    align-items: stretch;
    justify-content: flex-start;
    padding: 0;
    overflow: hidden;
  }

  #editHistoryOverlay .edit-history-card.viewport-sheet {
    flex: 1 1 auto;
    display: flex;
    flex-direction: column;
    width: 100%;
    max-width: none;
    height: 100%;
    min-height: 0;
    max-height: none;
    margin: 0;
    overflow: hidden;
    padding-top: max(1.75rem, env(safe-area-inset-top, 0px));
    padding-bottom: max(1.25rem, env(safe-area-inset-bottom, 0px));
  }

  .edit-history-head {
    flex-wrap: wrap;
  }

  #editHistoryOverlay .edit-history-body {
    flex: 1 1 auto;
    flex-direction: column;
    min-height: 0;
  }

  #editHistoryOverlay .edit-history-versions {
    flex: 0 0 auto;
    width: 100%;
    min-height: 0;
    /* 25vh: sheet chrome is about 11rem, so the revision text keeps about half the screen. */
    max-height: min(18rem, 25vh);
    padding-right: 0;
  }

  #editHistoryText {
    flex: 1 1 0;
    width: 100%;
    height: auto;
    min-height: 0;
  }
}

html.is-embed,
html.is-embed body {
  height: auto;
  min-height: 0;
  background: transparent;
  background-color: transparent;
  color-scheme: normal;
}

html.is-embed {
  overflow: hidden;
}

html.is-embed body {
  display: block;
  margin: 0;
  overflow: hidden;
}

html.is-embed .hero,
html.is-embed .footer,
html.is-embed .bg-hex,
html.is-embed .scanlines,
html.is-embed .publish-fab,
html.is-embed .scroll-top,
html.is-embed .post-layer,
html.is-embed .welcome-flyer {
  display: none !important;
}

html.is-embed .app {
  height: auto;
  min-height: 0;
  flex: none;
  max-width: none;
  margin: 0;
  padding: 32px 20px;
  display: block;
  overflow: visible;
  background: transparent;
}

html.is-embed #view {
  width: 100%;
  max-width: 36rem;
  margin: 0 auto;
}

a.embed-card,
a.embed-card:hover {
  color: inherit;
  text-shadow: none;
}

html.is-embed .embed-card,
html.is-embed .embed-card:hover,
html.is-embed .embed-card:focus {
  background: var(--bg-panel-opaque);
  border-color: var(--red);
  box-shadow: none;
  overflow: visible;
  padding: 1.7rem 1.55rem 1.45rem;
  gap: 0.85rem;
}

a.embed-card:focus-visible,
.embed-hit:focus-visible {
  outline: 1px solid var(--yellow);
  outline-offset: 3px;
}

.embed-hit {
  position: absolute;
  inset: 0;
  z-index: 1;
}

html.is-embed .embed-card .embed-speak,
html.is-embed .embed-card .embed-file {
  position: relative;
  z-index: 2;
}

html.is-embed .embed-card .card-meta {
  flex-wrap: nowrap;
  align-items: flex-start;
}

.embed-meta {
  display: flex;
  flex: 1 1 auto;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.55rem;
  min-width: 0;
}

html.is-embed .embed-card .embed-meta > * {
  max-width: 100%;
}

html.is-embed .embed-card .embed-meta .author-link {
  flex-shrink: 1;
}

html.is-embed .embed-card .embed-meta .author-name,
html.is-embed .embed-card .embed-meta .community {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.embed-mark {
  display: inline-flex;
  align-items: center;
  flex: 0 0 auto;
  margin-left: auto;
  color: var(--yellow);
  line-height: 0;
  filter: drop-shadow(0 0 6px rgba(255, 42, 77, 0.7));
  pointer-events: none;
  transition: filter 0.25s ease, color 0.25s ease;
}

html.has-mouse .embed-card:hover .embed-mark,
.embed-card:focus-visible .embed-mark {
  color: var(--red-bright);
  filter:
    drop-shadow(0 0 6px #ff2a4d)
    drop-shadow(0 0 16px rgba(227, 19, 55, 0.9))
    drop-shadow(0 0 28px rgba(227, 19, 55, 0.55));
}

.embed-mark-logo {
  width: 36px;
  height: 36px;
  display: block;
  overflow: visible;
  transform-origin: center;
  transition: transform 0.45s ease;
}

.embed-mark-logo.is-spinning {
  transition: none;
}

.embed-status {
  margin: 0.35rem 0;
  font-family: var(--font-mono);
  font-size: 0.9rem;
  line-height: 1.45;
  color: var(--gray);
}

html.is-embed .embed-card .card-meta .meta-time {
  margin-left: 0;
}

html.is-embed .embed-card .card-thumb {
  flex: none;
  width: 100%;
  height: auto;
  min-height: 0;
  max-height: 480px;
  object-fit: cover;
}

/* Under the card link and the video hit, so a click still opens the post. */
html.is-embed .embed-card .embed-stats {
  z-index: 0;
  pointer-events: none;
}

body.is-dao #view {
  max-width: none;
}

.dao-page .page-title {
  margin-bottom: 0.35rem;
}

.dao-kicker {
  margin: 0 0 1.1rem;
  font-family: var(--font-display);
  font-size: 0.68rem;
  font-weight: 600;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--yellow);
}

.dao-copy,
.dao-note,
.dao-about,
.dao-page .search-form,
.dao-page .tags-status,
.dao-stats,
.dao-choices,
.dao-facts,
.dao-actions,
.dao-rank,
.dao-supporters,
.dao-create {
  max-width: 40rem;
}

.dao-copy p,
.dao-note,
.dao-about {
  font-family: var(--font-body);
  font-size: 1.15rem;
  line-height: 1.65;
  color: var(--gray);
}

.dao-copy p,
.dao-note,
.dao-about {
  margin: 0 0 1.15rem;
}

.dao-about {
  white-space: pre-wrap;
  overflow-wrap: anywhere;
}

.dao-rank {
  margin: 0 0 0.85rem;
  font-family: var(--font-mono);
  font-size: 0.95rem;
  color: var(--yellow);
}

.proposal-phase {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 0.45rem 0.75rem;
  max-width: 40rem;
  margin: 0 0 0.85rem;
}

.proposal-phase-label {
  font-family: var(--font-mono);
  font-size: 0.95rem;
  line-height: 1.4;
  color: var(--yellow);
}

.proposal-phase .proposal-support {
  position: relative;
  display: flex;
  align-items: center;
  flex: none;
  width: 6.5rem;
  height: 1.05rem;
  cursor: default;
}

.proposal-phase:has(.proposal-support:hover),
.proposal-phase:has(.proposal-support:focus),
.proposal-phase:has(.proposal-support:focus-visible) {
  position: relative;
  z-index: 8;
}

.dao-page .tags-status {
  margin: -0.35rem 0 1rem;
}

.dao-page #witnessSearchForm,
.dao-page #proposalSearchForm {
  max-width: 14rem;
}

.dao-page #proposalSearchForm {
  margin: 0 0 1.15rem;
}

.dao-stats,
.dao-choices,
.dao-facts {
  display: grid;
  gap: 0.7rem;
  margin: 0 0 1.15rem;
}

.proposal-rates {
  max-width: 40rem;
  margin: 1.15rem 0 0;
}

.proposal-rates p {
  margin: 0 0 0.4rem;
  font-family: var(--font-body);
  font-size: 1.05rem;
  line-height: 1.45;
  color: var(--gray);
}

.proposal-rates ul + p {
  margin-top: 0.9rem;
}

.proposal-rates ul {
  margin: 0;
  padding: 0;
  list-style: none;
}

.proposal-rates li {
  display: flex;
  flex-wrap: wrap;
  gap: 0.2rem 0.75rem;
  margin: 0.18rem 0 0;
  font-family: var(--font-mono);
  font-size: 0.9rem;
  color: var(--text);
}

.proposal-rates li span {
  color: var(--gray);
}

.dao-stats {
  grid-template-columns: repeat(4, minmax(0, 1fr));
}

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

.dao-facts {
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0.85rem 1.2rem;
}

.dao-stat,
.dao-choice {
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 0.75rem 0.85rem;
  min-width: 0;
}

a.dao-stat-treasury {
  display: block;
  color: inherit;
  text-shadow: none;
}

a.dao-stat-treasury:hover,
a.dao-stat-treasury:focus-visible {
  border-color: var(--yellow);
  color: inherit;
  text-shadow: none;
}

.dao-stat-label,
.dao-choice small,
.dao-facts dt {
  display: block;
  font-family: var(--font-display);
  font-size: 0.62rem;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--gray-dim);
}

.dao-stat-label,
.dao-stat-unit {
  text-transform: none;
}

.dao-stat strong {
  display: block;
  margin-top: 0.28rem;
  font-family: var(--font-mono);
  font-size: 1.25rem;
  font-weight: 400;
  color: var(--yellow);
}

.dao-stat-unit {
  font-family: var(--font-mono);
  font-size: 0.75rem;
  color: var(--gray-dim);
}

.dao-choice {
  display: flex;
  flex-direction: column;
  gap: 0.3rem;
  color: var(--yellow);
  font-family: var(--font-serif);
  font-size: 1.55rem;
  line-height: 1.15;
}

.dao-choice:hover {
  border-color: var(--border-hot);
  text-shadow: none;
}

.dao-choice small {
  color: var(--gray);
}

.dao-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.75rem;
  margin: 0 0 0.85rem;
}

.dao-facts {
  margin: 0;
}

.dao-facts div {
  min-width: 0;
}

.dao-facts dd {
  margin: 0.2rem 0 0;
  font-family: var(--font-mono);
  font-size: 0.95rem;
  color: var(--gray);
  overflow-wrap: anywhere;
}

.dao-facts a {
  color: var(--yellow);
}

.dao-disabled {
  color: var(--red-bright);
}

.dao-supporters {
  margin-top: 1.7rem;
}

.dao-supporters .dao-kicker {
  margin-bottom: 0.45rem;
}

.dao-supporters .dao-note {
  margin-bottom: 0.75rem;
}

.dao-page #proposalSupporterLoad,
.dao-page #proposalSupporterRetry {
  margin: 0 0 0.85rem;
}

.dao-supporter-loading {
  justify-content: flex-start;
  padding: 0.15rem 0 0.85rem;
}

.dao-table {
  width: 100%;
  border-collapse: collapse;
  margin: 0;
  font-family: var(--font-body);
  font-size: 0.95rem;
  line-height: 1.75;
  background: transparent;
}

.dao-table th,
.dao-table td {
  border: 1px solid var(--border);
  padding: 0.55rem 0.75rem;
  color: var(--gray);
  background: transparent;
  text-align: left;
  font-weight: 400;
}

.dao-table th {
  font-weight: 700;
  text-align: center;
}

.dao-table td.dao-rank {
  text-align: center;
}

.dao-table td:last-child {
  text-align: right;
}

.dao-table small {
  display: block;
  margin-top: 0.15rem;
  font-size: 0.85rem;
  line-height: 1.45;
  color: var(--gray);
}

.dao-rank-inline,
.dao-who-label {
  display: none;
}

@media (max-width: 720px) {
  .dao-table .dao-rank {
    display: none;
  }

  .dao-rank-inline,
  .dao-who-label {
    display: inline;
  }

  .dao-rank-inline {
    white-space: nowrap;
  }

  .dao-account-label {
    display: none;
  }

  .dao-table th.dao-account,
  .dao-table td.dao-account {
    padding-left: 0.3rem;
    padding-right: 0.35rem;
    overflow-wrap: anywhere;
  }

  .dao-table th:last-child,
  .dao-table td:last-child {
    /* 1% shrinks the column to the stake text. A fixed width left a gap beside it. */
    width: 1%;
    white-space: nowrap;
    text-align: right;
    padding-left: 0.4rem;
    padding-right: 0.7rem;
  }
}

.dao-create {
  margin: 0 0 1.15rem;
}

.dao-tools {
  display: flex;
  align-items: center;
  gap: 0.15rem;
  max-width: 40rem;
  margin: 0 0 1.75rem;
}

.dao-page .dao-tools #witnessSearchForm,
.dao-page .dao-tools #proposalSearchForm {
  flex: 0 1 14rem;
  width: 14rem;
  max-width: calc(100% - 2.4rem);
  margin: 0;
}

.dao-tools:has(#proposalSearchForm) {
  flex-wrap: wrap;
  column-gap: 0.35rem;
  row-gap: 0.45rem;
  margin-bottom: 1.15rem;
}

.dao-proposal-side {
  display: flex;
  align-items: center;
  align-self: stretch;
  gap: 0.35rem;
  flex: 0 1 auto;
  min-width: 0;
  max-width: 100%;
}

.dao-tools .proposal-sort {
  margin: 0;
  flex: 0 0 auto;
  z-index: 1;
}

.dao-tools .proposal-sort[hidden] {
  display: none;
}

.dao-tools .proposal-sort.is-open {
  z-index: 9;
}

.dao-tools .proposal-sort .comment-sort-menu {
  min-width: 10.5rem;
}

.dao-tools .proposal-sort .comment-sort-menu.is-up {
  top: auto;
  bottom: calc(100% + 0.3rem);
}

.dao-page .dao-tools #proposalSearchForm {
  flex: 1 1 14rem;
  width: auto;
  min-width: min(14rem, 100%);
  max-width: 14rem;
}

@media (max-width: 720px) {
  .dao-tools:has(#proposalSearchForm) {
    row-gap: 0.85rem;
  }

  .dao-tools:has(#proposalSearchForm) .cyber-toggle-compact {
    min-height: 2.65rem;
  }
}

.proposal-own {
  margin-top: 0.85rem;
}

.proposal-own-note {
  position: relative;
  display: flex;
  align-items: center;
  gap: 0.45rem 0.85rem;
  margin: 0.65rem 0 0;
  font-family: var(--font-mono);
  font-size: 0.75rem;
  color: var(--gray);
  line-height: 1.45;
}

.proposal-own-note:has(.is-open) {
  z-index: 9;
}

.proposal-own-note:first-child {
  margin-top: 0;
}

.proposal-own-text {
  display: flex;
  flex: 1;
  min-width: 0;
  overflow: hidden;
  white-space: nowrap;
}

.proposal-own-subject {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
}

.proposal-own-label,
.proposal-own-meta {
  flex: 0 0 auto;
}

.proposal-own-more {
  position: static;
  flex: 0 0 auto;
}

.proposal-own-more .dao-more-menu {
  top: auto;
  bottom: calc(100% + 0.35rem);
  left: auto;
  right: 0;
}

#proposalCancelLead {
  overflow-wrap: anywhere;
}

.dao-page .dao-create + .dao-filter {
  margin-top: 0;
}

.dao-filter {
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem 1.25rem;
  margin: 1.15rem 0 1.15rem;
}

.dao-filter button {
  margin: 0;
  padding: 0.15rem 0 0.28rem;
  border: 0;
  border-bottom: 2px solid transparent;
  border-radius: 0;
  background: none;
  color: var(--text);
  font-family: var(--font-body);
  font-size: 1.05rem;
  line-height: 1.3;
  cursor: pointer;
}

.dao-filter button.is-active {
  border-bottom-color: var(--text);
}

.dao-filter button:hover {
  color: var(--yellow);
}

.dao-filter button.is-active:hover {
  color: var(--text);
}

.witness-table {
  display: grid;
  grid-template-columns:
    2.1rem
    minmax(0, 1.5fr)
    minmax(4.4rem, 0.75fr)
    minmax(3.1rem, 0.5fr)
    minmax(2.5rem, 0.45fr)
    minmax(3.6rem, 0.55fr)
    minmax(4.6rem, 0.7fr)
    minmax(2.6rem, 0.4fr)
    5.5rem;
  column-gap: 0.4rem;
  width: 100%;
  margin-top: 0.35rem;
}

.witness-head,
.witness-row {
  display: grid;
  grid-column: 1 / -1;
  grid-template-columns: subgrid;
  align-items: center;
}

.witness-head {
  align-items: end;
}

.witness-head > span {
  padding-bottom: 0.45rem;
  font-family: var(--font-display);
  font-size: 0.58rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--gray-dim);
}

.witness-head > span:nth-child(n + 3):nth-child(-n + 8) {
  text-align: right;
}

#witnessList {
  display: contents;
}

.witness-row {
  border-bottom: 1px solid var(--border);
}

.witness-cells {
  display: grid;
  grid-column: 3 / 9;
  grid-template-columns: subgrid;
  align-items: center;
  min-width: 0;
}

.witness-rank,
.witness-who,
.witness-cell,
.witness-vote {
  padding-top: 0.55rem;
  padding-bottom: 0.55rem;
}

.witness-rank {
  grid-column: 1;
  font-family: var(--font-mono);
  color: var(--text);
  text-align: center;
  text-shadow: none;
}

.witness-who {
  grid-column: 2;
  display: flex;
  align-items: center;
  gap: 0.45rem;
  min-width: 0;
  color: var(--gray);
  text-shadow: none;
}

.witness-who:hover {
  color: var(--yellow);
  text-shadow: none;
}

.witness-name {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  font-family: var(--font-mono);
}

.witness-cell {
  font-family: var(--font-mono);
  font-size: 0.92rem;
  color: var(--gray);
  text-align: right;
  font-variant-numeric: tabular-nums;
}

.witness-votes {
  position: relative;
  cursor: default;
}

.witness-votes:focus {
  outline: none;
}

.witness-votes:focus-visible {
  outline: 1px solid var(--gray);
  outline-offset: 2px;
}

.witness-votes .session-stat-tip {
  left: auto;
  right: 0;
  z-index: 8;
}

.witness-votes:hover .session-stat-tip,
.witness-votes:focus .session-stat-tip,
.witness-votes:focus-visible .session-stat-tip {
  opacity: 1;
  visibility: visible;
}

.witness-row:has(.witness-votes:hover),
.witness-row:has(.witness-votes:focus),
.witness-row:has(.witness-votes:focus-visible) {
  position: relative;
  z-index: 8;
}

.witness-cell.is-behind {
  color: var(--gray-dim);
}

.witness-cell.is-disabled {
  color: var(--red-bright);
}

.witness-action {
  display: contents;
}

.witness-vote {
  grid-column: 9;
  justify-self: end;
}

span.witness-vote.is-voted {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: auto;
  height: auto;
  min-width: 0;
  padding: 0.55rem 1rem;
  border: 1px solid transparent;
  border-radius: 999px;
  background: transparent;
  color: var(--yellow);
  box-shadow: none;
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 0.68rem;
  letter-spacing: 0.14em;
  line-height: normal;
  text-transform: uppercase;
  cursor: default;
}

span.witness-vote.is-voted::before {
  content: "Vote";
  visibility: hidden;
}

.btn-primary.witness-vote.is-voted,
.btn-primary.witness-vote.is-voted:hover:not(:disabled),
.btn-primary.witness-vote.is-voted:active:not(:disabled) {
  width: auto;
  height: auto;
  min-width: 0;
  border-color: transparent;
  background: transparent;
  color: var(--yellow);
  box-shadow: none;
  filter: none;
  transform: none;
  text-shadow: none;
}

.btn-primary.witness-vote.is-voted::before {
  content: "Vote";
  visibility: hidden;
}

.btn-primary.witness-vote.is-voted::after {
  content: none;
}

.btn-primary.witness-vote.is-voted:focus-visible {
  outline: 1px solid var(--yellow);
  outline-offset: 3px;
}

.dao-vote-check {
  position: absolute;
  left: 50%;
  top: 50%;
  display: block;
  width: 1.85rem;
  height: 1.85rem;
  transform: translate(-50%, -50%);
}

.btn-primary.witness-vote:disabled {
  cursor: not-allowed;
}

.btn-primary.witness-vote[aria-busy="true"]:disabled {
  cursor: wait;
}

.dao-split,
.dao-empty {
  grid-column: 1 / -1;
}

.dao-split {
  --dao-check: 0.35rem;
  display: block;
  margin: 0.85rem 0 0.35rem;
  padding: 0;
  border: 0;
  background: none;
  color: var(--text);
  font-family: var(--font-body);
  font-size: 1.05rem;
  line-height: 1.5;
  text-align: left;
}

.dao-split::before {
  content: "";
  display: block;
  height: calc(var(--dao-check) * 3);
  margin-bottom: 0.55rem;
  background-image:
    linear-gradient(90deg, #101010 50%, var(--yellow) 50%),
    linear-gradient(90deg, var(--yellow) 50%, #101010 50%),
    linear-gradient(90deg, #101010 50%, var(--yellow) 50%);
  background-size: calc(var(--dao-check) * 2) var(--dao-check);
  background-position: 0 0, 0 var(--dao-check), 0 calc(var(--dao-check) * 2);
  background-repeat: repeat-x;
}

.dao-split span {
  display: block;
  padding: 0;
  background: none;
  color: var(--text);
  text-align: left;
}

.dao-empty {
  margin: 0.35rem 0 1rem;
}

.dao-page #witnessRetry,
.dao-page #witnessSupporterRetry {
  margin-top: 0.25rem;
}

@media (max-width: 720px) {
  .dao-stats {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .dao-choices,
  .dao-facts {
    grid-template-columns: 1fr;
  }

  .witness-table {
    display: block;
  }

  .witness-head {
    display: none;
  }

  #witnessList {
    display: flex;
    flex-direction: column;
    gap: 0.55rem;
  }

  .witness-row {
    display: grid;
    grid-template-columns: auto minmax(0, 1fr) auto;
    grid-template-areas:
      "rank who vote"
      "cells cells cells";
    gap: 0.45rem 0.65rem;
    align-items: center;
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 0.7rem 0.75rem;
  }

  .witness-rank,
  .witness-who {
    grid-column: auto;
    padding: 0;
  }

  .witness-vote {
    grid-column: auto;
  }

  .witness-rank {
    grid-area: rank;
    text-align: left;
  }

  .witness-who {
    grid-area: who;
  }

  .witness-vote {
    grid-area: vote;
    justify-self: end;
  }

  .witness-cells {
    display: grid;
    grid-area: cells;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 0.45rem 0.6rem;
    padding-top: 0.15rem;
  }

  .witness-cell {
    padding: 0;
    text-align: left;
  }

  .witness-votes .session-stat-tip {
    left: 0;
    right: auto;
  }

  .witness-cell::before {
    content: attr(data-label);
    display: block;
    margin-bottom: 0.12rem;
    font-family: var(--font-display);
    font-size: 0.58rem;
    font-weight: 700;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    color: var(--gray-dim);
  }

  .dao-split {
    margin: 0.35rem 0;
  }
}

.proposal-stats .dao-stat strong {
  font-size: 1.05rem;
  overflow-wrap: anywhere;
}

.proposal-table {
  width: 100%;
  margin-top: 0.35rem;
}

#proposalList {
  display: grid;
  width: 100%;
  min-width: 0;
  grid-template-columns:
    max-content
    minmax(0, 1fr)
    minmax(0, 1fr)
    max-content
    max-content;
  column-gap: 1.25rem;
  row-gap: 0.55rem;
  align-items: center;
}

#proposalList > :not(.proposal-row) {
  grid-column: 1 / -1;
}

.proposal-row {
  display: grid;
  grid-template-columns: subgrid;
  grid-column: 1 / -1;
  align-items: center;
  min-width: 0;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 0.5rem 0.95rem 0.42rem;
}

.proposal-body {
  display: grid;
  grid-template-columns: subgrid;
  grid-column: 1 / 5;
  row-gap: 0.38rem;
  min-width: 0;
}

.proposal-top,
.proposal-bottom {
  grid-column: 1 / -1;
  min-width: 0;
}

.proposal-action {
  grid-column: 5;
  align-self: center;
  justify-self: end;
}

.proposal-action:empty {
  pointer-events: none;
}

.proposal-action:empty::before {
  content: "Vote";
  visibility: hidden;
  display: block;
  padding: 0.55rem 1rem;
  border: 1px solid transparent;
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 0.68rem;
  letter-spacing: 0.14em;
  line-height: normal;
  text-transform: uppercase;
  white-space: nowrap;
}

.proposal-action .proposal-vote {
  position: relative;
}

.proposal-action .proposal-vote.is-voted {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: auto;
  height: auto;
  min-width: 0;
  padding: 0.55rem 1rem;
  border: 1px solid transparent;
  border-radius: 999px;
  background: transparent;
  color: var(--yellow);
  box-shadow: none;
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 0.68rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}

.proposal-action .btn-primary.proposal-vote.is-voted,
.proposal-action .btn-primary.proposal-vote.is-voted:hover:not(:disabled),
.proposal-action .btn-primary.proposal-vote.is-voted:active:not(:disabled) {
  border-color: transparent;
  background: transparent;
  color: var(--yellow);
  box-shadow: none;
  filter: none;
  transform: none;
  text-shadow: none;
}

.proposal-action .proposal-vote.is-voted::before {
  content: "Vote";
  visibility: hidden;
}

.proposal-action .btn-primary.proposal-vote.is-voted::after,
.proposal-action .proposal-vote.is-voted::after {
  content: none;
}

.proposal-action .proposal-vote.is-voted:focus-visible {
  outline: 1px solid var(--yellow);
  outline-offset: 3px;
}

.proposal-action .btn-primary.proposal-vote:disabled {
  cursor: not-allowed;
}

.proposal-action .btn-primary.proposal-vote[aria-busy="true"]:disabled {
  cursor: wait;
}

.proposal-action span.proposal-vote.is-voted {
  cursor: default;
}

.proposal-top {
  display: flex;
  align-items: center;
  gap: 0.85rem;
  min-width: 0;
}

.proposal-who {
  display: flex;
  align-items: center;
  gap: 0.55rem;
  flex: 1;
  min-width: 0;
  color: var(--text);
  text-shadow: none;
}

.proposal-who .avatar {
  flex: none;
  width: 28px;
  height: 28px;
}

.proposal-copy {
  display: flex;
  align-items: baseline;
  flex-wrap: wrap;
  gap: 0.15rem 0.5rem;
  flex: 1;
  min-width: 0;
}

.proposal-user {
  flex: none;
  font-family: var(--font-mono);
  font-size: 0.92rem;
  color: var(--yellow);
  text-shadow: none;
}

.proposal-user:hover {
  text-shadow: none;
}

.proposal-to {
  flex: none;
  font-family: var(--font-body);
  font-size: 0.85rem;
  color: var(--gray);
}

.proposal-subject {
  flex: 1 1 0;
  min-width: 5rem;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  font-family: var(--font-body);
  font-size: 1.02rem;
  line-height: 1.3;
  color: var(--text);
  text-shadow: none;
}

.proposal-subject:hover {
  color: var(--yellow);
  text-shadow: none;
}

.proposal-row.is-return .proposal-subject {
  color: var(--yellow);
}

#proposalList.is-all .proposal-row.is-return,
#proposalList.is-return-yellow .proposal-row.is-return {
  border-color: var(--yellow);
}

.proposal-id {
  flex: none;
  font-family: var(--font-mono);
  font-size: 0.95rem;
  color: var(--text);
}

a.proposal-id {
  color: var(--yellow);
  text-shadow: none;
}

a.proposal-id:hover,
a.proposal-id:focus-visible {
  color: var(--yellow);
  text-shadow: none;
}

.dao-detail .page-title {
  overflow-wrap: anywhere;
}

.dao-detail .proposal-who {
  max-width: 40rem;
  margin: 0 0 0.95rem;
}

.dao-detail .proposal-who .avatar {
  width: 40px;
  height: 40px;
}

.dao-detail .proposal-who .proposal-avatar {
  flex: none;
  display: block;
  line-height: 0;
}

.dao-detail .proposal-user,
.dao-detail .proposal-user:focus-visible {
  color: var(--gray);
  text-shadow: none;
}

.dao-detail .proposal-user:hover {
  color: var(--yellow);
  text-shadow: none;
}

.dao-detail .proposal-action:empty {
  display: none;
}

.dao-detail .dao-stat-unit + .dao-stat-unit {
  margin-left: 0.35rem;
}

.proposal-cells {
  display: grid;
  grid-template-columns: subgrid;
  grid-column: 1 / -1;
  align-items: baseline;
  min-width: 0;
}

.proposal-cell,
.proposal-stake {
  position: relative;
  font-family: var(--font-mono);
  font-size: 0.9rem;
  color: var(--text);
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
}

.proposal-cell::before {
  content: attr(data-label);
  margin-right: 0.4rem;
  font-family: var(--font-display);
  font-size: 0.58rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--gray-dim);
}

.proposal-unit {
  margin-left: 0.12rem;
  font-size: 1em;
  color: inherit;
}

.proposal-approved {
  position: relative;
  display: inline-block;
  /* The disk is 24/28 of this box so the circle stays off the SVG viewport. */
  width: calc(0.85rem * 28 / 24);
  height: calc(0.85rem * 28 / 24);
  margin-left: 0.66rem;
  color: var(--yellow);
  vertical-align: -0.1em;
  line-height: 0;
  cursor: default;
}

.proposal-approved-check {
  display: block;
  width: 100%;
  height: 100%;
}

.proposal-approved:focus {
  outline: none;
}

.proposal-approved:focus-visible {
  outline: 1px solid var(--yellow);
  outline-offset: 2px;
}

.proposal-approved .session-stat-tip {
  left: 0;
  right: auto;
  z-index: 8;
}

.proposal-approved:hover .session-stat-tip,
.proposal-approved:focus .session-stat-tip,
.proposal-approved:focus-visible .session-stat-tip {
  opacity: 1;
  visibility: visible;
}

.proposal-cell.is-end {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 0.55rem;
  min-width: 0;
}

.proposal-cell.is-end::before {
  margin-right: 0;
}

.proposal-cell.is-end .proposal-figure {
  text-align: right;
}

.proposal-stake:focus {
  outline: none;
}

.proposal-stake:focus-visible {
  outline: 1px solid var(--gray);
  outline-offset: 2px;
}

.proposal-stake .session-stat-tip {
  left: 0;
  right: auto;
  z-index: 8;
}

.proposal-stake:hover .session-stat-tip,
.proposal-stake:focus .session-stat-tip,
.proposal-stake:focus-visible .session-stat-tip {
  opacity: 1;
  visibility: visible;
}

.proposal-row:has(.proposal-stake:hover),
.proposal-row:has(.proposal-stake:focus),
.proposal-row:has(.proposal-stake:focus-visible),
.proposal-row:has(.proposal-approved:hover),
.proposal-row:has(.proposal-approved:focus),
.proposal-row:has(.proposal-approved:focus-visible),
.proposal-row:has(.proposal-support:hover),
.proposal-row:has(.proposal-support:focus),
.proposal-row:has(.proposal-support:focus-visible) {
  position: relative;
  z-index: 8;
}

.proposal-bottom {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 0.75rem;
  min-width: 0;
  margin-top: 0.05rem;
  padding-top: 0.32rem;
  border-top: 1px solid var(--border);
}

.proposal-stake {
  flex: none;
}

.proposal-bottom .proposal-approved {
  margin-left: 0;
  align-self: center;
  flex: none;
}

.proposal-bottom .proposal-support {
  position: relative;
  display: flex;
  align-items: center;
  align-self: center;
  flex: none;
  width: 4.25rem;
  height: calc(0.85rem * 28 / 24);
  cursor: default;
}

.proposal-support-track {
  display: block;
  width: 100%;
  height: 0.32rem;
  overflow: hidden;
  border-radius: 999px;
  background: var(--gray-result);
}

.proposal-support-level {
  display: block;
  height: 100%;
  width: var(--support-level, 0%);
  max-width: 100%;
  border-radius: inherit;
  background: var(--yellow);
}

.proposal-support.is-some .proposal-support-level {
  min-width: 2px;
}

.proposal-support:focus {
  outline: none;
}

.proposal-support:focus-visible {
  outline: 1px solid var(--yellow);
  outline-offset: 2px;
}

.proposal-support .session-stat-tip {
  left: 0;
  right: auto;
  z-index: 8;
}

.proposal-support:hover .session-stat-tip,
.proposal-support:focus .session-stat-tip,
.proposal-support:focus-visible .session-stat-tip {
  opacity: 1;
  visibility: visible;
}

.proposal-foot {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  margin-left: auto;
  font-family: var(--font-body);
  font-size: 0.82rem;
  color: var(--gray);
}

.proposal-threshold span {
  display: none;
}

.proposal-threshold {
  margin: 0.15rem 0 0;
}

.proposal-unfunded {
  margin: 0.2rem 0 0;
  color: var(--text);
  font-family: var(--font-body);
  font-size: 1.05rem;
  line-height: 1.4;
  text-align: left;
}

.proposal-totals {
  display: grid;
  grid-template-columns: subgrid;
  align-items: baseline;
  min-width: 0;
  margin: 0.2rem 0 0;
  padding: 0.75rem 0.95rem 0.15rem;
  border: 1px solid transparent;
  border-top-color: var(--gray);
}

.proposal-totals .proposal-cell[data-label="Total"] {
  grid-column: 1;
}

.proposal-totals .proposal-cell[data-label="Paid"] {
  grid-column: 3;
}

.proposal-totals .proposal-cell[data-label="To pay"] {
  grid-column: 4;
}

.proposal-approved-note {
  grid-column: 1 / -1;
  grid-row: 2;
  align-self: start;
  margin: 0.35rem 0 0;
  font-family: var(--font-body);
  font-size: 0.82rem;
  line-height: 1.35;
  color: var(--gray-dim);
  text-align: left;
}

@media (max-width: 720px) {
  .dao-stats.proposal-stats {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 900px) {
  #proposalList {
    display: flex;
    flex-direction: column;
    align-items: stretch;
    gap: 0.55rem;
  }

  .proposal-row {
    display: flex;
    flex-direction: column;
    align-items: stretch;
    gap: 0.85rem;
    padding: 0.55rem 0.7rem 0.7rem;
  }

  .proposal-body {
    display: flex;
    flex-direction: column;
    gap: 0.38rem;
  }

  .proposal-top,
  .proposal-bottom,
  .proposal-cells,
  .proposal-action {
    grid-column: auto;
  }

  .proposal-top {
    align-items: flex-start;
  }

  .proposal-who {
    flex-wrap: wrap;
    column-gap: 0.5rem;
    row-gap: 0.75rem;
  }

  .proposal-copy {
    display: contents;
  }

  .proposal-subject {
    flex: 1 0 100%;
    min-width: 0;
    overflow: visible;
    text-overflow: unset;
    white-space: normal;
    overflow-wrap: break-word;
  }

  .proposal-id {
    margin-top: 0.28rem;
  }

  .proposal-action {
    align-self: flex-start;
  }

  .proposal-action:empty {
    display: none;
  }

  #proposalList .proposal-action .proposal-vote.is-voted {
    justify-content: flex-start;
    width: 1.85rem;
    min-height: 1.85rem;
    padding: 0;
  }

  #proposalList .proposal-action .proposal-vote.is-voted::before {
    content: none;
  }

  #proposalList .proposal-action .dao-vote-check {
    position: static;
    transform: none;
  }

  .proposal-cells {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    column-gap: 1.15rem;
    row-gap: 0.75rem;
  }

  .proposal-cell,
  .proposal-cell.is-end {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    justify-content: flex-start;
    gap: 0.28rem;
  }

  .proposal-cell::before,
  .proposal-cell.is-end::before {
    display: block;
    margin: 0;
  }

  .proposal-cell.is-end .proposal-figure {
    margin-left: 0;
    text-align: left;
  }

  .proposal-cell,
  .proposal-stake {
    font-size: 0.9rem;
  }

  .proposal-bottom .proposal-support {
    width: 3.25rem;
  }

  .proposal-row.is-return .proposal-bottom {
    flex-wrap: wrap;
    row-gap: 0.28rem;
  }

  .proposal-row.is-return .proposal-foot {
    flex-basis: 100%;
    margin-left: 0;
    overflow: visible;
    text-align: left;
    text-overflow: unset;
    white-space: normal;
  }

  .proposal-totals {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    column-gap: 1.15rem;
    row-gap: 0.75rem;
    padding: 0.85rem 0.7rem 0.15rem;
  }

  .proposal-totals .proposal-cell[data-label="Total"] {
    grid-column: 1;
    grid-row: 1;
  }

  .proposal-totals .proposal-cell[data-label="Paid"] {
    grid-column: 1;
    grid-row: 2;
  }

  .proposal-totals .proposal-cell[data-label="To pay"] {
    grid-column: 2;
    grid-row: 2;
  }

  .proposal-approved-note {
    grid-row: 3;
    margin-top: 0;
  }
}
