:root {
  color-scheme: dark;
  --void: #000000;
  --void-soft: #030508;
  --text: #e8f2ff;
  --muted: #6b8299;
  --line: rgba(120, 170, 255, 0.14);
  --glow: rgba(90, 155, 255, 0.45);
  --blue-core: #b8d9ff;
  --blue: #3d8eff;
  --blue-deep: #0a2a6e;
  --cyan: #5eb8ff;
  --accent: #7eb8ff;
  --panel: rgba(0, 0, 0, 0.78);
  --panel-strong: rgba(2, 6, 14, 0.94);
  --glass: rgba(8, 14, 28, 0.55);
}

* {
  box-sizing: border-box;
}

html,
body {
  width: 100%;
  min-height: 100%;
  margin: 0;
}

body {
  overflow: hidden;
  background: var(--void);
  color: var(--text);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  -webkit-font-smoothing: antialiased;
}

button,
textarea {
  font: inherit;
}

button {
  color: inherit;
}

.cosmos {
  position: relative;
  width: 100vw;
  height: 100dvh;
  min-height: 560px;
  overflow: hidden;
  background: #000;
}

.cosmos::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 2;
  pointer-events: none;
  background:
    radial-gradient(ellipse 120% 80% at 50% 45%, transparent 0%, rgba(0, 0, 0, 0.35) 55%, rgba(0, 0, 0, 0.88) 100%),
    radial-gradient(circle at 50% 120%, rgba(30, 80, 180, 0.12), transparent 42%);
}

.cosmos::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 3;
  pointer-events: none;
  box-shadow: inset 0 0 120px rgba(0, 0, 0, 0.75);
}

.starfield {
  position: absolute;
  inset: 0;
  z-index: 0;
  overflow: hidden;
}

.starfield-image {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center 40%;
  opacity: 0.92;
  filter: brightness(0.55) saturate(0.75) contrast(1.08);
  transform: scale(1.14);
  animation: star-drift 240s linear infinite;
}

@keyframes star-drift {
  from {
    transform: scale(1.14) translate3d(0, 0, 0);
  }
  to {
    transform: scale(1.14) translate3d(-1.2%, -0.6%, 0);
  }
}

.brand {
  position: fixed;
  z-index: 30;
  top: max(18px, env(safe-area-inset-top));
  left: 50%;
  transform: translateX(-50%);
  border: 1px solid rgba(126, 184, 255, 0.22);
  border-radius: 10px;
  padding: 10px 22px;
  background: rgba(0, 0, 0, 0.42);
  backdrop-filter: blur(16px);
  color: var(--blue-core);
  cursor: pointer;
  font-family: Inter, ui-sans-serif, system-ui, sans-serif;
  font-size: clamp(0.95rem, 2.4vw, 1.35rem);
  font-weight: 600;
  letter-spacing: 0.28em;
  text-indent: 0.28em;
  text-shadow:
    0 0 8px rgba(184, 217, 255, 0.9),
    0 0 22px rgba(61, 142, 255, 0.55),
    0 0 48px rgba(10, 42, 110, 0.8);
  box-shadow:
    0 0 24px rgba(61, 142, 255, 0.12),
    inset 0 0 20px rgba(61, 142, 255, 0.04);
}

.brand:focus-visible,
.icon-button:focus-visible,
.orb:focus-visible,
.cic:focus-visible,
.tray-trigger:focus-visible,
.back-button:focus-visible,
.coders-trigger:focus-visible,
.action-grid button:focus-visible,
.send-button:focus-visible,
.coders-primary:focus-visible,
.coders-ghost:focus-visible,
.coders-open:focus-visible {
  outline: 2px solid var(--cyan);
  outline-offset: 3px;
}

.earth-system {
  position: absolute;
  inset: 0;
  z-index: 1;
  display: grid;
  place-items: center;
}

.earth-wrap {
  position: relative;
  width: min(72vmin, 660px);
  aspect-ratio: 1;
  border-radius: 50%;
  filter: drop-shadow(0 0 60px rgba(61, 142, 255, 0.22));
}

.earth-image,
.terminator {
  position: absolute;
  inset: 9%;
  width: 82%;
  height: 82%;
  border-radius: 50%;
}

.earth-image {
  object-fit: cover;
  filter: saturate(0.95) contrast(1.05) brightness(0.72);
  box-shadow:
    inset -40px -20px 70px rgba(0, 0, 0, 0.75),
    0 0 70px rgba(61, 142, 255, 0.14);
  animation: earth-breathe 12s ease-in-out infinite;
}

.terminator {
  pointer-events: none;
  background:
    radial-gradient(circle at 38% 32%, transparent 0 32%, rgba(0, 0, 0, 0.1) 48%, rgba(0, 0, 0, 0.82) 78%),
    linear-gradient(115deg, transparent 0 45%, rgba(0, 0, 0, 0.78) 77%);
  mix-blend-mode: multiply;
}

.orbit-ring {
  position: absolute;
  left: 50%;
  top: 50%;
  border: 1px solid rgba(126, 184, 255, 0.1);
  border-radius: 50%;
  transform: translate(-50%, -50%) rotateX(63deg) rotateZ(0deg);
  pointer-events: none;
  box-shadow: 0 0 20px rgba(61, 142, 255, 0.06);
}

.ring-inner {
  width: 47%;
  height: 47%;
  animation: orbit-spin 32s linear infinite;
}

.ring-middle {
  width: 68%;
  height: 68%;
  border-color: rgba(94, 184, 255, 0.12);
  animation: orbit-spin 42s linear infinite reverse;
}

.ring-outer {
  width: 88%;
  height: 88%;
  border-color: rgba(126, 184, 255, 0.08);
  animation: orbit-spin 56s linear infinite;
}

.orb-layer {
  position: absolute;
  inset: 0;
  pointer-events: none;
}

.orb {
  position: absolute;
  left: 50%;
  top: 50%;
  width: var(--orb-size, 74px);
  height: var(--orb-size, 74px);
  border: 1px solid color-mix(in srgb, var(--orb-color, var(--accent)) 42%, transparent);
  border-radius: 50%;
  background:
    radial-gradient(circle at 32% 26%, rgba(255, 255, 255, 0.35), transparent 0 14%),
    radial-gradient(circle at 50% 55%, rgba(0, 0, 0, 0.88), rgba(0, 0, 0, 0.55) 55%, rgba(4, 10, 22, 0.92) 100%);
  box-shadow:
    0 0 28px color-mix(in srgb, var(--orb-color, var(--accent)) 35%, transparent),
    inset 0 0 28px rgba(0, 0, 0, 0.65);
  color: #f4f9ff;
  cursor: grab;
  display: grid;
  place-items: center;
  pointer-events: auto;
  transform: translate(-50%, -50%);
  transition: opacity 240ms ease, filter 240ms ease, scale 240ms ease, box-shadow 240ms ease;
  user-select: none;
}

.orb[data-use="hi"] {
  filter: brightness(1.08);
  scale: 1.04;
  box-shadow:
    0 0 36px color-mix(in srgb, var(--orb-color, var(--accent)) 48%, transparent),
    inset 0 0 24px rgba(0, 0, 0, 0.7);
}

.orb[data-use="lo"] {
  opacity: 0.42;
}

.orb.is-dragging {
  cursor: grabbing;
  transition: none;
}

.orb-glyph {
  font-family: "JetBrains Mono", ui-monospace, monospace;
  font-weight: 500;
  font-size: 0.72rem;
  letter-spacing: 0.06em;
  text-shadow: 0 0 14px color-mix(in srgb, var(--orb-color, var(--accent)) 80%, white);
}

.orb-label {
  position: absolute;
  top: calc(100% + 8px);
  left: 50%;
  transform: translateX(-50%);
  max-width: 92px;
  color: rgba(200, 220, 255, 0.72);
  font-size: 0.68rem;
  font-weight: 500;
  line-height: 1.15;
  text-align: center;
  text-shadow: 0 0 16px #000;
  overflow-wrap: anywhere;
}

.orb-dial {
  position: absolute;
  width: 136px;
  height: 136px;
  border: 1px solid rgba(126, 184, 255, 0.14);
  border-radius: 50%;
  pointer-events: none;
  transform: translate(-50%, -50%) scale(0.92);
  opacity: 0;
  transition: opacity 160ms ease, transform 160ms ease;
  box-shadow: 0 0 30px rgba(61, 142, 255, 0.1);
}

.orb-dial.visible {
  opacity: 1;
  transform: translate(-50%, -50%) scale(1);
}

.orb-dial span {
  position: absolute;
  left: 50%;
  top: 50%;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--cyan);
  box-shadow: 0 0 14px var(--cyan);
}

.coders-trigger {
  position: fixed;
  z-index: 28;
  top: max(18px, env(safe-area-inset-top));
  right: max(18px, env(safe-area-inset-right));
  display: inline-flex;
  align-items: center;
  gap: 8px;
  border: 1px solid rgba(126, 184, 255, 0.28);
  border-radius: 999px;
  padding: 10px 16px 10px 12px;
  background: rgba(0, 0, 0, 0.55);
  backdrop-filter: blur(18px);
  color: var(--blue-core);
  cursor: pointer;
  box-shadow:
    0 0 28px rgba(61, 142, 255, 0.16),
    inset 0 0 16px rgba(61, 142, 255, 0.05);
}

.coders-trigger-glyph {
  display: grid;
  place-items: center;
  width: 28px;
  height: 28px;
  border-radius: 50%;
  background: rgba(61, 142, 255, 0.12);
  border: 1px solid rgba(126, 184, 255, 0.35);
  font-size: 0.85rem;
  text-shadow: 0 0 12px rgba(126, 184, 255, 0.8);
}

.coders-trigger-label {
  font-size: 0.78rem;
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}

.back-button {
  position: fixed;
  z-index: 24;
  left: 18px;
  top: max(22px, env(safe-area-inset-top));
  border: 1px solid rgba(126, 184, 255, 0.18);
  border-radius: 10px;
  padding: 9px 12px;
  background: rgba(0, 0, 0, 0.5);
  backdrop-filter: blur(14px);
  color: rgba(200, 220, 255, 0.78);
  cursor: pointer;
  opacity: 0;
  pointer-events: none;
  transform: translateY(-8px);
  transition: opacity 180ms ease, transform 180ms ease;
}

.has-depth .back-button {
  opacity: 1;
  pointer-events: auto;
  transform: translateY(0);
}

.cic {
  position: fixed;
  right: max(18px, env(safe-area-inset-right));
  bottom: max(22px, env(safe-area-inset-bottom));
  z-index: 28;
  width: 84px;
  height: 84px;
  border: 1px solid rgba(94, 184, 255, 0.22);
  border-radius: 50%;
  background: rgba(0, 0, 0, 0.48);
  backdrop-filter: blur(16px);
  box-shadow:
    0 0 40px rgba(61, 142, 255, 0.14),
    inset 0 0 28px rgba(61, 142, 255, 0.05);
  cursor: pointer;
}

.cic::before {
  content: "";
  position: absolute;
  inset: 10px;
  border: 1px solid rgba(126, 184, 255, 0.12);
  border-radius: 50%;
  animation: orbit-spin-flat 14s linear infinite;
}

.cic-core {
  position: absolute;
  inset: 28px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  background: linear-gradient(145deg, #d4e8ff, #7eb8ff);
  color: #02060f;
  font-family: "JetBrains Mono", ui-monospace, monospace;
  font-weight: 500;
  font-size: 0.72rem;
  box-shadow: 0 0 20px rgba(126, 184, 255, 0.45);
}

.cic-node {
  position: absolute;
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: var(--cyan);
  box-shadow: 0 0 12px currentColor;
}

.cic-a { left: 37px; top: 6px; }
.cic-b { right: 10px; bottom: 22px; }
.cic-c { left: 12px; bottom: 22px; opacity: 0.65; }

.tray-trigger {
  position: fixed;
  z-index: 26;
  left: 50%;
  bottom: max(4px, env(safe-area-inset-bottom));
  width: min(160px, 34vw);
  height: 14px;
  border: 0;
  border-radius: 999px 999px 0 0;
  background: linear-gradient(90deg, transparent, rgba(126, 184, 255, 0.28), transparent);
  cursor: pointer;
  transform: translateX(-50%);
  opacity: 0.5;
}

.drawer {
  position: fixed;
  z-index: 40;
  left: 50%;
  bottom: 0;
  width: min(900px, calc(100vw - 16px));
  max-height: min(78dvh, 780px);
  display: grid;
  grid-template-rows: auto auto minmax(0, 1fr);
  border: 1px solid rgba(126, 184, 255, 0.18);
  border-bottom: 0;
  border-radius: 16px 16px 0 0;
  background: var(--panel);
  box-shadow:
    0 -8px 60px rgba(0, 0, 0, 0.65),
    0 0 80px rgba(61, 142, 255, 0.08),
    inset 0 1px 0 rgba(126, 184, 255, 0.08);
  backdrop-filter: blur(28px);
  transform: translate(-50%, calc(100% - 14px));
  transition: transform 240ms ease;
}

.drawer.open {
  transform: translate(-50%, 0);
}

.drawer-handle {
  width: 48px;
  height: 3px;
  margin: 12px auto 6px;
  border-radius: 999px;
  background: rgba(126, 184, 255, 0.28);
  box-shadow: 0 0 10px rgba(61, 142, 255, 0.35);
}

.drawer-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  padding: 8px 20px 16px;
  border-bottom: 1px solid var(--line);
}

.eyebrow {
  margin: 0 0 6px;
  color: var(--muted);
  font-size: 0.68rem;
  font-weight: 600;
  letter-spacing: 0.2em;
  text-transform: uppercase;
}

h1 {
  margin: 0;
  font-size: clamp(1.05rem, 2.6vw, 1.55rem);
  font-weight: 600;
  line-height: 1.15;
  letter-spacing: 0.02em;
  color: #f4f9ff;
}

.icon-button {
  width: 36px;
  height: 36px;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: rgba(255, 255, 255, 0.03);
  color: var(--muted);
  cursor: pointer;
}

.drawer-section {
  display: none;
  min-height: 0;
}

.drawer-section.active {
  display: grid;
}

#panel-chat.active {
  grid-template-rows: auto minmax(0, 1fr) auto;
}

.messages {
  min-height: 0;
  overflow: auto;
  padding: 18px 20px;
  display: flex;
  flex-direction: column;
  gap: 12px;
  scrollbar-color: rgba(126, 184, 255, 0.2) transparent;
}

.message {
  max-width: min(86%, 690px);
  padding: 12px 14px;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.02);
}

.message.user {
  align-self: flex-end;
  border-color: rgba(94, 184, 255, 0.22);
  background: rgba(61, 142, 255, 0.06);
  box-shadow: 0 0 20px rgba(61, 142, 255, 0.06);
}

.message.assistant {
  align-self: flex-start;
  border-color: rgba(126, 184, 255, 0.14);
}

.message-label,
.message-meta {
  color: var(--muted);
  font-size: 0.68rem;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.message-body {
  margin-top: 7px;
  color: var(--text);
  line-height: 1.58;
  white-space: pre-wrap;
  overflow-wrap: anywhere;
}

.message-meta {
  margin-top: 10px;
  color: rgba(126, 184, 255, 0.75);
}

.action-payload {
  margin: 10px 0 0;
  padding: 10px;
  border-radius: 10px;
  background: rgba(0, 0, 0, 0.45);
  overflow: auto;
  color: rgba(184, 217, 255, 0.85);
  font-family: "JetBrains Mono", ui-monospace, monospace;
  font-size: 0.74rem;
}

.composer {
  border-top: 1px solid var(--line);
  background: var(--panel-strong);
}

.mode-strip {
  display: flex;
  gap: 8px;
  padding: 12px 16px 0;
}

.mode-strip label {
  display: inline-flex;
  min-width: 92px;
  height: 34px;
  align-items: center;
  justify-content: center;
  border: 1px solid var(--line);
  border-radius: 999px;
  color: var(--muted);
  background: rgba(255, 255, 255, 0.02);
  cursor: pointer;
  font-size: 0.76rem;
  font-weight: 600;
}

.mode-strip input {
  position: absolute;
  opacity: 0;
  pointer-events: none;
}

.mode-strip label:has(input:checked) {
  color: var(--blue-core);
  border-color: rgba(126, 184, 255, 0.45);
  background: rgba(61, 142, 255, 0.1);
  box-shadow: 0 0 18px rgba(61, 142, 255, 0.12);
}

.input-row {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 10px;
  padding: 12px 16px 16px;
  align-items: end;
}

textarea {
  width: 100%;
  min-height: 46px;
  max-height: 180px;
  resize: none;
  border: 1px solid var(--line);
  border-radius: 12px;
  outline: none;
  padding: 13px 14px;
  color: var(--text);
  background: rgba(0, 0, 0, 0.42);
  line-height: 1.4;
}

textarea:focus {
  border-color: rgba(94, 184, 255, 0.45);
  box-shadow: 0 0 0 3px rgba(61, 142, 255, 0.08), 0 0 24px rgba(61, 142, 255, 0.08);
}

.send-button,
.action-grid button {
  border: 1px solid rgba(126, 184, 255, 0.35);
  border-radius: 12px;
  color: var(--blue-core);
  background: rgba(61, 142, 255, 0.12);
  cursor: pointer;
  font-weight: 600;
  box-shadow: 0 0 20px rgba(61, 142, 255, 0.1);
}

.send-button {
  min-width: 88px;
  height: 46px;
}

.send-button:disabled,
textarea:disabled {
  cursor: wait;
  opacity: 0.55;
}

.status-grid,
.action-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
  padding: 18px 20px;
}

.status-grid article {
  min-height: 92px;
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 14px;
  background: rgba(255, 255, 255, 0.02);
}

.status-grid span {
  display: block;
  margin-bottom: 12px;
  color: var(--muted);
  font-size: 0.68rem;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.status-grid strong {
  color: var(--text);
  font-family: "JetBrains Mono", ui-monospace, monospace;
  font-size: 0.82rem;
  overflow-wrap: anywhere;
}

.action-grid button {
  min-height: 52px;
  padding: 12px;
}

.quick-deck {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  padding: 14px 20px 0;
}

.quick-deck button {
  border: 1px solid rgba(126, 184, 255, 0.18);
  border-radius: 999px;
  padding: 8px 12px;
  color: rgba(200, 220, 255, 0.82);
  background: rgba(0, 0, 0, 0.35);
  cursor: pointer;
  font-size: 0.74rem;
  font-weight: 500;
}

.quick-deck button:hover,
.quick-deck button:focus-visible {
  border-color: rgba(126, 184, 255, 0.42);
  background: rgba(61, 142, 255, 0.08);
  box-shadow: 0 0 16px rgba(61, 142, 255, 0.1);
}

.coders-hub {
  min-height: 0;
  overflow: auto;
  padding: 18px 20px 22px;
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.coders-lead {
  margin: 0;
  color: var(--muted);
  font-size: 0.88rem;
  line-height: 1.55;
}

.coders-continuation {
  border: 1px solid rgba(126, 184, 255, 0.2);
  border-radius: 14px;
  padding: 14px 16px;
  background: rgba(0, 0, 0, 0.38);
  box-shadow: inset 0 0 30px rgba(61, 142, 255, 0.04);
}

.coders-continuation-head {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  color: var(--blue-core);
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}

.coders-continuation-meta {
  color: var(--muted);
  letter-spacing: 0.06em;
  text-transform: none;
  font-weight: 500;
}

.coders-continuation-text {
  margin: 10px 0 14px;
  color: rgba(220, 232, 255, 0.86);
  font-size: 0.86rem;
  line-height: 1.5;
}

.coders-continuation-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.coders-primary,
.coders-ghost,
.coders-open {
  border-radius: 10px;
  padding: 10px 14px;
  cursor: pointer;
  font-size: 0.78rem;
  font-weight: 600;
}

.coders-primary {
  border: 1px solid rgba(126, 184, 255, 0.42);
  color: var(--blue-core);
  background: rgba(61, 142, 255, 0.14);
  box-shadow: 0 0 22px rgba(61, 142, 255, 0.12);
}

.coders-ghost {
  border: 1px solid var(--line);
  color: var(--muted);
  background: transparent;
}

.coders-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}

.coders-card {
  border: 1px solid var(--line);
  border-radius: 14px;
  padding: 14px;
  background: rgba(0, 0, 0, 0.35);
  box-shadow: 0 0 24px color-mix(in srgb, var(--lab-accent, var(--accent)) 8%, transparent);
}

.coders-card.is-here {
  border-color: color-mix(in srgb, var(--lab-accent, var(--accent)) 45%, transparent);
  box-shadow: 0 0 28px color-mix(in srgb, var(--lab-accent, var(--accent)) 18%, transparent);
}

.coders-card-top {
  display: flex;
  align-items: center;
  gap: 12px;
}

.coders-card-glyph {
  display: grid;
  place-items: center;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  border: 1px solid color-mix(in srgb, var(--lab-accent, var(--accent)) 40%, transparent);
  background: rgba(0, 0, 0, 0.5);
  color: var(--lab-accent, var(--accent));
  font-family: "JetBrains Mono", ui-monospace, monospace;
  font-size: 0.72rem;
  box-shadow: 0 0 18px color-mix(in srgb, var(--lab-accent, var(--accent)) 25%, transparent);
}

.coders-card h2 {
  margin: 0;
  font-size: 0.95rem;
  font-weight: 600;
}

.coders-here {
  display: block;
  margin-top: 3px;
  color: rgba(126, 184, 255, 0.75);
  font-size: 0.68rem;
  font-weight: 500;
}

.coders-card-path {
  margin: 10px 0 12px;
  color: var(--muted);
  font-family: "JetBrains Mono", ui-monospace, monospace;
  font-size: 0.68rem;
}

.coders-open {
  width: 100%;
  border: 1px solid color-mix(in srgb, var(--lab-accent, var(--accent)) 32%, transparent);
  color: color-mix(in srgb, var(--lab-accent, var(--accent)) 85%, white);
  background: rgba(0, 0, 0, 0.35);
}

.is-thinking .cic-core {
  animation: pulse-core 900ms ease-in-out infinite;
}

.is-thinking .brand {
  box-shadow:
    0 0 32px rgba(61, 142, 255, 0.22),
    inset 0 0 24px rgba(61, 142, 255, 0.08);
}

@keyframes earth-breathe {
  50% { filter: saturate(1) contrast(1.06) brightness(0.78); }
}

@keyframes orbit-spin {
  to { transform: translate(-50%, -50%) rotateX(63deg) rotateZ(360deg); }
}

@keyframes orbit-spin-flat {
  to { transform: rotate(360deg); }
}

@keyframes pulse-core {
  50% { transform: scale(1.06); filter: brightness(1.15); }
}

.focus-mode .earth-system {
  opacity: 0.16;
  filter: blur(1.5px) saturate(0.7);
}

.focus-mode .orb,
.focus-mode .orbit-ring,
.focus-mode .tray-trigger,
.focus-mode .cic,
.focus-mode .coders-trigger {
  opacity: 0.14;
}

.focus-mode .drawer {
  max-height: min(88dvh, 880px);
  background: rgba(0, 0, 0, 0.96);
}

@media (max-width: 760px) {
  .cosmos {
    min-height: 100dvh;
  }

  .earth-wrap {
    width: min(88vmin, 560px);
  }

  .orb {
    width: calc(var(--orb-size, 70px) * 0.84);
    height: calc(var(--orb-size, 70px) * 0.84);
  }

  .orb-label {
    max-width: 68px;
    font-size: 0.64rem;
  }

  .brand {
    padding: 8px 14px;
    letter-spacing: 0.18em;
    text-indent: 0.18em;
    font-size: 0.82rem;
  }

  .coders-trigger {
    padding: 8px 12px 8px 10px;
  }

  .coders-trigger-label {
    display: none;
  }

  .cic {
    width: 76px;
    height: 76px;
  }

  .cic-core {
    inset: 24px;
  }

  .drawer {
    width: 100vw;
    max-height: 82dvh;
    border-radius: 14px 14px 0 0;
  }

  .drawer-head,
  .messages,
  .quick-deck,
  .status-grid,
  .action-grid,
  .coders-hub {
    padding-inline: 14px;
  }

  .status-grid,
  .action-grid,
  .coders-grid {
    grid-template-columns: 1fr;
  }

  .message {
    max-width: 100%;
  }

  .input-row {
    grid-template-columns: 1fr;
  }

  .send-button {
    width: 100%;
  }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    scroll-behavior: auto !important;
    transition-duration: 0.01ms !important;
  }
}