@import url("https://fonts.googleapis.com/css2?family=Electrolize&family=Yrsa:ital,wght@0,300..700;1,300..700&display=swap");

:root {
  --ink: #0c031d;
  --ink-soft: #1b0629;
  --paper: #100421;
  --paper-deep: #1b0629;
  --line: rgba(224, 213, 255, 0.17);
  --acid: #00f0ff;
  --coral: #e75aff;
  --blue: #c47aff;
  --white: #e0d5ff;
  --muted: #9485b6;
  --medium-purple: #3e1e68;
  --light-purple: #8357c5;
  --orange: #f7931a;
  --radius: 22px;
  font-family: "Electrolize", ui-sans-serif, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  color: var(--white);
  background: var(--paper);
  font-synthesis: none;
}

* {
  box-sizing: border-box;
}

[hidden] {
  display: none !important;
}

html {
  min-height: 100%;
  background: var(--paper);
  touch-action: manipulation;
}

body {
  min-width: 320px;
  min-height: 100vh;
  margin: 0;
  overflow-x: hidden;
  background:
    radial-gradient(circle at 15% 10%, rgba(131, 87, 197, 0.3), transparent 31rem),
    radial-gradient(circle at 88% 80%, rgba(0, 240, 255, 0.08), transparent 28rem),
    var(--paper);
  color: var(--white);
  text-shadow: 0 0 8px rgba(195, 122, 255, 0.25);
}

button,
input {
  font: inherit;
}

button,
a {
  -webkit-tap-highlight-color: transparent;
}

button:focus-visible,
input:focus-visible,
a:focus-visible {
  outline: 3px solid var(--blue);
  outline-offset: 3px;
}

.noise {
  position: fixed;
  inset: 0;
  z-index: 20;
  pointer-events: none;
  opacity: 0.15;
  background:
    repeating-linear-gradient(73deg, transparent 0 3px, rgba(23, 23, 19, 0.025) 3px 4px),
    repeating-linear-gradient(161deg, transparent 0 5px, rgba(255, 255, 255, 0.025) 5px 6px);
}

.entry-shell {
  display: flex;
  min-height: 100vh;
  flex-direction: column;
}

.entry-nav,
.room-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.entry-nav {
  padding: 30px 4.5vw 18px;
}

.wordmark {
  display: inline-flex;
  align-items: center;
  gap: 11px;
  max-width: min(620px, 70vw);
  color: inherit;
  font-size: 15px;
  font-weight: 500;
  letter-spacing: 0.015em;
  text-decoration: none;
}

.wordmark-mark {
  display: grid;
  width: 32px;
  height: 32px;
  place-items: center;
  transform: rotate(-7deg);
  border: 1px solid var(--coral);
  border-radius: 50%;
  background: var(--medium-purple);
  color: var(--acid);
  box-shadow: 0 0 16px rgba(231, 90, 255, 0.45);
  font-family: "Yrsa", Georgia, serif;
  font-size: 18px;
  font-style: italic;
}

.privacy-pill {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 9px 14px;
  border: 1px solid var(--line);
  border-radius: 999px;
  color: #b8aad7;
  font-size: 11px;
  font-weight: 750;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.privacy-pill i {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--acid);
  box-shadow: 0 0 0 4px rgba(0, 240, 255, 0.1), 0 0 12px rgba(0, 240, 255, 0.6);
}

.entry-grid {
  display: grid;
  width: min(1280px, 91vw);
  margin: auto;
  grid-template-columns: minmax(0, 1.35fr) minmax(330px, 0.65fr);
  gap: clamp(48px, 9vw, 140px);
  align-items: center;
  padding: 4vh 0 8vh;
}

.eyebrow,
.micro-label,
.room-label,
.stage-kicker {
  margin: 0;
  color: var(--muted);
  font-size: 10px;
  font-weight: 850;
  letter-spacing: 0.16em;
  text-transform: uppercase;
}

.entry-copy h1 {
  max-width: 780px;
  margin: 18px 0 26px;
  font-size: clamp(62px, 7.1vw, 116px);
  font-weight: 500;
  letter-spacing: -0.055em;
  line-height: 0.88;
  text-transform: uppercase;
}

.entry-copy h1 em {
  position: relative;
  color: var(--coral);
  font-family: "Yrsa", Georgia, "Times New Roman", serif;
  font-size: 0.82em;
  font-weight: 500;
  letter-spacing: -0.055em;
  white-space: nowrap;
}

.entry-copy h1 em::after {
  position: absolute;
  right: 2%;
  bottom: -6px;
  left: 2%;
  height: 5px;
  transform: rotate(-1deg);
  border-radius: 50%;
  background: currentColor;
  content: "";
  opacity: 0.75;
}

.lede {
  max-width: 570px;
  margin: 0;
  color: #c5b8df;
  font-size: clamp(17px, 1.5vw, 22px);
  line-height: 1.55;
}

.trust-row {
  display: flex;
  flex-wrap: wrap;
  gap: 24px 34px;
  margin-top: 42px;
  color: #a99ac8;
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.trust-row span {
  display: inline-flex;
  align-items: center;
  gap: 9px;
}

.trust-row b {
  color: var(--coral);
  font-family: Georgia, serif;
  font-size: 13px;
  font-style: italic;
}

.entry-card {
  position: relative;
  padding: 34px;
  transform: rotate(0.7deg);
  border: 1px solid rgba(196, 122, 255, 0.38);
  border-radius: 12px;
  background: rgba(27, 6, 41, 0.84);
  box-shadow: 0 0 0 1px rgba(0, 240, 255, 0.06), 0 24px 80px rgba(0, 0, 0, 0.35);
  backdrop-filter: blur(16px);
}

.entry-card::before {
  position: absolute;
  top: -12px;
  left: 50%;
  width: 96px;
  height: 25px;
  transform: translateX(-50%) rotate(-2deg);
  background: rgba(0, 240, 255, 0.65);
  box-shadow: 0 0 18px rgba(0, 240, 255, 0.35);
  content: "";
  opacity: 0.7;
}

.card-index {
  color: #8f7eae;
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
  font-size: 10px;
  letter-spacing: 0.12em;
}

.invite-stamp {
  display: inline-block;
  margin-top: 34px;
  padding: 7px 10px;
  transform: rotate(-2deg);
  border: 1px solid var(--coral);
  color: var(--coral);
  font-size: 9px;
  font-weight: 900;
  letter-spacing: 0.12em;
}

.entry-card h2 {
  margin: 19px 0 8px;
  font-family: "Yrsa", Georgia, serif;
  font-size: 36px;
  font-weight: 500;
  letter-spacing: -0.045em;
}

.entry-card > p {
  margin: 0;
  color: #b8aad4;
  font-size: 14px;
  line-height: 1.55;
}

.entry-card .random-name-hint {
  margin-top: 9px;
  color: #9b8db9;
  font-size: 12px;
}

.field-label {
  display: block;
  margin: 30px 0 8px;
  color: #a899c6;
  font-size: 10px;
  font-weight: 850;
  letter-spacing: 0.13em;
  text-transform: uppercase;
}

.name-field {
  display: flex;
  align-items: center;
  border-bottom: 1px solid var(--acid);
}

.name-field input {
  width: 100%;
  padding: 12px 0;
  border: 0;
  outline: 0;
  background: transparent;
  color: var(--white);
  font-family: "Yrsa", Georgia, serif;
  font-size: 22px;
}

.name-field input::placeholder {
  color: #aaa79d;
}

.name-field span {
  font-size: 20px;
}

.primary-button {
  display: flex;
  width: 100%;
  align-items: center;
  justify-content: space-between;
  margin-top: 28px;
  padding: 17px 18px 17px 21px;
  border: 1px solid var(--coral);
  border-radius: 2px;
  background: var(--medium-purple);
  color: var(--white);
  cursor: pointer;
  font-size: 14px;
  font-weight: 800;
  transition: transform 160ms ease, box-shadow 160ms ease;
}

.primary-button:hover {
  transform: translate(-3px, -3px);
  box-shadow: 5px 5px 0 var(--coral), 0 0 22px rgba(231, 90, 255, 0.34);
}

.button-arrow {
  color: var(--acid);
  font-size: 21px;
}

.fine-print {
  margin-top: 18px !important;
  color: #8b897f !important;
  font-size: 10px !important;
}

.entry-footer {
  display: flex;
  overflow: hidden;
  justify-content: space-between;
  padding: 14px 4.5vw;
  border-top: 1px solid var(--line);
  color: #897aa8;
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
  font-size: 9px;
  letter-spacing: 0.1em;
  white-space: nowrap;
}

.entry-footer a {
  color: var(--acid);
  text-decoration-color: rgba(0, 240, 255, 0.45);
  text-underline-offset: 3px;
}

.entry-footer a:hover {
  text-decoration-color: currentColor;
}

.room-shell {
  min-height: 100vh;
  background:
    radial-gradient(circle at 22% 8%, rgba(62, 30, 104, 0.55), transparent 34rem),
    linear-gradient(145deg, #0c031d 0%, #170528 58%, #0b0318 100%);
  color: var(--white);
}

.room-header {
  min-height: 78px;
  padding: 0 24px;
  border-bottom: 1px solid rgba(196, 122, 255, 0.22);
  background: rgba(12, 3, 29, 0.72);
  backdrop-filter: blur(18px);
}

.wordmark-light {
  color: var(--white);
}

.room-identity {
  display: flex;
  align-items: center;
  gap: 11px;
}

.room-label {
  color: #85857d;
}

.room-identity strong {
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
  font-size: 12px;
  letter-spacing: 0.13em;
}

.header-actions {
  display: flex;
  align-items: center;
  gap: 9px;
}

.ghost-button,
.icon-button {
  border: 1px solid rgba(255, 255, 255, 0.2);
  background: transparent;
  color: var(--white);
  cursor: pointer;
}

.ghost-button {
  display: flex;
  align-items: center;
  gap: 20px;
  padding: 10px 13px;
  border-radius: 999px;
  font-size: 11px;
  font-weight: 800;
}

.ghost-button:hover {
  border-color: var(--acid);
  box-shadow: 0 0 14px rgba(0, 240, 255, 0.2);
}

.icon-button {
  width: 38px;
  height: 38px;
  border-radius: 50%;
  font-size: 23px;
  font-weight: 300;
}

.settings-button .settings-glyph {
  display: block;
  margin: auto;
  color: currentColor;
  font-family: Arial, Helvetica, sans-serif;
  font-size: 22px;
  font-style: normal;
  font-variant-emoji: text;
  font-weight: 400;
  line-height: 1;
}

.room-layout {
  display: grid;
  min-height: calc(100vh - 78px);
  grid-template-columns: minmax(0, 1fr) 370px;
}

.stage-column {
  min-width: 0;
  padding: 22px;
}

.stage-stack {
  position: relative;
}

.stage {
  position: relative;
  display: grid;
  overflow: hidden;
  min-height: 0;
  max-height: calc(100vh - 248px);
  aspect-ratio: 16 / 9;
  place-items: center;
  border: 1px solid rgba(196, 122, 255, 0.3);
  border-radius: var(--radius);
  background:
    radial-gradient(circle at 50% 36%, rgba(131, 87, 197, 0.24), transparent 34%),
    #080113;
  box-shadow: 0 18px 65px rgba(0, 0, 0, 0.3), inset 0 0 55px rgba(131, 87, 197, 0.06);
}

.stage.audio-mode::before {
  position: absolute;
  z-index: 0;
  width: min(42%, 290px);
  aspect-ratio: 1;
  border: 1px solid rgba(0, 240, 255, 0.32);
  border-radius: 50%;
  background:
    repeating-radial-gradient(circle, transparent 0 15px, rgba(231, 90, 255, 0.15) 16px 18px),
    radial-gradient(circle, rgba(0, 240, 255, 0.22), transparent 62%);
  box-shadow: 0 0 70px rgba(231, 90, 255, 0.18);
  content: "";
  animation: audio-pulse 2.4s ease-in-out infinite;
}

@keyframes audio-pulse {
  50% {
    transform: scale(1.055);
    opacity: 0.72;
  }
}

.stage video {
  position: relative;
  z-index: 1;
  display: block;
  width: 100%;
  height: 100%;
  min-width: 0;
  min-height: 0;
  max-width: 100%;
  max-height: 100%;
  background: #05010b;
  object-fit: contain;
  object-position: center center;
}

.media-preview {
  position: relative;
  z-index: 1;
  display: block;
  width: 100%;
  height: 100%;
  min-width: 0;
  min-height: 0;
  max-width: 100%;
  max-height: 100%;
  background: #05010b;
  object-fit: contain;
  object-position: center center;
}

.stage video:not([src]) {
  display: none;
}

.stage.audio-mode video {
  opacity: 0;
}

.annotation-canvas {
  position: absolute;
  z-index: 2;
  inset: 0;
  width: 100%;
  height: 100%;
  cursor: crosshair;
  touch-action: none;
}

.annotation-canvas.is-pen {
  cursor: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='24' height='24' viewBox='0 0 24 24'%3E%3Cpath fill='%23ffffff' d='m4 16-1 5 5-1L19 9l-4-4z'/%3E%3C/svg%3E") 3 21, crosshair;
}

.pointer-layer {
  position: absolute;
  z-index: 3;
  inset: 0;
  overflow: hidden;
  pointer-events: none;
}

.shared-pointer {
  position: absolute;
  width: 28px;
  height: 28px;
  transform: translate(-50%, -50%) scale(0.55);
  border: 3px solid var(--pointer-color);
  border-radius: 50%;
  opacity: 0;
  box-shadow: 0 0 0 6px color-mix(in srgb, var(--pointer-color) 22%, transparent),
    0 0 24px var(--pointer-color);
  transition: opacity 160ms ease, transform 160ms ease;
}

.shared-pointer::after {
  position: absolute;
  inset: 7px;
  border-radius: 50%;
  background: var(--pointer-color);
  content: "";
}

.shared-pointer.visible {
  transform: translate(-50%, -50%) scale(1);
  opacity: 1;
}

.shared-pointer small {
  position: absolute;
  top: 32px;
  left: 50%;
  padding: 5px 8px;
  transform: translateX(-50%);
  border-radius: 999px;
  background: rgba(12, 3, 29, 0.9);
  color: var(--white);
  font-size: 12px;
  font-weight: 800;
  white-space: nowrap;
}

.annotation-tools {
  position: absolute;
  z-index: 4;
  top: 14px;
  left: 14px;
  display: flex;
  align-items: center;
  gap: 7px;
  padding: 8px;
  border: 1px solid rgba(224, 213, 255, 0.24);
  border-radius: 999px;
  background: rgba(12, 3, 29, 0.82);
  box-shadow: 0 10px 32px rgba(0, 0, 0, 0.32);
  backdrop-filter: blur(12px);
}

.annotation-tool,
.color-swatch {
  display: grid;
  width: 34px;
  height: 34px;
  flex: 0 0 auto;
  place-items: center;
  border: 1px solid rgba(224, 213, 255, 0.22);
  border-radius: 50%;
  background: rgba(62, 30, 104, 0.48);
  color: var(--white);
  cursor: pointer;
  font-size: 17px;
}

.annotation-tool:hover,
.annotation-tool.active {
  border-color: var(--acid);
  background: rgba(0, 240, 255, 0.15);
  color: var(--acid);
  box-shadow: 0 0 14px rgba(0, 240, 255, 0.22);
}

.pointer-tool-icon::before,
.pointer-tool-icon::after {
  position: absolute;
  border-radius: 50%;
  content: "";
}

.pointer-tool-icon,
.pen-tool-icon,
.clear-tool-icon {
  position: relative;
}

.pointer-tool-icon::before {
  width: 13px;
  height: 13px;
  border: 1.8px solid currentColor;
}

.pointer-tool-icon::after {
  width: 3px;
  height: 3px;
  background: currentColor;
}

.pen-tool-icon::before {
  width: 4px;
  height: 17px;
  transform: rotate(42deg);
  border: 1.5px solid currentColor;
  border-radius: 2px 2px 5px 5px;
  content: "";
}

.clear-tool-icon::before {
  width: 14px;
  height: 11px;
  transform: rotate(-42deg);
  border: 1.5px solid currentColor;
  border-radius: 2px;
  content: "";
}

.color-swatch {
  width: 25px;
  height: 25px;
  border: 3px solid rgba(12, 3, 29, 0.92);
  background: var(--swatch);
  box-shadow: 0 0 0 1px rgba(224, 213, 255, 0.3);
}

.color-swatch[data-color="#00f0ff"] { --swatch: #00f0ff; }
.color-swatch[data-color="#e75aff"] { --swatch: #e75aff; }
.color-swatch[data-color="#f7931a"] { --swatch: #f7931a; }
.color-swatch[data-color="#ffffff"] { --swatch: #ffffff; }

.color-swatch.selected {
  box-shadow: 0 0 0 2px var(--white), 0 0 15px var(--swatch);
}

.tool-divider {
  width: 1px;
  height: 22px;
  background: rgba(224, 213, 255, 0.2);
}

.empty-stage {
  position: absolute;
  z-index: 5;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-direction: column;
  padding: 30px;
  text-align: center;
}

.empty-orbit {
  display: grid;
  width: 80px;
  height: 80px;
  margin-bottom: 25px;
  place-items: center;
  transform: rotate(7deg);
  border: 1px solid rgba(0, 240, 255, 0.46);
  box-shadow: 0 0 32px rgba(0, 240, 255, 0.1);
  border-radius: 48% 52% 40% 60%;
}

.empty-orbit span {
  display: grid;
  width: 42px;
  height: 42px;
  place-items: center;
  transform: rotate(-7deg);
  border-radius: 50%;
  background: var(--acid);
  color: var(--ink);
  box-shadow: 0 0 20px rgba(0, 240, 255, 0.35);
  font-size: 27px;
  font-weight: 300;
}

.stage-kicker {
  color: #797972;
}

.empty-stage h2 {
  margin: 10px 0 9px;
  font-family: "Yrsa", Georgia, serif;
  font-size: clamp(31px, 3.2vw, 52px);
  font-weight: 400;
  letter-spacing: -0.045em;
}

.empty-stage > p:not(.stage-kicker) {
  max-width: 470px;
  margin: 0;
  color: #a99abd;
  font-size: 13px;
  line-height: 1.55;
}

.choose-button {
  display: inline-flex;
  align-items: center;
  gap: 26px;
  margin-top: 25px;
  padding: 13px 15px 13px 18px;
  border: 0;
  border-radius: 999px;
  border: 1px solid var(--acid);
  background: rgba(62, 30, 104, 0.78);
  color: var(--white);
  box-shadow: 0 0 18px rgba(0, 240, 255, 0.1);
  cursor: pointer;
  font-size: 14px;
  font-weight: 850;
}

.choose-button:hover {
  background: var(--acid);
  color: var(--ink);
}

.sound-gate {
  position: absolute;
  z-index: 6;
  display: flex;
  align-items: center;
  gap: 13px;
  padding: 14px 18px;
  border: 1px solid rgba(255, 255, 255, 0.22);
  border-radius: 999px;
  background: rgba(23, 23, 19, 0.88);
  color: var(--white);
  cursor: pointer;
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.35);
  backdrop-filter: blur(12px);
}

.sound-gate > span:first-child {
  display: grid;
  width: 35px;
  height: 35px;
  place-items: center;
  border-radius: 50%;
  background: var(--acid);
  color: var(--ink);
}

.sound-gate b,
.sound-gate small {
  display: block;
  text-align: left;
}

.sound-gate b {
  font-size: 12px;
}

.sound-gate small {
  margin-top: 2px;
  color: #aaa9a2;
  font-size: 9px;
}

.kicked-overlay {
  position: absolute;
  z-index: 7;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-direction: column;
  background: #120322;
  text-align: center;
}

.kicked-mark {
  display: grid;
  width: 58px;
  height: 58px;
  place-items: center;
  border-radius: 50%;
  background: var(--coral);
  color: var(--ink);
  font-size: 35px;
}

.kicked-overlay h2 {
  margin: 18px 0 6px;
  font-family: "Yrsa", Georgia, serif;
  font-size: 36px;
  font-weight: 400;
}

.kicked-overlay p {
  margin: 0;
  color: #96968e;
}

.kicked-overlay a {
  margin-top: 24px;
  color: var(--acid);
  font-size: 12px;
  font-weight: 800;
}

.transport {
  display: grid;
  align-items: center;
  gap: 18px;
  grid-template-columns: minmax(190px, 0.9fr) auto minmax(240px, 1.1fr);
  padding: 18px 4px 11px;
}

.now-playing {
  display: flex;
  min-width: 0;
  align-items: center;
  gap: 12px;
}

.art-tile {
  display: grid;
  width: 42px;
  height: 42px;
  flex: 0 0 auto;
  place-items: center;
  transform: rotate(-3deg);
  background: var(--coral);
  color: var(--ink);
  font-family: "Yrsa", Georgia, serif;
  font-size: 13px;
  font-style: italic;
  font-weight: 700;
}

.now-playing > div,
.now-playing strong,
.now-playing small {
  min-width: 0;
}

.now-playing strong,
.now-playing small {
  display: block;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.now-playing strong {
  margin-top: 3px;
  font-size: 12px;
}

.now-playing small {
  margin-top: 3px;
  color: #777770;
  font-size: 9px;
}

.playback-controls {
  display: flex;
  align-items: center;
  gap: 8px;
}

.round-control {
  width: 36px;
  height: 36px;
  border: 1px solid rgba(224, 213, 255, 0.24);
  border-radius: 50%;
  background: transparent;
  color: var(--white);
  cursor: pointer;
  font-family: Arial, sans-serif;
  font-size: 11px;
}

.round-control:hover {
  border-color: var(--acid);
  box-shadow: 0 0 14px rgba(0, 240, 255, 0.28);
}

.round-control-primary {
  border-color: var(--coral);
  background: var(--coral);
  color: var(--ink);
  box-shadow: 0 0 16px rgba(231, 90, 255, 0.26);
}

.round-control-primary.is-playing {
  border-color: var(--acid);
  background: var(--acid);
  box-shadow: 0 0 16px rgba(0, 240, 255, 0.24);
}

.control-icon {
  position: relative;
  display: block;
  width: 14px;
  height: 14px;
  margin: auto;
}

.play-icon::before {
  position: absolute;
  top: 1px;
  left: 3px;
  width: 0;
  height: 0;
  border-top: 6px solid transparent;
  border-bottom: 6px solid transparent;
  border-left: 9px solid currentColor;
  content: "";
}

.sound-icon {
  position: relative;
  width: 18px;
  height: 18px;
}

.sound-icon::before {
  position: absolute;
  top: 2px;
  left: 5px;
  width: 0;
  height: 0;
  border-top: 7px solid transparent;
  border-bottom: 7px solid transparent;
  border-left: 10px solid currentColor;
  content: "";
}

.is-playing .play-icon::before,
.is-playing .play-icon::after {
  position: absolute;
  top: 1px;
  width: 4px;
  height: 12px;
  border: 0;
  background: currentColor;
  content: "";
}

.is-playing .play-icon::before {
  left: 2px;
}

.is-playing .play-icon::after {
  right: 2px;
}

.stop-icon::before {
  position: absolute;
  inset: 2px;
  border-radius: 1px;
  background: currentColor;
  content: "";
}

.volume-icon::before {
  position: absolute;
  top: 4px;
  left: 1px;
  width: 5px;
  height: 6px;
  background: currentColor;
  clip-path: polygon(0 25%, 45% 25%, 100% 0, 100% 100%, 45% 75%, 0 75%);
  content: "";
}

.volume-icon::after {
  position: absolute;
  top: 2px;
  right: 0;
  width: 7px;
  height: 10px;
  border: 1.5px solid currentColor;
  border-top-color: transparent;
  border-bottom-color: transparent;
  border-left-color: transparent;
  border-radius: 50%;
  content: "";
}

.is-muted .volume-icon::after {
  top: 6px;
  right: -1px;
  width: 8px;
  height: 1.5px;
  transform: rotate(-45deg);
  border: 0;
  border-radius: 0;
  background: currentColor;
}

.fullscreen-icon {
  width: 16px;
  height: 16px;
  background:
    linear-gradient(currentColor 0 0) left top / 7px 2px no-repeat,
    linear-gradient(currentColor 0 0) left top / 2px 7px no-repeat,
    linear-gradient(currentColor 0 0) right top / 7px 2px no-repeat,
    linear-gradient(currentColor 0 0) right top / 2px 7px no-repeat,
    linear-gradient(currentColor 0 0) left bottom / 7px 2px no-repeat,
    linear-gradient(currentColor 0 0) left bottom / 2px 7px no-repeat,
    linear-gradient(currentColor 0 0) right bottom / 7px 2px no-repeat,
    linear-gradient(currentColor 0 0) right bottom / 2px 7px no-repeat;
}

.is-fullscreen-active .fullscreen-icon {
  transform: scale(0.78);
}

.volume-slider {
  width: 72px;
  accent-color: var(--acid);
}

.change-media-button,
.owner-button {
  border: 1px solid rgba(0, 240, 255, 0.35);
  border-radius: 999px;
  background: rgba(0, 240, 255, 0.08);
  color: var(--acid);
  cursor: pointer;
  font-size: 10px;
  font-weight: 800;
  white-space: nowrap;
}

.change-media-button {
  min-height: 34px;
  padding: 0 12px;
}

.timeline-wrap {
  min-width: 0;
}

.timeline-wrap input {
  width: 100%;
  height: 3px;
  margin: 0;
  appearance: none;
  border-radius: 4px;
  background: rgba(255, 255, 255, 0.18);
  cursor: pointer;
}

.timeline-wrap input::-webkit-slider-thumb {
  width: 12px;
  height: 12px;
  appearance: none;
  border: 2px solid var(--ink);
  border-radius: 50%;
  background: var(--acid);
  box-shadow: 0 0 0 1px var(--acid);
}

.timeline-wrap input::-moz-range-thumb {
  width: 10px;
  height: 10px;
  border: 2px solid var(--ink);
  border-radius: 50%;
  background: var(--acid);
}

.time-row {
  display: flex;
  justify-content: space-between;
  margin-top: 7px;
  color: #6e6e67;
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
  font-size: 8px;
}

.transfer-strip {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  padding: 8px 0 0;
  border-top: 1px solid rgba(255, 255, 255, 0.08);
  color: #777770;
  font-size: 9px;
}

.transfer-copy {
  display: flex;
  align-items: center;
  gap: 8px;
  white-space: nowrap;
}

.transfer-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--acid);
  box-shadow: 0 0 0 3px rgba(200, 255, 53, 0.1);
}

.quality-control {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-left: auto;
  color: #9f9e97;
  font-size: 9px;
  font-weight: 750;
  white-space: nowrap;
}

.quality-control select {
  padding: 6px 28px 6px 9px;
  border: 1px solid rgba(0, 240, 255, 0.34);
  border-radius: 999px;
  background: #1b0629;
  color: var(--white);
  cursor: pointer;
  font: inherit;
}

.quality-control select:focus-visible {
  outline: 2px solid var(--acid);
  outline-offset: 2px;
}

.transfer-track {
  overflow: hidden;
  width: min(280px, 34vw);
  height: 3px;
  border-radius: 4px;
  background: rgba(255, 255, 255, 0.09);
}

.transfer-track i {
  display: block;
  width: 0;
  height: 100%;
  border-radius: inherit;
  background: var(--acid);
  transition: width 180ms ease;
}

.people-panel {
  display: flex;
  min-height: 0;
  flex-direction: column;
  padding: 25px 20px 20px;
  border-left: 1px solid rgba(196, 122, 255, 0.22);
  background: rgba(27, 6, 41, 0.86);
  backdrop-filter: blur(18px);
}

.people-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  padding: 0 4px 22px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.people-header h2 {
  margin: 6px 0 0;
  font-family: "Yrsa", Georgia, serif;
  font-size: 27px;
  font-weight: 400;
}

.count-badge {
  display: grid;
  width: 29px;
  height: 29px;
  place-items: center;
  border-radius: 50%;
  background: var(--acid);
  color: var(--ink);
  font-size: 11px;
  font-weight: 900;
}

.participant-list {
  overflow-y: auto;
  min-height: 100px;
  max-height: 180px;
  flex: 0 1 auto;
  padding: 8px 0 14px;
}

.participant {
  display: flex;
  align-items: center;
  gap: 11px;
  padding: 11px 4px;
}

.avatar {
  display: grid;
  width: 38px;
  height: 38px;
  flex: 0 0 auto;
  place-items: center;
  border: 1px solid rgba(255, 255, 255, 0.14);
  border-radius: 50%;
  background: var(--avatar, #3e3e38);
  color: var(--white);
  font-family: "Yrsa", Georgia, serif;
  font-size: 14px;
  font-style: italic;
  overflow: hidden;
}

.avatar img,
.identity-avatar img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.participant-copy {
  min-width: 0;
  flex: 1;
}

.participant-name {
  display: flex;
  align-items: center;
  gap: 7px;
  font-size: 11px;
  font-weight: 750;
}

.participant-meta {
  display: block;
  overflow: hidden;
  max-width: 100%;
  margin-top: 4px;
  padding: 0;
  appearance: none;
  border: 0;
  background: transparent;
  color: #72726b;
  cursor: pointer;
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
  font-size: 8px;
  text-align: left;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.participant-meta:hover {
  color: var(--acid);
}

.participant-meta:focus-visible {
  border-radius: 3px;
  outline: 2px solid var(--acid);
  outline-offset: 3px;
}

.host-tag,
.you-tag {
  padding: 3px 5px;
  border: 1px solid rgba(255, 255, 255, 0.15);
  border-radius: 999px;
  color: #94948c;
  font-size: 7px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.host-tag {
  border-color: rgba(200, 255, 53, 0.35);
  color: var(--acid);
}

.kick-button {
  border: 0;
  background: transparent;
  color: #777770;
  cursor: pointer;
  font-size: 9px;
  font-weight: 800;
  text-transform: uppercase;
}

.participant-actions {
  display: flex;
  flex: 0 0 auto;
  align-items: center;
  gap: 5px;
}

.owner-button {
  padding: 6px 8px;
}

.kick-button:hover {
  color: var(--coral);
}

.connection-card {
  padding: 14px;
  border: 1px solid rgba(255, 255, 255, 0.11);
  border-radius: 13px;
  background: rgba(62, 30, 104, 0.24);
}

.connection-topline {
  display: flex;
  align-items: center;
  gap: 8px;
  color: #c6c5bd;
  font-size: 9px;
  font-weight: 750;
}

.status-indicator {
  width: 7px;
  height: 7px;
  border-radius: 50%;
}

.status-indicator.pending {
  background: #f2b544;
  animation: pulse 1.4s infinite;
}

.status-indicator.online {
  background: var(--acid);
}

.status-indicator.error {
  background: var(--coral);
}

@keyframes pulse {
  50% { opacity: 0.35; }
}

.connection-card p {
  margin: 9px 0 0;
  color: #6f6f68;
  font-size: 9px;
  line-height: 1.5;
}

.retry-button {
  margin-top: 10px;
  padding: 0;
  border: 0;
  background: transparent;
  color: var(--acid);
  cursor: pointer;
  font-size: 9px;
  font-weight: 800;
}

.side-invite {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-top: 12px;
  padding: 14px;
  border: 0;
  border-radius: 13px;
  border: 1px solid var(--acid);
  background: rgba(0, 240, 255, 0.92);
  color: var(--ink);
  cursor: pointer;
  text-align: left;
  font-size: 11px;
  font-weight: 850;
}

.side-invite small {
  display: block;
  margin-bottom: 4px;
  font-size: 7px;
  letter-spacing: 0.12em;
}

.side-invite > span:last-child {
  font-size: 20px;
}

.chat-panel {
  display: flex;
  overflow: hidden;
  min-height: 260px;
  flex: 1;
  flex-direction: column;
  margin: 4px 0 12px;
  border: 1px solid rgba(196, 122, 255, 0.2);
  border-radius: 14px;
  background: rgba(12, 3, 29, 0.6);
}

.chat-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 13px 14px 11px;
  border-bottom: 1px solid rgba(196, 122, 255, 0.15);
}

.chat-header h2 {
  margin: 3px 0 0;
  font-family: "Yrsa", Georgia, serif;
  font-size: 21px;
  font-weight: 500;
}

.chat-live {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  color: #a99ac8;
  font-size: 8px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.chat-live i {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--acid);
  box-shadow: 0 0 10px rgba(0, 240, 255, 0.75);
}

.chat-messages {
  overflow-y: auto;
  min-height: 130px;
  flex: 1;
  padding: 8px 12px 12px;
  scrollbar-color: var(--medium-purple) transparent;
}

.chat-messages.chat-disabled {
  opacity: 0.58;
}

.chat-empty {
  display: grid;
  min-height: 100%;
  place-content: center;
  color: #71628f;
  text-align: center;
}

.chat-empty span {
  color: var(--coral);
  font-family: "Yrsa", Georgia, serif;
  font-size: 27px;
}

.chat-empty p {
  margin: 3px 0 0;
  font-size: 9px;
  line-height: 1.5;
}

.chat-message {
  display: flex;
  align-items: flex-start;
  gap: 9px;
  padding: 8px 2px;
}

.chat-avatar {
  display: grid;
  width: 27px;
  height: 27px;
  flex: 0 0 auto;
  place-items: center;
  border: 1px solid rgba(231, 90, 255, 0.4);
  border-radius: 50%;
  background: var(--medium-purple);
  color: var(--white);
  font-family: "Yrsa", Georgia, serif;
  font-size: 11px;
}

.chat-message.self .chat-avatar {
  border-color: rgba(0, 240, 255, 0.46);
  background: rgba(0, 240, 255, 0.14);
  color: var(--acid);
}

.chat-content {
  min-width: 0;
  flex: 1;
}

.chat-meta {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 8px;
}

.chat-meta strong {
  overflow: hidden;
  color: #cfc1ea;
  font-size: 9px;
  font-weight: 700;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.chat-meta time {
  color: #66577f;
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
  font-size: 7px;
}

.chat-content p {
  margin: 4px 0 0;
  color: #b8aad3;
  font-size: 10px;
  line-height: 1.45;
  overflow-wrap: anywhere;
  text-shadow: none;
  white-space: pre-wrap;
}

.chat-form {
  display: flex;
  gap: 7px;
  padding: 10px;
  border-top: 1px solid rgba(196, 122, 255, 0.14);
}

.chat-form input {
  min-width: 0;
  flex: 1;
  padding: 10px 11px;
  border: 1px solid rgba(224, 213, 255, 0.16);
  border-radius: 9px;
  outline: 0;
  background: rgba(62, 30, 104, 0.23);
  color: var(--white);
  font-size: 10px;
}

.chat-form input::placeholder {
  color: #70618b;
}

.chat-form input:focus {
  border-color: var(--acid);
  box-shadow: 0 0 0 2px rgba(0, 240, 255, 0.08);
}

.chat-form button {
  width: 37px;
  height: 37px;
  flex: 0 0 auto;
  border: 1px solid var(--coral);
  border-radius: 9px;
  background: var(--coral);
  color: var(--ink);
  cursor: pointer;
  font-size: 17px;
  font-weight: 800;
}

.chat-form button:hover {
  box-shadow: 0 0 15px rgba(231, 90, 255, 0.42);
}

.visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  clip-path: inset(50%);
  white-space: nowrap;
}

.stage:fullscreen,
.stage.is-fullscreen {
  width: 100vw;
  height: 100vh;
  max-height: none;
  aspect-ratio: auto;
  border: 0;
  border-radius: 0;
  background: #030006;
}

.source-dialog,
.settings-dialog,
.identity-dialog,
.remote-signer-dialog,
.ban-confirm-dialog {
  width: min(760px, calc(100vw - 32px));
  max-height: min(760px, calc(100dvh - 32px));
  padding: 0;
  overflow: auto;
  border: 1px solid rgba(196, 122, 255, 0.42);
  border-radius: 24px;
  background:
    radial-gradient(circle at 85% 0, rgba(131, 87, 197, 0.28), transparent 320px),
    #100421;
  color: var(--white);
  box-shadow: 0 32px 110px rgba(0, 0, 0, 0.72), 0 0 45px rgba(231, 90, 255, 0.16);
}

.source-dialog::backdrop,
.settings-dialog::backdrop,
.identity-dialog::backdrop,
.remote-signer-dialog::backdrop,
.ban-confirm-dialog::backdrop {
  background: rgba(3, 0, 10, 0.78);
  backdrop-filter: blur(9px);
}

.source-dialog-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 24px;
  padding: 28px 30px 20px;
  border-bottom: 1px solid var(--line);
}

.source-dialog-head h2 {
  margin: 5px 0 0;
  font-family: "Yrsa", Georgia, serif;
  font-size: 38px;
  font-weight: 450;
  line-height: 1;
}

.source-options {
  display: grid;
  gap: 12px;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  padding: 22px 30px 14px;
}

.source-option {
  position: relative;
  display: grid;
  min-width: 0;
  min-height: 146px;
  align-content: start;
  gap: 8px;
  padding: 20px;
  border: 1px solid rgba(224, 213, 255, 0.17);
  border-radius: 17px;
  background: rgba(62, 30, 104, 0.24);
  color: var(--white);
  text-align: left;
}

button.source-option {
  cursor: pointer;
}

button.source-option:hover,
button.source-option:focus-visible {
  border-color: var(--acid);
  background: rgba(0, 240, 255, 0.08);
  box-shadow: inset 0 0 25px rgba(0, 240, 255, 0.05);
}

.source-option strong {
  font-size: 16px;
}

.source-option small {
  color: var(--muted);
  font-size: 12px;
  line-height: 1.45;
}

.source-option-icon {
  position: relative;
  display: block;
  width: 38px;
  height: 38px;
  margin-bottom: 8px;
  border: 1px solid rgba(0, 240, 255, 0.32);
  border-radius: 50%;
  color: var(--acid);
  box-shadow: 0 0 16px rgba(0, 240, 255, 0.12);
}

.source-file-icon::before {
  position: absolute;
  inset: 9px 11px 8px;
  border: 1.5px solid currentColor;
  border-radius: 2px;
  content: "";
}

.source-file-icon::after {
  position: absolute;
  top: 17px;
  left: 15px;
  width: 8px;
  height: 1.5px;
  background: currentColor;
  box-shadow: 0 5px currentColor;
  content: "";
}

.source-screen-icon::before {
  position: absolute;
  inset: 9px 7px 12px;
  border: 1.5px solid currentColor;
  border-radius: 3px;
  content: "";
}

.source-screen-icon::after {
  position: absolute;
  right: 11px;
  bottom: 7px;
  left: 11px;
  height: 1.5px;
  background: currentColor;
  box-shadow: 7px -2px 0 -0.25px currentColor;
  content: "";
}

.source-link-icon::before,
.source-link-icon::after {
  position: absolute;
  top: 13px;
  width: 13px;
  height: 8px;
  transform: rotate(-35deg);
  border: 1.5px solid currentColor;
  border-radius: 999px;
  content: "";
}

.source-link-icon::before {
  left: 7px;
}

.source-link-icon::after {
  right: 7px;
}

.source-url-option {
  grid-column: 1 / -1;
  min-height: 0;
}

.source-url-row {
  display: flex;
  gap: 8px;
  margin-top: 6px;
}

.source-url-row input {
  min-width: 0;
  flex: 1;
  padding: 12px 13px;
  border: 1px solid rgba(224, 213, 255, 0.2);
  border-radius: 10px;
  background: rgba(12, 3, 29, 0.74);
  color: var(--white);
}

.source-url-row button {
  padding: 0 18px;
  border: 0;
  border-radius: 10px;
  background: var(--coral);
  color: var(--ink);
  cursor: pointer;
  font-weight: 900;
}

.source-progress {
  margin: 4px 30px 16px;
  padding: 13px 15px;
  border: 1px solid rgba(0, 240, 255, 0.2);
  border-radius: 12px;
  background: rgba(0, 240, 255, 0.05);
}

.source-progress > div {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  color: var(--muted);
  font-size: 11px;
}

.source-progress progress {
  width: 100%;
  height: 5px;
  margin-top: 9px;
  accent-color: var(--acid);
}

.source-dialog-note {
  margin: 0;
  padding: 0 30px 26px;
  color: #817698;
  font-size: 11px;
  line-height: 1.55;
}

.identity-divider {
  display: flex;
  align-items: center;
  gap: 10px;
  margin: 17px 0 13px;
  color: var(--muted);
  font-size: 10px;
  text-transform: uppercase;
}

.identity-divider::before,
.identity-divider::after {
  height: 1px;
  flex: 1;
  background: var(--line);
  content: "";
}

.nostr-login-button,
.saved-login-button {
  width: 100%;
  min-height: 48px;
  border: 1px solid rgba(0, 240, 255, 0.34);
  border-radius: 12px;
  background: rgba(0, 240, 255, 0.07);
  color: var(--white);
  cursor: pointer;
  font-weight: 800;
}

.nostr-login-button {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
}

.nostr-login-mark {
  display: grid;
  width: 29px;
  height: 29px;
  place-items: center;
  border: 1px solid var(--coral);
  border-radius: 50%;
  background: var(--medium-purple);
  color: var(--acid);
  font-family: "Yrsa", Georgia, serif;
  font-size: 12px;
  font-style: italic;
}

.identity-summary {
  display: flex;
  align-items: center;
  gap: 11px;
  padding: 11px;
  border: 1px solid rgba(0, 240, 255, 0.28);
  border-radius: 12px;
  background: rgba(0, 240, 255, 0.06);
}

.identity-avatar {
  display: grid;
  overflow: hidden;
  width: 38px;
  height: 38px;
  flex: 0 0 auto;
  place-items: center;
  border-radius: 50%;
  background: var(--medium-purple);
  color: var(--acid);
}

.identity-summary > span:nth-child(2) {
  min-width: 0;
  flex: 1;
}

.identity-summary strong,
.identity-summary small {
  display: block;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.identity-summary small {
  margin-top: 3px;
  color: var(--muted);
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
  font-size: 9px;
}

.identity-summary button {
  border: 0;
  background: transparent;
  color: var(--coral);
  cursor: pointer;
  font-size: 9px;
}

.settings-dialog,
.identity-dialog,
.remote-signer-dialog {
  width: min(700px, calc(100vw - 32px));
  padding: 0;
}

.ban-confirm-dialog {
  width: min(460px, calc(100vw - 32px));
}

.ban-confirm-content {
  display: grid;
  justify-items: start;
  gap: 12px;
  padding: 30px;
}

.ban-confirm-mark {
  display: grid;
  width: 46px;
  height: 46px;
  place-items: center;
  border: 1px solid rgba(255, 116, 150, 0.6);
  border-radius: 50%;
  background: rgba(255, 70, 120, 0.13);
  color: #ff7496;
  font-size: 25px;
  font-weight: 900;
}

.ban-confirm-content h2 {
  margin: 2px 0 0;
  font-family: "Yrsa", Georgia, serif;
  font-size: 38px;
  font-weight: 450;
  line-height: 1;
}

.ban-confirm-content p {
  margin: 0;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.6;
}

.ban-confirm-actions {
  display: flex;
  width: 100%;
  justify-content: flex-end;
  gap: 10px;
  margin-top: 10px;
}

.ban-confirm-actions button {
  min-height: 42px;
  padding: 0 18px;
  border-radius: 9px;
  cursor: pointer;
  font-weight: 850;
}

.secondary-button {
  border: 1px solid rgba(224, 213, 255, 0.22);
  background: rgba(255, 255, 255, 0.04);
  color: var(--white);
}

.danger-button {
  border: 1px solid #ff7496;
  background: #ff7496;
  color: #16000a;
}

.danger-button:hover {
  box-shadow: 0 0 18px rgba(255, 116, 150, 0.3);
}

.settings-dialog form {
  margin: 0;
}

.settings-grid {
  display: grid;
  gap: 14px;
  padding: 24px 30px 10px;
}

.settings-field,
.settings-toggle {
  display: grid;
  gap: 6px;
  padding: 16px;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: rgba(62, 30, 104, 0.22);
}

.settings-field > span,
.settings-toggle strong {
  font-size: 14px;
  font-weight: 800;
}

.settings-field small,
.settings-toggle small {
  display: block;
  color: var(--muted);
  font-size: 10px;
  line-height: 1.45;
}

.settings-field select,
.settings-number,
.bunker-form input {
  min-height: 42px;
  border: 1px solid rgba(224, 213, 255, 0.2);
  border-radius: 9px;
  background: #1b0629;
  color: var(--white);
}

.settings-field select {
  padding: 0 11px;
}

.settings-number {
  display: flex;
  align-items: center;
  padding-right: 12px;
}

.settings-number input {
  min-width: 0;
  flex: 1;
  padding: 0 11px;
  border: 0;
  outline: 0;
  background: transparent;
  color: inherit;
}

.settings-number span {
  color: var(--muted);
  font-size: 10px;
}

.settings-toggle {
  grid-template-columns: 1fr auto;
  align-items: center;
}

.settings-toggle input {
  width: 22px;
  height: 22px;
  accent-color: var(--acid);
}

.settings-readonly {
  margin: 10px 30px 0;
  color: var(--muted);
  font-size: 11px;
}

.settings-save {
  width: calc(100% - 60px);
  margin: 18px 30px 28px;
}

.banned-section {
  margin: 14px 30px 0;
  padding: 18px;
  border: 1px solid rgba(231, 90, 255, 0.24);
  border-radius: 14px;
  background: rgba(62, 30, 104, 0.2);
}

.banned-section-head,
.banned-person {
  display: flex;
  align-items: center;
  gap: 12px;
}

.banned-section-head {
  justify-content: space-between;
}

.banned-section-head h3 {
  margin: 3px 0 0;
  font-size: 16px;
}

.banned-count {
  display: grid;
  min-width: 30px;
  height: 30px;
  place-items: center;
  border: 1px solid rgba(231, 90, 255, 0.35);
  border-radius: 50%;
  color: var(--coral);
  font-size: 11px;
  font-weight: 900;
}

.banned-section-copy,
.banned-empty {
  color: var(--muted);
  font-size: 10px;
  line-height: 1.45;
}

.banned-section-copy {
  margin: 10px 0 14px;
}

.banned-empty {
  margin: 0;
  padding: 12px 0 2px;
}

.banned-list {
  display: grid;
  gap: 8px;
}

.banned-person {
  justify-content: space-between;
  padding: 10px 11px;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: rgba(8, 1, 19, 0.5);
}

.banned-person-copy {
  min-width: 0;
}

.banned-person-copy strong,
.banned-person-copy button {
  display: block;
}

.banned-person-copy strong {
  overflow: hidden;
  font-size: 11px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.banned-person-copy button {
  max-width: 100%;
  margin-top: 3px;
  padding: 0;
  overflow: hidden;
  border: 0;
  background: transparent;
  color: var(--muted);
  cursor: pointer;
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
  font-size: 8px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.unban-button {
  min-height: 30px;
  padding: 0 11px;
  border: 1px solid rgba(0, 240, 255, 0.35);
  border-radius: 999px;
  background: rgba(0, 240, 255, 0.08);
  color: var(--acid);
  cursor: pointer;
  font-size: 9px;
  font-weight: 900;
}

.unban-button:hover {
  border-color: var(--acid);
  box-shadow: 0 0 13px rgba(0, 240, 255, 0.22);
}

.identity-intro {
  margin: 0;
  padding: 20px 30px 5px;
  color: var(--muted);
  font-size: 12px;
  line-height: 1.55;
}

.identity-options {
  display: grid;
  gap: 12px;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  padding: 18px 30px;
}

.identity-option .nostr-login-mark {
  width: 38px;
  height: 38px;
  margin-bottom: 8px;
}

.bunker-form {
  padding: 0 30px 14px;
}

.bunker-form > label {
  display: block;
  margin-bottom: 8px;
  color: var(--muted);
  font-size: 10px;
  font-weight: 800;
  text-transform: uppercase;
}

.bunker-form > div {
  display: flex;
  gap: 8px;
}

.bunker-form input {
  min-width: 0;
  flex: 1;
  padding: 0 12px;
}

.bunker-form button,
.nip46-panel button {
  padding: 0 16px;
  border: 1px solid var(--acid);
  border-radius: 9px;
  background: var(--acid);
  color: var(--ink);
  cursor: pointer;
  font-weight: 850;
}

.saved-login-button {
  width: calc(100% - 60px);
  margin: 0 30px 14px;
}

.nip46-panel {
  display: grid;
  gap: 9px;
  margin: 0 30px 14px;
  padding: 14px;
  border: 1px solid rgba(0, 240, 255, 0.24);
  border-radius: 12px;
  background: rgba(0, 240, 255, 0.05);
}

.nip46-panel a {
  overflow: hidden;
  color: var(--acid);
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
  font-size: 9px;
  overflow-wrap: anywhere;
}

.nip46-qr {
  display: block;
  width: min(220px, 100%);
  height: auto;
  margin: 4px auto;
  border: 8px solid #fff;
  border-radius: 12px;
  background: #fff;
  image-rendering: pixelated;
}

.nip46-panel button {
  min-height: 38px;
}

.nip46-request-panel {
  padding: 18px;
}

.nip46-qr-reveal {
  position: relative;
  display: grid;
  width: min(236px, 100%);
  min-height: 0;
  margin: 3px auto;
  padding: 0;
  overflow: hidden;
  place-items: center;
  border: 0 !important;
  border-radius: 15px !important;
  background: #10031d !important;
  color: var(--white) !important;
  cursor: pointer;
}

.nip46-qr-reveal .nip46-qr {
  width: 100%;
  margin: 0;
  transform: scale(1.04);
  filter: blur(15px);
  opacity: 0.48;
  transition: filter 180ms ease, opacity 180ms ease, transform 180ms ease;
}

.nip46-qr-reveal.is-revealed .nip46-qr {
  transform: scale(1);
  filter: none;
  opacity: 1;
}

.nip46-qr-cover {
  position: absolute;
  inset: 0;
  display: grid;
  align-content: center;
  justify-items: center;
  gap: 5px;
  padding: 20px;
  background: rgba(12, 3, 29, 0.58);
  text-align: center;
  backdrop-filter: blur(3px);
}

.nip46-qr-cover b {
  font-size: 14px;
}

.nip46-qr-cover small {
  color: var(--muted);
  font-size: 10px;
}

.remote-bunker-form {
  padding-top: 4px;
}

.challenge-panel {
  border-color: rgba(231, 90, 255, 0.35);
}

.challenge-panel p {
  margin: 0;
  color: var(--muted);
  font-size: 11px;
  overflow-wrap: anywhere;
}

.identity-login-status {
  min-height: 18px;
  margin: 0;
  padding: 0 30px 25px;
  color: var(--acid);
  font-size: 11px;
}

.toast {
  position: fixed;
  z-index: 40;
  right: 22px;
  bottom: 22px;
  max-width: min(380px, calc(100vw - 44px));
  padding: 13px 16px;
  transform: translateY(20px);
  border: 1px solid rgba(255, 255, 255, 0.16);
  border-radius: 999px;
  background: var(--medium-purple);
  color: var(--white);
  font-size: 11px;
  font-weight: 700;
  opacity: 0;
  pointer-events: none;
  transition: opacity 180ms ease, transform 180ms ease;
}

.toast.visible {
  transform: translateY(0);
  opacity: 1;
}

.toast.error {
  background: var(--coral);
  color: var(--ink);
}

/* Readable from more than arm's length, including the dense room sidebar. */
.wordmark {
  font-size: 17px;
}

.privacy-pill,
.eyebrow,
.micro-label,
.room-label,
.stage-kicker,
.card-index,
.field-label {
  font-size: 12px;
}

.trust-row,
.ghost-button,
.now-playing strong,
.round-control,
.count-badge,
.participant-name,
.side-invite,
.chat-form input {
  font-size: 14px;
}

.invite-stamp,
.fine-print,
.entry-footer,
.now-playing small,
.sound-gate small,
.time-row,
.transfer-strip,
.participant-meta,
.kick-button,
.connection-topline,
.connection-card p,
.retry-button,
.chat-live,
.chat-empty p,
.chat-meta strong,
.chat-meta time,
.chat-content p,
.side-invite small,
.toast {
  font-size: 12px !important;
}

.entry-card > p,
.primary-button,
.kicked-overlay a {
  font-size: 16px;
}

@media (max-width: 980px) {
  .entry-grid {
    gap: 50px;
    grid-template-columns: 1fr;
    padding-top: 7vh;
  }

  .entry-copy h1 {
    font-size: clamp(60px, 12vw, 104px);
  }

  .entry-card {
    width: min(520px, 100%);
    margin: 0 auto 8vh;
  }

  .room-layout {
    grid-template-columns: 1fr;
  }

  .people-panel {
    min-height: 440px;
    border-top: 1px solid rgba(255, 255, 255, 0.12);
    border-left: 0;
  }

  .stage {
    max-height: none;
  }
}

@media (max-width: 700px) {
  body {
    min-width: 0;
    overscroll-behavior: none;
  }

  .privacy-pill,
  .ticker,
  .room-label,
  .ghost-button span:first-child {
    display: none;
  }

  .entry-nav {
    padding: 22px;
  }

  .entry-grid {
    width: auto;
    margin: 0;
    padding: 54px 22px 80px;
  }

  .entry-copy h1 {
    margin-top: 14px;
    font-size: clamp(55px, 18vw, 82px);
    line-height: 0.86;
  }

  .entry-copy h1 em {
    white-space: normal;
  }

  .lede {
    font-size: 17px;
  }

  .entry-card {
    padding: 27px 24px;
  }

  .entry-footer {
    justify-content: center;
  }

  .room-header {
    min-height: 68px;
    padding: env(safe-area-inset-top) max(14px, env(safe-area-inset-right)) 0 max(14px, env(safe-area-inset-left));
  }

  .room-header .wordmark > span:last-child {
    display: none;
  }

  .room-layout {
    min-height: calc(100vh - 68px);
  }

  .stage-column {
    padding: 10px max(10px, env(safe-area-inset-right)) 18px max(10px, env(safe-area-inset-left));
  }

  .stage {
    border-radius: 15px;
  }

  .empty-orbit {
    width: 62px;
    height: 62px;
    margin-bottom: 18px;
  }

  .empty-stage h2 {
    font-size: 29px;
  }

  .empty-stage > p:not(.stage-kicker) {
    display: none;
  }

  .choose-button {
    margin-top: 18px;
  }

  .annotation-tools {
    position: static;
    width: 100%;
    max-width: 100%;
    justify-content: center;
    gap: 5px;
    margin-top: 9px;
    padding: 6px;
    overflow-x: auto;
    border-radius: 14px;
    background: rgba(27, 6, 41, 0.96);
    scrollbar-width: none;
  }

  .annotation-tool {
    width: 31px;
    height: 31px;
  }

  .color-swatch {
    width: 22px;
    height: 22px;
  }

  .transport {
    gap: 12px;
    grid-template-columns: minmax(0, 1fr);
    padding: 14px 3px 8px;
  }

  .timeline-wrap {
    grid-column: 1 / -1;
    grid-row: 2;
  }

  .playback-controls {
    width: 100%;
    flex-wrap: wrap;
    grid-row: 3;
    justify-content: center;
  }

  .change-media-button {
    min-height: 36px;
  }

  .volume-slider {
    width: min(24vw, 88px);
  }

  .transfer-track {
    width: 90px;
  }

  .quality-control > span,
  .transfer-track {
    display: none;
  }

  .people-panel {
    padding: 25px max(16px, env(safe-area-inset-right)) max(28px, env(safe-area-inset-bottom)) max(16px, env(safe-area-inset-left));
  }

  .participant {
    align-items: flex-start;
    flex-wrap: wrap;
  }

  .participant-actions {
    width: 100%;
    padding-left: 49px;
  }

  .owner-button,
  .kick-button {
    min-height: 34px;
    padding: 7px 10px;
  }

  .toast {
    right: 12px;
    bottom: max(12px, env(safe-area-inset-bottom));
    max-width: calc(100vw - 24px);
    border-radius: 15px;
  }

  .source-dialog,
  .settings-dialog,
  .identity-dialog,
  .remote-signer-dialog,
  .ban-confirm-dialog {
    width: calc(100vw - 16px);
    max-height: calc(100dvh - 16px);
    border-radius: 18px;
  }

  .ban-confirm-content {
    padding: 24px 20px;
  }

  .ban-confirm-actions {
    flex-direction: column-reverse;
  }

  .ban-confirm-actions button {
    width: 100%;
  }

  .source-dialog-head {
    padding: 21px 18px 16px;
  }

  .source-dialog-head h2 {
    font-size: 31px;
  }

  .source-options {
    grid-template-columns: 1fr;
    padding: 15px 18px 10px;
  }

  .source-option {
    min-height: 118px;
    padding: 16px;
  }

  .source-url-option {
    grid-column: auto;
  }

  .source-url-row {
    align-items: stretch;
    flex-direction: column;
  }

  .source-url-row button {
    min-height: 44px;
  }

  .source-progress {
    margin: 4px 18px 14px;
  }

  .source-dialog-note {
    padding: 0 18px max(20px, env(safe-area-inset-bottom));
  }

  .settings-grid,
  .identity-options {
    grid-template-columns: 1fr;
    padding: 15px 18px 8px;
  }

  .banned-section {
    margin-right: 18px;
    margin-left: 18px;
  }

  .identity-intro {
    padding: 16px 18px 4px;
  }

  .bunker-form {
    padding: 8px 18px 12px;
  }

  .bunker-form > div {
    align-items: stretch;
    flex-direction: column;
  }

  .bunker-form input,
  .bunker-form button {
    min-height: 44px;
  }

  .saved-login-button,
  .settings-save {
    width: calc(100% - 36px);
    margin-right: 18px;
    margin-left: 18px;
  }

  .nip46-panel {
    margin-right: 18px;
    margin-left: 18px;
  }

  .identity-login-status {
    padding: 0 18px max(20px, env(safe-area-inset-bottom));
  }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    scroll-behavior: auto !important;
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
}
