:root {
  --color-bg: #f7fbff;
  --color-text: #172033;
  --color-muted: #64708a;
  --color-surface: #ffffff;
  --color-border: #cbd7ea;
  --color-accent: #1769e0;
  --color-accent-strong: #0e3f94;
  --color-success: #0f7b53;
  --color-danger: #b42318;
  --space-1: 4px;
  --space-2: 8px;
  --space-3: 12px;
  --space-4: 16px;
  --space-5: 24px;
  --space-6: 32px;
  --space-7: 48px;
  --radius-sm: 6px;
  --radius-md: 8px;
  --motion-slow: 22s;
  --motion-medium: 360ms;
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  min-height: 100vh;
  color: var(--color-text);
  background: var(--color-bg);
}

.home-body {
  min-height: 100vh;
  overflow: hidden;
  background:
    radial-gradient(circle at 12% 20%, rgb(23 105 224 / 16%), transparent 26%),
    radial-gradient(circle at 88% 12%, rgb(15 123 83 / 13%), transparent 24%),
    linear-gradient(135deg, #f8fbff 0%, #edf6ff 48%, #fff9ea 100%);
}

.corner-nav {
  position: fixed;
  top: var(--space-4);
  right: var(--space-4);
  z-index: 10;
  display: flex;
  gap: var(--space-2);
}

.corner-nav a {
  display: inline-grid;
  place-items: center;
  min-height: 36px;
  padding: 0 14px;
  color: var(--color-accent-strong);
  background: rgb(255 255 255 / 86%);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-sm);
  box-shadow: 0 10px 28px rgb(22 41 80 / 12%);
  font-size: 0.9rem;
  font-weight: 800;
  text-decoration: none;
}

.corner-nav a:focus-visible {
  outline: 3px solid #8bbdff;
  outline-offset: 3px;
}

.home-stage {
  display: grid;
  align-content: center;
  min-height: 100vh;
  width: min(100%, 1040px);
  padding: var(--space-7) var(--space-5);
  margin: 0 auto;
}

.home-stage h1 {
  max-width: 760px;
  color: var(--color-text);
}

button,
input,
textarea {
  font: inherit;
}

button:focus-visible,
input:focus-visible,
textarea:focus-visible {
  outline: 3px solid #8bbdff;
  outline-offset: 3px;
}

.page {
  display: grid;
  place-items: center;
  padding: var(--space-5);
}

.submit-shell,
.admin-shell,
.login-shell {
  width: min(100%, 920px);
}

.login-shell {
  width: min(100%, 520px);
}

.login-form {
  margin-top: var(--space-5);
}

.submit-shell {
  display: grid;
  gap: var(--space-6);
  grid-template-columns: minmax(0, 0.9fr) minmax(320px, 1.1fr);
  align-items: center;
}

.page-submit .event-intro {
  position: relative;
  left: clamp(-64px, -4vw, -28px);
  max-width: 520px;
}

.event-mark {
  margin: 0 0 var(--space-3);
  color: var(--color-accent);
  font-size: 0.9rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0;
}

.brand-logo {
  display: block;
  width: min(100%, 280px);
  height: auto;
  margin-bottom: var(--space-5);
}

.brand-logo--home {
  width: min(72vw, 360px);
  margin-bottom: var(--space-6);
}

.brand-logo--form {
  width: min(100%, 260px);
}

.brand-logo--login {
  width: min(100%, 230px);
}

.brand-logo--admin {
  width: 180px;
  margin-bottom: var(--space-3);
}

h1,
h2,
p {
  margin-top: 0;
}

h1 {
  margin-bottom: var(--space-4);
  font-size: clamp(2rem, 5vw, 4.5rem);
  line-height: 1;
  letter-spacing: 0;
}

.event-intro p:last-child {
  color: var(--color-muted);
  font-size: 1.1rem;
  line-height: 1.55;
}

.wish-form,
.admin-column {
  background: var(--color-surface);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-md);
  box-shadow: 0 18px 55px rgb(22 41 80 / 12%);
}

.wish-form {
  display: grid;
  gap: var(--space-4);
  padding: var(--space-6);
}

label {
  display: grid;
  gap: var(--space-2);
  color: var(--color-text);
  font-weight: 700;
}

.field-hint {
  color: var(--color-muted);
  font-size: 0.92rem;
  font-weight: 500;
  line-height: 1.35;
}

textarea,
input {
  width: 100%;
  border: 1px solid var(--color-border);
  border-radius: var(--radius-sm);
  padding: 13px 14px;
  color: var(--color-text);
  background: #fbfdff;
}

textarea {
  resize: vertical;
  min-height: 150px;
  line-height: 1.5;
}

.form-row {
  display: flex;
  gap: var(--space-3);
  align-items: center;
}

.between {
  justify-content: space-between;
}

.form-grid {
  display: grid;
  gap: var(--space-4);
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.form-message {
  min-height: 1.4em;
  color: var(--color-muted);
  line-height: 1.4;
}

.form-message.success {
  color: var(--color-success);
}

.form-message.error {
  color: var(--color-danger);
}

.counter {
  color: var(--color-muted);
  font-variant-numeric: tabular-nums;
}

.primary-button,
.secondary-button,
.ghost-button,
.danger-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 0;
  border-radius: var(--radius-sm);
  min-height: 44px;
  padding: 0 18px;
  font-weight: 800;
  line-height: 1;
  text-align: center;
  text-decoration: none;
  cursor: pointer;
  white-space: nowrap;
}

.primary-button {
  color: #fff;
  background: var(--color-accent);
}

.secondary-button {
  color: #fff;
  background: var(--color-accent-strong);
}

.ghost-button {
  color: var(--color-accent-strong);
  background: #eaf2ff;
}

.danger-button {
  color: #fff;
  background: var(--color-danger);
}

button:disabled {
  cursor: wait;
  opacity: 0.65;
}

.screen-body {
  overflow: hidden;
  background: #090d0f;
  color: #f2f6f3;
}

.screen-stage {
  position: relative;
  width: 100vw;
  height: 100vh;
  min-height: 100vh;
  overflow: hidden;
  isolation: isolate;
  background-image:
    linear-gradient(rgb(145 179 174 / 7%) 1px, transparent 1px),
    linear-gradient(90deg, rgb(145 179 174 / 7%) 1px, transparent 1px);
  background-size: 48px 48px;
}

.screen-stage::before {
  content: "";
  position: absolute;
  z-index: 0;
  inset: 0;
  background:
    linear-gradient(90deg, #52d8c8 0 25%, #f5c95f 25% 50%, #ff7f73 50% 75%, #8eafff 75%) top / 100% 3px no-repeat,
    linear-gradient(180deg, transparent 70%, rgb(0 0 0 / 36%) 100%);
  pointer-events: none;
}

.screen-header {
  position: absolute;
  z-index: 4;
  top: 26px;
  left: 38px;
  display: flex;
  align-items: center;
  gap: 22px;
}

.screen-brand {
  display: grid;
  grid-template-columns: auto auto;
  align-items: stretch;
  min-height: 62px;
  border: 1px solid rgb(224 239 234 / 28%);
  border-radius: var(--radius-sm);
  overflow: hidden;
  box-shadow: 0 14px 38px rgb(0 0 0 / 22%);
}

.screen-brand span,
.screen-brand strong {
  display: grid;
  place-items: center;
  padding: 0 14px;
}

.screen-brand span {
  color: #09100f;
  background: #f2f6f3;
  font-size: 1.05rem;
  font-weight: 900;
}

.screen-brand strong {
  color: #09100f;
  background: #52d8c8;
  font-size: 1.55rem;
}

.screen-heading p {
  margin-bottom: 5px;
  color: #aabbb7;
  font-size: 0.78rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0;
}

.screen-header h1 {
  margin: 0;
  color: #fff;
  font-size: 2.75rem;
  line-height: 0.98;
  text-shadow: 0 5px 28px rgb(0 0 0 / 28%);
}

.network-canvas {
  position: absolute;
  z-index: 1;
  inset: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
}

.wish-network {
  position: absolute;
  z-index: 2;
  inset: 128px 3.2vw 58px;
  display: grid;
  grid-template-columns: repeat(var(--network-columns, 3), minmax(0, 1fr));
  grid-template-rows: repeat(var(--network-rows, 3), minmax(0, 1fr));
  gap: clamp(16px, 2.4vh, 30px) clamp(18px, 2.8vw, 44px);
  align-items: center;
  justify-items: center;
  transition: grid-template-columns var(--motion-medium) ease;
}

.wish-node {
  position: relative;
  display: grid;
  grid-template-rows: auto 1fr auto;
  gap: 12px;
  width: min(100%, 480px);
  min-height: 126px;
  max-height: 100%;
  padding: 18px 22px 20px;
  overflow: hidden;
  color: #111817;
  background: #f1f5f2;
  border: 1px solid rgb(255 255 255 / 65%);
  border-radius: var(--radius-sm);
  box-shadow: 0 18px 42px rgb(0 0 0 / 32%);
  opacity: 0;
  scale: 0.96;
  animation: node-float var(--float-duration, 10s) ease-in-out var(--float-delay, 0s) infinite alternate;
  transition: opacity 320ms ease, scale 320ms ease, box-shadow 320ms ease;
  line-height: 1.35;
}

.wish-node::before,
.wish-node::after {
  content: "";
  position: absolute;
  pointer-events: none;
}

.wish-node::before {
  top: 0;
  left: 0;
  width: 36%;
  height: 4px;
  background: var(--accent);
}

.wish-node::after {
  right: 10px;
  bottom: 10px;
  width: 14px;
  height: 14px;
  border-right: 2px solid var(--accent);
  border-bottom: 2px solid var(--accent);
}

.wish-node--visible {
  opacity: 1;
  scale: 1;
}

.wish-node-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.wish-node-code {
  color: #5b6d68;
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;
  font-size: 0.68rem;
  font-weight: 800;
  text-transform: uppercase;
}

.wish-node-signal {
  width: 7px;
  height: 7px;
  flex: 0 0 auto;
  background: var(--accent);
  box-shadow: 0 0 0 4px color-mix(in srgb, var(--accent) 20%, transparent);
}

.wish-node-text {
  align-self: center;
  font-size: 1.42rem;
  line-height: 1.24;
  overflow-wrap: anywhere;
}

.wish-node-meta {
  color: #576761;
  font-size: 0.82rem;
  font-weight: 700;
}

.wish-node--long .wish-node-text {
  font-size: 1.2rem;
}

.wish-node--very-long .wish-node-text {
  font-size: 1.05rem;
}

.wish-network[data-density="solo"] .wish-node {
  width: min(72vw, 760px);
  min-height: 210px;
  padding: 26px 32px 30px;
}

.wish-network[data-density="solo"] .wish-node-text {
  font-size: 2rem;
}

.wish-network[data-density="solo"] .wish-node--long .wish-node-text {
  font-size: 1.72rem;
}

.wish-network[data-density="solo"] .wish-node--very-long .wish-node-text {
  font-size: 1.45rem;
}

.wish-network[data-density="sparse"] .wish-node {
  width: min(100%, 580px);
  min-height: 168px;
}

.wish-network[data-density="sparse"] .wish-node-text {
  font-size: 1.65rem;
}

.wish-network[data-density="sparse"] .wish-node--long .wish-node-text {
  font-size: 1.35rem;
}

.wish-network[data-density="sparse"] .wish-node--very-long .wish-node-text {
  font-size: 1.16rem;
}

@keyframes node-float {
  from {
    translate: -4px -3px;
  }
  to {
    translate: 4px 3px;
  }
}

.screen-footer {
  position: absolute;
  z-index: 4;
  right: 32px;
  bottom: 18px;
  left: 38px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 20px;
  color: #9aaca7;
  font-size: 0.78rem;
  font-weight: 700;
}

.screen-status {
  display: flex;
  align-items: center;
  gap: 9px;
}

.screen-status-dot {
  width: 7px;
  height: 7px;
  background: #f5c95f;
}

.screen-status[data-state="online"] .screen-status-dot {
  background: #52d8c8;
  box-shadow: 0 0 0 4px rgb(82 216 200 / 14%);
}

.screen-status[data-state="offline"] .screen-status-dot {
  background: #ff7f73;
}

.screen-signature {
  color: #71817d;
  text-transform: uppercase;
}

@media (max-height: 850px) and (min-width: 701px) {
  .screen-header {
    top: 18px;
  }

  .screen-brand {
    min-height: 54px;
  }

  .screen-header h1 {
    font-size: 2.25rem;
  }

  .wish-network {
    inset: 105px 3vw 48px;
    gap: 14px 32px;
  }

  .wish-node {
    min-height: 104px;
    padding: 14px 18px 16px;
    gap: 8px;
  }

  .wish-node-text {
    font-size: 1.18rem;
  }

  .wish-node--long .wish-node-text {
    font-size: 1.02rem;
  }

  .wish-node--very-long .wish-node-text {
    font-size: 0.9rem;
  }

  .wish-network[data-density="solo"] .wish-node-text {
    font-size: 1.8rem;
  }
}

@media (max-width: 700px) {
  .screen-body {
    overflow: auto;
  }

  .screen-stage {
    width: 100%;
    height: auto;
    min-height: 100svh;
    padding: 18px 14px 24px;
    overflow: visible;
    background-size: 32px 32px;
  }

  .screen-header {
    position: relative;
    top: auto;
    left: auto;
    gap: 12px;
  }

  .screen-brand {
    min-height: 48px;
  }

  .screen-brand span,
  .screen-brand strong {
    padding: 0 9px;
  }

  .screen-brand span {
    font-size: 0.8rem;
  }

  .screen-brand strong {
    font-size: 1.1rem;
  }

  .screen-heading p {
    font-size: 0.65rem;
  }

  .screen-header h1 {
    font-size: 1.45rem;
  }

  .network-canvas {
    display: none;
  }

  .wish-network {
    position: relative;
    inset: auto;
    grid-template-columns: 1fr !important;
    grid-template-rows: none !important;
    gap: 14px;
    margin-top: 28px;
  }

  .wish-network .wish-node,
  .wish-network[data-density="solo"] .wish-node,
  .wish-network[data-density="sparse"] .wish-node {
    width: 100%;
    min-height: 132px;
    padding: 18px 20px 20px;
  }

  .wish-network .wish-node-text,
  .wish-network[data-density="solo"] .wish-node-text,
  .wish-network[data-density="sparse"] .wish-node-text {
    font-size: 1.2rem;
  }

  .wish-network .wish-node--long .wish-node-text,
  .wish-network .wish-node--very-long .wish-node-text {
    font-size: 1.02rem;
  }

  .screen-footer {
    position: relative;
    right: auto;
    bottom: auto;
    left: auto;
    margin-top: 24px;
    font-size: 0.7rem;
  }

  .screen-signature {
    display: none;
  }
}

.admin-shell {
  display: grid;
  gap: var(--space-5);
}

.admin-header {
  display: flex;
  justify-content: space-between;
  gap: var(--space-4);
  align-items: center;
}

.admin-header-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: flex-end;
  gap: var(--space-3);
}

.admin-capacity {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  color: var(--color-muted);
  font-size: 0.82rem;
  font-weight: 800;
  text-transform: uppercase;
}

.admin-export-link {
  color: var(--color-accent-strong);
}

.admin-header h1 {
  font-size: clamp(2rem, 4vw, 3.4rem);
}

.admin-columns {
  display: grid;
  gap: var(--space-4);
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
}

.admin-column {
  padding: var(--space-5);
  min-height: 420px;
}

.admin-column h2 {
  margin-bottom: var(--space-4);
}

.wish-list {
  display: grid;
  gap: var(--space-3);
}

.wish-item {
  display: grid;
  gap: var(--space-3);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-md);
  padding: var(--space-4);
  background: #fbfdff;
}

.wish-item--featured {
  border-color: #52a89e;
  box-shadow: inset 4px 0 0 #52a89e;
}

.wish-item p {
  margin-bottom: 0;
  overflow-wrap: anywhere;
  line-height: 1.45;
}

.wish-meta {
  color: var(--color-muted);
  font-size: 0.9rem;
}

.wish-actions {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-2);
}

.muted-list .wish-item {
  opacity: 0.72;
}

@media (max-width: 760px) {
  .page {
    place-items: start;
    padding: var(--space-4);
  }

  .submit-shell,
  .admin-columns,
  .form-grid {
    grid-template-columns: 1fr;
  }

  .page-submit .event-intro {
    left: 0;
  }

  .wish-form {
    padding: var(--space-5);
  }

  .admin-header {
    align-items: flex-start;
    flex-direction: column;
  }
}

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

  .wish-node {
    animation: none;
  }
}

/* Digital yearbook screen */
.screen-stage {
  background-color: #090d0f;
  background-image:
    linear-gradient(rgb(145 179 174 / 7%) 1px, transparent 1px),
    linear-gradient(90deg, rgb(145 179 174 / 7%) 1px, transparent 1px),
    repeating-linear-gradient(90deg, transparent 0 191px, rgb(255 255 255 / 2%) 192px);
  animation: screen-grid-drift 64s linear infinite;
}

.screen-scan {
  position: absolute;
  z-index: 1;
  top: 0;
  right: 0;
  left: 0;
  height: 1px;
  background: #52d8c8;
  box-shadow: 0 0 18px rgb(82 216 200 / 55%);
  opacity: 0;
  pointer-events: none;
  animation: screen-scan 26s linear infinite;
}

.screen-chrome-label {
  position: absolute;
  z-index: 3;
  top: 50%;
  color: #53635f;
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;
  font-size: 0.62rem;
  font-weight: 700;
  writing-mode: vertical-rl;
}

.screen-chrome-label--left {
  left: 12px;
  rotate: 180deg;
}

.screen-chrome-label--right {
  right: 12px;
}

.screen-header {
  top: 25px;
  right: 38px;
  left: 38px;
  justify-content: space-between;
  align-items: flex-end;
  gap: 40px;
}

.screen-heading p {
  margin: 0 0 5px;
  color: #aabbb7;
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;
  font-size: 0.72rem;
}

.screen-header .screen-heading h1 {
  margin: 0;
  color: #f3f7f4;
  font-size: 3.65rem;
  font-weight: 900;
  line-height: 0.88;
}

.screen-heading h1 span {
  color: #52d8c8;
}

.screen-logo-title {
  line-height: 0;
}

.screen-logo {
  display: block;
  width: 340px;
  max-width: 36vw;
  height: auto;
}

.screen-event-meta {
  display: grid;
  gap: 6px;
  padding-bottom: 3px;
  color: #aabbb7;
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;
  font-size: 0.72rem;
  text-align: right;
  text-transform: uppercase;
}

.screen-header-tools {
  display: flex;
  align-items: center;
  gap: 18px;
}

.screen-qr {
  display: grid;
  grid-template-columns: minmax(112px, 1fr) 132px;
  gap: 12px;
  width: 316px;
  min-height: 148px;
  padding: 8px;
  color: #15201e;
  background: #f4f8f5;
  border: 1px solid rgb(255 255 255 / 70%);
  border-radius: var(--radius-sm);
  box-shadow: 0 18px 42px rgb(0 0 0 / 32%);
}

.screen-qr-copy {
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  gap: 16px;
  padding: 10px 5px 9px 9px;
}

.screen-qr-copy strong {
  font-size: 1.08rem;
  line-height: 1.08;
  text-transform: uppercase;
}

.screen-qr-copy span {
  color: #61716d;
  font-size: 0.72rem;
  font-weight: 700;
  line-height: 1.25;
}

.screen-qr-link {
  position: relative;
  display: grid;
  place-items: center;
  width: 132px;
  height: 132px;
  overflow: hidden;
  color: #13201d;
  background: #f4f8f5;
  border: 1px solid #c7d5d0;
  border-radius: 3px;
}

.screen-qr-link img {
  display: block;
  width: 100%;
  height: 100%;
}

.screen-qr-placeholder {
  display: none;
  place-items: center;
  gap: 7px;
  padding: 10px;
  text-align: center;
}

.screen-qr-placeholder strong {
  color: #8a9a96;
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;
  font-size: 1.5rem;
}

.screen-qr-placeholder small {
  color: #6b7b77;
  font-size: 0.62rem;
  font-weight: 700;
  line-height: 1.2;
  text-transform: uppercase;
}

.screen-qr[data-state="loading"] .screen-qr-link {
  background:
    linear-gradient(90deg, transparent 46%, rgb(82 216 200 / 22%) 50%, transparent 54%) 0 0 / 200% 100%,
    #eef4f1;
  animation: qr-loading 1.8s linear infinite;
}

.screen-qr[data-state="loading"] img {
  display: none;
}

.screen-qr[data-state="unavailable"] {
  border-color: #f5c95f;
}

.screen-qr[data-state="unavailable"] img {
  display: none;
}

.screen-qr[data-state="unavailable"] .screen-qr-placeholder {
  display: grid;
}

.screen-event-meta strong {
  color: #f5c95f;
}

.screen-empty {
  position: absolute;
  z-index: 2;
  top: 54%;
  left: 50%;
  display: grid;
  justify-items: center;
  gap: 10px;
  width: min(80vw, 620px);
  color: #eef5f1;
  text-align: center;
  translate: -50% -50%;
}

.screen-empty[hidden] {
  display: none;
}

.screen-empty-core {
  position: relative;
  width: 58px;
  height: 58px;
  margin-bottom: 16px;
  border: 1px solid rgb(82 216 200 / 58%);
  rotate: 45deg;
  animation: empty-core 5s ease-in-out infinite alternate;
}

.screen-empty-core::before,
.screen-empty-core::after {
  content: "";
  position: absolute;
  background: #52d8c8;
}

.screen-empty-core::before {
  top: 50%;
  right: -34px;
  left: -34px;
  height: 1px;
}

.screen-empty-core::after {
  top: -34px;
  bottom: -34px;
  left: 50%;
  width: 1px;
}

.screen-empty strong {
  font-size: 1.65rem;
}

.screen-empty small {
  color: #788985;
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;
  font-size: 0.7rem;
  text-transform: uppercase;
}

.wish-network {
  inset: 180px 4vw 58px;
}

.wish-network::before {
  content: "";
  position: fixed;
  z-index: 4;
  inset: 0;
  background: rgb(6 9 10 / 78%);
  opacity: 0;
  pointer-events: none;
  transition: opacity 420ms ease;
}

.wish-network[data-featured="true"]::before {
  opacity: 1;
}

.wish-network--reflowing {
  animation: network-reflow 480ms ease;
}

.wish-node {
  padding-left: 28px;
  background:
    linear-gradient(90deg, rgb(17 24 23 / 4%) 1px, transparent 1px) 0 0 / 28px 100%,
    #f1f5f2;
}

.wish-node--short {
  width: min(86%, 420px);
}

.wish-node-scale {
  position: absolute;
  top: 37px;
  bottom: 25px;
  left: 8px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  width: 8px;
  border-left: 1px solid rgb(17 24 23 / 16%);
}

.wish-node-scale i {
  width: 7px;
  height: 1px;
  background: rgb(17 24 23 / 28%);
}

.wish-node-state {
  display: flex;
  align-items: center;
  gap: 10px;
}

.wish-node-new {
  color: #17211f;
  background: var(--accent);
  padding: 3px 6px;
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;
  font-size: 0.58rem;
  font-weight: 900;
}

.wish-node--featured {
  position: fixed;
  z-index: 5;
  top: 53%;
  left: 50%;
  width: min(70vw, 980px) !important;
  min-height: min(360px, 48vh) !important;
  max-height: 58vh;
  padding: 32px 40px 36px;
  transform: translate(-50%, -50%);
  animation: none;
  opacity: 1;
  scale: 1;
}

.wish-node--featured .wish-node-code::after {
  content: " · ГЛАВНОЕ";
  color: #b05249;
}

.wish-node--featured .wish-node-text,
.wish-node--featured.wish-node--long .wish-node-text,
.wish-node--featured.wish-node--very-long .wish-node-text {
  font-size: 2rem;
}

.wish-network[data-featured="true"] .wish-node:not(.wish-node--featured) {
  opacity: 0.08;
  scale: 0.96;
}

.wish-network[data-density="dense"] .wish-node {
  animation: none;
}

.wish-network[data-density="dense"] .wish-node-new {
  padding: 2px 5px;
}

@keyframes screen-scan {
  0%,
  74% {
    top: 0;
    opacity: 0;
  }
  76% {
    opacity: 0.32;
  }
  98% {
    top: 100%;
    opacity: 0.08;
  }
  100% {
    top: 100%;
    opacity: 0;
  }
}

@keyframes screen-grid-drift {
  from {
    background-position: 0 0, 0 0, 0 0;
  }
  to {
    background-position: 48px 48px, -48px 48px, 192px 0;
  }
}

@keyframes qr-loading {
  to {
    background-position: -200% 0, 0 0;
  }
}

@keyframes empty-core {
  from {
    opacity: 0.48;
    scale: 0.92;
  }
  to {
    opacity: 1;
    scale: 1;
  }
}

@keyframes network-reflow {
  0% {
    opacity: 0.72;
    filter: brightness(1.32);
  }
  100% {
    opacity: 1;
    filter: brightness(1);
  }
}

@media (max-height: 850px) and (min-width: 701px) {
  .screen-header {
    top: 16px;
  }

  .screen-header .screen-heading h1 {
    font-size: 2.8rem;
  }

  .screen-logo {
    width: 270px;
  }

  .wish-network {
    inset: 128px 4vw 48px;
  }

  .screen-qr {
    grid-template-columns: minmax(90px, 1fr) 96px;
    width: 250px;
    min-height: 108px;
    padding: 6px;
  }

  .screen-qr-link {
    width: 96px;
    height: 96px;
  }

  .screen-qr-copy {
    padding: 7px 3px 7px 7px;
  }

  .screen-qr-copy strong {
    font-size: 0.84rem;
  }

  .screen-qr-copy span {
    font-size: 0.61rem;
  }

  .wish-node--featured {
    min-height: min(300px, 48vh) !important;
  }

  .wish-node--featured .wish-node-text,
  .wish-node--featured.wish-node--long .wish-node-text,
  .wish-node--featured.wish-node--very-long .wish-node-text {
    font-size: 1.6rem;
  }
}

@media (max-width: 1100px) and (min-width: 701px) {
  .screen-header .screen-heading h1 {
    font-size: 2.8rem;
  }

  .screen-logo {
    width: 270px;
  }

  .screen-header-tools {
    gap: 10px;
  }

  .screen-qr {
    grid-template-columns: minmax(90px, 1fr) 96px;
    width: 250px;
    min-height: 108px;
    padding: 6px;
  }

  .screen-qr-link {
    width: 96px;
    height: 96px;
  }

  .screen-qr-copy {
    padding: 7px 3px 7px 7px;
  }

  .screen-qr-copy strong {
    font-size: 0.84rem;
  }

  .screen-qr-copy span {
    font-size: 0.61rem;
  }

  .wish-network {
    inset: 128px 4vw 48px;
  }
}

@media (max-width: 700px) {
  .screen-chrome,
  .screen-scan,
  .screen-qr {
    display: none;
  }

  .screen-header {
    position: relative;
    top: auto;
    right: auto;
    left: auto;
    align-items: flex-start;
  }

  .screen-stage {
    animation: none;
  }

  .screen-header .screen-heading h1 {
    font-size: 2rem;
  }

  .screen-logo {
    width: min(58vw, 250px);
    max-width: none;
  }

  .screen-event-meta {
    font-size: 0.58rem;
  }

  .wish-network {
    position: relative;
    inset: auto;
    width: 100%;
  }

  .screen-empty {
    position: relative;
    top: auto;
    left: auto;
    min-height: 60vh;
    margin: 30px auto 0;
    align-content: center;
    translate: none;
  }

  .wish-node--short {
    width: 100%;
  }

  .wish-node {
    animation: none;
  }

  .wish-node--featured {
    position: relative;
    top: auto;
    left: auto;
    width: 100% !important;
    min-height: 220px !important;
    max-height: none;
    transform: none;
    order: -1;
  }

  .wish-node--featured .wish-node-text,
  .wish-node--featured.wish-node--long .wish-node-text,
  .wish-node--featured.wish-node--very-long .wish-node-text {
    font-size: 1.32rem;
  }

  .wish-network[data-featured="true"]::before {
    display: none;
  }

  .wish-network[data-featured="true"] .wish-node:not(.wish-node--featured) {
    opacity: 0.32;
  }
}

/* Central word cloud */
.screen-heading > strong {
  display: block;
  color: #e8f0ed;
  font-size: 1rem;
  line-height: 1.1;
  text-transform: uppercase;
}

.screen-word-cloud {
  position: absolute;
  z-index: 2;
  top: 53%;
  left: 50%;
  width: min(44vw, 76vh, 780px);
  aspect-ratio: 1;
  pointer-events: none;
  transform: translate(-50%, -50%);
  transition: opacity 420ms ease, filter 420ms ease;
}

.word-cloud-layer {
  position: absolute;
  inset: 0;
}

.word-cloud-layer::before,
.word-cloud-layer::after {
  content: "";
  position: absolute;
  top: 50%;
  left: 50%;
  border: 1px solid rgb(82 216 200 / 10%);
  border-radius: 50%;
  transform: translate(-50%, -50%);
}

.word-cloud-layer::before {
  width: 61%;
  height: 61%;
  border-style: dashed;
}

.word-cloud-layer::after {
  width: 96%;
  height: 96%;
  border-color: rgb(142 175 255 / 8%);
}

.word-cloud-item {
  position: absolute;
  display: block;
  color: #aabbb7;
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;
  font-size: 0.86rem;
  font-weight: 750;
  line-height: 1;
  white-space: nowrap;
  transform: translate(-50%, -50%);
}

.word-cloud-item[hidden] {
  display: none;
}

.word-cloud-item[data-weight="2"] {
  color: #d7e3df;
  font-size: 1rem;
  font-weight: 800;
}

.word-cloud-item[data-weight="3"] {
  color: #f1f6f4;
  font-size: 1.15rem;
  font-weight: 850;
}

.word-cloud-token {
  display: block;
  padding: 4px 6px;
  border-left: 2px solid var(--word-accent);
  text-shadow: 0 0 18px color-mix(in srgb, var(--word-accent) 32%, transparent);
  animation: word-cloud-drift 8s ease-in-out var(--word-delay, 0s) infinite alternate;
}

.screen-core {
  position: absolute;
  z-index: 2;
  top: 50%;
  left: 50%;
  display: grid;
  justify-items: center;
  gap: 10px;
  width: 340px;
  min-height: 180px;
  align-content: center;
  color: #eff5f2;
  text-align: center;
  transform: translate(-50%, -50%);
}

.screen-core::before,
.screen-core::after {
  content: "";
  position: absolute;
  z-index: -1;
  pointer-events: none;
}

.screen-core::before {
  inset: -22px -34px;
  border-top: 1px solid rgb(82 216 200 / 30%);
  border-bottom: 1px solid rgb(142 175 255 / 22%);
}

.screen-core::after {
  top: 50%;
  right: -66px;
  left: -66px;
  height: 1px;
  background: linear-gradient(90deg, transparent, rgb(82 216 200 / 20%) 18%, transparent 18% 82%, rgb(82 216 200 / 20%) 82%, transparent);
}

.screen-core-kicker,
.screen-core-count,
.screen-core .screen-empty small {
  color: #82938f;
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;
  font-size: 0.62rem;
  font-weight: 800;
  text-transform: uppercase;
}

.screen-core-title {
  margin: 0;
  line-height: 0;
}

.screen-core-logo {
  display: block;
  width: 280px;
  max-width: 100%;
  height: auto;
  filter: drop-shadow(0 12px 28px rgb(0 0 0 / 38%));
}

.screen-core .screen-empty {
  position: static;
  display: grid;
  justify-items: center;
  gap: 4px;
  width: auto;
  color: #eef5f1;
  transform: none;
  translate: none;
}

.screen-core .screen-empty[hidden] {
  display: none;
}

.screen-core .screen-empty strong {
  font-size: 0.85rem;
}

.screen-core-count {
  color: #52d8c8;
}

.screen-scene {
  position: absolute;
  left: 50%;
  display: grid;
  justify-items: center;
  gap: 5px;
  color: #82938f;
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;
  font-size: 0.62rem;
  font-weight: 800;
  text-transform: uppercase;
  transform: translateX(-50%);
}

.screen-scene[hidden] {
  display: none;
}

.screen-scene-track {
  display: block;
  width: 120px;
  height: 2px;
  overflow: hidden;
  background: rgb(255 255 255 / 9%);
}

.screen-scene-track i {
  display: block;
  width: 100%;
  height: 100%;
  background: #52d8c8;
  transform-origin: left;
}

.screen-scene--running .screen-scene-track i {
  animation: screen-scene-progress var(--scene-duration, 18s) linear;
}

.screen-stage[data-featured="true"] .screen-word-cloud {
  opacity: 0.12;
  filter: blur(1px);
}

@keyframes word-cloud-drift {
  from {
    translate: -4px -2px;
  }
  to {
    translate: 4px 2px;
  }
}

@keyframes screen-scene-progress {
  from {
    scale: 0 1;
  }
  to {
    scale: 1 1;
  }
}

/* Peripheral hardware modules */
.wish-node {
  width: 100%;
  min-height: 0;
  height: min(100%, 184px);
  padding: 16px 30px 18px;
  gap: 9px;
  background:
    linear-gradient(90deg, transparent 0 74%, rgb(40 74 67 / 5%) 74% 74.5%, transparent 74.5%),
    linear-gradient(0deg, transparent 0 28%, rgb(40 74 67 / 4%) 28% 28.6%, transparent 28.6%),
    #edf3f0;
  border: 0;
  border-radius: 0;
  clip-path: polygon(0 14px, 14px 0, calc(100% - 30px) 0, 100% 30px, 100% calc(100% - 14px), calc(100% - 14px) 100%, 28px 100%, 0 calc(100% - 28px));
  filter: drop-shadow(0 15px 24px rgb(0 0 0 / 28%));
  box-shadow:
    inset 0 0 0 1px rgb(255 255 255 / 74%),
    inset 0 -1px 0 rgb(24 51 46 / 16%);
}

.wish-node--short {
  width: 100%;
}

.wish-node::before {
  width: 46%;
  height: 4px;
  box-shadow: 18px 7px 0 -1px color-mix(in srgb, var(--accent) 30%, transparent);
}

.wish-node::after {
  right: 13px;
  bottom: 13px;
  width: 18px;
  height: 18px;
  border-right: 2px solid var(--accent);
  border-bottom: 2px solid var(--accent);
  box-shadow: 5px 5px 0 -3px #edf3f0;
}

.wish-node[data-side="right"]::before {
  right: 0;
  left: auto;
}

.wish-node[data-side="right"]::after {
  right: auto;
  left: 13px;
  border-right: 0;
  border-left: 2px solid var(--accent);
}

.wish-node-ports {
  position: absolute;
  top: 50%;
  display: grid;
  gap: 8px;
  transform: translateY(-50%);
}

.wish-node[data-side="left"] .wish-node-ports {
  right: 0;
}

.wish-node[data-side="right"] .wish-node-ports {
  left: 0;
}

.wish-node-ports i {
  display: block;
  width: 13px;
  height: 2px;
  background: var(--accent);
  opacity: 0.7;
}

.wish-node[data-side="right"] .wish-node-scale {
  right: 8px;
  left: auto;
  border-right: 1px solid rgb(17 24 23 / 16%);
  border-left: 0;
}

.wish-node-code {
  letter-spacing: 0;
}

.wish-node-text {
  font-size: 1.28rem;
  line-height: 1.18;
}

.wish-node--long .wish-node-text {
  font-size: 1.05rem;
}

.wish-node--very-long .wish-node-text {
  font-size: 0.94rem;
  line-height: 1.16;
}

.wish-node-meta {
  font-size: 0.74rem;
}

.wish-node--featured {
  height: auto;
  min-height: min(360px, 48vh);
  clip-path: polygon(0 20px, 20px 0, calc(100% - 42px) 0, 100% 42px, 100% calc(100% - 20px), calc(100% - 20px) 100%, 42px 100%, 0 calc(100% - 42px));
}

.wish-node--featured .wish-node-ports {
  display: none;
}

.wish-network[data-density="solo"] .wish-node {
  width: 100%;
  height: min(100%, 230px);
  min-height: 230px;
  padding: 18px 30px 20px;
}

.wish-network[data-density="solo"] .wish-node-text {
  font-size: 1.28rem;
}

.wish-network[data-density="solo"] .wish-node--long .wish-node-text {
  font-size: 1.05rem;
}

.wish-network[data-density="solo"] .wish-node--very-long .wish-node-text {
  font-size: 0.94rem;
}

@media (min-width: 1101px) {
  .wish-network {
    grid-template-columns: minmax(300px, 420px) minmax(520px, 1fr) minmax(300px, 420px);
    grid-template-rows: repeat(var(--scene-rows, 4), minmax(0, 1fr));
    gap: 12px 32px;
  }

  .wish-node[data-side="left"] {
    grid-column: 1;
  }

  .wish-node[data-side="right"] {
    grid-column: 3;
  }

  .wish-node[data-side-slot="0"] {
    grid-row: 1;
  }

  .wish-node[data-side-slot="1"] {
    grid-row: 2;
  }

  .wish-node[data-side-slot="2"] {
    grid-row: 3;
  }

  .wish-node[data-side-slot="3"] {
    grid-row: 4;
  }
}

@media (max-width: 1100px) and (min-width: 701px) {
  .wish-network {
    grid-template-columns: minmax(190px, 1fr) minmax(270px, 1.2fr) minmax(190px, 1fr);
    grid-template-rows: repeat(var(--scene-rows, 2), minmax(0, 1fr));
    gap: 14px 18px;
  }

  .wish-node[data-side="left"] {
    grid-column: 1;
  }

  .wish-node[data-side="right"] {
    grid-column: 3;
  }

  .wish-node[data-side-slot="0"] {
    grid-row: 1;
  }

  .wish-node[data-side-slot="1"] {
    grid-row: 2;
  }

  .wish-node {
    height: min(100%, 180px);
    padding: 15px 24px 17px;
  }

  .wish-node-text {
    font-size: 1rem;
  }

  .wish-node--long .wish-node-text,
  .wish-node--very-long .wish-node-text {
    font-size: 0.82rem;
  }
}

@media (max-width: 1500px) and (min-width: 701px) {
  .screen-word-cloud {
    width: min(43vw, 72vh, 600px);
  }

  .screen-core {
    width: 270px;
    min-height: 150px;
  }

  .screen-core-logo {
    width: 220px;
  }

  .word-cloud-item {
    font-size: 0.68rem;
  }

  .word-cloud-item[data-weight="2"] {
    font-size: 0.78rem;
  }

  .word-cloud-item[data-weight="3"] {
    font-size: 0.88rem;
  }
}

@media (max-width: 1500px) and (min-width: 1101px) {
  .wish-node {
    height: min(100%, 188px);
    padding: 12px 26px 13px;
    gap: 6px;
  }

  .wish-node-text {
    font-size: 1.08rem;
    line-height: 1.16;
  }

  .wish-node--long .wish-node-text {
    font-size: 0.94rem;
  }

  .wish-node--very-long .wish-node-text {
    font-size: 0.84rem;
    line-height: 1.13;
  }

  .wish-node-meta {
    font-size: 0.68rem;
  }
}

@media (prefers-reduced-motion: reduce) {
  .word-cloud-token {
    animation: none;
  }

  .screen-scene-track {
    display: none;
  }
}

.screen-stage[data-motion="forced"] {
  animation-duration: 64s !important;
  animation-iteration-count: infinite !important;
}

.screen-stage[data-motion="forced"] .screen-scene-track {
  display: block;
}

.screen-stage[data-motion="forced"] .screen-scene--running .screen-scene-track i {
  animation-duration: var(--scene-duration, 18s) !important;
  animation-iteration-count: 1 !important;
}

@media (max-width: 700px) {
  .screen-word-cloud {
    position: relative;
    top: auto;
    left: auto;
    width: min(92vw, 430px);
    margin: 30px auto 20px;
    transform: none;
  }

  .word-cloud-item {
    display: none;
  }

  .screen-core {
    width: min(76vw, 290px);
  }

  .screen-core-logo {
    width: min(66vw, 250px);
  }

  .screen-core::before,
  .screen-core::after {
    display: none;
  }

  .screen-scene {
    position: static;
    transform: none;
  }

  .wish-node,
  .wish-network .wish-node,
  .wish-network[data-density="solo"] .wish-node,
  .wish-network[data-density="sparse"] .wish-node {
    height: auto;
    min-height: 132px;
    overflow: visible;
    clip-path: none;
    filter: none;
  }

  .wish-node-ports {
    display: none;
  }
}

/* Static brand orbit and graduation chat streams */
.screen-word-cloud {
  top: 52%;
  width: min(45vw, 76vh, 790px);
}

.static-orbit {
  position: absolute;
  inset: 0;
}

.static-orbit::before,
.static-orbit::after {
  content: "";
  position: absolute;
  top: 50%;
  left: 50%;
  border: 1px solid rgb(142 175 255 / 15%);
  border-radius: 50%;
  transform: translate(-50%, -50%);
}

.static-orbit::before {
  width: 68%;
  height: 68%;
  border-color: rgb(82 216 200 / 18%);
  border-style: dashed;
}

.static-orbit::after {
  width: 94%;
  height: 94%;
}

.orbit-node {
  position: absolute;
  z-index: 3;
  display: flex;
  align-items: center;
  gap: 11px;
  color: var(--orbit-accent);
  transform: translate(-50%, -50%);
}

.orbit-node i {
  display: grid;
  width: 54px;
  height: 54px;
  flex: 0 0 auto;
  place-items: center;
  color: var(--orbit-accent);
  background: rgb(6 9 10 / 88%);
  border: 2px solid var(--orbit-accent);
  border-radius: 50%;
  box-shadow: 0 0 24px color-mix(in srgb, var(--orbit-accent) 16%, transparent);
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;
  font-size: 1.35rem;
  font-style: normal;
  font-weight: 800;
}

.orbit-node strong {
  font-size: clamp(1rem, 1.35vw, 1.55rem);
  line-height: 1;
  text-shadow: 0 0 22px color-mix(in srgb, var(--orbit-accent) 24%, transparent);
  text-transform: lowercase;
  white-space: nowrap;
}

.orbit-node--luck,
.orbit-node--friendship,
.orbit-node--team,
.orbit-node--future {
  flex-direction: row-reverse;
}

.orbit-node--luck { top: 9%; left: 31%; }
.orbit-node--dreams { top: 9%; left: 70%; }
.orbit-node--friendship { top: 31%; left: 12%; }
.orbit-node--success { top: 31%; left: 88%; }
.orbit-node--team { top: 61%; left: 10%; }
.orbit-node--courage { top: 61%; left: 91%; }
.orbit-node--future { top: 84%; left: 28%; }
.orbit-node--inspiration { top: 84%; left: 73%; }

.screen-core {
  width: 430px;
  min-height: 210px;
  gap: 12px;
}

.screen-core::before {
  inset: -30px -54px;
  border-color: rgb(82 216 200 / 30%);
}

.screen-core::after {
  right: -94px;
  left: -94px;
}

.screen-core-kicker {
  color: #9fb0ac;
  font-size: 0.68rem;
  letter-spacing: 0;
}

.screen-core-logo {
  width: 370px;
}

.wish-network {
  z-index: 3;
  inset: 190px 2.8vw 64px;
  grid-template-columns: minmax(330px, 430px) minmax(500px, 1fr) minmax(330px, 430px);
  grid-template-rows: repeat(var(--scene-rows, 4), minmax(0, 1fr));
  gap: 14px 34px;
  align-items: stretch;
  justify-items: stretch;
  transition: none;
}

.chat-stream-label {
  position: absolute;
  top: -31px;
  color: #d7e2df;
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;
  font-size: 0.72rem;
  font-weight: 800;
  letter-spacing: 0;
  white-space: nowrap;
}

.chat-stream-label::first-letter {
  color: #52d8c8;
}

.chat-stream-label--left {
  left: 0;
}

.chat-stream-label--right {
  right: 0;
}

.wish-node,
.wish-network[data-density="solo"] .wish-node,
.wish-network[data-density="sparse"] .wish-node {
  position: relative;
  display: grid;
  grid-template-rows: auto minmax(0, 1fr) auto;
  gap: 8px;
  width: 100%;
  height: 100%;
  min-height: 0;
  max-height: 184px;
  padding: 13px 17px 12px;
  overflow: visible;
  color: #101615;
  background: #f0f3f2;
  border: 1px solid rgb(255 255 255 / 82%);
  border-radius: 6px;
  clip-path: none;
  filter: drop-shadow(0 14px 22px rgb(0 0 0 / 27%));
  box-shadow: inset 0 -1px 0 rgb(23 50 46 / 12%);
  opacity: 1;
  scale: 1;
  animation: none;
  transition: none;
}

.wish-node--short {
  width: 100%;
}

.wish-node::before {
  top: 0;
  left: 18px;
  width: 64px;
  height: 3px;
  background: var(--accent);
  box-shadow: none;
}

.wish-node::after {
  top: 50%;
  right: auto;
  bottom: auto;
  left: -14px;
  width: 0;
  height: 0;
  border: 0;
  border-top: 10px solid transparent;
  border-right: 14px solid #f0f3f2;
  border-bottom: 10px solid transparent;
  box-shadow: none;
  transform: translateY(-50%);
}

.wish-node[data-side="right"]::before {
  right: 18px;
  left: auto;
}

.wish-node[data-side="right"]::after {
  right: -14px;
  left: auto;
  border-right: 0;
  border-left: 14px solid #f0f3f2;
}

.wish-node-header {
  display: grid;
  grid-template-columns: 38px minmax(0, 1fr) auto;
  align-items: center;
  gap: 10px;
}

.wish-node-avatar {
  display: grid;
  width: 38px;
  height: 38px;
  place-items: center;
  color: #f7fbfa;
  background: color-mix(in srgb, var(--accent) 78%, #23413c);
  border-radius: 50%;
  font-size: 0.85rem;
  font-weight: 900;
}

.wish-node-identity {
  display: grid;
  gap: 2px;
  min-width: 0;
}

.wish-node-author {
  overflow: hidden;
  font-size: 0.9rem;
  line-height: 1.05;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.wish-node-group {
  overflow: hidden;
  color: #47706a;
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;
  font-size: 0.62rem;
  font-weight: 800;
  line-height: 1;
  text-overflow: ellipsis;
  text-transform: uppercase;
  white-space: nowrap;
}

.wish-node-state {
  gap: 6px;
}

.wish-node-signal {
  width: 6px;
  height: 6px;
  border-radius: 50%;
}

.wish-node-new {
  padding: 2px 5px;
  border-radius: 3px;
}

.wish-node-text,
.wish-network[data-density="solo"] .wish-node-text,
.wish-network[data-density="sparse"] .wish-node-text {
  align-self: center;
  font-size: 1.08rem;
  font-weight: 750;
  line-height: 1.18;
}

.wish-node--long .wish-node-text,
.wish-network[data-density="solo"] .wish-node--long .wish-node-text,
.wish-network[data-density="sparse"] .wish-node--long .wish-node-text {
  font-size: 0.9rem;
  line-height: 1.14;
}

.wish-node--very-long .wish-node-text,
.wish-network[data-density="solo"] .wish-node--very-long .wish-node-text,
.wish-network[data-density="sparse"] .wish-node--very-long .wish-node-text {
  font-size: 0.78rem;
  line-height: 1.12;
}

.wish-node-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.wish-node-code,
.wish-node-delivery {
  color: #60716d;
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;
  font-size: 0.58rem;
  font-weight: 800;
  text-transform: uppercase;
}

.wish-node-delivery {
  color: #39736b;
}

.wish-node--featured {
  position: fixed;
  z-index: 5;
  top: 53%;
  left: 50%;
  width: min(70vw, 980px) !important;
  height: auto !important;
  min-height: min(330px, 46vh) !important;
  max-height: 58vh;
  padding: 28px 34px 26px !important;
  transform: translate(-50%, -50%);
}

.wish-node--featured::after {
  display: none;
}

.wish-node--featured .wish-node-avatar {
  width: 50px;
  height: 50px;
  font-size: 1rem;
}

.wish-node--featured .wish-node-header {
  grid-template-columns: 50px minmax(0, 1fr) auto;
}

.wish-node--featured .wish-node-text,
.wish-node--featured.wish-node--long .wish-node-text,
.wish-node--featured.wish-node--very-long .wish-node-text {
  font-size: 2rem;
  line-height: 1.2;
}

.wish-network[data-featured="true"] .wish-node:not(.wish-node--featured) {
  opacity: 0.08;
  scale: 0.96;
}

@media (max-width: 1500px) and (min-width: 1101px) {
  .wish-network {
    grid-template-columns: minmax(300px, 360px) minmax(430px, 1fr) minmax(300px, 360px);
    gap: 13px 26px;
  }

  .screen-word-cloud {
    width: min(43vw, 72vh, 650px);
  }

  .screen-core {
    width: 340px;
  }

  .screen-core-logo {
    width: 300px;
  }

  .orbit-node i {
    width: 44px;
    height: 44px;
    font-size: 1rem;
  }

  .wish-node-text,
  .wish-network[data-density="solo"] .wish-node-text,
  .wish-network[data-density="sparse"] .wish-node-text {
    font-size: 0.94rem;
  }

  .wish-node--long .wish-node-text,
  .wish-node--very-long .wish-node-text {
    font-size: 0.76rem;
  }
}

@media (max-width: 1100px) and (min-width: 701px) {
  .wish-network {
    inset: 174px 2.2vw 60px;
    grid-template-columns: minmax(220px, 30vw) minmax(280px, 1fr) minmax(220px, 30vw);
    gap: 12px 18px;
  }

  .chat-stream-label {
    font-size: 0.58rem;
  }

  .screen-word-cloud {
    width: min(39vw, 62vh, 480px);
  }

  .screen-core {
    width: 250px;
  }

  .screen-core-logo {
    width: 220px;
  }

  .orbit-node i {
    width: 34px;
    height: 34px;
    font-size: 0.82rem;
  }

  .orbit-node strong {
    font-size: 0.74rem;
  }

  .wish-node,
  .wish-network[data-density="solo"] .wish-node,
  .wish-network[data-density="sparse"] .wish-node {
    padding: 10px 12px 9px;
  }

  .wish-node-header {
    grid-template-columns: 30px minmax(0, 1fr) auto;
    gap: 7px;
  }

  .wish-node-avatar {
    width: 30px;
    height: 30px;
    font-size: 0.68rem;
  }

  .wish-node-author {
    font-size: 0.74rem;
  }

  .wish-node-text,
  .wish-network[data-density="solo"] .wish-node-text,
  .wish-network[data-density="sparse"] .wish-node-text {
    font-size: 0.78rem;
  }

  .wish-node--long .wish-node-text,
  .wish-node--very-long .wish-node-text {
    font-size: 0.66rem;
  }
}

@media (max-width: 700px) {
  .screen-word-cloud {
    width: min(92vw, 430px);
  }

  .static-orbit::before {
    width: 78%;
    height: 78%;
  }

  .orbit-node {
    display: none;
  }

  .screen-core {
    width: min(78vw, 310px);
  }

  .screen-core-logo {
    width: min(70vw, 270px);
  }

  .wish-network {
    position: relative;
    inset: auto;
    display: grid;
    grid-template-columns: 1fr;
    grid-template-rows: none;
    gap: 16px;
    padding: 0 22px 30px;
  }

  .chat-stream-label {
    display: none;
  }

  .wish-node[data-side="left"],
  .wish-node[data-side="right"] {
    grid-column: 1;
    grid-row: auto;
  }

  .wish-node,
  .wish-network .wish-node,
  .wish-network[data-density="solo"] .wish-node,
  .wish-network[data-density="sparse"] .wish-node {
    height: auto;
    min-height: 142px;
    max-height: none;
  }

  .wish-node::after,
  .wish-node[data-side="right"]::after {
    display: none;
  }
}

/* TV-safe header spacing */
.screen-header {
  align-items: flex-start;
}

.screen-heading {
  display: grid;
  gap: 7px;
  max-width: min(31vw, 330px);
  padding: 10px 12px 11px;
  background: rgb(9 13 15 / 58%);
  border: 1px solid rgb(224 239 234 / 14%);
  border-left: 3px solid rgb(82 216 200 / 82%);
  border-radius: 6px;
  box-shadow: 0 14px 34px rgb(0 0 0 / 18%);
  backdrop-filter: blur(10px);
}

.screen-heading p {
  margin: 0;
  color: #9fb0ac;
  font-size: 0.63rem;
  line-height: 1.1;
}

.screen-heading > strong {
  color: #eef6f3;
  font-size: clamp(0.82rem, 1vw, 1.02rem);
  line-height: 1.24;
  overflow-wrap: anywhere;
}

.chat-stream-label {
  top: -25px;
  opacity: 0.68;
  font-size: 0.64rem;
}

.chat-stream-label--left {
  left: 14px;
}

.chat-stream-label--right {
  right: 14px;
}

.wish-network {
  inset: clamp(194px, 19.5vh, 224px) 2.8vw 64px;
}

@media (max-height: 850px) and (min-width: 701px) {
  .screen-heading {
    gap: 5px;
    max-width: 270px;
    padding: 8px 10px 9px;
  }

  .screen-heading p {
    font-size: 0.56rem;
  }

  .screen-heading > strong {
    font-size: 0.78rem;
    line-height: 1.18;
  }

  .chat-stream-label {
    display: none;
  }

  .wish-network {
    inset: clamp(178px, 23vh, 206px) 2.8vw 58px;
  }
}
