:root {
  --bg: #030403;
  --panel: #0a0b0b;
  --panel-2: #111214;
  --line: #202323;
  --line-bright: rgba(218, 255, 44, 0.5);
  --text: #f4f7ef;
  --muted: #858883;
  --dim: #52564f;
  --acid: #d9ff2f;
  --acid-2: #9eb326;
  --cyan: #30d6e8;
  --purple: #a98cff;
  --amber: #e9bd55;
  --danger: #ff5b72;
  color-scheme: dark;
}

* {
  box-sizing: border-box;
}

html {
  min-width: 320px;
  background: var(--bg);
}

body {
  margin: 0;
  min-height: 100vh;
  background:
    radial-gradient(circle at 20% 5%, rgba(217, 255, 47, 0.09), transparent 16rem),
    linear-gradient(180deg, #020302 0%, #050606 48%, #030403 100%);
  color: var(--text);
  font-family: Inter, "Microsoft YaHei", "PingFang SC", "Noto Sans SC", Arial, sans-serif;
  line-height: 1.5;
}

a {
  color: inherit;
  text-decoration: none;
}

button,
input,
textarea {
  font: inherit;
}

button {
  cursor: pointer;
}

.sr-only {
  position: absolute;
  overflow: hidden;
  width: 1px;
  height: 1px;
  padding: 0;
  border: 0;
  margin: -1px;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 20;
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: center;
  gap: 1.5rem;
  min-height: 60px;
  padding: 0 2.15rem;
  border-bottom: 1px solid rgba(255, 255, 255, 0.05);
  background: rgba(0, 0, 0, 0.9);
  backdrop-filter: blur(14px);
}

.brand {
  color: var(--acid);
  font-size: 1.28rem;
  font-weight: 900;
  letter-spacing: 0;
  text-shadow: 0 0 24px rgba(217, 255, 47, 0.35);
}

.home-page .brand {
  white-space: nowrap;
}

.site-nav {
  display: flex;
  justify-content: center;
  gap: 1.2rem;
  color: var(--muted);
  font-size: 0.86rem;
}

.site-nav a {
  position: relative;
  padding: 0.4rem 0.2rem;
  transition: color 0.18s ease;
}

.site-nav a:hover {
  color: var(--text);
}

.nav-notification-link {
  display: inline-flex;
  align-items: center;
  gap: 0.32rem;
}

.nav-notification-link span {
  display: inline-grid;
  place-items: center;
  min-width: 18px;
  height: 18px;
  border-radius: 999px;
  padding: 0 0.28rem;
  background: var(--acid);
  color: #050604;
  font-size: 0.68rem;
  font-weight: 1000;
}

.mobile-tabbar {
  display: none;
}

.header-action,
.header-ghost,
.primary-link,
.side-prompt button,
.pill-button {
  border: 0;
  border-radius: 999px;
  background: var(--acid);
  color: #070806;
  font-weight: 900;
  letter-spacing: 0;
  box-shadow: 0 0 0 1px rgba(217, 255, 47, 0.25), 0 18px 42px rgba(217, 255, 47, 0.16);
}

.header-action {
  min-width: 9.4rem;
  padding: 0.62rem 1.4rem;
  text-align: center;
  text-transform: uppercase;
}

.header-actions {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 0.55rem;
}

.header-actions form {
  margin: 0;
}

.header-ghost {
  min-height: 38px;
  border: 1px solid #242929;
  padding: 0.55rem 0.9rem;
  background: #101212;
  color: #dfe6da;
  box-shadow: none;
}

.header-user {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  min-height: 38px;
  border: 1px solid #242929;
  border-radius: 999px;
  padding: 0.35rem 0.75rem 0.35rem 0.4rem;
  background: #101212;
  color: #e7eee2;
  font-size: 0.82rem;
  font-weight: 900;
}

.header-user span {
  display: inline-grid;
  place-items: center;
  width: 26px;
  height: 26px;
  border-radius: 50%;
  background: var(--acid);
  color: #050604;
  font-size: 0.72rem;
}

.hero {
  position: relative;
  overflow: hidden;
  min-height: 500px;
  padding: 4.6rem 1.5rem 3.25rem;
  border-bottom: 1px solid rgba(255, 255, 255, 0.04);
}

.hero::before {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  opacity: 0.5;
  background-image:
    linear-gradient(110deg, transparent 0 18%, rgba(217, 255, 47, 0.16) 18.15%, transparent 18.4%),
    linear-gradient(42deg, transparent 0 58%, rgba(48, 214, 232, 0.1) 58.1%, transparent 58.28%),
    linear-gradient(150deg, transparent 0 72%, rgba(169, 140, 255, 0.11) 72.1%, transparent 72.35%);
  background-size: 330px 210px, 420px 260px, 380px 300px;
  mask-image: radial-gradient(circle at 50% 28%, #000 0 40%, transparent 72%);
}

.hero-orbit {
  position: absolute;
  inset: 5% 12% auto;
  height: 360px;
  pointer-events: none;
  opacity: 0.72;
  background:
    repeating-conic-gradient(from 20deg at 50% 50%, transparent 0 18deg, rgba(217, 255, 47, 0.24) 19deg 20deg, transparent 21deg 36deg);
  mask-image: radial-gradient(ellipse at center, transparent 0 31%, #000 32% 34%, transparent 35% 100%);
  transform: rotate(-8deg);
  animation: orbitSpin 24s linear infinite;
}

.hero-inner {
  position: relative;
  z-index: 1;
  max-width: 980px;
  margin: 0 auto;
  text-align: center;
}

.hero h1 {
  margin: 0 auto;
  max-width: 680px;
  color: #fff;
  font-size: clamp(2.5rem, 5vw, 4.7rem);
  line-height: 0.92;
  font-style: italic;
  font-weight: 1000;
  letter-spacing: 0;
  text-transform: uppercase;
}

.hero h1 span,
.hero h1 strong {
  display: block;
}

.hero h1 strong {
  color: var(--acid);
}

.hero p {
  margin: 2rem 0 3.1rem;
  color: #787878;
  font-size: clamp(1.04rem, 2vw, 1.55rem);
  font-weight: 900;
  font-style: italic;
}

.prompt-box {
  width: min(760px, 100%);
  min-height: 120px;
  margin: 0 auto;
  padding: 1rem 1.2rem 0.95rem;
  border: 1px solid var(--line-bright);
  border-radius: 24px;
  background: rgba(22, 22, 22, 0.94);
  box-shadow: 0 28px 72px rgba(0, 0, 0, 0.46);
  transition: border-color 0.18s ease, box-shadow 0.18s ease;
}

.prompt-box:focus-within,
.prompt-box.has-value {
  border-color: rgba(217, 255, 47, 0.9);
  box-shadow: 0 0 0 1px rgba(217, 255, 47, 0.22), 0 28px 72px rgba(0, 0, 0, 0.46);
}

.prompt-row {
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: center;
  gap: 0.85rem;
}

.prompt-icon {
  color: var(--muted);
  font-size: 1.4rem;
}

.prompt-row input {
  width: 100%;
  border: 0;
  outline: 0;
  background: transparent;
  color: var(--text);
  font-size: 1rem;
}

.prompt-row button {
  width: 42px;
  height: 42px;
  border: 0;
  border-radius: 11px;
  background: #727d22;
  color: #080a04;
  font-size: 1.3rem;
  font-weight: 900;
  opacity: 0.68;
  transition: background 0.18s ease, box-shadow 0.18s ease, opacity 0.18s ease, transform 0.18s ease;
}

.prompt-box.has-value .prompt-row button,
.prompt-row input:not(:placeholder-shown) + button {
  background: var(--acid);
  opacity: 1;
  box-shadow: 0 0 0 1px rgba(217, 255, 47, 0.28), 0 12px 28px rgba(217, 255, 47, 0.2);
}

.prompt-box.is-submitting .prompt-row button {
  opacity: 0.86;
  transform: translateY(-1px);
}

.prompt-tools {
  display: flex;
  flex-wrap: wrap;
  gap: 0.6rem;
  margin-top: 0.95rem;
}

.prompt-tools span {
  min-width: 72px;
  padding: 0.48rem 0.8rem;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.035);
  color: var(--muted);
  font-size: 0.78rem;
  font-weight: 800;
}

.hero-capabilities {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 0.7rem;
  margin-top: 1.05rem;
}

.hero-capabilities span {
  min-height: 34px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 999px;
  padding: 0.45rem 0.82rem;
  background: rgba(3, 4, 4, 0.48);
  color: #dce8d4;
  font-size: 0.78rem;
  font-weight: 900;
}

.hero-capabilities span:nth-child(2) {
  color: var(--cyan);
}

.hero-capabilities span:nth-child(3) {
  color: var(--amber);
}

.feed-section {
  padding: 1.9rem 2.1rem 4.2rem;
}

.tabs {
  display: flex;
  gap: 1rem;
  border-bottom: 1px solid var(--line);
}

.tabs button,
.tabs a,
.panel-tabs button {
  border: 0;
  background: transparent;
  color: var(--dim);
  font-size: 0.82rem;
  font-weight: 900;
  letter-spacing: 0;
}

.tabs button,
.tabs a {
  position: relative;
  padding: 0 1.2rem 0.65rem;
}

.tabs button.is-active,
.tabs a.is-active {
  color: var(--acid);
}

.tabs button.is-active::after,
.tabs a.is-active::after,
.panel-tabs button.is-active::after {
  content: "";
  position: absolute;
  right: 0;
  bottom: -1px;
  left: 0;
  height: 2px;
  background: var(--acid);
}

.feed-filter {
  display: grid;
  grid-template-columns: minmax(220px, 1fr) minmax(180px, 260px) auto auto;
  align-items: end;
  gap: 0.7rem;
  margin-top: 0.9rem;
}

.feed-filter label {
  display: grid;
  gap: 0.35rem;
  color: #8e978b;
  font-size: 0.76rem;
  font-weight: 900;
}

.feed-filter input,
.feed-filter select {
  width: 100%;
  min-height: 42px;
  border: 1px solid #242b2b;
  border-radius: 8px;
  outline: 0;
  padding: 0.65rem 0.75rem;
  background: #101313;
  color: var(--text);
}

.feed-filter button,
.feed-filter a,
.feed-pagination a,
.feed-pagination span {
  min-height: 42px;
  border: 1px solid #273030;
  border-radius: 999px;
  padding: 0.62rem 0.9rem;
  background: #111414;
  color: #dbe3d7;
  font-size: 0.78rem;
  font-weight: 900;
  text-decoration: none;
}

.feed-filter button {
  border-color: rgba(217, 255, 47, 0.42);
  background: var(--acid);
  color: #050604;
}

.feed-pagination {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.75rem;
  margin-top: 1.2rem;
}

.feed-pagination strong {
  color: #fff;
  font-size: 0.82rem;
}

.feed-pagination span {
  opacity: 0.45;
}

.feed-empty {
  grid-column: 1 / -1;
  min-height: 220px;
}

.project-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 0.75rem;
  margin-top: 1rem;
}

.project-card {
  overflow: hidden;
  min-width: 0;
  border: 1px solid #222;
  border-radius: 8px;
  background: #111;
  transition: transform 0.18s ease, border-color 0.18s ease;
}

.project-card:hover {
  transform: translateY(-2px);
  border-color: rgba(217, 255, 47, 0.32);
}

.thumb {
  display: block;
  aspect-ratio: 16 / 8.35;
  min-height: 180px;
  background: #070707;
}

.thumb-art {
  position: relative;
  overflow: hidden;
  width: 100%;
  height: 100%;
  background: #080808;
}

.cover-image,
.work-cover-image {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.cover-image {
  position: absolute;
  inset: 0;
  z-index: 1;
}

.view-pill {
  position: absolute;
  right: 0.55rem;
  bottom: 0.5rem;
  z-index: 2;
  padding: 0.13rem 0.45rem;
  border-radius: 999px;
  background: rgba(0, 0, 0, 0.58);
  color: #d7ddd4;
  font-size: 0.72rem;
}

.source-pill {
  position: absolute;
  left: 0.55rem;
  bottom: 0.5rem;
  z-index: 2;
  border-radius: 999px;
  padding: 0.13rem 0.45rem;
  background: rgba(217, 255, 47, 0.12);
  color: var(--acid);
  font-size: 0.72rem;
  font-weight: 900;
}

.card-body {
  padding: 0.7rem 0.75rem 0.82rem;
}

.project-title {
  display: block;
  overflow-wrap: anywhere;
  color: #dfe1dc;
  font-size: 0.9rem;
  font-weight: 900;
}

.project-meta {
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: center;
  gap: 0.45rem;
  margin-top: 0.75rem;
  color: #646864;
  font-size: 0.72rem;
}

.project-meta a {
  overflow: hidden;
  color: #8d9588;
  text-overflow: ellipsis;
  white-space: nowrap;
}

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

.avatar-mini {
  display: inline-grid;
  place-items: center;
  width: 20px;
  height: 20px;
  border-radius: 50%;
  background: #1f1f1f;
  color: #fff;
  font-size: 0.62rem;
}

.thumb-chlorophyll .thumb-art {
  background: #d6d8d6;
}

.chlorophyll-blob {
  position: absolute;
  border-radius: 48% 52% 44% 56%;
  background: #0e5718;
  filter: drop-shadow(0 0 16px rgba(22, 96, 28, 0.3));
}

.chlorophyll-blob.b1 {
  width: 46%;
  height: 72%;
  top: -8%;
  left: 8%;
  transform: rotate(22deg);
}

.chlorophyll-blob.b2 {
  width: 38%;
  height: 65%;
  right: 11%;
  bottom: -12%;
  transform: rotate(-28deg);
}

.chlorophyll-blob.b3 {
  width: 30%;
  height: 38%;
  left: 47%;
  top: 12%;
}

.thumb-sand .thumb-art {
  background:
    linear-gradient(160deg, transparent 0 40%, rgba(38, 135, 255, 0.8) 40.4% 44%, rgba(47, 208, 127, 0.8) 44.2% 49%, rgba(245, 208, 73, 0.9) 49.2% 54%, transparent 54.4%),
    linear-gradient(22deg, #b9aa85 0 48%, #298bf2 48.4% 51%, #4be47a 51.2% 54%, #d2b84c 54.3% 57%, #b9aa85 57.2%);
}

.sand-lines {
  position: absolute;
  inset: 18% 0 0;
  opacity: 0.35;
  background-image: repeating-linear-gradient(8deg, transparent 0 10px, rgba(255, 255, 255, 0.85) 10px 11px);
}

.thumb-tarot .thumb-art {
  display: grid;
  place-items: center;
  background:
    radial-gradient(circle, rgba(115, 53, 176, 0.28), transparent 48%),
    #10061f;
}

.tarot-title {
  color: var(--amber);
  font-family: Georgia, serif;
  font-size: clamp(1rem, 2.6vw, 2rem);
  font-weight: 900;
  letter-spacing: 0.28rem;
}

.tarot-button {
  position: absolute;
  bottom: 34%;
  padding: 0.28rem 1.3rem;
  border: 1px solid var(--amber);
  color: var(--amber);
  font-size: 0.72rem;
}

.thumb-cloud .thumb-art {
  background:
    linear-gradient(180deg, #8eb3c6 0 32%, #a0bd97 50%, #79a96a 100%);
}

.cloud-panel {
  position: absolute;
  top: 28%;
  left: 29%;
  width: 42%;
  padding: 1.4rem 0.8rem;
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.9);
  color: #303336;
  text-align: center;
  font-weight: 900;
}

.pasture {
  position: absolute;
  right: 10%;
  bottom: 28%;
  color: #ff846d;
  font-weight: 900;
}

.thumb-landscape .thumb-art {
  background:
    repeating-linear-gradient(0deg, transparent 0 11px, rgba(98, 206, 234, 0.45) 12px 13px),
    radial-gradient(ellipse at bottom, rgba(40, 179, 202, 0.55), transparent 55%),
    #05090a;
}

.mountain {
  position: absolute;
  bottom: 10%;
  border-radius: 50% 50% 8% 8%;
  background: linear-gradient(180deg, #ffffff 0 18%, #caff9a 20%, #7fcb5d 65%, #18351e 100%);
}

.mountain.m1 {
  left: 18%;
  width: 22%;
  height: 46%;
}

.mountain.m2 {
  left: 40%;
  width: 28%;
  height: 75%;
}

.mountain.m3 {
  right: 17%;
  width: 18%;
  height: 34%;
}

.thumb-hand .thumb-art {
  background:
    radial-gradient(circle at 68% 42%, rgba(255, 73, 92, 0.9) 0 2%, transparent 8%),
    linear-gradient(180deg, #8ba09a, #4e655d);
}

.hand-face {
  position: absolute;
  left: 34%;
  bottom: 0;
  width: 24%;
  height: 78%;
  border-radius: 45% 45% 0 0;
  background: linear-gradient(180deg, #c99167, #ead1bd);
}

.spark {
  position: absolute;
  top: 34%;
  right: 31%;
  width: 70px;
  height: 70px;
  background: repeating-conic-gradient(var(--danger) 0 10deg, transparent 12deg 28deg);
  border-radius: 50%;
  animation: pulse 1.4s ease-in-out infinite;
}

.thumb-magic .thumb-art {
  display: grid;
  place-items: center;
  background:
    radial-gradient(circle at 55% 55%, rgba(180, 130, 255, 0.16), transparent 28%),
    #0b0c16;
}

.magic-ready {
  color: var(--acid);
  font-weight: 900;
}

.thumb-globe .thumb-art {
  display: grid;
  place-items: center;
  background: linear-gradient(90deg, #211d19, #71675f, #1d1917);
}

.globe {
  width: 38%;
  aspect-ratio: 1;
  border-radius: 50%;
  background:
    radial-gradient(circle at 64% 42%, #8cd27e 0 8%, transparent 9%),
    radial-gradient(circle at 34% 58%, #76b974 0 11%, transparent 12%),
    radial-gradient(circle at 42% 35%, #5fa7e8 0 48%, #142d67 80%);
  box-shadow: 0 0 32px rgba(41, 215, 255, 0.7);
}

.site-footer {
  display: flex;
  gap: 1.6rem;
  align-items: center;
  min-height: 42px;
  padding: 0 2rem;
  border-top: 1px solid rgba(255, 255, 255, 0.06);
  color: #454940;
  font-size: 0.68rem;
}

.site-footer a {
  margin-left: auto;
  color: var(--acid-2);
  font-weight: 800;
}

.site-footer a + a {
  margin-left: 0;
}

.workbench-page {
  background: #000;
}

.workbench-page [data-tab-panel="agnes-text"],
.workbench-page [data-tab-panel="agnes-image"],
.workbench-page [data-tab-panel="agnes-video"] {
  display: none !important;
}

.build-page {
  display: grid;
  grid-template-rows: auto minmax(0, 1fr);
  height: 100vh;
  min-height: 100vh;
  overflow: hidden;
}

.build-page .site-header {
  position: relative;
  top: auto;
}

.build-page main {
  min-height: 0;
  overflow: hidden;
}

.build-page .site-footer {
  display: none;
}

.work-page {
  background: #000;
}

.work-page > .site-header,
.work-page > .site-footer {
  display: none;
}

.work-view {
  display: grid;
  grid-template-rows: 62px minmax(0, 1fr) 70px;
  height: 100vh;
  min-height: 100vh;
  background: #000;
  color: var(--text);
  overflow: hidden;
}

.work-topbar {
  display: grid;
  grid-template-columns: auto auto minmax(0, 1fr) auto;
  align-items: center;
  gap: 0.8rem;
  border-bottom: 1px solid #141414;
  padding: 0 2rem;
  background: #020202;
}

.work-back {
  display: inline-grid;
  place-items: center;
  width: 38px;
  height: 38px;
  border: 1px solid #252929;
  border-radius: 50%;
  background: #0a0b0b;
  color: #f3f7ec;
  font-size: 1.4rem;
  font-weight: 900;
}

.work-brand {
  color: var(--acid);
  font-weight: 1000;
  font-size: 1.02rem;
}

.work-topbar strong {
  justify-self: center;
  overflow: hidden;
  max-width: 60vw;
  color: #f8fbf4;
  text-overflow: ellipsis;
  white-space: nowrap;
  font-size: 0.86rem;
  letter-spacing: 0;
}

.work-topbar button {
  border: 0;
  background: transparent;
  color: #f4f7ef;
  font-size: 0.78rem;
  font-weight: 900;
}

.work-toolbar {
  display: flex;
  justify-content: flex-end;
  gap: 0.7rem;
}

.work-stage {
  position: relative;
  min-height: 0;
  padding: 1.35rem 2rem;
  overflow: hidden;
  background: #000;
}

.work-canvas-shell {
  width: 100%;
  height: 100%;
  overflow: hidden;
  border: 1px solid #161919;
  border-radius: 8px;
  background: #070707;
}

.work-canvas-shell iframe,
.work-canvas-shell canvas {
  display: block;
  width: 100%;
  height: 100%;
  border: 0;
  background: #050608;
}

.work-meta {
  display: flex;
  align-items: center;
  gap: 1rem;
  border-top: 1px solid #141414;
  padding: 0 2rem;
  background: #020202;
}

.work-author {
  display: flex;
  align-items: center;
  gap: 0.55rem;
  min-width: 0;
}

.work-author strong {
  color: #f5f8ef;
}

.work-author-link {
  color: #f5f8ef;
  font-weight: 900;
}

.work-author-link:hover {
  color: var(--acid);
}

.work-author span:not(.avatar-mini) {
  color: #9aa197;
  font-size: 0.76rem;
}

.work-meta a,
.work-remix-form button,
.work-remix-login {
  margin-left: auto;
  border: 1px solid #252b2b;
  border-radius: 999px;
  padding: 0.48rem 0.8rem;
  background: #111414;
  color: #dfe5da;
  font-size: 0.76rem;
  font-weight: 900;
}

.work-remix-form {
  margin: 0 0 0 auto;
}

.work-remix-form + a,
.work-remix-login + a {
  margin-left: 0;
}

.work-meta .work-author-link {
  margin-left: 0;
  border: 0;
  padding: 0;
  background: transparent;
  color: #f5f8ef;
  font-size: 0.86rem;
}

.work-meta a + a {
  margin-left: 0;
}

.inspiration-page {
  overflow: hidden;
  background: #000;
}

.inspiration-page > .site-header,
.inspiration-page > .site-footer {
  display: none;
}

.inspiration-shell {
  width: 100%;
  height: 100svh;
  overflow-x: hidden;
  overflow-y: auto;
  background: #000;
  scroll-snap-type: y mandatory;
  overscroll-behavior-y: contain;
}

.inspiration-slide {
  position: relative;
  width: 100%;
  height: 100svh;
  overflow: hidden;
  scroll-snap-align: start;
  scroll-snap-stop: always;
  background: #000;
  isolation: isolate;
}

.inspiration-slide iframe {
  position: absolute;
  inset: 0;
  z-index: 1;
  width: 100%;
  height: 100%;
  border: 0;
  background: #020303;
  pointer-events: none;
  opacity: 0;
  transition: opacity 0.32s ease;
}

.inspiration-slide.is-playing iframe {
  pointer-events: auto;
  opacity: 1;
}

.inspiration-cover {
  position: absolute;
  inset: 0;
  z-index: 1;
  overflow: hidden;
  background: #020303;
  opacity: 1;
  transition: opacity 0.32s ease, transform 0.32s ease;
}

.inspiration-slide.is-playing .inspiration-cover {
  opacity: 0;
  transform: scale(1.018);
  pointer-events: none;
}

.inspiration-cover img,
.inspiration-cover canvas {
  width: 100%;
  height: 100%;
  display: block;
  object-fit: cover;
}

.inspiration-cover-badge {
  position: absolute;
  top: max(1.1rem, env(safe-area-inset-top));
  left: max(1.1rem, env(safe-area-inset-left));
  z-index: 2;
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 999px;
  padding: 0.42rem 0.7rem;
  background: rgba(0, 0, 0, 0.36);
  color: rgba(245, 248, 239, 0.78);
  font-size: 0.72rem;
  font-weight: 900;
  backdrop-filter: blur(12px);
}

.inspiration-shade {
  position: absolute;
  inset: 0;
  z-index: 2;
  background:
    linear-gradient(180deg, rgba(0, 0, 0, 0.24), transparent 28%, rgba(0, 0, 0, 0.78)),
    linear-gradient(90deg, rgba(0, 0, 0, 0.56), transparent 58%);
  pointer-events: none;
}

.inspiration-copy {
  position: absolute;
  bottom: max(1.5rem, env(safe-area-inset-bottom));
  left: max(1.2rem, env(safe-area-inset-left));
  z-index: 4;
  width: min(620px, calc(100vw - 7rem));
  color: #fff;
  text-shadow: 0 2px 18px rgba(0, 0, 0, 0.76);
  pointer-events: auto;
}

.inspiration-author {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  margin-bottom: 0.72rem;
  color: #f4f7ef;
  font-size: 0.86rem;
  font-weight: 900;
}

.inspiration-copy h1 {
  margin: 0;
  color: #fff;
  font-size: clamp(1.55rem, 4.4vw, 4.4rem);
  line-height: 1.04;
  letter-spacing: 0;
}

.inspiration-copy h1 span {
  display: block;
  margin-top: 0.32rem;
  color: var(--acid);
  font-size: clamp(0.94rem, 1.8vw, 1.4rem);
  line-height: 1.25;
}

.inspiration-copy p {
  max-width: 48rem;
  margin: 0.82rem 0 0;
  color: rgba(245, 248, 239, 0.88);
  font-size: clamp(0.94rem, 1.65vw, 1.12rem);
  line-height: 1.58;
}

.inspiration-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 0.45rem;
  margin-top: 0.82rem;
}

.inspiration-tags span {
  border: 1px solid rgba(255, 255, 255, 0.15);
  border-radius: 999px;
  padding: 0.34rem 0.58rem;
  background: rgba(0, 0, 0, 0.32);
  color: #dfe6da;
  font-size: 0.72rem;
  font-weight: 900;
  backdrop-filter: blur(10px);
}

.inspiration-actions {
  position: absolute;
  right: max(1rem, env(safe-area-inset-right));
  bottom: max(2rem, env(safe-area-inset-bottom));
  z-index: 5;
  display: grid;
  gap: 0.72rem;
  justify-items: center;
}

.inspiration-params {
  position: absolute;
  top: max(4.5rem, env(safe-area-inset-top));
  right: max(5.2rem, env(safe-area-inset-right));
  z-index: 5;
  display: grid;
  gap: 0.46rem;
  width: min(260px, 22vw);
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 8px;
  padding: 0.78rem;
  background: rgba(5, 6, 6, 0.48);
  color: #f4f7ef;
  backdrop-filter: blur(16px);
}

.inspiration-params h2 {
  margin: 0 0 0.12rem;
  color: var(--acid);
  font-size: 0.78rem;
  letter-spacing: 0;
}

.inspiration-params div {
  display: grid;
  grid-template-columns: 3.2rem minmax(0, 1fr);
  gap: 0.45rem;
  align-items: center;
  min-width: 0;
}

.inspiration-params span {
  color: rgba(245, 248, 239, 0.56);
  font-size: 0.7rem;
  font-weight: 900;
}

.inspiration-params strong {
  overflow: hidden;
  color: #fff;
  text-overflow: ellipsis;
  white-space: nowrap;
  font-size: 0.74rem;
}

.inspiration-actions form {
  margin: 0;
}

.inspiration-actions button,
.inspiration-actions a {
  display: grid;
  place-items: center;
  grid-template-rows: 1fr auto;
  width: 46px;
  min-height: 46px;
  border: 1px solid rgba(255, 255, 255, 0.15);
  border-radius: 50%;
  background: rgba(5, 6, 6, 0.54);
  color: #fff;
  font-size: 1rem;
  font-weight: 1000;
  box-shadow: 0 12px 36px rgba(0, 0, 0, 0.36);
  backdrop-filter: blur(14px);
}

.inspiration-actions button span,
.inspiration-actions a span {
  color: inherit;
  font-size: 0.56rem;
  line-height: 1;
}

.inspiration-actions button.is-liked,
.inspiration-actions button.is-shared {
  border-color: rgba(217, 255, 47, 0.56);
  color: var(--acid);
}

.inspiration-actions button[aria-pressed="true"],
.inspiration-slide.is-playing [data-inspiration-play] {
  border-color: rgba(217, 255, 47, 0.64);
  background: var(--acid);
  color: #050604;
}

.inspiration-play-hint {
  position: absolute;
  top: max(1rem, env(safe-area-inset-top));
  left: 50%;
  z-index: 5;
  transform: translateX(-50%);
  border: 1px solid rgba(217, 255, 47, 0.22);
  border-radius: 999px;
  padding: 0.42rem 0.74rem;
  background: rgba(0, 0, 0, 0.38);
  color: #e8f2de;
  font-size: 0.72rem;
  font-weight: 900;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.18s ease;
  backdrop-filter: blur(12px);
}

.inspiration-slide.is-current .inspiration-play-hint {
  opacity: 1;
}

.inspiration-slide.is-playing .inspiration-play-hint {
  opacity: 1;
}

.inspiration-enter {
  position: absolute;
  left: max(1.2rem, env(safe-area-inset-left));
  bottom: max(11.2rem, calc(env(safe-area-inset-bottom) + 9rem));
  z-index: 5;
  border: 0;
  border-radius: 999px;
  padding: 0.72rem 1.05rem;
  background: var(--acid);
  color: #050604;
  font-size: 0.82rem;
  font-weight: 1000;
  box-shadow: 0 18px 42px rgba(217, 255, 47, 0.16);
}

.inspiration-empty {
  display: grid;
  place-items: center;
  min-height: 100svh;
  padding: 2rem;
  text-align: center;
}

.discover-hero {
  display: grid;
  grid-template-columns: minmax(260px, 0.8fr) minmax(320px, 1.2fr);
  gap: 1.25rem;
  align-items: end;
  padding: 4.2rem 2.1rem 1.2rem;
  border-bottom: 1px solid var(--line);
  background:
    radial-gradient(circle at 18% 20%, rgba(48, 214, 232, 0.14), transparent 18rem),
    radial-gradient(circle at 82% 0%, rgba(217, 255, 47, 0.12), transparent 18rem),
    #050606;
}

.discover-hero span {
  color: var(--acid);
  font-size: 0.78rem;
  font-weight: 1000;
}

.discover-hero h1 {
  max-width: 720px;
  margin: 0.28rem 0 0;
  color: #fff;
  font-size: clamp(2rem, 5vw, 4.6rem);
  line-height: 0.98;
  letter-spacing: 0;
}

.discover-search {
  margin: 0;
}

.discover-index {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0.8rem;
  padding: 1rem 2.1rem 0;
}

.discover-index > div {
  border: 1px solid #202727;
  border-radius: 8px;
  padding: 1rem;
  background: rgba(9, 11, 11, 0.82);
}

.discover-index h2 {
  margin: 0 0 0.72rem;
  color: #f5f8ef;
  font-size: 0.95rem;
}

.discover-chip-row {
  display: flex;
  flex-wrap: wrap;
  gap: 0.45rem;
}

.discover-chip-row a {
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 999px;
  padding: 0.38rem 0.62rem;
  background: #111414;
  color: #dfe6da;
  font-size: 0.76rem;
  font-weight: 900;
}

.discover-chip-row a:hover {
  border-color: rgba(217, 255, 47, 0.4);
  color: var(--acid);
}

.discover-results {
  padding-top: 1rem;
}

.composer-layout {
  display: grid;
  grid-template-columns: minmax(320px, 35vw) 1fr;
  min-height: calc(100vh - 102px);
  border-bottom: 1px solid var(--line);
}

.composer-side {
  display: flex;
  flex-direction: column;
  gap: 1.2rem;
  padding: 1rem 1.5rem 1.4rem;
  border-right: 1px solid var(--line);
  background: #030303;
}

.create-console {
  grid-template-columns: minmax(360px, 440px) minmax(0, 1fr);
}

.create-control-rail {
  display: grid;
  grid-template-rows: auto minmax(0, 1fr);
  gap: 0.8rem;
  min-height: 0;
  max-height: calc(100vh - 102px);
  overflow: hidden;
}

.control-intro {
  display: grid;
  gap: 0.55rem;
}

.free-usage-note {
  display: inline-block;
  width: fit-content;
  border: 1px solid rgba(217, 255, 47, 0.28);
  border-radius: 999px;
  padding: 0.35rem 0.62rem;
  background: rgba(217, 255, 47, 0.08);
  color: var(--acid);
  font-size: 0.72rem;
  font-weight: 900;
}

.usage-strip {
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem;
  color: #8d968a;
  font-size: 0.68rem;
  font-weight: 850;
}

.usage-strip span {
  display: inline-flex;
  align-items: center;
  gap: 0.18rem;
  border: 1px solid #202525;
  border-radius: 999px;
  padding: 0.28rem 0.48rem;
  background: #080a0a;
}

.usage-strip strong,
.usage-strip em {
  color: #dfe7db;
  font-style: normal;
}

.usage-strip .is-exhausted {
  border-color: rgba(255, 98, 98, 0.34);
  color: #ff8a8a;
}

.run-status {
  display: flex;
  align-items: center;
  gap: 0.45rem;
  color: var(--muted);
  font-size: 0.82rem;
}

.run-status strong {
  color: var(--acid);
}

.status-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: #69f681;
  box-shadow: 0 0 18px #69f681;
}

.composer-side h1 {
  margin: 0;
  font-size: clamp(1.8rem, 3vw, 2.65rem);
  line-height: 1;
}

.composer-side p {
  margin: 0;
  color: #d9ddd6;
  font-size: 0.86rem;
}

.composer-side .muted {
  color: var(--muted);
}

.status-card {
  padding: 1rem;
  border: 1px solid rgba(217, 255, 47, 0.28);
  border-radius: 8px;
  background: rgba(217, 255, 47, 0.035);
}

.status-card span {
  display: block;
  margin-bottom: 0.45rem;
  color: var(--acid);
  font-weight: 900;
}

.status-card p {
  color: #abb0a5;
  font-size: 0.84rem;
}

.side-prompt {
  display: grid;
  gap: 0.8rem;
  margin-top: auto;
}

.side-prompt textarea {
  min-height: 92px;
  resize: vertical;
  border: 1px solid var(--line);
  border-radius: 14px;
  outline: 0;
  padding: 1rem;
  background: #121212;
  color: var(--text);
}

.side-prompt textarea:focus {
  border-color: rgba(217, 255, 47, 0.48);
}

.side-prompt button {
  justify-self: start;
  padding: 0.72rem 1.35rem;
}

.panel-shell {
  position: relative;
  overflow: hidden;
  min-width: 0;
  background: #030303;
}

.output-shell .tab-panel,
.output-shell .agnes-panel {
  height: calc(100vh - 102px);
}

.panel-tabs {
  position: sticky;
  top: 60px;
  z-index: 5;
  display: flex;
  justify-content: center;
  gap: 2.2rem;
  height: 44px;
  overflow-x: auto;
  scrollbar-width: none;
  border-bottom: 1px solid var(--line);
  background: #050505;
}

.side-mode-tabs {
  position: static;
  top: auto;
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  justify-content: stretch;
  gap: 0.35rem;
  height: auto;
  min-height: 42px;
  padding: 0.24rem;
  overflow: visible;
  border: 1px solid #1e2222;
  border-radius: 8px;
  background: #0d0f0f;
}

.side-mode-tabs button {
  min-width: 0;
  border-radius: 6px;
  padding: 0.52rem 0.36rem;
  font-size: 0.72rem;
}

.side-mode-tabs button.is-active {
  background: rgba(217, 255, 47, 0.1);
}

.control-panel {
  display: none;
  min-height: 0;
}

.control-panel.is-active {
  display: grid;
  gap: 1rem;
}

.create-control-rail .control-panel.is-active {
  height: 100%;
  min-height: 0;
  overflow: auto;
}

.create-control-rail .control-panel:not([data-tab-panel="agnes-work"]).is-active {
  align-content: start;
  grid-template-rows: max-content max-content;
}

.create-control-rail [data-tab-panel="agnes-work"].is-active {
  grid-template-rows: minmax(150px, 1fr) auto auto auto auto;
  overflow: auto;
}

.control-panel .agnes-card {
  padding: 1rem;
}

.model-history-dock {
  padding: 0 0.25rem 0.5rem;
  min-height: 150px;
}

.api-control-note {
  display: grid;
  gap: 0.65rem;
  padding: 1rem;
  border: 1px solid #202424;
  border-radius: 8px;
  background: #0c0d0d;
}

.api-control-note h2,
.api-control-note p {
  margin: 0;
}

.api-control-note h2 {
  color: #fff;
  font-size: 1.1rem;
}

.api-control-note p {
  color: #a7ada3;
  font-size: 0.84rem;
}

.panel-tabs::-webkit-scrollbar {
  display: none;
}

.panel-tabs button {
  position: relative;
  flex: 0 0 auto;
  min-width: 72px;
  color: #777a74;
}

.panel-tabs button.is-active {
  color: var(--acid);
}

.plan-document,
.tab-panel {
  padding: 3.2rem 3.8rem;
}

.plan-document {
  max-width: 980px;
}

.plan-document h2,
.plan-document h3 {
  color: #fff;
}

.plan-document p,
.plan-document li {
  color: #d8ddd5;
}

.tab-panel {
  display: none;
  height: calc(100vh - 146px);
  overflow: auto;
}

.tab-panel.is-active {
  display: block;
}

.plan-text,
.code-text {
  margin: 0;
  max-width: 980px;
  white-space: pre-wrap;
  color: #e9eee6;
  font-family: Consolas, "Microsoft YaHei", monospace;
  font-size: 0.94rem;
  line-height: 1.75;
}

.code-text {
  color: #d3e4ff;
}

.preview-panel {
  display: none;
  place-items: center;
  overflow: hidden;
}

.preview-panel.is-active {
  display: grid;
}

.device-frame {
  width: min(476px, 88vw);
  aspect-ratio: 9 / 16;
  overflow: hidden;
  border: 4px solid #2b2d31;
  border-radius: 38px;
  background: #050508;
  box-shadow: 0 0 0 1px #000, 0 28px 100px rgba(0, 0, 0, 0.75);
}

.demo-stage {
  position: relative;
  width: 100%;
  height: 100%;
  overflow: hidden;
  background: #070711;
}

.demo-stage canvas,
.detail-art canvas {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
}

.demo-card {
  position: absolute;
  right: 8%;
  bottom: 5%;
  left: 8%;
  padding: 1.15rem;
  border: 1px solid rgba(255, 255, 255, 0.09);
  border-radius: 18px;
  background: rgba(17, 17, 33, 0.88);
  backdrop-filter: blur(16px);
}

.demo-card h2 {
  margin: 0 0 0.4rem;
  color: #b8a3ff;
  font-size: 1.25rem;
}

.demo-card p {
  margin: 0 0 1rem;
  color: #b7bccd;
  font-size: 0.78rem;
}

.demo-card label {
  display: grid;
  gap: 0.35rem;
  margin: 0.8rem 0;
  color: #b9c1ff;
  font-size: 0.76rem;
  font-weight: 900;
}

.demo-card input[type="range"] {
  width: 100%;
  accent-color: #7d7dff;
}

.timer {
  margin: 0.4rem 0 0.9rem;
  color: #fff;
  font-size: 3.4rem;
  font-weight: 1000;
  line-height: 1;
}

.pill-button {
  padding: 0.72rem 1.25rem;
}

.demo-pomodoro {
  display: grid;
  place-items: center;
  background: #e8f8ef;
}

.demo-pomodoro .demo-card {
  top: auto;
  bottom: 7%;
  background: rgba(255, 255, 255, 0.86);
  color: #16381d;
  text-align: center;
}

.demo-pomodoro .demo-card h2 {
  color: #09622b;
}

.demo-pomodoro .demo-card p {
  color: #73816f;
}

.demo-pomodoro::before {
  content: "";
  position: absolute;
  top: 25%;
  left: calc(50% - 44px);
  width: 88px;
  height: 112px;
  border: 5px solid #30334b;
  border-radius: 50%;
  background:
    radial-gradient(circle at 37% 30%, #30334b 0 6px, transparent 7px),
    radial-gradient(circle at 58% 30%, #30334b 0 6px, transparent 7px),
    radial-gradient(ellipse at 50% 58%, transparent 0 18px, #30334b 19px 21px, transparent 22px);
}

.demo-tarot {
  background:
    radial-gradient(circle at center, rgba(121, 43, 177, 0.35), transparent 60%),
    #10051f;
}

.demo-tarot::before {
  content: "MYSTIC";
  position: absolute;
  top: 24%;
  left: 0;
  width: 100%;
  color: var(--amber);
  text-align: center;
  font-family: Georgia, serif;
  font-size: 2rem;
  font-weight: 900;
  letter-spacing: 0.28rem;
}

.demo-cloud {
  background:
    radial-gradient(circle at 32% 25%, rgba(255, 255, 255, 0.8) 0 8%, transparent 9%),
    radial-gradient(circle at 54% 30%, rgba(255, 255, 255, 0.82) 0 10%, transparent 11%),
    linear-gradient(180deg, #9ac8dc 0 42%, #83b66f 43% 100%);
}

.demo-landscape {
  background:
    repeating-linear-gradient(0deg, transparent 0 14px, rgba(60, 214, 232, 0.32) 15px 16px),
    radial-gradient(ellipse at bottom, rgba(97, 244, 135, 0.42), transparent 60%),
    #050808;
}

.project-detail {
  display: grid;
  grid-template-columns: minmax(320px, 1fr) minmax(280px, 420px);
  gap: 2rem;
  min-height: calc(100vh - 102px);
  padding: 3rem 2rem;
}

.detail-preview {
  overflow: hidden;
  min-height: 520px;
  border: 1px solid #242424;
  border-radius: 10px;
  background: #080808;
}

.detail-art {
  min-height: 100%;
}

.detail-info {
  align-self: center;
}

.category {
  color: var(--acid);
  font-size: 0.78rem;
  font-weight: 900;
}

.detail-info h1 {
  margin: 0.5rem 0 1rem;
  font-size: clamp(2.2rem, 4vw, 4rem);
  line-height: 1;
}

.detail-info p {
  color: #c8cec3;
}

.detail-stats {
  display: flex;
  flex-wrap: wrap;
  gap: 0.6rem;
  margin: 1.4rem 0 1.8rem;
}

.detail-stats span {
  padding: 0.42rem 0.75rem;
  border: 1px solid #242424;
  border-radius: 999px;
  color: var(--muted);
  font-size: 0.78rem;
}

.primary-link {
  display: inline-block;
  padding: 0.72rem 1.35rem;
}

.error-page {
  display: grid;
  place-items: center;
  align-content: center;
  min-height: calc(100vh - 162px);
  padding: 3rem 1rem;
  text-align: center;
}

.error-page span {
  color: var(--acid);
  font-size: 0.84rem;
  font-weight: 1000;
}

.error-page h1 {
  margin: 0.45rem 0 0;
  color: #fff;
  font-size: clamp(2rem, 6vw, 4rem);
  line-height: 1;
}

.error-page p {
  max-width: 520px;
  margin: 1rem auto 1.4rem;
  color: #8d9588;
}

.error-actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 0.7rem;
}

.error-actions a {
  border: 1px solid #252b2b;
  border-radius: 999px;
  padding: 0.64rem 1rem;
  background: #111414;
  color: #dfe5da;
  font-weight: 900;
}

.error-actions a:first-child {
  border-color: rgba(217, 255, 47, 0.42);
  color: var(--acid);
}

.profile-hero {
  display: grid;
  justify-items: center;
  gap: 0.6rem;
  padding: 3rem 1rem 2.6rem;
  text-align: center;
}

.avatar-large {
  display: grid;
  place-items: center;
  width: 128px;
  height: 128px;
  border: 1px solid #292929;
  border-radius: 50%;
  background: #1b1b1b;
  color: #777;
  font-size: 2.6rem;
  font-weight: 900;
}

.profile-hero h1 {
  margin: 0.3rem 0 0;
  font-size: 1.8rem;
}

.profile-hero p {
  margin: 0;
  color: var(--muted);
}

.follow-row,
.profile-actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 0.6rem;
}

.follow-row span,
.profile-actions button,
.profile-actions form,
.profile-link-button {
  margin: 0;
}

.profile-actions button,
.profile-link-button {
  padding: 0.45rem 0.95rem;
  border: 1px solid #242424;
  border-radius: 999px;
  background: #151515;
  color: #90958d;
  font-size: 0.78rem;
}

.follow-row strong {
  color: #fff;
}

.profile-actions button {
  color: #fff;
}

.profile-link-button {
  color: #fff;
  font-weight: 900;
}

.profile-feed {
  padding-top: 0;
}

.profile-notice,
.profile-security-alert {
  margin-bottom: 1rem;
  border-radius: 8px;
  padding: 0.85rem 0.95rem;
}

.profile-notice {
  border: 1px solid rgba(217, 255, 47, 0.34);
  background: rgba(217, 255, 47, 0.08);
  color: var(--acid);
  font-size: 0.86rem;
  font-weight: 900;
}

.profile-security-alert {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
  gap: 0.8rem;
  border: 1px solid rgba(255, 198, 87, 0.32);
  background: rgba(255, 198, 87, 0.08);
}

.profile-security-alert strong {
  display: block;
  color: #ffd878;
  font-size: 0.9rem;
}

.profile-security-alert p,
.profile-security-alert span {
  margin: 0.2rem 0 0;
  color: #c3b99b;
  font-size: 0.78rem;
}

.profile-security-alert button {
  min-height: 36px;
  border: 1px solid rgba(255, 216, 120, 0.36);
  border-radius: 999px;
  padding: 0 0.9rem;
  background: rgba(255, 216, 120, 0.1);
  color: #ffd878;
  font-weight: 900;
}

.profile-edit-panel {
  margin-bottom: 1rem;
  border: 1px solid #222828;
  border-radius: 8px;
  background: #0d0f0f;
}

.profile-edit-panel summary {
  padding: 0.85rem 0.95rem;
  color: var(--acid);
  font-size: 0.86rem;
  font-weight: 900;
  cursor: pointer;
}

.profile-edit-form {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 0.8rem;
  padding: 0 0.95rem 0.95rem;
}

.profile-edit-form label {
  display: grid;
  gap: 0.38rem;
  color: #dfe5da;
  font-size: 0.78rem;
  font-weight: 900;
}

.profile-edit-form input,
.profile-edit-form textarea {
  width: 100%;
  border: 1px solid #242b2b;
  border-radius: 8px;
  outline: 0;
  padding: 0.66rem 0.72rem;
  background: #111414;
  color: var(--text);
}

.profile-edit-form textarea {
  grid-column: auto;
  resize: vertical;
}

.profile-edit-form button {
  align-self: end;
  border: 0;
  border-radius: 999px;
  padding: 0.72rem 1rem;
  background: var(--acid);
  color: #050604;
  font-weight: 900;
}

.public-user-hero {
  border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}

.history-section {
  margin-top: 1.1rem;
}

.history-title-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
}

.history-title-row h2 {
  margin: 0;
  font-size: 1rem;
}

.history-title-row span {
  color: var(--muted);
  font-size: 0.78rem;
}

.history-table {
  display: grid;
  gap: 0.6rem;
  margin-top: 0.75rem;
}

.history-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
  gap: 1rem;
  padding: 0.85rem 0.95rem;
  border: 1px solid #222828;
  border-radius: 8px;
  background: #0d0f0f;
}

.history-row strong {
  color: #fff;
  font-size: 0.9rem;
}

.history-row p {
  margin: 0.25rem 0;
  color: #9aa39a;
  font-size: 0.82rem;
  line-height: 1.5;
}

.history-row small,
.history-row span {
  color: #697269;
  font-size: 0.76rem;
}

.history-row a {
  padding: 0.48rem 0.85rem;
  border: 1px solid rgba(217, 255, 47, 0.35);
  border-radius: 999px;
  color: var(--acid);
  font-size: 0.78rem;
  text-decoration: none;
}

.profile-work-row {
  grid-template-columns: minmax(0, 1fr) minmax(240px, auto);
}

.history-actions {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  flex-wrap: wrap;
  gap: 0.45rem;
}

.history-actions form {
  margin: 0;
}

.history-actions button {
  padding: 0.48rem 0.85rem;
  border: 1px solid rgba(255, 255, 255, 0.14);
  border-radius: 999px;
  background: #151919;
  color: #d5ddd2;
  font-size: 0.78rem;
  cursor: pointer;
}

.history-actions button:hover,
.history-actions a:hover {
  border-color: rgba(217, 255, 47, 0.55);
  color: var(--acid);
}

.project-edit-panel {
  grid-column: 1 / -1;
  border-top: 1px solid rgba(255, 255, 255, 0.06);
  padding-top: 0.55rem;
}

.project-edit-panel summary {
  width: fit-content;
  color: var(--acid);
  font-size: 0.78rem;
  font-weight: 900;
  cursor: pointer;
}

.project-edit-form {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 0.75rem;
  margin-top: 0.75rem;
}

.project-edit-form label {
  display: grid;
  gap: 0.35rem;
  color: #dfe5da;
  font-size: 0.76rem;
  font-weight: 900;
}

.project-edit-form input,
.project-edit-form textarea {
  width: 100%;
  border: 1px solid #242b2b;
  border-radius: 8px;
  outline: 0;
  padding: 0.62rem 0.7rem;
  background: #111414;
  color: var(--text);
}

.project-edit-form input[type="file"] {
  color: #9da79b;
}

.project-description-field,
.project-cover-clear,
.project-edit-actions {
  grid-column: 1 / -1;
}

.project-cover-clear {
  display: flex !important;
  grid-template-columns: none !important;
  align-items: center;
  gap: 0.45rem !important;
  color: #9da79b !important;
  font-weight: 800 !important;
}

.project-cover-clear input {
  width: auto;
}

.project-edit-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.55rem;
}

.project-edit-actions button {
  border-color: rgba(217, 255, 47, 0.35);
  color: var(--acid);
}

.report-admin-note {
  margin-top: 0.45rem;
  border-left: 2px solid rgba(217, 255, 47, 0.38);
  padding: 0.45rem 0.6rem;
  background: rgba(217, 255, 47, 0.055);
  color: #dce7d5;
  font-size: 0.78rem;
  line-height: 1.5;
}

.notifications-page {
  width: min(980px, calc(100% - 2rem));
  margin: 0 auto;
  padding: 3rem 0 4rem;
}

.notifications-head {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 1rem;
  margin-bottom: 1rem;
}

.notifications-head span {
  color: var(--acid);
  font-size: 0.78rem;
  font-weight: 1000;
}

.notifications-head h1 {
  margin: 0.25rem 0 0;
  color: #fff;
  font-size: 1.65rem;
}

.notifications-head button,
.notification-actions button,
.notification-actions a {
  min-height: 36px;
  border: 1px solid #2a3030;
  border-radius: 999px;
  padding: 0 0.9rem;
  background: #101212;
  color: #dfe6da;
  font-size: 0.78rem;
  font-weight: 900;
}

.notifications-head button:hover,
.notification-actions button:hover,
.notification-actions a:hover {
  border-color: rgba(217, 255, 47, 0.38);
  color: var(--acid);
}

.notification-list {
  display: grid;
  gap: 0.7rem;
}

.notification-item {
  border: 1px solid #202727;
  border-radius: 8px;
  padding: 1rem;
  background: #0b0d0d;
}

.notification-item.is-unread {
  border-color: rgba(217, 255, 47, 0.34);
  background: rgba(217, 255, 47, 0.055);
}

.notification-item span {
  color: #8f978b;
  font-size: 0.74rem;
  font-weight: 900;
}

.notification-item h2 {
  margin: 0.3rem 0 0.35rem;
  color: #fff;
  font-size: 1rem;
}

.notification-item p {
  margin: 0;
  color: #aeb7aa;
  font-size: 0.86rem;
  line-height: 1.7;
}

.notification-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin-top: 0.8rem;
}

.notification-actions form,
.notifications-head form {
  margin: 0;
}

@media (max-width: 760px) {
  body {
    padding-bottom: calc(64px + env(safe-area-inset-bottom));
  }

  .site-header {
    min-height: 54px;
  }

  .site-nav {
    display: none;
  }

  .site-footer {
    display: none;
  }

  .mobile-tabbar {
    position: fixed;
    right: 0;
    bottom: 0;
    left: 0;
    z-index: 80;
    display: grid;
    grid-template-columns: repeat(5, minmax(0, 1fr));
    min-height: calc(60px + env(safe-area-inset-bottom));
    padding: 0.38rem 0.42rem max(0.38rem, env(safe-area-inset-bottom));
    border-top: 1px solid rgba(255, 255, 255, 0.08);
    background: rgba(0, 0, 0, 0.86);
    backdrop-filter: blur(18px);
  }

  .mobile-tabbar a {
    display: grid;
    place-items: center;
    gap: 0.1rem;
    color: #8c9489;
    font-size: 0.68rem;
    font-weight: 900;
    line-height: 1.1;
  }

  .mobile-tabbar a span {
    display: grid;
    place-items: center;
    width: 28px;
    height: 26px;
    color: #dfe6da;
    font-size: 1rem;
    line-height: 1;
  }

  .mobile-tabbar a.is-active {
    color: var(--acid);
  }

  .mobile-tabbar a.is-active span {
    color: var(--acid);
  }

  .site-header {
    grid-template-columns: auto auto;
  }

  .inspiration-page {
    padding-bottom: 0;
  }

  .inspiration-page .mobile-tabbar {
    background: linear-gradient(180deg, transparent, rgba(0, 0, 0, 0.9) 28%, rgba(0, 0, 0, 0.96));
  }

  .inspiration-shell {
    height: 100svh;
    padding-bottom: 0;
  }

  .inspiration-slide {
    height: 100svh;
  }

  .inspiration-copy {
    bottom: calc(4.75rem + env(safe-area-inset-bottom));
    width: calc(100vw - 5.9rem);
  }

  .inspiration-cover-badge {
    top: 0.88rem;
    left: 0.88rem;
  }

  .inspiration-copy h1 {
    font-size: clamp(1.38rem, 8vw, 2.45rem);
  }

  .inspiration-copy p {
    display: -webkit-box;
    overflow: hidden;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    font-size: 0.88rem;
  }

  .inspiration-tags {
    gap: 0.34rem;
  }

  .inspiration-tags span {
    padding: 0.26rem 0.44rem;
    font-size: 0.66rem;
  }

  .inspiration-actions {
    right: 0.72rem;
    bottom: calc(4.9rem + env(safe-area-inset-bottom));
    gap: 0.44rem;
  }

  .inspiration-actions button,
  .inspiration-actions a {
    width: 40px;
    min-height: 40px;
    font-size: 0.9rem;
  }

  .inspiration-actions button span,
  .inspiration-actions a span {
    font-size: 0.5rem;
  }

  .inspiration-params {
    top: 0.82rem;
    right: 0.82rem;
    width: min(176px, calc(100vw - 9rem));
    padding: 0.54rem;
    gap: 0.28rem;
  }

  .inspiration-params h2 {
    display: none;
  }

  .inspiration-params div {
    grid-template-columns: 2.5rem minmax(0, 1fr);
    gap: 0.3rem;
  }

  .inspiration-params div:nth-of-type(n + 5) {
    display: none;
  }

  .inspiration-params span,
  .inspiration-params strong {
    font-size: 0.62rem;
  }

  .inspiration-enter {
    left: 1rem;
    bottom: calc(12.1rem + env(safe-area-inset-bottom));
    padding: 0.56rem 0.86rem;
    font-size: 0.74rem;
  }

  .discover-hero {
    grid-template-columns: 1fr;
    gap: 1rem;
    padding: 2.2rem 0.9rem 1rem;
  }

  .discover-hero h1 {
    font-size: clamp(1.85rem, 11vw, 3.1rem);
  }

  .discover-search {
    display: grid;
  }

  .discover-index {
    grid-template-columns: 1fr;
    padding: 0.85rem 0.9rem 0;
  }

  .discover-results {
    padding: 0.9rem 0.9rem 5.3rem;
  }

  body.home-page {
    scroll-snap-type: none;
  }

  .home-page .hero {
    min-height: 78svh;
  }

  .home-page .feed-section {
    width: 100%;
    padding: 1rem 0.85rem 5.4rem;
  }

  .home-page .source-tabs,
  .home-page .feed-section > .tabs:not(.source-tabs) {
    display: none;
  }

  .home-page .feed-filter {
    display: none;
  }

  .home-page .project-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 0.62rem;
    margin: 0;
  }

  .home-page .project-card {
    position: static;
    min-height: 0;
    border: 1px solid #222;
    border-radius: 8px;
    scroll-snap-align: none;
  }

  .home-page .project-card:hover {
    transform: none;
  }

  .home-page .thumb {
    position: relative;
    aspect-ratio: auto;
    min-height: 160px;
  }

  .home-page .thumb-art::after {
    content: "";
    position: absolute;
    inset: 45% 0 0;
    z-index: 2;
    background: linear-gradient(180deg, transparent, rgba(0, 0, 0, 0.78));
    pointer-events: none;
  }

  .home-page .card-body {
    position: static;
    padding: 0.65rem 0.7rem 0.78rem;
    background: transparent;
  }

  .home-page .project-title {
    color: #fff;
    font-size: 1.04rem;
    line-height: 1.35;
  }

  .home-page .project-meta {
    color: #d5dbd1;
  }

  .home-page .view-pill {
    right: 0.55rem;
    bottom: 0.5rem;
    z-index: 5;
  }

  .home-page .source-pill {
    left: 0.55rem;
    bottom: 0.5rem;
    z-index: 5;
  }

  .profile-edit-form {
    grid-template-columns: 1fr;
  }

  .notifications-head {
    align-items: stretch;
    flex-direction: column;
  }

  .profile-security-alert {
    grid-template-columns: 1fr;
    align-items: stretch;
  }

  .project-edit-form {
    grid-template-columns: 1fr;
  }

  .profile-work-row,
  .history-row {
    grid-template-columns: 1fr;
    align-items: stretch;
  }

  .history-actions {
    justify-content: flex-start;
  }

  .history-actions a,
  .history-actions button {
    min-height: 38px;
  }
}

.agnes-panel {
  height: calc(100vh - 146px);
}

.agnes-grid {
  display: grid;
  grid-template-columns: minmax(280px, 420px) minmax(0, 1fr);
  gap: 1rem;
  min-height: 100%;
}

.agnes-card,
.agnes-result {
  min-width: 0;
  border: 1px solid #202424;
  border-radius: 8px;
  background: #0c0d0d;
}

.agnes-card {
  display: grid;
  align-content: start;
  gap: 0.95rem;
  padding: 1rem;
}

.agnes-card-head {
  display: grid;
  gap: 0.25rem;
  padding-bottom: 0.8rem;
  border-bottom: 1px solid #1e2222;
}

.agnes-card-head span,
.result-kicker {
  color: var(--acid);
  font-size: 0.75rem;
  font-weight: 900;
}

.agnes-card-head strong {
  color: #f1f5ed;
  font-size: 1rem;
}

.agnes-card label {
  display: grid;
  gap: 0.45rem;
  color: #d9ddd6;
  font-size: 0.82rem;
  font-weight: 800;
}

.agnes-card select,
.agnes-card input,
.agnes-card textarea {
  width: 100%;
  border: 1px solid #242828;
  border-radius: 8px;
  outline: 0;
  padding: 0.75rem 0.82rem;
  background: #151616;
  color: var(--text);
}

.agnes-card textarea {
  resize: vertical;
}

.agnes-card select:focus,
.agnes-card input:focus,
.agnes-card textarea:focus {
  border-color: rgba(217, 255, 47, 0.48);
}

.agnes-card button,
.task-box button {
  border: 0;
  border-radius: 999px;
  padding: 0.72rem 1.15rem;
  background: var(--acid);
  color: #050604;
  font-weight: 900;
}

.task-box button[data-video-stop] {
  border: 1px solid #2b3030;
  background: #111414;
  color: #dfe5da;
}

.form-row {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0.7rem;
}

.agnes-result {
  overflow: auto;
  padding: 1rem;
}

.agnes-result pre {
  min-height: 320px;
  margin: 0.75rem 0 0;
  white-space: pre-wrap;
  overflow-wrap: anywhere;
  color: #e9eee6;
  font-family: Consolas, "Microsoft YaHei", monospace;
  font-size: 0.9rem;
  line-height: 1.7;
}

.thinking-panel {
  margin: 0.7rem 0;
  overflow: hidden;
  border: 1px solid rgba(217, 255, 47, 0.18);
  border-radius: 8px;
  background: #080a0a;
}

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

.thinking-panel summary {
  cursor: pointer;
  padding: 0.65rem 0.75rem;
  color: var(--acid);
  font-size: 0.78rem;
  font-weight: 900;
  user-select: none;
}

.thinking-panel pre {
  min-height: 0 !important;
  max-height: 220px;
  margin: 0 !important;
  padding: 0.75rem;
  overflow: auto;
  border-top: 1px solid rgba(255, 255, 255, 0.06);
  color: #bfc8bb;
  font-size: 0.78rem;
  line-height: 1.6;
  white-space: pre-wrap;
  overflow-wrap: anywhere;
}

.media-result {
  display: grid;
  align-content: start;
  gap: 0.85rem;
}

.media-placeholder,
.task-box {
  display: grid;
  place-items: center;
  min-height: 360px;
  border: 1px dashed #303434;
  border-radius: 8px;
  color: var(--muted);
  text-align: center;
}

.task-box {
  place-items: start;
  align-content: center;
  gap: 0.85rem;
  padding: 1rem;
}

.task-box code {
  display: block;
  max-width: 100%;
  overflow-wrap: anywhere;
  color: var(--acid);
}

.task-box [data-video-status] {
  margin: 0;
  color: #a7aea2;
  font-size: 0.86rem;
}

.generated-media {
  display: block;
  max-width: 100%;
  max-height: 62vh;
  border: 1px solid #242828;
  border-radius: 8px;
  background: #050505;
  object-fit: contain;
}

.media-link {
  justify-self: start;
  color: var(--acid);
  font-size: 0.84rem;
  font-weight: 900;
}

.model-publish-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin-top: 0.75rem;
}

.model-publish-actions button,
.model-publish-actions a {
  min-height: 36px;
  border: 1px solid #293030;
  border-radius: 999px;
  padding: 0 0.85rem;
  background: #111414;
  color: #dfe5da;
  font-size: 0.78rem;
  font-weight: 900;
}

.model-publish-actions button:not(:disabled):hover,
.model-publish-actions a:hover {
  border-color: rgba(217, 255, 47, 0.38);
  color: var(--acid);
}

.model-publish-actions button:disabled {
  opacity: 0.6;
  cursor: not-allowed;
}

.agnes-result.is-loading {
  border-color: rgba(217, 255, 47, 0.36);
}

.agnes-result.has-error {
  border-color: rgba(255, 91, 114, 0.48);
}

.api-document code {
  color: var(--acid);
}

.workbench-panel {
  padding: 0;
}

.wiwana-workspace {
  display: grid;
  grid-template-columns: minmax(300px, 390px) minmax(0, 1fr);
  min-height: 100%;
}

.workspace-left {
  display: flex;
  flex-direction: column;
  gap: 1rem;
  padding: 1.35rem;
  border-right: 1px solid #151818;
  background: #050606;
}

.workspace-copy {
  display: grid;
  gap: 0.55rem;
}

.workspace-copy h2 {
  margin: 0;
  color: #fff;
  font-size: 1.45rem;
  line-height: 1.16;
}

.workspace-copy p {
  margin: 0;
  color: #9da39a;
  font-size: 0.84rem;
}

.mode-row {
  display: flex;
  gap: 0.55rem;
}

.toggle-pill {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  min-height: 34px;
  padding: 0.35rem 0.75rem;
  border: 1px solid #252a2a;
  border-radius: 999px;
  background: #121414;
  color: #dce2d6;
  font-size: 0.76rem;
  font-weight: 900;
  user-select: none;
}

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

.toggle-pill:has(input:checked) {
  border-color: rgba(217, 255, 47, 0.42);
  background: rgba(217, 255, 47, 0.1);
  color: var(--acid);
}

.workspace-prompt .thinking-toggle,
.agnes-card .thinking-toggle {
  display: inline-flex;
  align-items: center;
  justify-self: start;
  gap: 0.5rem;
  min-height: 34px;
  padding: 0.35rem 0.7rem;
  border: 1px solid #252a2a;
  border-radius: 999px;
  background: #121414;
  color: #dce2d6;
  font-size: 0.76rem;
  font-weight: 900;
  user-select: none;
}

.workspace-prompt .thinking-toggle input,
.agnes-card .thinking-toggle input {
  width: 14px;
  height: 14px;
  accent-color: var(--acid);
}

.workspace-prompt .thinking-toggle:has(input:checked),
.agnes-card .thinking-toggle:has(input:checked) {
  border-color: rgba(217, 255, 47, 0.42);
  background: rgba(217, 255, 47, 0.1);
  color: var(--acid);
}

.workspace-prompt {
  display: grid;
  gap: 0.85rem;
}

.workspace-prompt label {
  display: grid;
  gap: 0.45rem;
  color: #dfe5da;
  font-size: 0.82rem;
  font-weight: 900;
}

.workspace-prompt select,
.workspace-prompt textarea {
  width: 100%;
  border: 1px solid #242828;
  border-radius: 8px;
  outline: 0;
  padding: 0.78rem 0.85rem;
  background: #121414;
  color: var(--text);
}

.workspace-prompt textarea {
  min-height: 174px;
  resize: vertical;
}

.workspace-prompt select:focus,
.workspace-prompt textarea:focus {
  border-color: rgba(217, 255, 47, 0.5);
}

.workspace-prompt button {
  justify-self: start;
  border: 0;
  border-radius: 999px;
  padding: 0.72rem 1.15rem;
  background: var(--acid);
  color: #050604;
  font-weight: 900;
}

.workspace-prompt button:disabled {
  opacity: 0.55;
  cursor: wait;
}

.prompt-action-row {
  display: flex;
  align-items: center;
  gap: 0.55rem;
}

.workspace-prompt .voice-input-button {
  border: 1px solid #252a2a;
  background: #111414;
  color: #dce2d6;
}

.workspace-prompt .voice-input-button.is-active {
  border-color: rgba(217, 255, 47, 0.48);
  background: rgba(217, 255, 47, 0.12);
  color: var(--acid);
}

.resource-dock {
  border: 1px solid #202525;
  border-radius: 8px;
  background: #090b0b;
  overflow: visible;
}

.resource-dock:not(.is-open) {
  min-height: 40px;
}

.resource-summary {
  position: relative;
  display: block;
  width: 100%;
  border: 0;
  min-height: 38px;
  padding: 0.58rem 2rem 0.58rem 0.72rem;
  background: transparent;
  color: var(--acid);
  font-size: 0.78rem;
  font-weight: 900;
  cursor: pointer;
  text-align: left;
}

.resource-summary::after {
  content: "+";
  position: absolute;
  top: 50%;
  right: 0.72rem;
  transform: translateY(-50%);
  color: #6f766d;
  font-size: 1rem;
  line-height: 1;
}

.resource-dock.is-open .resource-summary::after {
  content: "-";
}

.resource-summary small {
  float: right;
  max-width: 62%;
  margin-top: 0.05rem;
  overflow: hidden;
  color: #6f766d;
  font-size: 0.68rem;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.resource-body {
  display: grid;
  gap: 0.55rem;
  padding: 0 0.65rem 0.7rem;
}

.resource-body[hidden] {
  display: none;
}

.asset-upload-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 0.35rem;
}

.asset-upload-button {
  display: grid;
  place-items: center;
  min-height: 34px;
  border: 1px solid #283030;
  border-radius: 8px;
  background: #111414;
  color: #dfe5da;
  font-size: 0.72rem;
  font-weight: 900;
  cursor: pointer;
}

.asset-upload-button:hover {
  border-color: rgba(217, 255, 47, 0.42);
  color: var(--acid);
}

.asset-upload-button input {
  position: absolute;
  width: 1px;
  height: 1px;
  opacity: 0;
  pointer-events: none;
}

.asset-status,
.asset-empty,
.asset-login-note {
  color: #737b72;
  font-size: 0.72rem;
  line-height: 1.45;
}

.asset-status.has-error {
  color: #ff8a9b;
}

.asset-list {
  display: grid;
  gap: 0.35rem;
  max-height: 140px;
  overflow: auto;
}

.asset-chip {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: stretch;
  overflow: hidden;
  border: 1px solid #202525;
  border-radius: 8px;
  background: #0d0f0f;
}

.asset-chip.is-selected {
  border-color: rgba(217, 255, 47, 0.6);
  background: rgba(217, 255, 47, 0.08);
}

.asset-select {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  gap: 0.18rem 0.45rem;
  min-width: 0;
  border: 0;
  padding: 0.5rem 0.58rem;
  background: transparent;
  color: #e7ede2;
  text-align: left;
}

.asset-select span {
  grid-row: 1 / 3;
  align-self: center;
  border: 1px solid rgba(217, 255, 47, 0.28);
  border-radius: 999px;
  padding: 0.14rem 0.38rem;
  color: var(--acid);
  font-size: 0.66rem;
  font-weight: 900;
}

.asset-select strong,
.asset-select small {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.asset-select strong {
  color: #fff;
  font-size: 0.76rem;
}

.asset-select small {
  color: #707871;
  font-size: 0.66rem;
}

.asset-delete {
  width: 34px;
  border: 0;
  border-left: 1px solid #202525;
  background: #111414;
  color: #9aa29a;
  font-size: 1rem;
  line-height: 1;
}

.asset-delete:hover {
  color: #ff8a9b;
}

.asset-login-note {
  display: grid;
  gap: 0.55rem;
}

.asset-login-note button {
  justify-self: start;
  border: 1px solid rgba(217, 255, 47, 0.35);
  border-radius: 999px;
  padding: 0.45rem 0.78rem;
  background: rgba(217, 255, 47, 0.1);
  color: var(--acid);
  font-weight: 900;
}

.version-list {
  display: grid;
  gap: 0.45rem;
  margin-top: auto;
  max-height: 190px;
  overflow: auto;
}

.version-dock {
  display: grid;
  gap: 0.45rem;
  min-height: 0;
}

.version-heading {
  display: flex;
  align-items: center;
  justify-content: space-between;
  color: var(--acid);
  font-size: 0.75rem;
  font-weight: 900;
}

.version-heading small,
.version-empty {
  color: #666d64;
  font-size: 0.72rem;
  font-weight: 800;
}

.version-empty {
  border: 1px dashed #202525;
  border-radius: 8px;
  padding: 0.65rem;
  text-align: center;
}

.history-dock {
  display: grid;
  gap: 0.45rem;
  min-height: 0;
}

.history-list {
  display: grid;
  gap: 0.45rem;
  max-height: 220px;
  overflow: auto;
}

.create-control-rail .history-row,
.version-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: stretch;
  gap: 0.35rem;
  min-width: 0;
}

.history-item {
  display: grid;
  gap: 0.22rem;
  width: 100%;
  padding: 0.65rem 0.72rem;
  border: 1px solid #202525;
  border-radius: 8px;
  background: #0a0c0c;
  color: #eef4ea;
  cursor: pointer;
  font: inherit;
  text-align: left;
  text-decoration: none;
}

.history-item:hover,
.history-item.is-active {
  border-color: rgba(217, 255, 47, 0.42);
}

.history-item strong {
  overflow: hidden;
  color: #fff;
  font-size: 0.82rem;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.history-item span,
.history-item small {
  color: #778077;
  font-size: 0.72rem;
  line-height: 1.45;
}

.history-delete,
.version-delete {
  width: 48px;
  min-height: 100%;
  border: 1px solid #202525;
  border-radius: 8px;
  background: #111414;
  color: #9aa29a;
  font-size: 0.72rem;
  font-weight: 900;
  cursor: pointer;
}

.history-delete:hover,
.version-delete:hover {
  border-color: rgba(255, 111, 134, 0.42);
  color: #ff8a9b;
}

.history-delete:disabled,
.version-delete:disabled {
  cursor: wait;
  opacity: 0.56;
}

@media (max-width: 560px) {
  .create-control-rail .history-row,
  .version-row {
    grid-template-columns: minmax(0, 1fr) 44px;
    gap: 0.3rem;
  }

  .history-delete,
  .version-delete {
    width: 44px;
    padding: 0;
    font-size: 0.68rem;
  }
}

.version-chip {
  display: grid;
  gap: 0.18rem;
  width: 100%;
  min-height: 50px;
  border: 1px solid #202424;
  border-radius: 8px;
  padding: 0.55rem 0.65rem;
  background: #0d0f0f;
  color: #eef4e9;
  text-align: left;
}

.version-chip:hover {
  border-color: rgba(217, 255, 47, 0.34);
  background: rgba(217, 255, 47, 0.06);
}

.version-chip.is-active {
  border-color: rgba(217, 255, 47, 0.74);
  background: rgba(217, 255, 47, 0.12);
}

.version-chip span {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  font-size: 0.82rem;
  font-weight: 900;
}

.version-chip small {
  overflow: hidden;
  color: #747a72;
  font-size: 0.7rem;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.workspace-right {
  display: grid;
  grid-template-rows: auto auto minmax(0, 1fr);
  min-width: 0;
  min-height: 100%;
  background: #030303;
}

.artifact-tabs {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.35rem;
  min-height: 44px;
  border-bottom: 1px solid #151818;
  background: #050505;
}

.artifact-tabs button {
  border: 0;
  border-bottom: 2px solid transparent;
  padding: 0.72rem 1rem 0.62rem;
  background: transparent;
  color: #686d67;
  font-size: 0.76rem;
  font-weight: 900;
}

.artifact-tabs button.is-active {
  border-bottom-color: var(--acid);
  color: var(--acid);
}

.artifact-link {
  margin-left: auto;
  margin-right: 1rem;
  color: var(--acid);
  font-size: 0.76rem;
  font-weight: 900;
}

.artifact-status {
  min-height: 40px;
  padding: 0.7rem 1rem;
  border-bottom: 1px solid #111414;
  color: #8d948a;
  font-size: 0.82rem;
}

.artifact-panel {
  display: none;
  min-height: 0;
  overflow: auto;
  padding: 1rem;
}

.artifact-panel.is-active {
  display: block;
}

.artifact-panel pre,
.artifact-panel textarea[data-work-code] {
  display: block;
  width: 100%;
  min-height: 100%;
  margin: 0;
  border: 0;
  outline: 0;
  resize: none;
  white-space: pre-wrap;
  overflow-wrap: anywhere;
  background: transparent;
  color: #e8eee2;
  font-family: Consolas, "Microsoft YaHei", monospace;
  font-size: 0.9rem;
  line-height: 1.7;
}

.code-artifact pre,
.code-artifact textarea {
  color: #d3e4ff;
}

.code-artifact.is-active,
.preview-artifact.is-active {
  display: grid;
  grid-template-rows: minmax(0, 1fr) auto;
}

.panel-bottom-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.45rem;
  min-height: 52px;
  padding: 0.55rem 0.8rem;
  border-top: 1px solid #151818;
  background: #050505;
  color: #8d948a;
  font-size: 0.78rem;
}

.code-bottom-actions {
  justify-content: flex-start;
}

.preview-bottom-actions {
  justify-content: flex-end;
}

.panel-bottom-actions [data-code-progress] {
  flex: 1 1 180px;
  min-width: 0;
}

.panel-bottom-actions button.is-active,
.panel-bottom-actions button:not(:disabled):hover {
  border-color: rgba(217, 255, 47, 0.42);
  background: rgba(217, 255, 47, 0.1);
  color: var(--acid);
}

.preview-artifact {
  padding: 0;
  overflow: hidden;
}

.preview-artifact.is-active {
  display: grid;
}

.preview-artifact iframe,
.generated-preview-frame {
  display: block;
  width: 100%;
  height: 100%;
  min-height: 0;
  border: 0;
  background: #08090b;
}

.generated-preview-panel {
  padding: 0;
  overflow: hidden;
}

.generated-preview-panel.is-active {
  display: block;
}

.generation-studio {
  display: grid;
  grid-template-columns: minmax(320px, 34vw) minmax(0, 1fr);
  height: 100%;
  min-height: 0;
  overflow: hidden;
  border-bottom: 1px solid var(--line);
  background: #000;
}

.dialog-panel {
  display: grid;
  grid-template-rows: auto minmax(0, 1fr) auto;
  min-width: 0;
  min-height: 0;
  overflow: hidden;
  border-right: 1px solid #171a1a;
  background: #030404;
}

.dialog-heading {
  display: grid;
  gap: 0.8rem;
  padding: 1.05rem 1.25rem 0.9rem;
  border-bottom: 1px solid #131616;
}

.stream-run-status {
  justify-content: space-between;
}

.dialog-heading h1 {
  margin: 0;
  color: #fff;
  font-size: clamp(1.7rem, 3vw, 2.9rem);
  line-height: 1.05;
  overflow-wrap: anywhere;
}

.chat-thread,
.conversation-log {
  display: grid;
  align-content: start;
  gap: 0.75rem;
  min-height: 0;
  overflow: auto;
  padding: 1rem 1.25rem;
}

.conversation-log {
  flex: 1 1 190px;
  max-height: 280px;
  padding: 0.2rem 0;
}

.create-control-rail .conversation-log {
  flex: none;
  max-height: none;
  height: 100%;
  min-height: 0;
  overflow: auto;
  padding: 0;
}

.create-control-rail .conversation-log:empty::before {
  content: "对话会显示在这里";
  display: grid;
  place-items: center;
  height: 100%;
  min-height: 100%;
  border: 1px dashed #202525;
  border-radius: 8px;
  color: #555c55;
  font-size: 0.82rem;
}

.create-control-rail .workspace-prompt {
  gap: 0.65rem;
  padding-top: 0.15rem;
}

.create-control-rail .workspace-prompt label {
  gap: 0.35rem;
}

.create-control-rail .workspace-prompt textarea {
  min-height: 108px;
  max-height: 142px;
  border-radius: 12px;
}

.create-control-rail .workspace-prompt button {
  min-width: 78px;
}

.create-control-rail .version-list {
  max-height: 120px;
  margin-top: 0;
}

.chat-turn {
  min-width: 0;
  border: 1px solid #202525;
  border-radius: 8px;
  padding: 0.8rem;
  background: #0b0d0d;
}

.chat-user {
  border-color: rgba(48, 214, 232, 0.28);
  background: rgba(48, 214, 232, 0.055);
}

.chat-assistant {
  border-color: rgba(217, 255, 47, 0.22);
  background: rgba(217, 255, 47, 0.035);
}

.chat-meta {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.8rem;
  margin-bottom: 0.45rem;
  color: var(--acid);
  font-size: 0.75rem;
  font-weight: 900;
}

.chat-meta small {
  color: #6f766d;
  font-size: 0.7rem;
}

.chat-turn p,
.chat-turn pre {
  margin: 0;
  white-space: pre-wrap;
  overflow-wrap: anywhere;
  color: #dfe5dc;
  font-family: inherit;
  font-size: 0.86rem;
  line-height: 1.65;
}

.dialog-composer {
  display: grid;
  gap: 0.7rem;
  padding: 0.9rem 1.25rem 1rem;
  border-top: 1px solid #131616;
  background: #050606;
}

.dialog-composer textarea {
  width: 100%;
  min-height: 86px;
  max-height: 210px;
  resize: vertical;
  border: 1px solid #252a2a;
  border-radius: 8px;
  outline: 0;
  padding: 0.8rem 0.85rem;
  background: #121414;
  color: var(--text);
}

.dialog-composer textarea:focus {
  border-color: rgba(217, 255, 47, 0.48);
}

.dialog-tools {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.45rem;
}

.ghost-tool,
.send-tool,
.code-actions button,
.code-actions a,
.panel-bottom-actions button {
  min-height: 34px;
  border: 1px solid #252a2a;
  border-radius: 999px;
  padding: 0.42rem 0.75rem;
  background: #111414;
  color: #dce2d6;
  font-size: 0.76rem;
  font-weight: 900;
}

.ghost-tool:disabled,
.code-actions button:disabled,
.panel-bottom-actions button:disabled {
  color: #555d55;
  cursor: not-allowed;
}

.send-tool {
  margin-left: auto;
  border-color: rgba(217, 255, 47, 0.45);
  background: var(--acid);
  color: #050604;
}

.code-stage {
  display: grid;
  grid-template-rows: auto minmax(0, 1fr);
  min-width: 0;
  min-height: 0;
  background: #030303;
}

.code-stage-tabs {
  display: flex;
  justify-content: center;
  gap: 1.4rem;
  min-height: 44px;
  border-bottom: 1px solid #151818;
  background: #050505;
}

.code-stage-tabs button {
  position: relative;
  border: 0;
  background: transparent;
  color: #686d67;
  font-size: 0.78rem;
  font-weight: 900;
}

.code-stage-tabs button.is-active {
  color: var(--acid);
}

.code-stage-tabs button.is-active::after {
  content: "";
  position: absolute;
  right: 0;
  bottom: 0;
  left: 0;
  height: 2px;
  background: var(--acid);
}

.code-stage-body {
  min-width: 0;
  min-height: 0;
  overflow: hidden;
}

.generation-panel {
  display: none;
  width: 100%;
  height: 100%;
  min-height: 0;
  overflow: hidden;
}

.generation-panel.is-active {
  display: block;
}

.generation-panel.is-active[data-generation-panel="code"],
.generation-panel.is-active[data-generation-panel="preview"] {
  display: grid;
  grid-template-rows: minmax(0, 1fr) auto;
}

.preview-artifact.generation-panel.is-active {
  display: grid;
}

.preview-stage {
  position: relative;
  display: grid;
  place-items: center;
  width: 100%;
  height: 100%;
  min-height: 0;
  overflow: auto;
  padding: 1.15rem;
  background:
    radial-gradient(circle at 50% 38%, rgba(217, 255, 47, 0.045), transparent 28rem),
    #020303;
}

.preview-device-shell {
  overflow: hidden;
  background: #08090b;
  box-shadow: 0 20px 80px rgba(0, 0, 0, 0.45);
  transition: width 0.18s ease, height 0.18s ease, border-radius 0.18s ease;
}

.preview-device-shell.is-desktop {
  width: min(100%, 1180px);
  height: min(100%, 760px);
  border: 1px solid #252929;
  border-radius: 8px;
}

.preview-device-shell.is-mobile {
  height: min(100%, 760px);
  max-width: min(420px, 92%);
  aspect-ratio: 9 / 16;
  border: 4px solid #2a2d31;
  border-radius: 34px;
  box-shadow: 0 0 0 1px #050505, 0 24px 86px rgba(0, 0, 0, 0.7);
}

.preview-device-shell iframe {
  display: block;
  width: 100%;
  height: 100%;
  min-height: 0;
  border: 0;
  background: #08090b;
}

.region-select-overlay {
  position: absolute;
  inset: 0;
  z-index: 8;
  pointer-events: none;
}

.region-select-overlay.is-active {
  background: rgba(0, 0, 0, 0.18);
  cursor: crosshair;
  pointer-events: auto;
}

.region-select-overlay.has-selection {
  pointer-events: none;
}

.region-select-box {
  position: absolute;
  min-width: 10px;
  min-height: 10px;
  border: 2px solid var(--acid);
  border-radius: 8px;
  background: rgba(217, 255, 47, 0.12);
  box-shadow: 0 0 0 9999px rgba(0, 0, 0, 0.24), 0 0 24px rgba(217, 255, 47, 0.28);
}

.stream-code-panel {
  height: 100%;
  min-height: 0;
  overflow: auto;
  background:
    linear-gradient(90deg, rgba(217, 255, 47, 0.035), transparent 28%),
    #07080a;
}

.stream-code {
  display: block;
  width: 100%;
  height: 100%;
  min-height: 100%;
  margin: 0;
  padding: 1.15rem 1.25rem 2rem;
  border: 0;
  resize: none;
  white-space: pre-wrap;
  overflow-wrap: anywhere;
  background: transparent;
  color: #d8e7ff;
  font-family: Consolas, "Microsoft YaHei", monospace;
  font-size: 0.88rem;
  line-height: 1.7;
  outline: 0;
  caret-color: var(--acid);
  user-select: text;
}

.stream-code:focus,
[data-work-code]:focus {
  box-shadow: inset 0 0 0 1px rgba(217, 255, 47, 0.42);
  background: rgba(217, 255, 47, 0.025);
}

.stream-code.is-streaming::after,
[data-work-code].is-streaming::after {
  content: "▋";
  display: inline-block;
  margin-left: 0.12rem;
  color: var(--acid);
  animation: cursorBlink 0.85s steps(2, start) infinite;
}

.code-stage-footer {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  align-items: center;
  gap: 0.9rem;
  min-height: 52px;
  padding: 0.55rem 0.8rem;
  border-top: 1px solid #151818;
  color: #8d948a;
  font-size: 0.78rem;
}

.preview-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
  align-items: center;
}

.preview-actions button {
  display: inline-grid;
  place-items: center;
  min-width: 36px;
  min-height: 34px;
  border: 1px solid #252a2a;
  border-radius: 999px;
  background: #111414;
  color: #dce2d6;
  font-size: 0.78rem;
  font-weight: 900;
}

.preview-actions button.is-active,
.preview-actions button:hover {
  border-color: rgba(217, 255, 47, 0.42);
  background: rgba(217, 255, 47, 0.1);
  color: var(--acid);
}

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

.code-actions button:not(:disabled):hover,
.code-actions a:hover,
.ghost-tool:not(:disabled):hover {
  border-color: rgba(217, 255, 47, 0.38);
  color: var(--acid);
}

.qr-modal[hidden] {
  display: none;
}

.publish-modal[hidden] {
  display: none;
}

.report-modal[hidden] {
  display: none;
}

.auth-modal[hidden] {
  display: none;
}

.qr-modal {
  position: fixed;
  inset: 0;
  z-index: 50;
  display: grid;
  place-items: center;
  padding: 1rem;
}

.publish-modal {
  position: fixed;
  inset: 0;
  z-index: 55;
  display: grid;
  place-items: center;
  padding: 1rem;
}

.report-modal {
  position: fixed;
  inset: 0;
  z-index: 60;
  display: grid;
  place-items: center;
  padding: 1rem;
}

.auth-modal {
  position: fixed;
  inset: 0;
  z-index: 70;
  display: grid;
  place-items: center;
  padding: 1rem;
}

.qr-scrim {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.72);
  backdrop-filter: blur(14px);
}

.publish-scrim {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.76);
  backdrop-filter: blur(16px);
}

.report-scrim {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.76);
  backdrop-filter: blur(16px);
}

.auth-scrim {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.78);
  backdrop-filter: blur(16px);
}

.qr-card {
  position: relative;
  z-index: 1;
  display: grid;
  gap: 0.85rem;
  width: min(320px, 100%);
  border: 1px solid #282d2d;
  border-radius: 8px;
  padding: 1rem;
  background: #151616;
  box-shadow: 0 28px 100px rgba(0, 0, 0, 0.65);
}

.publish-card {
  position: relative;
  z-index: 1;
  display: grid;
  gap: 1rem;
  width: min(520px, 100%);
  border: 1px solid #2a2f2f;
  border-radius: 8px;
  padding: 1.15rem;
  background: #171818;
  box-shadow: 0 30px 110px rgba(0, 0, 0, 0.7);
}

.report-card {
  position: relative;
  z-index: 1;
  display: grid;
  gap: 0.85rem;
  width: min(460px, 100%);
  border: 1px solid #2a2f2f;
  border-radius: 8px;
  padding: 1.15rem;
  background: #171818;
  box-shadow: 0 30px 110px rgba(0, 0, 0, 0.7);
}

.auth-card {
  position: relative;
  z-index: 1;
  display: grid;
  gap: 1rem;
  width: min(380px, 100%);
  border: 1px solid #292e2e;
  border-radius: 14px;
  padding: 1.4rem;
  background: #151616;
  box-shadow: 0 30px 110px rgba(0, 0, 0, 0.72);
}

.auth-brand {
  justify-self: center;
  color: var(--acid);
  font-size: 1.45rem;
  font-weight: 1000;
  letter-spacing: 0;
}

.auth-tabs {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 0.35rem;
  padding: 0.25rem;
  border: 1px solid #242929;
  border-radius: 999px;
  background: #0d0f0f;
}

.auth-tabs button {
  border: 0;
  border-radius: 999px;
  padding: 0.52rem 0.8rem;
  background: transparent;
  color: #858b82;
  font-weight: 900;
}

.auth-tabs button.is-active {
  background: rgba(217, 255, 47, 0.12);
  color: var(--acid);
}

.auth-form {
  display: none;
  gap: 0.75rem;
}

.auth-form.is-active {
  display: grid;
}

.auth-form h2 {
  margin: 0;
  color: #fff;
  font-size: 1.16rem;
}

.auth-form p,
.auth-form small {
  margin: 0;
  color: #777f73;
  font-size: 0.78rem;
}

.auth-form small {
  text-align: center;
}

.auth-form a {
  color: var(--acid);
  font-weight: 900;
}

.auth-form label {
  display: grid;
  gap: 0.35rem;
  color: #dfe5da;
  font-size: 0.78rem;
  font-weight: 900;
}

.auth-code-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: end;
  gap: 0.55rem;
}

.auth-code-row button {
  min-height: 44px;
  border: 1px solid rgba(217, 255, 47, 0.36);
  border-radius: 10px;
  padding: 0 0.82rem;
  background: rgba(217, 255, 47, 0.1);
  color: var(--acid);
  font-size: 0.78rem;
  font-weight: 1000;
  white-space: nowrap;
}

.auth-code-row button:disabled {
  opacity: 0.65;
  cursor: wait;
}

.auth-form input {
  width: 100%;
  border: 1px solid #2a3030;
  border-radius: 10px;
  outline: 0;
  padding: 0.82rem 0.9rem;
  background: #090a0a;
  color: var(--text);
}

.auth-form input:focus {
  border-color: rgba(217, 255, 47, 0.52);
}

.auth-form button[type="submit"] {
  border: 0;
  border-radius: 10px;
  padding: 0.82rem 1rem;
  background: var(--acid);
  color: #050604;
  font-weight: 1000;
}

.auth-form button[type="submit"]:disabled {
  opacity: 0.7;
  cursor: wait;
}

.auth-error {
  border: 1px solid rgba(255, 91, 114, 0.42);
  border-radius: 8px;
  padding: 0.65rem 0.75rem;
  background: rgba(255, 91, 114, 0.08);
  color: #ff8a9b;
  font-size: 0.78rem;
}

.auth-error.is-success {
  border-color: rgba(217, 255, 47, 0.34);
  background: rgba(217, 255, 47, 0.08);
  color: var(--acid);
}

.auth-page {
  min-height: 64vh;
  display: grid;
  place-items: center;
  padding: 4rem 1rem;
}

.auth-page-panel {
  display: grid;
  gap: 0.85rem;
  width: min(420px, 100%);
  border: 1px solid #272d2d;
  border-radius: 8px;
  padding: 1.2rem;
  background: #121515;
}

.auth-page-panel > strong {
  color: var(--acid);
  font-size: 1.25rem;
  font-weight: 1000;
}

.auth-page-panel h1 {
  margin: 0;
  color: #fff;
  font-size: 1.35rem;
}

.auth-page-panel p {
  margin: 0;
  color: #899187;
  font-size: 0.88rem;
  line-height: 1.7;
}

.auth-page-error {
  color: #ff8a9b !important;
}

.auth-page-form {
  display: grid;
  gap: 0.75rem;
}

.auth-page-form label {
  display: grid;
  gap: 0.35rem;
  color: #dfe5da;
  font-size: 0.78rem;
  font-weight: 900;
}

.auth-page-form input {
  border: 1px solid #2a3030;
  border-radius: 10px;
  padding: 0.82rem 0.9rem;
  background: #090a0a;
  color: var(--text);
}

.auth-page-panel a,
.auth-page-panel button,
.auth-page-form button {
  justify-self: start;
  border: 0;
  border-radius: 10px;
  padding: 0.78rem 1rem;
  background: var(--acid);
  color: #050604;
  font-weight: 1000;
}

.qr-card h2 {
  margin: 0;
  color: #fff;
  font-size: 1rem;
}

.publish-card h2 {
  margin: 0;
  color: #fff;
  font-size: 1.1rem;
}

.report-card h2 {
  margin: 0;
  color: #fff;
  font-size: 1.1rem;
}

.report-card p,
.report-card small {
  margin: 0;
  color: #899187;
  font-size: 0.78rem;
}

.publish-card form {
  display: grid;
  gap: 0.8rem;
}

.report-card form {
  display: grid;
  gap: 0.78rem;
}

.publish-card label {
  display: grid;
  gap: 0.4rem;
  color: #dfe5da;
  font-size: 0.8rem;
  font-weight: 900;
}

.report-card label {
  display: grid;
  gap: 0.4rem;
  color: #dfe5da;
  font-size: 0.8rem;
  font-weight: 900;
}

.publish-card input,
.publish-card textarea,
.publish-card select {
  width: 100%;
  border: 1px solid #2a3030;
  border-radius: 8px;
  outline: 0;
  padding: 0.72rem 0.8rem;
  background: #0f1111;
  color: var(--text);
}

.report-card textarea,
.report-card select {
  width: 100%;
  border: 1px solid #2a3030;
  border-radius: 8px;
  outline: 0;
  padding: 0.72rem 0.8rem;
  background: #0f1111;
  color: var(--text);
}

.publish-card textarea {
  resize: vertical;
}

.report-card textarea {
  resize: vertical;
}

.publish-card input:focus,
.publish-card textarea:focus,
.publish-card select:focus {
  border-color: rgba(217, 255, 47, 0.52);
}

.report-card textarea:focus,
.report-card select:focus {
  border-color: rgba(217, 255, 47, 0.52);
}

.publish-card button[type="submit"] {
  justify-self: start;
  min-width: 96px;
  border: 0;
  border-radius: 999px;
  padding: 0.68rem 1.2rem;
  background: var(--acid);
  color: #050604;
  font-weight: 900;
}

.report-card button[type="submit"] {
  justify-self: start;
  min-width: 96px;
  border: 0;
  border-radius: 999px;
  padding: 0.68rem 1.2rem;
  background: var(--acid);
  color: #050604;
  font-weight: 900;
}

.publish-card button[type="submit"]:disabled {
  opacity: 0.7;
  cursor: wait;
}

.report-card button[type="submit"]:disabled {
  opacity: 0.7;
  cursor: wait;
}

.cover-tools {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
  gap: 0.65rem;
}

.cover-preview {
  display: flex;
  align-items: center;
  min-height: 64px;
  gap: 0.65rem;
  border: 1px dashed #2a3030;
  border-radius: 8px;
  padding: 0.55rem;
  color: #8f988c;
  font-size: 0.76rem;
}

.cover-preview img {
  width: 96px;
  height: 54px;
  flex: 0 0 auto;
  border-radius: 6px;
  object-fit: cover;
}

.cover-tools button {
  border: 1px solid #2c3434;
  border-radius: 999px;
  padding: 0.55rem 0.8rem;
  background: #151818;
  color: #edf4e9;
  font-weight: 900;
}

.cover-tools button:disabled {
  opacity: 0.6;
  cursor: wait;
}

.publish-preview {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.8rem;
  border: 1px solid #242a2a;
  border-radius: 8px;
  padding: 0.75rem;
  background: #101212;
  color: #91988e;
  font-size: 0.76rem;
}

.publish-preview a {
  flex: 0 0 auto;
  color: var(--acid);
  font-weight: 900;
}

.qr-card img {
  width: min(224px, 100%);
  justify-self: center;
  border-radius: 8px;
  padding: 0.75rem;
  background: #fff;
}

.qr-card p {
  margin: 0;
  color: #8f968b;
  font-size: 0.72rem;
  overflow-wrap: anywhere;
}

.qr-close {
  position: absolute;
  top: 0.7rem;
  right: 0.7rem;
  width: 28px;
  height: 28px;
  border: 0;
  border-radius: 999px;
  background: #202323;
  color: #a8afa4;
  font-size: 1rem;
  line-height: 1;
}

.publish-close,
.report-close {
  position: absolute;
  top: 0.75rem;
  right: 0.75rem;
  width: 30px;
  height: 30px;
  border: 0;
  border-radius: 999px;
  background: #242727;
  color: #aeb5aa;
  font-size: 1rem;
  line-height: 1;
}

.auth-close {
  position: absolute;
  top: 0.8rem;
  right: 0.8rem;
  width: 30px;
  height: 30px;
  border: 0;
  border-radius: 999px;
  background: #242727;
  color: #aeb5aa;
  font-size: 1rem;
  line-height: 1;
}

.published-detail-preview .detail-art {
  background: #050608;
}

.published-detail-preview iframe {
  display: block;
  width: 100%;
  height: 100%;
  min-height: 520px;
  border: 0;
  background: #050608;
}

.published-text-view {
  display: grid;
  align-content: start;
  gap: 0.8rem;
  width: 100%;
  height: 100%;
  min-height: 520px;
  overflow: auto;
  padding: 3rem;
  background: radial-gradient(circle at 10% 10%, rgba(217, 255, 47, 0.08), transparent 18rem), #050606;
}

.published-text-view span {
  color: var(--acid);
  font-size: 0.78rem;
  font-weight: 1000;
}

.published-text-view h1 {
  margin: 0;
  color: #fff;
  font-size: 1.7rem;
}

.published-text-view pre {
  margin: 0;
  color: #dfe8da;
  font-family: inherit;
  font-size: 1rem;
  line-height: 1.9;
  white-space: pre-wrap;
  overflow-wrap: anywhere;
}

.published-media-image,
.published-media-video {
  display: block;
  width: 100%;
  height: 100%;
  min-height: 520px;
  object-fit: contain;
  background: #050505;
}

.detail-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.7rem;
  align-items: center;
}

.secondary-link {
  border: 1px solid #2b3030;
  border-radius: 999px;
  padding: 0.68rem 1.05rem;
  background: #111414;
  color: #dfe5da;
  font-weight: 900;
}

.admin-page,
.admin-login-page {
  min-height: 100vh;
  background: #050606;
}

.admin-page {
  display: grid;
  grid-template-columns: 248px minmax(0, 1fr);
}

.admin-sidebar {
  position: sticky;
  top: 0;
  display: flex;
  flex-direction: column;
  height: 100vh;
  padding: 1.25rem;
  border-right: 1px solid #1b1f1f;
  background: #030404;
}

.admin-brand {
  color: var(--acid);
  font-size: 1.05rem;
  font-weight: 1000;
}

.admin-nav {
  display: grid;
  gap: 0.35rem;
  margin-top: 1.5rem;
}

.admin-nav a,
.admin-sidebar-foot a,
.admin-sidebar-foot button {
  border: 0;
  border-radius: 8px;
  padding: 0.68rem 0.75rem;
  background: transparent;
  color: #92998f;
  text-align: left;
  font-weight: 800;
}

.admin-nav a:hover,
.admin-nav a.is-active {
  background: rgba(217, 255, 47, 0.1);
  color: var(--acid);
}

.admin-sidebar-foot {
  display: grid;
  gap: 0.35rem;
  margin-top: auto;
}

.admin-sidebar-foot button {
  width: 100%;
  cursor: pointer;
}

.admin-main {
  min-width: 0;
  padding: 1.25rem;
}

.admin-topbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  margin-bottom: 1.25rem;
  padding: 1rem 1.1rem;
  border: 1px solid #1c2222;
  border-radius: 8px;
  background: #0b0d0d;
}

.admin-kicker,
.admin-muted {
  color: var(--acid);
  font-size: 0.74rem;
  font-weight: 900;
}

.admin-topbar h1 {
  margin: 0.18rem 0 0;
  color: #fff;
  font-size: 1.55rem;
}

.admin-user {
  border: 1px solid #252b2b;
  border-radius: 999px;
  padding: 0.38rem 0.75rem;
  color: #cfd6ca;
  font-size: 0.82rem;
}

.admin-stat-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
  gap: 0.8rem;
  margin-bottom: 0.9rem;
}

.admin-stat-grid article,
.admin-panel,
.admin-login-card {
  border: 1px solid #1c2222;
  border-radius: 8px;
  background: #0b0d0d;
}

.admin-stat-grid article {
  padding: 1rem;
}

.admin-stat-grid span {
  color: #8f968b;
  font-size: 0.78rem;
  font-weight: 900;
}

.admin-stat-grid strong {
  display: block;
  margin-top: 0.35rem;
  color: #fff;
  font-size: 2rem;
  line-height: 1;
}

.admin-grid-2 {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0.9rem;
  margin-bottom: 0.9rem;
}

.admin-grid-3 {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 0.9rem;
  margin-bottom: 0.9rem;
}

.admin-today-grid article {
  background: linear-gradient(180deg, rgba(217, 255, 47, 0.05), #0b0d0d);
}

.admin-panel {
  overflow: hidden;
}

.monitor-list {
  display: grid;
  gap: 0.45rem;
  padding: 0.85rem 1rem 1rem;
}

.monitor-list div {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
  gap: 0.75rem;
  border-bottom: 1px solid rgba(255, 255, 255, 0.04);
  padding-bottom: 0.42rem;
}

.monitor-list div:last-child {
  border-bottom: 0;
  padding-bottom: 0;
}

.monitor-list span,
.monitor-list p {
  margin: 0;
  color: #929a8f;
  font-size: 0.78rem;
}

.monitor-list strong {
  color: #fff;
  font-size: 0.92rem;
}

.admin-panel-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.8rem;
  min-height: 54px;
  padding: 0.85rem 1rem;
  border-bottom: 1px solid #192020;
}

.admin-panel-head h2 {
  margin: 0;
  color: #fff;
  font-size: 1rem;
}

.admin-panel-head a,
.admin-primary {
  color: var(--acid);
  font-size: 0.82rem;
  font-weight: 900;
}

.admin-filter-tabs {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 0.45rem;
}

.admin-filter-tabs a {
  border: 1px solid #273030;
  border-radius: 999px;
  padding: 0.3rem 0.58rem;
  background: #111414;
  color: #aab2a6;
  font-size: 0.72rem;
}

.admin-filter-tabs a.is-active {
  border-color: rgba(217, 255, 47, 0.42);
  background: rgba(217, 255, 47, 0.1);
  color: var(--acid);
}

.admin-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.84rem;
}

.admin-table th,
.admin-table td {
  padding: 0.78rem 0.85rem;
  border-bottom: 1px solid #161d1d;
  color: #d9dfd3;
  text-align: left;
  vertical-align: top;
}

.admin-table th {
  color: #7e877a;
  font-size: 0.72rem;
  text-transform: uppercase;
}

.admin-truncate {
  max-width: 360px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

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

.admin-actions a,
.admin-actions button {
  border: 1px solid #273030;
  border-radius: 999px;
  padding: 0.32rem 0.62rem;
  background: #111414;
  color: #d9dfd3;
  font-size: 0.74rem;
  font-weight: 900;
}

.admin-actions button {
  color: #ff7b8d;
}

.admin-report-detail {
  max-width: 280px;
  color: #aeb7aa;
  overflow-wrap: anywhere;
}

.admin-report-form {
  display: grid;
  gap: 0.45rem;
  min-width: 240px;
}

.admin-report-form textarea {
  width: 100%;
  border: 1px solid #242b2b;
  border-radius: 8px;
  outline: 0;
  padding: 0.55rem 0.62rem;
  background: #111414;
  color: var(--text);
  font-size: 0.78rem;
  resize: vertical;
}

.status-badge {
  display: inline-flex;
  border: 1px solid rgba(217, 255, 47, 0.32);
  border-radius: 999px;
  padding: 0.18rem 0.5rem;
  color: var(--acid);
  font-size: 0.72rem;
  font-weight: 900;
}

.admin-form-panel {
  padding: 1rem;
}

.admin-form {
  display: grid;
  gap: 0.9rem;
}

.admin-form-grid {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.admin-form label {
  display: grid;
  gap: 0.42rem;
  color: #dfe5da;
  font-size: 0.82rem;
  font-weight: 900;
}

.admin-form input,
.admin-form select,
.admin-form textarea {
  width: 100%;
  border: 1px solid #242b2b;
  border-radius: 8px;
  outline: 0;
  padding: 0.72rem 0.8rem;
  background: #111414;
  color: var(--text);
}

.admin-form textarea {
  resize: vertical;
}

.admin-code-input {
  font-family: Consolas, "Microsoft YaHei", monospace;
  font-size: 0.84rem;
}

.admin-form input:focus,
.admin-form select:focus,
.admin-form textarea:focus {
  border-color: rgba(217, 255, 47, 0.5);
}

.admin-full {
  grid-column: 1 / -1;
}

.admin-check {
  align-content: end;
  grid-template-columns: auto 1fr;
  align-items: center;
}

.admin-check input {
  width: 16px;
  height: 16px;
  accent-color: var(--acid);
}

.admin-form-actions {
  display: flex;
  gap: 0.7rem;
  align-items: center;
}

.admin-form-actions button,
.admin-login-card button {
  border: 0;
  border-radius: 999px;
  padding: 0.72rem 1.15rem;
  background: var(--acid);
  color: #050604;
  font-weight: 900;
}

.admin-form-actions a {
  color: #9ca399;
  font-weight: 900;
}

.admin-inline-form {
  margin: 0;
}

.admin-inline-form button {
  border: 1px solid rgba(217, 255, 47, 0.35);
  border-radius: 999px;
  padding: 0.45rem 0.72rem;
  background: rgba(217, 255, 47, 0.12);
  color: var(--acid);
  font-size: 0.76rem;
  font-weight: 900;
}

.admin-inline-form button:disabled {
  opacity: 0.45;
}

.admin-alert {
  border: 1px solid rgba(255, 91, 114, 0.42);
  border-radius: 8px;
  margin-bottom: 1rem;
  padding: 0.75rem 0.85rem;
  background: rgba(255, 91, 114, 0.08);
  color: #ff91a0;
}

.admin-alert-success {
  border-color: rgba(217, 255, 47, 0.32);
  background: rgba(217, 255, 47, 0.08);
  color: var(--acid);
}

.admin-detail {
  padding: 1rem;
}

.admin-detail .admin-panel-head {
  margin: -1rem -1rem 1rem;
}

.admin-detail h3 {
  margin: 1.2rem 0 0.55rem;
  color: #fff;
}

.admin-detail pre,
.admin-empty pre {
  max-height: 420px;
  overflow: auto;
  border: 1px solid #1b2222;
  border-radius: 8px;
  padding: 0.85rem;
  background: #050606;
  color: #cdd5c7;
  white-space: pre-wrap;
  overflow-wrap: anywhere;
}

.admin-meta-grid {
  display: grid;
  grid-template-columns: 120px minmax(0, 1fr);
  gap: 0.45rem 0.8rem;
  margin: 0;
}

.admin-meta-grid dt {
  color: #81897c;
  font-weight: 900;
}

.admin-meta-grid dd {
  margin: 0;
  color: #e2e8dc;
  overflow-wrap: anywhere;
}

.admin-preline {
  white-space: pre-line;
}

.admin-empty {
  border: 1px solid #252b2b;
  border-radius: 8px;
  padding: 1.2rem;
  background: #0b0d0d;
}

.admin-empty h2 {
  margin: 0 0 0.55rem;
  color: #fff;
}

.admin-empty p {
  color: #a7aea2;
}

.admin-login-page {
  display: grid;
  place-items: center;
  padding: 1rem;
}

.admin-login-card {
  display: grid;
  gap: 0.9rem;
  width: min(420px, 100%);
  padding: 1.3rem;
}

.admin-login-card h1 {
  margin: 0;
  color: #fff;
}

.admin-login-card p {
  margin: 0;
  color: #9ca399;
}

@keyframes orbitSpin {
  to {
    transform: rotate(352deg);
  }
}

@keyframes cursorBlink {
  50% {
    opacity: 0;
  }
}

@keyframes pulse {
  50% {
    transform: scale(1.2) rotate(18deg);
    opacity: 0.6;
  }
}

@media (max-width: 1180px) {
  .project-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .composer-layout {
    grid-template-columns: 360px 1fr;
  }

  .generation-studio {
    grid-template-columns: 360px minmax(0, 1fr);
  }
}

@media (max-width: 860px) {
  .site-header {
    grid-template-columns: auto auto;
    padding: 0 1rem;
  }

  .site-nav {
    order: 3;
    grid-column: 1 / -1;
    justify-content: flex-start;
    padding-bottom: 0.6rem;
  }

  .header-action {
    min-width: auto;
    padding: 0.52rem 0.95rem;
  }

  .hero {
    min-height: 460px;
    padding-top: 3.3rem;
  }

  .project-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .feed-section {
    padding-right: 1rem;
    padding-left: 1rem;
  }

  .composer-layout,
  .project-detail {
    grid-template-columns: 1fr;
  }

  .composer-side {
    min-height: auto;
    max-height: none;
    border-right: 0;
    border-bottom: 1px solid var(--line);
  }

  .side-prompt {
    margin-top: 1rem;
  }

  .panel-tabs {
    position: static;
    top: auto;
    justify-content: flex-start;
    gap: 1.1rem;
    padding: 0 1rem;
  }

  .plan-document,
  .tab-panel {
    padding: 2rem 1.2rem;
  }

  .tab-panel {
    height: auto;
    min-height: 640px;
  }

  .output-shell .tab-panel,
  .output-shell .agnes-panel {
    height: auto;
  }

  .agnes-grid {
    grid-template-columns: 1fr;
  }

  .wiwana-workspace {
    grid-template-columns: 1fr;
  }

  .workspace-left {
    border-right: 0;
    border-bottom: 1px solid #151818;
  }

  .preview-artifact iframe,
  .generated-preview-frame {
    min-height: 640px;
  }

  .admin-page {
    grid-template-columns: 1fr;
  }

  .admin-sidebar {
    position: static;
    height: auto;
  }

  .admin-nav {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .admin-stat-grid,
  .admin-grid-2,
  .admin-grid-3,
  .admin-form-grid {
    grid-template-columns: 1fr;
  }

  .admin-table {
    display: block;
    overflow-x: auto;
  }

  .work-view {
    grid-template-rows: 58px minmax(0, 1fr) auto;
  }

  .work-topbar,
  .work-stage,
  .work-meta {
    padding-right: 1rem;
    padding-left: 1rem;
  }

  .work-topbar {
    grid-template-columns: auto minmax(0, 1fr) auto;
  }

  .work-brand {
    display: none;
  }

  .work-topbar strong {
    justify-self: start;
    max-width: 52vw;
  }

  .work-meta {
    flex-wrap: wrap;
    min-height: 78px;
    padding-top: 0.75rem;
    padding-bottom: 0.75rem;
  }

  .workbench-page {
    overflow-x: hidden;
  }

  .workbench-page .site-header {
    position: sticky;
    grid-template-columns: auto auto;
    gap: 0.65rem;
    min-height: 54px;
    padding: 0.55rem 0.85rem;
  }

  .workbench-page .brand {
    font-size: 1.05rem;
  }

  .workbench-page .site-nav {
    order: 3;
    grid-column: 1 / -1;
    justify-content: space-between;
    gap: 0.35rem;
    padding: 0.15rem 0 0;
    font-size: 0.76rem;
  }

  .workbench-page .header-actions {
    gap: 0.4rem;
  }

  .workbench-page .header-action,
  .workbench-page .header-ghost,
  .workbench-page .header-user {
    min-height: 34px;
    padding: 0.45rem 0.62rem;
    font-size: 0.74rem;
  }

  .workbench-page .header-user {
    max-width: 44vw;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
  }

  .workbench-page .site-footer {
    display: none;
  }

  .create-console {
    grid-template-columns: 1fr;
    min-height: auto;
  }

  .create-control-rail {
    display: grid;
    grid-template-rows: auto auto;
    gap: 0.7rem;
    min-height: auto;
    max-height: none;
    overflow: visible;
    padding: 0.8rem 0.85rem 0.95rem;
    border-right: 0;
    border-bottom: 1px solid #171b1b;
  }

  .create-control-rail .control-intro {
    gap: 0.25rem;
  }

  .create-control-rail .control-intro h1 {
    font-size: 1.45rem;
  }

  .create-control-rail .control-intro p {
    font-size: 0.76rem;
    line-height: 1.45;
  }

  .side-mode-tabs {
    position: sticky;
    top: 93px;
    z-index: 9;
    gap: 0.25rem;
    min-height: 40px;
    padding: 0.2rem;
  }

  .side-mode-tabs button {
    min-height: 34px;
    padding: 0.42rem 0.2rem;
    font-size: 0.7rem;
  }

  .create-control-rail .control-panel.is-active {
    height: auto;
    overflow: visible;
  }

  .create-control-rail [data-tab-panel="agnes-work"].is-active {
    grid-template-rows: auto auto auto auto auto;
    overflow: visible;
  }

  .create-control-rail .conversation-log {
    height: auto;
    max-height: 220px;
    min-height: 120px;
  }

  .create-control-rail .conversation-log:empty::before {
    min-height: 120px;
  }

  .create-control-rail .workspace-prompt textarea {
    min-height: 116px;
    max-height: 170px;
  }

  .create-control-rail .workspace-prompt button,
  .agnes-card button {
    width: 100%;
    min-height: 42px;
  }

  .resource-summary {
    min-height: 36px;
    padding: 0.52rem 1.8rem 0.52rem 0.65rem;
  }

  .asset-upload-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .asset-list {
    max-height: 122px;
  }

  .create-control-rail .version-list,
  .history-list {
    max-height: 172px;
  }

  .output-shell {
    overflow: visible;
  }

  .output-shell .tab-panel,
  .output-shell .agnes-panel {
    height: auto;
    min-height: 64vh;
  }

  .workbench-panel {
    min-height: 68vh;
  }

  .workspace-right {
    min-height: 68vh;
    grid-template-rows: auto auto minmax(420px, 1fr);
  }

  .artifact-tabs {
    position: sticky;
    top: 0;
    z-index: 7;
    justify-content: flex-start;
    overflow-x: auto;
    padding: 0 0.55rem;
  }

  .artifact-tabs button {
    min-width: 68px;
    min-height: 42px;
    padding: 0.66rem 0.7rem 0.55rem;
    font-size: 0.74rem;
  }

  .artifact-link {
    display: none;
  }

  .artifact-status {
    min-height: 36px;
    padding: 0.58rem 0.85rem;
    font-size: 0.76rem;
  }

  .artifact-panel {
    padding: 0.85rem;
  }

  .artifact-panel pre,
  .artifact-panel textarea[data-work-code] {
    min-height: 360px;
    font-size: 0.78rem;
    line-height: 1.6;
  }

  .code-artifact.is-active,
  .preview-artifact.is-active {
    min-height: 560px;
  }

  .panel-bottom-actions {
    position: sticky;
    bottom: 0;
    z-index: 6;
    gap: 0.4rem;
    min-height: 58px;
    padding: 0.55rem 0.65rem max(0.55rem, env(safe-area-inset-bottom));
  }

  .code-bottom-actions,
  .preview-bottom-actions {
    justify-content: stretch;
  }

  .panel-bottom-actions button {
    flex: 1 1 0;
    min-width: 0;
    min-height: 40px;
    padding: 0.5rem 0.55rem;
    font-size: 0.74rem;
  }

  .preview-stage {
    min-height: 500px;
    padding: 0.75rem;
  }

  .preview-device-shell.is-desktop {
    width: 100%;
    height: 500px;
  }

  .preview-device-shell.is-mobile {
    width: min(100%, 360px);
    max-width: 100%;
    height: auto;
    max-height: none;
    border-width: 3px;
    border-radius: 28px;
  }

  .agnes-panel:not(.workbench-panel) {
    padding: 0.85rem;
  }

  .agnes-card {
    gap: 0.75rem;
    padding: 0.85rem;
  }

  .agnes-card textarea {
    min-height: 110px;
  }

  .form-row {
    gap: 0.55rem;
  }

  .agnes-result {
    min-height: 420px;
    padding: 0.85rem;
  }

  .agnes-result pre {
    min-height: 280px;
    font-size: 0.8rem;
    line-height: 1.65;
  }

  .media-placeholder,
  .task-box {
    min-height: 300px;
  }

  .generated-media {
    width: 100%;
    max-height: 58vh;
  }
}

@media (max-width: 560px) {
  .auth-code-row {
    grid-template-columns: 1fr;
  }

  .hero h1 {
    font-size: 2.5rem;
  }

  .prompt-box {
    border-radius: 18px;
  }

  .prompt-row {
    grid-template-columns: auto 1fr;
  }

  .prompt-row button {
    grid-column: 2;
    justify-self: end;
  }

  .feed-filter {
    grid-template-columns: 1fr;
  }

  .project-grid {
    grid-template-columns: 1fr;
  }

  .home-page {
    scroll-snap-type: y proximity;
    background: #000;
  }

  .home-page .site-header {
    min-height: 54px;
    background: rgba(0, 0, 0, 0.78);
  }

  .home-page .brand {
    max-width: 58vw;
    overflow-wrap: anywhere;
    font-size: 0.98rem;
    line-height: 1.1;
  }

  .home-page .site-nav {
    justify-content: space-between;
    gap: 0.25rem;
    font-size: 0.74rem;
  }

  .home-page .header-actions {
    gap: 0.32rem;
  }

  .home-page .header-action,
  .home-page .header-ghost {
    min-height: 32px;
    padding: 0.42rem 0.58rem;
    font-size: 0.72rem;
  }

  .home-page .hero {
    display: flex;
    align-items: center;
    min-height: calc(100svh - 54px);
    padding: 2rem 0.9rem;
    scroll-snap-align: start;
    background:
      radial-gradient(circle at 50% 28%, rgba(217, 255, 47, 0.18), transparent 18rem),
      #020303;
  }

  .home-page .hero p {
    margin: 1.25rem 0 1.45rem;
    font-size: 0.96rem;
    line-height: 1.45;
  }

  .home-page .prompt-tools {
    gap: 0.35rem;
  }

  .home-page .prompt-tools span {
    min-width: auto;
    padding: 0.34rem 0.55rem;
    font-size: 0.68rem;
  }

  .home-page .hero-capabilities {
    gap: 0.4rem;
  }

  .home-page .hero-capabilities span {
    min-height: 30px;
    padding: 0.35rem 0.55rem;
    font-size: 0.68rem;
  }

  .home-page .feed-section {
    padding: 0;
  }

  .home-page .feed-section > .tabs,
  .home-page .feed-filter,
  .home-page .feed-pagination {
    display: none;
  }

  .home-page .project-grid {
    display: block;
    margin: 0;
  }

  .home-page .project-card {
    position: relative;
    min-height: calc(100svh - 128px);
    border: 0;
    border-radius: 0;
    background: #000;
    scroll-snap-align: start;
  }

  .home-page .project-card:hover {
    transform: none;
  }

  .home-page .thumb {
    position: absolute;
    inset: 0;
    height: 100%;
    min-height: 0;
    aspect-ratio: auto;
  }

  .home-page .thumb-art::after {
    content: "";
    position: absolute;
    inset: 45% 0 0;
    z-index: 2;
    pointer-events: none;
    background: linear-gradient(180deg, transparent, rgba(0, 0, 0, 0.82));
  }

  .home-page .card-body {
    position: absolute;
    right: 4rem;
    bottom: max(1.1rem, env(safe-area-inset-bottom));
    left: 0;
    z-index: 3;
    padding: 0 1rem;
    background: transparent;
  }

  .home-page .project-title {
    color: #fff;
    font-size: 1.08rem;
    line-height: 1.28;
    text-shadow: 0 2px 16px rgba(0, 0, 0, 0.7);
  }

  .home-page .project-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 0.42rem;
    color: #d4dbd0;
    text-shadow: 0 2px 14px rgba(0, 0, 0, 0.72);
  }

  .home-page .project-meta a {
    color: #f2f7ef;
  }

  .home-page .view-pill,
  .home-page .source-pill {
    bottom: auto;
    top: 1rem;
  }

  .home-page .source-pill {
    left: 1rem;
  }

  .home-page .view-pill {
    right: 1rem;
  }

  .thumb {
    min-height: 210px;
  }

  .site-footer {
    flex-wrap: wrap;
    padding: 0.8rem 1rem;
  }

  .dialog-heading,
  .chat-thread,
  .dialog-composer {
    padding-right: 1rem;
    padding-left: 1rem;
  }

  .dialog-tools .toggle-pill,
  .ghost-tool {
    flex: 1 1 auto;
    justify-content: center;
  }

  .send-tool {
    width: 100%;
    margin-left: 0;
  }

  .workbench-page .site-header {
    padding-right: 0.75rem;
    padding-left: 0.75rem;
  }

  .workbench-page .site-nav a {
    padding: 0.24rem 0.12rem;
  }

  .workbench-page .header-actions {
    justify-content: flex-end;
  }

  .workbench-page .header-action {
    display: none;
  }

  .create-control-rail {
    padding-right: 0.72rem;
    padding-left: 0.72rem;
  }

  .create-control-rail .control-intro p {
    display: none;
  }

  .side-mode-tabs {
    top: 86px;
  }

  .history-item {
    padding: 0.58rem 0.62rem;
  }

  .workspace-right {
    grid-template-rows: auto auto minmax(390px, 1fr);
  }

  .artifact-panel {
    padding: 0.7rem;
  }

  .artifact-panel pre,
  .artifact-panel textarea[data-work-code] {
    min-height: 330px;
    font-size: 0.76rem;
  }

  .code-artifact.is-active,
  .preview-artifact.is-active {
    min-height: 520px;
  }

  .preview-stage {
    min-height: 430px;
    padding: 0.55rem;
  }

  .preview-device-shell.is-desktop {
    height: 430px;
  }

  .preview-device-shell.is-mobile {
    width: min(100%, 320px);
    border-radius: 24px;
  }

  .panel-bottom-actions {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .preview-bottom-actions {
    grid-template-columns: repeat(5, minmax(0, 1fr));
  }

  .preview-bottom-actions button {
    padding-right: 0.35rem;
    padding-left: 0.35rem;
  }

  .form-row {
    grid-template-columns: 1fr;
  }

  .agnes-panel:not(.workbench-panel) {
    padding: 0.72rem;
  }

  .media-placeholder,
  .task-box {
    min-height: 240px;
  }

  .cover-tools,
  .publish-preview {
    display: grid;
    grid-template-columns: 1fr;
  }

  .cover-tools button,
  .publish-card button[type="submit"] {
    width: 100%;
  }
}

@media (max-width: 680px) {
  .generation-studio {
    grid-template-columns: 1fr;
    height: auto;
    min-height: calc(100vh - 102px);
    overflow: visible;
  }

  .dialog-panel {
    min-height: 520px;
    border-right: 0;
    border-bottom: 1px solid var(--line);
  }

  .code-stage {
    min-height: 720px;
  }

  .code-stage-footer {
    grid-template-columns: 1fr;
    align-items: flex-start;
  }

  .preview-actions,
  .code-actions {
    justify-content: flex-start;
  }
}

@media (max-width: 760px) {
  body:not(.inspiration-page) {
    padding-bottom: calc(64px + env(safe-area-inset-bottom));
  }

  .site-nav {
    display: none;
  }

  .mobile-tabbar {
    position: fixed;
    right: 0;
    bottom: 0;
    left: 0;
    z-index: 80;
    display: grid;
    grid-template-columns: repeat(5, minmax(0, 1fr));
    min-height: calc(60px + env(safe-area-inset-bottom));
    padding: 0.38rem 0.42rem max(0.38rem, env(safe-area-inset-bottom));
    border-top: 1px solid rgba(255, 255, 255, 0.08);
    background: rgba(0, 0, 0, 0.88);
    backdrop-filter: blur(18px);
  }

  .mobile-tabbar a {
    display: grid;
    place-items: center;
    gap: 0.1rem;
    color: #8c9489;
    font-size: 0.68rem;
    font-weight: 900;
    line-height: 1.1;
  }

  .mobile-tabbar a span {
    display: grid;
    place-items: center;
    width: 28px;
    height: 26px;
    color: #dfe6da;
    font-size: 1rem;
    line-height: 1;
  }

  .mobile-tabbar a.is-active,
  .mobile-tabbar a.is-active span {
    color: var(--acid);
  }

  .home-page {
    scroll-snap-type: none;
  }

  .home-page .hero {
    min-height: 78svh;
    scroll-snap-align: none;
  }

  .home-page .feed-section {
    width: 100%;
    padding: 1rem 0.85rem 5.4rem;
  }

  .home-page .feed-section > .tabs,
  .home-page .feed-filter,
  .home-page .feed-pagination {
    display: none;
  }

  .home-page .project-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 0.62rem;
    margin: 0;
  }

  .home-page .project-card {
    position: static;
    min-height: 0;
    border: 1px solid #222;
    border-radius: 8px;
    background: #111;
    scroll-snap-align: none;
  }

  .home-page .thumb {
    position: relative;
    inset: auto;
    height: auto;
    min-height: 160px;
    aspect-ratio: 4 / 5;
  }

  .home-page .card-body {
    position: static;
    right: auto;
    bottom: auto;
    left: auto;
    padding: 0.65rem 0.7rem 0.78rem;
    background: transparent;
  }

  .home-page .project-title {
    font-size: 0.86rem;
    line-height: 1.35;
  }

  .home-page .project-meta {
    display: grid;
    grid-template-columns: auto 1fr;
    font-size: 0.66rem;
  }

  .home-page .project-meta span:last-child {
    display: none;
  }

  .home-page .view-pill {
    right: 0.55rem;
    bottom: 0.5rem;
  }

  .home-page .source-pill {
    left: 0.55rem;
    bottom: 0.5rem;
  }

  .inspiration-page {
    padding-bottom: 0;
  }

  .inspiration-page .mobile-tabbar {
    background: linear-gradient(180deg, transparent, rgba(0, 0, 0, 0.9) 28%, rgba(0, 0, 0, 0.96));
  }

  .inspiration-copy {
    bottom: calc(4.75rem + env(safe-area-inset-bottom));
    width: calc(100vw - 5.9rem);
  }

  .inspiration-copy h1 {
    font-size: clamp(1.38rem, 8vw, 2.45rem);
  }

  .inspiration-copy p {
    display: -webkit-box;
    overflow: hidden;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    font-size: 0.88rem;
  }

  .inspiration-tags {
    gap: 0.34rem;
  }

  .inspiration-tags span {
    padding: 0.26rem 0.44rem;
    font-size: 0.66rem;
  }

  .inspiration-actions {
    right: 0.72rem;
    bottom: calc(5.35rem + env(safe-area-inset-bottom));
    gap: 0.56rem;
  }

  .inspiration-actions button,
  .inspiration-actions a {
    width: 42px;
    height: 42px;
  }

  .discover-hero {
    grid-template-columns: 1fr;
    gap: 1rem;
    padding: 2.2rem 0.9rem 1rem;
  }

  .discover-hero h1 {
    font-size: clamp(1.85rem, 11vw, 3.1rem);
  }

  .discover-search {
    display: grid;
  }

  .discover-index {
    grid-template-columns: 1fr;
    padding: 0.85rem 0.9rem 0;
  }

  .discover-results {
    padding: 0.9rem 0.9rem 5.3rem;
  }
}
